Minimize common subproject javafx dependencies

This commit is contained in:
Chris Beams 2018-11-04 18:16:07 +01:00
parent 3cd467cc9f
commit cb4f6edd9a
No known key found for this signature in database
GPG Key ID: 3D214F8F5BC5ED73

View File

@ -17,7 +17,12 @@ configure(rootProject) {
configure(subprojects) { configure(subprojects) {
apply plugin: 'java' apply plugin: 'java'
apply plugin: 'com.google.osdetector'
sourceCompatibility = 1.10 sourceCompatibility = 1.10
ext {
os = osdetector.os == 'osx' ? 'mac' : osdetector.os == 'windows' ? 'win' : osdetector.os
}
repositories { repositories {
jcenter() jcenter()
@ -56,11 +61,9 @@ configure(project(':assets')) {
configure(project(':common')) { configure(project(':common')) {
apply plugin: 'com.google.protobuf' apply plugin: 'com.google.protobuf'
apply plugin: 'com.google.osdetector'
ext { ext {
protobufVersion = '3.5.1' protobufVersion = '3.5.1'
platform = osdetector.os == 'osx' ? 'mac' : osdetector.os == 'windows' ? 'win' : osdetector.os
} }
sourceSets.main.java.srcDir "$buildDir/generated/source/proto/main/java" sourceSets.main.java.srcDir "$buildDir/generated/source/proto/main/java"
@ -72,12 +75,8 @@ configure(project(':common')) {
} }
dependencies { dependencies {
compile "org.openjfx:javafx-base:11:$platform" compile "org.openjfx:javafx-base:11:$os"
compile "org.openjfx:javafx-graphics:11:$platform" compile "org.openjfx:javafx-graphics:11:$os"
compile "org.openjfx:javafx-controls:11:$platform"
compile "org.openjfx:javafx-fxml:11:$platform"
compile "org.openjfx:javafx-swing:11:$platform"
compile "com.google.protobuf:protobuf-java:$protobufVersion" compile "com.google.protobuf:protobuf-java:$protobufVersion"
compile 'com.google.code.gson:gson:2.7' compile 'com.google.code.gson:gson:2.7'
compile('com.googlecode.json-simple:json-simple:1.1.1') { compile('com.googlecode.json-simple:json-simple:1.1.1') {
@ -211,6 +210,9 @@ configure(project(':desktop')) {
compile 'de.jensd:fontawesomefx-materialdesignfont:2.0.26-9.1.2' compile 'de.jensd:fontawesomefx-materialdesignfont:2.0.26-9.1.2'
compile 'com.googlecode.jcsv:jcsv:1.4.0' compile 'com.googlecode.jcsv:jcsv:1.4.0'
compile 'com.github.sarxos:webcam-capture:0.3.12' compile 'com.github.sarxos:webcam-capture:0.3.12'
compile "org.openjfx:javafx-controls:11:$os"
compile "org.openjfx:javafx-fxml:11:$os"
compile "org.openjfx:javafx-swing:11:$os"
compileOnly 'org.projectlombok:lombok:1.18.2' compileOnly 'org.projectlombok:lombok:1.18.2'
annotationProcessor 'org.projectlombok:lombok:1.18.2' annotationProcessor 'org.projectlombok:lombok:1.18.2'