diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-11-08 20:48:37 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-11-08 20:48:37 +0000 |
commit | 1544764919a1c3393d091795db5f73760b6eed28 (patch) | |
tree | 0867a47f8c6288ec478cd648cfbd21dd14eed328 /CMakeLists.txt | |
parent | 3cfd800e0519babb33d28ee6bb8ed83d0a83285c (diff) | |
download | rspamd-1544764919a1c3393d091795db5f73760b6eed28.tar.gz rspamd-1544764919a1c3393d091795db5f73760b6eed28.zip |
[Minor] Throw off legacy stuff
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 0376739b8..4b8b03452 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -514,19 +514,6 @@ ENDIF(CMAKE_INSTALL_PREFIX) LIST(APPEND CMAKE_REQUIRED_LIBRARIES m) -# Try to detect platform for further configuration -CHECK_C_SOURCE_COMPILES ("#if !defined(__x86_64) && !defined(__amd64) && !defined(_M_X64) - #error assume 32 bit arch - #endif - int main() { return 0;}" AMD_64) -IF(NOT BUILD_CPU_MODE) - IF(AMD_64) - SET (BUILD_CPU_MODE "64") - ELSE(AMD_64) - SET (BUILD_CPU_MODE "32") - ENDIF(AMD_64) -ENDIF(NOT BUILD_CPU_MODE) - SET(POE_LOOP "Loop::IO_Poll") SET(TAR "tar") @@ -567,9 +554,6 @@ ENDIF(CMAKE_SYSTEM_NAME STREQUAL "Darwin") IF(CMAKE_SYSTEM_NAME STREQUAL "Linux") SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_GNU_SOURCE") ADD_DEFINITIONS(-D_GNU_SOURCE -DLINUX) - IF(BUILD_CPU_MODE STREQUAL "32") - ADD_DEFINITIONS(-D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE) - ENDIF(BUILD_CPU_MODE STREQUAL "32") # Workaround with architecture specific includes #IF(IS_DIRECTORY "/usr/include/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu/") # INCLUDE_DIRECTORIES("/usr/include/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu/") @@ -590,36 +574,16 @@ IF(CMAKE_SYSTEM_NAME STREQUAL "Linux") ENDIF(CMAKE_SYSTEM_NAME STREQUAL "Linux") IF(CMAKE_SYSTEM_NAME STREQUAL "SunOS") - IF(NOT BUILD_CPU_MODE) - SET (BUILD_CPU_MODE "32") - ENDIF(NOT BUILD_CPU_MODE) IF("${CMAKE_C_COMPILER_ID}" MATCHES SunPro) SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Xa -xregs=no%frameptr -xstrconst -xc99") - SET(SUN_BUILD32 "-xtarget=generic") - SET(SUN_BUILD64 "-xtarget=generic64") IF(ENABLE_OPTIMIZATION MATCHES "ON") SET(CMAKE_C_OPT_FLAGS "-fast -xdepend") ELSE(ENABLE_OPTIMIZATION MATCHES "ON") SET(CMAKE_C_OPT_FLAGS "-xO0") ENDIF(ENABLE_OPTIMIZATION MATCHES "ON") - ELSE("${CMAKE_C_COMPILER_ID}" MATCHES SunPro) - set(SUN_BUILD32 "-m32") - set(SUN_BUILD64 "-m64") ENDIF("${CMAKE_C_COMPILER_ID}" MATCHES SunPro) - IF (BUILD_CPU_MODE STREQUAL "32") - message (STATUS "Building 32-bit mode on Solaris") - # If we are asked to build 32 bit mode - set(CMAKE_C_FLAGS "${SUN_BUILD32} ${CMAKE_C_FLAGS}") - set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SUN_BUILD32}") - ELSE (BUILD_CPU_MODE STREQUAL "32") - # solaris 64-bit mode - message (STATUS "Building 64-bit mode on Solaris") - set(CMAKE_C_FLAGS "${SUN_BUILD64} ${CMAKE_C_FLAGS}") - set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SUN_BUILD64}") - ENDIF (BUILD_CPU_MODE STREQUAL "32") - SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__EXTENSIONS__ -DSOLARIS -D_POSIX_SOURCE -D_POSIX_C_SOURCE=200112L") LIST(APPEND CMAKE_REQUIRED_LIBRARIES rt) |