mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-30 15:19:05 +08:00
39 lines
1.1 KiB
CMake
39 lines
1.1 KiB
CMake
if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
|
|
message(FATAL_ERROR "${PORT} does not currently support UWP")
|
|
endif()
|
|
|
|
include(vcpkg_common_functions)
|
|
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO gflags/gflags
|
|
REF v2.2.0
|
|
SHA512 e2106ca70ff539024f888bca12487b3bf7f4f51928acf5ae3e1022f6bbd5e3b7882196ec50b609fd52f739e1f7b13eec7d4b3535d8216ec019a3577de6b4228d
|
|
HEAD_REF master
|
|
)
|
|
|
|
vcpkg_apply_patches(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PATCHES "${CMAKE_CURRENT_LIST_DIR}/fix-install.patch"
|
|
PATCHES "${CMAKE_CURRENT_LIST_DIR}/fix-static-linking.patch"
|
|
)
|
|
|
|
vcpkg_configure_cmake(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PREFER_NINJA
|
|
OPTIONS
|
|
-DGFLAGS_REGISTER_BUILD_DIR:BOOL=OFF
|
|
-DGFLAGS_REGISTER_INSTALL_PREFIX:BOOL=OFF
|
|
-DBUILD_gflags_nothreads_LIB:BOOL=OFF
|
|
)
|
|
|
|
vcpkg_install_cmake()
|
|
vcpkg_fixup_cmake_targets()
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
|
|
file(INSTALL ${SOURCE_PATH}/COPYING.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/gflags RENAME copyright)
|
|
|
|
vcpkg_copy_pdbs()
|