Skip to content

Commit

Permalink
Add USE_TFMAN_STATIC option
Browse files Browse the repository at this point in the history
  • Loading branch information
data-man committed May 26, 2022
1 parent 7eb51cb commit edfb5d6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ option(BUILD_FFI_LIBRARY "Build ffi library (containing all symbols which are st
option(USE_POC "Build small, uninstalled proof-of-concept binaries" ON)
option(USE_QRCODEGEN "Enable libqrcodegen QR code support" OFF)
option(USE_STATIC "Build static libraries (in addition to shared)" ON)
option(USE_TFMAN_STATIC "Link tfman with notcurses statically" ON)
set(USE_MULTIMEDIA "ffmpeg" CACHE STRING "Multimedia engine, one of 'ffmpeg', 'oiio', or 'none'")
set_property(CACHE USE_MULTIMEDIA PROPERTY STRINGS ffmpeg oiio none)
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
Expand Down Expand Up @@ -746,13 +747,22 @@ target_include_directories(tfman
"${libdeflate_INCLUDE_DIRS}"
"${ZLIB_INCLUDE_DIRS}"
)
if(USE_TFMAN_STATIC AND USE_STATIC)
target_link_libraries(tfman
PRIVATE
notcurses-core-static
"${libdeflate}"
"${ZLIB_LIBRARIES}"
)
else()
target_link_libraries(tfman
PRIVATE
notcurses-core
"${libdeflate}"
"${ZLIB_LIBRARIES}"
)
endif()
endif()

############################################################################
# ncneofetch
Expand Down

0 comments on commit edfb5d6

Please sign in to comment.