summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix Module.ExternalData test on VS 6Brad King2013-02-041-0/+1
| | | | | | | | Run the test with the ctest --build-noclean option. The test CMakeLists.txt file already uses file(REMOVE_RECURSE) to clean out downloaded data anyway. Some file removed by "msdev ... /clean" causes CMake to re-run in the middle of the build step and file(REMOVE_RECURSE) wipes out already-generated files.
* Fix Module.ExternalData test on CygwinBrad King2013-02-041-1/+5
| | | | | In ExternalData_URL_TEMPLATES add a leading slash to the path after file:// only if the path does not already start with one.
* Merge branch 'fix-atomic-rename-on-Windows' into add-ExternalData-moduleBrad King2013-02-041-31/+20
|\
| * Fix cmSystemTools::RenameFile race on WindowsBrad King2013-02-041-31/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit d46d8df0 (Re-implemented cmGeneratedFileStream to look like a real stream and replace the destination file atomically, 2004-11-03) our RenameFile implementation tries to deal with MoveFile not replacing read-only files. In order to avoid the Get/SetFileAttributes pair we used stat to test for existence of the destination file. This has a race in which the destination could be created between the test for existence and the MoveFile call. Remove the stat call and use GetFileAttributes to detect whether the file exists. This shortens the race but does not eliminate it. Use a loop to try multiple times in case we lose the race. While at it, drop Win9x support and always use MoveFileEx.
* | ExternalData: Collapse ../ components in DATA{} pathsBrad King2013-01-306-6/+23
| | | | | | | | | | Relative path components need to be normalized out even if they appear in the middle of a caller-supplied string.
* | ExternalData: Add support for SHA 1 and 2 hash algorithmsBrad King2013-01-3017-2/+51
| | | | | | | | | | Update the Module.ExternalData and RunCMake.ExternalData tests to cover some of them.
* | ExternalData: Generalize hash algo/ext handlingBrad King2013-01-301-11/+9
| | | | | | | | | | | | | | Use private global variables _ExternalData_REGEX_(ALGO|EXT) to match the possible hash algorithm names and extensions in regular expressions. Use "file(<algo>)" instead of "cmake -E md5sum" to compute hashes without a child process and to support more hash algorithms.
* | ExternalData: Allow DATA{} syntax to reference directoriesBrad King2013-01-3015-9/+86
| | | | | | | | | | | | | | Use a trailing slash to reference a directory. Require that a list of associated files be specified to select from within the directory. One may simply use DATA{Dir/,REGEX:.*} to reference all files but get a directory passed on the command line.
* | ExternalData: Allow ()-groups in series match regexBrad King2013-01-302-6/+9
| | | | | | | | | | | | | | Refactor use of the ExternalData_SERIES_MATCH value to avoid assuming that it has no ()-groups that interfere with group indexing. Extend the Module.ExternalData test to cover this case.
* | ExternalData: Add tests covering interfaces and errorsBrad King2013-01-30123-0/+554
| | | | | | | | | | | | | | | | Add a Module.ExternalData test to verify data retrieval and test argument DATA{} references. Add a RunCMake.ExternalData test to verify error handling and automatic transformation of a raw data to a content link and staged object.
* | ExternalData: Improve series matching using an explicit syntaxBrad King2013-01-291-27/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Automatic series recognition can generate false positives too easily when the default series configuration is flexible enough to handle common cases. Avoid false positives by requiring an explicit syntax to activate series recognition. Choose the syntax DATA{<name>,:} to be short, simple, and look like a vertical ellipsis. This allows us to improve the default series match configuration. Allow series references to contain one of the numbered file names. Allow '-' as a separator in addition to '.' and '_'. Document what the default configuration matches. Also provide more options to configure series <name> parsing.
* | ExternalData: Remove unused private interfaceBrad King2013-01-281-10/+0
| | | | | | | | | | The 'store' action was part of an older design and is no longer needed. Remove it.
* | ExternalData: Cleanup stray TODO and typo in commentsBrad King2013-01-281-2/+1
| | | | | | | | | | Remove an outdated TODO line left from earlier designs. Also fix a typo.
* | ExternalData: Do not match directory names when resolving DATA{}Brad King2013-01-281-2/+9
| | | | | | | | | | | | Our content link and object download infrastructure supports only blobs (files), not trees (directories). Do not allow references to end in a slash.
* | ExternalData: Remove compatibility with CMake < 2.8.5Brad King2013-01-241-17/+6
| | | | | | | | | | Now that the module comes in a sufficiently new CMake it does not need to support older versions.
* | Add ExternalData moduleBrad King2013-01-242-0/+714
|/ | | | | | | | | | Take files we previously distributed in ITK 4.3.1: CMake/ExternalData.cmake CMake/ExternalData_config.cmake.in and add them for distribution in upstream CMake. Update the copyright notice block format to follow CMake conventions.
* Merge topic 'fix-COMPATIBLE_INTERFACE-link-libraries'Brad King2013-01-245-3/+48
|\ | | | | | | | | 6fbe3ce Exclude the LINK_LIBRARIES related properties from INTERFACE evaluation.
| * Exclude the LINK_LIBRARIES related properties from INTERFACE evaluation.Stephen Kelly2013-01-245-3/+48
| | | | | | | | | | | | These interface-related link-libraries properties are used to determine the value of the other INTERFACE properties, so we were getting infinite recursion and segfaults otherwise.
* | Merge topic 'cmMakefile-comment-typos'Brad King2013-01-241-3/+3
|\ \ | | | | | | | | | | | | 3853a6c spell: fix a few typos in comments
| * | spell: fix a few typos in commentsYury G. Kudryashov2013-01-231-3/+3
| | |
* | | CMake Nightly Date StampKitware Robot2013-01-241-1/+1
| |/ |/|
* | Merge topic 'disallow-IMPORTED-interface-porcelain'Brad King2013-01-2312-61/+15
|\ \ | | | | | | | | | | | | | | | b98d14d Disallow porcelain to populate includes and defines of IMPORTED targets. 48a4cf2 Revert "Allow target_link_libraries with IMPORTED targets."
| * | Disallow porcelain to populate includes and defines of IMPORTED targets.Stephen Kelly2013-01-2110-44/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With similar reasoning to the parent commit, as downstreams, we can't determine what $<CONFIG> generator expressions would be appropriate. Upstream would have populated the INTERFACE_INCLUDE_DIRECTORIES with config-specific generator expressions, possibly appropriate for their DEBUG_CONFIGURATIONS. In theory, if we would add include directories for a DEBUG intent, we would have to match the upstream configurations for that. Rather than attempting to discover the appropriate configurations at this time, simplify the feature instead. The use of IMPORTED targets with these commands could still be added in the future if targets would export their DEBUG_CONFIGURATIONS somehow.
| * | Revert "Allow target_link_libraries with IMPORTED targets."Stephen Kelly2013-01-212-17/+0
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 9cfe4f1b769597bd9ba179eba46572a9df27f64c. It turns out that correctly adding the content to the IMPORTED_LINK_INTERFACE_LIBARIES_<CONFIG> of an upstream target from the buildsystem of a downstream project is not simple. If upstream had added the INTERFACE content, the config-specific properties would be determined by the DEBUG_CONFIGURATIONS of upstream. As downstream, we don't have any information about what the DEBUG_CONFIGURATIONS of upstream were, so we can't determine which configuration-specific properties to populate. The best we can do is add it to all of them or add it to the ones downstream considers to be DEBUG_CONFIGURATIONS, neither of which is a good solution. So, removing the porcelain API for that is the best approach. A human can still determine which properties to populate and use the set_property API to populate the desired properies. Another solution to this would be for upstream targets to publish what they consider DEBUG_CONFIGURATIONS, but that can be added in a future release.
* | Merge topic 'clean-include-dirs-debugging'Brad King2013-01-2310-63/+122
|\ \ | | | | | | | | | | | | | | | | | | | | | 6063fef Output include directories as LOG messages, not warnings. aa66748 Specify the target whose includes are being listed. d70204a Only output includes once after the start of 'generate-time' when debugging. 0d46e9a Store includes from the same include_directories call together.
| * | Output include directories as LOG messages, not warnings.Stephen Kelly2013-01-212-4/+8
| | |
| * | Specify the target whose includes are being listed.Stephen Kelly2013-01-212-6/+6
| | |
| * | Only output includes once after the start of 'generate-time' when debugging.Stephen Kelly2013-01-215-1/+17
| | | | | | | | | | | | | | | | | | During configure-time, GetIncludeDirectories may be called too, for example if using the export() command. As the content can be different, it should be output each time then.
| * | Store includes from the same include_directories call together.Stephen Kelly2013-01-216-52/+91
| | | | | | | | | | | | | | | | | | Otherwise, we get a separate IncludeDirectoriesEntry for each include, and that causes unnecessary and confusing splitting in the output when debugging the INCLUDE_DIRECTORIES property.
* | | Merge topic 'export-new-style-files'Brad King2013-01-232-72/+72
|\ \ \ | | | | | | | | | | | | | | | | 02d4e53 Generate new-style cmake code during export.
| * | | Generate new-style cmake code during export.Stephen Kelly2013-01-202-72/+72
| | | | | | | | | | | | | | | | Use empty end*() commands and lowercase commands.
* | | | Merge topic 'fix-LINK_LIBRARIES-population'Brad King2013-01-231-2/+3
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | d7f1520 Don't wrap all targets in LINK_LIBRARIES in a TARGET_NAME genex.
| * | | | Don't wrap all targets in LINK_LIBRARIES in a TARGET_NAME genex.Stephen Kelly2013-01-201-2/+3
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is not necessary and the current state is unintentional. Before this patch, target_link_libraries(foo bar) causes the LINK_LIBRARIES property of foo to contain $<TARGET_NAME:bar> instead of just bar
* | | | Merge topic 'qt4-autolink-qtmain'Brad King2013-01-2323-4/+284
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | e3b5eb6 Automatically link to the qtmain library when linking to QtCore. 6c8d8af Add the $<TARGET_POLICY> expression
| * | | | Automatically link to the qtmain library when linking to QtCore.Stephen Kelly2013-01-238-6/+122
| | | | | | | | | | | | | | | | | | | | | | | | | When using QAxServer, ensure that the qtmain library is excluded by reporting an error at CMake time if it is not.
| * | | | Add the $<TARGET_POLICY> expressionStephen Kelly2013-01-1716-0/+164
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This new expression allows checking how a policy was set when a target was created. That information is only recorded for a subset of policies, so a whitelist is used.
* | | | | Merge topic 'fix-COMPATIBLE_INTERFACE-properties'Brad King2013-01-2332-5/+325
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 830246e Export the COMPATIBLE_INTERFACE_BOOL content properties bd82bb4 Clear the link information in ClearLinkMaps. e987991 Make INTERFACE determined properties readable in generator expressions. d9afacc Exit early if we find an inconsistent property. 1800f70 Populate the link information cache before checking dependent properties.
| * | | | | Export the COMPATIBLE_INTERFACE_BOOL content propertiesStephen Kelly2013-01-217-0/+93
| | | | | |
| * | | | | Clear the link information in ClearLinkMaps.Stephen Kelly2013-01-211-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The cache here needs to be cleared if GetLinkInformation is called at configure-time, such as during an export(). The next commit does exactly that, and without this patch, the LinkLanguage test would fail.
| * | | | | Make INTERFACE determined properties readable in generator expressions.Stephen Kelly2013-01-2027-1/+218
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The properties are evaluated as link-dependent interface properties when evaluating the generator expressions.
| * | | | | Exit early if we find an inconsistent property.Stephen Kelly2013-01-181-0/+3
| |/ / / / | | | | | | | | | | | | | | | Further messages about inconsistency are distracting.
| * | | | Populate the link information cache before checking dependent properties.Stephen Kelly2013-01-161-4/+4
| | | | | | | | | | | | | | | | | | | | The dependent properties check can require the link information.
* | | | | Merge topic 'xcode-duplicate-flags-13354'Brad King2013-01-231-5/+10
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | f447db7 XCode generator won't infinitely parse compiler flags (bug #13354).
| * | | | | XCode generator won't infinitely parse compiler flags (bug #13354).Robert Maynard2013-01-181-5/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When parsing the compiler flag list we reduce the search space on each iteration to be the subset of the string we hadn't searched before.
* | | | | | Merge topic 'fix-target_include_directories-genex'Brad King2013-01-232-1/+18
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 24dcf0c Make sure generator expressions can be used with target_include_directories.
| * | | | | | Make sure generator expressions can be used with target_include_directories.Stephen Kelly2013-01-162-1/+18
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | Handle the case that a generator expression is used before treating a non-target as an error.
* | | | | | Merge topic 'vs11-external-include'Brad King2013-01-232-0/+2
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | bc65b74 VS11: Fix VSExternalInclude test
| * | | | | | VS11: Fix VSExternalInclude testBrad King2013-01-162-0/+2
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set CMAKE_SUPPRESS_REGENERATION in the Lib1 and Lib2 projects so that their .vcxproj files do not contain references to ZERO_CHECK. Such references do not make sense when using the files in another .sln file. This does not reduce the effectiveness of the test because real projects that use include_external_msproject will have their own .vcxproj files not generated by CMake anyway.
* | | | | | Merge topic 'ExternalProject-DEPENDS-target'Brad King2013-01-232-3/+8
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | c0f1af9 ExternalProject: Allow DEPENDS on normal targets (#13849)
| * | | | | | ExternalProject: Allow DEPENDS on normal targets (#13849)Brad King2013-01-162-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ExternalProject_Add DEPENDS option adds two types of dependencies. It adds a target-level build order dependency between the external project target and the named targets. It also adds a file-level dependency on the "done" stamp file of the named external project targets. Targets not created by ExternalProject_Add have no such stamp file and no _EP_STAMP_DIR property. Prior to commit d14c0243 (Refactor repeated code into function, 2012-04-26) we unconditionally accepted an empty stamp dir and generated a dependency on a non-existent file. After that commit we generate an error that no stamp dir is set. Skip the file-level dependency when the named dependency is not an external project target in order to allow this use case. Teach the ExternalProject test to cover the case.