summaryrefslogtreecommitdiffstats
path: root/Tests/Module
Commit message (Collapse)AuthorAgeFilesLines
* CUDA: Add Device LTO support for nvccRobert Maynard2022-07-224-0/+110
| | | | Fixes #22200
* IBMClang: Add support for IBM Open XL C/C++Aaron Liu2022-01-271-2/+2
| | | | Fixes: #22929
* LCC: Add policy CMP0129 regarding interpreting LCC as GNUmakise-homura2021-10-211-0/+3
| | | | | | | | | | Due to MCST LCC compiler identification is now changed to LCC, there should be a way for old projects to still identify it as GNU, as it was before. This commits adds the policy: CMP0129: Compiler id for MCST LCC compilers is now LCC, not GNU. This policy controls such a behavior. OLD behaivior is to treat LCC as GNU, NEW is to treat is as LCC.
* LCC: Add dedicated support for MCST LCC compilermakise-homura2021-10-151-2/+2
| | | | | | | | | | | | | | | | | | | | | Divert LCC compiler as a new one, instead of treating it as GNU. Since old times, Elbrus C/C++/Fortran Compiler (LCC) by MCST has been passing checks for GNU compilers, so it has been identified as GNU. Now, with intent of seriously upstreaming its support, it has been added as a separate LCC compiler, and its version displays not a supported GCC version, but LCC version itself (e.g. LCC 1.25.19 instead of GNU 7.3.0). This commit adds its support for detection, and also converts basically every check like 'is this compiler GNU?' to 'is this compiler GNU or LCC?'. The only places where this check is untouched, is where it regards other platforms where LCC is unavailable (primarily non-Linux), and where it REALLY differs from GNU compiler. Note: this transition may break software that are already ported to Elbrus, but hardly relies that LCC will be detected as GNU; still such software is not known.
* Tests: Update for the FujitsuClang compilerYuichiro Utsumi2021-03-311-2/+2
|
* Tests: Update for the Fujitsu compilerChuck Atkins2021-03-311-2/+2
|
* Tests: Update Module.WriteCompilerDetectionHeader for IntelLLVMBrad King2021-01-281-2/+2
|
* Tests: Update tests for NVHPC compilerTin Huynh2021-01-271-2/+2
| | | | Treat it just like PGI.
* Tests: Avoid duplicate custom commands for Xcode "new build system"Brad King2020-09-181-0/+7
|
* Tests: Cover CheckTypeSize with uint8_t and std::uint8_tBrad King2020-07-223-0/+38
|
* bindexplib: supporting llvm bitcode formats using llvm-nmZsolt Parragi2019-08-306-5/+36
|
* Clang: For MSVC ABI do not use modes older than C++14Brad King2019-07-241-3/+1
| | | | | | | | | | | | | | | | | | | | 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-1/+3
| | | | | | | | | 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
* Merge topic 'meta-feature_only_infer_granular_support'Brad King2019-04-101-4/+8
|\ | | | | | | | | | | | | | | | | | | 613ac56e50 Add a test to verify meta-feature parity with granular features b0f46c48f6 CompileFeatures: Now able to presume full language level support 646fb1a646 CompileFeatures: memoize C++ compilers with full language level support 0d641fcfad Tests: Remove outdated portion of CompileFeatures genex test Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3176
| * CompileFeatures: Now able to presume full language level supportRobert Maynard2019-04-091-4/+8
| | | | | | | | | | | | | | | | | | Previously compilers that only supported the meta-level flags would not have any of the granular features listed. Now we presume that they have full support and enable all the features. Update granular feature tests to skip the actual compilation checks for the presumed features.
* | find_dependency: Always search dependenciesDamien R2019-03-294-1/+36
|/ | | | | | | | | | | | | When a dependency was already found, find_dependency did not search it again. While this works in basic case, it does not when there are components as the check does not take components into account. Given the fact that there is no documentation about this optimization and that the correct implementation is not trivial as it would require changes in find_package to have the list of components already found we always search dependencies. Fix #17583.
* Tests: Fix Module.WriteCompilerDetectionHeader for Intel on WindowsBrad King2019-02-141-1/+2
| | | | | Fix a condition added by commit 091afa7342 (Tests: Teach tests when to treat clang-cl as MSVC, 2018-11-06) to be specific to Clang.
* Tests: Teach tests when to treat clang-cl as MSVCZsolt Parragi2019-02-111-3/+3
| | | | | | | | | | | | | | | | | | | * Disable the system include unused variable test in ExportImport when clang is in MSVC compatible mode. * Disable CxxDialect testcase when clang is in MSVC compatible mode, as it doesn't support `typeof`. * Teach Module.WriteCompilerDetectionHeader to treat clang-cl as MSVC. * Disable the SystemIncludeDirectories testcase within IncludeDirectories when clang is in MSVC compatible mode. * Disable the CMakeOnly.CheckCXXCompilerFlag testcase when clang is in MSVC compatible mode. * Treat clang-cl as MSVC in LinkOptions.cmake in the try_run and try_compile testcases.
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-018-63/+63
| | | | | | | | | | | | 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.
* Tests: Avoid duplicate rules in ExternalData testBrad King2018-04-132-3/+4
| | | | | | | | | | | | | In commit v3.7.0-rc1~158^2 (ExternalData: Tolerate files duplicated across multiple targets, 2016-07-07) we added a test case for repeating the same data file reference in three different targets in the same directory in order to exercise its corresponding fix. However, we re-used the top-level `Data.dat` file which is already produced by an unrelated test case. `ninja` diagnoses the duplicate rule. Update the test to use a dedicated data file name for the three-times repeated case to avoid this conflict. It still covers the original purpose of the test.
* WCDH: introduce BARE_FEATURESRolf Eike Beer2018-04-032-1/+37
| | | | | | This allows defining compat versions of some C/C++ features with the name of the keyword itself, so all code can look as if it was written for the new language standard.
* Merge topic 'modernize-git-whitespace-attributes'Brad King2017-08-256-5/+5
|\ | | | | | | | | | | | | | | | | | | | | 8ed03baa gitattributes: prefer `eol=crlf` to `-crlf` 40470031 MumpsCoverage: remove unnecessary attribute d20485d8 gitattributes: prefer `eol=lf` to `crlf=input` b85c2589 gitattributes: prefer `-text` for binary files 377f3685 gitattributes: remove unused attributes Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1173
| * gitattributes: prefer `-text` for binary filesBen Boeckel2017-08-236-5/+5
| |
* | Tests: Print more info on CheckIPOSupported test failureBrad King2017-08-233-6/+9
|/
* CompileFeatures: Makes tests work with meta-feature onlyChuck Atkins2017-05-291-1/+12
|
* Tests: Add cases for typical CheckIPOSupported usageRuslan Baratov2017-04-189-0/+88
|
* WriteCompilerDetectionHeader: fix STATIC_ASSERTDaniel Pfeifer2017-03-062-0/+6
| | | | fixes #16185
* Tests/Module/WCDH: only use -Werror=undef compiler flag if actually supportedRolf Eike Beer2017-02-021-1/+5
|
* Tests/Module/WCDH: write multi_file_compiler_detection.h before using itRolf Eike Beer2017-02-021-11/+11
| | | | | | | | This was broken in commit 98e6d1e5e426c491e04faa746c11746002e6a69d (Tests/Module/WCDH: make it work with only C features defined) when all C tests were made accessible even if no C++ features are available, but the header was only created if C++ features are available. Fix it by creating the header unconditionally before any checks on the available features.
* Tests/Module/WCDH: make it work with only C features definedRolf Eike Beer2017-01-301-51/+51
|
* WCDH: optionally omit error code for unknown compilers or compiler versionsRolf Eike Beer2017-01-301-1/+29
| | | | | | This allows one to generate a header that will basically always work. In case an unknown compiler or compiler version is encountered it simply falls back to the unsupported case.
* ExternalData: Add support for SHA-3 algorithmsBrad King2016-11-113-0/+3
|
* ExternalData: Add support for multiple hash algorithmsMatt McCormick2016-10-185-0/+6
| | | | | | | | | | Add support for projects to have `Data.txt.md5` *and* `Data.txt.sha512` where the content links hold hashes for the same file. Check all `ExternalData_URL_TEMPLATES` entries in order for all available hashes. The data acquisition is considered a failure if none of the available URL resources has any of the given hashes. This makes it possible to have multiple data server resources where all servers do not support all hashing algorithms.
* ExternalData: Tolerate files duplicated across multiple targetsBrad King2016-09-073-0/+27
| | | | | | | | | | | | | | | | | | | | | | If multiple ExternalData_Target_Add calls generate the same output file then we need to avoid calling add_custom_command multiple times with that output. This was already done within a single target by setting a variable in the local function scope. This will not be visible in other calls though so we need to use a directory property instead to prevent adding a custom command multiple times for one output in a directory. Normally it is not safe to have multiple custom commands that produce the same output file across multiple independent targets, but since we use atomic replacement of outputs the resulting races should not be a problem. For the convenience of projects, tolerate this instead of diagnosing it. In particular, we previously allowed up to two copies of the custom command in one directory because CMake has a fallback from MAIN_DEPENDENCY to an `<output>.rule` file. While at it, add a note to the documentation that typically only one external data target should be needed for a project. Reported-by: David Manthey <david.manthey@kitware.com>
* Tests: Port GenerateExportHeader test to RunCMake infrastructureBrad King2016-09-0534-1530/+0
| | | | This will allow build failure cases to be added later.
* Use string(APPEND) in TestsDaniel Pfeifer2016-07-271-2/+2
| | | | | | | 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'
* Tests: Run clang-format on GenerateExportHeader codeBrad King2016-06-291-1/+1
|
* GenerateExportHeader: Add option to specify custom contentBrad King2016-06-282-0/+7
|
* Revise C++ coding style using clang-formatKitware Robot2016-05-1616-189/+238
| | | | | | | | | | | | | 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.
* WCDH: Add Intel to list of supported compilersRobert Maynard2016-04-281-5/+9
|
* GenerateExportHeader: Do not define DEFINE_NO_DEPRECATED (#16022)Andreas Schuh2016-03-1714-42/+56
| | | | | | Previously we allowed this definition to persist outside our header. This would cause conflicts across multiple such headers because the name was always the same. Fix this by avoiding the definition altogether.
* Tests: fix Module.GenerateExportHeader building on Clang/C2Mariusz PluciƄski2016-03-103-1/+93
|
* Tests: fix GenerateExportHeader directory definitionsBen Boeckel2016-02-122-9/+6
| | | | | | There's no need to stringify the values, but instead just pass in strings. The core problem is that the path may have tokens which are replaced by the preprocessor which causes an invalid path to be used.
* GenerateExportHeader: Work around buggy std::getline behavior in BCB5.James Johnston2015-12-311-0/+12
|
* Revert topic 'compiler-features-solaris'Brad King2015-10-081-2/+1
| | | | | | | | Revert commit v3.4.0-rc1~10^2~2 (Features: Disable support for Oracle SolarisStudio on non-Linux, 2015-09-29) and two follow-up commits. The support of compile features and language standards on Orcale SolarisStudio needs more investigation so for CMake 3.4 we should just act as 3.3 did.
* Tests: Suppress WriteCompilerDetectionHeader failure on SunProBrad King2015-09-301-1/+2
| | | | | | We do support SunPro 5.13 compiler features, but only on Linux. Suppress the portion of the test that fails on Solaris until the larger problem can be addressed.
* GenerateExportHeader: Use dllexport/dllimport on CygwinTony Kelman2015-08-271-2/+2
| | | | | | | Cygwin sits on top of Windows and so can use explicit symbol export and import markup too. Co-Author: Yaakov Selkowitz <yselkowitz@cygwin.com>
* ExternalData: Add option to disable use of symlinksBrad King2015-05-224-0/+16
| | | | | | | | | Add an ExternalData_NO_SYMLINKS to enable use of copies instead of symlinks to populate the real data files behind a DATA{} reference. This will be useful on UNIX-like systems when the underlying filesystem does not actually support symbolic links. Suggested-by: Matt McCormick <matt.mccormick@kitware.com>
* ExternalData: Add option to recursively match under directoriesBrad King2015-03-2711-0/+16
| | | | | | Extend the ``DATA{Dir/,...}`` syntax with a new ``RECURSE:`` option to enable recursive matching of associated files. This will allow an entire directory tree of data to be referenced at once.
* ExternalData: Add support for custom algorithm-to-URL mappingBrad King2015-02-256-0/+16
| | | | | | | | | Allow URL templates to contain a %(algo:<key>) placeholder that is replaced by mapping the canonical hash algorithm name through a map defined by the <key>. Extend the Module.ExternalData test to cover the behavior. Extend the RunCMake.ExternalData test to cover error cases.