Commit Graph

26126 Commits

Author SHA1 Message Date
Brad King
5c171ca898 Restore unconditional use of "standard" include directories
`CMAKE_<LANG>_STANDARD_INCLUDE_DIRECTORIES` is meant to unconditionally
add explicitly specified include directories to compile lines.  In
commit 5f34bdc7f9 (cmLocalGenerator: Refactor
`GetIncludeDirectoriesImplicit` method, 2019-01-25, v3.14.0-rc1~65^2~1)
a condition was accidentally added to exclude implicit include
directories.  Drop that condition.

Fixes: #18936
2019-02-18 17:10:07 -05:00
Brad King
9502276f82 Prefix implicit include directories with sysroot on construction
Since commit 7cd65c97fa (Add CMAKE_SYSROOT variable to set --sysroot
when cross compiling., 2013-04-13, v3.0.0-rc1~342^2) we have prefixed
the value of `CMAKE_SYSROOT` to implicit include directories.  This was
done because we hard-coded `/usr/include` as an implicit include
directory without accounting for the sysroot.  Instead we should prefix
the hard-coded paths when they are constructed.  Update the
`Platform/UnixPaths` module to do this as `Platform/Darwin` already
does.

Since commit 5990ecb741 (Compute implicit include directories from
compiler output, 2018-12-07, v3.14.0-rc1~108^2) the values of the
`CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES` variables are computed from
a real compiler invocation so they already account for the sysroot
prefix.  In commit 6fc3382944 (Update logic for sysroot in detected
implicit include directories, 2019-02-13, v3.14.0-rc2~6^2) we attempted
to apply the prefix conditionally, but that is incorrect because the
compiler's real implicit include directories are not all under the
sysroot.  Instead assume that all implicit include directories in
`CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES` already have the sysroot
prefix if needed.  Code that constructs the value must be responsible
for that because it is the only place that knows.
2019-02-18 17:09:26 -05:00
Saleem Abdulrasool
c489c3e715 Ninja: remove duplicate local variable (NFC)
Remove the second reference to the generator target.
2019-02-18 12:09:20 -08:00
Saleem Abdulrasool
c048cb75fc Ninja: add properties for Swift partial module and doc
When building a swift object, we emit a partial swiftmodule and swiftdoc
that must be merged at the end.  However, in order to do that, we need
to enumerate the swiftmodules and swiftdocs.  As a result, the path must
be known to CMake.  Rather than hardcoding the rules into CMake, create
a source property that we can query.  This will allow us to create a
final placeholder to emit the merge rule.

Issue: #18800
2019-02-18 11:15:47 -08:00
Brad King
0923246b2e Merge topic 'require-xcode-5'
afb325018e Xcode: Require at least Xcode 5

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2975
2019-02-18 09:20:16 -05:00
Brad King
03e10384ec Merge topic 'delete_copy_assign'
ae5e97a005 Delete some default constructors and assignment operators

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2968
2019-02-18 09:05:30 -05:00
Kitware Robot
f1235fd37d CMake Nightly Date Stamp 2019-02-18 00:01:19 -05:00
Kitware Robot
8ec1942f62 CMake Nightly Date Stamp 2019-02-17 00:01:05 -05:00
Gregor Jasny
afb325018e Xcode: Require at least Xcode 5 2019-02-16 15:20:39 +01:00
Kitware Robot
657b30905a CMake Nightly Date Stamp 2019-02-16 00:01:07 -05:00
Artur Ryt
706b93fa55 Modernize: C-arrays and loops over them
It replaces C arrays with deduced std::initializer_lists
or std::array what makes enables for-loop over them.
2019-02-15 23:40:30 +01:00
Brad King
820424d95d Merge topic 'systools-cleanup'
bd20cc29a2 cmSystemTools: Remove redundant cmCopyFile() and Split()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2966
2019-02-15 10:04:49 -05:00
Kyle Edwards
160735c479 Merge topic 'remove_return_void'
30faf72625 Remove return from void function

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2969
2019-02-15 10:02:10 -05:00
Brad King
f2dc10d55c Merge topic 'ninja-swift-library-name'
157570b5a2 Add placeholder for Swift's library name

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2902
2019-02-15 10:00:21 -05:00
Brad King
3c9c91a360 Merge topic 'update-kwsys'
f510aafbfc Merge branch 'upstream-KWSys' into update-kwsys
a930de85d8 KWSys 2019-02-14 (e270ce9f)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2967
2019-02-15 09:59:40 -05:00
Vitaly Stakhovsky
bd20cc29a2 cmSystemTools: Remove redundant cmCopyFile() and Split() 2019-02-15 09:52:29 -05:00
Brad King
e6897c72e7 CMake 3.14.0-rc2 2019-02-15 07:46:43 -05:00
Brad King
3bc2fb55b4 Merge topic 'vs2017-sdk81'
5c26e3c5e3 VS: Fix validation of Windows 8.1 SDK

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Dedmen Miller <dedmenmiller@googlemail.com>
Merge-request: !2962
2019-02-15 07:29:05 -05:00
Albert Astals Cid
ae5e97a005 Delete some default constructors and assignment operators
They are unused, but if someone used them they would lead to
problems since they would copy the internal raw pointers
and the destructor would cause double delete
2019-02-15 07:25:47 -05:00
Brad King
3411c81575 Merge topic 'try_compile-expand-compile-defs'
cde2596a19 try_compile: Restore expansion of ;-list in COMPILE_DEFINITIONS

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2965
2019-02-15 07:19:51 -05:00
Brad King
113a395ee7 Merge branch 'try_compile-expand-compile-defs' into release-3.14
Merge-request: !2965
2019-02-15 06:47:59 -05:00
Brad King
cde2596a19 try_compile: Restore expansion of ;-list in COMPILE_DEFINITIONS
The quoting added by commit 8c5221fb1f (try_compile: Preserve special
characters in COMPILE_DEFINITIONS, 2019-01-21, v3.14.0-rc1~108^2~3)
broke the case that the `COMPILE_DEFINITIONS` value contains a `;`.
Without the quoting the `;` would be generated literally in an unquoted
argument in the test `CMakeLists.txt` file and would then be expanded.
With quoting the `;` is preserved, which is not the old behavior.

Fix this by expanding the `;`-list ahead of time.  Add test cases for
behavior with both `#` and `;`.

This was noticed with the PGI compiler where we set
`CMAKE_CXX*_STANDARD_COMPILE_OPTION` to values like `--c++17;-A`.  The
symptom had also been observed while preparing commit ef8f237686
(ParseImplicitIncludeInfo: add SunPro Fortran and PGI compiler, Cray
fix, 2019-01-29, v3.14.0-rc1~26^2~2) but was not recognized at the time
as a regression.  Revert the workaround added by that commit.

Fixes: #18919
2019-02-15 06:21:19 -05:00
Kitware Robot
a2a903fe42 CMake Nightly Date Stamp 2019-02-15 00:01:08 -05:00
Albert Astals Cid
30faf72625 Remove return from void function 2019-02-14 17:34:06 +01:00
Brad King
9d3710affe Merge branch 'vs2017-sdk81' into release-3.14
Merge-request: !2962
2019-02-14 11:24:16 -05:00
Brad King
f510aafbfc Merge branch 'upstream-KWSys' into update-kwsys
* upstream-KWSys:
  KWSys 2019-02-14 (e270ce9f)
2019-02-14 10:55:44 -05:00
Brad King
0069825f50 Merge topic 'fortran-submodule-names'
d80ecba5c2 Fortran: Fix submodule file names across compilers
72057d9c15 Fortran: Thread compiler id through to internal Fortran parser
7ae329e2ed Fortran: Factor out .mod and .smod file name construction

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Michael Hirsch, Ph.D. <michael@scivision.co>
Merge-request: !2958
2019-02-14 10:25:15 -05:00
Brad King
2f51f281a8 Merge branch 'fortran-submodule-names' into release-3.14
Merge-request: !2958
2019-02-14 10:24:43 -05:00
Brad King
d80ecba5c2 Fortran: Fix submodule file names across compilers
The naming convention for submodule files varies across compilers.  Add
a table to the compiler information modules and thread the information
through to the Fortran module dependency parser.  Fill out the table for
compiler ids known to support Fortran submodules.

Fixes: #18746
2019-02-14 10:23:02 -05:00
Brad King
72057d9c15 Fortran: Thread compiler id through to internal Fortran parser 2019-02-14 10:23:02 -05:00
Brad King
7ae329e2ed Fortran: Factor out .mod and .smod file name construction 2019-02-14 10:23:02 -05:00
Brad King
50ba2f019b Merge topic 'fix-legacy-implicit-includes'
6fc3382944 Update logic for sysroot in detected implicit include directories
2ad14ef4ea cmAlgorithms: Add cmHasPrefix to match existing cmHasSuffix
557b2d6e65 Fix regression in -I/usr/include exclusion logic
017598a444 macOS: Fix addition of <sdk>/usr/include to default implicit include dirs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2957
2019-02-14 10:14:47 -05:00
Brad King
fd74eba140 Merge topic 'fix-pointer-truncation'
76a5ac2100 cmListFileLexer: Add missing include to avoid possible pointer truncation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2956
2019-02-14 10:14:08 -05:00
Brad King
49a53cac87 Merge topic 'update-kwsys'
ec13bd5230 Tests: Disable test that builds KWSys if not also building CMake
ded4bc136e Merge branch 'upstream-KWSys' into update-kwsys
f3999a21c8 KWSys 2019-02-12 (44676809)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2953
2019-02-14 10:11:54 -05:00
Brad King
5c26e3c5e3 VS: Fix validation of Windows 8.1 SDK
The check added by commit 0a29a31161 (VS2017: Verify Windows 8.1 SDK
before using it, 2017-04-25, v3.8.1~2^2) used the wrong path to
`windows.h` within the SDK, leading to it never being detected.

Fixes: #18923
2019-02-14 08:25:26 -05:00
Kitware Robot
5b3683ec8a CMake Nightly Date Stamp 2019-02-14 00:01:06 -05:00
Saleem Abdulrasool
157570b5a2 Add placeholder for Swift's library name
This allows us to set the proper link name for the Swift library
(soname).  Because this needs to be passed to the object being compiled,
we need to create a new placeholder so that it can be sent along to the
frontend.  Default to the target name unless it is explicitly provided.
2019-02-13 09:25:29 -08:00
Brad King
9f351b93ab Merge branch 'fix-pointer-truncation' into release-3.14
Merge-request: !2956
2019-02-13 10:28:02 -05:00
Zsolt Parragi
76a5ac2100 cmListFileLexer: Add missing include to avoid possible pointer truncation
The `cmsys/Enconding.h` include had a typo in its surrounding ifdef,
possibly causing a missing function declaration (`cmsysEncoding_DupToWide`).
As this is C code, this resulted in the code compiling, but with a truncated
return value, possibly causing crashes.
2019-02-13 10:22:59 -05:00
Brad King
63efce507b Merge topic 'names'
fc8b90af2c Create and use `cmGeneratorTarget::Names`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2936
2019-02-13 10:17:55 -05:00
Brad King
8914d4317a Merge topic 'systools-stdstring2'
080a79ca4a cmSystemTools: More methods accept `std::string` params

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2952
2019-02-13 10:17:08 -05:00
Brad King
264128469d Merge topic 'cmcurses-fix-solaris-lambda-warning'
c28abdb5ac cmCursesMainForm: Fix lambda return type deducing warning

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2955
2019-02-13 10:16:31 -05:00
Brad King
30783addc1 Merge branch 'fix-legacy-implicit-includes' into release-3.14
Merge-request: !2957
2019-02-13 10:05:48 -05:00
Brad King
6fc3382944 Update logic for sysroot in detected implicit include directories
Since commit 5990ecb741 (Compute implicit include directories from
compiler output, 2018-12-07, v3.14.0-rc1~108^2) the values of the
`CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES` variables are computed from
a real compiler invocation.  In this case the paths under the sysroot
should already have the sysroot prefix so we should no longer have to
add the sysroot prefix.  However, it is also possible for project code
to add its own paths to `CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES`
without the sysroot prefix and expect the historical addition of the
sysroot prefix to be preserved.

Try to account for both cases by conditionally adding the sysroot prefix
on implicit include directories that do not already have it.
2019-02-13 10:03:56 -05:00
Brad King
2ad14ef4ea cmAlgorithms: Add cmHasPrefix to match existing cmHasSuffix 2019-02-13 09:52:20 -05:00
Brad King
557b2d6e65 Fix regression in -I/usr/include exclusion logic
The change in commit 15ad830062 (Refactor exclusion of -I/usr/include to
avoid per-language values, 2019-01-21, v3.14.0-rc1~108^2~4) caused the
exclusion to apply to Fortran, but it was only meant for C, CXX, and
CUDA.  The purpose of the change was to prepare for the value of
`CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES` to be computed from the
actual compiler instead of hard-coded.  We need to preserve exclusion of
`-I/usr/include` if the compiler has any implicit include directory that
looks intended to replace it, e.g. `<sdk>/usr/include` on macOS.

Fixes: #18914
2019-02-13 09:52:20 -05:00
Brad King
122946def9 Merge topic 'genex-GENEX_EVAL-fix-recursion'
e429e9af42 genex: Fix erroneous handling of recursion for $<GENEX_EVAL:>

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: yrHeTaTeJlb <jjj.bo@yandex.ru>
Merge-request: !2954
2019-02-13 08:40:04 -05:00
Brad King
1c4570e22e Merge branch 'genex-GENEX_EVAL-fix-recursion' into release-3.14
Merge-request: !2954
2019-02-13 08:37:38 -05:00
Marc Chevrier
e429e9af42 genex: Fix erroneous handling of recursion for $<GENEX_EVAL:>
Fixes: #18894
2019-02-13 08:37:02 -05:00
Kitware Robot
99ec095d9d CMake Nightly Date Stamp 2019-02-13 00:01:06 -05:00
Artur Ryt
c28abdb5ac cmCursesMainForm: Fix lambda return type deducing warning
It was issued by sparc compiler on Solaris system
See !2947
2019-02-12 19:24:53 +01:00
Brad King
ded4bc136e Merge branch 'upstream-KWSys' into update-kwsys
* upstream-KWSys:
  KWSys 2019-02-12 (44676809)
2019-02-12 08:35:12 -05:00
Brad King
9d2ab63aaf Merge topic 'clangcl-fixes'
091afa7342 Tests: Teach tests when to treat clang-cl as MSVC
006768903c Work around clang-cl breakage on make_unique/std::forward
d625dfcdf9 Avoid compiling CMake itself as C++17 with Clang's MSVC ABI

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2573
2019-02-12 08:31:00 -05:00
Brad King
20afd497c9 Merge topic 'progress-stdstring'
950c099d83 cmake: Progress functions use `std::string` param

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2948
2019-02-12 08:30:13 -05:00
Brad King
a7a8571933 Merge topic 'modernize-cmCursesMainForm'
f6291eee25 cmCursesMainForm: Modernize with STL and ranged-for loops

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2947
2019-02-12 08:29:08 -05:00
Brad King
c0ba467d2d Merge topic 'cmCTestRunTest-compress'
948c55857e cmCTestRunTest: Remove duplicated compression logic

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2946
2019-02-12 08:28:24 -05:00
Kitware Robot
64ae72c52a CMake Nightly Date Stamp 2019-02-12 00:01:06 -05:00
Vitaly Stakhovsky
080a79ca4a cmSystemTools: More methods accept std::string params 2019-02-11 18:11:59 -05:00
Saleem Abdulrasool
fc8b90af2c Create and use cmGeneratorTarget::Names
Rather than taking a number of out parameters for the various names,
create a structure that is reused for both `GetLibraryNames` and
`GetExecutableNames`.  Replace uses according to the new interface.
2019-02-11 10:44:24 -08:00
Vitaly Stakhovsky
950c099d83 cmake: Progress functions use std::string param 2019-02-11 10:32:43 -05:00
Zsolt Parragi
006768903c Work around clang-cl breakage on make_unique/std::forward
Clang on Windows with the MSVC ABI produces link errors of the
form `unresolved std::_Iosb<int>::{app,_Openmode} in ...`.
Use a temporary variable to forward as lvalue rather than rvalue
to work around the problem.
2019-02-11 15:04:28 +01:00
Zsolt Parragi
d625dfcdf9 Avoid compiling CMake itself as C++17 with Clang's MSVC ABI
GUID functions in ATL cause compilation errors with this compiler.
Add the offending case to our check for C++17 support so that it
is not used by default when it does not work.
2019-02-11 15:04:19 +01:00
Brad King
8a1d25afdf Merge topic 'ctest-exit-code-int64'
440b08e4f0 CTest: Represent process exit codes as 64-bit signed integer

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2944
2019-02-11 08:08:56 -05:00
Brad King
4b37b4f1bb Merge topic 'modernize-for-loops'
01b2d6ab74 Modernize: Use ranged for-loops when possible
15bdbec017 cmAlgorithms: Make cmRange advance/retreat safe for rvalues

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
Merge-request: !2901
2019-02-11 08:08:22 -05:00
Brad King
5651568d14 Merge topic 'ghs-updates'
bcd99fac60 GHS: Document usage of GHS_NO_SOURCE_GROUP_FILE

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2943
2019-02-11 07:45:23 -05:00
Brad King
d9ddb30e92 Merge topic 'fix-exclude-dir-with-iface'
f87e724e8c Fix EXCLUDE_FROM_ALL on directory with an interface library

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2937
2019-02-11 07:44:40 -05:00
Kitware Robot
56c2eab1e2 CMake Nightly Date Stamp 2019-02-11 00:01:16 -05:00
Artur Ryt
f6291eee25 cmCursesMainForm: Modernize with STL and ranged-for loops 2019-02-10 19:07:50 +01:00
Regina Pfeifer
948c55857e cmCTestRunTest: Remove duplicated compression logic 2019-02-10 15:47:15 +01:00
Kitware Robot
e7d319714d CMake Nightly Date Stamp 2019-02-10 00:01:05 -05:00
Kitware Robot
2f2295ec9e CMake Nightly Date Stamp 2019-02-09 00:01:07 -05:00
Zsolt Parragi
440b08e4f0 CTest: Represent process exit codes as 64-bit signed integer
Exit code constants on Windows, such as `STATUS_NO_MEMORY` do not fit in
a 32-bit signed integer type.  They do fit in an unsigned 32-bit type,
but for compatibility with UNIX semantics we treat exit codes as signed.
Use a 64-bit signed integer to handle both.
2019-02-08 14:49:20 -05:00
Brad King
88031dd09a Merge branch 'ghs-updates' into release-3.14
Merge-request: !2943
2019-02-08 14:02:14 -05:00
Brad King
3b58b647ae Merge branch 'fix-exclude-dir-with-iface' into release-3.14
Merge-request: !2937
2019-02-08 14:02:03 -05:00
Fred Baksik
bcd99fac60 GHS: Document usage of GHS_NO_SOURCE_GROUP_FILE
-- Also change variable name to CMAKE_GHS_NO_SOURCE_GROUP_FILE
2019-02-08 13:07:00 -05:00
Kyle Edwards
18b0329a81 Merge topic 'cmake_parse_arguments-keywords_missing_values'
5228432b45 cmake_parse_arguments: add KEYWORDS_MISSING_VALUES
8e746db6e1 cmake_parse_arguments: Factor out part of implementation for re-use

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2910
2019-02-08 12:14:46 -05:00
Brad King
89ca5d7fdc Merge topic 'message-stdstring'
82edd98300 cmSystemTools: MessageCallback and Message() accept std::string argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2929
2019-02-08 08:49:35 -05:00
Brad King
bf12794504 Merge topic 'getreqdef'
00ba28ffd0 cmMakefile::GetRequiredDefinition: return const std::string&

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2930
2019-02-08 08:48:51 -05:00
Brad King
9783825de5 Merge topic 'runsinglecommand'
65baaa0e37 cmSystemTools::RunSingleCommand: Accept std::string argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2927
2019-02-08 08:47:56 -05:00
Brad King
f87e724e8c Fix EXCLUDE_FROM_ALL on directory with an interface library
Since commit dc6888573d (Pass EXCLUDE_FROM_ALL from directory to
targets, 2019-01-15, v3.14.0-rc1~83^2) we automatically forward the
`EXCLUDE_FROM_ALL` to targets as they are created.  This regressed
support for interface libraries on which the property is not allowed.

Skip forwarding the `EXCLUDE_FROM_ALL` property for interface libraries.
It is not needed on them because they do not participate in the
generated build system anyway.

Fixes: #18896
2019-02-08 08:17:48 -05:00
Kitware Robot
3f0a5b3fe8 CMake Nightly Date Stamp 2019-02-08 00:01:07 -05:00
Artur Ryt
01b2d6ab74 Modernize: Use ranged for-loops when possible
Replaced most manual `const_iterator`-based loops and some
reverse-iterator loops with range loops.

Fixes: #18858
2019-02-07 22:39:05 +01:00
Artur Ryt
15bdbec017 cmAlgorithms: Make cmRange advance/retreat safe for rvalues
In rvalue context these functions have to return cmRange
by copy instead of reference to temporary object

It allows to use ranged-for over cmMakeRange(xxx).advance(yyy)
2019-02-07 22:38:12 +01:00
Vitaly Stakhovsky
82edd98300 cmSystemTools: MessageCallback and Message() accept std::string argument 2019-02-07 13:41:27 -05:00
Brad King
41802ef35d Merge topic 'prefer-front-back-over-begin-rbegin'
f3534386b5 Prefer front/back/data over dereferencing begin/rbegin iter

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
Merge-request: !2914
2019-02-07 13:30:31 -05:00
Torsten Robitzki
5228432b45 cmake_parse_arguments: add KEYWORDS_MISSING_VALUES
Add KEYWORDS_MISSING_VALUES output variable to cmake_parse_arguments() to
allow to detect keywords that received no values.

Fixes: #18706
2019-02-07 12:59:10 -05:00
Vitaly Stakhovsky
00ba28ffd0 cmMakefile::GetRequiredDefinition: return const std::string& 2019-02-07 07:35:16 -05:00
Brad King
7df10748e2 Merge topic 'xcode-stdlib-flags'
8af334f5ba Xcode: Derive stdlib from CXX flags

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2919
2019-02-07 06:45:42 -05:00
Brad King
f657bcbd48 Merge branch 'xcode-stdlib-flags' into release-3.14
Merge-request: !2919
2019-02-07 06:44:19 -05:00
Gregor Jasny
8af334f5ba Xcode: Derive stdlib from CXX flags
Closes: #18396
2019-02-07 06:43:51 -05:00
Brad King
f60ec9e63a Merge topic 'vs-csharp-nowarn-numbers'
822697996e VS: Fix nowarn compiler option to accept warning numbers.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2923
2019-02-07 06:42:30 -05:00
Brad King
f835526d8f Merge branch 'vs-csharp-nowarn-numbers' into release-3.14
Merge-request: !2923
2019-02-07 06:41:22 -05:00
Wil Stark
822697996e VS: Fix nowarn compiler option to accept warning numbers.
Warning disables are transferred to the VS IDE `<NoWarn>` node.

Fixes: #18878
2019-02-07 06:39:45 -05:00
Kitware Robot
c2ffcb3aab CMake Nightly Date Stamp 2019-02-07 00:01:07 -05:00
Torsten Robitzki
8e746db6e1 cmake_parse_arguments: Factor out part of implementation for re-use 2019-02-06 14:46:52 -05:00
Vitaly Stakhovsky
65baaa0e37 cmSystemTools::RunSingleCommand: Accept std::string argument 2019-02-06 11:02:10 -05:00
Artur Ryt
f3534386b5 Prefer front/back/data over dereferencing begin/rbegin iter
Changed for sequenced containers: vector, list, string and array
2019-02-06 10:43:16 -05:00
Brad King
062cfd991f Begin post-3.14 development 2019-02-06 10:11:11 -05:00
Brad King
bf1c2a2593 CMake 3.14.0-rc1 version update 2019-02-06 10:08:35 -05:00
Brad King
d6729505cb Merge topic 'relax_CUDA_RESOLVE_DEVICE_SYMBOLS_constraints'
850ef90a66 CUDA: Honor CUDA_RESOLVE_DEVICE_SYMBOLS for more target types

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !2900
2019-02-06 06:51:30 -05:00
Brad King
4400ac07f7 Merge topic 'autogen_same_name_different_extension'
a28caabf45 Autogen: AUTOMOC support for files with the same name but different extensions
1f802295f2 Autogen: Extend the SameName test with same name but different extension files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2920
2019-02-06 06:50:36 -05:00
Kitware Robot
3a2387bce7 CMake Nightly Date Stamp 2019-02-06 00:01:07 -05:00
Robert Maynard
850ef90a66 CUDA: Honor CUDA_RESOLVE_DEVICE_SYMBOLS for more target types
`CUDA_RESOLVE_DEVICE_SYMBOLS` can be used with shared, module, and
executable target types.  This relaxation is to allow for better
interoperability with linkers that automatically do CUDA device symbol
resolution and have no way to disable it.
2019-02-05 11:09:48 -05:00
Sebastian Holtermann
a28caabf45 Autogen: AUTOMOC support for files with the same name but different extensions
This adds support for AUTOMOC to moc header files with the same but different
extensions (e.g `obj.h`, `obj.hpp`, `obj.hxx`).  If a moc file would appear
multiple times in `mocs_compilation.cpp`, a number suffix is appended
to the name to make it unique.

Closes #14489
2019-02-05 15:51:53 +01:00
Brad King
f47d980f73 Merge topic 'update-kwsys'
9ddbf4c6e6 Merge branch 'upstream-KWSys' into update-kwsys
8372c05472 KWSys 2019-02-05 (65802a20)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2918
2019-02-05 07:49:07 -05:00
Brad King
ab01ce91ee Merge topic 'autogen_single_all_sources_iteration'
b6cf086267 Autogen: Iterate over makefile sources only once
ed0fa784eb cmSystemTools: Let `GetFileFormat` accept a `std::stding const&`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2909
2019-02-05 07:47:14 -05:00
Brad King
c6d679f0d9 Merge topic 'vs-fortran-target-check'
d3d2c3cd49 VS: Fix Fortran target type selection when linking C++ targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2913
2019-02-05 07:36:36 -05:00
Brad King
25e616862d Merge topic 'swift-xcode-10.2'
96dece6dc1 Xcode: Update default Swift language version for Xcode 10.2

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2912
2019-02-05 07:29:59 -05:00
Brad King
9ddbf4c6e6 Merge branch 'upstream-KWSys' into update-kwsys
* upstream-KWSys:
  KWSys 2019-02-05 (65802a20)
2019-02-05 07:20:34 -05:00
Kitware Robot
762a41fd19 CMake Nightly Date Stamp 2019-02-05 00:01:05 -05:00
Brad King
d3d2c3cd49 VS: Fix Fortran target type selection when linking C++ targets
Since commit 2c9f35789d (VS: Decide project type by linker lang as
fallback, 2017-03-30, v3.9.0-rc1~340^2) we consider the linker language
when detecting whether to generate a `.vfproj` or `.vcxproj` file.
However, this could cause C-only projects to become `.vfproj` files if
they link to Fortran projects.  Instead we should consider only the
`LINKER_LANGUAGE` property on the target itself.  This approach is
already used for CSharp.  It allows project code to specify the project
file type for a target with no sources but does not allow linked targets
to affect it.

Fixes: #18687
2019-02-04 14:13:46 -05:00
Brad King
96dece6dc1 Xcode: Update default Swift language version for Xcode 10.2
Xcode 10.2 no longer supports Swift language versions before 4.0.

Fixes: #18871
2019-02-04 13:26:10 -05:00
Brad King
6e91f5d620 Merge topic 'cmSourceFile_refactor'
254b7260f4 cmSourceFile: Check if a file is GENERATED first in the full path computation
cd8a930d61 cmSourceFile: Refactor FindFullPath method
6d407ae439 Use cmSourceFile::GetIsGenerated
2ddf3f4467 cmSourceFile: Add IsGenerated method
b9d44fc350 cmSourceFile: Additional static property strings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2908
2019-02-04 08:04:31 -05:00
Brad King
a5ec7f868f Merge topic 'vs-wince-deployment'
f5d72be57a VS: Fix deployment for WinCE projects

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2907
2019-02-04 07:49:01 -05:00
Brad King
40e1288260 Merge topic 'winrtrefs'
cff026dbc0 VS: Fix WinRT component references
6c21722adb Tests: Fix VSWinStorePhone test with Windows 10 SDK 17763

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2906
2019-02-04 07:47:15 -05:00
Brad King
dc4a2749a5 Merge topic 'set-env-warning'
cb01b8c8ba set: warn of extra arguments after ENV value.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2903
2019-02-04 07:46:29 -05:00
Kitware Robot
d401c10db5 CMake Nightly Date Stamp 2019-02-04 00:01:05 -05:00
Kitware Robot
149402898c CMake Nightly Date Stamp 2019-02-03 00:01:05 -05:00
Sebastian Holtermann
b6cf086267 Autogen: Iterate over makefile sources only once
In QtAutoGen we used to iterate over all makefile source two times to
extract file parameters for moc and uic respectively.  This patch merges both
iterations into one loop. This makes the code easier to understand and likely
faster to execute as well.
2019-02-02 18:42:08 +01:00
Sebastian Holtermann
ed0fa784eb cmSystemTools: Let GetFileFormat accept a std::stding const&
The `const char*` used formerly was converted to a `std::string`
internally anyway.
2019-02-02 18:42:08 +01:00
Sebastian Holtermann
254b7260f4 cmSourceFile: Check if a file is GENERATED first in the full path computation
In `cmSourceFile::FindFullPath` check first if the file is GENERATED before
aborting on `FindFullPathFailed`.  This allows recomputation of the full path
when the GENERATED property was set after the file path was computed with an
error.
2019-02-02 18:39:22 +01:00
Sebastian Holtermann
cd8a930d61 cmSourceFile: Refactor FindFullPath method
Refactors the cmSourceFile::FindFullPath method to
use lambdas.
2019-02-02 18:39:22 +01:00
Kitware Robot
dfec0f4a11 CMake Nightly Date Stamp 2019-02-02 00:01:06 -05:00
Wil Stark
f5d72be57a VS: Fix deployment for WinCE projects
Fixes: #18868
2019-02-01 13:59:09 -05:00
Gilles Khouzam
cff026dbc0 VS: Fix WinRT component references
WinRT components need to be referenced in a similar way that managed
code libraries are referenced.  Validate that the library reference is a
WinRT component and reference it through the project.

Add test coverage for `VS_WINRT_COMPONENT`.  While at it, fix the IOT
reference failing on Win10 SDK 17763 which doesn't include it anymore.

Fixes: #18846
2019-02-01 13:04:52 -05:00
Sebastian Holtermann
6d407ae439 Use cmSourceFile::GetIsGenerated 2019-02-01 17:02:53 +01:00
Sebastian Holtermann
2ddf3f4467 cmSourceFile: Add IsGenerated method
All cmSourceFiles are checked at least once whether they're `GENERATED` or not.
This adds a convenience method `GetIsGenerated` that returns a private
boolean cache variable `IsGenerated`.  `IsGenerated` is updated every time the
`GENERATED` property is written.
2019-02-01 16:55:35 +01:00
Sebastian Holtermann
b9d44fc350 cmSourceFile: Additional static property strings 2019-02-01 16:21:32 +01:00
Brad King
cf3af44af2 Merge topic 'server-normalize-paths'
1c6c2bae28 cmake-server: Normalize build and source directories

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2898
2019-02-01 08:11:19 -05:00
Taylor Holberton
cb01b8c8ba set: warn of extra arguments after ENV value.
Fixes: #18842
2019-02-01 06:10:34 -05:00
Kitware Robot
9512a58238 CMake Nightly Date Stamp 2019-02-01 00:01:07 -05:00
Gregor Jasny
1c6c2bae28 cmake-server: Normalize build and source directories
Fixes: #18862
2019-01-31 12:49:56 -05:00
Brad King
d526327079 Merge topic 'ninja-intel-depfile'
a624a3e1b3 Ninja: Use deps=gcc for Intel Compiler on Windows
f4f3b6b9af Ninja: Detect when ninja is new enough to support a multi-line depfile
699cd03212 Ninja: Drop unnecessary deptype customization infrastructure

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2893
2019-01-31 11:19:38 -05:00
Brad King
29368abde7 Merge topic 'install-strip-macos'
20291e8e72 install: Fix stripping on macOS

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2892
2019-01-31 11:18:40 -05:00
Brad King
1b46f2f12a Merge topic 'xcode-object-dir'
8a7f93d000 Xcode: Fix object library builds with sanitizers enabled
eff9c69740 Xcode: Place object library artifacts outside Objects-normal directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2885
2019-01-31 11:17:40 -05:00
Brad King
ca0310b919 Merge topic 'set-validate-cache-type'
198650ae73 set: warn if CACHE type is not recognized

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2874
2019-01-31 11:16:53 -05:00
Brad King
0933707d5c Merge topic 'autogen-std-bind-to-lambdas'
d6fbd438c4 Autogen: Refactor std::bind calls to lambdas

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2766
2019-01-31 11:15:11 -05:00
Brad King
dc9f4f9eca Merge topic 'tidy-use-equals-default-fix'
3f9822ff6d clang-tidy: Silence use-equals-default warning

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2887
2019-01-31 11:14:21 -05:00
Brad King
fb82385515 Merge topic 'std-string-callback'
1180fc8780 OutputCallback: Accept std::string argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: vvs31415 <vstakhovsky@fastmail.com>
Merge-request: !2891
2019-01-31 11:13:34 -05:00
Brad King
24bee427b5 Merge topic 'update-kwsys'
a37614667d Configure KWSys to honor CMake_NO_CXX_STANDARD
e3b26f0004 Merge branch 'upstream-KWSys' into update-kwsys
c22e373a30 KWSys 2019-01-30 (ce89cada)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2886
2019-01-31 11:12:27 -05:00
Brad King
9eaa6aa599 Merge topic 'autogen-qt-version-from-dirprops'
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
2019-01-31 10:58:23 -05:00
Brad King
5107a84d46 Merge topic 'restore-install-late-framework'
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
2019-01-31 10:50:38 -05:00
Vitaly Stakhovsky
0779bc9393 ReadListFile: Accept std::string argument 2019-01-31 09:27:54 -05:00
Brad King
8ea30a44d3 Merge topic 'unused-members'
ea9a376085 Remove unused 'class cmake' members

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2895
2019-01-31 09:27:06 -05:00
Brad King
ea9a376085 Remove unused 'class cmake' members
* The `InTryCompile` member has been unused since commit 62854e9966
  (cmState: Move try_compile state from cmake class., 2015-04-11,
  v3.3.0-rc1~196^2~9).

* The `ConvertMessageType` and `IsMessageTypeVisible` members have been
  unused since commit 421012a330 (cmMessenger: Extract from cmake class,
  2016-01-28, v3.7.0-rc1~222^2~1).

* The `InitializeProperties` member has been unused since commit
  de722d7d63 (Move property initialization to cmState., 2015-04-06,
  v3.3.0-rc1~196^2~1).

Co-Author: Vitaly Stakhovsky <vvs31415@gitlab.org>
2019-01-31 07:15:55 -05:00
Kitware Robot
de7eb1a3d0 CMake Nightly Date Stamp 2019-01-31 00:01:06 -05:00
Harry Mallon
20291e8e72 install: Fix stripping on macOS
On macOS the `strip` tool requires special arguments depending on the
type of binary to be stripped.

Fixes: #11367
Fixes: #16499
2019-01-30 22:00:16 +00:00
Brad King
a624a3e1b3 Ninja: Use deps=gcc for Intel Compiler on Windows
Ninja 1.9 supports the depfile format generated by this compiler.
Use `deps = gcc` when the version of Ninja is new enough.

Unfortunately the Intel Compiler for Windows does not properly
escape spaces in paths written to a depfile so if there is a
space in the path we must still fall back to `deps = msvc`.

Fixes: #18855
2019-01-30 14:59:23 -05:00
Brad King
f4f3b6b9af Ninja: Detect when ninja is new enough to support a multi-line depfile
Ninja 1.9 supports the multi-line depfile format generated by the
Intel Compiler for Windows.  Teach the global generator to detect
when the version is new enough to support this.
2019-01-30 14:58:21 -05:00
Brad King
699cd03212 Ninja: Drop unnecessary deptype customization infrastructure
Do not pass `CMAKE_NINJA_DEPTYPE_<LANG>` in place of `deps = gcc`.
If Ninja ever introduces a new dependency type we will likely need
to update CMake for it anyway.
2019-01-30 14:54:35 -05:00
Brad King
eb2c23868f Merge topic 'tidy-use-equals-delete'
b05b778a2d clang-tidy: Use `= delete`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Rejected-by: vvs31415 <vstakhovsky@fastmail.com>
Merge-request: !2848
2019-01-30 14:00:58 -05:00
Regina Pfeifer
1180fc8780 OutputCallback: Accept std::string argument 2019-01-30 18:33:58 +01:00
Regina Pfeifer
3f9822ff6d clang-tidy: Silence use-equals-default warning
clang-tidy 7 has an option to suppress this warning in macros which
defaults to '1'.  Set the option to '0' and silence the warning
explicitly.
2019-01-30 17:51:07 +01:00
Sebastian Holtermann
062d21c36a Autogen: Read the Qt version from directory properties as well
This lets AUTOGEN read the Qt version from directory properties as a fallback
when the Qt version variables are empty or unset.
2019-01-30 11:30:18 -05:00
Taylor Holberton
198650ae73 set: warn if CACHE type is not recognized 2019-01-30 10:47:24 -05:00
Brad King
e3b26f0004 Merge branch 'upstream-KWSys' into update-kwsys
* upstream-KWSys:
  KWSys 2019-01-30 (ce89cada)
2019-01-30 10:36:24 -05:00
Brad King
8a7f93d000 Xcode: Fix object library builds with sanitizers enabled
Using `xcodebuild -enableAddressSanitizer YES ...` causes object files
to be placed in a different directory name.  Xcode provides a
placeholder for this that we can use in `OTHER_LDFLAGS` to reference
object files for linking the dependents of object libraries.  However,
CMake's features for installing and exporting object libraries depend on
knowing the real path with no placeholders.  For these cases, use the
default object directory.  Users will then have to choose between
sanitizers and the installation and export features, but both will work
individually.

Fixes: #16289
2019-01-30 10:28:40 -05:00
Brad King
eff9c69740 Xcode: Place object library artifacts outside Objects-normal directory
The `CONFIGURATION_BUILD_DIR` value in the Xcode project file specifies
where to place the library artifact.  For object libraries we've used
the `Objects-normal` directory to hide away the `.a` that we otherwise
cannot stop Xcode from producing.  The parent of this directory is also
specific to the target and does not vary with Xcode's sanitizer
features, so move the artifact there.

Issue: #16289
2019-01-30 10:28:05 -05:00
Brad King
d685a46f56 Merge topic 'vs-msbuild-arch'
da402a081b VS: Use MSBuild matching toolset host architecture
147d36ce93 Find native build tool after selecting a toolset

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2876
2019-01-30 08:13:04 -05:00
Brad King
c30f9b1cde Merge topic 'functional-callbacks'
8c92db829b MessageCallback: Remove unused bool& argument
bcee24aecc Use `std::function` for callbacks

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: vvs31415 <vstakhovsky@fastmail.com>
Acked-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
Merge-request: !2872
2019-01-30 08:10:27 -05:00
Brad King
bcec7d0778 Merge topic 'copyfile-stdstring'
c31b6e616d cmSystemTools: copy file member functions accept std::string params

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2877
2019-01-30 08:08:59 -05:00
Brad King
95210d027a macOS: Restore compatibility for setting FRAMEWORK after install()
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
2019-01-30 08:00:06 -05:00
Kitware Robot
d21769d5dd CMake Nightly Date Stamp 2019-01-30 00:01:07 -05:00
Artur Ryt
d6fbd438c4 Autogen: Refactor std::bind calls to lambdas 2019-01-29 20:51:12 +01:00
Regina Pfeifer
b05b778a2d clang-tidy: Use = delete 2019-01-29 14:09:21 -05:00
Brad King
d75fec5a88 Merge topic 'tidy-use-equals-default'
094f01d0f0 cleanup: Prefer compiler provided special member functions
55671b41d2 clang-tidy: Use `= default`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Brad King <brad.king@kitware.com>
Merge-request: !2841
2019-01-29 14:07:24 -05:00
Regina Pfeifer
8c92db829b MessageCallback: Remove unused bool& argument 2019-01-29 16:35:53 +01:00
Vitaly Stakhovsky
c31b6e616d cmSystemTools: copy file member functions accept std::string params
Cleaned up `c_str()`s.
`cmSystemTools::CopyFileIfDifferent()` removed as redundant.
2019-01-29 10:34:18 -05:00
Regina Pfeifer
bcee24aecc Use std::function for callbacks 2019-01-29 16:32:52 +01:00
Brad King
9620cb935a Merge topic 'add_consistent_verbose_build_flag'
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
2019-01-29 09:19:39 -05:00
Brad King
60c06620a6 Merge topic 'cmoutputconverter-simplify'
b6a957c969 cmOutputConverter: move ConvertToRelativePath to cmStateDirectory.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2831
2019-01-29 09:18:42 -05:00
Brad King
90ac5e6384 Merge topic 'message-stdstring'
186d9b083d cmSystemTools::Message: Add overload accepting std::string

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2869
2019-01-29 09:17:51 -05:00
Brad King
e7be5638a0 Merge topic 'ftc-string'
2fc69ba0b3 cmFileTimeComparison: use std::string arguments

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2868
2019-01-29 09:16:58 -05:00
Brad King
da402a081b VS: Use MSBuild matching toolset host architecture
VS 2017 and VS 2019 provide `amd64/MSBuild.exe` variants next to
their `MSBuild.exe` tools.  When the 64-bit host toolchain is
selected (e.g. via `host=x64`), select the 64-bit MSBuild too.

Fixes: #18219
2019-01-29 09:11:00 -05:00
Brad King
147d36ce93 Find native build tool after selecting a toolset
This will allow `CMAKE_GENERATOR_TOOLSET` to influence build tool
selection.

For reference, commit f8cb9944a1 (Find native build tool after
determining the target system, 2017-09-26, v3.10.0-rc1~31^2) already
delayed this step from where it was historically.
2019-01-29 09:09:18 -05:00
Brad King
fa7077e741 Merge topic 'vs-host-arch'
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
2019-01-29 09:05:51 -05:00
Brad King
eeb34232fc Merge topic 'add-missing-macos-framework'
475e78d907 macOS: Add missing explicit dependency on CoreServices framework

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2873
2019-01-29 08:59:59 -05:00
Brad King
bcb1297faf Merge topic 'autogen_reenable_implicit_include_dirs'
03dbb62d31 Autogen: Reenable passing compiler implicit include directories to moc
5f34bdc7f9 cmLocalGenerator: Refactor `GetIncludeDirectoriesImplicit` method
f16dfdf71f cmLocalGenerator: Simplify `GetIncludeDirectories`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2864
2019-01-29 08:59:06 -05:00
Chuck Atkins
475e78d907 macOS: Add missing explicit dependency on CoreServices framework
On Apple, the implementation of cmGlobalXCodeGenerator::Open uses
LSOpenCFURLRef from CoreServices.  This get's transitively pulled in
from CMake's libuv build but ends up generating a linker error when
using an external libuv.  This explicitly adds the appropriate
dependency.
2019-01-29 06:59:24 -05:00
Kitware Robot
62c0b1aebb CMake Nightly Date Stamp 2019-01-29 00:01:06 -05:00
Brad King
0fd742a6ff VS: Teach VS 2019 generator to select host tools matching host arch
This generator is new so we can introduce the long-desired behavior
of selecting ``host=x64`` tools by default on x64 hosts.
2019-01-28 12:58:21 -05:00
Brad King
17cef3806d VS: Add support for explicit 32-bit toolset selection via host=x86
Generalize the ``host=x64`` option in `CMAKE_GENERATOR_TOOLSET`
to also support ``host=x86``.
2019-01-28 11:22:50 -05:00
Brad King
bf774e521b VS: Remove stray semicolons from VS 2019 implementation 2019-01-28 11:22:31 -05:00
Brad King
142e67eac6 VS: Use internal abstraction for VCTargetsPath host arch
Call our internal host architecture lookup method rather than directly
accessing a member used by its implementation.
2019-01-28 11:16:02 -05:00
Florian Maushart
439fe2e253 cmake: Add options for verbose output to --build mode
While we already support `VERBOSE` environment variable and
`CMAKE_VERBOSE_MAKEFILE` cached variable, add `-v` and `--verbose`
command line options to be able to activate verbose output directly from
CMake's build tool mode command line.

Also make `msbuild` honor the verbosity setting. `xcodebuild` still
doesn't honor the verbosity setting as it will need a policy added
and reworking of cmGlobalGenerator and cmsys to support
multiple command invocation.
2019-01-28 09:44:50 -05:00
Vitaly Stakhovsky
186d9b083d cmSystemTools::Message: Add overload accepting std::string 2019-01-28 09:35:51 -05:00
Vitaly Stakhovsky
2fc69ba0b3 cmFileTimeComparison: use std::string arguments 2019-01-28 09:09:59 -05:00
Sebastian Holtermann
03dbb62d31 Autogen: Reenable passing compiler implicit include directories to moc
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
2019-01-28 08:41:37 -05:00
Sebastian Holtermann
5f34bdc7f9 cmLocalGenerator: Refactor GetIncludeDirectoriesImplicit method
Use a dedicated `std::set` for implicit include directories instead
of (ab)using the emitted variable.  This in combination with lambdas
makes it easier to comprehend which paths are emitted.

For the implicit include directories we used to omit the
`CMAKE_SYSROOT_COMPILE`/`CMAKE_SYSROOT` prefix.  This has been changed and
the implicit paths are returned prefixed.  Implicit include directory returning
is only ever used by QtAutoGen which requires prefixed paths.  QtAutoGen passes
the (implicit) include paths to the `moc` which isn't aware of
`CMAKE_SYSROOT_COMPILE`/`CMAKE_SYSROOT`.
2019-01-28 08:41:28 -05:00
Sebastian Holtermann
f16dfdf71f cmLocalGenerator: Simplify GetIncludeDirectories
This patch strips the `stripImplicitDirs` and `appendAllImplicitDirs`
parameters from the `cmLocalGenerator::GetIncludeDirectories` method and makes
it a wrapper into the new `cmLocalGenerator::GetIncludeDirectoriesImplicit`
method.  `cmLocalGenerator::GetIncludeDirectoriesImplicit` is the renamed old
implementation of `cmLocalGenerator::GetIncludeDirectories` and still
accepts `stripImplicitDirs` and `appendAllImplicitDirs`.

The motivation is that there's only *one* case where
`cmLocalGenerator::GetIncludeDirectories` is called with the
`stripImplicitDirs` parameter being `false` (QtAutoGen), but many other places
where it is called using the `true` default value.

QtAutoGen is modified to use `cmLocalGenerator::GetIncludeDirectoriesImplicit`
directly.  In two use cases of `cmLocalGenerator::GetIncludeDirectories`
the manually set `true` value for `stripImplicitDirs` is removed.
2019-01-28 08:41:28 -05:00
Brad King
8e495333c0 Merge topic 'cmake-gui-s-b'
ad0853b3d4 QtDialog: Clean up and document -S and -B options

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !2863
2019-01-28 08:36:58 -05:00
Brad King
a844c7248d Merge topic 'cmake-E-compare_files-eol'
a5098cad94 cmake: Add --ignore-eol option to `-E compare_files` command

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2778
2019-01-28 08:27:03 -05:00
Taylor Braun-Jones
a5098cad94 cmake: Add --ignore-eol option to -E compare_files command
Fixes: #13007
2019-01-28 08:24:50 -05:00
Brad King
1593e16d88 Merge topic 'get_filename_component_last_ext'
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
2019-01-28 08:21:50 -05:00
Brad King
ce57bc8e04 Merge topic 'vs2019'
626c51f47b VS: Update for Visual Studio 2019 Preview 2
fd45cbf40e VS: Fix `/MANIFESTUAC:` link flag mapping for v142
db35e3cfd6 VS: Fix support for '/guard:cf' linker flag for v142
533f95c847 VS: Map the link `/debug` flag for v142
d2fcc6748a VS: Fix `/MANIFESTUAC:NO` link flag mapping for v142
a7973ccb53 VS: Populate `/permissive` flag table entry for v142
049410c0b6 VS: Populate `/JMC-` flag table entry for v142
43aa632f57 VS: Populate `-Qspectre-` flag table entry for v142
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2856
2019-01-28 08:07:28 -05:00
Brad King
70fabb8f25 Merge topic 'png-optimize'
b9e6d04558 Reduce size of PNG images
880e380599 CPack: Replace corrupted background png with original

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2852
2019-01-28 08:04:51 -05:00
Kitware Robot
f832f15509 CMake Nightly Date Stamp 2019-01-28 00:01:05 -05:00
Bruno Manganelli
b6a957c969 cmOutputConverter: move ConvertToRelativePath to cmStateDirectory. 2019-01-27 15:48:57 +00:00
Kitware Robot
f725750f04 CMake Nightly Date Stamp 2019-01-27 00:01:05 -05:00
Kitware Robot
be2cc309f1 CMake Nightly Date Stamp 2019-01-26 00:01:07 -05:00