[CMake] INSTALL with FILES and generator expressions

Jörg Kreuzberger j.kreuzberger at procitec.de
Fri Nov 21 09:59:50 EST 2014


Hi!

i would like to install files with generator expressions. I define a variable with my qt install files.
These looks like this:

QT_INSTALL_FILES $<$<CONFIG:Debug>:/home/src/qt/486-64-dbg/lib/libQtCore-486-ubgcc482x64.so.4>;$<$<CONFIG:Release>:/home/src/qt/486-64-dbg/lib/libQtCore-486-ubgcc482x64.so.4>;$<$<CONFIG:Debug>:/home/src/qt/486-64-dbg/lib/libQtXml-486-ubgcc482x64.so.4>;$<$<CONFIG:Release>:/home/src/qt/486-64-dbg/lib/libQtXml-486-ubgcc482x64.so.4>;/home/src/s4_branch/s4/src/procitec/src/tools/internal/genmaw/$<$<CONFIG:Debug>:/home/src/qt/486-64-dbg/lib/libQtCore-486-ubgcc482x64.so.4>;/home/src/s4_branch/s4/src/procitec/src/tools/internal/genmaw/$<$<CONFIG:Release>:/home/src/qt/486-64-dbg/lib/libQtCore-486-ubgcc482x64.so.4>;/home/src/s4_branch/s4/src/procitec/src/tools/internal/genmaw/$<$<CONFIG:Debug>:/home/src/qt/486-64-dbg/lib/libQtXml-486-ubgcc482x64.so.4>;/home/src/s4_branch/s4/src/procitec/src/tools/internal/genmaw/$<$<CONFIG:Release>:/home/src/qt/486-64-dbg/lib/libQtXml-486-ubgcc482x64.so.4>

If i now install, cmake prepends the CMAKE_CURRENT_SOURCE_DIR to the files and fails with "cannot find file /my/current/source/dir/home/...."

Why is the file detected as "full" path?
Environment is unix and cmake 3.0, generator is unix makefiles

Thanks for any help
Joerg



More information about the CMake mailing list