[CMake] Why can't INSTALL(TARGET ...) find an executable that CMake
built?
Christian Convey
christian.convey at gmail.com
Mon Jul 30 12:31:43 EDT 2007
I've got a multi-level project. I'm not explicitly setting the
EXECUTABLE_OUTPUT_PATH variable, so executables end up in the same
directory as whatever CMakeLists.txt file dfines the executable.
So I have an executable named "MOOSDB", which ends up in the directory
Core/MOOSDB/
In Core/MOOSDB/CMakeLists.txt, I also have this line:
INSTALL(
TARGETS MOOSDB
DESTINATION bin/moos-${MOOS_VERSION}
COMPONENT Moos_Core)
But installation doesn't work!
>From my project's top-level directory I do a "make all", which
definitely produces the MOOSDB executable, placing it within the
Core/MOOSDB/ subdirectory.
But then when I run the following command, I get this output:
-- Install configuration: ""
-- Install configuration: ""
-- Install configuration: ""
-- Install configuration: ""
-- Install configuration: ""
CMake Error: Error in cmake code at
/home/cjc/src/x/Core/MOOSDB/cmake_install.cmake:30:
FILE INSTALL cannot find file
"/home/cjc/src/x/Core/MOOSDB/CMakeFiles/CMakeRelink.dir/MOOSDB" to
install.
Current CMake stack:
/home/cjc/src/x/cmake_install.cmake;/home/cjc/src/x/Core/cmake_install.cmake;/home/cjc/src/x/Core/MOOSDB/cmake_install.cmake
Any ideas what I'm doing wrong?
Thanks,
Christian
More information about the CMake
mailing list