diff --git a/CMakeLists.txt b/CMakeLists.txt index 5613914f..d0c774ce 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -108,7 +108,7 @@ endif() if ((NOT CRYPTOPP_CROSS_COMPILE) AND (NOT (WINDOWS OR WINDOWS_STORE OR WINDOWS_PHONE))) # Use Regex; match i386, i486, i586 and i686 if (NOT (${UNAME_MACHINE} MATCHES "i.86")) - SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC") + SET(CMAKE_POSITION_INDEPENDENT_CODE 1) endif() endif()