2019-02-02 13:20:06 +08:00
|
|
|
if(NOT VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
|
|
|
|
message(FATAL_ERROR "This port currently only supports x64 architecture")
|
|
|
|
endif()
|
|
|
|
|
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO arrayfire/forge
|
2020-10-14 04:17:32 +08:00
|
|
|
REF 1a0f0cb6371a8c8053ab5eb7cbe3039c95132389 # v1.0.5
|
|
|
|
SHA512 8f8607421880a0f0013380eb5efb3a4f05331cd415d68c9cd84dd57eb727da1df6223fc6d65b106675d6aa09c3388359fab64443c31fadadf7641161be6b3b89
|
2019-02-02 13:20:06 +08:00
|
|
|
HEAD_REF master
|
2019-06-07 10:03:08 +08:00
|
|
|
PATCHES fix-static_build.patch
|
2019-02-02 13:20:06 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_configure_cmake(
|
|
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
|
|
PREFER_NINJA
|
|
|
|
OPTIONS
|
|
|
|
-DFG_BUILD_DOCS=OFF
|
|
|
|
-DFG_BUILD_EXAMPLES=OFF
|
|
|
|
-DFG_INSTALL_BIN_DIR=bin
|
|
|
|
-DFG_WITH_FREEIMAGE=OFF
|
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_install_cmake()
|
|
|
|
|
2020-01-09 08:33:48 +08:00
|
|
|
if (VCPKG_TARGET_IS_WINDOWS)
|
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH cmake)
|
|
|
|
else()
|
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH share/Forge/cmake)
|
|
|
|
endif()
|
2019-02-02 13:20:06 +08:00
|
|
|
|
|
|
|
file(GLOB DLLS ${CURRENT_PACKAGES_DIR}/bin/* ${CURRENT_PACKAGES_DIR}/debug/bin/*)
|
|
|
|
list(FILTER DLLS EXCLUDE REGEX "forge\\.dll\$")
|
|
|
|
file(REMOVE_RECURSE
|
|
|
|
${CURRENT_PACKAGES_DIR}/debug/include
|
2020-01-09 08:33:48 +08:00
|
|
|
${CURRENT_PACKAGES_DIR}/debug/share
|
2019-02-02 13:20:06 +08:00
|
|
|
${CURRENT_PACKAGES_DIR}/debug/examples
|
|
|
|
${CURRENT_PACKAGES_DIR}/examples
|
|
|
|
${DLLS}
|
|
|
|
)
|
|
|
|
|
2020-01-09 08:33:48 +08:00
|
|
|
file(INSTALL ${SOURCE_PATH}/.github/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
|