View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0012552 | CMake | CMake | public | 2011-11-02 10:06 | 2012-02-08 13:51 | ||||
Reporter | bert | ||||||||
Assigned To | Rolf Eike Beer | ||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||
Status | closed | Resolution | no change required | ||||||
Platform | x86_64 | OS | Ubuntu | OS Version | 10.10 | ||||
Product Version | CMake-2-8 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0012552: CMake ignores toolchain file | ||||||||
Description | CMake seems to ignore a (possibly faulty) toolchain file. Regardless whether I use the CMAKE_TOOLCHAIN_FILE option or not, the exact same Makefile is generated. Furthermore, CMake doesn't even throw errors on faulty or non-exisiting toolchain files. I'm not sure whether this is intended behavior, though. | ||||||||
Steps To Reproduce | $ cmake . -- Entering Project Cmake File... -- Configuring the ... Library... -- Configuring for Standard-Linux... -- Configuring done -- Generating done -- Build files have been written to: ... $ cmake -DCMAKE_TOOLCHAIN_FILE=toolchain-that-should-work.cmake . -- Entering Project Cmake File... -- Configuring the ... Library... -- Configuring for Standard-Linux... -- Configuring done -- Generating done -- Build files have been written to: ... $ echo fubar > dummy-toolchain.cmake $ cmake -DCMAKE_TOOLCHAIN_FILE=dummy-toolchain.cmake . -- Entering Project Cmake File... -- Configuring the ... Library... -- Configuring for Standard-Linux... -- Configuring done -- Generating done -- Build files have been written to: ... $ cmake -DCMAKE_TOOLCHAIN_FILE=nonexisting-file.cmake . -- Entering Project Cmake File... -- Configuring the ... Library... -- Configuring for Standard-Linux... -- Configuring done -- Generating done -- Build files have been written to: ... A diff on all the generated Makefiles shows no differences. | ||||||||
Additional Information | $ uname -a Linux PC 2.6.35-30-generic 0000061-Ubuntu SMP Tue Oct 11 17:52:57 UTC 2011 x86_64 GNU/Linux $ cmake --version cmake version 2.8.2 | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Relationships | |
Relationships |
Notes | |
(0027709) Eric NOULARD (developer) 2011-11-02 10:13 |
Hi Bert, This is because you've already done one CMake run in the same build dir so that CMake is using previously cached vars values. Could you retry the faulty toolchain case in a pristine build dir? As a side note you'd better use out-of-source build: http://www.cmake.org/Wiki/CMake_FAQ#Out-of-source_build_trees [^] |
(0027710) bert (reporter) 2011-11-02 11:34 |
Ok, this was obviously my fault. After removing the CMakeCache.txt, CMake does not ignore the CMAKE_TOOLCHAIN_OPTION anymore. Thanks for the hints and sorry for sort of abusing the bug tracker. Maybe some kind of "--force" option could make this behavior more transparent to the user? Or maybe a warning, that one is trying to screw up a previously generated build tree with build files that would actually belong into a new, seperate build tree. But just ignoring user inputs doesn't feel right to me. |
(0027729) Eric NOULARD (developer) 2011-11-04 18:50 |
Suggest the requested behavior on the mailing thus you'll get more feedback on your suggestion. That said it's very convenient to be able to call "cmake <path-to-existing-build>" in a previously configured directory and cached values are not overwritten by the value in the toolchain. |
Notes |
Issue History | |||
Date Modified | Username | Field | Change |
2011-11-02 10:06 | bert | New Issue | |
2011-11-02 10:13 | Eric NOULARD | Note Added: 0027709 | |
2011-11-02 11:34 | bert | Note Added: 0027710 | |
2011-11-04 18:50 | Eric NOULARD | Note Added: 0027729 | |
2012-02-08 13:51 | Rolf Eike Beer | Status | new => closed |
2012-02-08 13:51 | Rolf Eike Beer | Assigned To | => Rolf Eike Beer |
2012-02-08 13:51 | Rolf Eike Beer | Resolution | open => no change required |
Issue History |
Copyright © 2000 - 2018 MantisBT Team |