|
|
|
@ -2503,6 +2503,22 @@ macro( tde_setup_architecture_flags )
|
|
|
|
|
set( TDE_PIE_CFLAGS -fPIE )
|
|
|
|
|
set( TDE_PIE_LDFLAGS -pie )
|
|
|
|
|
endif( HAVE_PIE_SUPPORT )
|
|
|
|
|
|
|
|
|
|
set( _reproducible_cxxflags
|
|
|
|
|
"-fdebug-prefix-map=${CMAKE_SOURCE_DIR}=."
|
|
|
|
|
"-fmacro-prefix-map=${CMAKE_SOURCE_DIR}=."
|
|
|
|
|
)
|
|
|
|
|
foreach( _flag ${_reproducible_cxxflags} )
|
|
|
|
|
string( REGEX REPLACE "=.*" "" _flag_name "${_flag}" )
|
|
|
|
|
string( REGEX REPLACE "[^a-zA-Z0-9]+" "_" _flag_var "CXXFLAG_${_flag_name}" )
|
|
|
|
|
if( NOT "${CMAKE_CXX_FLAGS}" MATCHES "(^| )${_flag_name}" )
|
|
|
|
|
check_cxx_compiler_flag( "${_flag}" ${_flag_var} )
|
|
|
|
|
if( ${_flag_var} )
|
|
|
|
|
set( CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} ${_flag}" )
|
|
|
|
|
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_flag}" )
|
|
|
|
|
endif()
|
|
|
|
|
endif()
|
|
|
|
|
endforeach()
|
|
|
|
|
endif( )
|
|
|
|
|
endmacro( )
|
|
|
|
|
|
|
|
|
|