Summary: | Variables defined in the CMakeLists.txt of a parent directory are not propagated to the CMakeLists.txt of the subdirectories | ||
---|---|---|---|
Product: | [Applications] kdevelop | Reporter: | Daniel Calviño Sánchez <danxuliu> |
Component: | Build tools: CMake | Assignee: | kdevelop-bugs-null |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | git master | ||
Target Milestone: | 4.3.0 | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/kdevelop/df00d058fcce0d4026704aeffbb6802dd9582433 | Version Fixed In: | |
Attachments: | Unit test for CMakeManagerTest showing the bug |
Description
Daniel Calviño Sánchez
2012-11-07 11:05:26 UTC
Git commit df00d058fcce0d4026704aeffbb6802dd9582433 by Aleix Pol. Committed on 15/11/2012 at 03:48. Pushed by apol into branch 'master'. Fix subdirectory scoping in cmake projects Don't pop the scope until all the subdirectories have been processed. Thanks to Daniel Calviño Sánchez for such a helpful bug report :) Related: bug 238455 M +6 -3 projectmanagers/cmake/cmakemanager.cpp M +27 -0 projectmanagers/cmake/tests/cmakemanagertest.cpp M +1 -0 projectmanagers/cmake/tests/cmakemanagertest.h http://commits.kde.org/kdevelop/df00d058fcce0d4026704aeffbb6802dd9582433 (In reply to comment #1) > Thanks to Daniel Calviño Sánchez for such a helpful bug report :) Glad to help :) > M +6 -3 projectmanagers/cmake/cmakemanager.cpp > M +27 -0 projectmanagers/cmake/tests/cmakemanagertest.cpp > M +1 -0 projectmanagers/cmake/tests/cmakemanagertest.h > > http://commits.kde.org/kdevelop/df00d058fcce0d4026704aeffbb6802dd9582433 It looks like you missed to add "projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables". The unit test fails without it even if the bug was fixed ;) Git commit b4772e0493cc3442871d0f6779053ca03745689e by Aleix Pol. Committed on 16/11/2012 at 02:48. Pushed by apol into branch '4.4'. Forgot to add the unit test input! A +19 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/CMakeLists.txt A +3 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/conditions_in_subdirectory_based_on_root_variables.kdev4 A +2 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/foo.cpp [License: UNKNOWN] * A +9 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/subdirectory/CMakeLists.txt A +2 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/subdirectory/foo.cpp [License: UNKNOWN] * The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page. http://commits.kde.org/kdevelop/b4772e0493cc3442871d0f6779053ca03745689e Git commit aef8dfad6b8e397ca645a2d0e97dce087a23bbfa by Aleix Pol. Committed on 16/11/2012 at 02:48. Pushed by apol into branch 'master'. Forgot to add the unit test input! A +19 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/CMakeLists.txt A +3 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/conditions_in_subdirectory_based_on_root_variables.kdev4 A +2 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/foo.cpp [License: UNKNOWN] * A +9 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/subdirectory/CMakeLists.txt A +2 -0 projectmanagers/cmake/tests/manual/conditions_in_subdirectory_based_on_root_variables/subdirectory/foo.cpp [License: UNKNOWN] * The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page. http://commits.kde.org/kdevelop/aef8dfad6b8e397ca645a2d0e97dce087a23bbfa |