summaryrefslogtreecommitdiffstats
path: root/Tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge topic 'autogen-qt-version-from-dirprops'Brad King2019-01-316-1/+72
|\ | | | | | | | | | | | | | | | | | | | | 91d98542d2 Merge branch 'autogen-qt-version-from-dirprops-release' into autogen-qt-version-from-dirprops-master 062d21c36a Autogen: Read the Qt version from directory properties as well 17ac7c4024 Tests: add cases for providing Qt5Core_VERSION manually 2df6d69014 AutoGen: query Qt5 version from directory properties b598dfb65e Tests: add cases for providing Qt5Core_VERSION manually Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2883
| * Tests: add cases for providing Qt5Core_VERSION manuallyBen Boeckel2019-01-306-1/+72
| |
* | Merge topic 'restore-install-late-framework'Brad King2019-01-313-0/+14
|\ \ | |/ |/| | | | | | | | | | | | | | | f64099cf5e Merge branch 'backport-restore-install-late-framework' 95210d027a macOS: Restore compatibility for setting FRAMEWORK after install() d9dd68cb60 macOS: Restore compatibility for setting FRAMEWORK after install() Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Kyle Edwards <kyle.edwards@kitware.com> Merge-request: !2878
| * macOS: Restore compatibility for setting FRAMEWORK after install()Brad King2019-01-303-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `FRAMEWORK` target property affects the way the `install()` command treats the target and so should be set first. Our implementation assumed that this was always the case and led to an assertion failure. Prior to CMake 3.12 this was visible only when using an explicit `LIBRARY ... NAMELINK_ONLY` option, but commit 0212d7c762 (install: add NAMELINK_COMPONENT argument, 2018-04-18, v3.12.0-rc1~139^2~3) made it possible with a simple `LIBRARY DESTINATION`. Fully supporting out-of-order specification will require non-trivial refactoring to defer install generator creation to generate time. For now simply restore the old behavior of installing the framework to the library destination and warn about the case. Fixes: #18848
* | Merge topic 'fetchcontent-reduce-boilerplate'Brad King2019-01-3010-0/+52
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | a94355c7b7 FetchContent: Add new command FetchContent_MakeAvailable() 611d5274de Sphinx: Add limited support for nested variables in docs 1a07e1b47d FetchContent: Trivial doc corrections Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2830
| * | FetchContent: Add new command FetchContent_MakeAvailable()Craig Scott2019-01-2610-0/+52
| | | | | | | | | Relates: #18754
* | | Merge topic 'add_consistent_verbose_build_flag'Brad King2019-01-2911-1/+50
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 66801f4d40 cmake: Add tests for verbose output to --build mode 439fe2e253 cmake: Add options for verbose output to --build mode 638667efa2 cmake: cmcmd.cxx fix "The arguments are" comments 3ca4402966 ctest: Fix --build-and-test without --build-target on Xcode cb6c233ecc cmake: Add -hideShellScriptEnvironment xcodebuild option 1a45266cb5 cmGlobalGenerator: Add a class that represent the build command Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2708
| * | | cmake: Add tests for verbose output to --build modeRobert Maynard2019-01-2811-1/+50
| | | |
* | | | Merge topic 'update-tutorial'Brad King2019-01-29120-680/+3346
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 0e2cdacf7b Tests: Update style of c++ code snippets in Tutorial directions f2ddedfa58 Tests: Update CMake tutorial 438651506a Tests: Make ExternalProjectLocal independent of Tutorial directory Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2731
| * | | | Tests: Update style of c++ code snippets in Tutorial directionsZack Galbreath2019-01-272-25/+17
| | | | |
| * | | | Tests: Update CMake tutorialBetsy McPhail2019-01-27112-604/+3099
| | | | | | | | | | | | | | | | | | | | Latest material from data.kitware.com -> Collections -> Courses -> CMake.
| * | | | Tests: Make ExternalProjectLocal independent of Tutorial directoryBetsy McPhail2019-01-278-76/+255
| | | | | | | | | | | | | | | | | | | | | | | | | Adopt a copy of the needed content so we can modify the original independent of this test.
* | | | | Merge topic 'vs-host-arch'Brad King2019-01-298-5/+24
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 0fd742a6ff VS: Teach VS 2019 generator to select host tools matching host arch 17cef3806d VS: Add support for explicit 32-bit toolset selection via host=x86 bf774e521b VS: Remove stray semicolons from VS 2019 implementation 142e67eac6 VS: Use internal abstraction for VCTargetsPath host arch Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2870
| * | | | | VS: Teach VS 2019 generator to select host tools matching host archBrad King2019-01-282-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This generator is new so we can introduce the long-desired behavior of selecting ``host=x64`` tools by default on x64 hosts.
| * | | | | VS: Add support for explicit 32-bit toolset selection via host=x86Brad King2019-01-286-4/+10
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | Generalize the ``host=x64`` option in `CMAKE_GENERATOR_TOOLSET` to also support ``host=x86``.
* | | | | Autogen: Reenable passing compiler implicit include directories to mocSebastian Holtermann2019-01-283-2/+11
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 5990ecb741 (Compute implicit include directories from compiler output, 2018-12-07) we now have compiler implicit include directory computation for gcc and clang. It should be safe now to pass these to `moc`. This patch re-enables passing the compiler implicit include directories to `moc`, which was disabled due to issue #18669. Fixes: #18041 Issue: #18669
* | | | Merge topic 'cmake-E-compare_files-eol'Brad King2019-01-2810-0/+12
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a5098cad94 cmake: Add --ignore-eol option to `-E compare_files` command Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2778
| * | | | cmake: Add --ignore-eol option to `-E compare_files` commandTaylor Braun-Jones2019-01-2810-0/+12
| |/ / / | | | | | | | | | | | | Fixes: #13007
* | | | Merge topic 'get_filename_component_last_ext'Brad King2019-01-281-1/+3
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2a9220c34d Help: Add notes for topic 'get_filename_component_last_ext' edda30d0f5 Tests: Add tests for LAST_EXT and NAME_WLE 7a25ef326b Help: Add documentation for new get_filename_component components e50a36df48 cmGetFilenameComponentCommand: Add more components Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2853
| * | | | Tests: Add tests for LAST_EXT and NAME_WLETushar Maheshwari2019-01-241-1/+3
| | |/ / | |/| |
* | | | Merge topic 'implicit-incs-upd'Brad King2019-01-2845-7/+1085
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2e91627dea ParseImplicitIncludeInfo: add Fortran implicit include handling 568343767e ParseImplicitIncludeInfo: handle/add SunPro, XL, and -nostdinc test cases Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2855
| * | | | ParseImplicitIncludeInfo: add Fortran implicit include handlingChuck Cranor2019-01-2515-6/+436
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently cmake is only setting CMAKE_Fortran_IMPLICIT_INCLUDE_DIRECTORIES the first time it runs (the implicit includes parser is only run when the cache variables are initially populated). It is left unset during additional runs. This behavior is both confusing and inconsistent. Modify CMakeFortranCompiler.cmake.in to preserve the value of CMAKE_Fortran_IMPLICIT_INCLUDE_DIRECTORIES so that cmake's Fortran behavior matches C and CXX (i.e. CMAKE_Fortran_IMPLICIT_INCLUDE_DIRECTORIES retains its value across runs). The implicit includes variable may not be as useful for Fortran as it is for C and CXX, but we do want cmake to be consistent in how it is handled. Adjust CMakeParseImplicitIncludeInfo to parse verbose Fortran output for Cray and XL compiler IDs (GNU and clang were already ok since they use the same verbose output format as they do with C/CXX). Allow Tests/RunCMake/ParseImplicitIncludeInfo/data/CMakeLists.txt to generate test inputs for Fortran too, and add some sample Fortran input files for the Tests/RunCMake/ParseImplicitIncludeInfo test.
| * | | | ParseImplicitIncludeInfo: handle/add SunPro, XL, and -nostdinc test casesChuck Cranor2019-01-2532-2/+650
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add parser code for compiler IDs SunPro and XL. For SunPro, /usr/include appears to be hardwired in and it does not have a -nostdinc-type flag. For XL, the "xlc" and "xlC" commands determine if you are C or C++ based on input filename. So compiling x.c with "xlC" reverts to C and compiling x.cc with "xlc" upgrades to CXX. System include paths are specified by: -qc_stdinc=[path] and -qgcc_c_stdinc=[path] (for C) -qcpp_stdinc=[path] and -qgcc_cpp_stdinc=[path] (for CXX) If you specify "-qnostdinc" then the above flags are ignored. Specifying an empty path reverts the value to the default path (e.g. "-qgcc_c_stdinc=" reverts that to the default). Adjust the code to handle parsing the case where the user specifies additional compiler include flags via CMAKE_C_FLAGS/CMAKE_CXX_FLAGS. For example: "-DCMAKE_C_FLAGS=-nostdinc" ... note that gcc and clang output slightly differ when -nostdinc is specified (clang skips printing 'search starts here:' with the angle brackets, gcc always prints it). Enable sunos-{C,CXX}-SunPro test cases and add XL test cases. Also add a few -nostdinc style tests.
* | | | Merge topic 'png-optimize'Brad King2019-01-2818-10/+10
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | b9e6d04558 Reduce size of PNG images 880e380599 CPack: Replace corrupted background png with original Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2852
| * | | Reduce size of PNG imagesLucy Phipps2019-01-2518-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | Use FileOptimizer 13.50.2431 (x86) and ZopfliPNG 1.0.2. Update expected file hashes in tests.
* | | | Merge topic 'max-recursion-depth'Brad King2019-01-2590-0/+657
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a6982cff0d cmMakefile: Impose maximum recursion limit Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Juraj Oršulić <juraj.orsulic@fer.hr> Merge-request: !2746
| * | | | cmMakefile: Impose maximum recursion limitKyle Edwards2019-01-2390-0/+657
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to keep infinitely-recursive scripts from causing a stack overflow in the CMake executable, CMake now imposes a maximum recursion limit before issuing an error message. The limit can be adjusted at runtime with CMAKE_MAXIMUM_RECURSION_DEPTH. Fixes: #18694
* | | | Merge topic 'exclude_from_all'Brad King2019-01-253-0/+61
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dc6888573d Pass EXCLUDE_FROM_ALL from directory to targets Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2816
| * | | | Pass EXCLUDE_FROM_ALL from directory to targetsZack Galbreath2019-01-213-0/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a target is created it now inherits the EXCLUDE_FROM_ALL property from its directory. This change makes it possible to include a target in "all", even if its directory has been marked as EXCLUDE_FROM_ALL.
* | | | | FindPython: Introduce NumPy componentHiroshi Miura2019-01-245-64/+183
| |_|/ / |/| | | | | | | | | | | | | | | Fixes: #18678 Signed-off-by: Hiroshi Miura <miurahr@linux.com>
* | | | FindPython: Support script modeKyle Edwards2019-01-234-0/+13
| | | | | | | | | | | | | | | | Fixes: #18827
* | | | FindPython: Test existence of imported targetsKyle Edwards2019-01-233-0/+24
| |/ / |/| |
* | | Merge topic 'cmake_build_jobs_supports_no_space'Brad King2019-01-239-0/+21
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | f2fca92686 cmake: --build supports '-jN' e463133cd2 Tests: Remove unused files from RunCMake.CommandLine test Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2819
| * | | cmake: --build supports '-jN'Robert Maynard2019-01-229-0/+25
| | | |
| * | | Tests: Remove unused files from RunCMake.CommandLine testBrad King2019-01-224-4/+0
| | | | | | | | | | | | | | | | Drop `-stderr.txt` files for cases that do not exist.
* | | | cmake: Convert no source/build dir error to warningCraig Scott2019-01-223-3/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Temporarily restore previous behavior that allowed specifying no source or build directory to work, even though it was neither documented nor supported. This commit is expected to eventually be reverted to restore the fatal error for such cases. Relates: #18817
* | | | Merge topic 'implicit-includes'Brad King2019-01-2256-0/+1560
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5990ecb741 Compute implicit include directories from compiler output d751d2d2ed CMakeDetermineCompilerABI: set locale to C for try_compile() c765ae495a CMakeDetermineCompilerABI: pass verbose flag during compilation 8c5221fb1f try_compile: Preserve special characters in COMPILE_DEFINITIONS 15ad830062 Refactor exclusion of -I/usr/include to avoid per-language values Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2716
| * | | | Compute implicit include directories from compiler outputChuck Cranor2019-01-2156-0/+1560
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - CMakeParseImplicitIncludeInfo.cmake: new parser that extracts the compiler's include path from verbose output. If the parser cannot parse the output, we fall back to the old behavior. On osx we skip over framework directories (handled elsewhere). - CMakeDetermineCompilerABI.cmake: - use verbose flag in try_compile for ${src} - use new cmake_parse_implicit_include_info() to attempt extract implicit include directory path and if successful set CMAKE_${LANG}_IMPLICIT_INCLUDE_DIRECTORIES - CMakeCCompiler.cmake.in and CMakeCXXCompiler.cmake.in - preserve CMAKE_${LANG}_IMPLICIT_INCLUDE_DIRECTORIES value between runs in the same way CMAKE_${LANG}_IMPLICIT_LINK_DIRECTORIES is preserved - Tests/RunCMake/ParseImplicitIncludeInfo: tests for parse based on the older Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in. The test runs a set of verbose compiler outputs collected from various machines through the parser and checks the results. New compiler files can be added by dropping input/output files in the ParseImplicitIncludeInfo/data subdirectory and then adding the new set of files to the ${targets} list in ParseImplicitIncludeInfo.cmake. There is a helper CMakeLists.txt in ParseImplicitIncludeInfo/data that can help with the generation of test input files. NOTE: the standard cmake pre-commit hook rejects verbose compiler output with trailing spaces... you have to manually edit them out. This shouldn't impact the test. Note that both the parser and the test code can use CMAKE_${LANG}_COMPILER_* variables such as ${CMAKE_CXX_COMPILER_ID} to decide how to parse verbose compiler output. For the test code, this requires us to save the variables values in the test input files. Fixes: #16291
* | | | | Merge topic 'help-mark-default-generator'Brad King2019-01-221-0/+4
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dfd5ae7da7 Help: Mark default CMake generator with asterisk 6023fe7ff2 ccmake: Append rather than replace Generators section of docs 7408cd3929 cmake: Return generator docs directly Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2682
| * | | | | Help: Mark default CMake generator with asteriskArtur Ryt2019-01-181-0/+4
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Required extracting default generator evaluation to explicit function, as Visual Studio generators get validated during their construction. Fixes: #18544
* | | | | Merge topic 'crosscompiling_emulator-fix'Brad King2019-01-221-0/+6
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ab3b549ee0 CROSSCOMPILING_EMULATOR: Fix test generation for empty value Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2834
| * | | | | CROSSCOMPILING_EMULATOR: Fix test generation for empty valueKyle Edwards2019-01-211-0/+6
| | |/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If CROSSCOMPILING_EMULATOR was set to an empty string, and a test was generated with the executable as the command, CMake would segfault upon trying to generate the test file. Fix this. Fixes: #18819
* | | | | FindGit: Add imported targetKyle Edwards2019-01-214-0/+47
|/ / / /
* | | | Merge topic 'ExternalProject-non-cmake-source-subdir'Brad King2019-01-213-0/+34
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | c09ec79981 ExternalProject: support SOURCE_SUBDIR for BUILD_IN_SOURCE Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2823
| * | | | ExternalProject: support SOURCE_SUBDIR for BUILD_IN_SOURCEBen Boeckel2019-01-173-0/+34
| | |_|/ | |/| |
* | | | Merge topic 'fortran-compiler-id'Brad King2019-01-2110-4/+61
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a080914274 Fortran: Add compiler ID/Version generator expressions Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2804
| * | | | Fortran: Add compiler ID/Version generator expressionsAndrew Paprocki2019-01-1810-4/+61
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds `Fortran_COMPILER_ID` and `Fortran_COMPILER_VERSION` generator expression support to match equivalent `C_COMPILER_ID`, `CXX_COMPILER_ID`, `C_COMPILER_VERSION`, and `CXX_COMPILER_VERSION` support. This is very helpful in the case where the C/C++ compiler suite is a different type of compiler from the platform Fortran compiler and projects use generator expressions to assign compiler flags and definitions. (e.g. `GNU` C/C++ and `SunPro` Fortran on Linux)
* | | | Merge topic 'cmake-role-fix'Brad King2019-01-213-2/+19
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 264bdac185 CMAKE_ROLE: Fix value for ctest --build-and-test Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2820
| * | | | CMAKE_ROLE: Fix value for ctest --build-and-testKyle Edwards2019-01-183-2/+19
| | |/ / | |/| | | | | | | | | | | | | | --build-and-test builds a CMake project, so CMAKE_ROLE should be PROJECT. Fix this and add a test case.
* | | | Merge topic 'ctest-json-polish'Brad King2019-01-217-11/+21
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cae9d2a61a CTest: Teach --show-only= to reject unknown values 7370b02c36 CTest: Teach --show-only=json-v1 to filter out not-available tests 62fec84ad7 Tests: Fix RunCMake.CTestCommandLine case when no python is found 75a7a23746 Tests: Rename RunCMake.CTestCommandLine show-only test cases fecbc87608 Tests: Fix RunCMake.CTestCommandLine to actually check json-v1 Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2812