Skip to content

Commit

Permalink
getting closer …
Browse files Browse the repository at this point in the history
  • Loading branch information
IOOI-SqAR committed Jan 2, 2024
1 parent 527d064 commit f4b051f
Show file tree
Hide file tree
Showing 9 changed files with 96 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions JTCEMU/settings.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
rootProject.name = "JTCEMU"
1 change: 1 addition & 0 deletions JTCEMUCommon/settings.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
rootProject.name = "JTCEMUCommon"
86 changes: 86 additions & 0 deletions JTCemuFX/biuld.gradle.kts.off
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
buildscript {
extra.apply {
set("javafx_version", 21)
}
repositories {
gradlePluginPortal()
}
dependencies {
classpath("org.openjfx:javafx-plugin:0.1.0")
classpath("org.gradle.kotlin:gradle-kotlin-dsl-plugins:4.2.1")
}
}
apply(plugin = "org.openjfx.javafxplugin")

plugins {
id("java")
id("application")
id("org.gradle.kotlin.kotlin-dsl") version "4.2.1"
id("org.javamodularity.moduleplugin") version "1.8.12"
id("org.openjfx.javafxplugin") version "0.1.0"
id("org.beryx.jlink") version "2.25.0"
}

group "com.example"
version "1.0-SNAPSHOT"

repositories {
mavenCentral()
gradlePluginPortal()
}

java {
sourceCompatibility = org.gradle.api.JavaVersion.VERSION_21
targetCompatibility = org.gradle.api.JavaVersion.VERSION_21
modularity.inferModulePath.set(false)
}
tasks.withType<JavaCompile> {
options.encoding = "UTF-8"
}

javafx {
version = "${extra("javafx_version")}"
application {
mainClass.set("org.jens_mueller.jtcemu.platform.fx.Launcher")
applicationName = "JTCemuFX"
}
modules("javafx.base","javafx.fxml","javafx.controls","javafx.graphics","javafx.web","javafx.media","javafx.swing")
}

dependencies {
implementation(project(":JTCEMUCommon"))

// here starts JavaFX
compileOnly("org.openjfx:javafx-plugin:0.1.0")

compileOnly("org.openjfx:javafx:${extra("javafx_version")}")

compileOnly("org.openjfx:javafx-base:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-graphics:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-controls:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-fxml:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-swing:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-media:${extra("javafx_version")}")
compileOnly("org.openjfx:javafx-web:${extra("javafx_version")}")

testImplementation("junit:junit:4.13.1")
}

tasks.withType<Jar> {
manifest {
attributes["Main-Class"] = "org.jens_mueller.jtcemu.platform.fx.Launcher"
// attributes["Class-Path"] = configurations
// .runtimeClasspath
// .get()
// .joinToString(separator = " ") { if (it.isDirectory) { it.toString() } else { zipTree(it).toString() } }
// .duplicatesStrategy(DuplicatesStrategy.EXCLUDE)
}
}

jlink{
launcher {
name = "org.jens_mueller.jtcemu.platform.fx.Launcher"
}
imageZip = project.file("${buildDir}/distributions/app-${javafx.platform.classifier}.zip")
addOptions("--strip-debug", "--compress", "2", "--no-header-files", "--no-man-pages")
}
3 changes: 2 additions & 1 deletion JTCemuFX/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,14 @@ repositories {
}

ext {
javafx_version = '21'
junitVersion = '5.10.0'
}

sourceCompatibility = '21'
targetCompatibility = '21'

tasks.withType(JavaCompile) {
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
}

Expand Down
5 changes: 1 addition & 4 deletions JTCemuFX/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
module org.jens_mueller.jtcemu.platform.fx {
requires javafx.controls;
requires javafx.fxml;

opens org.jens_mueller.jtcemu.platform.fx to javafx.fxml;
opens org.jens_mueller.jtcemu.platform.fx;
exports org.jens_mueller.jtcemu.platform.fx;
}
1 change: 1 addition & 0 deletions VirtualJTCCommon/settings.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
rootProject.name = "VirtualJTCCommon"
2 changes: 0 additions & 2 deletions bin/Manifest.txt

This file was deleted.

5 changes: 3 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
buildscript {
ext.javafx_version = '21'
repositories {
maven { url 'https://plugins.gradle.org/m2/' }
}
}

plugins {
id 'java'
id 'application'
}

group 'org.sqar.virtualjtc'
Expand Down

0 comments on commit f4b051f

Please sign in to comment.