vcpkg/ports/oatpp-postgresql/portfile.cmake
2020-11-05 18:21:17 -08:00

29 lines
928 B
CMake

set(OATPP_VERSION "1.2.0")
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO oatpp/oatpp-postgresql
REF 349d610084375c46be95d50ce10b787ae6c2baf4 # 1.2.0
SHA512 2faa688077020bbe64807be85d8d61e5aa84163a044d42df0a3b1701cf82048ff0322acb72d4e757a38403e14cba6a7a766daa965862e04756e483d9b750a365
HEAD_REF master
)
set(VCPKG_C_FLAGS "${VCPKG_CXX_FLAGS} -D_CRT_SECURE_NO_WARNINGS")
set(VCPKG_CXX_FLAGS "${VCPKG_CXX_FLAGS} -D_CRT_SECURE_NO_WARNINGS")
vcpkg_configure_cmake(
SOURCE_PATH "${SOURCE_PATH}"
PREFER_NINJA
OPTIONS
"-DOATPP_BUILD_TESTS:BOOL=OFF"
)
vcpkg_install_cmake()
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/oatpp-postgresql-${OATPP_VERSION})
vcpkg_copy_pdbs()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)