[jansson] Enable cmake scripts

This commit is contained in:
Robert Schumacher 2017-06-20 16:19:36 -07:00
parent e4e2d27ee9
commit 833c38c630
2 changed files with 6 additions and 9 deletions

View File

@ -30,17 +30,10 @@ vcpkg_configure_cmake(
-DJANSSON_BUILD_SHARED_LIBS=${JANSSON_BUILD_SHARED_LIBS}
)
vcpkg_install_cmake(DISABLE_PARALLEL)
vcpkg_fixup_cmake_targets(CONFIG_PATH cmake)
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/jansson RENAME copyright)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/cmake)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/cmake)
if(VCPKG_CRT_LINKAGE STREQUAL static)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
endif()
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/jansson RENAME copyright)
vcpkg_copy_pdbs()

View File

@ -16,6 +16,10 @@
function(vcpkg_fixup_cmake_targets)
cmake_parse_arguments(_vfct "" "CONFIG_PATH" "" ${ARGN})
if(_vfct_UNPARSED_ARGUMENTS)
message(FATAL_ERROR "vcpkg_fixup_cmake_targets was passed extra arguments: ${_vfct_UNPARSED_ARGUMENTS}")
endif()
set(DEBUG_SHARE ${CURRENT_PACKAGES_DIR}/debug/share/${PORT})
set(RELEASE_SHARE ${CURRENT_PACKAGES_DIR}/share/${PORT})