summaryrefslogtreecommitdiffstats
path: root/Tests/ComplexOneConfig
Commit message (Collapse)AuthorAgeFilesLines
* Tests: choose an explicit FULL strategy in tests expecting itBen Boeckel2025-07-291-0/+2
| | | | | | Since it can be set in the environment when running the test suite, guard tests which are sensitive to intermediate directory strategy changes with explicit settings.
* CMAKE_COMPILER_IS_*: Replace with CMAKE_<LANG>_COMPILER_IDPeter Kokot2025-03-292-2/+2
| | | | | | | | | | Variables such as CMAKE_COMPILER_IS_GNUCC are documented as obsolete/deprecated and ideally shouldn't be used in the code anymore to have clearer compiler identifications. In the past QCC compiler was identified as GNU and also had this variable set to 1 (see policy CMP0047). Same still applies for LCC compiler (see policy CMP0129).
* Revise C++ coding style using clang-format with "east const"Kitware Robot2025-01-231-4/+4
| | | | | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`, now with "east const" enforcement. Use `clang-format` version 18. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit. Issue: #26123
* Revise C++ coding style using clang-format-18Kitware Robot2025-01-231-1/+1
| | | | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 18. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit. Fixes: #26123
* CMP0050: Remove support for OLD behaviorBrad King2025-01-192-13/+3
|
* CMP0043: Remove support for OLD behaviorBrad King2025-01-192-17/+0
| | | | | Note that per-source `COMPILE_DEFINITIONS_<CONFIG>` are not covered by the policy, and are still supported.
* CMP0035: Remove support for OLD variable_requires commandBrad King2025-01-193-19/+2
|
* CMP0034: Remove support for OLD utility_source commandBrad King2025-01-192-7/+1
|
* CMP0033: Remove support for OLD export_library_dependencies commandBrad King2025-01-191-3/+0
|
* CMP0032: Remove support for OLD output_required_files commandBrad King2025-01-194-29/+0
|
* CMP0029: Remove support for OLD subdir_depends commandBrad King2025-01-191-2/+0
|
* CMP0003: Remove support for OLD behaviorBrad King2025-01-171-10/+0
|
* style: Remove trailing blank lines from all CMake sourcesMatthew Woehlke2024-11-212-2/+0
| | | | | | | Our development workflow tooling prevents trailing blank lines from being added, but some such lines remain from before that was enforced. Remove them to make it easier to rename files without triggering enforcement.
* Tests: Update cmake_minimum_required versions to 3.10Brad King2024-10-035-6/+8
|
* Tests: Fix clang -Wstrict-prototypes warningsBrad King2023-10-264-4/+4
|
* OrangeC: Add support for OrangeC compilerDavid Lindauer2023-09-253-2/+8
| | | | | | | Add compiler information modules. Update the test suite. Fixes: #25032 Co-authored-by: Brad King <brad.king@kitware.com>
* Tests: Simplify nested if conditions in Complex testsBrad King2023-09-252-19/+5
|
* Tests/ComplexOneConfig: Replace exec_program() with execute_process()Kyle Edwards2023-07-241-3/+3
|
* Tests: Fix some tests under CFLAGS=-DNDEBUG CXXFLAGS=-DNDEBUGBrad King2022-09-012-1/+9
| | | | Fixes: #23888
* Tests: Remove incidental use of C++98 compiler modesBrad King2022-04-261-15/+0
| | | | | | | | | | Several tests specify use of C++98 mode since commit b0f277db38 (HP aCC: record compiler flag for Ansi C++98 support for version 3.80 onwards, 2014-04-15, v3.1.0-rc1~550^2). The motivating use case for those changes was dropped by commit 49640d3629 (HP-UX: Drop support for building CMake on HP-UX, 2017-08-04, v3.10.0-rc1~304^2), so remove the use of C++98 mode too. Also remove code that, on some compilers, used C++11 instead of C++98, because we can now just use their default mode.
* replace remove and remove_directory with rm in testsJohnny Jazeix2019-11-132-2/+2
|
* Revise include order using clang-format-6.0Kitware Robot2019-10-012-3/+6
| | | | | Run the `clang-format.bash` script to update our C and C++ code to a new include order `.clang-format`. Use `clang-format` version 6.0.
* Clang: For MSVC ABI do not use modes older than C++14Brad King2019-07-241-5/+0
| | | | | | | | | | | | | | | | | | | | Since commit d44c0db0b2 (clang: setup correct configuration in gnu mode, 2019-02-20, v3.15.0-rc1~41^2~5) we support the GNU-like Clang that targets the MSVC ABI. However, Clang cannot compile with the MSVC standard library unless it runs in a mode aware of C++14 (since MSVC itself does not even have a lower mode). When `CMAKE_CXX_STANDARD` is set to 98 or 11, use C++14 anyway. Since Clang's default mode is aware of C++14, another option is to not add any flags for 98 or 11. However, if a future Clang version ever defaults to a higher C++ standard, setting the standard to 98 or 11 should at least not use a mode higher than 14. Also revert test updates from commit 4819ff9647 (Tests: fix failures with gnu mode clang on windows, 2019-03-21, v3.15.0-rc1~41^2~3) that were meant to work around the standard selection problem. Fixes: #19496
* Tests: fix failures with gnu mode clang on windowsZsolt Parragi2019-05-241-0/+5
| | | | | | | | | Root causes were: * Using incorrect conditions (assuming MSVC-like command line mode) * Trying to compile the MSVC STL in C++11 mode, when parts of it require C++14 or enabling MS extensions in clang. * Missing flush in a testcase using stdout in a dll and a main part with static crt
* Fix misc. typosluz.paz2018-06-041-1/+1
| | | | Found via `codespell` and `grep`
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-016-41/+41
| | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 6.0. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
* MAINT: Misc. typosluz.paz2018-02-131-1/+1
| | | | Found via `codespell -q 3 -I ../cmake-whitelist.txt`.
* HP-UX: Drop support for building CMake on HP-UXBrad King2017-08-071-7/+0
| | | | | | | | CMake will soon require both C++11 and libuv to build. Neither of these works on HP-UX, so unfortunately we need to drop support for the platform until someone can get them working. Issue: #17137
* configure_file: Add support for indented cmakedefineSylvain Joubert2017-07-044-0/+30
| | | | | | | | Optional spaces and/or tabs are now understood between the '#' character and the 'cmakedefine'/'cmakedefine01' words. This indentation is preserved in the output lines. Fixes: #13037
* Add additional <= and >= comparison operatorsChuck Atkins2016-08-092-17/+255
| | | | | This adds the LESS_EQUAL, GREATER_EQUAL, and associated STR and VERSION equivalents to use the combined <= and >= functionality.
* Use string(APPEND) in TestsDaniel Pfeifer2016-07-274-6/+6
| | | | | | | Automate with: find Tests -type f -print0 | xargs -0 perl -i -0pe \ 's/set\(([a-zA-Z0-9_]+)(\s+)"\$\{\1\}([^"])/string(APPEND \1\2"\3/g'
* Source: Remove long-unused .cvsignore fileBrad King2016-07-081-1/+1
|
* Revise C++ coding style using clang-formatKitware Robot2016-05-1611-267/+225
| | | | | | | | | | | | | Run the `Utilities/Scripts/clang-format.bash` script to update all our C++ code to a new style defined by `.clang-format`. Use `clang-format` version 3.8. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
* Format include directive blocks and ordering with clang-formatBrad King2016-04-291-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sort include directives within each block (separated by a blank line) in lexicographic order (except to prioritize `sys/types.h` first). First run `clang-format` with the config file: --- SortIncludes: false ... Commit the result temporarily. Then run `clang-format` again with: --- SortIncludes: true IncludeCategories: - Regex: 'sys/types.h' Priority: -1 ... Commit the result temporarily. Start a new branch and cherry-pick the second commit. Manually resolve conflicts to preserve indentation of re-ordered includes. This cleans up the include ordering without changing any other style. Use the following command to run `clang-format`: $ git ls-files -z -- \ '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' | egrep -z -v '(Lexer|Parser|ParserHelper)\.' | egrep -z -v '^Source/cm_sha2' | egrep -z -v '^Source/(kwsys|CursesDialog/form)/' | egrep -z -v '^Utilities/(KW|cm).*/' | egrep -z -v '^Tests/Module/GenerateExportHeader' | egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' | xargs -0 clang-format -i This selects source files that do not come from a third-party. Inspired-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
* Tests: fix complexOneConfig building on Clang/C2Mariusz PluciƄski2016-03-101-0/+7
|
* Xcode: Disable test for system include dirsGregor Jasny2016-02-081-1/+2
|
* Tests: Remove incorrect indentation from Complex test commentBrad King2015-01-221-1/+1
|
* Encoding: Modify tests to work using non-ascii paths.Clinton Stimpson2015-01-092-16/+20
| | | | | | | | | | For complex*, CustomCommand and OutDir tests, non-ascii paths are avoided in test code by using relative paths, and setting the working when running the test. This also avoids the need to internationalize the test code. For RunCMake.GeneratorExpression, use a UTF-8 encoding in file(STRINGS) to retrieve the compiled absolute path correctly.
* Tests: Set policies in 'complex' testsBrad King2014-07-221-0/+15
| | | | | | These tests cover the OLD behavior of some policies. Set them to OLD to avoid warnings in the test output. Leave a comment that explains why this is done here but not recommended in general.
* tests: allow RelWithDebInfo and MinSizeRel configs to workBen Boeckel2014-06-051-0/+8
|
* HP aCC: record compiler flag for Ansi C++98 support for version 3.80 onwardsRolf Eike Beer2014-04-251-0/+15
| | | | | | Old versions of aCC need a special compiler flag to get full C++98 template support as e.g. CMake itself or the Complex and ComplexOneConfig tests need. The same versions need a special flag to get a proper C++ library, too.
* Replace MATCHES test on numbers with EQUAL testRolf Eike Beer2014-04-141-1/+1
| | | | | The MATCHES tests were actually wrong, as "a4b" and "42" would also cause a match when it should not.
* Remove .* expressions from beginning and end of MATCHES regexsRolf Eike Beer2014-04-141-1/+1
| | | | | | | | | All these expressions work the same: "foo" ".*foo.*" "^.*foo.*$" This assumes that the "Intel*" expressions were meant to be "Intel.*".
* Drop use of configure_file IMMEDIATE optionDaniele E. Domenichelli2013-11-131-3/+3
| | | | | | Since commit 7d47c693 (Drop compatibility with CMake < 2.4, 2013-10-08) we no longer need to use the configure_file IMMEDIATE option to support compatibility modes less than 2.0.
* Drop compatibility with CMake < 2.4Brad King2013-10-233-5/+4
| | | | | | | | | | | | Drop all behavior activated by setting CMAKE_BACKWARDS_COMPATIBILITY to a value lower than 2.4, and generate an error when projects or the user attempt to do so. In the error suggest using a CMake 2.8.x release. Teach cmake_minimum_required to warn about projects that do not require at least CMake 2.4. They are not supported by CMake >= 3.0. Replace the documentation of CMAKE_BACKWARDS_COMPATIBILITY with a reference to policy CMP0001.
* Haiku: Several fixes to platform moduleAdrien Destugues2013-10-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Do not define BEOS anymore (this includes workarounds which we don't need most of the time in Haiku, so we prefer opt-in IF(HAIKU) in the cmake files instead). * On the other hand, do define UNIX (we are trying to be compliant) and HAIKU (there is still a number of things we don't do like the average UNIX clone) * Do not use UnixPaths, as our filesystem hierarchy isn't anything like what it expects. * Do not use -nostart, which the compiler doesn't know about anymore. This used to be an Haiku extension to gcc, and is equivalent to -shared which is the default gcc option. * While "dl" functions are provided in libroot, this is always implicitly linked so there is no need to tell cmake about it. * Forcing position-independent code is not needed, so remove it. * On the other hand, include appropriate linker options for executables and shared libraries. * Support for the two available compilers in Haiku (gcc2 and gcc4) and pick the right headers and libraries according to the currently selected one. * With the adoption of the package manager, the directory layout was changed. Tell cmake where to look for header files and libraries. * As we don't define BEOS anymore, enable the workaround we still need for HAIKU as well. This is the lack of a libm (it is part of the implicitly linked in libroot) Applied-by: Rolf Eike Beer <eike@sf-mail.de>
* replace string(... MATCHES "^const$) with string(... STREQUAL "const")Rolf Eike Beer2013-06-021-8/+5
|
* get_filename_component: Add explicit unit testsBrad King2013-04-163-103/+0
| | | | | Add test RunCMake.get_filename_component to cover cases of the command. Remove redundant coverage of these cases from the "complex" tests.
* Remove CMake-language block-end command argumentsKitware Robot2012-08-135-121/+121
| | | | | | | | | | | | | | | | | Ancient versions of CMake required else(), endif(), and similar block termination commands to have arguments matching the command starting the block. This is no longer the preferred style. Run the following shell code: for c in else endif endforeach endfunction endmacro endwhile; do echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/' done >convert.sed && git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' | egrep -z -v '^(Utilities/cm|Source/kwsys/)' | egrep -z -v 'Tests/CMakeTests/While-Endwhile-' | xargs -0 sed -i -f convert.sed && rm convert.sed
* Convert CMake-language commands to lower caseKitware Robot2012-08-137-490/+490
| | | | | | | | | | | | | | | | | Ancient CMake versions required upper-case commands. Later command names became case-insensitive. Now the preferred style is lower-case. Run the following shell code: cmake --help-command-list | grep -v "cmake version" | while read c; do echo 's/\b'"$(echo $c | tr '[:lower:]' '[:upper:]')"'\(\s*\)(/'"$c"'\1(/g' done >convert.sed && git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' | egrep -z -v '^(Utilities/cm|Source/kwsys/)' | xargs -0 sed -i -f convert.sed && rm convert.sed