Hash :
f01879d5
        
        Author :
  
        
        Date :
2024-10-21T09:58:26
        
      
Align ELF sections to 16K boundaries (-Wl,-z,max-page-size=16384) Even though the initial request was about Android, it is not only about it, but it could be the case for Linux as well (so as Apple M1/... chips) And this should not affect anything, since this is just ELFs Fixes: https://github.com/libevent/libevent/issues/1708
include(CheckLinkerFlag)
macro(add_linker_flags)
	foreach(flag ${ARGN})
		string(REGEX REPLACE "[-.+/:= ]" "_" _flag_esc "${flag}")
		check_linker_flag(C "${flag}" check_c_linker_flag_${_flag_esc})
		if (check_c_linker_flag_${_flag_esc})
			set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${flag}")
			set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${flag}")
		endif()
	endforeach()
endmacro()