https://github.com/Kitware/CMake
Revision 5c84eca2108c8b47a74391c732710c67e23adfa3 authored by Brad King on 01 June 2022, 17:30:51 UTC, committed by Brad King on 01 June 2022, 17:57:47 UTC
Since commit 07223c5c27 (Tutorial: Update Step 5 to work on Windows,
2020-02-18, v3.18.0-rc1~655^2) the logic does not work on non-Windows
platforms when cmake is re-run on an existing build tree.  It is also
more complicated than we'd like for a tutorial example.  Avoid the need
to consider the `m` library case by performing the check as C++.

Since `check_cxx_symbol_exists` cannot handle overloaded functions
like `exp` and `log`, check with `check_cxx_source_compiles` instead.
This also presents a more general-purpose example in the tutorial.

Fixes: #23524
1 parent 18be0f9
History
Tip revision: 5c84eca2108c8b47a74391c732710c67e23adfa3 authored by Brad King on 01 June 2022, 17:30:51 UTC
Tutorial: Simplify logic checking for cmath functions
Tip revision: 5c84eca
File Mode Size
.github
.gitlab
Auxiliary
Help
Licenses
Modules
Packaging
Source
Templates
Tests
Utilities
.clang-format -rw-r--r-- 1.4 KB
.clang-tidy -rw-r--r-- 1.3 KB
.codespellrc -rw-r--r-- 570 bytes
.editorconfig -rw-r--r-- 164 bytes
.gitattributes -rw-r--r-- 1.2 KB
.gitignore -rw-r--r-- 280 bytes
.gitlab-ci.yml -rw-r--r-- 20.9 KB
.hooks-config -rw-r--r-- 418 bytes
CMakeCPack.cmake -rw-r--r-- 9.8 KB
CMakeCPackOptions.cmake.in -rw-r--r-- 11.9 KB
CMakeGraphVizOptions.cmake -rw-r--r-- 153 bytes
CMakeLists.txt -rw-r--r-- 34.6 KB
CMakeLogo.gif -rw-r--r-- 4.4 KB
CONTRIBUTING.rst -rw-r--r-- 3.0 KB
CTestConfig.cmake -rw-r--r-- 566 bytes
CTestCustom.cmake.in -rw-r--r-- 6.6 KB
CompileFlags.cmake -rw-r--r-- 4.7 KB
Copyright.txt -rw-r--r-- 5.3 KB
DartConfig.cmake -rw-r--r-- 374 bytes
README.rst -rw-r--r-- 3.9 KB
bootstrap -rwxr-xr-x 63.0 KB
cmake_uninstall.cmake.in -rw-r--r-- 789 bytes
configure -rwxr-xr-x 99 bytes
doxygen.config -rw-r--r-- 27.4 KB

README.rst

back to top