make RPI option more descriptive

pull/179/head
despair 6 years ago committed by Rick
parent afa83f0646
commit 43afede986
No known key found for this signature in database
GPG Key ID: C0EDC8723FDC3465

@ -9,7 +9,7 @@ option(USE_AVX2 "enable avx2 code" )
option(USE_NETNS "enable networking namespace support" )
option(AMD_RYZEN_HACK "hack for AMD Ryzen FPU bug (support FMA3 and FMA4 in FPU, but does not show in CPUID)" )
option(STATIC_LINK "emit fully linked binaries" )
option(RPI "Build for 32-bit Raspberry Pi" )
option(NON_PC_TARGET "non-pc target build: iphone, andriod, embedded non-i386 SBC, etc" )
option(SHADOW "use shadow testing framework. linux only" )
option(ASAN "use address sanitiser, if your system has it" )
option(JEMALLOC "use jemalloc. Not required on BSD" )
@ -70,13 +70,13 @@ if(DEBIAN)
add_definitions(-DDEBIAN)
else()
if(NOT ANDROID)
if(NOT RPI)
if (NOT USE_AVX2)
if(NOT NON_PC_TARGET)
if (NOT USE_AVX2)
set(CRYPTO_FLAGS -march=core2 -msse4.1 -mtune=native -mfpmath=sse)
else()
set(CRYPTO_FLAGS -march=haswell -mtune=native -mfpmath=sse)
endif(NOT USE_AVX2)
endif(NOT RPI)
endif(NOT NON_PC_TARGET)
endif(NOT ANDROID)
endif(DEBIAN)
@ -147,10 +147,11 @@ if(CMAKE_BUILD_TYPE MATCHES "[Dd][Ee][Bb][Uu][Gg]")
add_compile_options( ${DEBUG_FLAGS} )
endif(CMAKE_BUILD_TYPE MATCHES "[Dd][Ee][Bb][Uu][Gg]")
if(RPI)
# Add non-386 target-specific options here
if(NON_PC_TARGET)
add_definitions(-DRPI)
set(WITH_STATIC ON)
endif(RPI)
endif(NON_PC_TARGET)
add_compile_options(${OPTIMIZE_FLAGS} ${CRYPTO_FLAGS})
@ -703,11 +704,11 @@ if(WITH_STATIC)
target_link_libraries(${PLATFORM_LIB} Threads::Threads)
endif(USE_LIBABYSS)
if(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
if(RPI)
if(NON_PC_TARGET)
target_link_libraries(${PLATFORM_LIB} -lrt)
else()
target_link_libraries(${PLATFORM_LIB} -lcap)
endif(RPI)
endif(NON_PC_TARGET)
endif(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(${STATIC_LIB} ${CRYPTOGRAPHY_LIB} ${LIBS} ${PLATFORM_LIB})
if(NOT WITH_SHARED)

Loading…
Cancel
Save