summaryrefslogtreecommitdiffstats
path: root/Tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'fix-static-private-non-target-depends' into releaseBrad King2016-02-175-0/+17
|\
| * Fix export of STATIC library PRIVATE non-target dependenciesBrad King2016-02-175-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit v3.5.0-rc1~43^2 (Fix export of STATIC library PRIVATE dependencies with CMP0022 NEW, 2016-01-15) we taught target_link_libraries to generate `$<LINK_ONLY:$<TARGET_NAME:dep>>` in INTERFACE_LINK_LIBRARIES instead of `$<LINK_ONLY:dep>` so that `dep` can be recognized as a target name and updated during export. However, this approach does not work when `dep` is just a plain library name and not a target because `$<TARGET_NAME:...>` requires the name of a reachable target. Since we do not know during target_link_libraries whether the name will correspond to a reachable target or not, we cannot inject the `$<TARGET_NAME:...>` expression. Revert this change and solve the original problem instead by teaching the export logic to recognize and update target names directly in `$<LINK_ONLY:...>` expressions. Reported-by: Ben Boeckel <ben.boeckel@kitware.com>
* | Merge branch 'fix-cmake_parse_arguments-expansion' into releaseBrad King2016-02-121-0/+19
|\ \
| * | cmake_parse_arguments: Restore ;-list argument flatteningDimitar Yordanov2016-02-121-0/+19
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The re-implementation in commit v3.5.0-rc1~116^2~1 (CMakeParseArguments: replace by native cmake_parse_arguments command, 2015-12-05) introduced a regression when parsing the ARGN arguments with cmake_parse_arguments. The original implementation used foreach(currentArg ${ARGN}) to iterate over input arguments. This flattened ;-lists within the arguments whether they were quoted or not. Fix our new implementation to preserve this behavior and add a test case to cover it. Signed-off-by: Dimitar Yordanov <dimitar.yordanov@sap.com> Signed-off-by: Matthias Maennich <matthias.maennich@sap.com>
* | Merge branch 'fix-install-EXPORT-crash' into releaseBrad King2016-02-087-3/+14
|\ \
| * | Tests: Avoid OS X 10.5 limitation warning in RunCMake.install testBrad King2016-02-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The EXPORT-OldIFace test case uses install(TARGETS) and so generates a warning: CMake Warning in CMakeLists.txt: WARNING: Target "foo" has runtime paths which cannot be changed during install. To change runtime paths, OS X version 10.6 or newer is required. Therefore, runtime paths will not be changed when installing. CMAKE_BUILD_WITH_INSTALL_RPATH may be used to work around this limitation. Set CMAKE_BUILD_WITH_INSTALL_RPATH to avoid the warning since we do not need to run the binaries from the build tree anyway.
| * | install(EXPORT): Fix crash on target in another directoryBrad King2016-02-053-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactoring merged by commit v3.5.0-rc1~299 (Merge topic 'use-generator-target', 2015-10-20) in and around commit v3.5.0-rc1~299^2~13 (cmExportSet: Store a cmGeneratorTarget, 2015-10-17) changed export sets to delay looking up actual targets and stores only their names. However, in InstallCommand::HandleExportMode we need to lookup targets immediately to check them for EXPORT_LINK_INTERFACE_LIBRARIES. The check was accidentally made local to the current directory, so if an export set contains a target from another directory the lookup fails and CMake crashes. Fix the check to look up the target name globally, and tolerate when no target is found just in case. Reported-by: Kelly Thompson <kgt@lanl.gov>
| * | Tests: Use newer policy settings in RunCMake.install testBrad King2016-02-054-3/+4
| |/ | | | | | | In particular, avoid CMP0042 warnings on OS X.
* | Merge branch 'test-ctest_submit-update' into releaseBrad King2016-02-084-4/+4
|\ \
| * | Tests: Extend ctest_submit host lookup failure matching (#15958)Orion Poplawski2016-02-084-4/+4
| |/ | | | | | | | | | | | | Match this message: Could not resolve host: -no-site-; Name or service not known ^^^^^^^^^^^^^^^^^^^^^^^^^^^
* | Fix dependency scanning configuration in subdirectoriesBrad King2016-02-055-1/+7
|/ | | | | | | | | | | | | | | Refactoring in commit v3.5.0-rc1~347^2~2 (Set the current dirs on the snapshot before creating the cmMakefile) accidentally changed the source and binary directories configured in `cmake -E cmake_depends` for use during dependency scanning. This can cause the wrong directory information to be loaded. It also breaks Fortran module dependency scanning for modules provided by targets in subdirectories that do not have Fortran_MODULE_DIRECTORY set. Fix the dependency scanning directory configuration and add a test to cover the Fortran module case in which the breakage was observed. Reported-by: Kelly Thompson <kgt@lanl.gov>
* Merge topic 'fix-CMAKE_MATCH-self-match'Brad King2016-02-022-0/+6
|\ | | | | | | | | 6ffc4323 cmConditionEvaluator: Fix matching of `CMAKE_MATCH_*` values (#15944)
| * cmConditionEvaluator: Fix matching of `CMAKE_MATCH_*` values (#15944)Brad King2016-02-012-0/+6
| | | | | | | | | | | | | | | | | | | | | | While evaluating `if(MATCHES)` we get a `const char*` pointer to the string to be matched. On code like if(CMAKE_MATCH_COUNT MATCHES "Y") the string to be matched may be owned by our own result variables. We must move the value to our own buffer before clearing them. Otherwise we risk reading freed storage.
* | add_custom_command: Clarify error when TARGET is out of scope (#15681)Brad King2016-01-2810-2/+19
|/ | | | | | | | The add_custom_command(TARGET) signature only works for targets defined in the current directory. Clarify this in the error message when the target exists but was defined elsewhere. Inspired-by: Bartosz Kosiorek <gang65@poczta.onet.pl>
* Merge topic 'test-fltk_wrap_ui'Brad King2016-01-223-4/+7
|\ | | | | | | | | f98ae28e Tests: Cover fltk_wrap_ui on an executable that links libraries
| * Tests: Cover fltk_wrap_ui on an executable that links librariesBrad King2016-01-213-4/+7
| | | | | | | | | | | | | | CMake 3.4 may crash on this case. The problem seems to have been fixed since then, but keep it working by adding a test case now. Reported-by: Gonzalo Garramuño <ggarra13@gmail.com>
* | Merge topic 'FindPNG-imported-targets'Brad King2016-01-224-0/+50
|\ \ | | | | | | | | | | | | 9b08c623 FindPNG: Create an imported PNG::PNG target (#15911)
| * | FindPNG: Create an imported PNG::PNG target (#15911)Sam Thursfield2016-01-214-0/+50
| | | | | | | | | | | | | | | | | | Imported targets are now the recommended way of dealing with external library dependencies. Add one for FindPNG and update documentation accordingly. Also add a test case activated by CMake_TEST_FindPNG.
* | | Merge topic 'fix-pkg_search_module-cache'Brad King2016-01-222-0/+17
|\ \ \ | | | | | | | | | | | | | | | | 40249bcc FindPkgConfig: set standard variables in the cache
| * | | FindPkgConfig: set standard variables in the cacheBen Boeckel2016-01-212-0/+17
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | Fixes a regression introduced when the code was simplified to use the variable queries. Fixes #15903. Reported-by: Bernd Lörwald
* | | Merge topic 'add-FindXalanC'Brad King2016-01-214-0/+41
|\ \ \ | | | | | | | | | | | | | | | | f9e45ab9 FindXalanC: New module to find the Apache Xalan-C++ library
| * | | FindXalanC: New module to find the Apache Xalan-C++ libraryRoger Leigh2016-01-204-0/+41
| | | |
* | | | cmake: Fix `-E time` argument passing to childBrad King2016-01-204-0/+10
| |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | Since this command was introduced in 2002 it has incorrectly constructed the child process command line by concatenating arguments separated by spaces with no quoting. Fix this by passing the command argument vector directly to RunSingleCommand without an intermediate quoting and re-parsing step. Reported-by: Andrey Pokrovskiy <wonder.mice@gmail.com>
* | | Merge topic 'cache-parse-error-line-number'Brad King2016-01-207-0/+26
|\ \ \ | | | | | | | | | | | | | | | | 77cd74a3 Print line number of cache parse errors (#11109)
| * | | Print line number of cache parse errors (#11109)Ashley Whetter2016-01-197-0/+26
| | |/ | |/| | | | | | | | | | Track the line number while parsing `CMakeCache.txt` files and include it in a parse failure error message.
* | | UseJava: Fix create_javah CLASSPATH handling on WindowsMarc Chevrier2016-01-194-3/+40
|/ / | | | | | | Preserve semicolons in the value.
* | Fix export of STATIC library PRIVATE dependencies with CMP0022 NEWBrad King2016-01-153-1/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The target_link_libraries command records the PRIVATE dependencies of a STATIC library in INTERFACE_LINK_LIBRARIES as "$<LINK_ONLY:dep>". This hides the target name from export namespacing logic inside a generator expression. When user-written generator expressions reference a target name they must put it inside a "$<TARGET_NAME:dep>" expression to allow the export logic to rename the target. In the case that the private dependency is not already a generator expression, target_link_libraries must use "$<LINK_ONLY:$<TARGET_NAME:dep>>" to allow the export logic to rename the target. Reported-by: Tamás Kenéz <tamas.kenez@gmail.com>
* | Tests: Use CMP0022 NEW behavior in some ExportImport casesBrad King2016-01-151-0/+3
| |
* | Tests: Isolate policy changes in ExportImport testBrad King2016-01-151-2/+5
|/ | | | Use cmake_policy(PUSH/POP) to isolate CMP0022 policy changes.
* Merge topic 'install-DIRECTORY-genex'Brad King2016-01-147-5/+14
|\ | | | | | | | | 630c8aa8 install: Allow generator expressions in DIRECTORY
| * install: Allow generator expressions in DIRECTORYYves Frederix2016-01-137-5/+14
| | | | | | | | | | Teach install(DIRECTORY) to support generator expressions in the list of directories, much like install(FILES) already supports.
* | Add -Werror and -Wno-error command-line optionsMichael Scott2016-01-1222-9/+95
|/ | | | | | | | | Expand the -W set of cmake options to include support for the -Werror and -Wno-error format, which is used to control upgrading and downgrading warning and error messages. Implement support for these new formats for the dev and deprecated message types. Add tests and updated documentation for new options.
* Merge topic 'release-windows'Brad King2016-01-071-1/+1
|\ | | | | | | | | | | | | | | fae47798 Utilities/Release: Configure Windows binary to support Windows XP 083312a8 Utilities/Release: Switch to .msi builder for Windows binary 240b065f Utilities/Release: Optionally load environment on remote build server a95b4715 Utilities/Release: Add optional remote launcher to ssh calls
| * Utilities/Release: Switch to .msi builder for Windows binaryBrad King2015-12-211-1/+1
| | | | | | | | | | Use a new build machine to produce the Windows binary using the CPack WiX generator to produce a `.msi` installer.
* | Merge topic 'xcode-global-attribute-variant'Brad King2016-01-072-1/+61
|\ \ | | | | | | | | | | | | | | | | | | | | | d8bc26a0 Xcode: Parse variant and genex for CMAKE_XCODE_ATTRIBUTE (#14947) dc0ddb9e Xcode: Store configuration name along with XcodeObject (#14947) 28f98cee Xcode: Make CMAKE_XCODE_ATTRIBUTE calculation last step (#14947) 28db2268 Xcode: Factor out XCODE_ATTRIBUTE_ variant filter (#14947)
| * | Xcode: Parse variant and genex for CMAKE_XCODE_ATTRIBUTE (#14947)Gregor Jasny2016-01-032-1/+61
| |/
* | Merge topic 'xcode-escape-backslash'Brad King2016-01-073-0/+11
|\ \ | | | | | | | | | | | | ba39d7e9 Xcode: Escape all backslashes in strings (#15328)
| * | Xcode: Escape all backslashes in strings (#15328)Gregor Jasny2016-01-073-0/+11
| |/ | | | | | | | | | | | | | | | | | | Before this change backslashes in strings were escaped during compile flags adds via AppendFlag(). But global flags like OTHER_CPLUSPLUSFLAGS are not added as flags but as plain strings so they were not escaped properly. Now the escaping is performed within cmXCodeObject::PrintString() which ensures that strings are always encoded.
* | GenerateExportHeader: Work around buggy std::getline behavior in BCB5.James Johnston2015-12-311-0/+12
|/
* cmake_parse_arguments: consider duplicate keyword as warningMatthias Maennich2015-12-172-3/+43
| | | | | | The behaviour of double specified keywords is rather undefined or at least not clearly documented. This change introduces a strict check and emits a warning in case a keyword has been specified more than once.
* CMakeParseArguments: replace by native cmake_parse_arguments commandMatthias Maennich2015-12-175-17/+9
| | | | | | | Implement a native `cmake_parse_arguments` command that is fully compatible with the documented behaviour of the previous implementation. Leave the CMakeParseArguments module empty but existing for compatibility.
* CMakeParseArguments: add a RunCMake test suiteMatthias Maennich2015-12-1711-0/+185
|
* Merge topic 'FindGTest-imported-targets'Brad King2015-12-144-0/+38
|\ | | | | | | | | | | | | f0b5ce7f Help: Add notes for topic 'FindGTest-imported-targets' 99afe235 Tests: Add tests for FindGTest 611735e7 FindGTest: Add imported targets and update documentation
| * Tests: Add tests for FindGTestRoger Leigh2015-12-104-0/+38
| |
* | Merge topic 'ios-universal'Brad King2015-12-117-0/+160
|\ \ | | | | | | | | | | | | | | | 565d080a Xcode: Add support for combined install on iOS 34f5ef56 iOS: Fix App Bundle layout
| * | Xcode: Add support for combined install on iOSRuslan Baratov2015-12-107-0/+160
| |/ | | | | | | | | | | | | | | | | | | | | | | This patch solves the problem of installing both: Device and Simulator libraries on iOS. Before only one of them was installed. If the IOS_INSTALL_COMBINED property is set on a target, a special install hook will be activated which builds the corresponding target and combines both at the install location. The original patch was contributed by Ruslan Baratov, and polished by Gregor Jasny.
* | Merge topic 'simplify-CTest.UpdateGIT-test'Brad King2015-12-111-19/+11
|\ \ | | | | | | | | | | | | 972849fb Tests: Simplify CTest.UpdateGIT repo path construction
| * | Tests: Simplify CTest.UpdateGIT repo path constructionBrad King2015-12-101-19/+11
| |/ | | | | | | | | | | | | Avoid constructing full paths to .git repositories in the test. Use relative paths and let Git convert them to absolute paths internally. This is simpler and also avoids trouble with various absolute path root component conventions on Windows (`c:/`, `/c/`, `/cygdrive/c/`).
* | cmake: Teach -E make_directory to support multiple input directoriesBartosz Kosiorek2015-12-107-0/+18
|/
* Merge topic 'cmake-E-copy-multiple-inputs'Brad King2015-12-0910-0/+23
|\ | | | | | | | | | | | | | | bc35087d cmake: Teach -E copy_directory to support multiple input directories 98be140f cmake: Refine -E copy[_if_different] documentation 93cc80ae cmake: Refine -E copy_if_different implementation indentation 0903812b cmake: Refine -E chdir documentation