[CMake] Problems with CMAKE language selection
Carminati Federico
federico.carminati at cern.ch
Mon Oct 13 10:32:33 EDT 2008
Dear All,
I have a problem with Cmake while choosing the language within
a CMakeList.txt. It was explained to me on this list that this is
indeed not possible, however a friend pointed me out an "undocumented"
feature of CMake. If you initialise the CMakeLists.txt with
Project(MyProject NONE)
you can enable languages within the CMakeLists.txt after having set
the CMAKE_<compiler>_COMPILER variable. Most things seem to work,
however there is a snag. If I run the attached simple CMakeLists.txt
on the mac, I get the following error message
CMake Error at /usr/local/share/cmake-2.7/Modules/
CMakeFindBinUtils.cmake:59 (MESSAGE):
Could not find install_name_tool, please check your installation.
The reason is that the variable CMAKE_INSTALL_NAME_TOOL is pre-set to
be "install_name_tool", so that when in CMakeFindBinUtils.cmake,
specifically for the Mac, this program is looked up at line 55, being
the variable defined, it is not found. This may have something to do
with the comment at line 50 of Darwin.cmake, which talks about an
"hack"... This is easily solved uncommenting line 12 of the attached
CMakeLists.txt that resets to NOTFOUND the variable.
Is this a bug? Should I submit this to Mantis? Any remarks? Thanks and
best regards,
Federico Carminati
CERN-PH
1211 Geneva 23
Switzerland
Tel: +41 22 76 74959
Fax: +41 22 76 68505
Mobile: +41 76 487 4843
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: CMakeLists.txt
URL: <http://www.cmake.org/pipermail/cmake/attachments/20081013/5f51938d/attachment.txt>
-------------- next part --------------
More information about the CMake
mailing list