Commit Graph

4967 Commits

Author SHA1 Message Date
Brad King
d3b981ab3e Merge topic 'ipo-per-lang'
ba247cca IPO: Consider support for each language separately

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !964
2017-06-15 10:05:02 -04:00
Brad King
c8b4da5838 Merge topic 'vs-dotnet-custom-reference-tags'
07ec212a VS: add target property VS_DOTNET_REFERENCEPROP_<refname>_TAG_<tagname>

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !960
2017-06-14 12:43:34 -04:00
Brad King
ba247ccaba IPO: Consider support for each language separately
We only define `INTERPROCEDURAL_OPTIMIZATION` behavior for C, CXX, and
Fortran languages.  Do not try to enable support for other languages.
Furthermore, each language builds with a different compiler, so check
for support by CMake and the compiler for each language independently.

Fixes: #16944
2017-06-14 10:36:57 -04:00
Sebastian Holtermann
7f68ad6612 Autogen: Tests: Disable some tests on non ASCII build paths 2017-06-13 16:51:33 +02:00
Michael Stürmer
07ec212ae8 VS: add target property VS_DOTNET_REFERENCEPROP_<refname>_TAG_<tagname>
Fixes: #16689
2017-06-13 10:46:31 -04:00
Sebastian Holtermann
38e3fc4bdd Autogen: Tests fix for utf8 paths 2017-06-12 21:54:45 +02:00
Brad King
00b91b1530 Merge topic 'execute_process-pipeline-results'
d6051ca3 execute_process: Add option to get results of every child

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !702
2017-06-12 10:22:12 -04:00
Brad King
99153a9eb6 Merge topic 'cuda-compiler-launcher'
414438b2 CUDA: Add option to run the compiler through launcher tools

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !949
2017-06-12 10:20:58 -04:00
Adam Weisi
d6051ca39e execute_process: Add option to get results of every child
Add a `RESULTS_VARIABLE` option to get the results of all children
in a pipeline of one or more `COMMAND`s.
2017-06-10 08:03:06 -04:00
Brad King
414438b2fb CUDA: Add option to run the compiler through launcher tools
Add a `CUDA_COMPILER_LAUNCHER` target property like those added for C
and CXX by commit v3.4.0-rc1~450^2 (Add options to launch the compiler
through tools like ccache or distcc, 2015-06-04).

Fixes: #16953
2017-06-09 12:34:39 -04:00
Brad King
82be694c7a file(GENERATE): Add policy CMP0070 to define relative path behavior
Previously `file(GENERATE)` did not define any behavior for relative
paths given to the `OUTPUT` or `INPUT` arguments.  Define behavior
consistent with CMake conventions and add a policy to provide
compatibility for projects that relied on the old accidental behavior.

Fixes: #16786
2017-06-09 10:38:43 -04:00
Brad King
69050f4d16 Tests: Use full output paths in file(GENERATE) calls
We don't define behavior for relative paths to the OUTPUT argument.
Fix our tests to use full paths.
2017-06-08 13:31:33 -04:00
Florian Maushart
e7869e80ce cmake_host_system_information: Add more keywords
Extend the `cmake_host_system_information()` command to add processor
identification keywords.
2017-06-05 13:51:30 -04:00
Brad King
2d3d88f3bb Merge topic 'GoogleTest-disabled-tests'
92bbb706 GoogleTest: Add support for disabled tests

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Craig Scott <craig.scott@crascit.com>
Merge-request: !920
2017-06-05 10:16:39 -04:00
Chuck Atkins
92bbb70695 GoogleTest: Add support for disabled tests
Fixes: #10612
2017-06-05 10:11:08 -04:00
Brad King
00639f2d5d Merge topic 'test-GNUInstallDirs-FreeBSD'
913736f1 Tests: Fix RunCMake.GNUInstallDirs on BSD platforms

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !921
2017-06-05 09:42:36 -04:00
Brad King
913736f17d Tests: Fix RunCMake.GNUInstallDirs on BSD platforms
The `GNUInstallDirs` module has different defaults on BSD platforms.
Update the test expected output to account for the difference.

Fixes: #16887
2017-06-02 16:26:30 -04:00
Brad King
6a42b9609f Merge topic 'ninja-mingw'
82badfff Ninja: Fix CMP0058 on MinGW
c5ff50fc Tests: Fix CustomCommandByproducts regex for phony rules

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !919
2017-06-01 14:00:58 -04:00
Brad King
860db083ca Merge topic 'add-common-record-features-macros'
3c1ecb52 Intel: Fix missing C std default for 12.0 <= ver < 12.1
f70b0bb3 SunPro: Make sure all known versions get CXX98 defaults
220ede74 GNU: Fix language defaults for 3.4
a40e6ba8 Clang: Fix language defaults for 2.1
9b112a84 Compilers: Port to use default cmake_record_lang_compile_features macros
37221529 MSVC: Add empty definitions for std compile options
e556f1b9 CompileFeatures: Makes tests work with meta-feature only
20ffa147 Tests: Allow test macro to take no executable arguments
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !833
2017-06-01 13:40:47 -04:00
Brad King
c5ff50fc19 Tests: Fix CustomCommandByproducts regex for phony rules
Update the regex to match phony rules that have no inputs.
2017-05-31 11:48:02 -04:00
Brad King
52d0983a88 Tests: Skip BootstrapTest if testing external CMake
If we are not actually building CMake then we should not run the
`BootstrapTest` (which builds CMake).
2017-05-31 10:11:51 -04:00
Brad King
de16ff3e58 Merge topic 'ninja-mingw'
6a2f8335 Ninja: Fix escaping of path to depfile
781eb380 Tests: Fix VSResource test on MinGW with Ninja and a space in the path

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !911
2017-05-31 08:55:44 -04:00
Brad King
926ef3ee03 Merge topic 'fix-XCTest-build-config'
be55f069 Tests: Fix XCTest build configuration

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !907
2017-05-31 08:53:39 -04:00
Brad King
781eb380f4 Tests: Fix VSResource test on MinGW with Ninja and a space in the path 2017-05-30 15:30:40 -04:00
Brad King
f34f7815e3 Tests: Fix Qt5Autogen test on Xcode
Fix the `mocPlugin` project to provide `mocPlugin.xcodeproj` instead of
`Project.xcodeproj` so that the `try_compile` project name matches.
Also search in the `Debug` subdirectory of the `try_compile` build tree
for the resulting binaries, to work with multi-config generators.
2017-05-30 10:09:37 -04:00
Brad King
be55f069f9 Tests: Fix XCTest build configuration
Build the test binaries with the same configuration in which they will
be tested instead of the default Debug configuration.  This fixes the
test when run in a Release configuration.
2017-05-30 09:44:13 -04:00
Chuck Atkins
e556f1b909 CompileFeatures: Makes tests work with meta-feature only 2017-05-29 13:51:45 -04:00
Chuck Atkins
20ffa14708 Tests: Allow test macro to take no executable arguments 2017-05-29 12:34:28 -04:00
Brad King
d375618921 Merge topic 'sunpro-std-flags'
370d0d25 SunPro: update flags used for CMake itself
f1f21e30 SunPro: set -library=stlport as standard compile option for C++98
9316120c SunPro: add standard compile option for C++03
783fbb77 Tests: Compile entire Plugin test with the same language standard

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !879
2017-05-28 09:22:33 -04:00
Brad King
783fbb77e7 Tests: Compile entire Plugin test with the same language standard
Set `CMAKE_CXX_STANDARD` early so that both KWSys and our test code
build with the same language standard.  This is important on compilers
that have incompatible standard libraries.
2017-05-26 13:26:39 -04:00
Sebastian Holtermann
e3e692caea Autogen: Test adaptions 2017-05-26 15:27:17 +02:00
Sebastian Holtermann
dbda590628 Autogen: Per-config file suffixes. New AUTOGEN_BUILD_DIR target property.
Closes #14760
Closes #14313
2017-05-26 15:27:17 +02:00
Brad King
def409af76 Merge topic 'FindDoxygen-add-docs-function'
59ffabfe Improve Doxygen support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !684
2017-05-25 15:14:53 -04:00
Brad King
d6df882add Merge topic 'find_dependency-improvements'
ab358d6a Improve find_dependency argument handling

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !872
2017-05-25 15:13:47 -04:00
Brad King
a9b11235a8 Merge topic 'find_package-shorter-message'
d0b9d1cc find_package: shorten output for missing package in config mode
d9df805f cmFindPackageCommand: Split condition to improve readability

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !851
2017-05-25 15:13:03 -04:00
Alex Turbov
59ffabfeec Improve Doxygen support
Except Graphviz's `dot` Doxygen may use few other utilities like
`mscgen` (Message Sequence Chart) and `dia` (Diagram Editor).

Now this module allows to manage Doxygen settings from `CMakeLists.txt`
and forget about `Doxyfile`s. Also it provides a helper function
to add a target to generate documentation: `doxygen_add_docs`.

Implement code review notes:

- Introduce `COMPONENTS` to find: `dot`, `mscgen` and `dia`;
- Deprecate variables `DOXYGEN_SKIP_DOT`, `DOXYGEN_EXECUTABLE`,
  `DOXYGEN_DOT_EXECUTABLE`, `DOXYGEN_DOT_FOUND` in favour of
  `doxygen_add_docs ` usage instead;
- Properly handle paths to found tools in Windows;
- Prevent adding a custom target if Doxygen was not really found;
- Introduce exported (executable) targets for found components.

Co-Author: Craig Scott <craig.scott@crascit.com>
2017-05-24 10:15:45 +07:00
Christoph Grüninger
d0b9d1cceb find_package: shorten output for missing package in config mode
If CONFIG or MODULE is given and the package is not REQUIRED,
output a one-liner instead of the full warning.

Update Tests/RunCMake/find_package expected output to match.
2017-05-23 15:27:42 -04:00
Matthew Woehlke
ab358d6a85 Improve find_dependency argument handling
Remove highly specialized and totally positional argument handling in
find_dependency macro, and instead just pass arguments through to
find_package. This gives users access to the full suite of arguments
that find_package knows, and is backward compatible with the old
arguments.

Also, rewrite the unit tests for this, since the old tests are
exclusively focused on testing the old argument handling and are no
longer applicable, and add some success tests (the old tests did not
even set up the CMake state in a way that CMake had any hope of ever
finding the test package).
2017-05-22 13:32:43 -04:00
Brad King
a5ccddf057 FindProtobuf: Rename imported targets to match upstream names
Rename our recently added imported targets to match those provided by
the upstream's CMake-based build.  That way a project using
`find_package(Protobuf)` can get the same target names no matter how
protobuf is found.

Suggested-by: Konstantin Podsvirov <konstantin@podsvirov.pro>
2017-05-22 10:51:55 -04:00
Brad King
8ca236592b Merge topic 'add-findpackage-root-prefix'
fe8f08d2 find_*: Add docs for PackageRoot search path group
57744ca9 find_*: Add tests for PackageRoot search path group
ef3d360a find_*: Add a new PackageRoot search path group

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !796
2017-05-22 10:40:04 -04:00
Brad King
c9d9a3fb39 Merge topic 'pgi-fix-windows'
4eb15824 Windows-PGI: Add platform definitions
a94ae96e Windows-PGI: Adapt default compiler flags
c2c2d366 ImplicitLinkInfo: Add support for PGI on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !794
2017-05-22 10:37:57 -04:00
Christian Pfeiffer
c2c2d36619 ImplicitLinkInfo: Add support for PGI on Windows
Since PGI does not write linker directives into objects, the necessary
libraries have to be parsed from commandline. PGI does however link the
Visual C++ runtime libraries, so they have to be filtered out to ensure
no collision with settings of other languages can occur.
2017-05-20 20:02:43 +02:00
Brad King
6867b882ec Merge topic 'target-depends-per-config'
87a37e64 cmComputeTargetDepends: Avoid nested loops over configurations
5a913794 cmComputeTargetDepends: Avoid computing with empty configuration
70c65572 Tests: Fix RunCMake.CMP0022 tll case for Debug configuration

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !865
2017-05-19 14:20:11 -04:00
Brad King
555f234fa2 Merge topic 'solarisEmptyFileFix'
1bfe3720 Tests: Ensure Solaris linker never sees empty contents

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !860
2017-05-19 14:19:28 -04:00
Brad King
caba59b8fa Merge topic 'solaris_testLibSONAME'
94cd4505 Tests: Make function name not match SONAME

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !868
2017-05-19 14:18:31 -04:00
Brad King
561e5edc3c Merge topic 'FindProtobuf-targets'
37627217 Help: Add notes for topic 'FindProtobuf-targets'
e4e1d194 FindProtobuf: add tests
f29635b6 FindProtobuf: add targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !861
2017-05-19 14:17:50 -04:00
Craig Scott
94cd4505f7 Tests: Make function name not match SONAME
We look for `SONAME` in the output of `readelf` to check whether the
binary contains the field.  Do not provide a symbol that may
accidentally match.

Fixes: #16894
2017-05-18 10:26:09 -04:00
Brad King
70c6557285 Tests: Fix RunCMake.CMP0022 tll case for Debug configuration
The `CMP0022-WARN-tll` case overrides legacy properties set by
`target_link_libraries` so that we can verify that the policy
warning is emitted.  When building in the Debug configuration,
the `_DEBUG` variant of the legacy property is set/checked too.

Fix the test case to override both variants.  Previously it only
passed because `cmComputeTargetDepends::AddInterfaceDepends`
always evaluated dependencies with the "" configuration.
2017-05-18 10:18:50 -04:00
Brad King
44f8f839cb Merge topic 'cpack-archive-per-component-filename'
9e06e97d CPack/Archive: per component filenames support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !859
2017-05-18 09:01:57 -04:00
Brad King
10371cd6dc Merge topic 'source_group-TREE-relative-path'
4716f2be source_group: Restore TREE support for relative paths

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !852
2017-05-18 08:53:51 -04:00