Permalink
Browse files

Merge pull request #181 from rusdevops/patch-2

Update CMakeLists.txt
  • Loading branch information...
vincent-richard committed Mar 12, 2018
2 parents f04190b + 51af739 commit ed825ba255f2d56ad5d70c194859ecd7241db1dd
Showing with 12 additions and 0 deletions.
  1. +12 −0 CMakeLists.txt
@@ -109,6 +109,10 @@ IF(VMIME_BUILD_SHARED_LIBRARY)
${VMIME_LIBRARY_INCLUDE_FILES}
)
TARGET_INCLUDE_DIRECTORIES(${VMIME_LIBRARY_NAME} PUBLIC
$<INSTALL_INTERFACE:include>
)
GENERATE_EXPORT_HEADER(
${VMIME_LIBRARY_NAME}
BASE_NAME VMIME
@@ -154,6 +158,10 @@ IF(VMIME_BUILD_STATIC_LIBRARY)
${VMIME_LIBRARY_INCLUDE_FILES}
)
TARGET_INCLUDE_DIRECTORIES(${VMIME_LIBRARY_NAME}-static PUBLIC
$<INSTALL_INTERFACE:include>
)
GENERATE_EXPORT_HEADER(
${VMIME_LIBRARY_NAME}-static
BASE_NAME VMIME
@@ -199,6 +207,7 @@ SET(CMAKE_INSTALL_LIBDIR lib CACHE PATH "Output directory for libraries")
IF(VMIME_BUILD_SHARED_LIBRARY)
INSTALL(
TARGETS ${VMIME_LIBRARY_NAME}
EXPORT ${VMIME_LIBRARY_NAME}-config
LIBRARY DESTINATION "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" COMPONENT sharedlibs
ARCHIVE DESTINATION "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" COMPONENT sharedlibs
)
@@ -207,6 +216,7 @@ ENDIF()
IF(VMIME_BUILD_STATIC_LIBRARY)
INSTALL(
TARGETS ${VMIME_LIBRARY_NAME}-static
EXPORT ${VMIME_LIBRARY_NAME}-config
LIBRARY DESTINATION "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" COMPONENT staticlibs
ARCHIVE DESTINATION "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" COMPONENT staticlibs
)
@@ -222,6 +232,8 @@ INSTALL_HEADERS_WITH_DIRECTORY(VMIME_LIBRARY_GENERATED_INCLUDE_FILES headers "${
# COMPONENT headers
#)
install(EXPORT ${VMIME_LIBRARY_NAME}-config DESTINATION cmake)
##############################################################################
# Tests

0 comments on commit ed825ba

Please sign in to comment.