mirror of
https://github.com/google/benchmark.git
synced 2024-12-27 13:00:36 +08:00
Pass flag string to check_cxx_compiler_flag
(#298)
This commit is contained in:
parent
2aca242bf6
commit
d1daeee4e9
@ -25,7 +25,7 @@ function(add_cxx_compiler_flag FLAG)
|
||||
string(REGEX REPLACE "[^A-Za-z_0-9]" "_" SANITIZED_FLAG ${SANITIZED_FLAG})
|
||||
string(REGEX REPLACE "_+" "_" SANITIZED_FLAG ${SANITIZED_FLAG})
|
||||
set(CMAKE_REQUIRED_FLAGS "${FLAG}")
|
||||
check_cxx_compiler_flag("" ${SANITIZED_FLAG})
|
||||
check_cxx_compiler_flag("${FLAG}" ${SANITIZED_FLAG})
|
||||
if(${SANITIZED_FLAG})
|
||||
set(VARIANT ${ARGV1})
|
||||
if(ARGV1)
|
||||
|
Loading…
Reference in New Issue
Block a user