aboutsummaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
Diffstat (limited to 'external')
-rw-r--r--external/db_drivers/liblmdb/CMakeLists.txt1
-rw-r--r--external/easylogging++/CMakeLists.txt1
-rw-r--r--external/easylogging++/ea_config.h2
-rw-r--r--external/miniupnpc/CMakeLists.txt7
-rw-r--r--external/unbound/CMakeLists.txt1
5 files changed, 12 insertions, 0 deletions
diff --git a/external/db_drivers/liblmdb/CMakeLists.txt b/external/db_drivers/liblmdb/CMakeLists.txt
index d3d3df6ad..3a09712de 100644
--- a/external/db_drivers/liblmdb/CMakeLists.txt
+++ b/external/db_drivers/liblmdb/CMakeLists.txt
@@ -54,3 +54,4 @@ if(${ARCH_WIDTH} EQUAL 32)
target_compile_definitions(lmdb
PUBLIC -DMDB_VL32)
endif()
+set_property(TARGET lmdb APPEND PROPERTY COMPILE_FLAGS "-fPIC")
diff --git a/external/easylogging++/CMakeLists.txt b/external/easylogging++/CMakeLists.txt
index 97d0bf571..8fe3fa487 100644
--- a/external/easylogging++/CMakeLists.txt
+++ b/external/easylogging++/CMakeLists.txt
@@ -54,4 +54,5 @@ if (BUILD_GUI_DEPS)
ARCHIVE DESTINATION ${lib_folder}
LIBRARY DESTINATION ${lib_folder})
endif()
+set_property(TARGET easylogging APPEND PROPERTY COMPILE_FLAGS "-fPIC")
diff --git a/external/easylogging++/ea_config.h b/external/easylogging++/ea_config.h
index c97858f30..4c74925d3 100644
--- a/external/easylogging++/ea_config.h
+++ b/external/easylogging++/ea_config.h
@@ -8,5 +8,7 @@
#define ELPP_NO_DEBUG_MACROS
#ifdef EASYLOGGING_CC
+#if !(!defined __GNUC__ || defined __MINGW32__ || defined __MINGW64__ || defined __ANDROID__)
#define ELPP_FEATURE_CRASH_LOG
#endif
+#endif
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})
diff --git a/external/unbound/CMakeLists.txt b/external/unbound/CMakeLists.txt
index 99ef62c5a..7d4da33e2 100644
--- a/external/unbound/CMakeLists.txt
+++ b/external/unbound/CMakeLists.txt
@@ -50,6 +50,7 @@ else()
add_definitions(-D_GNU_SOURCE)
endif()
add_definitions(-std=c99)
+add_definitions(-fPIC)
option(USE_ECDSA "Use ECDSA algorithms" ON)
option(USE_SHA2 "Enable SHA2 support" ON)