mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-22 23:06:18 +00:00
Changed: Use ADD_PLATFORM_LINKFLAGS macro
This commit is contained in:
parent
13544a4d84
commit
4cdcbb1332
1 changed files with 11 additions and 11 deletions
|
@ -793,7 +793,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
|
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
ADD_PLATFORM_LINKFLAGS("${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(TARGET_ARMV7)
|
IF(TARGET_ARMV7)
|
||||||
|
@ -803,7 +803,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
|
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
ADD_PLATFORM_LINKFLAGS("${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(TARGET_ARMV6)
|
IF(TARGET_ARMV6)
|
||||||
|
@ -813,7 +813,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
|
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}")
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}")
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
ADD_PLATFORM_LINKFLAGS("${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
@ -825,7 +825,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SIMULATOR_SYSROOT}")
|
ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SIMULATOR_SYSROOT}")
|
||||||
ADD_PLATFORM_FLAGS("${XARCH}-mios-simulator-version-min=${IOS_VERSION}")
|
ADD_PLATFORM_FLAGS("${XARCH}-mios-simulator-version-min=${IOS_VERSION}")
|
||||||
IF(CMAKE_OSX_DEPLOYMENT_TARGET)
|
IF(CMAKE_OSX_DEPLOYMENT_TARGET)
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-macosx_version_min,${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
ADD_PLATFORM_LINKFLAGS("${XARCH}-Wl,-macosx_version_min,${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ELSE()
|
ELSE()
|
||||||
|
@ -834,7 +834,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
IF(CMAKE_OSX_DEPLOYMENT_TARGET VERSION_LESS "10.7")
|
IF(CMAKE_OSX_DEPLOYMENT_TARGET VERSION_LESS "10.7")
|
||||||
MESSAGE(FATAL_ERROR "Minimum target for OS X is 10.7 but you're using ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
MESSAGE(FATAL_ERROR "Minimum target for OS X is 10.7 but you're using ${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-macosx_version_min,${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
ADD_PLATFORM_LINKFLAGS("-Wl,-macosx_version_min,${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
@ -845,7 +845,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-headerpad_max_install_names")
|
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-headerpad_max_install_names")
|
||||||
|
|
||||||
IF(HAVE_FLAG_SEARCH_PATHS_FIRST)
|
IF(HAVE_FLAG_SEARCH_PATHS_FIRST)
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-search_paths_first")
|
ADD_PLATFORM_LINKFLAGS("-Wl,-search_paths_first")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ELSE()
|
ELSE()
|
||||||
|
@ -893,7 +893,7 @@ MACRO(NL_SETUP_BUILD)
|
||||||
|
|
||||||
IF(TARGET_ARMV7)
|
IF(TARGET_ARMV7)
|
||||||
ADD_PLATFORM_FLAGS("-march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3-d16")
|
ADD_PLATFORM_FLAGS("-march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3-d16")
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -march=armv7-a -Wl,--fix-cortex-a8")
|
ADD_PLATFORM_LINKFLAGS("-march=armv7-a -Wl,--fix-cortex-a8")
|
||||||
ELSEIF(TARGET_ARMV5)
|
ELSEIF(TARGET_ARMV5)
|
||||||
ADD_PLATFORM_FLAGS("-march=armv5te -mtune=xscale -msoft-float")
|
ADD_PLATFORM_FLAGS("-march=armv5te -mtune=xscale -msoft-float")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
@ -913,8 +913,8 @@ MACRO(NL_SETUP_BUILD)
|
||||||
ADD_PLATFORM_FLAGS("-fpic -finline-functions -fmessage-length=0 -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers")
|
ADD_PLATFORM_FLAGS("-fpic -finline-functions -fmessage-length=0 -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers")
|
||||||
SET(RELEASE_CFLAGS "${RELEASE_CFLAGS} -funswitch-loops -finline-limit=300")
|
SET(RELEASE_CFLAGS "${RELEASE_CFLAGS} -funswitch-loops -finline-limit=300")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-z,noexecstack")
|
ADD_PLATFORM_LINKFLAGS("-Wl,-z,noexecstack")
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -L${PLATFORM_ROOT}/usr/lib")
|
ADD_PLATFORM_LINKFLAGS("-L${PLATFORM_ROOT}/usr/lib")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(APPLE)
|
IF(APPLE)
|
||||||
|
@ -932,12 +932,12 @@ MACRO(NL_SETUP_BUILD)
|
||||||
ADD_PLATFORM_FLAGS("-fstack-protector --param=ssp-buffer-size=4")
|
ADD_PLATFORM_FLAGS("-fstack-protector --param=ssp-buffer-size=4")
|
||||||
|
|
||||||
IF(NOT APPLE)
|
IF(NOT APPLE)
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,--no-undefined -Wl,--as-needed")
|
ADD_PLATFORM_LINKFLAGS("-Wl,--no-undefined -Wl,--as-needed")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(NOT APPLE)
|
IF(NOT APPLE)
|
||||||
# hardening
|
# hardening
|
||||||
SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now")
|
ADD_PLATFORM_LINKFLAGS("-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
IF(WITH_SYMBOLS)
|
IF(WITH_SYMBOLS)
|
||||||
|
|
Loading…
Reference in a new issue