From 5580656e79dcfe79d28652b76ce5fef0aad82735 Mon Sep 17 00:00:00 2001 From: weisj <31143295+weisJ@users.noreply.github.com> Date: Wed, 14 Apr 2021 23:54:32 +0200 Subject: [PATCH] Build: Update to Gradle 7 Upgrade gradle version to 7.0. Make use of typesafe project and library accessors. These replace the current bom project. Handle different xCode version on macOS. --- .github/workflows/gradle.yml | 4 +- .github/workflows/snapshot.yml | 2 +- .gitignore | 2 + annotations-processor/build.gradle.kts | 2 +- build.gradle.kts | 23 ++++---- .../kotlin/DownloadPrebuiltBinariesTask.kt | 2 +- buildSrc/src/main/kotlin/JniUtils.kt | 48 +++++++++++++++-- buildSrc/src/main/kotlin/UberJniJarPlugin.kt | 42 +++++---------- buildSrc/src/main/kotlin/XCode.kt | 20 +++++++ core/build.gradle.kts | 50 +++++++++--------- .../src/test/java/test/AbstractImageTest.java | 3 +- .../test/java/test/CustomTitleBarTest.java | 8 ++- .../src/test/java/test/NativeLibraryTest.java | 4 +- dependencies-bom/build.gradle.kts | 47 ---------------- gradle.properties | 16 +----- gradle/libs.versions.toml | 42 +++++++++++++++ gradle/wrapper/gradle-wrapper.jar | Bin 58910 -> 59203 bytes gradle/wrapper/gradle-wrapper.properties | 10 ++-- gradlew | 2 +- gradlew.bat | 21 ++------ macos/build.gradle.kts | 33 +++++++----- native-utils/build.gradle.kts | 1 + property-loader/build.gradle.kts | 8 +-- settings.gradle.kts | 8 +-- theme/build.gradle.kts | 12 ++--- windows/build.gradle.kts | 27 ++++------ 26 files changed, 225 insertions(+), 212 deletions(-) create mode 100644 buildSrc/src/main/kotlin/XCode.kt delete mode 100644 dependencies-bom/build.gradle.kts create mode 100644 gradle/libs.versions.toml diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 6326dec4..80f9b72d 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -45,7 +45,9 @@ jobs: with: java-version: 8 - name: Build & Test - run: xvfb-run -a -server-num=1 --server-args="-screen 0 2000x3000x16" ./gradlew build test -PskipAutostyle --info --no-daemon + env: + PROPS_GITHUB: "-PgithubAccessToken=${{ secrets.GITHUB_TOKEN }}" + run: xvfb-run -a -server-num=1 --server-args="-screen 0 2000x3000x16" ./gradlew build test -PskipAutostyle -PfailIfLibraryMissing=true $(echo $PROPS_GITHUB) --info --no-daemon - name: Upload Test Results if: ${{ always() }} uses: actions/upload-artifact@v1 diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml index 820ab922..ef864f78 100644 --- a/.github/workflows/snapshot.yml +++ b/.github/workflows/snapshot.yml @@ -25,7 +25,7 @@ jobs: java-version: 8 - name: Publish env: - PROPS_RELEASE: "-Prc=1 -Pgh -Prelease=false -PskipJavadoc -PskipAutostyle" + PROPS_RELEASE: "-Prc=1 -Pgh -Prelease=false -PskipJavadoc -PskipAutostyle -PfailIfLibraryMissing" PROPS_GIT: "-PghGitSourceUsername=${{ secrets.GH_GIT_USERNAME }} -PghGitSourcePassword=${{ secrets.GITHUB_TOKEN }}" PROPS_NEXUS: "-PghNexusUsername=${{ secrets.GH_NEXUS_USERNAME }} -PghNexusPassword=${{ secrets.GH_NEXUS_PASSWORD }}" PROPS_SIGNING: "-PuseInMemoryKey=true -Psigning.inMemoryKey=${{ secrets.IN_MEMORY_KEY }} -Psigning.password=${{ secrets.SIGNING_PASSWORD }}" diff --git a/.gitignore b/.gitignore index cb851649..9c9938a4 100644 --- a/.gitignore +++ b/.gitignore @@ -25,6 +25,8 @@ repo/ /buildSrc/out/ /*/out/ *.iml +*.ipr +*.iws .run/ # VS Code diff --git a/annotations-processor/build.gradle.kts b/annotations-processor/build.gradle.kts index 22c94518..a8c1818d 100644 --- a/annotations-processor/build.gradle.kts +++ b/annotations-processor/build.gradle.kts @@ -3,5 +3,5 @@ plugins { } dependencies { - api(project(":darklaf-annotations")) + api(projects.darklafAnnotations) } diff --git a/build.gradle.kts b/build.gradle.kts index 59a0da12..b3242a26 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -9,6 +9,7 @@ import com.github.vlsi.gradle.publishing.dsl.simplifyXml import com.github.vlsi.gradle.publishing.dsl.versionFromResolution plugins { + idea id("com.github.autostyle") id("com.github.vlsi.crlf") id("com.github.vlsi.gradle-extensions") @@ -16,9 +17,9 @@ plugins { } val skipJavadoc by props() -val enableMavenLocal by props() +val enableMavenLocal by props(false) val enableGradleMetadata by props() -val skipAutostyle by props() +val skipAutostyle by props(false) val isRelease = project.stringProperty("release").toBool() val snapshotName by props("") @@ -56,6 +57,7 @@ tasks.closeRepository.configure { enabled = isRelease } val buildVersion = "$projectVersion$snapshotIdentifier${releaseParams.snapshotSuffix}" println("Building: Darklaf $buildVersion") println(" JDK: " + System.getProperty("java.home")) +println(" Gradle: " + gradle.gradleVersion) fun BaseFormatExtension.license(addition: String = "") { val extra = if (addition.isEmpty()) "" else "\n$addition" @@ -107,9 +109,10 @@ allprojects { val githubAccessToken by props("") plugins.withType { + val failIfLibraryMissing by props(false) prebuiltBinaries { prebuiltLibrariesFolder = "pre-build-libraries" - failIfLibraryIsMissing = false + failIfLibraryIsMissing = failIfLibraryMissing github( user = "weisj", repository = "darklaf", @@ -168,13 +171,6 @@ allprojects { fileMode = "664".toInt(8) } - plugins.withType { - dependencies { - "api"(platform(project(":darklaf-dependencies-bom"))) - "annotationProcessor"(platform(project(":darklaf-dependencies-bom"))) - } - } - if (!enableGradleMetadata) { tasks.withType { enabled = false @@ -227,6 +223,7 @@ allprojects { from(source) { include("**/*.properties") filteringCharset = "UTF-8" + duplicatesStrategy = DuplicatesStrategy.INCLUDE // apply native2ascii conversion since Java 8 expects properties to have ascii symbols only filter(org.apache.tools.ant.filters.EscapeUnicode::class) } @@ -289,10 +286,8 @@ allprojects { } configure { - if (project.path.startsWith(":darklaf-dependencies-bom") || - project.path == ":" - ) { - // We don't it to Central for now + if (project.path == ":") { + // Skip the root project return@configure } diff --git a/buildSrc/src/main/kotlin/DownloadPrebuiltBinariesTask.kt b/buildSrc/src/main/kotlin/DownloadPrebuiltBinariesTask.kt index 1c7b9b8f..f93d316e 100644 --- a/buildSrc/src/main/kotlin/DownloadPrebuiltBinariesTask.kt +++ b/buildSrc/src/main/kotlin/DownloadPrebuiltBinariesTask.kt @@ -117,7 +117,7 @@ open class DownloadPrebuiltBinariesTask @Inject constructor( private val Json.latestRun: Json? get() { - val runs = this["workflow_runs"] as List + val runs = this["workflow_runs"] as? List ?: return null val candidates = runs.asSequence().filter { val completed = "completed" == it["status"] val success = "success" == it["conclusion"] diff --git a/buildSrc/src/main/kotlin/JniUtils.kt b/buildSrc/src/main/kotlin/JniUtils.kt index d7f59fcb..63e89b97 100644 --- a/buildSrc/src/main/kotlin/JniUtils.kt +++ b/buildSrc/src/main/kotlin/JniUtils.kt @@ -1,7 +1,35 @@ +import dev.nokee.platform.jni.JniLibraryDependencies import dev.nokee.runtime.nativebase.OperatingSystemFamily import dev.nokee.runtime.nativebase.TargetMachine +import org.gradle.api.Action import org.gradle.api.GradleException import org.gradle.api.Project +import org.gradle.api.artifacts.MinimalExternalModuleDependency +import org.gradle.api.artifacts.ModuleDependency +import org.gradle.api.artifacts.ModuleDependencyCapabilitiesHandler +import org.gradle.api.provider.Provider + +fun MinimalExternalModuleDependency.dependencyNotation() = + "${module.group}:${module.name}:${versionConstraint.requiredVersion}" + +fun JniLibraryDependencies.jvmLibImplementation(notation: Provider) { + jvmImplementation(notation.map { it.dependencyNotation() }.get()) +} + +fun JniLibraryDependencies.nativeLibImplementation(notation: Provider) { + nativeImplementation(notation.map { it.dependencyNotation() }.get()) +} + +fun JniLibraryDependencies.nativeLibImplementation( + notation: Provider, + action: Action +) { + nativeImplementation(notation.map { it.dependencyNotation() }.get(), action) +} + +fun ModuleDependencyCapabilitiesHandler.requireLibCapability(notation: Provider) { + requireCapabilities(notation.get().dependencyNotation()) +} val TargetMachine.variantName: String get() { @@ -11,11 +39,25 @@ val TargetMachine.variantName: String operatingSystemFamily.isMacOS -> "macos" else -> GradleException("Unknown operating system family '${operatingSystemFamily}'.") } - val architecture = if (architecture.is32Bit) "x86" else "x86-64" - return "$osFamily-$architecture" + return "$osFamily-$architectureString" } -fun libraryFileNameFor(project : Project, osFamily: OperatingSystemFamily) : String = when { +val TargetMachine.targetsHost: Boolean + get() { + val osName = System.getProperty("os.name").toLowerCase().replace(" ", "") + val osFamily = operatingSystemFamily + return when { + osFamily.isWindows && osName.contains("windows") -> true + osFamily.isLinux && osName.contains("linux") -> true + osFamily.isMacOS && osName.contains("macos") -> true + else -> false + } + } + +val TargetMachine.architectureString: String + get() = if (architecture.is32Bit) "x86" else "x86-64" + +fun libraryFileNameFor(project: Project, osFamily: OperatingSystemFamily): String = when { osFamily.isWindows -> "${project.name}.dll" osFamily.isLinux -> "lib${project.name}.so" osFamily.isMacOS -> "lib${project.name}.dylib" diff --git a/buildSrc/src/main/kotlin/UberJniJarPlugin.kt b/buildSrc/src/main/kotlin/UberJniJarPlugin.kt index 30fafc33..e1908d6d 100644 --- a/buildSrc/src/main/kotlin/UberJniJarPlugin.kt +++ b/buildSrc/src/main/kotlin/UberJniJarPlugin.kt @@ -1,12 +1,11 @@ -import dev.nokee.platform.base.VariantView +import dev.nokee.platform.jni.JarBinary import dev.nokee.platform.jni.JniJarBinary -import dev.nokee.platform.jni.JniLibrary import dev.nokee.platform.jni.JniLibraryExtension import org.gradle.api.Plugin import org.gradle.api.Project +import org.gradle.api.file.FileTree import org.gradle.api.provider.Provider import org.gradle.jvm.tasks.Jar -import dev.nokee.runtime.nativebase.TargetMachine class UberJniJarPlugin : Plugin { @@ -20,34 +19,17 @@ class UberJniJarPlugin : Plugin { val project = task.project val logger = task.logger val library = project.extensions.getByType(JniLibraryExtension::class.java) - library.binaries.withType(JniJarBinary::class.java).configureEach { - jarTask.configure { enabled = false } - } + logger.info("${project.name}: Merging binaries into the JVM Jar.") - when (library.targetMachines.get().size) { - 0 -> logger.info("No native target for project ${project.name}") - 1 -> { - library.variants.configureEach { - task.into(this@configureEach.resourcePath) { - from(this@configureEach.nativeRuntimeFiles) - } - } - } - else -> { - for (targetMachine in library.targetMachines.get()) { - val variant = library.variants.withTarget(targetMachine) - task.into(variant.map { it.resourcePath }) { - from(variant.map { it.nativeRuntimeFiles }) - } - } - } - } + task.from(library.variants.flatMap { variant -> + if (variant.targetMachine.targetsHost) { + variant.binaries.withType(JniJarBinary::class.java) + .map { it.asZipTree(project) }.get() + } else listOf() + }) } - private fun VariantView.withTarget(target: TargetMachine): Provider { - return filter { it.targetMachine == target }.map { - check(it.size == 1) - it.first() - } - } + private fun JarBinary.asZipTree(project: Project): Provider = + jarTask.map { project.zipTree(it.archiveFile) } + } diff --git a/buildSrc/src/main/kotlin/XCode.kt b/buildSrc/src/main/kotlin/XCode.kt new file mode 100644 index 00000000..459c0ba8 --- /dev/null +++ b/buildSrc/src/main/kotlin/XCode.kt @@ -0,0 +1,20 @@ +import org.gradle.util.VersionNumber +import java.util.concurrent.TimeUnit + +fun String.runCommand(): String? { + return runCatching { + val process = ProcessBuilder(*split(" ").toTypedArray()).start() + val output = process.inputStream.reader(Charsets.UTF_8).use { + it.readText() + } + process.waitFor(10, TimeUnit.SECONDS) + output.trim() + }.getOrNull() +} + +fun getXCodeVersion(): VersionNumber? { + val version = "/usr/bin/xcodebuild -version".runCommand() ?: return null + val extracted = Regex("""Xcode\s+([0-9\\.]*).*""") + .find(version)?.groupValues?.getOrNull(1) ?: return null + return VersionNumber.parse(extracted) +} diff --git a/core/build.gradle.kts b/core/build.gradle.kts index dd1f2932..0050efe6 100644 --- a/core/build.gradle.kts +++ b/core/build.gradle.kts @@ -7,31 +7,30 @@ plugins { } dependencies { - api(project(":darklaf-theme")) - api(project(":darklaf-property-loader")) - api(project(":darklaf-utils")) - implementation(project(":darklaf-native-utils")) - implementation(project(":darklaf-platform-base")) - implementation(project(":darklaf-windows")) - implementation(project(":darklaf-macos")) - implementation("org.swinglabs:jxlayer") - implementation("com.formdev:svgSalamander") - implementation("com.github.weisj:swing-dsl-laf-support") - - compileOnly("org.jetbrains:annotations") - compileOnly("org.swinglabs:swingx") - - testImplementation("com.formdev:svgSalamander") - testImplementation("com.miglayout:miglayout-core") - testImplementation("com.miglayout:miglayout-swing") - testImplementation("org.swinglabs:swingx") - testImplementation("org.junit.jupiter:junit-jupiter-api") - testImplementation("com.fifesoft:rsyntaxtextarea") - testImplementation("com.github.lgooddatepicker:LGoodDatePicker") - testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") - - annotationProcessor("com.google.auto.service:auto-service") - compileOnly("com.google.auto.service:auto-service-annotations") + api(projects.darklafTheme) + api(projects.darklafPropertyLoader) + api(projects.darklafUtils) + implementation(projects.darklafNativeUtils) + implementation(projects.darklafPlatformBase) + implementation(projects.darklafWindows) + implementation(projects.darklafMacos) + implementation(libs.swingDsl) + implementation(libs.svgSalamander) + implementation(libs.jxlayer) + + compileOnly(libs.nullabilityAnnotations) + compileOnly(libs.swingx) + + testImplementation(libs.svgSalamander) + testImplementation(libs.bundles.test.miglayout) + testImplementation(libs.swingx) + testImplementation(libs.test.rsyntaxtextarea) + testImplementation(libs.test.lGoodDatePicker) + testImplementation(libs.test.junit.api) + testRuntimeOnly(libs.test.junit.engine) + + compileOnly(libs.autoservice.annotations) + annotationProcessor(libs.autoservice.processor) } tasks.test { @@ -44,6 +43,7 @@ fun Jar.includeLicenses() { CrLfSpec(LineEndings.LF).run { into("META-INF") { filteringCharset = "UTF-8" + duplicatesStrategy = DuplicatesStrategy.EXCLUDE textFrom("$rootDir/licenses/DARCULA_LICENSE.txt") textFrom("$rootDir/licenses/INTELLIJ_LICENSE.txt") textFrom("$rootDir/licenses/INTELLIJ_NOTICE.txt") diff --git a/core/src/test/java/test/AbstractImageTest.java b/core/src/test/java/test/AbstractImageTest.java index 1d6f4aa4..ad4f6513 100644 --- a/core/src/test/java/test/AbstractImageTest.java +++ b/core/src/test/java/test/AbstractImageTest.java @@ -30,7 +30,6 @@ import java.nio.file.Files; import javax.imageio.ImageIO; import com.github.weisj.darklaf.util.ImageUtil; -import com.github.weisj.darklaf.util.Scale; import com.github.weisj.darklaf.util.graphics.ScaledImage; abstract class AbstractImageTest { @@ -79,7 +78,7 @@ abstract class AbstractImageTest { Robot robot = new Robot(); Point p = w.getLocationOnScreen(); BufferedImage image = robot.createScreenCapture( - new Rectangle(p.x, p.y, Scale.scaleWidth(w.getWidth()), Scale.scaleHeight(w.getHeight()))); + new Rectangle(p.x, p.y, w.getWidth(), w.getHeight())); ImageIO.write(image, "png", file); return image; } catch (IOException | AWTException e) { diff --git a/core/src/test/java/test/CustomTitleBarTest.java b/core/src/test/java/test/CustomTitleBarTest.java index 5c1bb583..e35fae1a 100644 --- a/core/src/test/java/test/CustomTitleBarTest.java +++ b/core/src/test/java/test/CustomTitleBarTest.java @@ -91,6 +91,7 @@ class CustomTitleBarTest extends AbstractImageTest { }); } }); + f.setAlwaysOnTop(true); f.setVisible(true); frameModifier.accept(f); }); @@ -104,6 +105,11 @@ class CustomTitleBarTest extends AbstractImageTest { Thread.currentThread().interrupt(); } } + try { + new Robot().waitForIdle(); + } catch (AWTException e) { + e.printStackTrace(); + } return frame; } @@ -201,7 +207,7 @@ class CustomTitleBarTest extends AbstractImageTest { @Test @EnabledOnOs({OS.MAC, OS.WINDOWS}) void checkTitleBarHidden() { - SwingUtilities.invokeLater(() -> LafManager.install(new IntelliJTheme())); + TestUtils.runOnSwingThreadNotThrowing(() -> LafManager.install(new IntelliJTheme())); UIManager.put("macos.coloredTitleBar", true); Assertions.assertTrue(LafManager.isDecorationsEnabled()); checkImage("title_bar_hidden_" + SystemInfo.getOsName(), diff --git a/core/src/test/java/test/NativeLibraryTest.java b/core/src/test/java/test/NativeLibraryTest.java index 6f7a2b07..6b0836be 100644 --- a/core/src/test/java/test/NativeLibraryTest.java +++ b/core/src/test/java/test/NativeLibraryTest.java @@ -44,9 +44,9 @@ class NativeLibraryTest { @EnabledOnOs(OS.WINDOWS) void testWindowsLibraryLoading() { WindowsLibrary library = new TestWindowsLibrary(); - Assertions.assertNotNull(getClass().getResource(library.getX64Path() + library.getLibraryName()), + Assertions.assertNotNull(WindowsLibrary.class.getResource(library.getX64Path() + library.getLibraryName()), "x64 library doesn't exist"); - Assertions.assertNotNull(getClass().getResource(library.getX86Path() + library.getLibraryName()), + Assertions.assertNotNull(WindowsLibrary.class.getResource(library.getX86Path() + library.getLibraryName()), "x86 library doesn't exist"); // Assertions.assertDoesNotThrow(library::updateLibrary); // Assertions.assertTrue(library.isLoaded(), "Windows library isn't loaded"); diff --git a/dependencies-bom/build.gradle.kts b/dependencies-bom/build.gradle.kts deleted file mode 100644 index 04d65fed..00000000 --- a/dependencies-bom/build.gradle.kts +++ /dev/null @@ -1,47 +0,0 @@ -plugins { - `java-platform` -} - -val String.v: String get() = rootProject.extra["$this.version"] as String - -// Note: Gradle allows to declare dependency on "bom" as "api", -// and it makes the constraints to be transitively visible -// However Maven can't express that, so the approach is to use Gradle resolution -// and generate pom files with resolved versions -// See https://github.com/gradle/gradle/issues/9866 - -fun DependencyConstraintHandlerScope.apiv( - notation: String, - versionProp: String = notation.substringAfterLast(':') -) = - "api"("$notation:${versionProp.v}") - -fun DependencyConstraintHandlerScope.runtimev( - notation: String, - versionProp: String = notation.substringAfterLast(':') -) = - "runtimeOnly"("$notation:${versionProp.v}") - -dependencies { - // Parenthesis are needed here: https://github.com/gradle/gradle/issues/9248 - (constraints) { - // api means "the dependency is for both compilation and runtime" - // runtime means "the dependency is only for runtime, not for compilation" - // In other words, marking dependency as "runtime" would avoid accidental - // dependency on it during compilation - apiv("net.java.dev.jna:jna") - apiv("org.swinglabs:jxlayer") - apiv("org.swinglabs:swingx") - apiv("com.formdev:svgSalamander") - apiv("com.fifesoft:rsyntaxtextarea") - apiv("com.miglayout:miglayout-core", "miglayout") - apiv("com.miglayout:miglayout-swing", "miglayout") - apiv("org.junit.jupiter:junit-jupiter-api", "junit") - apiv("org.junit.jupiter:junit-jupiter-engine", "junit") - apiv("com.google.auto.service:auto-service-annotations", "auto-service") - apiv("com.google.auto.service:auto-service", "auto-service") - apiv("com.github.lgooddatepicker:LGoodDatePicker") - apiv("com.github.weisj:swing-dsl-laf-support", "swing-dsl") - apiv("org.jetbrains:annotations") - } -} diff --git a/gradle.properties b/gradle.properties index 9f59e7f8..7bd1e857 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,6 @@ # suppress inspection "UnusedProperty" for whole file org.gradle.parallel = true +org.gradle.caching = true kotlin.code.style = official # See https://github.com/gradle/gradle/pull/11358 , https://issues.apache.org/jira/browse/INFRA-14923 @@ -10,19 +11,6 @@ systemProp.org.gradle.internal.publish.checksums.insecure = true darklaf.version = 2.6.0 # Plugins -com.github.vlsi.vlsi-release-plugins.version = 1.70 +com.github.vlsi.vlsi-release-plugins.version = 1.74 com.github.autostyle.version = 3.1 nokee.version = 0.4.0 - -# Dependencies -jna.version = 5.5.0 -jxlayer.version = 3.0.4 -miglayout.version = 5.2 -swingx.version = 1.6.1 -svgSalamander.version = 1.1.2.4 -junit.version = 5.6.2 -rsyntaxtextarea.version = 3.1.1 -auto-service.version = 1.0-rc7 -LGoodDatePicker.version = 11.0.2 -swing-dsl.version = latest.integration -annotations.version = 16.0.2 diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml new file mode 100644 index 00000000..f465e329 --- /dev/null +++ b/gradle/libs.versions.toml @@ -0,0 +1,42 @@ +[versions] +jna = "5.5.0" +jxlayer = "3.0.4" +swingx = "1.6.1" +miglayout = "5.2" +svgSalamander = "1.1.2.4" +rsyntaxtextarea = "3.1.1" +junit = "5.6.2" +autoservice = "1.0-rc7" +miglayout = "5.2" +lGoodDatePicker = "11.0.2" +swingDsl = "latest.integration" +nullabilityAnnotations = "16.0.2" +macOSFramework = "latest.integration" + +[libraries] +jna = { module = "net.java.dev.jna:jna", version.ref = "jna" } +jxlayer = { module = "org.swinglabs:jxlayer", version.ref = "jxlayer" } +swingx = { module = "org.swinglabs:swingx", version.ref = "swingx" } +svgSalamander = { module = "com.formdev:svgSalamander", version.ref = "svgSalamander" } +swingDsl = { module = "com.github.weisj:swing-dsl-laf-support", version.ref = "swingDsl" } +autoservice-annotations = { module = "com.google.auto.service:auto-service-annotations", version.ref = "autoservice" } +autoservice-processor = { module = "com.google.auto.service:auto-service", version.ref = "autoservice" } +nullabilityAnnotations = { module = "org.jetbrains:annotations", version.ref = "nullabilityAnnotations" } + +# MacOS frameworks +macosLegacy-javaVM-base = { module = "dev.nokee.framework:JavaVM", version.ref = "macOSFramework" } +macosLegacy-javaVM-capability-javaNativeFoundation = { module = "JavaVM:JavaNativeFoundation", version.ref = "macOSFramework" } +macos-javaNativeFoundation = { module = "dev.nokee.framework:JavaNativeFoundation", version.ref = "macOSFramework" } +macos-appKit = { module = "dev.nokee.framework:AppKit", version.ref = "macOSFramework" } +macos-cocoa = { module = "dev.nokee.framework:Cocoa", version.ref = "macOSFramework" } + +# Test libraries +test-junit-api = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "junit" } +test-junit-engine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "junit" } +test-miglayout-core = { module = "com.miglayout:miglayout-core", version.ref = "miglayout" } +test-miglayout-swing = { module = "com.miglayout:miglayout-swing", version.ref = "miglayout" } +test-lGoodDatePicker = { module = "com.github.lgooddatepicker:LGoodDatePicker", version.ref = "lGoodDatePicker" } +test-rsyntaxtextarea = { module = "com.fifesoft:rsyntaxtextarea", version.ref = "rsyntaxtextarea" } + +[bundles] +test-miglayout = ["test-miglayout-core", "test-miglayout-swing"] diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 62d4c053550b91381bbd28b1afc82d634bf73a8a..e708b1c023ec8b20f512888fe07c5bd3ff77bb8f 100644 GIT binary patch delta 6656 zcmY+Ibx_pN*Z*PZ4(U#j1qtbvrOTyO8fghZ8kYJfEe%U|$dV!@ASKczEZq$fg48M@ z;LnHO_j#Uq?%bL4dY^md%$$4Y+&@nKC|1uHR&59YNhubGh72|a#ylPdh9V+akp|I; zPk^W-a00GrFMkz_NSADdv2G2-i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|F~JEUGxz;+DB=8fxXhnBI4R12q6ews$lA`Jfi}r@A@-)6TOAUMNYFYJ zZ-Zd?lxFTyjN3mXnL!%#>Z%$0gJ4*9g;e;@zSmQ{eGGDaRRNM3s@6!;hYuVc=c+3B z=qzNNS~n^EsJU4aOGE|mdy={C^lPKEfPL-IJAsTpQsDgZ@~s+eHZYmp9yb=YW_4r?lqQaYZQ`nau){W`LY#P)>i zq^wHEuOYs#FlPZeMuT@Etb@~A6feCebq`miJE3w+gAL%bVF_s*5e*@)?xmKSo%I3? zLELHVdWia$}~s6 zr!^LfxSSB4Td&9iTXrzQpl5ZDo#SdmNr;23QsPHQ!x!UT9xtb!Ycz^JF8x)%cFOXK z^EXw%dRz_VD}7?RU^4{)1+xFO=z!EI8IUa3U*rag=1BpHX$Xi<__kSbS{y_xa*MJv z_`thq0Z^sPzjAk48ssDQj}!$N8Q$XC84(bU$t_Bm69Jf+C!h_}ep zwzpQj9sRA94<{x3{~z&ix-DwX;RAzka)4-#6ZHJqKh|SVuO|>Yrv+m30+!|sK<-|E z=)5E->#y<_1V|T1f%Af!ZYqXg}`O zI$qKOWdnclF`%_Z`WGOe{`A`l-#a?s=Q1a#@BOWmExH2;Wl`OB!B-%lq3nO{4=WO& z#k_x|N&(qzm*6S{G*|GCegF2N2ulC+(58z2DG~yUs}i8zvRf&$CJCaexJ6Xu!`qz( z)*v8*kAE#D0KCo*s{8^Rbg=`*E2MzeIt0|x55%n-gO&yX#$l=3W7-_~&(G8j1E(XB hw}tl`5K!1C(72%nnjQrp<7@!WCh47rWB+@R{{wClNUHz< diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index c2de0917..f371643e 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ -distributionBase = GRADLE_USER_HOME -distributionPath = wrapper/dists -distributionUrl = https\://services.gradle.org/distributions/gradle-6.5-bin.zip -zipStoreBase = GRADLE_USER_HOME -zipStorePath = wrapper/dists +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-7.0-bin.zip +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew index fbd7c515..4f906e0c 100755 --- a/gradlew +++ b/gradlew @@ -130,7 +130,7 @@ fi if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then APP_HOME=`cygpath --path --mixed "$APP_HOME"` CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - + JAVACMD=`cygpath --unix "$JAVACMD"` # We build the pattern for arguments to be converted via cygpath diff --git a/gradlew.bat b/gradlew.bat index 5093609d..107acd32 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -40,7 +40,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto init +if "%ERRORLEVEL%" == "0" goto execute echo. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. @@ -54,7 +54,7 @@ goto fail set JAVA_HOME=%JAVA_HOME:"=% set JAVA_EXE=%JAVA_HOME%/bin/java.exe -if exist "%JAVA_EXE%" goto init +if exist "%JAVA_EXE%" goto execute echo. echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% @@ -64,21 +64,6 @@ echo location of your Java installation. goto fail -:init -@rem Get command-line arguments, handling Windows variants - -if not "%OS%" == "Windows_NT" goto win9xME_args - -:win9xME_args -@rem Slurp the command line arguments. -set CMD_LINE_ARGS= -set _SKIP=2 - -:win9xME_args_slurp -if "x%~1" == "x" goto execute - -set CMD_LINE_ARGS=%* - :execute @rem Setup the command line @@ -86,7 +71,7 @@ set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar @rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* :end @rem End local scope for the variables with windows NT shell diff --git a/macos/build.gradle.kts b/macos/build.gradle.kts index 9cdfec4e..6233fb70 100644 --- a/macos/build.gradle.kts +++ b/macos/build.gradle.kts @@ -1,3 +1,5 @@ +import org.gradle.util.VersionNumber + plugins { java id("dev.nokee.jni-library") @@ -7,29 +9,32 @@ plugins { } library { - val minOs = "10.10" - val frameworkVersion = "10.15" - dependencies { - jvmImplementation(project(":darklaf-theme")) - jvmImplementation(project(":darklaf-native-utils")) - jvmImplementation(project(":darklaf-utils")) - jvmImplementation(project(":darklaf-platform-base")) - jvmImplementation(project(":darklaf-property-loader")) - nativeImplementation("dev.nokee.framework:JavaVM:[$frameworkVersion,)") - nativeImplementation("dev.nokee.framework:JavaVM:[$frameworkVersion,)") { - capabilities { - requireCapability("JavaVM:JavaNativeFoundation:[$frameworkVersion,)") + jvmImplementation(projects.darklafTheme) + jvmImplementation(projects.darklafNativeUtils) + jvmImplementation(projects.darklafUtils) + jvmImplementation(projects.darklafPlatformBase) + jvmImplementation(projects.darklafPropertyLoader) + nativeLibImplementation(libs.macos.appKit) + nativeLibImplementation(libs.macos.cocoa) + val xCodeVersion = getXCodeVersion() + if (xCodeVersion != null && xCodeVersion >= VersionNumber.parse("12.2")) { + nativeLibImplementation(libs.macos.javaNativeFoundation) + } else { + nativeLibImplementation(libs.macosLegacy.javaVM.base) + nativeLibImplementation(libs.macosLegacy.javaVM.base) { + capabilities { + requireLibCapability(libs.macosLegacy.javaVM.capability.javaNativeFoundation) + } } } - nativeImplementation("dev.nokee.framework:AppKit:[$frameworkVersion,)") - nativeImplementation("dev.nokee.framework:Cocoa:[$frameworkVersion,)") } targetMachines.addAll(machines.macOS.x86_64) variants.configureEach { resourcePath.set("com/github/weisj/darklaf/platform/${project.name}/${targetMachine.variantName}") sharedLibrary { + val minOs = "10.10" compileTasks.configureEach { compilerArgs.addAll("-mmacosx-version-min=$minOs") // Build type not modeled yet, assuming release diff --git a/native-utils/build.gradle.kts b/native-utils/build.gradle.kts index 48c13fe4..191e1488 100644 --- a/native-utils/build.gradle.kts +++ b/native-utils/build.gradle.kts @@ -9,6 +9,7 @@ tasks.jar { CrLfSpec(LineEndings.LF).run { into("META-INF") { filteringCharset = "UTF-8" + duplicatesStrategy = DuplicatesStrategy.EXCLUDE textFrom("$rootDir/licenses/NATIVEUTIL_LICENSE.txt") } } diff --git a/property-loader/build.gradle.kts b/property-loader/build.gradle.kts index 453320d9..c2b28ba0 100644 --- a/property-loader/build.gradle.kts +++ b/property-loader/build.gradle.kts @@ -3,10 +3,10 @@ plugins { } dependencies { - api(project(":darklaf-utils")) - implementation("com.formdev:svgSalamander") - testImplementation("org.junit.jupiter:junit-jupiter-api") - testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") + api(projects.darklafUtils) + implementation(libs.svgSalamander) + testImplementation(libs.test.junit.api) + testRuntimeOnly(libs.test.junit.engine) } tasks.test { diff --git a/settings.gradle.kts b/settings.gradle.kts index 156537cc..4a9dfec0 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,8 +1,10 @@ +enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS") +enableFeaturePreview("VERSION_CATALOGS") + pluginManagement { plugins { fun String.v() = extra["$this.version"].toString() - fun PluginDependenciesSpec.idv(id: String, key: String = id) = id(id) version key.v() - + fun idv(id: String, key: String = id) = id(id) version key.v() idv("com.github.autostyle") idv("com.github.vlsi.crlf", "com.github.vlsi.vlsi-release-plugins") idv("com.github.vlsi.gradle-extensions", "com.github.vlsi.vlsi-release-plugins") @@ -10,11 +12,9 @@ pluginManagement { idv("com.github.vlsi.stage-vote-release", "com.github.vlsi.vlsi-release-plugins") } } - rootProject.name = "darklaf" include( - "dependencies-bom", "annotations", "annotations-processor", "native-utils", diff --git a/theme/build.gradle.kts b/theme/build.gradle.kts index 8d937d3e..f882c2a3 100644 --- a/theme/build.gradle.kts +++ b/theme/build.gradle.kts @@ -3,12 +3,12 @@ plugins { } dependencies { - implementation(project(":darklaf-property-loader")) - implementation(project(":darklaf-utils")) + implementation(projects.darklafPropertyLoader) + implementation(projects.darklafUtils) - compileOnly(project(":darklaf-annotations")) - annotationProcessor(project(":darklaf-annotations-processor")) + compileOnly(projects.darklafAnnotations) + annotationProcessor(projects.darklafAnnotationsProcessor) - annotationProcessor("com.google.auto.service:auto-service") - compileOnly("com.google.auto.service:auto-service-annotations") + compileOnly(libs.autoservice.annotations) + annotationProcessor(libs.autoservice.processor) } diff --git a/windows/build.gradle.kts b/windows/build.gradle.kts index a61d1989..2f98f0bc 100644 --- a/windows/build.gradle.kts +++ b/windows/build.gradle.kts @@ -8,12 +8,12 @@ plugins { library { dependencies { - jvmImplementation(project(":darklaf-native-utils")) - jvmImplementation(project(":darklaf-utils")) - jvmImplementation(project(":darklaf-platform-base")) - jvmImplementation(project(":darklaf-theme")) - jvmImplementation(project(":darklaf-property-loader")) - jvmImplementation("net.java.dev.jna:jna") + jvmImplementation(projects.darklafNativeUtils) + jvmImplementation(projects.darklafUtils) + jvmImplementation(projects.darklafPlatformBase) + jvmImplementation(projects.darklafTheme) + jvmImplementation(projects.darklafPropertyLoader) + jvmLibImplementation(libs.jna) } targetMachines.addAll(machines.windows.x86, machines.windows.x86_64) @@ -23,17 +23,8 @@ library { compileTasks.configureEach { compilerArgs.addAll(toolChain.map { when (it) { - is Gcc, is Clang -> listOf("--std=c++11", "-Wall", "-Wextra", "-pedantic", "-Werror") - is VisualCpp -> listOf("/EHsc", "/W4", "/permissive", "/WX") - else -> emptyList() - } - }) - - // Build type not modeled yet, assuming release - compilerArgs.addAll(toolChain.map { - when (it) { - is Gcc, is Clang -> listOf("-O2") - is VisualCpp -> listOf("/O2") + is Gcc, is Clang -> listOf("--std=c++17", "-Wall", "-Wextra", "-pedantic", "-O2") + is VisualCpp -> listOf("/std:c++17", "/EHsc", "/W4", "/permissive", "/WX", "/02") else -> emptyList() } }) @@ -41,7 +32,7 @@ library { linkTask.configure { linkerArgs.addAll(toolChain.map { when (it) { - is Gcc, is Clang -> listOf("-ldwmapi", "-lGdi32", "-luser32", "-ladvapi32", "-Shell32") + is Gcc, is Clang -> listOf("-ldwmapi", "-lGdi32", "-luser32", "-ladvapi32", "-lShell32") is VisualCpp -> listOf("dwmapi.lib", "user32.lib", "Gdi32.lib", "Advapi32.lib", "Shell32.lib") else -> emptyList() }