pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

wip/openjfx21: import openjfx21-21.0.8



Module Name:	pkgsrc-wip
Committed By:	Ryo ONODERA <ryoon%NetBSD.org@localhost>
Pushed By:	ryoon
Date:		Tue Aug 12 13:08:03 2025 +0900
Changeset:	d008de868b4f23b0f1e9033b41a43654ec8a94f7

Added Files:
	openjfx21/DESCR
	openjfx21/Makefile
	openjfx21/PLIST
	openjfx21/distinfo
	openjfx21/files/netbsd.gradle
	openjfx21/patches/patch-apps_samples_Ensemble8_src_app_java_ensemble_PlatformFeatures.java
	openjfx21/patches/patch-build.gradle
	openjfx21/patches/patch-modules_javafx.base_src_main_java_com_sun_javafx_PlatformUtil.java
	openjfx21/patches/patch-modules_javafx.controls_src_main_java_com_sun_javafx_scene_control_behavior_TextInputControlBehavior.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_ui_Platform.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_utils_NativeLibLoader.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_LogicalFont.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_PrismFontFactory.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_Toolkit.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_GlassSystemMenu.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_WindowStage.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_prism_impl_PrismSettings.java
	openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_launcher.c
	openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_wrapped.c
	openjfx21/patches/patch-modules_javafx.graphics_src_main_native-prism-es2_PrismES2Defs.h
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_check-xcfilelists.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_generate-unified-sources.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_check-xcfilelists.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_generate-unified-sources.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_check-xcfilelists.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_generate-unified-sources.sh
	openjfx21/patches/patch-modules_javafx.web_src_main_native_Tools_DumpRenderTree_Scripts_check-xcfilelists.sh

Log Message:
wip/openjfx21: import openjfx21-21.0.8

OpenJFX is an open source, next generation client application
platform for desktop, mobile and embedded systems based on JavaSE.
It is a collaborative effort by many individuals and companies with
the goal of producing a modern, efficient, and fully featured
toolkit for developing rich client applications. This is the open
source project where we develop JavaFX.

OpenJFX is free software, licensed under GPL v2 with the Classpath
exception, just like the JDK. Anybody is welcome to contribute to
this project, port it to other platforms or devices, or do anything
else that a free software license allows you to do!

This package tacks OpenJFX 21.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=d008de868b4f23b0f1e9033b41a43654ec8a94f7

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 openjfx21/DESCR                                    |  13 +
 openjfx21/Makefile                                 | 102 +++++++
 openjfx21/PLIST                                    |  27 ++
 openjfx21/distinfo                                 |  39 +++
 openjfx21/files/netbsd.gradle                      | 296 +++++++++++++++++++++
 ...le8_src_app_java_ensemble_PlatformFeatures.java |  12 +
 openjfx21/patches/patch-build.gradle               |  83 ++++++
 ..._src_main_java_com_sun_javafx_PlatformUtil.java |  32 +++
 ..._control_behavior_TextInputControlBehavior.java |  30 +++
 ...cs_src_main_java_com_sun_glass_ui_Platform.java |  13 +
 ...n_java_com_sun_glass_utils_NativeLibLoader.java |  32 +++
 ..._main_java_com_sun_javafx_font_LogicalFont.java |  13 +
 ..._java_com_sun_javafx_font_PrismFontFactory.java |  47 ++++
 ...cs_src_main_java_com_sun_javafx_tk_Toolkit.java |  13 +
 ..._com_sun_javafx_tk_quantum_GlassSystemMenu.java |  37 +++
 ...java_com_sun_javafx_tk_quantum_WindowStage.java |  13 +
 ...main_java_com_sun_prism_impl_PrismSettings.java |  13 +
 ...x.graphics_src_main_native-glass_gtk_launcher.c |  14 +
 ...fx.graphics_src_main_native-glass_gtk_wrapped.c |  14 +
 ...aphics_src_main_native-prism-es2_PrismES2Defs.h |  13 +
 ...rce_JavaScriptCore_Scripts_check-xcfilelists.sh |  16 ++
 ...aScriptCore_Scripts_generate-unified-sources.sh |  13 +
 ...ive_Source_WebCore_Scripts_check-xcfilelists.sh |  16 ++
 ...rce_WebCore_Scripts_generate-unified-sources.sh |  22 ++
 ...ource_WebKitLegacy_scripts_check-xcfilelists.sh |  16 ++
 ...ebKitLegacy_scripts_generate-unified-sources.sh |  13 +
 ...ols_DumpRenderTree_Scripts_check-xcfilelists.sh |  16 ++
 27 files changed, 968 insertions(+)

diffs:
diff --git a/openjfx21/DESCR b/openjfx21/DESCR
new file mode 100644
index 0000000000..4368d61b8f
--- /dev/null
+++ b/openjfx21/DESCR
@@ -0,0 +1,13 @@
+OpenJFX is an open source, next generation client application
+platform for desktop, mobile and embedded systems based on JavaSE.
+It is a collaborative effort by many individuals and companies with
+the goal of producing a modern, efficient, and fully featured
+toolkit for developing rich client applications. This is the open
+source project where we develop JavaFX.
+
+OpenJFX is free software, licensed under GPL v2 with the Classpath
+exception, just like the JDK. Anybody is welcome to contribute to
+this project, port it to other platforms or devices, or do anything
+else that a free software license allows you to do!
+
+This package tacks OpenJFX 21.
diff --git a/openjfx21/Makefile b/openjfx21/Makefile
new file mode 100644
index 0000000000..8f88c83dce
--- /dev/null
+++ b/openjfx21/Makefile
@@ -0,0 +1,102 @@
+# $NetBSD$
+
+DISTNAME=	jfx21u-21.0.8+2
+PKGNAME=	${DISTNAME:S/jfx21u-/openjfx21-/:C/\\+[[:digit:]\.]*//}
+CATEGORIES=	x11
+MASTER_SITES=	${MASTER_SITE_GITHUB:=openjdk/}
+GITHUB_PROJECT=	jfx21u
+GITHUB_TAG=	21.0.8+2
+
+MAINTAINER=	ryoon%NetBSD.org@localhost
+HOMEPAGE=	https://github.com/openjdk/jfx21u/
+COMMENT=	JavaFX is Java client application platform
+LICENSE=	gnu-gpl-v2
+
+JARS+=		lucene-core-7.7.3.jar
+JARS+=		lucene-grouping-7.7.3.jar
+JARS+=		lucene-queryparser-7.7.3.jar
+JARS+=		antlr4-4.7.2-complete.jar
+
+DISTFILES=	${DEFAULT_DISTFILES} ${JARS}
+
+SITES.lucene-core-7.7.3.jar=		https://repo.maven.apache.org/maven2/org/apache/lucene/lucene-core/7.7.3/
+SITES.lucene-grouping-7.7.3.jar=	https://repo.maven.apache.org/maven2/org/apache/lucene/lucene-grouping/7.7.3/
+SITES.lucene-queryparser-7.7.3.jar=	https://repo.maven.apache.org/maven2/org/apache/lucene/lucene-queryparser/7.7.3/
+SITES.antlr4-4.7.2-complete.jar=	https://repo1.maven.org/maven2/org/antlr/antlr4/4.7.2/
+
+DEPENDS+=	swt-[0-9]*:../../x11/swt
+
+WRKSRC=		${WRKDIR}/jfx21u-21.0.8-2
+USE_TOOLS+=	pkg-config
+USE_LANGUAGES=	c c++
+
+PKGCONFIG_OVERRIDE+=	modules/javafx.web/src/main/native/Source/JavaScriptCore/javascriptcoregtk.pc.in
+
+USE_JAVA=	yes
+USE_JAVA2=	21
+
+TOOL_DEPENDS+=	gradle-[0-9]*:../../devel/gradle
+MAKE_ENV+=	GRADLE_USER_HOME=${WRKDIR}/.gradle
+
+# Should use pkg-config for libX11 inside gradle instead.
+CXX_LDFLAGS+=		-L${PREFIX}/lib
+CXX_LDFLAGS+=		${COMPILER_RPATH_FLAG}${PREFIX}/lib
+_WRAP_EXTRA_ARGS.CXX+=	${CXX_LDFLAGS}
+CWRAPPERS_PREPEND.cxx+=	${CXX_LDFLAGS}
+
+# For pipewire header file
+CC_CPPFLAGS+=	-I${BUILDLINK_DIR}/include/pipewire-0.3
+CC_CPPFLAGS+=	-I${BUILDLINK_DIR}/include/spa-0.2
+.include "../../mk/bsd.fast.prefs.mk"
+.if ${OPSYS} == "NetBSD"
+CC_CPPFLAGS+=	-D__LOCALE_C_ONLY
+.endif
+_WRAP_EXTRA_ARGS.CC+=	${CC_CPPFLAGS}
+CWRAPPERS_PREPEND.cc+=	${CC_CPPFLAGS}
+
+post-patch:
+	# Do not verify swt jar.
+	${RM} ${WRKSRC}/gradle/verification-metadata.xml
+	# build file for NetBSD
+	${CP} ${FILESDIR}/netbsd.gradle ${WRKSRC}/buildSrc
+	# Gstreamer build for NetBSD
+	${CP} -r ${WRKSRC}/modules/javafx.media/src/main/native/jfxmedia/projects/linux \
+		${WRKSRC}/modules/javafx.media/src/main/native/jfxmedia/projects/netbsd
+	${CP} -r ${WRKSRC}/modules/javafx.media/src/main/native/gstreamer/projects/linux \
+		${WRKSRC}/modules/javafx.media/src/main/native/gstreamer/projects/netbsd
+
+pre-configure:
+	${MKDIR} ${WRKDIR}/deps
+	${LN} -sf ${PREFIX}/lib/java/swt.jar \
+	${WRKDIR}/deps/org.eclipse.swt.gtk.netbsd.x86_64_3.105.3.v20170228-0512.jar
+.for d in ${JARS}
+	${LN} -sf ${WRKDIR}/${d} ${WRKDIR}/deps
+.endfor
+
+do-configure:
+	${ECHO} "JFX_DEPS_URL = ${WRKDIR}/deps" >> ${WRKSRC}/gradle.properties
+
+do-build:
+	cd ${WRKSRC} && \
+		${SETENV} ${MAKE_ENV} gradle --no-daemon all \
+			--exclude-task javadoc --warning-mode all --info
+
+INSTALLATION_DIRS+=     openjfx21/lib
+INSTALLATION_DIRS+=     openjfx21/jmods
+
+do-install:
+	${INSTALL_DATA} ${WRKSRC}/build/javafx-exports.zip \
+		${DESTDIR}${PREFIX}/openjfx21
+	${INSTALL_DATA} ${WRKSRC}/build/artifacts/javafx-sdk-21*/lib/* \
+		${DESTDIR}${PREFIX}/openjfx21/lib
+	${INSTALL_DATA} ${WRKSRC}/build/artifacts/javafx-sdk-21*/src.zip \
+		${DESTDIR}${PREFIX}/openjfx21
+	${INSTALL_DATA} ${WRKSRC}/build/artifacts/javafx-jmods-21*/* \
+		${DESTDIR}${PREFIX}/openjfx21/jmods
+
+.include "../../lang/openjdk21/buildlink3.mk"
+.include "../../multimedia/pipewire/buildlink3.mk"
+.include "../../x11/gtk3/buildlink3.mk"
+.include "../../x11/libXtst/buildlink3.mk"
+.include "../../mk/java-vm.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/openjfx21/PLIST b/openjfx21/PLIST
new file mode 100644
index 0000000000..ed4803c0d0
--- /dev/null
+++ b/openjfx21/PLIST
@@ -0,0 +1,27 @@
+@comment $NetBSD$
+openjfx21/javafx-exports.zip
+openjfx21/jmods/javafx.base.jmod
+openjfx21/jmods/javafx.controls.jmod
+openjfx21/jmods/javafx.fxml.jmod
+openjfx21/jmods/javafx.graphics.jmod
+openjfx21/jmods/javafx.media.jmod
+openjfx21/jmods/javafx.swing.jmod
+openjfx21/jmods/javafx.web.jmod
+openjfx21/lib/javafx-swt.jar
+openjfx21/lib/javafx.base.jar
+openjfx21/lib/javafx.controls.jar
+openjfx21/lib/javafx.fxml.jar
+openjfx21/lib/javafx.graphics.jar
+openjfx21/lib/javafx.media.jar
+openjfx21/lib/javafx.properties
+openjfx21/lib/javafx.swing.jar
+openjfx21/lib/javafx.web.jar
+openjfx21/lib/libdecora_sse.so
+openjfx21/lib/libglass.so
+openjfx21/lib/libglassgtk3.so
+openjfx21/lib/libjavafx_font.so
+openjfx21/lib/libjavafx_iio.so
+openjfx21/lib/libprism_common.so
+openjfx21/lib/libprism_es2.so
+openjfx21/lib/libprism_sw.so
+openjfx21/src.zip
diff --git a/openjfx21/distinfo b/openjfx21/distinfo
new file mode 100644
index 0000000000..73b5398671
--- /dev/null
+++ b/openjfx21/distinfo
@@ -0,0 +1,39 @@
+$NetBSD$
+
+BLAKE2s (antlr4-4.7.2-complete.jar) = 1da05850745a85da90415159aae16f357751af3696a39387d6f8053acf1155f3
+SHA512 (antlr4-4.7.2-complete.jar) = e788d28796c8925a158f0a09048590bdcf6730d46dcb8a12b362cbcc80a7ceb76374b2675987c953faecd3cf4a847b1571485a71081a84684170d25d05176a11
+Size (antlr4-4.7.2-complete.jar) = 2079769 bytes
+BLAKE2s (jfx21u-21.0.8+2.tar.gz) = 6fb310cacd29a1430a12064bfd9e56b73fbaae8acfafe7d68a1b565169fce95b
+SHA512 (jfx21u-21.0.8+2.tar.gz) = 187d4408d51acffd7ec0dd53a59e68de159e266bb5553b13ee4d044128f773e98cf35077104f01f30e422dee5f8849a82eca2f0993bfa57747b293cc8fb6bacf
+Size (jfx21u-21.0.8+2.tar.gz) = 65221670 bytes
+BLAKE2s (lucene-core-7.7.3.jar) = 8501f20801667fc14b3b4f72b1f89f07a1ec60cf79a0736a5bb61ad3fd9f87a6
+SHA512 (lucene-core-7.7.3.jar) = 19d5e29d048b6dabd87fba7e5e12fefd443fe1b67ede6644b7c268e290ee8b3c47cb5fe4a90a9e4b140df9325ca6db0c1ee057d5b343f4d3616351d04d6a740a
+Size (lucene-core-7.7.3.jar) = 3089727 bytes
+BLAKE2s (lucene-grouping-7.7.3.jar) = d2627ebbcc40552cb9f79300c97b5d78fe087fd054d26652d9cf3fab08764cd6
+SHA512 (lucene-grouping-7.7.3.jar) = a0974c199bfb699e4e059290ca81cb765d5e093a3083239cb2b8e6668bf06e6a85c61e0ccba607eedab14760eb1a7595779bed24f51659b6d736b5c7cd900a38
+Size (lucene-grouping-7.7.3.jar) = 87265 bytes
+BLAKE2s (lucene-queryparser-7.7.3.jar) = 8ce768c348e42ce7309d6e4d9edd261e7f9160902d5e6a1c45a86a91a10e426c
+SHA512 (lucene-queryparser-7.7.3.jar) = eed3d5c9b83f740e665eb44fe483f76a1f5cf181fa42e65f5106bebd7026d1518d626e146c2c6c4da46c64e080e6b466c0542c1c9f49bbd46c9c6f0d8e193e6f
+Size (lucene-queryparser-7.7.3.jar) = 381935 bytes
+SHA1 (patch-apps_samples_Ensemble8_src_app_java_ensemble_PlatformFeatures.java) = c1409353ef8cd851a6e9a6c6d3484aeed18f8c9e
+SHA1 (patch-build.gradle) = 6a50e781b04a00fde1140ccf5cd4aa631111c42b
+SHA1 (patch-modules_javafx.base_src_main_java_com_sun_javafx_PlatformUtil.java) = c24b952e290711d28e4d87a09c1547c5be93f55b
+SHA1 (patch-modules_javafx.controls_src_main_java_com_sun_javafx_scene_control_behavior_TextInputControlBehavior.java) = 53e97b1ca68f70d878012f8fb2727012034f48d3
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_glass_ui_Platform.java) = 9f0253bb645b3d49047c518da3135977a2a0c854
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_glass_utils_NativeLibLoader.java) = 486225058abc7552807b8d23942550cbcb09b95d
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_LogicalFont.java) = 06a06dce90af4e0b5db186ecb5d7e2971728a687
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_PrismFontFactory.java) = 59efea4859dd8d73096cfa94d7f6ff95102d8582
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_Toolkit.java) = cda8079591dcd79429528e4866b5d92e5640965c
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_GlassSystemMenu.java) = 6fca0b4e5e99cf43d7870249433d0071a4168d3c
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_WindowStage.java) = 3937bc794f13010df045054d76bc2076881b5d0d
+SHA1 (patch-modules_javafx.graphics_src_main_java_com_sun_prism_impl_PrismSettings.java) = 5c48515862b775b3144686c0e1d445c4d56e2b6b
+SHA1 (patch-modules_javafx.graphics_src_main_native-glass_gtk_launcher.c) = b0bf6679145ac8f380cdfd0b16e622768a0130d7
+SHA1 (patch-modules_javafx.graphics_src_main_native-glass_gtk_wrapped.c) = ff0a0e690a5306c0ec717637044e107ca9e02b7f
+SHA1 (patch-modules_javafx.graphics_src_main_native-prism-es2_PrismES2Defs.h) = 6f79e4b7141b5afeb8b4520f47eb7f1d3d7d0ab8
+SHA1 (patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_check-xcfilelists.sh) = 4eb93f7f34719e59f48165cfed6b6c58cfbcb4fb
+SHA1 (patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_generate-unified-sources.sh) = 75a057af3da336142a09e0c48202a91302453146
+SHA1 (patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_check-xcfilelists.sh) = 1fca3db799b8976613de7efad42c97a0f73f80a6
+SHA1 (patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_generate-unified-sources.sh) = 9f855d39eb03cae0d233565a36c10cbf52ac09e2
+SHA1 (patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_check-xcfilelists.sh) = faa04d02bda7d59353f466f7e7ca207f70d09d86
+SHA1 (patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_generate-unified-sources.sh) = 423c18fa816d9eb66ee187c0e3239f3d51d11b9a
+SHA1 (patch-modules_javafx.web_src_main_native_Tools_DumpRenderTree_Scripts_check-xcfilelists.sh) = 1574850c9b2df602786a931928239709f7116343
diff --git a/openjfx21/files/netbsd.gradle b/openjfx21/files/netbsd.gradle
new file mode 100644
index 0000000000..d4b80bf5b2
--- /dev/null
+++ b/openjfx21/files/netbsd.gradle
@@ -0,0 +1,296 @@
+/*
+ * Copyright (c) 2013, 2024, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+ext.NETBSD = [:]
+
+// Declare whether this particular target file applies to the current system
+NETBSD.canBuild = IS_NETBSD;
+if (!NETBSD.canBuild) return;
+
+// All desktop related packages should be built
+NETBSD.compileSwing = true;
+NETBSD.compileSWT = true;
+
+// Libraries end up in the lib/$OS_ARCH directory for Linux
+NETBSD.libDest = "lib"
+
+// Lambda for naming the generated libs
+NETBSD.library = { name -> return (IS_STATIC_BUILD ? "lib${name}.a" : "lib${name}.so") as String }
+
+// A set of common parameters to use for both compiling and linking
+def commonFlags = [
+        "-fno-strict-aliasing", "-fPIC", "-fno-omit-frame-pointer", // optimization flags
+        "-fstack-protector",
+        "-Wextra", "-Wall", "-Wformat-security", "-Wno-unused", "-Wno-parentheses", "-Werror=trampolines"] // warning flags
+
+if (OS_ARCH == "i386") {
+    commonFlags += "-m32"
+}
+
+if (IS_STATIC_BUILD) {
+    commonFlags += "-DSTATIC_BUILD"
+}
+
+// Specify the compilation parameters and link parameters
+def cppFlags = [
+        commonFlags, "-I$JDK_HOME/include", "-I$JDK_HOME/include/netbsd", "-c",
+        "-ffunction-sections", "-fdata-sections",
+        IS_DEBUG_NATIVE ? ["-ggdb", "-DVERBOSE"] : ["-O2", "-DNDEBUG"]].flatten()
+
+def cFlags = [cppFlags, "-Werror=implicit-function-declaration"].flatten()
+
+def ccFlagsGTK3 = cppFlags
+//ccFlags.addAll(["-Wnon-virtual-dtor", "-Woverloaded-virtual", "-std=c++0x"])
+def dynamicLinkFlags = ["-shared", commonFlags,
+                 "-z", "relro",
+                 "-Wl,--gc-sections"].flatten()
+
+def staticLinkFlags = [].flatten()
+
+def linkFlags = IS_STATIC_BUILD ? staticLinkFlags : dynamicLinkFlags;
+
+if (IS_DEBUG_NATIVE) {
+    linkFlags += "-g"
+}
+
+def toolchainDir
+if (hasProperty('toolchainDir')) {
+    toolchainDir = ext.toolchainDir + "/"
+} else {
+    toolchainDir = ""
+}
+
+def gtk3CCFlags = [ "-Wno-deprecated-declarations" ];
+def gtk3LinkFlags = [ ];
+
+setupTools("netbsd_gtk3",
+    { propFile ->
+        ByteArrayOutputStream results2 = new ByteArrayOutputStream();
+        exec {
+            commandLine("${toolchainDir}pkg-config", "--cflags", "gtk+-3.0", "gthread-2.0", "xtst", "gio-unix-2.0")
+            setStandardOutput(results2);
+        }
+        propFile << "cflagsGTK3=" << results2.toString().trim() << "\n";
+
+        ByteArrayOutputStream results4 = new ByteArrayOutputStream();
+        exec {
+            commandLine("${toolchainDir}pkg-config", "--libs", "gtk+-3.0", "gthread-2.0", "xtst", "gio-unix-2.0")
+            setStandardOutput(results4);
+        }
+        propFile << "libsGTK3=" << results4.toString().trim()  << "\n";
+
+    },
+    { properties ->
+        def cflagsGTK3 = properties.getProperty("cflagsGTK3")
+        def libsGTK3 = properties.getProperty("libsGTK3")
+        if (cflagsGTK3 && libsGTK3) {
+            gtk3CCFlags.addAll(cflagsGTK3.split(" "))
+            gtk3LinkFlags.addAll(libsGTK3.split(" "))
+        } else {
+            throw new IllegalStateException("GTK3 development packages not found. If GTK3 packages are installed, please remove the build directory and try again.")
+        }
+    }
+)
+
+def pangoCCFlags = ["-D_ENABLE_PANGO"];
+def pangoLinkFlags = [];
+setupTools("netbsd_pango_tools",
+    { propFile ->
+        ByteArrayOutputStream results = new ByteArrayOutputStream();
+        exec {
+            commandLine "${toolchainDir}pkg-config", "--cflags", "pangoft2"
+            standardOutput = results
+        }
+        propFile << "cflags=" << results.toString().trim() << "\n";
+
+        results = new ByteArrayOutputStream();
+        exec {
+            commandLine "${toolchainDir}pkg-config", "--libs", "pangoft2"
+            standardOutput = results
+        }
+        propFile << "libs=" << results.toString().trim();
+    },
+    { properties ->
+        def cflags = properties.getProperty("cflags")
+        def libs = properties.getProperty("libs")
+        if (cflags && libs) {
+            pangoCCFlags.addAll(cflags.split(" "))
+            pangoLinkFlags.addAll(libs.split(" "))
+        } else {
+            throw new IllegalStateException("Linux pango packages not found.\nIf pango packages are installed, please remove the build directory and try again.")
+        }
+    }
+)
+
+def freetypeCCFlags = [ext.IS_COMPILE_PANGO ? "-D_ENABLE_PANGO" :
+                       ext.IS_COMPILE_HARFBUZZ ? "-D_ENABLE_HARFBUZZ" : ""]
+def freetypeLinkFlags = []
+setupTools("netbsd_freetype_tools",
+    { propFile ->
+        ByteArrayOutputStream results = new ByteArrayOutputStream();
+        exec {
+            commandLine "${toolchainDir}pkg-config", "--cflags", "freetype2"
+            standardOutput = results
+        }
+        propFile << "cflags=" << results.toString().trim() << "\n";
+
+        results = new ByteArrayOutputStream();
+        exec {
+            commandLine "${toolchainDir}pkg-config", "--libs", "freetype2"
+            standardOutput = results
+        }
+        propFile << "libs=" << results.toString().trim();
+    },
+    { properties ->
+        def cflags = properties.getProperty("cflags")
+        def libs = properties.getProperty("libs")
+        if (cflags && libs) {
+            freetypeCCFlags.addAll(cflags.split(" "))
+            if (!IS_STATIC_BUILD) {
+                freetypeLinkFlags.addAll(libs.split(" "))
+            }
+        } else {
+            throw new IllegalStateException("Linux freetype packages not found.\nIf freetype packages are installed, please remove the build directory and try again.")
+        }
+    }
+)
+
+def compiler = IS_COMPILE_PARFAIT ? "parfait-gcc" : "${toolchainDir}gcc";
+def linker = IS_STATIC_BUILD ? "ar" : IS_COMPILE_PARFAIT ? "parfait-g++" : "${toolchainDir}g++";
+
+// Strip native .so shared libraries as a postprocess step when copying them
+NETBSD.strip = "${toolchainDir}strip"
+NETBSD.stripArgs = [ "-x" ]
+
+NETBSD.glass = [:]
+// glassgtk3 support is practically essential for NetBSD.
+NETBSD.glass.variants = ["glass", "glassgtk3"]
+
+FileTree ft_gtk_launcher = fileTree("${project(":graphics").projectDir}/src/main/native-glass/gtk/") {
+    include("**/launcher.c")
+}
+
+FileTree ft_gtk = fileTree("${project(":graphics").projectDir}/src/main/native-glass/gtk/") {
+    exclude("**/launcher.c")
+}
+
+NETBSD.glass.glass = [:]
+NETBSD.glass.glass.nativeSource = ft_gtk_launcher.getFiles()
+NETBSD.glass.glass.compiler = compiler
+NETBSD.glass.glass.ccFlags = [cppFlags, "-Werror"].flatten()
+NETBSD.glass.glass.linker = linker
+NETBSD.glass.glass.linkFlags = IS_STATIC_BUILD? linkFlags : [linkFlags, "-lX11"].flatten()
+NETBSD.glass.glass.lib = "glass"
+
+NETBSD.glass.glassgtk3 = [:]
+NETBSD.glass.glassgtk3.nativeSource =  ft_gtk.getFiles()
+NETBSD.glass.glassgtk3.compiler = compiler
+NETBSD.glass.glassgtk3.ccFlags = IS_STATIC_BUILD ?
+        ["-fno-threadsafe-statics", cppFlags, gtk3CCFlags].flatten() :
+        [cppFlags, gtk3CCFlags, "-Werror"].flatten()
+NETBSD.glass.glassgtk3.linker = linker
+NETBSD.glass.glassgtk3.linkFlags = IS_STATIC_BUILD ? linkFlags : [linkFlags, gtk3LinkFlags].flatten()
+NETBSD.glass.glassgtk3.lib = "glassgtk3"
+
+NETBSD.decora = [:]
+NETBSD.decora.compiler = compiler
+NETBSD.decora.ccFlags = [cppFlags, "-ffast-math"].flatten()
+NETBSD.decora.linker = linker
+NETBSD.decora.linkFlags = [linkFlags].flatten()
+NETBSD.decora.lib = "decora_sse"
+
+NETBSD.prism = [:]
+NETBSD.prism.nativeSource = file("${project(":graphics").projectDir}/src/main/native-prism")
+NETBSD.prism.compiler = compiler
+NETBSD.prism.ccFlags = [cFlags, "-DINLINE=inline"].flatten()
+NETBSD.prism.linker = linker
+NETBSD.prism.linkFlags = [linkFlags].flatten()
+NETBSD.prism.lib = "prism_common"
+
+NETBSD.prismSW = [:]
+NETBSD.prismSW.nativeSource = file("${project(":graphics").projectDir}/src/main/native-prism-sw")
+NETBSD.prismSW.compiler = compiler
+NETBSD.prismSW.ccFlags = [cFlags, "-DINLINE=inline"].flatten()
+NETBSD.prismSW.linker = linker
+NETBSD.prismSW.linkFlags = [linkFlags].flatten()
+NETBSD.prismSW.lib = "prism_sw"
+
+NETBSD.iio = [:]
+NETBSD.iio.nativeSource = [
+    file("${project("graphics").projectDir}/src/main/native-iio"),
+    file("${project("graphics").projectDir}/src/main/native-iio/libjpeg")]
+NETBSD.iio.compiler = compiler
+NETBSD.iio.ccFlags = [cFlags, "-fvisibility=hidden"].flatten()
+NETBSD.iio.linker = IS_STATIC_BUILD ? "ld" : linker
+NETBSD.iio.linkFlags = [linkFlags].flatten()
+NETBSD.iio.lib = "javafx_iio"
+
+NETBSD.prismES2 = [:]
+NETBSD.prismES2.nativeSource = [
+    file("${project("graphics").projectDir}/src/main/native-prism-es2"),
+    file("${project("graphics").projectDir}/src/main/native-prism-es2/GL"),
+    file("${project("graphics").projectDir}/src/main/native-prism-es2/x11")
+]
+NETBSD.prismES2.compiler = compiler
+NETBSD.prismES2.ccFlags = ["-DLINUX", cFlags].flatten()
+NETBSD.prismES2.linker = linker
+NETBSD.prismES2.linkFlags =IS_STATIC_BUILD ? linkFlags : [linkFlags, "-lX11", "-lXxf86vm", "-lGL"].flatten()
+NETBSD.prismES2.lib = "prism_es2"
+
+def closedDir = file("$projectDir/../rt-closed")
+NETBSD.font = [:]
+NETBSD.font.compiler = compiler
+NETBSD.font.nativeSource = [file("${project("graphics").projectDir}/src/main/native-font")]
+NETBSD.font.ccFlags = ["-DJFXFONT_PLUS", cppFlags].flatten()
+NETBSD.font.linker = linker
+NETBSD.font.linkFlags = [linkFlags].flatten()
+NETBSD.font.lib = "javafx_font"
+
+NETBSD.fontFreetype = [:]
+NETBSD.fontFreetype.nativeSource = ["src/main/native-font/freetype.c"]
+NETBSD.fontFreetype.compiler = compiler
+NETBSD.fontFreetype.ccFlags = ["-DJFXFONT_PLUS", cFlags, freetypeCCFlags].flatten()
+NETBSD.fontFreetype.linker = linker
+NETBSD.fontFreetype.linkFlags = IS_STATIC_BUILD ? linkFlags : [linkFlags, freetypeLinkFlags].flatten()
+NETBSD.fontFreetype.lib = "javafx_font_freetype"
+
+NETBSD.fontPango = [:]
+NETBSD.fontPango.nativeSource = ["src/main/native-font/pango.c"]
+NETBSD.fontPango.compiler = compiler
+NETBSD.fontPango.ccFlags = ["-DJFXFONT_PLUS", cFlags, pangoCCFlags].flatten()
+NETBSD.fontPango.linker = linker
+NETBSD.fontPango.linkFlags =IS_STATIC_BUILD ? linkFlags : [linkFlags, pangoLinkFlags].flatten()
+NETBSD.fontPango.lib = "javafx_font_pango"
+
+NETBSD.media = [:]
+NETBSD.media.compiler = compiler
+NETBSD.media.linker = linker
+NETBSD.media.ar = "${toolchainDir}ar"
+
+NETBSD.webkit = [:]
+NETBSD.webkit.compiler = compiler
+NETBSD.webkit.linker = linker
+NETBSD.webkit.ccFlags = commonFlags.flatten()
+NETBSD.webkit.linkFlags = linkFlags.flatten()
diff --git a/openjfx21/patches/patch-apps_samples_Ensemble8_src_app_java_ensemble_PlatformFeatures.java b/openjfx21/patches/patch-apps_samples_Ensemble8_src_app_java_ensemble_PlatformFeatures.java
new file mode 100644
index 0000000000..ab9655b6b7
--- /dev/null
+++ b/openjfx21/patches/patch-apps_samples_Ensemble8_src_app_java_ensemble_PlatformFeatures.java
@@ -0,0 +1,12 @@
+$NetBSD$
+
+--- apps/samples/Ensemble8/src/app/java/ensemble/PlatformFeatures.java.orig	2024-08-20 17:07:03.000000000 +0000
++++ apps/samples/Ensemble8/src/app/java/ensemble/PlatformFeatures.java
+@@ -43,6 +43,7 @@ public class PlatformFeatures {
+     private static final boolean WINDOWS = os.startsWith("Windows");
+     private static final boolean MAC = os.startsWith("Mac");
+     private static final boolean LINUX = os.startsWith("Linux");
++    private static final boolean NETBSD = os.startsWith("NetBSD");
+     private static final boolean ANDROID = "android".equals(System.getProperty("javafx.platform")) || "Dalvik".equals(System.getProperty("java.vm.name"));
+     private static final boolean IOS = os.startsWith("iOS");
+     private static final boolean EMBEDDED = "arm".equals(arch) && !IOS && !ANDROID;
diff --git a/openjfx21/patches/patch-build.gradle b/openjfx21/patches/patch-build.gradle
new file mode 100644
index 0000000000..5e951c8322
--- /dev/null
+++ b/openjfx21/patches/patch-build.gradle
@@ -0,0 +1,83 @@
+$NetBSD$
+
+--- build.gradle.orig	2025-06-17 08:39:24.000000000 +0000
++++ build.gradle
+@@ -359,6 +359,7 @@ ext.IS_RISCV64 = OS_ARCH.toLowerCase().c
+ ext.IS_MAC = OS_NAME.contains("mac") || OS_NAME.contains("darwin")
+ ext.IS_WINDOWS = OS_NAME.contains("windows")
+ ext.IS_LINUX = OS_NAME.contains("linux")
++ext.IS_NETBSD = OS_NAME.contains("netbsd")
+ 
+ ext.MAVEN_GROUP_ID = "org.openjfx"
+ 
+@@ -366,12 +367,12 @@ ext.MAVEN_GROUP_ID = "org.openjfx"
+ // at present building on PI is not supported, but we would only need to make
+ // some changes on assumptions on what should be built (like SWT / Swing) and
+ // such and we could probably make it work.
+-if (!IS_MAC && !IS_WINDOWS && !IS_LINUX) fail("Unsupported build OS ${OS_NAME}")
++if (!IS_MAC && !IS_WINDOWS && !IS_LINUX && !IS_NETBSD) fail("Unsupported build OS ${OS_NAME}")
+ if (IS_WINDOWS && OS_ARCH != "x86" && OS_ARCH != "amd64") {
+     fail("Unknown and unsupported build architecture: $OS_ARCH")
+ } else if (IS_MAC && OS_ARCH != "x86_64" && OS_ARCH != "aarch64") {
+     fail("Unknown and unsupported build architecture: $OS_ARCH")
+-} else if (IS_LINUX && OS_ARCH != "i386" && OS_ARCH != "amd64" && !IS_AARCH64 && !IS_LOONGARCH64 && !IS_RISCV64) {
++} else if ((IS_LINUX || IS_NETBSD) && OS_ARCH != "i386" && OS_ARCH != "amd64" && !IS_AARCH64 && !IS_LOONGARCH64 && !IS_RISCV64) {
+     fail("Unknown and unsupported build architecture: $OS_ARCH")
+ }
+ 
+@@ -501,7 +502,9 @@ ext.SWT_FILE_NAME = IS_MAC ? "org.eclips
+     IS_WINDOWS && IS_64 ? "org.eclipse.swt.win32.win32.x86_64_3.105.3.v20170228-0512" :
+     IS_WINDOWS && !IS_64 ? "org.eclipse.swt.win32.win32.x86_3.105.3.v20170228-0512" :
+     IS_LINUX && IS_64 ? "org.eclipse.swt.gtk.linux.x86_64_3.105.3.v20170228-0512" :
+-    IS_LINUX && !IS_64 ? "org.eclipse.swt.gtk.linux.x86_3.105.3.v20170228-0512" : ""
++    IS_LINUX && !IS_64 ? "org.eclipse.swt.gtk.linux.x86_3.105.3.v20170228-0512" :
++    IS_NETBSD && IS_64 ? "org.eclipse.swt.gtk.netbsd.x86_64_3.105.3.v20170228-0512" :
++    IS_NETBSD && !IS_64 ? "org.eclipse.swt.gtk.netbsd.x86_3.105.3.v20170228-0512" : ""
+ 
+ // Specifies whether to run full tests (true) or smoke tests (false)
+ defineProperty("FULL_TEST", "false")
+@@ -666,7 +669,7 @@ defineProperty("MAVEN_VERSION", IS_MAVEN
+ // Check whether the COMPILE_TARGETS property has been specified (if so, it was done by
+ // the user and not by this script). If it has not been defined then default
+ // to building the normal desktop build for this machine
+-project.ext.set("defaultHostTarget", IS_MAC ? "mac" : IS_WINDOWS ? "win" : IS_LINUX ? "linux" : "");
++project.ext.set("defaultHostTarget", IS_MAC ? "mac" : IS_WINDOWS ? "win" : IS_LINUX ? "linux" : IS_NETBSD ? "netbsd" : "");
+ defineProperty("COMPILE_TARGETS", "$defaultHostTarget")
+ 
+ // Flag indicating whether to import cross compile tools
+@@ -820,7 +823,7 @@ void fetchExternalTools(String configNam
+                 def File pkgdir = file("$destdir/$basename")
+ 
+                 if (pkgname.endsWith(".tgz") || pkgname.endsWith("tar.gz")) {
+-                    if (IS_LINUX || IS_MAC) {
++                    if (IS_LINUX || IS_MAC || IS_NETBSD) {
+                         // use native tar to support symlinks
+                         pkgdir.mkdirs()
+                         exec {
+@@ -1308,7 +1311,7 @@ compileTargets { t ->
+     if (!targetProperties.containsKey('includeMonocle')) targetProperties.includeMonocle = false
+     if (!targetProperties.containsKey('includeEGL')) targetProperties.includeEGL = false
+ 
+-    if (!targetProperties.containsKey('includeGTK')) targetProperties.includeGTK = IS_LINUX
++    if (!targetProperties.containsKey('includeGTK')) targetProperties.includeGTK = IS_LINUX || IS_NETBSD
+ 
+     if (!targetProperties.containsKey('modLibDest')) targetProperties.modLibDest = targetProperties.libDest
+ 
+@@ -1440,7 +1443,7 @@ logger.quiet("minimum jdk version: ${jfx
+ logger.quiet("minimum jdk build number: ${jfxBuildJdkBuildnumMin}")
+ logger.quiet("Java target version: ${JAVA_TARGET_VERSION}")
+ 
+-if (IS_LINUX) {
++if (IS_LINUX || IS_NETBSD) {
+     logger.quiet("GCC version: ${jfxBuildLinuxGccVersion}")
+ } else if (IS_WINDOWS) {
+     logger.quiet("MSVC version: ${jfxBuildWindowsMsvcVersion}")
+@@ -4657,7 +4660,7 @@ configurations {
+ }
+ 
+ if (IS_STUB_RUNTIME_OPENJFX) {
+-    def String platform = IS_MAC ? "mac" : IS_WINDOWS ? "win" : IS_LINUX ? "linux" : ""
++    def String platform = IS_MAC ? "mac" : IS_WINDOWS ? "win" : IS_LINUX ? "linux" : IS_NETBSD ? "netbsd" : ""
+     dependencies {
+         openjfxStubs "org.openjfx:javafx-media:$STUB_RUNTIME_OPENJFX:$platform@jar"
+         openjfxStubs "org.openjfx:javafx-web:$STUB_RUNTIME_OPENJFX:$platform@jar"
diff --git a/openjfx21/patches/patch-modules_javafx.base_src_main_java_com_sun_javafx_PlatformUtil.java b/openjfx21/patches/patch-modules_javafx.base_src_main_java_com_sun_javafx_PlatformUtil.java
new file mode 100644
index 0000000000..781ceaf389
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.base_src_main_java_com_sun_javafx_PlatformUtil.java
@@ -0,0 +1,32 @@
+$NetBSD$
+
+--- modules/javafx.base/src/main/java/com/sun/javafx/PlatformUtil.java.orig	2024-10-21 13:17:03.235566355 +0000
++++ modules/javafx.base/src/main/java/com/sun/javafx/PlatformUtil.java
+@@ -85,6 +85,7 @@ public class PlatformUtil {
+     private static final boolean WINDOWS_7_OR_LATER = WINDOWS && versionNumberGreaterThanOrEqualTo(6.1f);
+     private static final boolean MAC = os.startsWith("Mac");
+     private static final boolean LINUX = os.startsWith("Linux") && !ANDROID;
++    private static final boolean NETBSD = os.startsWith("NetBSD");
+     private static final boolean SOLARIS = os.startsWith("SunOS");
+     private static final boolean IOS = os.startsWith("iOS");
+     private static final boolean STATIC_BUILD = "Substrate VM".equals(System.getProperty("java.vm.name"));
+@@ -141,6 +142,10 @@ public class PlatformUtil {
+         return LINUX;
+     }
+ 
++    public static boolean isNetBSD(){
++        return NETBSD;
++    }
++
+     public static boolean useEGL() {
+         return useEGL;
+     }
+@@ -170,7 +175,7 @@ public class PlatformUtil {
+      * Returns true if the operating system is a form of Linux or Solaris
+      */
+     public static boolean isUnix(){
+-        return LINUX || SOLARIS;
++        return LINUX || SOLARIS || NETBSD;
+     }
+ 
+     /**
diff --git a/openjfx21/patches/patch-modules_javafx.controls_src_main_java_com_sun_javafx_scene_control_behavior_TextInputControlBehavior.java b/openjfx21/patches/patch-modules_javafx.controls_src_main_java_com_sun_javafx_scene_control_behavior_TextInputControlBehavior.java
new file mode 100644
index 0000000000..f6dccefd23
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.controls_src_main_java_com_sun_javafx_scene_control_behavior_TextInputControlBehavior.java
@@ -0,0 +1,30 @@
+$NetBSD$
+
+--- modules/javafx.controls/src/main/java/com/sun/javafx/scene/control/behavior/TextInputControlBehavior.java.orig	2024-10-21 13:19:58.353820234 +0000
++++ modules/javafx.controls/src/main/java/com/sun/javafx/scene/control/behavior/TextInputControlBehavior.java
+@@ -56,6 +56,7 @@ import java.text.Bidi;
+ import java.util.function.Predicate;
+ 
+ import static com.sun.javafx.PlatformUtil.isLinux;
++import static com.sun.javafx.PlatformUtil.isNetBSD;
+ import static com.sun.javafx.PlatformUtil.isMac;
+ import static com.sun.javafx.PlatformUtil.isWindows;
+ import static com.sun.javafx.scene.control.inputmap.KeyBinding.OptionalBoolean;
+@@ -552,7 +553,7 @@ public abstract class TextInputControlBe
+ 
+     public void selectNextWord() {
+         TextInputControl textInputControl = getNode();
+-        if (isMac() || isLinux()) {
++        if (isMac() || isLinux() || isNetBSD()) {
+             textInputControl.selectEndOfNextWord();
+         } else {
+             textInputControl.selectNextWord();
+@@ -601,7 +602,7 @@ public abstract class TextInputControlBe
+ 
+     protected void nextWord() {
+         TextInputControl textInputControl = getNode();
+-        if (isMac() || isLinux()) {
++        if (isMac() || isLinux() || isNetBSD()) {
+             textInputControl.endOfNextWord();
+         } else {
+             textInputControl.nextWord();
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_ui_Platform.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_ui_Platform.java
new file mode 100644
index 0000000000..2d6ed7388a
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_ui_Platform.java
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/glass/ui/Platform.java.orig	2024-10-21 13:22:39.527745356 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/glass/ui/Platform.java
+@@ -68,6 +68,8 @@ final class Platform {
+                 type = WINDOWS;
+             } else if (PlatformUtil.isLinux()) {
+                 type = GTK;
++            } else if (PlatformUtil.isNetBSD()) {
++                type = GTK;
+             } else if (PlatformUtil.isIOS()) {
+                 type = IOS;
+             }
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_utils_NativeLibLoader.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_utils_NativeLibLoader.java
new file mode 100644
index 0000000000..fbb17025bf
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_glass_utils_NativeLibLoader.java
@@ -0,0 +1,32 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/glass/utils/NativeLibLoader.java.orig	2024-08-20 17:07:03.000000000 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/glass/utils/NativeLibLoader.java
+@@ -363,6 +363,8 @@ public class NativeLibLoader {
+             relativeDir = "lib";
+         } else if (PlatformUtil.isLinux()) {
+             relativeDir = "lib";
++        } else if (PlatformUtil.isNetBSD()) {
++            relativeDir = "lib";
+         }
+ 
+         // Location of native libraries relative to java.home
+@@ -383,6 +385,8 @@ public class NativeLibLoader {
+             relativeDir = ".";
+         } else if (PlatformUtil.isLinux()) {
+             relativeDir = ".";
++        } else if (PlatformUtil.isNetBSD()) {
++            relativeDir = ".";
+         }
+ 
+         // Location of native libraries relative to jar file
+@@ -421,6 +425,9 @@ public class NativeLibLoader {
+                 } else if (PlatformUtil.isLinux()) {
+                     libPrefix = "lib";
+                     libSuffix = ".so";
++                } else if (PlatformUtil.isNetBSD()) {
++                    libPrefix = "lib";
++                    libSuffix = ".so";
+                 }
+             }
+ 
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_LogicalFont.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_LogicalFont.java
new file mode 100644
index 0000000000..64f280badb
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_LogicalFont.java
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/javafx/font/LogicalFont.java.orig	2024-10-21 13:21:27.486740460 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/javafx/font/LogicalFont.java
+@@ -171,7 +171,7 @@ public class LogicalFont implements Comp
+             styleName = STYLE_BOLD_ITALIC;
+         }
+         fullName = familyName + " " + styleName;
+-        if (PrismFontFactory.isLinux) {
++        if (PrismFontFactory.isLinux || PrismFontFactory.isNetBSD) {
+             FontConfigManager.FcCompFont fcCompFont =
+                 FontConfigManager.getFontConfigFont(family, bold, italic);
+             physicalFullName = fcCompFont.firstFont.fullName;
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_PrismFontFactory.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_PrismFontFactory.java
new file mode 100644
index 0000000000..2dd8370e21
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_font_PrismFontFactory.java
@@ -0,0 +1,47 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/javafx/font/PrismFontFactory.java.orig	2024-10-21 13:24:59.712095825 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/javafx/font/PrismFontFactory.java
+@@ -51,6 +51,7 @@ public abstract class PrismFontFactory i
+     public static final boolean debugFonts;
+     public static final boolean isWindows;
+     public static final boolean isLinux;
++    public static final boolean isNetBSD;
+     public static final boolean isMacOSX;
+     public static final boolean isIOS;
+     public static final boolean isAndroid;
+@@ -86,6 +87,7 @@ public abstract class PrismFontFactory i
+         isWindows = PlatformUtil.isWindows();
+         isMacOSX  = PlatformUtil.isMac();
+         isLinux   = PlatformUtil.isLinux();
++        isNetBSD  = PlatformUtil.isNetBSD();
+         isIOS     = PlatformUtil.isIOS();
+         isAndroid = PlatformUtil.isAndroid();
+         isEmbedded = PlatformUtil.isEmbedded();
+@@ -164,7 +166,7 @@ public abstract class PrismFontFactory i
+     private static String getNativeFactoryName() {
+         if (isWindows) return DW_FACTORY;
+         if (isMacOSX || isIOS) return CT_FACTORY;
+-        if (isLinux || isAndroid) return FT_FACTORY;
++        if (isLinux || isAndroid || isNetBSD) return FT_FACTORY;
+         return null;
+     }
+ 
+@@ -884,7 +886,7 @@ public abstract class PrismFontFactory i
+                         break;
+                     }
+                 }
+-                if (fontResource == null && isLinux) {
++                if (fontResource == null && (isLinux || isNetBSD)) {
+                     String path = FontConfigManager.getDefaultFontPath();
+                     if (path != null) {
+                         fontResource = createFontResource(jreDefaultFontLC,
+@@ -1724,7 +1726,7 @@ public abstract class PrismFontFactory i
+                                 fontToFamilyNameMap,
+                                 familyToFontListMap);
+                 }
+-            } else if (isLinux) {
++            } else if (isLinux || isNetBSD) {
+                 FontConfigManager.populateMaps(tmpFontToFileMap,
+                                                fontToFamilyNameMap,
+                                                familyToFontListMap,
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_Toolkit.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_Toolkit.java
new file mode 100644
index 0000000000..95093f4215
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_Toolkit.java
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/javafx/tk/Toolkit.java.orig	2024-10-21 13:16:03.339570009 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/javafx/tk/Toolkit.java
+@@ -186,6 +186,8 @@ public abstract class Toolkit {
+             return DEFAULT_TOOLKIT;
+         } else if (PlatformUtil.isLinux()) {
+             return DEFAULT_TOOLKIT;
++        } else if (PlatformUtil.isNetBSD()) {
++            return DEFAULT_TOOLKIT;
+         } else if (PlatformUtil.isIOS()) {
+             return DEFAULT_TOOLKIT;
+         } else if (PlatformUtil.isAndroid()) {
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_GlassSystemMenu.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_GlassSystemMenu.java
new file mode 100644
index 0000000000..a6d19b4229
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_GlassSystemMenu.java
@@ -0,0 +1,37 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/javafx/tk/quantum/GlassSystemMenu.java.orig	2024-10-21 13:26:25.192842112 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/javafx/tk/quantum/GlassSystemMenu.java
+@@ -316,13 +316,13 @@ class GlassSystemMenu implements TKSyste
+         } else if (accelerator instanceof KeyCodeCombination) {
+             KeyCodeCombination kcc  = (KeyCodeCombination)accelerator;
+             KeyCode            code = kcc.getCode();
+-            assert PlatformUtil.isMac() || PlatformUtil.isLinux();
++            assert PlatformUtil.isMac() || PlatformUtil.isLinux() || PlatformUtil.isNetBSD();
+             int modifier = glassModifiers(kcc);
+             if (PlatformUtil.isMac()) {
+                 int finalCode = code.isLetterKey() ? code.getChar().toUpperCase().charAt(0)
+                         : code.getCode();
+                 glassSubMenuItem.setShortcut(finalCode, modifier);
+-            } else if (PlatformUtil.isLinux()) {
++            } else if (PlatformUtil.isLinux() || PlatformUtil.isNetBSD()) {
+                 String lower = code.getChar().toLowerCase();
+                 if ((modifier & KeyEvent.MODIFIER_CONTROL) != 0) {
+                     glassSubMenuItem.setShortcut(lower.charAt(0), modifier);
+@@ -351,14 +351,14 @@ class GlassSystemMenu implements TKSyste
+             ret += KeyEvent.MODIFIER_ALT;
+         }
+         if (kcc.getShortcut() == KeyCombination.ModifierValue.DOWN) {
+-            if (PlatformUtil.isLinux()) {
++            if (PlatformUtil.isLinux() || PlatformUtil.isNetBSD()) {
+                 ret += KeyEvent.MODIFIER_CONTROL;
+             } else if (PlatformUtil.isMac()) {
+                 ret += KeyEvent.MODIFIER_COMMAND;
+             }
+         }
+         if (kcc.getMeta() == KeyCombination.ModifierValue.DOWN) {
+-            if (PlatformUtil.isLinux()) {
++            if (PlatformUtil.isLinux() || PlatformUtil.isNetBSD()) {
+                 ret += KeyEvent.MODIFIER_WINDOWS;   // RT-19326 - Linux shortcut support
+             } else if (PlatformUtil.isMac()) {
+                 ret += KeyEvent.MODIFIER_COMMAND;
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_WindowStage.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_WindowStage.java
new file mode 100644
index 0000000000..d91fedec5b
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_javafx_tk_quantum_WindowStage.java
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/javafx/tk/quantum/WindowStage.java.orig	2024-10-21 13:27:30.874992552 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/javafx/tk/quantum/WindowStage.java
+@@ -440,7 +440,7 @@ public class WindowStage extends GlassSt
+         } else if (PlatformUtil.isWindows()) { //Windows Sized Icons
+             SMALL_ICON_HEIGHT = 32;
+             SMALL_ICON_WIDTH = 32;
+-        } else if (PlatformUtil.isLinux()) { //Linux icons
++        } else if (PlatformUtil.isLinux() || PlatformUtil.isNetBSD()) { //Linux icons
+             SMALL_ICON_HEIGHT = 128;
+             SMALL_ICON_WIDTH = 128;
+         }
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_prism_impl_PrismSettings.java b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_prism_impl_PrismSettings.java
new file mode 100644
index 0000000000..4a38515512
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_java_com_sun_prism_impl_PrismSettings.java
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/java/com/sun/prism/impl/PrismSettings.java.orig	2024-10-21 13:23:22.340848969 +0000
++++ modules/javafx.graphics/src/main/java/com/sun/prism/impl/PrismSettings.java
+@@ -217,6 +217,8 @@ public final class PrismSettings {
+                     tryOrderArr = new String[] { "es2" };
+             } else if (PlatformUtil.isLinux()) {
+                 tryOrderArr = new String[] { "es2", "sw" };
++            } else if (PlatformUtil.isNetBSD()) {
++                tryOrderArr = new String[] { "es2", "sw" };
+             } else {
+                 tryOrderArr = new String[] { "sw" };
+             }
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_launcher.c b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_launcher.c
new file mode 100644
index 0000000000..2fa2633afb
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_launcher.c
@@ -0,0 +1,14 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/native-glass/gtk/launcher.c.orig	2024-10-21 10:13:04.269805887 +0000
++++ modules/javafx.graphics/src/main/native-glass/gtk/launcher.c
+@@ -25,7 +25,9 @@
+ 
+ #include <stdio.h>
+ #include <stdlib.h>
++#if defined(__linux__)
+ #include <linux/fb.h>
++#endif
+ #include <fcntl.h>
+ #ifndef __USE_GNU       // required for dladdr() & Dl_info
+ #define __USE_GNU
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_wrapped.c b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_wrapped.c
new file mode 100644
index 0000000000..9822446b96
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-glass_gtk_wrapped.c
@@ -0,0 +1,14 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/native-glass/gtk/wrapped.c.orig	2024-10-21 10:32:44.512852512 +0000
++++ modules/javafx.graphics/src/main/native-glass/gtk/wrapped.c
+@@ -24,7 +24,9 @@
+  */
+ 
+ #include <stdio.h>
++#if defined(__linux__)
+ #include <linux/fb.h>
++#endif
+ #include <fcntl.h>
+ #ifndef __USE_GNU       // required for dladdr() & Dl_info
+ #define __USE_GNU
diff --git a/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-prism-es2_PrismES2Defs.h b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-prism-es2_PrismES2Defs.h
new file mode 100644
index 0000000000..cfd3515d7b
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.graphics_src_main_native-prism-es2_PrismES2Defs.h
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.graphics/src/main/native-prism-es2/PrismES2Defs.h.orig	2024-08-20 17:07:03.000000000 +0000
++++ modules/javafx.graphics/src/main/native-prism-es2/PrismES2Defs.h
+@@ -26,7 +26,7 @@
+ #ifndef _Prism_es2_defs_h_
+ #define _Prism_es2_defs_h_
+ 
+-#if defined(SOLARIS) || defined(LINUX) || defined(ANDROID_NDK) /* SOLARIS || LINUX */
++#if defined(SOLARIS) || defined(LINUX) || defined(ANDROID_NDK) || defined(NETBSD) /* SOLARIS || LINUX */
+ #define GLX_GLEXT_PROTOTYPES
+ #define GLX_GLXEXT_PROTOTYPES
+ #define UNIX
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_check-xcfilelists.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_check-xcfilelists.sh
new file mode 100644
index 0000000000..6db8e255e3
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_check-xcfilelists.sh
@@ -0,0 +1,16 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/JavaScriptCore/Scripts/check-xcfilelists.sh.orig	2025-08-10 14:14:01.044225649 +0000
++++ modules/javafx.web/src/main/native/Source/JavaScriptCore/Scripts/check-xcfilelists.sh
+@@ -1,8 +1,8 @@
+ #!/bin/sh
+ 
+-[ "${WK_DISABLE_CHECK_XCFILELISTS}" == "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
+-[ "${DEPLOYMENT_LOCATION}" == "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
+-[ "${USE_INTERNAL_SDK}" == "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
++[ "${WK_DISABLE_CHECK_XCFILELISTS}" = "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
++[ "${DEPLOYMENT_LOCATION}" = "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
++[ "${USE_INTERNAL_SDK}" = "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
+ 
+ SCRIPT="${BUILD_SCRIPTS_DIR}/generate-xcfilelists"
+ [ -f "${SCRIPT}" ] || SCRIPT="${PROJECT_DIR}/../../../${WK_ADDITIONAL_SCRIPTS_DIR}/generate-xcfilelists"
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_generate-unified-sources.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_generate-unified-sources.sh
new file mode 100644
index 0000000000..3c25db013b
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_JavaScriptCore_Scripts_generate-unified-sources.sh
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/JavaScriptCore/Scripts/generate-unified-sources.sh.orig	2025-08-10 14:17:57.204286150 +0000
++++ modules/javafx.web/src/main/native/Source/JavaScriptCore/Scripts/generate-unified-sources.sh
+@@ -7,7 +7,7 @@ ARGS=("$@")
+ cd $SRCROOT
+ 
+ if [ -z "${BUILD_SCRIPTS_DIR}" ]; then
+-    if [ "${DEPLOYMENT_LOCATION}" == "YES" ]; then
++    if [ "${DEPLOYMENT_LOCATION}" = "YES" ]; then
+         BUILD_SCRIPTS_DIR="${SDKROOT}${WK_ALTERNATE_WEBKIT_SDK_PATH}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
+     else
+         BUILD_SCRIPTS_DIR="${BUILT_PRODUCTS_DIR}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_check-xcfilelists.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_check-xcfilelists.sh
new file mode 100644
index 0000000000..6153f1f713
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_check-xcfilelists.sh
@@ -0,0 +1,16 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/WebCore/Scripts/check-xcfilelists.sh.orig	2025-08-10 14:18:56.469313448 +0000
++++ modules/javafx.web/src/main/native/Source/WebCore/Scripts/check-xcfilelists.sh
+@@ -1,8 +1,8 @@
+ #!/bin/sh
+ 
+-[ "${WK_DISABLE_CHECK_XCFILELISTS}" == "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
+-[ "${DEPLOYMENT_LOCATION}" == "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
+-[ "${USE_INTERNAL_SDK}" == "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
++[ "${WK_DISABLE_CHECK_XCFILELISTS}" = "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
++[ "${DEPLOYMENT_LOCATION}" = "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
++[ "${USE_INTERNAL_SDK}" = "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
+ 
+ SCRIPT="${BUILD_SCRIPTS_DIR}/generate-xcfilelists"
+ [ -f "${SCRIPT}" ] || SCRIPT="${PROJECT_DIR}/../../../${WK_ADDITIONAL_SCRIPTS_DIR}/generate-xcfilelists"
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_generate-unified-sources.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_generate-unified-sources.sh
new file mode 100644
index 0000000000..ac469a342f
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebCore_Scripts_generate-unified-sources.sh
@@ -0,0 +1,22 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/WebCore/Scripts/generate-unified-sources.sh.orig	2025-08-10 14:18:25.170536421 +0000
++++ modules/javafx.web/src/main/native/Source/WebCore/Scripts/generate-unified-sources.sh
+@@ -7,7 +7,7 @@ ARGS=("$@")
+ cd $SRCROOT
+ 
+ if [ -z "${BUILD_SCRIPTS_DIR}" ]; then
+-    if [ "${DEPLOYMENT_LOCATION}" == "YES" ]; then
++    if [ "${DEPLOYMENT_LOCATION}" = "YES" ]; then
+         BUILD_SCRIPTS_DIR="${SDKROOT}${WK_ALTERNATE_WEBKIT_SDK_PATH}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
+     else
+         BUILD_SCRIPTS_DIR="${BUILT_PRODUCTS_DIR}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
+@@ -23,7 +23,7 @@ if [ $# -eq 0 ]; then
+ fi
+ 
+ SOURCES="Sources.txt SourcesCocoa.txt platform/SourcesLibWebRTC.txt"
+-if [ "${USE_INTERNAL_SDK}" == "YES" ]; then
++if [ "${USE_INTERNAL_SDK}" = "YES" ]; then
+     SOURCES="${SOURCES} SourcesCocoaInternalSDK.txt"
+ fi
+ 
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_check-xcfilelists.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_check-xcfilelists.sh
new file mode 100644
index 0000000000..4302b125de
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_check-xcfilelists.sh
@@ -0,0 +1,16 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/WebKitLegacy/scripts/check-xcfilelists.sh.orig	2025-08-10 14:16:45.240988935 +0000
++++ modules/javafx.web/src/main/native/Source/WebKitLegacy/scripts/check-xcfilelists.sh
+@@ -1,8 +1,8 @@
+ #!/bin/sh
+ 
+-[ "${WK_DISABLE_CHECK_XCFILELISTS}" == "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
+-[ "${DEPLOYMENT_LOCATION}" == "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
+-[ "${USE_INTERNAL_SDK}" == "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
++[ "${WK_DISABLE_CHECK_XCFILELISTS}" = "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
++[ "${DEPLOYMENT_LOCATION}" = "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
++[ "${USE_INTERNAL_SDK}" = "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
+ 
+ SCRIPT="${BUILD_SCRIPTS_DIR}/generate-xcfilelists"
+ [ -f "${SCRIPT}" ] || SCRIPT="${PROJECT_DIR}/../../../${WK_ADDITIONAL_SCRIPTS_DIR}/generate-xcfilelists"
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_generate-unified-sources.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_generate-unified-sources.sh
new file mode 100644
index 0000000000..8f34874120
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Source_WebKitLegacy_scripts_generate-unified-sources.sh
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Source/WebKitLegacy/scripts/generate-unified-sources.sh.orig	2025-08-10 14:15:56.096757442 +0000
++++ modules/javafx.web/src/main/native/Source/WebKitLegacy/scripts/generate-unified-sources.sh
+@@ -7,7 +7,7 @@ ARGS=("$@")
+ cd $SRCROOT
+ 
+ if [ -z "${BUILD_SCRIPTS_DIR}" ]; then
+-    if [ "${DEPLOYMENT_LOCATION}" == "YES" ]; then
++    if [ "${DEPLOYMENT_LOCATION}" = "YES" ]; then
+         BUILD_SCRIPTS_DIR="${SDKROOT}${WK_ALTERNATE_WEBKIT_SDK_PATH}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
+     else
+         BUILD_SCRIPTS_DIR="${BUILT_PRODUCTS_DIR}${WK_LIBRARY_HEADERS_FOLDER_PATH}/wtf/Scripts"
diff --git a/openjfx21/patches/patch-modules_javafx.web_src_main_native_Tools_DumpRenderTree_Scripts_check-xcfilelists.sh b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Tools_DumpRenderTree_Scripts_check-xcfilelists.sh
new file mode 100644
index 0000000000..f9e8705136
--- /dev/null
+++ b/openjfx21/patches/patch-modules_javafx.web_src_main_native_Tools_DumpRenderTree_Scripts_check-xcfilelists.sh
@@ -0,0 +1,16 @@
+$NetBSD$
+
+--- modules/javafx.web/src/main/native/Tools/DumpRenderTree/Scripts/check-xcfilelists.sh.orig	2025-08-10 14:15:05.377332024 +0000
++++ modules/javafx.web/src/main/native/Tools/DumpRenderTree/Scripts/check-xcfilelists.sh
+@@ -1,8 +1,8 @@
+ #!/bin/sh
+ 
+-[ "${WK_DISABLE_CHECK_XCFILELISTS}" == "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
+-[ "${DEPLOYMENT_LOCATION}" == "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
+-[ "${USE_INTERNAL_SDK}" == "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
++[ "${WK_DISABLE_CHECK_XCFILELISTS}" = "1" ] && { echo "### Not running because WK_DISABLE_CHECK_XCFILELISTS is set"; exit 0; }
++[ "${DEPLOYMENT_LOCATION}" = "YES" ] && { echo "### Not running because DEPLOYMENT_LOCATION is YES"; exit 0; }
++[ "${USE_INTERNAL_SDK}" = "YES" ] || { echo "### Not running because USE_INTERNAL_SDK is not YES"; exit 0; }
+ 
+ SCRIPT="${BUILD_SCRIPTS_DIR}/generate-xcfilelists"
+ [ -f "${SCRIPT}" ] || SCRIPT="${PROJECT_DIR}/../../../${WK_ADDITIONAL_SCRIPTS_DIR}/generate-xcfilelists"


Home | Main Index | Thread Index | Old Index