[Cmake-commits] CMake branch, next, updated. v3.1.0-rc1-260-g13cbd03
Brad King
brad.king at kitware.com
Fri Oct 31 13:37:38 EDT 2014
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 13cbd0344b9f4a3ecf9e19c42f9125093ca9cc95 (commit)
via 1531df2b866df9aa52dc54219a4552e94f47b622 (commit)
via 4abbb1400d81e1288cdf1e2f708eaa938f7b3955 (commit)
via bd7ba8e25f0bc2d57bc162d2d945e10bad29a327 (commit)
via e9282782e489a78de9c2896ee01fdd02ce8ca396 (commit)
from 311227b6d8629e4d6b65c8e57d706ae6fcb07ee0 (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=13cbd0344b9f4a3ecf9e19c42f9125093ca9cc95
commit 13cbd0344b9f4a3ecf9e19c42f9125093ca9cc95
Merge: 311227b 1531df2
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Oct 31 13:37:36 2014 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Fri Oct 31 13:37:36 2014 -0400
Merge topic 'fix-configure_file-COPYONLY' into next
1531df2b configure_file: Warn about unknown arguments
4abbb140 Qt4: Fix configure_file call to use COPYONLY, not COPY_ONLY
bd7ba8e2 KWSys: Fix configure_file call to use COPYONLY, not COPY_ONLY
e9282782 Help: Fix configure_file call to use COPYONLY, not COPY_ONLY
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=1531df2b866df9aa52dc54219a4552e94f47b622
commit 1531df2b866df9aa52dc54219a4552e94f47b622
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Oct 31 13:07:21 2014 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Fri Oct 31 13:21:21 2014 -0400
configure_file: Warn about unknown arguments
Extend the RunCMake.configure_file test with a case covering possible
common typos of the COPYONLY option.
Reported-by: Iosif Neitzke <iosif.neitzke at gmail.com>
diff --git a/Source/cmConfigureFileCommand.cxx b/Source/cmConfigureFileCommand.cxx
index 395e6c8..cb727a8 100644
--- a/Source/cmConfigureFileCommand.cxx
+++ b/Source/cmConfigureFileCommand.cxx
@@ -74,6 +74,7 @@ bool cmConfigureFileCommand
this->CopyOnly = false;
this->EscapeQuotes = false;
+ std::string unknown_args;
this->AtOnly = false;
for(unsigned int i=2;i < args.size();++i)
{
@@ -99,6 +100,18 @@ bool cmConfigureFileCommand
{
/* Ignore legacy option. */
}
+ else
+ {
+ unknown_args += " ";
+ unknown_args += args[i];
+ unknown_args += "\n";
+ }
+ }
+ if (!unknown_args.empty())
+ {
+ std::string msg = "configure_file called with unknown argument(s):\n";
+ msg += unknown_args;
+ this->Makefile->IssueMessage(cmake::AUTHOR_WARNING, msg);
}
if ( !this->ConfigureFile() )
diff --git a/Tests/RunCMake/configure_file/RunCMakeTest.cmake b/Tests/RunCMake/configure_file/RunCMakeTest.cmake
index c8bfa57..c010256 100644
--- a/Tests/RunCMake/configure_file/RunCMakeTest.cmake
+++ b/Tests/RunCMake/configure_file/RunCMakeTest.cmake
@@ -6,3 +6,4 @@ run_cmake(UTF16LE-BOM)
run_cmake(UTF16BE-BOM)
run_cmake(UTF32LE-BOM)
run_cmake(UTF32BE-BOM)
+run_cmake(UnknownArg)
diff --git a/Tests/RunCMake/configure_file/UnknownArg-stderr.txt b/Tests/RunCMake/configure_file/UnknownArg-stderr.txt
new file mode 100644
index 0000000..46930c0
--- /dev/null
+++ b/Tests/RunCMake/configure_file/UnknownArg-stderr.txt
@@ -0,0 +1,10 @@
+CMake Warning \(dev\) at UnknownArg.cmake:1 \(configure_file\):
+ configure_file called with unknown argument\(s\):
+
+ COPY_ONLY
+ COPYFILE
+ COPY_FILE
+
+Call Stack \(most recent call first\):
+ CMakeLists.txt:3 \(include\)
+This warning is for project developers. Use -Wno-dev to suppress it.
diff --git a/Tests/RunCMake/configure_file/UnknownArg.cmake b/Tests/RunCMake/configure_file/UnknownArg.cmake
new file mode 100644
index 0000000..5125c83
--- /dev/null
+++ b/Tests/RunCMake/configure_file/UnknownArg.cmake
@@ -0,0 +1,2 @@
+configure_file(${CMAKE_ROOT}/Modules/CMakeConfigurableFile.in UnknownArg.txt
+ @ONLY COPYONLY COPY_ONLY COPYFILE COPY_FILE)
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=4abbb1400d81e1288cdf1e2f708eaa938f7b3955
commit 4abbb1400d81e1288cdf1e2f708eaa938f7b3955
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Oct 31 13:16:07 2014 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Fri Oct 31 13:20:19 2014 -0400
Qt4: Fix configure_file call to use COPYONLY, not COPY_ONLY
diff --git a/Modules/Qt4Macros.cmake b/Modules/Qt4Macros.cmake
index 8c4daac..6516b0a 100644
--- a/Modules/Qt4Macros.cmake
+++ b/Modules/Qt4Macros.cmake
@@ -232,7 +232,7 @@ macro (QT4_ADD_RESOURCES outfiles )
# let's make a configured file and add it as a dependency so cmake is run
# again when dependencies need to be recomputed.
QT4_MAKE_OUTPUT_FILE("${infile}" "" "qrc.depends" out_depends)
- configure_file("${infile}" "${out_depends}" COPY_ONLY)
+ configure_file("${infile}" "${out_depends}" COPYONLY)
else()
# The .qrc file does not exist (yet). Let's add a dependency and hope
# that it will be generated later
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=bd7ba8e25f0bc2d57bc162d2d945e10bad29a327
commit bd7ba8e25f0bc2d57bc162d2d945e10bad29a327
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Oct 31 13:09:11 2014 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Fri Oct 31 13:20:19 2014 -0400
KWSys: Fix configure_file call to use COPYONLY, not COPY_ONLY
diff --git a/Source/kwsys/CMakeLists.txt b/Source/kwsys/CMakeLists.txt
index 8ca4360..2067690 100644
--- a/Source/kwsys/CMakeLists.txt
+++ b/Source/kwsys/CMakeLists.txt
@@ -265,7 +265,7 @@ STRING(COMPARE EQUAL "${PROJECT_SOURCE_DIR}" "${PROJECT_BINARY_DIR}"
KWSYS_IN_SOURCE_BUILD)
IF(NOT KWSYS_IN_SOURCE_BUILD)
CONFIGURE_FILE(${PROJECT_SOURCE_DIR}/kwsysPrivate.h
- ${PROJECT_BINARY_DIR}/kwsysPrivate.h COPY_ONLY IMMEDIATE)
+ ${PROJECT_BINARY_DIR}/kwsysPrivate.h COPYONLY IMMEDIATE)
ENDIF(NOT KWSYS_IN_SOURCE_BUILD)
# Select plugin module file name convention.
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e9282782e489a78de9c2896ee01fdd02ce8ca396
commit e9282782e489a78de9c2896ee01fdd02ce8ca396
Author: Iosif Neitzke <iosif.neitzke at gmail.com>
AuthorDate: Fri Oct 31 11:26:51 2014 -0500
Commit: Brad King <brad.king at kitware.com>
CommitDate: Fri Oct 31 13:19:33 2014 -0400
Help: Fix configure_file call to use COPYONLY, not COPY_ONLY
The configure_file signature has option 'COPYONLY' (no underscore).
Fix the example in 'cmake-packages.7.rst'.
diff --git a/Help/manual/cmake-packages.7.rst b/Help/manual/cmake-packages.7.rst
index c4cca6d..5d6201c 100644
--- a/Help/manual/cmake-packages.7.rst
+++ b/Help/manual/cmake-packages.7.rst
@@ -316,7 +316,7 @@ shared library:
)
configure_file(cmake/ClimbingStatsConfig.cmake
"${CMAKE_CURRENT_BINARY_DIR}/ClimbingStats/ClimbingStatsConfig.cmake"
- COPY_ONLY
+ COPYONLY
)
set(ConfigPackageLocation lib/cmake/ClimbingStats)
-----------------------------------------------------------------------
Summary of changes:
Help/manual/cmake-packages.7.rst | 2 +-
Modules/Qt4Macros.cmake | 2 +-
Source/cmConfigureFileCommand.cxx | 13 +++++++++++++
Source/kwsys/CMakeLists.txt | 2 +-
Tests/RunCMake/configure_file/RunCMakeTest.cmake | 1 +
Tests/RunCMake/configure_file/UnknownArg-stderr.txt | 10 ++++++++++
Tests/RunCMake/configure_file/UnknownArg.cmake | 2 ++
7 files changed, 29 insertions(+), 3 deletions(-)
create mode 100644 Tests/RunCMake/configure_file/UnknownArg-stderr.txt
create mode 100644 Tests/RunCMake/configure_file/UnknownArg.cmake
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list