Is there a way to specify assembly references based on build configuration in Visual Studio?

后端 未结 2 1173
孤城傲影
孤城傲影 2020-12-07 18:51

I have a project that adds some extensibility to another application through their API. However, I want to be able to use the same project for multiple versions of their app

2条回答
  •  长情又很酷
    2020-12-07 19:24

    
      False
      ..\SharedLibs\log4net\$(Platform)\$(Configuration)\log4net.dll
    
    

    You can replace the hint path with the properties:

    $(Configuration) is equivalent to Release/Debug or whatever other configuration you have. $(Platform) is equivalent to x86/x64/Any CPU

    If your configuration includes Any CPU then you will need to put single quotes around $(Configuration)

    Also refer to the condition options referenced by adrianbanks

提交回复
热议问题