aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/CMakeLists.txt8
-rw-r--r--tests/CMakeLists.txt8
2 files changed, 10 insertions, 6 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index ec773ae02..dfdf90b97 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -28,9 +28,11 @@
#
# Parts of this file are originally copyright (c) 2012-2013 The Cryptonote developers
-add_definitions(-DSTATICLIB)
-# miniupnp changed their static define
-add_definitions(-DMINIUPNP_STATICLIB)
+if (WIN32 AND STATIC)
+ add_definitions(-DSTATICLIB)
+ # miniupnp changed their static define
+ add_definitions(-DMINIUPNP_STATICLIB)
+endif ()
function (bitmonero_private_headers group)
source_group("${group}\\Private"
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 3da9fdb6b..0f99cab73 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -28,9 +28,11 @@
#
# Parts of this file are originally copyright (c) 2012-2013 The Cryptonote developers
-add_definitions(-DSTATICLIB)
-# miniupnp changed their static define
-add_definitions(-DMINIUPNP_STATICLIB)
+if (WIN32 AND STATIC)
+ add_definitions(-DSTATICLIB)
+ # miniupnp changed their static define
+ add_definitions(-DMINIUPNP_STATICLIB)
+endif ()
find_package(GTest)