Skip to content

Commit 2510ae2

Browse files
authored
check_configuration.cmake: remove COMPILE_LANGUAGE:CXX from set_common_compile_options (#71)
cmake version 3.10.2 fails with this error: CMake Error at cmake/common/check_configuration.cmake:120 (target_compile_options): Error evaluating generator expression: $<COMPILE_LANGUAGE:CXX> $<COMPILE_LANGUAGE:...> Unknown language. version 3.22.2 does not produce this error. Signed-off-by: Beat Küng <[email protected]>
1 parent cb4403a commit 2510ae2

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

cmake/common/check_configuration.cmake

-4
Original file line numberDiff line numberDiff line change
@@ -120,15 +120,11 @@ function(set_common_compile_options target)
120120
target_compile_options(${target} PRIVATE -Wall
121121
-Wextra
122122
-Wshadow
123-
$<$<COMPILE_LANGUAGE:CXX>:-Wnon-virtual-dtor>
124123
-pedantic
125124
-Wcast-align
126125
-Wunused
127-
$<$<COMPILE_LANGUAGE:CXX>:-Woverloaded-virtual>
128126
-Wconversion
129127
$<$<CXX_COMPILER_ID:GNU>:-Wlogical-op>
130-
$<$<AND:$<CXX_COMPILER_ID:GNU>,$<COMPILE_LANGUAGE:CXX>>:-Wuseless-cast>
131-
$<$<COMPILE_LANGUAGE:CXX>:-Wold-style-cast>
132128
$<$<OR:$<AND:$<CXX_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<CXX_COMPILER_VERSION>,6.0.0>>>,$<AND:$<C_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<C_COMPILER_VERSION>,6.0.0>>>>:-Wnull-dereference>
133129
$<$<OR:$<AND:$<CXX_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<CXX_COMPILER_VERSION>,7.0.0>>>,$<AND:$<C_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<C_COMPILER_VERSION>,7.0.0>>>>:-Wduplicated-branches>
134130
$<$<OR:$<AND:$<CXX_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<CXX_COMPILER_VERSION>,6.0.0>>>,$<AND:$<C_COMPILER_ID:GNU>,$<NOT:$<VERSION_LESS:$<C_COMPILER_VERSION>,6.0.0>>>>:-Wduplicated-cond>

0 commit comments

Comments
 (0)