1c8ea5b6e1
Bug: 302718225 Test: cd build/soong/cc && go test Test: https://r.android.com/2803466 Change-Id: Ie7df635233ed68c40d917ea1f83f9fd4b5bfe729
10 lines
248 B
Text
10 lines
248 B
Text
include(CheckCXXCompilerFlag)
|
|
|
|
macro(append_cxx_flags_if_supported VAR)
|
|
foreach(FLAG ${ARGN})
|
|
check_cxx_compiler_flag(${FLAG} HAS_FLAG${FLAG})
|
|
if(${HAS_FLAG${FLAG}})
|
|
list(APPEND ${VAR} ${FLAG})
|
|
endif()
|
|
endforeach()
|
|
endmacro()
|