Fix bundling issues with liberica

This commit is contained in:
crschnick
2025-05-29 05:51:36 +00:00
parent 8060024289
commit fba3750b48
3 changed files with 6 additions and 3 deletions
+3
View File
@@ -1,5 +1,6 @@
import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform
import java.lang.module.ModuleFinder
import java.util.stream.Stream
buildscript {
@@ -186,6 +187,8 @@ project.ext {
signingPassword = project.hasProperty('signingKeyPassword') ? project.property("signingKeyPassword") : (System.getenv('GPG_KEY_PASSWORD') != null ? System.getenv('GPG_KEY_PASSWORD') : "")
deeplApiKey = findProperty('DEEPL_API_KEY') != null ? findProperty('DEEPL_API_KEY') : ""
bundledJdkJavaFx = ModuleFinder.ofSystem().find("javafx.base").isPresent()
// Define a custom JavaFX SDK location
// customJavaFxPath = null
+2 -2
View File
@@ -40,7 +40,7 @@ dependencies {
implementation files(it)
}
}
if (!useBundledJavaFx) {
if (!useBundledJna) {
configurations.jna.getAsFileTree().getFiles().forEach {
implementation files(it)
}
@@ -68,7 +68,7 @@ jlink {
options.addAll('--strip-native-debug-symbols', 'exclude-debuginfo-files')
}
if (useBundledJavaFx) {
if (useBundledJavaFx && !bundledJdkJavaFx) {
addExtraModulePath(layout.projectDirectory.dir("javafx/${platformName}/${arch}").toString())
}
if (useBundledJna) {
+1 -1
View File
@@ -27,7 +27,7 @@ if (rootProject.hasProperty("customJavaFxPath")) {
dependencies {
javafx fileTree(dir: customJavaFxPath, include: '*.jar')
}
} else {
} else if (!bundledJdkJavaFx) {
// Always use maven version for now
dependencies {
javafx "org.openjfx:javafx-base:${devJavafxVersion}:${platform}"