]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
just link the archive_static with ADDITIONAL_LIBS 77/head
authorJosh Klontz <Joshua.Klontz@noblis.org>
Tue, 15 Apr 2014 20:53:41 +0000 (16:53 -0400)
committerJosh Klontz <Joshua.Klontz@noblis.org>
Tue, 15 Apr 2014 20:53:41 +0000 (16:53 -0400)
CMakeLists.txt
libarchive/CMakeLists.txt

index d75db8fba757747d13c584ff6caf5c08f7c78f1c..2cdb9fb4858566341fd845b3d0cb2a81916f70e7 100644 (file)
@@ -1491,12 +1491,6 @@ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/build/cmake/config.h.in
 INCLUDE_DIRECTORIES(BEFORE ${CMAKE_CURRENT_BINARY_DIR})
 ADD_DEFINITIONS(-DHAVE_CONFIG_H)
 
-#
-# Expose ADDITIONAL_LIBS for projects using libarchive as a subdirectory
-# and linking against archive_static.
-#
-set(LIBARCHIVE_ADDITIONAL_LIBS ${ADDITIONAL_LIBS} CACHE INTERNAL "libarchive dependencies")
-
 #
 # Register installation of PDF documents.
 #
index ecb0409bd9d881b98608098f9f72a6f8bc287809..c146cec13c6ced88d2b7c8b4a9ddeb4faa377f81 100644 (file)
@@ -175,6 +175,7 @@ SET_TARGET_PROPERTIES(archive PROPERTIES SOVERSION ${SOVERSION})
 
 # archive_static is a static library
 ADD_LIBRARY(archive_static STATIC ${libarchive_SOURCES} ${include_HEADERS})
+TARGET_LINK_LIBRARIES(archive_static ${ADDITIONAL_LIBS})
 SET_TARGET_PROPERTIES(archive_static PROPERTIES COMPILE_DEFINITIONS
   LIBARCHIVE_STATIC)
 # On Posix systems, libarchive.so and libarchive.a can co-exist.