Commit Graph

19414 Commits

Author SHA1 Message Date
Domen Vrankar ecd71c9c1a SystemTools: time operations on directories
On windows FILE_FLAG_BACKUP_SEMANTICS enables us to
read/write time both on files and directories.
2015-09-29 01:18:14 +02:00
Domen Vrankar 19c6f4eefc SystemTools: set time file permissions
On Windows if file permissions are read only
FILE_WRITE_ATTRIBUTES will enables us to
get file handle and change file time.
2015-09-29 01:18:10 +02:00
Raffi Enficiaud 749a140a0c CPackDeb: allow empty directories in component packages 2015-09-29 01:18:04 +02:00
Mike Pagel fa5284f07f VS: Prevent generated "rule" files from causing rebuilds
When we generate a ".rule" file to attach a custom command in a VS IDE
project, set the file timestamp to be old enough to prevent the rule
from re-running due to its timestamp.
2015-09-28 10:58:57 -04:00
Brad King 6c6a8c5d5a Merge topic 'minor-cleanups'
51e48637 VS: Remove impossible condition.
203eada6 cmMakefile: Remove Configured state.
5642449a cmCommand: Remove IsDiscouraged interface.
77c6a339 cmSetCommand: Re-use local named variable.
732f5511 cmSetCommand: Fix typo in comment.
8544f16d cmGlobalGenerator: Devirtualize method.
9096daaf Ninja: Remove unused variable.
2015-09-28 10:44:59 -04:00
Brad King bc92647b91 Merge topic 'update-kwsys'
946e8615 Merge branch 'upstream-kwsys' into update-kwsys
29ad0694 KWSys 2015-09-25 (dc4e4a55)
2015-09-28 10:44:52 -04:00
Brad King 5ed2292d3a Merge topic 'ninja-cleanup-path-conversion'
6e2a4087 Ninja: Centralize path conversion in global generator (#15757)
993d0641 Ninja: Fix OBJECT_DIR placeholder substitution in link rules
2015-09-28 10:44:48 -04:00
Brad King cfcd5e8518 Merge topic 'genex-SHELL_PATH'
ca6ba3fe Genex: Add a SHELL_PATH expression
7de868c4 Tests: Simplify GeneratorExpression check implementation
2015-09-28 10:44:43 -04:00
Stefan Kislinskiy ca6ba3fee5 Genex: Add a SHELL_PATH expression
Some commands on Windows do not understand forward slash paths and
require backslashes.  In order to help projects generate shell
invocations of such commands, provide a generator expression to convert
paths to the shell-preferred path format for the current generator.
This will allow custom commands to generate paths the same way CMake
does for compiler command invocations.
2015-09-28 10:37:33 -04:00
Kitware Robot 4480a9262d CMake Nightly Date Stamp 2015-09-28 00:01:04 -04:00
Stephen Kelly 51e4863782 VS: Remove impossible condition. 2015-09-27 12:09:33 +02:00
Stephen Kelly 203eada65e cmMakefile: Remove Configured state.
It is vestigial.
2015-09-27 12:08:07 +02:00
Stephen Kelly 5642449a69 cmCommand: Remove IsDiscouraged interface.
This used to affect documentation, but does not affect the Sphinx
documentation.
2015-09-27 12:08:07 +02:00
Stephen Kelly 77c6a339af cmSetCommand: Re-use local named variable. 2015-09-27 12:08:07 +02:00
Stephen Kelly 732f551187 cmSetCommand: Fix typo in comment. 2015-09-27 12:08:06 +02:00
Stephen Kelly 8544f16d1e cmGlobalGenerator: Devirtualize method. 2015-09-27 12:08:06 +02:00
Stephen Kelly 9096daaf5c Ninja: Remove unused variable. 2015-09-27 12:08:06 +02:00
Kitware Robot a100888b75 CMake Nightly Date Stamp 2015-09-27 00:01:05 -04:00
Stephen Kelly 1e83a963d8 QtAutogen: Split initializer methods into separate class. 2015-09-26 19:32:54 +02:00
Stephen Kelly 12f0e13c5f QtAutogen: Simplify generator initialization API. 2015-09-26 19:32:54 +02:00
Stephen Kelly 65ff75d3f5 QtAutogen: Remove unnecessary dereference. 2015-09-26 19:32:54 +02:00
Stephen Kelly 64b78c147f QtAutogen: Move Source initialization to prior loop.
Ensure that all targets have their _automoc.cpp before attempting
to initialize the autogen target.  The initialization evaluates
generator expressions for target sources, and must include the
_automoc.cpp of object library dependents in order for TARGET_OBJECTS
to include the object file for the corresponding _automoc.cpp file.
2015-09-26 19:32:53 +02:00
Stephen Kelly c3c20d3ce3 QtAutogen: Add _automoc.cpp sources before initializing. 2015-09-26 19:32:53 +02:00
Stephen Kelly 8b6ec29d40 QtAutogen: Move initialization condition to caller. 2015-09-26 19:32:53 +02:00
Stephen Kelly 9470b056fc QtAutogen: Move condition to prior loop. 2015-09-26 19:32:53 +02:00
Stephen Kelly b7491b1cda QtAutogen: Move condition to prior loop. 2015-09-26 19:32:52 +02:00
Stephen Kelly e791c85419 QtAutogen: Make some methods static. 2015-09-26 19:32:52 +02:00
Stephen Kelly 6210ec644a QtAutogen: Make internal method private. 2015-09-26 19:32:52 +02:00
Stephen Kelly a3ceb998d7 QtAutogen: Don't use members to initialize automoc targets. 2015-09-26 19:32:50 +02:00
Stephen Kelly dced2fe10f QtAutogen: Rename variable. 2015-09-26 19:21:49 +02:00
Stephen Kelly f9a77e76e4 QtAutogen: Don't use a member to store skipped uic files. 2015-09-26 18:48:23 +02:00
Stephen Kelly c3633e7a41 QtAutogen: Add missing includes and forward declarations. 2015-09-26 18:48:23 +02:00
Brad King 946e861519 Merge branch 'upstream-kwsys' into update-kwsys 2015-09-26 10:42:35 -04:00
Brad King 64b7baac4a Merge topic 'revert-cpack-package-empty-dirs'
4fa17553 Revert topic 'cpack-package-empty-dirs'
2015-09-26 10:40:40 -04:00
Kitware Robot 1ec54fff11 CMake Nightly Date Stamp 2015-09-26 00:01:07 -04:00
Brad King 414cc18a9a Merge topic 'revert-cmake-W-options'
2e606306 Merge branch 'improve-variable-help-formatting' into revert-cmake-W-options
81739e92 Revert topic 'cmake-W-options' (#15747)
2015-09-25 16:16:17 -04:00
Brad King da7276cf94 Replace http://www.cmake.org URLs with https://cmake.org
The latter is now the preferred URL for visiting cmake.org with a
browser.  Convert using the shell code:

 git ls-files -z | xargs -0 sed -i 's|http://www\.cmake|https://cmake|g'
2015-09-25 15:47:39 -04:00
Brad King 6e2a4087f2 Ninja: Centralize path conversion in global generator (#15757)
In the Ninja generator we run all build rules from the top of the build
tree rather than changing into each subdirectory.  Therefore we convert
all paths relative to the HOME_OUTPUT directory.  However, the Convert
method on cmLocalGenerator restricts relative path conversions to avoid
leaving the build tree with a "../" sequence.  Therefore conversions
performed for "subdirectories" that are outside the top of the build
tree always use full paths while conversions performed for
subdirectories that are inside the top of the build tree may use
relative paths to refer to the same files.

Since Ninja always runs rules from the top of the build tree we should
convert them using only the top-level cmLocalGenerator in order to
remain consistent.  Also extend the test suite with a case that fails
without this fix.
2015-09-25 14:36:30 -04:00
Brad King 993d064197 Ninja: Fix OBJECT_DIR placeholder substitution in link rules
Convert the OBJECT_DIR value to the shell output format so that
it is properly quoted when the path contains spaces.
2015-09-25 14:36:30 -04:00
Brad King 4fa1755315 Revert topic 'cpack-package-empty-dirs'
The changes in commit 47b060ae (CPackDeb: allow empty directories in
component packages, 2015-09-21), commit b58de9fe (CPack: allow packaging
of empty directories, 2015-09-21), and commit b761e90d (CPack: remove
accidental changes, 2015-09-22) regressed packaging of CMake itself.
Revert the changes until they can be revised and rebased on other
changes that make additional fixes.
2015-09-25 11:55:59 -04:00
Brad King 02f95f9b7c Merge topic 'fix-try_compile-internal-argv'
710bde43 cmCoreTryCompile: Fix internal argument vector construction
2015-09-25 10:12:42 -04:00
Brad King 5a83303f50 Merge topic 'install-directory-dest-genex'
bd189cc2 install: Allow generator expressions in DIRECTORY DESTINATION
2015-09-25 10:12:40 -04:00
Brad King ede54544f1 Merge topic 'fix-max-path-initialization'
8bfff686 cmLocalGenerator: Compute object max path on construction.
2c2479fb cmGlobalGenerator: Create all local generators after Configure().
194bb068 cmGlobalGenerator: Remove unused method.
c5f07e05 cmGlobalGenerator: Create local generators after all makefiles configured.
dd408de4 cmGlobalGenerator: Create local generator after configuring the makefile.
8a88089b cmMakefile: Create the local generator after configuring the makefile.
934aa454 Makefiles: Remove need to create local generator at configure time.
61b48e70 Makefiles: Port to cmOutputConverter.
2015-09-25 10:12:35 -04:00
Kitware Robot 7c0b22a84e CMake Nightly Date Stamp 2015-09-25 00:01:06 -04:00
Brad King 710bde43aa cmCoreTryCompile: Fix internal argument vector construction
In TryCompileCode we construct an internal argv[] vector that needs to
have a fake argv[0] so our internal cmake command line looks like a real
command line.  Fix construction of the fake argv[0] when try_compile is
called without the CMAKE_FLAGS argument.  Otherwise the first internal
-DVAR=val argument that we use to pass information like
CMAKE_OSX_SYSROOT is ignored.
2015-09-24 15:26:32 -04:00
Brad King cbfae8c3f2 Merge topic 'install-files-dest-genex'
69ab5f55 Tests: Cover install(FILES) with a genex DESTINATION
17aa6fd3 install: Allow generator expressions in FILES DESTINATION
2015-09-24 10:28:54 -04:00
Robert Goulet bd189cc24e install: Allow generator expressions in DIRECTORY DESTINATION 2015-09-24 09:13:03 -04:00
Stephen Kelly 8bfff68642 cmLocalGenerator: Compute object max path on construction. 2015-09-24 09:39:39 +02:00
Stephen Kelly 2c2479fbed cmGlobalGenerator: Create all local generators after Configure(). 2015-09-24 09:39:39 +02:00
Stephen Kelly 194bb06803 cmGlobalGenerator: Remove unused method. 2015-09-24 09:39:39 +02:00
Stephen Kelly c5f07e0537 cmGlobalGenerator: Create local generators after all makefiles configured. 2015-09-24 09:39:38 +02:00
Stephen Kelly dd408de46b cmGlobalGenerator: Create local generator after configuring the makefile. 2015-09-24 09:39:38 +02:00
Stephen Kelly 8a88089bbe cmMakefile: Create the local generator after configuring the makefile.
The local generator is not used during configure time.
2015-09-24 09:39:38 +02:00
Stephen Kelly 934aa454d0 Makefiles: Remove need to create local generator at configure time.
This method is used during try_compile.
2015-09-24 09:39:38 +02:00
Stephen Kelly 61b48e70bc Makefiles: Port to cmOutputConverter. 2015-09-24 09:39:38 +02:00
Kitware Robot 02ccef2ae5 CMake Nightly Date Stamp 2015-09-24 00:01:05 -04:00
Robert Goulet 17aa6fd362 install: Allow generator expressions in FILES DESTINATION 2015-09-23 14:37:17 -04:00
Brad King c3b3284c93 Merge topic 'vs-target-ordering'
40c7b461 VS: Fix rebuild with regeneration after input CMake code change (#15754)
03bfe71a VS: Refactor target ordering logic
2015-09-23 09:23:01 -04:00
Brad King 3779716616 Merge topic 'cpack-package-empty-dirs'
b761e90d CPack: remove accidental changes
2015-09-23 09:22:59 -04:00
Domen Vrankar b761e90d70 CPack: remove accidental changes
Remove changes accidentally included in commit b58de9fe (CPack: allow
packaging of empty directories, 2015-09-22).
2015-09-23 09:15:57 -04:00
Kitware Robot 44f2ade2cb CMake Nightly Date Stamp 2015-09-23 00:01:05 -04:00
Brad King 2e6063068c Merge branch 'improve-variable-help-formatting' into revert-cmake-W-options
Resolve conflicts in

 Help/variable/CMAKE_ERROR_DEPRECATED.rst
 Help/variable/CMAKE_WARN_DEPRECATED.rst

by integrating changes from both sides.
2015-09-22 13:57:08 -04:00
Brad King 81739e9215 Revert topic 'cmake-W-options' (#15747)
The changes in commit c96fe0b4 (cmake: Add -W options to control
deprecation warnings and errors, 2015-07-28) fail to account for
-Wdev warnings produced by places in CMake other than message().
This causes a regression in which -Wno-dev fails to suppress such
warnings.  Revert the feature until it can be revised accordingly.
2015-09-22 13:53:09 -04:00
Brad King 442d17ef6c Merge topic 'cpack-package-empty-dirs'
b58de9fe CPack: allow packaging of empty directories
47b060ae CPackDeb: allow empty directories in component packages
2015-09-22 10:47:11 -04:00
Brad King da7c8a8dae Merge topic 'restrict-shlib-link-flags-to-enable-exports'
b15f4e9b try_compile: Propogate CMP0065 to the generated project.
9784af1b CMP0065: Restrict the use of CMAKE_SHARED_LIBRARY_LINK_<LANG>_FLAGS
2015-09-22 10:46:59 -04:00
Brad King 4be709a6b7 Merge topic 'fix-policy-CMP0064-version'
402bf096 CMP0064: Fix recorded version of introduction to be 3.4
2015-09-22 10:46:57 -04:00
Brad King f1365f3206 Merge topic 'fix-windows-version-detection'
17009189 Windows: Fix CMAKE_HOST_SYSTEM_VERSION on Windows >= 8 (#15674)
2015-09-22 10:46:54 -04:00
Brad King 40c7b46123 VS: Fix rebuild with regeneration after input CMake code change (#15754)
When using "cmake --build ." or "MSBuild ALL_BUILD.vcxproj" to drive the
build the dependencies in the .sln file are not considered.  This means
that ProjectReference elements in .vcxproj files are used to order
targets.  We must ensure that the ZERO_CHECK target is listed as the
first dependency of every target so that when it causes regeneration of
the build files then MSBuild has not yet loaded the updated files.
2015-09-22 10:26:00 -04:00
Brad King 03bfe71ae0 VS: Refactor target ordering logic
Refactor cmGlobalVisualStudioGenerator::TargetCompare to store the name of
the target that should come first instead of hard-coding "ALL_BUILD".
Update client sites to specify "ALL_BUILD" when ordering for .sln files
and an empty string otherwise (in cases when "ALL_BUILD" should not be
encountered anyway).
2015-09-22 10:25:58 -04:00
Kitware Robot dce7d8befb CMake Nightly Date Stamp 2015-09-22 00:01:04 -04:00
Domen Vrankar b58de9fe2b CPack: allow packaging of empty directories 2015-09-22 02:08:26 +02:00
Raffi Enficiaud 47b060aee0 CPackDeb: allow empty directories in component packages 2015-09-22 01:57:44 +02:00
Chuck Atkins b15f4e9b86 try_compile: Propogate CMP0065 to the generated project.
Set policy CMP0065 to the value used in the calling project.

Set the the value of CMAKE_ENABLE_EXPORTS if set in the calling
project to initialize the target property appropriately.
2015-09-21 10:12:13 -04:00
Chuck Atkins 9784af1b50 CMP0065: Restrict the use of CMAKE_SHARED_LIBRARY_LINK_<LANG>_FLAGS
This new policy restricts the addition of the shared library link flags
to executables only when the ENABLE_EXPORTS property is set to True.
2015-09-21 10:12:13 -04:00
Brad King 402bf096ec CMP0064: Fix recorded version of introduction to be 3.4
This policy was added for CMake 3.4 but accidentally recorded as 3.3.
Fix this and update the RunCMake.CMP0064 test WARN case accordingly.
2015-09-21 10:05:02 -04:00
Brad King 38830fc0ca Merge topic 'cpack-deb-checksum-on-symlinks'
da295f45 CPack/Deb: checksum on symlinks release notes
7c7874c8 CPackDeb: preventing md5sum on symlinks
2015-09-21 09:25:31 -04:00
Brad King dd8285c688 Merge topic 'fix-compatibility-mode-LOCATION'
2514e426 CMP0026: Use compatibility codepath until configure is finished (#15748)
b98f7712 cmGlobalGenerator: Add API for the configure step being finished.
b5de2bd9 cmLocalGenerator: Simplify condition.
2015-09-21 09:25:29 -04:00
Brad King 4f640afc1a Merge topic 'ninja-refactor-msvc-deps'
109a7a24 Ninja: Detect MSVC /showIncludes prefix with compiler flags (#15596)
828c05b9 Ninja: Refactor lookup of cmcldeps location
c73fbda6 CMakeDetermineCompilerId: Drop unused code path
2015-09-21 09:25:27 -04:00
Brad King 82a0c7be3f Merge topic 'ctest-custom-output-size'
fd47df45 CTest: Add options to limit output of passed and failed tests
6e3151f6 CTest: Document and test custom output size settings
2015-09-21 09:25:24 -04:00
Gilles Khouzam 17009189f8 Windows: Fix CMAKE_HOST_SYSTEM_VERSION on Windows >= 8 (#15674)
According to GetVersionEx documentation:

 https://msdn.microsoft.com/en-us/library/windows/desktop/ms724451.aspx
 https://msdn.microsoft.com/en-us/library/windows/desktop/dn481241.aspx

we must manifest each application to explicitly declare support for each
version of Windows.
2015-09-21 09:02:41 -04:00
Kitware Robot 358b564145 CMake Nightly Date Stamp 2015-09-21 00:01:04 -04:00
Kitware Robot ba7f7067ca CMake Nightly Date Stamp 2015-09-20 00:01:05 -04:00
Kitware Robot 0da7a4d4c7 CMake Nightly Date Stamp 2015-09-19 00:01:05 -04:00
Raffi Enficiaud 7c7874c86e CPackDeb: preventing md5sum on symlinks
- Direct call to cmSystemTools::ComputeFileMD5
- Avoiding hashing symlinks
- Tests
2015-09-18 22:20:42 +02:00
Stephen Kelly 2514e4265c CMP0026: Use compatibility codepath until configure is finished (#15748)
Use it instead of the similar cmMakefile API.  It is necessary to
know that the Configure step is completely done, not just that one
particular cmMakefile is finished configuring.

Prior to commit 611220f7 (cmTarget: Use reliable test for CMP0024 and CMP0026
OLD., 2015-07-25), this was determined by checking whether cmGeneratorTargets
exist yet, which happens after the Configure step.
2015-09-18 20:49:00 +02:00
Stephen Kelly b98f7712ea cmGlobalGenerator: Add API for the configure step being finished. 2015-09-18 20:48:15 +02:00
Stephen Kelly b5de2bd9de cmLocalGenerator: Simplify condition.
This API is only called after configure-time.
2015-09-18 19:41:47 +02:00
Roman Wüger fd47df4503 CTest: Add options to limit output of passed and failed tests
Add ctest command-line options:

  --test-output-size-passed <n>
  --test-output-size-failed <n>

to set the amount of test output to store in Test.xml as a command-line
dashboard client.
2015-09-18 11:32:06 -04:00
Brad King 828c05b9f5 Ninja: Refactor lookup of cmcldeps location
This executable comes with CMake so just compute its location in
cmSystemTools instead of storing it in compiler information modules.
2015-09-18 10:01:25 -04:00
Brad King 2b3aad83f2 Merge topic 'cmake-gui-qt5-package'
851915a5 cmake-gui:  Improve packaging of Qt5 libraries.
2015-09-18 09:56:41 -04:00
Brad King 309026147a Merge topic 'ms-manifest-files'
e134e53b Add support for *.manifest source files with MSVC tools
da00be63 MSVC: Rewrite manifest file handling with Makefile and Ninja
d488b5c9 Ninja: Always add OBJECT_DIR variable to link rules
6d620f5a VS: Add manifest tool settings to VS 8 and 9 project files
2015-09-18 09:56:39 -04:00
Kitware Robot 9c7bb9f103 CMake Nightly Date Stamp 2015-09-18 00:01:06 -04:00
Brad King eb154697c0 Merge topic 'cpack-deb-fakeroot-removal'
becb14c9 CPack/DEB: test preserve extra config file permissions
7044e8ee CPackDeb: use of libarchive and removal of fakeroot
415405a3 cmArchiveWrite: control user/group, permissions and recursive file adding
4f2ff601 Tests: Make RunCMake.CPack error messages more readable
81b748ae cmGeneratedFileStream: Fix spelling in comment
2015-09-17 15:34:02 -04:00
Raffi Enficiaud 7044e8ee4b CPackDeb: use of libarchive and removal of fakeroot 2015-09-17 15:30:39 -04:00
Raffi Enficiaud 415405a308 cmArchiveWrite: control user/group, permissions and recursive file adding 2015-09-17 15:30:38 -04:00
Raffi Enficiaud 81b748ae1d cmGeneratedFileStream: Fix spelling in comment
s/destionation/destination/
2015-09-17 15:30:07 -04:00
Clinton Stimpson 851915a58c cmake-gui: Improve packaging of Qt5 libraries.
Fixes #15685, where the right Qt5 dlls on Windows were not packaged because
they were not found when relying on the PATH environment variable.

Also some cleanup of code introduced in 8120e13f, but no longer needed with 678aaad1.
2015-09-17 08:32:51 -06:00
Brad King e134e53b47 Add support for *.manifest source files with MSVC tools
Classify .manifest sources separately, add dependencies on them, and
pass them to the MS manifest tool to merge with linker-generated
manifest files.

Inspired-by: Gilles Khouzam <gillesk@microsoft.com>
2015-09-17 10:21:32 -04:00
Brad King da00be6359 MSVC: Rewrite manifest file handling with Makefile and Ninja
Add a helper class private to "cmcmd.cxx" to contain the implementation.
Update the link logic to use the intermediate files directory for each
target to hold manifest and resource files before embedding into the
binary.  Preserve the old behavior of placing the .manifest file next
to the binary when not linking incrementally even though it will be
embedded.
2015-09-17 10:21:32 -04:00
Brad King d488b5c976 Ninja: Always add OBJECT_DIR variable to link rules
The <OBJECT_DIR> placeholder is always available in Makefile
generators so make it available from the Ninja generator too.
2015-09-17 10:21:32 -04:00