Skip to content

Commit 6212ec9

Browse files
SebastianBoenashif
authored andcommitted
cmake: Cache the 'toolchain-is-ok' test as well
All compiler flag checks are cached for build-time performance reasons except for the test that tests the toolchain itself. It is believed that this test was left uncached because at the time, there was not enough trust in the caching mechanism. But time has shown that the caching mechanism is safe. So cache this test as well. This improves build-time performance and also reduces noise in the logs. Signed-off-by: Sebastian Bøe <[email protected]>
1 parent 4a50444 commit 6212ec9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ enable_language(C CXX ASM)
4040

4141
# Verify that the toolchain can compile a dummy file, if it is not we
4242
# won't be able to test for compatibility with certain C flags.
43-
check_c_compiler_flag("" toolchain_is_ok)
43+
zephyr_check_compiler_flag(C "" toolchain_is_ok)
4444
assert(toolchain_is_ok "The toolchain is unable to build a dummy C file. See CMakeError.log.")
4545

4646
# In some cases the "final" things are not used at all and "_prebuilt"

0 commit comments

Comments
 (0)