mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-24 23:11:08 +08:00
7808b25b12
* [log4cxx] update to 1.2.0 * [log4cxx] update to 1.2.0
40 lines
1.3 KiB
CMake
40 lines
1.3 KiB
CMake
vcpkg_download_distfile(ARCHIVE
|
|
URLS "https://archive.apache.org/dist/logging/log4cxx/${VERSION}/apache-log4cxx-${VERSION}.tar.gz"
|
|
FILENAME "apache-log4cxx-${VERSION}.tar.gz"
|
|
SHA512 377234407c5f1128fbff6e5d2fcda3f53aae275962cd9207257674fa016095f4bc4ac0c318c1ba2a75f3252402cce0776c1211ffa917a60f8a89a12f01d45efb
|
|
)
|
|
|
|
vcpkg_extract_source_archive(
|
|
SOURCE_PATH ARCHIVE "${ARCHIVE}"
|
|
PATCHES
|
|
fix-find-package.patch
|
|
)
|
|
|
|
vcpkg_cmake_configure(
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
OPTIONS
|
|
-DLOG4CXX_INSTALL_PDB=OFF # Installing pdbs failed on debug static. So, disable it and let vcpkg_copy_pdbs() do it
|
|
-DBUILD_TESTING=OFF
|
|
)
|
|
|
|
vcpkg_cmake_install()
|
|
vcpkg_copy_pdbs()
|
|
|
|
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/log4cxx)
|
|
|
|
if(VCPKG_TARGET_IS_LINUX OR VCPKG_TARGET_IS_OSX)
|
|
vcpkg_fixup_pkgconfig()
|
|
endif()
|
|
|
|
file(READ "${CURRENT_PACKAGES_DIR}/share/${PORT}/log4cxxConfig.cmake" _contents)
|
|
file(WRITE "${CURRENT_PACKAGES_DIR}/share/${PORT}/log4cxxConfig.cmake"
|
|
"include(CMakeFindDependencyMacro)
|
|
find_dependency(expat CONFIG)
|
|
${_contents}"
|
|
)
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share")
|
|
|
|
# Handle copyright
|
|
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|