[x265] [PATCH] cmake: make it more clear that the extra libs are only linked to the CLI

Steve Borho steve at borho.org
Mon Jun 22 21:34:38 CEST 2015


# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1435001649 18000
#      Mon Jun 22 14:34:09 2015 -0500
# Node ID 537c5fd8f5d59f5a5f8b3c7a5616e856906eeb49
# Parent  af4ab43b2cf0d240a76a100d5174c792ac50a393
cmake: make it more clear that the extra libs are only linked to the CLI

this was already what was happening, in effect, but not it is more clear

diff -r af4ab43b2cf0 -r 537c5fd8f5d5 source/CMakeLists.txt
--- a/source/CMakeLists.txt	Mon Jun 22 14:25:57 2015 -0500
+++ b/source/CMakeLists.txt	Mon Jun 22 14:34:09 2015 -0500
@@ -394,9 +394,6 @@
 if(NOT MSVC)
     set_target_properties(x265-static PROPERTIES OUTPUT_NAME x265)
 endif()
-if(EXTRA_LIB)
-    target_link_libraries(x265-static ${EXTRA_LIB})
-endif()
 if(EXTRA_LINK_FLAGS)
     list(APPEND LINKER_OPTIONS ${EXTRA_LINK_FLAGS})
 endif()
@@ -528,6 +525,9 @@
         endif()
     endif()
     set_target_properties(cli PROPERTIES OUTPUT_NAME x265)
+    if(EXTRA_LIB)
+        target_link_libraries(cli ${EXTRA_LIB})
+    endif()
     if(LINKER_OPTIONS)
         # set_target_properties can't do list expansion
         string(REPLACE ";" " " LINKER_OPTION_STR "${LINKER_OPTIONS}")


More information about the x265-devel mailing list