Use a "User Macro" in .vcproj RelativePath
Posted
by Tom Leys
on Stack Overflow
See other posts from Stack Overflow
or by Tom Leys
Published on 2009-05-22T04:39:15Z
Indexed on
2010/05/24
3:00 UTC
Read the original article
Hit count: 308
Inside .vcproj files There is a list of all source files in your project.
How can we use a macro to specify the path to a source file? If we do this:
<File
RelativePath="$(Lib3rdParty)\Qt\qtwinmigrate-2.5-commercial\src\qmfcapp.cpp">
</File>
The compiler cannot find the folder:
qmfcapp.cpp
c1xx : fatal error C1083: Cannot open source file: '.\$(lib3rdparty)\qt\qtwinmigrate- 2.5-commercial\src\qmfcapp.cpp': No such file or directory
As you can see, our project compiles in several source files from QT. QT lives inside a folder of external libraries, and we don't want hardcode the path from our project to that folder (we have a very large solution)
© Stack Overflow or respective owner