This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "CMake".
The branch, next has been updated via e8803698fd37ad214347df5939c267548d77eb07 (commit) via b7af338c78b970a4cf2c92d5ea017131d9af4200 (commit) from ac4c26ca9cc431e2a7994e35d4a401c0e800eeff (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e8803698fd37ad214347df5939c267548d77eb07 commit e8803698fd37ad214347df5939c267548d77eb07 Merge: ac4c26c b7af338 Author: Brad King <brad.k...@kitware.com> AuthorDate: Thu Mar 13 15:06:32 2014 -0400 Commit: CMake Topic Stage <kwro...@kitware.com> CommitDate: Thu Mar 13 15:06:32 2014 -0400 Merge topic 'fix-Qt4-moc-command-depends' into next b7af338c Revert topic 'fix-Qt4-moc-command-depends' http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=b7af338c78b970a4cf2c92d5ea017131d9af4200 commit b7af338c78b970a4cf2c92d5ea017131d9af4200 Author: Brad King <brad.k...@kitware.com> AuthorDate: Thu Mar 13 15:06:57 2014 -0400 Commit: Brad King <brad.k...@kitware.com> CommitDate: Thu Mar 13 15:06:57 2014 -0400 Revert topic 'fix-Qt4-moc-command-depends' It will be revised and restored. diff --git a/Modules/Qt4Macros.cmake b/Modules/Qt4Macros.cmake index aca8996..8baf896 100644 --- a/Modules/Qt4Macros.cmake +++ b/Modules/Qt4Macros.cmake @@ -141,7 +141,7 @@ macro (QT4_CREATE_MOC_COMMAND infile outfile moc_flags moc_options moc_target) set(_moc_extra_parameters_file @${_moc_parameters_file}) add_custom_command(OUTPUT ${outfile} COMMAND Qt4::moc ${_moc_extra_parameters_file} - DEPENDS ${infile} ${_moc_parameters_file} + DEPENDS ${infile} ${_moc_working_dir} VERBATIM) endmacro () diff --git a/Source/cmCustomCommandGenerator.cxx b/Source/cmCustomCommandGenerator.cxx index 04a514f..a091cff 100644 --- a/Source/cmCustomCommandGenerator.cxx +++ b/Source/cmCustomCommandGenerator.cxx @@ -90,21 +90,8 @@ std::vector<std::string> const& cmCustomCommandGenerator::GetOutputs() const return this->CC.GetOutputs(); } -#include <assert.h> - //---------------------------------------------------------------------------- std::vector<std::string> const& cmCustomCommandGenerator::GetDepends() const { - this->Depends.clear(); - std::vector<std::string> depends = this->CC.GetDepends(); - for(std::vector<std::string>::const_iterator - i = depends.begin(); - i != depends.end(); ++i) - { - cmsys::auto_ptr<cmCompiledGeneratorExpression> cge = this->GE->Parse(*i); - std::string rr = cge->Evaluate(this->Makefile, this->Config); - cmSystemTools::ExpandListArgument( - rr, this->Depends); - } - return this->Depends; + return this->CC.GetDepends(); } diff --git a/Source/cmCustomCommandGenerator.h b/Source/cmCustomCommandGenerator.h index a59f307..cbcdb41 100644 --- a/Source/cmCustomCommandGenerator.h +++ b/Source/cmCustomCommandGenerator.h @@ -28,7 +28,6 @@ class cmCustomCommandGenerator bool OldStyle; bool MakeVars; cmGeneratorExpression* GE; - mutable std::vector<std::string> Depends; public: cmCustomCommandGenerator(cmCustomCommand const& cc, const std::string& config, diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index fc6b881..db88749 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -604,9 +604,6 @@ private: bool IsUtility(std::string const& dep); void CheckCustomCommand(cmCustomCommand const& cc); void CheckCustomCommands(const std::vector<cmCustomCommand>& commands); - void FollowCommandDepends(cmCustomCommand const& cc, - const std::string& config, - std::set<std::string>& emitted); }; //---------------------------------------------------------------------------- @@ -823,48 +820,16 @@ cmTargetTraceDependencies } // Queue the custom command dependencies. - std::vector<std::string> configs; - std::set<std::string> emitted; - this->Makefile->GetConfigurations(configs); - if (configs.empty()) - { - this->FollowCommandDepends(cc, "", emitted); - } - for(std::vector<std::string>::const_iterator ci = configs.begin(); - ci != configs.end(); ++ci) - { - this->FollowCommandDepends(cc, *ci, emitted); - } -} - -//---------------------------------------------------------------------------- -void cmTargetTraceDependencies::FollowCommandDepends(cmCustomCommand const& cc, - const std::string& config, - std::set<std::string>& emitted) -{ - cmListFileBacktrace lfbt; - std::vector<std::string> evaluatedDepends; - for(std::vector<std::string>::const_iterator di = cc.GetDepends().begin(); - di != cc.GetDepends().end(); ++di) - { - cmGeneratorExpression ge(lfbt); - cmsys::auto_ptr<cmCompiledGeneratorExpression> cge = ge.Parse(*di); - cmSystemTools::ExpandListArgument( - cge->Evaluate(this->Makefile, config), evaluatedDepends); - } - - for(std::vector<std::string>::const_iterator di = evaluatedDepends.begin(); - di != evaluatedDepends.end(); ++di) + std::vector<std::string> const& depends = cc.GetDepends(); + for(std::vector<std::string>::const_iterator di = depends.begin(); + di != depends.end(); ++di) { std::string const& dep = *di; - if(emitted.insert(dep).second) + if(!this->IsUtility(dep)) { - if(!this->IsUtility(dep)) - { - // The dependency does not name a target and may be a file we - // know how to generate. Queue it. - this->FollowName(dep); - } + // The dependency does not name a target and may be a file we + // know how to generate. Queue it. + this->FollowName(dep); } } } diff --git a/Tests/CustomCommand/CMakeLists.txt b/Tests/CustomCommand/CMakeLists.txt index 4a74aec..bbae387 100644 --- a/Tests/CustomCommand/CMakeLists.txt +++ b/Tests/CustomCommand/CMakeLists.txt @@ -185,7 +185,7 @@ add_executable(CustomCommand # here to test adding the generation rule after referencing the # generated source in a target. add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/generated.c - DEPENDS $<1:generator> $<0:does_not_exist> + DEPENDS generator COMMAND generator ARGS ${PROJECT_BINARY_DIR}/generated.c ) diff --git a/Tests/Qt4Targets/CMakeLists.txt b/Tests/Qt4Targets/CMakeLists.txt index 60954a2..af9fc3f 100644 --- a/Tests/Qt4Targets/CMakeLists.txt +++ b/Tests/Qt4Targets/CMakeLists.txt @@ -36,24 +36,3 @@ add_executable(Qt4WrapMacroTest WIN32 main_wrap_test.cpp ${moc_file}) set_property(TARGET Qt4WrapMacroTest PROPERTY AUTOMOC OFF) target_include_directories(Qt4WrapMacroTest PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/interface") target_link_libraries(Qt4WrapMacroTest Qt4::QtGui) - -set(timeformat "%Y%j%H%M%S") -file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild") -execute_process(COMMAND "${CMAKE_COMMAND}" -DADD_DEF=0 "-H${CMAKE_CURRENT_SOURCE_DIR}/IncrementalMoc" "-B${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild" "-DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE}") -execute_process(COMMAND "${CMAKE_COMMAND}" --build "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild") -file(TIMESTAMP "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild/moc_foo.cpp" tsvar_before "${timeformat}") -if (NOT tsvar_before) - message(SEND_ERROR "Unable to read timestamp from moc file from first build!") -endif() - -execute_process(COMMAND "${CMAKE_COMMAND}" -E sleep 1) # Ensure that at least a second passes. -execute_process(COMMAND "${CMAKE_COMMAND}" -DADD_DEF=1 "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild" "-DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE}") -execute_process(COMMAND "${CMAKE_COMMAND}" --build "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild") -file(TIMESTAMP "${CMAKE_CURRENT_BINARY_DIR}/IncrementalMocBuild/moc_foo.cpp" tsvar_after "${timeformat}") -if (NOT tsvar_after) - message(SEND_ERROR "Unable to read timestamp from moc file from first build!") -endif() - -if (NOT tsvar_after GREATER tsvar_before) - message(SEND_ERROR "Rebuild did not re-create moc file. Before: ${tsvar_before}. After: ${tsvar_after}") -endif() diff --git a/Tests/Qt4Targets/IncrementalMoc/CMakeLists.txt b/Tests/Qt4Targets/IncrementalMoc/CMakeLists.txt deleted file mode 100644 index 4ba0ced..0000000 --- a/Tests/Qt4Targets/IncrementalMoc/CMakeLists.txt +++ /dev/null @@ -1,13 +0,0 @@ - -cmake_minimum_required(VERSION 2.8.12) -project(IncrementalMoc) - -find_package(Qt4 REQUIRED) - -qt4_generate_moc(foo.h moc_foo.cpp) - -add_library(testlib foo.cpp moc_foo.cpp) -target_link_libraries(testlib Qt4::QtCore) -if (ADD_DEF) - target_compile_definitions(testlib PRIVATE NEW_DEF) -endif() diff --git a/Tests/Qt4Targets/IncrementalMoc/foo.cpp b/Tests/Qt4Targets/IncrementalMoc/foo.cpp deleted file mode 100644 index e924f7e..0000000 --- a/Tests/Qt4Targets/IncrementalMoc/foo.cpp +++ /dev/null @@ -1,8 +0,0 @@ - -#include "foo.h" - -Foo::Foo() - : QObject(0) -{ - -} diff --git a/Tests/Qt4Targets/IncrementalMoc/foo.h b/Tests/Qt4Targets/IncrementalMoc/foo.h deleted file mode 100644 index 38d899f..0000000 --- a/Tests/Qt4Targets/IncrementalMoc/foo.h +++ /dev/null @@ -1,9 +0,0 @@ - -#include <QObject> - -class Foo : QObject -{ - Q_OBJECT -public: - Foo(); -}; ----------------------------------------------------------------------- Summary of changes: Modules/Qt4Macros.cmake | 2 +- Source/cmCustomCommandGenerator.cxx | 15 +------- Source/cmCustomCommandGenerator.h | 1 - Source/cmGeneratorTarget.cxx | 49 ++++-------------------- Tests/CustomCommand/CMakeLists.txt | 2 +- Tests/Qt4Targets/CMakeLists.txt | 21 ---------- Tests/Qt4Targets/IncrementalMoc/CMakeLists.txt | 13 ------- Tests/Qt4Targets/IncrementalMoc/foo.cpp | 8 ---- Tests/Qt4Targets/IncrementalMoc/foo.h | 9 ----- 9 files changed, 10 insertions(+), 110 deletions(-) delete mode 100644 Tests/Qt4Targets/IncrementalMoc/CMakeLists.txt delete mode 100644 Tests/Qt4Targets/IncrementalMoc/foo.cpp delete mode 100644 Tests/Qt4Targets/IncrementalMoc/foo.h hooks/post-receive -- CMake _______________________________________________ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits