1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-14 02:08:27 +08:00
Commit Graph

51146 Commits

Author SHA1 Message Date
Brad King
d29da8ed3e cmMakefile: Simplify custom target 'force' output name generation
Remove unnecessary check of policy CMP0049.  The policy can never
trigger on our internally-generated name because it has no variable
references.

The rename in commit 0ed5ce4cd8 (cmTarget: Rename AddSource method for
backward compatibility., 2014-03-17, v3.1.0-rc1~688^2~17) made it look
like this code path depended on CMP0049.  Then commit 0e1faa28cb
(cmMakefile: Separate custom command setup from actual creation,
2019-09-14, v3.16.0-rc1~85^2) and commit ea1bed34b2 (cmMakefile: Extract
utilities used for creation of custom commands, 2019-09-21,
v3.16.0-rc1~52^2~1) built additional infrastructure to thread that
dependence through the call stack.  Remove it all.
2020-12-15 07:00:52 -05:00
Brad King
2b1cc175ee Help: Clarify version adding add_custom_{command,target} OUTPUT genex support
Update the documentation added by commit c257c25419
(add_custom_{command,target}: Add genex support to OUTPUT and
BYPRODUCTS, 2020-10-19) to use sphinx markup instead of prose to specify
the version in which the feature was added.
2020-12-15 07:00:20 -05:00
Brad King
82b25be80a Merge topic 'FindMatlab-MCR'
9c360b9eea FindMatlab: Fix search for MCR
bda5e2ac8f FindMatlab: Only include engine and dataarray libraries if they are found

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5600
2020-12-14 07:28:42 -05:00
Brad King
fedfe763ee Merge topic 'custom-command-output-genex'
c257c25419 add_custom_{command,target}: Add genex support to OUTPUT and BYPRODUCTS
f36af9228b cmLocalGenerator: Evaluate generator expressions in custom command outputs
c887cefd9a cmLocalGenerator: Simplify custom command output cmSourceFile creation
947ba01bf9 cmLocalGenerator: Factor out helper to expand custom command output paths
1902d28ebc cmLocalGenerator: Refactor UpdateOutputToSourceMap to avoid boolean trap
e4034eabe9 cmLocalGenerator: Re-order logic in CreateGeneratedSource
706c48301d cmCustomCommandGenerator: Treat relative outputs w.r.t. build dir
5d23c5446e cmCustomCommandGenerator: Refactor OUTPUT and DEPENDS path evaluation
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kyle Edwards <kyle.edwards@kitware.com>
Acked-by: Pavel Solodovnikov <hellyeahdominate@gmail.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !5402
2020-12-14 07:22:45 -05:00
Brad King
979af92e9e Merge topic 'doc-try_compile-typos'
1f41eb8472 Help: Fix small typos in documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5609
2020-12-14 07:20:34 -05:00
Guillem Vela
1f41eb8472 Help: Fix small typos in documentation 2020-12-14 07:18:47 -05:00
Brad King
f62bcd08aa Merge topic 'makefiles-compiler-deps-optims'
b2ff3c52df cmDependsCompiler: rely now on cmGccDepfileReader for depfile parser

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5599
2020-12-14 07:16:05 -05:00
Brad King
06dae10c9b Merge topic 'automoc-autouic-autorcc-not-csharp'
f65f20938c Autogen: Avoid processing CSharp targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5507
2020-12-14 07:15:01 -05:00
Brad King
7ad7ac4167 Merge topic 'update-curl'
d0bac89cea curl: Set build options the way we need for CMake
54931fdff0 Merge branch 'upstream-curl' into update-curl
5aacc593a9 curl 2020-12-09 (e0528597)
4cd65e5d88 curl: Update script to get curl 7.74.0

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5592
2020-12-14 07:14:16 -05:00
Brad King
b4a17cc0cc Merge branch 'release-3.19' 2020-12-14 07:11:07 -05:00
Brad King
528fbd61b7 Merge topic 'FindGLUT-macos-tbd'
d29d034e2e FindGLUT: Handle Mojave and Big Sur 'tbd' framework files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5601
2020-12-14 07:11:07 -05:00
Brad King
6aff058ab4 Merge topic 'FindGLUT-macos-tbd' into release-3.19
d29d034e2e FindGLUT: Handle Mojave and Big Sur 'tbd' framework files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5601
2020-12-14 07:11:07 -05:00
Brad King
33a8a4adff Merge branch 'release-3.19' 2020-12-14 07:10:04 -05:00
Brad King
7be4b24ae6 Merge topic 'macos-homebrew-apple-silicon' into release-3.19
1a5c1a68b6 macOS: Add /opt/homebrew to CMAKE_SYSTEM_PREFIX_PATH on Apple Silicon

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Fons Rademakers <fons.rademakers@cern.ch>
Merge-request: !5602
2020-12-14 07:10:04 -05:00
Brad King
41d8c20221 Merge topic 'macos-homebrew-apple-silicon'
1a5c1a68b6 macOS: Add /opt/homebrew to CMAKE_SYSTEM_PREFIX_PATH on Apple Silicon

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Fons Rademakers <fons.rademakers@cern.ch>
Merge-request: !5602
2020-12-14 07:10:04 -05:00
Brad King
627e390ff7 Merge branch 'release-3.19' 2020-12-14 07:08:50 -05:00
Brad King
4cdf951f07 Merge topic 'install-properties' into release-3.19
63db7ae9c4 cmake: Clear INSTALL file properties between runs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5603
2020-12-14 07:08:49 -05:00
Brad King
f70814c3fd Merge topic 'install-properties'
63db7ae9c4 cmake: Clear INSTALL file properties between runs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5603
2020-12-14 07:08:49 -05:00
Brad King
04ed1e73dd Merge topic 'execute_process-command-error' into release-3.19
e5a4ffaad1 execute_process: Improve COMMAND_ERROR_IS_FATAL error capture scenarios

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5588
2020-12-14 07:07:46 -05:00
Brad King
0d5649c67b Merge branch 'release-3.19' 2020-12-14 07:07:46 -05:00
Brad King
922ad5c6b9 Merge topic 'execute_process-command-error'
e5a4ffaad1 execute_process: Improve COMMAND_ERROR_IS_FATAL error capture scenarios

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5588
2020-12-14 07:07:46 -05:00
Kitware Robot
0a6c7cdd07 CMake Nightly Date Stamp 2020-12-14 00:01:19 -05:00
Kitware Robot
703a58cba3 CMake Nightly Date Stamp 2020-12-13 00:02:09 -05:00
Kitware Robot
4621ffb028 CMake Nightly Date Stamp 2020-12-12 00:01:10 -05:00
Brad King
1a5c1a68b6 macOS: Add /opt/homebrew to CMAKE_SYSTEM_PREFIX_PATH on Apple Silicon
According to https://brew.sh/2020/12/01/homebrew-2.6.0/ the `/opt/homebrew`
directory is recommended for installing ARM architecture brew packages.

Fixes: #21585
2020-12-11 13:07:17 -05:00
Brad King
23df57a3a7 Merge topic 'apple-silicon-host-arch' into release-3.19
b7f0327dcd Tests: Cover macOS host architecture selection on Apple Silicon hosts
5f882f6ce5 macOS: Offer control over host architecture on Apple Silicon hosts

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5589
2020-12-11 13:05:34 -05:00
Brad King
0064981f6f Merge branch 'release-3.19' 2020-12-11 13:05:34 -05:00
Brad King
794aa36b1f Merge topic 'apple-silicon-host-arch'
b7f0327dcd Tests: Cover macOS host architecture selection on Apple Silicon hosts
5f882f6ce5 macOS: Offer control over host architecture on Apple Silicon hosts

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5589
2020-12-11 13:05:34 -05:00
Brad King
0d9c43281f Merge branch 'release-3.19' 2020-12-11 13:04:37 -05:00
Brad King
1404741153 Merge topic 'doc-3_19_release-fixes'
3765a415df Merge branch 'master' into doc-3_19_release-fixes
ff4d1d44f2 Help: Clarify scope details of deferred call ids for cmake_language()
b4c02a0a1d Help: Re-sort indexes in the manuals
2c33949c64 Help: Mention how OPTIMIZE_DEPENDENCIES is initialized
0816482302 Help: xref variable that cmake_minimum_required() sets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5598
2020-12-11 13:04:37 -05:00
Brad King
0a5a883d53 Merge topic 'doc-3_19_release-fixes' into release-3.19
ff4d1d44f2 Help: Clarify scope details of deferred call ids for cmake_language()
b4c02a0a1d Help: Re-sort indexes in the manuals
2c33949c64 Help: Mention how OPTIMIZE_DEPENDENCIES is initialized
0816482302 Help: xref variable that cmake_minimum_required() sets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5598
2020-12-11 13:04:36 -05:00
Brad King
63db7ae9c4 cmake: Clear INSTALL file properties between runs
Do not keep state across separate project configurations.
This is particularly important in `cmake-gui` where those
configurations can be for separate projects.

Fixes: #21580
2020-12-11 12:30:27 -05:00
Alessandro Ambrosano
f65f20938c Autogen: Avoid processing CSharp targets
Fixes: #21442
2020-12-11 11:37:11 -05:00
Nikolaj Fogh
9c360b9eea FindMatlab: Fix search for MCR
Fixes: #21068, #21582
2020-12-11 11:30:59 -05:00
Nikolaj Fogh
bda5e2ac8f FindMatlab: Only include engine and dataarray libraries if they are found 2020-12-11 11:27:35 -05:00
Robert Maynard
d29d034e2e FindGLUT: Handle Mojave and Big Sur 'tbd' framework files 2020-12-11 11:01:30 -05:00
Brad King
3765a415df Merge branch 'master' into doc-3_19_release-fixes 2020-12-11 10:39:14 -05:00
Marc Chevrier
b2ff3c52df cmDependsCompiler: rely now on cmGccDepfileReader for depfile parser
To avoid duplicate effort of depfile parsing and enhance robustness
of parsing against mal-formed depfiles in preparation of DEPFILE option
support of add_custom_command command for makefiles generators.
2020-12-11 14:48:00 +01:00
Brad King
d0bac89cea curl: Set build options the way we need for CMake 2020-12-11 08:39:40 -05:00
Brad King
c257c25419 add_custom_{command,target}: Add genex support to OUTPUT and BYPRODUCTS
Move rejection of `#`, `<`, and `>` characters in outputs and byproducts
to a generate-time check.  This removes the front-end check that
disallowed generator expressions.  The generators have already been
updated to handle them.

Fixes: #12877
2020-12-11 08:24:21 -05:00
Brad King
f36af9228b cmLocalGenerator: Evaluate generator expressions in custom command outputs
Custom commands with generator expressions in their OUTPUTs or
BYPRODUCTS are still attached to a single `.rule` file.  We use an
internal map to look up the source file holding the custom command for a
given output.  Populate this map using the outputs and byproducts from
all configurations after evaluating the generator expressions for each
configuration.

Issue: #12877
2020-12-11 08:24:06 -05:00
Craig Scott
ff4d1d44f2 Help: Clarify scope details of deferred call ids for cmake_language()
Fixes: #21586
2020-12-11 18:25:42 +11:00
Kitware Robot
adc6a4c540 CMake Nightly Date Stamp 2020-12-11 00:01:08 -05:00
Craig Scott
b4c02a0a1d Help: Re-sort indexes in the manuals 2020-12-11 11:19:04 +11:00
Craig Scott
2c33949c64 Help: Mention how OPTIMIZE_DEPENDENCIES is initialized 2020-12-11 11:19:04 +11:00
Craig Scott
0816482302 Help: xref variable that cmake_minimum_required() sets
The CMAKE_MINIMUM_REQUIRED_VERSION has long been set by
the cmake_minimum_required() command, but the command docs
never mentioned this. Only the variable's own docs stated this but
the variable isn't very discoverable without it being mentioned in
the command's docs as well.
2020-12-11 11:19:04 +11:00
Brad King
b7f0327dcd Tests: Cover macOS host architecture selection on Apple Silicon hosts
Add test cases verifying that `CMAKE_APPLE_SILICON_PROCESSOR` set as
either a cache or environment variable causes that to be selected as the
host architecture.  Also verify that sources compile using whatever is
selected as the host architecture, even when the explicit setting is not
used.

Issue: #21554
2020-12-10 12:08:15 -05:00
Brad King
5f882f6ce5 macOS: Offer control over host architecture on Apple Silicon hosts
Since commit b6c60f14b6 (macOS: Default to arm64 architecture on Apple
Silicon hosts, 2020-09-28, v3.19.0-rc1~63^2) we use `sysctl` to detect
that we are running on Apple Silicon in a way that pierces Rosetta.
This always sets `CMAKE_HOST_SYSTEM_PROCESSOR` to be `arm64` on such
hosts.  However, macOS offers strong support for running processes under
an emulated `x86_64` architecture.

Teach CMake to select either `arm64` or `x86_64` as the host
architecture on Apple Silicon based on the architecture of its own
process.  When CMake is built as a universal binary, macOS will select
whichever slice (architecture) is appropriate under the user's shell,
and `CMAKE_HOST_SYSTEM_PROCESSOR` will match.

Also offer a `CMAKE_APPLE_SILICON_PROCESSOR` variable and environment
variable to provide users with explicit control over the host
architecture selection regardless of CMake's own architecture.

Finally, if `CMAKE_OSX_ARCHITECTURES` is not set, pass explicit flags to
the toolchain to use selected host architecture instead of letting the
toolchain pick.

Fixes: #21554
2020-12-10 12:08:13 -05:00
Brad King
8240131ff7 Merge branch 'release-3.19' 2020-12-10 12:05:17 -05:00
Brad King
fd6c1e5a73 Merge topic 'rel-macos-apple-silicon'
56a075eb5d ci: update macOS package to produce universal binaries
b184cc256b ci: do not use sccache for macOS packaging
41bddf1028 ci: update to pre-built Qt 5.9.9 universal binaries for macOS packages
b201dc0d42 Utilities/Release: Add script to build Qt 5.9.9 macOS universal binaries

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !5595
2020-12-10 12:05:17 -05:00