aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/3fd
diff options
context:
space:
mode:
authorEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
committerEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
commit54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch)
treed915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/3fd
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/3fd')
-rw-r--r--vcpkg/ports/3fd/RapidXML.patch10
-rw-r--r--vcpkg/ports/3fd/portfile.cmake55
-rw-r--r--vcpkg/ports/3fd/vcpkg.json33
3 files changed, 98 insertions, 0 deletions
diff --git a/vcpkg/ports/3fd/RapidXML.patch b/vcpkg/ports/3fd/RapidXML.patch
new file mode 100644
index 0000000..6373fc2
--- /dev/null
+++ b/vcpkg/ports/3fd/RapidXML.patch
@@ -0,0 +1,10 @@
+--- a/3FD/xml.h
++++ b/3FD/xml.h
+@@ -4,6 +4,6 @@
+ #include "exceptions.h"
+ #include "utils.h"
+-#include <rapidxml.hpp>
++#include <rapidxml/rapidxml.hpp>
+
+ #include <array>
+ #include <algorithm>
diff --git a/vcpkg/ports/3fd/portfile.cmake b/vcpkg/ports/3fd/portfile.cmake
new file mode 100644
index 0000000..82ff6fc
--- /dev/null
+++ b/vcpkg/ports/3fd/portfile.cmake
@@ -0,0 +1,55 @@
+# Check library linkage:
+vcpkg_check_linkage(ONLY_STATIC_LIBRARY ONLY_DYNAMIC_CRT)
+
+# Get source code:
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO faburaya/3fd
+ REF 3a0fe606268721d1560b88dcca8647c67c0b275c # v2.6.3 (Stable)
+ SHA512 70630291b4055de2044ad76ef21e99d6ab6fd3468debb2a864a461cf8513642fe87f116e9dfff96ecff96f4577108493dc25aa40eeefcd93ee75990b13bb7b20
+ HEAD_REF master
+ PATCHES
+ RapidXML.patch
+)
+
+# Build:
+if (VCPKG_TARGET_IS_UWP) # UWP:
+ vcpkg_msbuild_install(
+ SOURCE_PATH "${SOURCE_PATH}"
+ PROJECT_SUBPATH "3FD/3FD.WinRT.UWP.vcxproj"
+ )
+elseif (VCPKG_TARGET_IS_WINDOWS) # Win32:
+ vcpkg_msbuild_install(
+ SOURCE_PATH "${SOURCE_PATH}"
+ PROJECT_SUBPATH "3FD/3FD.vcxproj"
+ TARGET Build
+ )
+else()
+ message(FATAL_ERROR "Unsupported system: 3FD is not currently ported to VCPKG in ${VCPKG_CMAKE_SYSTEM_NAME}!")
+endif()
+
+# Install:
+file(GLOB HEADER_FILES LIST_DIRECTORIES false "${SOURCE_PATH}/3FD/*.h")
+file(INSTALL
+ ${HEADER_FILES}
+ DESTINATION "${CURRENT_PACKAGES_DIR}/include/3FD"
+ PATTERN "*_impl*.h" EXCLUDE
+ PATTERN "*example*.h" EXCLUDE
+ PATTERN "stdafx.h" EXCLUDE
+ PATTERN "targetver.h" EXCLUDE
+)
+
+file(INSTALL "${SOURCE_PATH}/btree" DESTINATION "${CURRENT_PACKAGES_DIR}/include/3FD")
+file(INSTALL "${SOURCE_PATH}/OpenCL/CL" DESTINATION "${CURRENT_PACKAGES_DIR}/include/3FD")
+
+file(MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/share/3FD")
+file(INSTALL
+ "${SOURCE_PATH}/3FD/3fd-config-template.xml"
+ DESTINATION "${CURRENT_PACKAGES_DIR}/share/3FD"
+)
+
+# Handle copyright
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
+file(INSTALL "${SOURCE_PATH}/Acknowledgements.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/3fd")
+
+vcpkg_copy_pdbs()
diff --git a/vcpkg/ports/3fd/vcpkg.json b/vcpkg/ports/3fd/vcpkg.json
new file mode 100644
index 0000000..760828e
--- /dev/null
+++ b/vcpkg/ports/3fd/vcpkg.json
@@ -0,0 +1,33 @@
+{
+ "name": "3fd",
+ "version": "2.6.3",
+ "port-version": 5,
+ "description": "C++ Framework For Fast Development",
+ "supports": "windows & !static & !arm64",
+ "dependencies": [
+ {
+ "name": "boost-lockfree",
+ "platform": "windows"
+ },
+ {
+ "name": "boost-regex",
+ "platform": "windows"
+ },
+ {
+ "name": "poco",
+ "default-features": false,
+ "features": [
+ "data",
+ "odbc"
+ ],
+ "platform": "windows"
+ },
+ "rapidxml",
+ "sqlite3",
+ {
+ "name": "vcpkg-msbuild",
+ "host": true,
+ "platform": "windows"
+ }
+ ]
+}