early-access version 2853
This commit is contained in:
27
externals/vcpkg/ports/forge/cmake_config.patch
vendored
Executable file
27
externals/vcpkg/ports/forge/cmake_config.patch
vendored
Executable file
@@ -0,0 +1,27 @@
|
||||
diff --git a/CMakeModules/ForgeConfig.cmake.in b/CMakeModules/ForgeConfig.cmake.in
|
||||
index 6fb18ac..5a3b000 100644
|
||||
--- a/CMakeModules/ForgeConfig.cmake.in
|
||||
+++ b/CMakeModules/ForgeConfig.cmake.in
|
||||
@@ -83,3 +83,22 @@ if ((TARGET Forge::forge AND Forge_BINARY_EXISTS) OR TARGET forge)
|
||||
else ()
|
||||
set(Forge_FOUND OFF)
|
||||
endif ()
|
||||
+
|
||||
+if(Forge_FOUND)
|
||||
+ # Check for dependencies when Forge binary and cmake files are found
|
||||
+ include(CMakeFindDependencyMacro)
|
||||
+
|
||||
+ find_dependency(glad CONFIG)
|
||||
+ find_dependency(glfw3 CONFIG)
|
||||
+ find_dependency(freetype CONFIG)
|
||||
+ find_dependency(freeimage CONFIG)
|
||||
+ find_dependency(OpenGL)
|
||||
+
|
||||
+ if(NOT WIN32)
|
||||
+ find_package(PkgConfig REQUIRED)
|
||||
+ pkg_check_modules(fontconfig REQUIRED)
|
||||
+ if(NOT fontconfig_FOUND)
|
||||
+ message(FATAL_ERROR "Please install Fontconfig dependency")
|
||||
+ endif()
|
||||
+ endif()
|
||||
+endif()
|
||||
37
externals/vcpkg/ports/forge/portfile.cmake
vendored
Executable file
37
externals/vcpkg/ports/forge/portfile.cmake
vendored
Executable file
@@ -0,0 +1,37 @@
|
||||
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
|
||||
REF v1.0.8
|
||||
SHA512 08e5eb89d80f7fa3310f0eb37481492b5c1dfff00b33c308169862d8b25cf93ad1d9c0db78667c0207a7f6f8ca4046c196bd3a987af839ea1864b49c738ee8e3
|
||||
HEAD_REF master
|
||||
PATCHES cmake_config.patch
|
||||
)
|
||||
file(REMOVE ${SOURCE_PATH}/CMakeModules/FindOpenGL.cmake)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
OPTIONS
|
||||
-DFG_BUILD_DOCS=OFF
|
||||
-DFG_BUILD_EXAMPLES=OFF
|
||||
-DFG_INSTALL_BIN_DIR=bin
|
||||
-DFG_INSTALL_CMAKE_DIR=share/Forge
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
vcpkg_fixup_cmake_targets(CONFIG_PATH share/Forge TARGET_PATH share/Forge)
|
||||
|
||||
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
|
||||
${CURRENT_PACKAGES_DIR}/debug/share
|
||||
${CURRENT_PACKAGES_DIR}/debug/examples
|
||||
${CURRENT_PACKAGES_DIR}/examples
|
||||
${DLLS}
|
||||
)
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/.github/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
|
||||
19
externals/vcpkg/ports/forge/vcpkg.json
vendored
Executable file
19
externals/vcpkg/ports/forge/vcpkg.json
vendored
Executable file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "forge",
|
||||
"version-semver": "1.0.8",
|
||||
"description": "An OpenGL interop library that can be used with ArrayFire or any other application using CUDA or OpenCL compute backend.",
|
||||
"homepage": "https://github.com/arrayfire/forge",
|
||||
"supports": "x64",
|
||||
"dependencies": [
|
||||
"boost-functional",
|
||||
{
|
||||
"name": "fontconfig",
|
||||
"platform": "!windows"
|
||||
},
|
||||
"freeimage",
|
||||
"freetype",
|
||||
"glad",
|
||||
"glfw3",
|
||||
"glm"
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user