Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
We don't really need librt (-lrt)
  • Loading branch information
Leonid Boytsov authored and Leonid Boytsov committed Mar 5, 2019
1 parent 955a286 commit 83c2775
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions similarity_search/CMakeLists.txt
Expand Up @@ -42,17 +42,17 @@ if(${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU")
message(FATAL_ERROR "GCC version must be at least 4.7!")
endif()
# Uncomment the following lines to see how the code compiles without AVX,SSE4.2 and/or SSE2
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -lrt -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=x86-64")
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -lrt -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=core2")
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -lrt -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -msse4.2")
set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Wcast-align -Ofast -lm -lrt -DNDEBUG -std=c++11 -pthread -DHAVE_CXX0X -march=native -Wl,--no-as-needed -fpic")
set (CMAKE_CXX_FLAGS_DEBUG "-Wall -Wunreachable-code -Wcast-align -ggdb -lm -lrt -DNDEBUG -std=c++11 -pthread -DHAVE_CXX0X -march=native -Wl,--no-as-needed -fpic")
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=x86-64")
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=core2")
#set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lm -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -msse4.2")
set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Wcast-align -Ofast -lm -DNDEBUG -std=c++11 -pthread -DHAVE_CXX0X -march=native -Wl,--no-as-needed -fpic")
set (CMAKE_CXX_FLAGS_DEBUG "-Wall -Wunreachable-code -Wcast-align -ggdb -lm -DNDEBUG -std=c++11 -pthread -DHAVE_CXX0X -march=native -Wl,--no-as-needed -fpic")
elseif(${CMAKE_CXX_COMPILER_ID} STREQUAL "Intel")
if (CXX_COMPILER_VERSION VERSION_LESS 14.0.1)
message(FATAL_ERROR "Intel version must be at least 14.0.1!")
endif()
set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -lrt -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -march=native -fpic")
set (CMAKE_CXX_FLAGS_DEBUG "-Wall -Wunreachable-code -ggdb -lrt -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -march=native -fpic")
set (CMAKE_CXX_FLAGS_RELEASE "-Wall -Wunreachable-code -Ofast -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -march=native -fpic")
set (CMAKE_CXX_FLAGS_DEBUG "-Wall -Wunreachable-code -ggdb -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -march=native -fpic")
elseif(${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang")
if (CXX_COMPILER_VERSION VERSION_LESS 4.2.1)
message(FATAL_ERROR "Clang version must be at least 3.4 (GCC >= 4.2.1 equivalent)!")
Expand Down

0 comments on commit 83c2775

Please sign in to comment.