How to set $(OutDir), $(TargetName), $(TargetExt), and %(Lib.OutputFile) with Visual Studio?

前端 未结 7 865
轻奢々
轻奢々 2021-01-03 22:52

I\'m trying to build gtest on Visual Studio 2010. After converting the solution file, I tried to build, and I got the following warning messages.

Warning 1           


        
7条回答
  •  忘掉有多难
    2021-01-03 23:14

    I think no one has the right answer, i solved this way: in project properties pages, check if linker->General->Output file match configuration properties->General->target name & configuration properties->General->target extension.

    You don't need to add any 'd', of course, is more simple set to Inherit from parent or project defaults, for all 3 variables.

    Example:

    Linker → General → Output File = "myproject.exe"
    

    then:

    Configuration Properties → General → Target Name = "myproject"
    
    configuration properties → General → Target Extension = ".exe"
    

提交回复
热议问题