diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2018-01-11 15:16:20 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2018-01-11 15:51:32 +0000 |
commit | f65711a29b4fa8c96a0e08e78edf3629863b3665 (patch) | |
tree | 96eec37669c5de34f82adf7241a28f8ef9b8c022 | |
parent | Merge pull request #3091 (diff) | |
download | monero-f65711a29b4fa8c96a0e08e78edf3629863b3665.tar.xz |
miniupnpc: always build with -fPIC
since we now build PIE binaries
-rw-r--r-- | external/miniupnpc/CMakeLists.txt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/external/miniupnpc/CMakeLists.txt b/external/miniupnpc/CMakeLists.txt index bc9685699..2df8d474b 100644 --- a/external/miniupnpc/CMakeLists.txt +++ b/external/miniupnpc/CMakeLists.txt @@ -73,6 +73,13 @@ if (CMAKE_COMPILER_IS_GNUC) endif () endif() +# always add -fPIC +set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") +set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -fPIC") +set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -fPIC") +set (CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO} -fPIC") +set (CMAKE_C_FLAGS_MINSIZEREL "${CMAKE_C_FLAGS_MINSIZEREL} -fPIC") + configure_file (${CMAKE_CURRENT_SOURCE_DIR}/miniupnpcstrings.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/miniupnpcstrings.h) include_directories (${CMAKE_CURRENT_BINARY_DIR}) |