mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-29 11:41:15 +03:00
tests: scripts: fix test_cmake_out_of_source
By default C++ code would be compiled with GNU while C with Clang and this can create problems at link time. In order to prevent this we use Clang for both. Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
This commit is contained in:
@ -65,7 +65,9 @@ component_test_cmake_out_of_source () {
|
||||
mkdir "$OUT_OF_SOURCE_DIR"
|
||||
cd "$OUT_OF_SOURCE_DIR"
|
||||
# Note: Explicitly generate files as these are turned off in releases
|
||||
cmake -D CMAKE_BUILD_TYPE:String=Check -D GEN_FILES=ON -D TEST_CPP=1 "$MBEDTLS_ROOT_DIR"
|
||||
# Note: Use Clang compiler also for C++ (C uses it by default)
|
||||
CXX=clang++ cmake -D CMAKE_BUILD_TYPE:String=Check -D GEN_FILES=ON \
|
||||
-D TEST_CPP=1 "$MBEDTLS_ROOT_DIR"
|
||||
make
|
||||
|
||||
msg "test: cmake 'out-of-source' build"
|
||||
|
Reference in New Issue
Block a user