diff options
author | Tom Rondeau <tom@trondeau.com> | 2014-06-27 15:10:31 -0400 |
---|---|---|
committer | Tom Rondeau <tom@trondeau.com> | 2014-06-28 13:58:57 -0400 |
commit | 0099eb9bd7a11afdf9276d6f4a5dafa757ebdb7c (patch) | |
tree | b278b8598719ce8a1284b1707c49d4e39c1a639c /gr-atsc | |
parent | 3d8a19b55a15a285d5a95d1e786cb93e26cb4f3a (diff) |
build: adds an ENABLE_STATIC_LIB option to cmake to build static (.a) versions of the libraries.
Diffstat (limited to 'gr-atsc')
-rw-r--r-- | gr-atsc/lib/CMakeLists.txt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gr-atsc/lib/CMakeLists.txt b/gr-atsc/lib/CMakeLists.txt index 22ea35c09e..5ac14fa118 100644 --- a/gr-atsc/lib/CMakeLists.txt +++ b/gr-atsc/lib/CMakeLists.txt @@ -127,6 +127,19 @@ add_library(gnuradio-atsc SHARED ${gr_atsc_sources}) target_link_libraries(gnuradio-atsc ${atsc_libs}) GR_LIBRARY_FOO(gnuradio-atsc RUNTIME_COMPONENT "atsc_runtime" DEVEL_COMPONENT "atsc_devel") +if(ENABLE_STATIC_LIBS) + add_library(gnuradio-atsc_static STATIC ${gr_atsc_sources}) + + if(NOT WIN32) + set_target_properties(gnuradio-atsc_static + PROPERTIES OUTPUT_NAME gnuradio-atsc) + endif(NOT WIN32) + + install(TARGETS gnuradio-atsc_static + ARCHIVE DESTINATION lib${LIB_SUFFIX} COMPONENT "atsc_devel" # .lib file + ) +endif(ENABLE_STATIC_LIBS) + ######################################################################## # Build and register unit test ######################################################################## |