diff --git a/similarity_search/CMakeLists.txt b/similarity_search/CMakeLists.txt index 1451b30..2ad020f 100644 --- a/similarity_search/CMakeLists.txt +++ b/similarity_search/CMakeLists.txt @@ -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)!")