summaryrefslogtreecommitdiff
path: root/volk/lib
diff options
context:
space:
mode:
authorTom Rondeau <tom@trondeau.com>2014-06-27 15:10:31 -0400
committerTom Rondeau <tom@trondeau.com>2014-06-28 13:58:57 -0400
commit0099eb9bd7a11afdf9276d6f4a5dafa757ebdb7c (patch)
treeb278b8598719ce8a1284b1707c49d4e39c1a639c /volk/lib
parent3d8a19b55a15a285d5a95d1e786cb93e26cb4f3a (diff)
build: adds an ENABLE_STATIC_LIB option to cmake to build static (.a) versions of the libraries.
Diffstat (limited to 'volk/lib')
-rw-r--r--volk/lib/CMakeLists.txt14
1 files changed, 13 insertions, 1 deletions
diff --git a/volk/lib/CMakeLists.txt b/volk/lib/CMakeLists.txt
index e25c5c65c7..d72eb726e4 100644
--- a/volk/lib/CMakeLists.txt
+++ b/volk/lib/CMakeLists.txt
@@ -472,6 +472,19 @@ install(TARGETS volk
RUNTIME DESTINATION bin COMPONENT "volk_runtime" # .dll file
)
+if(ENABLE_STATIC_LIBS)
+ add_library(volk_static STATIC ${volk_sources})
+
+ if(NOT WIN32)
+ set_target_properties(volk_static
+ PROPERTIES OUTPUT_NAME volk)
+ endif(NOT WIN32)
+
+ install(TARGETS volk_static
+ ARCHIVE DESTINATION lib${LIB_SUFFIX} COMPONENT "volk_devel" # .lib file
+ )
+endif(ENABLE_STATIC_LIBS)
+
########################################################################
# Build the QA test application
########################################################################
@@ -495,4 +508,3 @@ if(Boost_FOUND)
add_test(qa_volk_test_all test_all)
endif(Boost_FOUND)
-