Commit 2804c313 authored by Dominik Charousset's avatar Dominik Charousset

Set -fPIC on static builds

parent abbb245c
...@@ -4,7 +4,7 @@ project(caf C CXX) ...@@ -4,7 +4,7 @@ project(caf C CXX)
include(CheckCSourceCompiles) include(CheckCSourceCompiles)
include(CheckCSourceRuns) include(CheckCSourceRuns)
# Set default install paths. # Set default install paths.
# See https://cmake.org/cmake/help/latest/module/GNUInstallDirs.html # See https://cmake.org/cmake/help/latest/module/GNUInstallDirs.html
include(GNUInstallDirs) include(GNUInstallDirs)
...@@ -341,7 +341,7 @@ if(MINGW) ...@@ -341,7 +341,7 @@ if(MINGW)
build_string("EXTRA_FLAGS" "-static") build_string("EXTRA_FLAGS" "-static")
elseif(CYGWIN) elseif(CYGWIN)
build_string("EXTRA_FLAGS" "-U__STRICT_ANSI__") build_string("EXTRA_FLAGS" "-U__STRICT_ANSI__")
elseif(NOT CAF_BUILD_STATIC_ONLY) else()
build_string("EXTRA_FLAGS" "-fPIC") build_string("EXTRA_FLAGS" "-fPIC")
endif() endif()
if (WIN32) if (WIN32)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment