aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpradeep <pradeep.garigipati@gmail.com>2021-05-11 23:09:03 +0530
committerGitHub <noreply@github.com>2021-05-11 10:39:03 -0700
commit48678ea8b27e697ca613b6f1abff75f0984f370b (patch)
treee9398e770404346902fae2b1289552e750ba7718
parent56a5c2ac52835bcdfe5962568cf1e61376a1dd82 (diff)
downloadvcpkg-48678ea8b27e697ca613b6f1abff75f0984f370b.tar.gz
vcpkg-48678ea8b27e697ca613b6f1abff75f0984f370b.zip
[Forge] update version to 1.0.7 (#17099)
* [forge] Update forge to v1.0.7 tag - Use explicit cmake files install path - Use REF option in vcpkg_from_github command to fetch tag * [forge] Update version in baseline
-rw-r--r--ports/forge/cmake_config.patch59
-rw-r--r--ports/forge/fix-static_build.patch28
-rw-r--r--ports/forge/fix-usage.patch29
-rw-r--r--ports/forge/portfile.cmake19
-rw-r--r--ports/forge/vcpkg.json7
-rw-r--r--versions/baseline.json4
-rw-r--r--versions/f-/forge.json5
7 files changed, 75 insertions, 76 deletions
diff --git a/ports/forge/cmake_config.patch b/ports/forge/cmake_config.patch
new file mode 100644
index 000000000..eb77265a0
--- /dev/null
+++ b/ports/forge/cmake_config.patch
@@ -0,0 +1,59 @@
+diff --git a/CMakeModules/ForgeConfig.cmake.in b/CMakeModules/ForgeConfig.cmake.in
+index e4c7737..5a3b000 100644
+--- a/CMakeModules/ForgeConfig.cmake.in
++++ b/CMakeModules/ForgeConfig.cmake.in
+@@ -57,16 +57,24 @@ if (NOT TARGET Forge::forge AND
+ endif ()
+
+ if (TARGET Forge::forge)
+- get_property(config TARGET Forge::forge PROPERTY IMPORTED_CONFIGURATIONS)
+- if(NOT config)
+- set(config "NOCONFIG")
++ get_property(configs TARGET Forge::forge PROPERTY IMPORTED_CONFIGURATIONS)
++ if(NOT configs)
++ set(configs "NOCONFIG")
+ endif()
+- get_property(loc TARGET Forge::forge PROPERTY IMPORTED_LOCATION_${config})
++ foreach(config IN LISTS configs)
++ get_property(loc TARGET Forge::forge PROPERTY IMPORTED_LOCATION_${config})
++
++ # break if any of the imported configurations exist. All configs write to the same
++ # location so they are not working as CMake intended. Its fine for single config
++ # installers like ours.
++ if(EXISTS ${loc})
++ set(Forge_BINARY_EXISTS TRUE)
++ break()
++ endif()
++ endforeach()
+ endif ()
+
+-if ((TARGET Forge::forge AND EXISTS ${loc})
+- OR
+- TARGET forge)
++if ((TARGET Forge::forge AND Forge_BINARY_EXISTS) OR TARGET forge)
+ set(Forge_FOUND ON)
+ if (TARGET forge AND NOT TARGET Forge::forge)
+ add_library(Forge::forge ALIAS forge)
+@@ -75,3 +83,22 @@ if ((TARGET Forge::forge AND EXISTS ${loc})
+ 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()
diff --git a/ports/forge/fix-static_build.patch b/ports/forge/fix-static_build.patch
deleted file mode 100644
index 67f498cd8..000000000
--- a/ports/forge/fix-static_build.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-diff --git a/extern/glad/CMakeLists.txt b/extern/glad/CMakeLists.txt
-index c8c8d86..27adf86 100644
---- a/extern/glad/CMakeLists.txt
-+++ b/extern/glad/CMakeLists.txt
-@@ -2,15 +2,19 @@ add_library(forge_glad_interface INTERFACE)
-
- target_include_directories(forge_glad_interface
- INTERFACE
-- ${CMAKE_CURRENT_SOURCE_DIR}/include
-+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
- )
-
- target_sources(forge_glad_interface
- INTERFACE
-- ${CMAKE_CURRENT_SOURCE_DIR}/src/glad.c
-+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/glad.c>
- )
-
- target_link_libraries(forge_glad_interface
- INTERFACE
-- ${CMAKE_DL_LIBS}
-+ $<BUILD_INTERFACE:${CMAKE_DL_LIBS}>
- )
-+
-+if (NOT BUILD_SHARED_LIBS)
-+ install(TARGETS forge_glad_interface EXPORT ForgeTargets)
-+endif ()
-\ No newline at end of file
diff --git a/ports/forge/fix-usage.patch b/ports/forge/fix-usage.patch
deleted file mode 100644
index 5ce05e249..000000000
--- a/ports/forge/fix-usage.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-diff --git a/CMakeModules/ForgeConfig.cmake.in b/CMakeModules/ForgeConfig.cmake.in
-index e4c7737..6429069 100644
---- a/CMakeModules/ForgeConfig.cmake.in
-+++ b/CMakeModules/ForgeConfig.cmake.in
-@@ -52,16 +52,18 @@ set(Forge_FOUND OFF)
-
- if (NOT TARGET Forge::forge AND
- NOT TARGET forge AND
-- EXISTS @PACKAGE_CMAKE_DIR@/ForgeTargets.cmake)
-- include(@PACKAGE_CMAKE_DIR@/ForgeTargets.cmake)
-+ EXISTS ${CMAKE_CURRENT_LIST_DIR}/ForgeTargets.cmake)
-+ include(${CMAKE_CURRENT_LIST_DIR}/ForgeTargets.cmake)
- endif ()
-
- if (TARGET Forge::forge)
-- get_property(config TARGET Forge::forge PROPERTY IMPORTED_CONFIGURATIONS)
-- if(NOT config)
-- set(config "NOCONFIG")
-+ get_property(configs TARGET Forge::forge PROPERTY IMPORTED_CONFIGURATIONS)
-+ if(NOT configs)
-+ set(configs "NOCONFIG")
- endif()
-- get_property(loc TARGET Forge::forge PROPERTY IMPORTED_LOCATION_${config})
-+ foreach(config ${configs})
-+ get_property(loc TARGET Forge::forge PROPERTY IMPORTED_LOCATION_${config})
-+ endforeach()
- endif ()
-
- if ((TARGET Forge::forge AND EXISTS ${loc})
diff --git a/ports/forge/portfile.cmake b/ports/forge/portfile.cmake
index 1c3923e35..bdbd5ee80 100644
--- a/ports/forge/portfile.cmake
+++ b/ports/forge/portfile.cmake
@@ -5,31 +5,24 @@ endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO arrayfire/forge
- REF 1a0f0cb6371a8c8053ab5eb7cbe3039c95132389 # v1.0.5
- SHA512 8f8607421880a0f0013380eb5efb3a4f05331cd415d68c9cd84dd57eb727da1df6223fc6d65b106675d6aa09c3388359fab64443c31fadadf7641161be6b3b89
+ REF v1.0.7
+ SHA512 d341d5c6bdccf7d2f085162d1d8209b0b28d73b8a9f3173546b26f06bf8e422b3fdf1cfbaa7d122ea75cee5cf5f6bb6dbd2bffc10d8e0c336b5b8695c39f7b54
HEAD_REF master
- PATCHES
- fix-static_build.patch
- fix-usage.patch
+ PATCHES cmake_config.patch
)
+file(REMOVE ${SOURCE_PATH}/CMakeModules/FindOpenGL.cmake)
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
+ -DFG_INSTALL_CMAKE_DIR=share/Forge
)
vcpkg_install_cmake()
-
-if (VCPKG_TARGET_IS_WINDOWS)
- vcpkg_fixup_cmake_targets(CONFIG_PATH cmake)
-else()
- vcpkg_fixup_cmake_targets(CONFIG_PATH share/Forge/cmake)
-endif()
+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\$")
diff --git a/ports/forge/vcpkg.json b/ports/forge/vcpkg.json
index 05d7a3a13..52d62400b 100644
--- a/ports/forge/vcpkg.json
+++ b/ports/forge/vcpkg.json
@@ -1,8 +1,7 @@
{
"name": "forge",
- "version-semver": "1.0.5",
- "port-version": 1,
- "description": "Helps with high performance visualizations involving OpenGL-CUDA/OpenCL interop.",
+ "version-semver": "1.0.7",
+ "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": [
@@ -13,7 +12,7 @@
},
"freeimage",
"freetype",
- "glbinding",
+ "glad",
"glfw3",
"glm"
]
diff --git a/versions/baseline.json b/versions/baseline.json
index 929eb83fa..e98d58e8d 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -2049,8 +2049,8 @@
"port-version": 0
},
"forge": {
- "baseline": "1.0.5",
- "port-version": 1
+ "baseline": "1.0.7",
+ "port-version": 0
},
"fp16": {
"baseline": "2021-02-21",
diff --git a/versions/f-/forge.json b/versions/f-/forge.json
index 9f302b28b..a74daa624 100644
--- a/versions/f-/forge.json
+++ b/versions/f-/forge.json
@@ -1,6 +1,11 @@
{
"versions": [
{
+ "git-tree": "ca5513200ad2efb90936120fdfc7ea8bb6730f9d",
+ "version-semver": "1.0.7",
+ "port-version": 0
+ },
+ {
"git-tree": "b160185b8e2d1f0bd2268cb56d73e0e6a2940f69",
"version-semver": "1.0.5",
"port-version": 1