mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Drop old check
This commit is contained in:
parent
6a7535afe6
commit
c86d92f3db
@ -1,25 +0,0 @@
|
||||
include(CheckCXXCompilerFlag)
|
||||
|
||||
# Adds CXX compiler flag if the flag is supported by the compiler.
|
||||
#
|
||||
# This is effectively a combination of CMake's check_cxx_compiler_flag()
|
||||
# and add_compile_options():
|
||||
#
|
||||
# if(check_cxx_compiler_flag(flag))
|
||||
# add_compile_options(flag)
|
||||
#
|
||||
function(eth_add_cxx_compiler_flag_if_supported FLAG)
|
||||
# Remove leading - or / from the flag name.
|
||||
string(REGEX REPLACE "^[-/]" "" name ${FLAG})
|
||||
# Deletes any ':' because it's invalid variable names.
|
||||
string(REGEX REPLACE ":" "" name ${name})
|
||||
check_cxx_compiler_flag(${FLAG} ${name})
|
||||
if(${name})
|
||||
add_compile_options(${FLAG})
|
||||
endif()
|
||||
|
||||
# If the optional argument passed, store the result there.
|
||||
if(ARGV1)
|
||||
set(${ARGV1} ${name} PARENT_SCOPE)
|
||||
endif()
|
||||
endfunction()
|
@ -15,13 +15,9 @@
|
||||
# These settings then end up spanning all POSIX platforms (Linux, OS X, BSD, etc)
|
||||
|
||||
include(CableCompileOptions)
|
||||
include(EthCheckCXXCompilerFlag)
|
||||
|
||||
if(NOT EMSCRIPTEN)
|
||||
eth_add_cxx_compiler_flag_if_supported(-fstack-protector-strong have_stack_protector_strong_support)
|
||||
if(NOT have_stack_protector_strong_support)
|
||||
eth_add_cxx_compiler_flag_if_supported(-fstack-protector)
|
||||
endif()
|
||||
cable_add_compile_options(IF_SUPPORTED -fstack-protector -fstack-protector-strong)
|
||||
endif()
|
||||
|
||||
if (("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU") OR ("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang"))
|
||||
|
Loading…
Reference in New Issue
Block a user