11plugins {
2- id(" java-library " )
3- id(" maven-publish " )
2+ id(" java" )
3+ id(" us.ihmc.ihmc-build " )
44}
55
6- group = " us.ihmc"
7- version = " 5.0.0"
6+ ihmc {
7+ group = " us.ihmc"
8+ version = " 5.0.0"
9+ vcsUrl = " https://github.com/ihmcrobotics/zed-java-api"
10+ openSource = true
11+ description = " Use Stereolabs sensors such as ZED 2, ZED 2i, ZED X, ZED Mini, ZED X Mini from Java."
812
9- repositories {
10- mavenCentral ()
13+ configureDependencyResolution()
14+ configurePublications ()
1115}
1216
13- java {
14- withSourcesJar()
17+ tasks.javadoc {
18+ // The javadoc compiler has a lot of errors with the javacpp generated comments, but we need a javadoc.jar for publishing
19+ exclude(" us/ihmc/zed/**" )
1520}
1621
17- publishing {
18- publications {
19- create<MavenPublication >(" mavenJava" ) {
20- from(components[" java" ])
21-
22- groupId = project.group.toString()
23- artifactId = " zed-java-api"
24- version = project.version.toString()
25- }
26- }
27-
28- repositories {
29- maven {
30- val releasesRepo = uri(" https://s01.oss.sonatype.org/content/repositories/releases" )
31- val snapshotsRepo = uri(" https://s01.oss.sonatype.org/content/repositories/snapshots" )
32- url = if (version.toString().endsWith(" SNAPSHOT" )) snapshotsRepo else releasesRepo
33-
34- credentials {
35- username = project.findProperty(" publishUsername" ).toString()
36- password = project.findProperty(" publishPassword" ).toString()
37- }
38- }
39- }
40- }
41-
42- dependencies {
22+ mainDependencies {
4323 // Transitive dependencies
4424 api(" us.ihmc:javacpp:1.5.11-ihmc-2" ) {
4525 isTransitive = true
@@ -50,25 +30,18 @@ dependencies {
5030 api(" us.ihmc:ihmc-native-library-loader:2.0.4" ) {
5131 isTransitive = true
5232 }
53-
54- testImplementation(platform(" org.junit:junit-bom:5.9.1" ))
55- testImplementation(" org.junit.jupiter:junit-jupiter" )
56-
57- // OpenCV for demos
58- val openblasVersion = " 0.3.28-1.5.11-ihmc-2"
59- testImplementation(" us.ihmc:openblas:$openblasVersion " )
60- testImplementation(" us.ihmc:openblas:$openblasVersion :linux-x86_64" )
61- testImplementation(" us.ihmc:openblas:$openblasVersion :linux-arm64" )
62- testImplementation(" us.ihmc:openblas:$openblasVersion :windows-x86_64" )
63- val opencvVersion = " 4.10.0-1.5.11-ihmc-2"
64- testImplementation(" us.ihmc:opencv:$opencvVersion " )
65- testImplementation(" us.ihmc:opencv:$opencvVersion :linux-arm64" )
66- testImplementation(" us.ihmc:opencv:$opencvVersion :linux-x86_64" )
67- testImplementation(" us.ihmc:opencv:$opencvVersion :linux-x86_64-gpu" )
68- testImplementation(" us.ihmc:opencv:$opencvVersion :windows-x86_64" )
69- testImplementation(" us.ihmc:opencv:$opencvVersion :windows-x86_64-gpu" )
7033}
7134
72- tasks.test {
73- useJUnitPlatform()
35+ testDependencies {
36+ // OpenCV for demos
37+ val openblasVersion = " 0.3.28-1.5.11-ihmc-2"
38+ implementation(" us.ihmc:openblas:$openblasVersion " )
39+ implementation(" us.ihmc:openblas:$openblasVersion :linux-x86_64" )
40+ implementation(" us.ihmc:openblas:$openblasVersion :linux-arm64" )
41+ implementation(" us.ihmc:openblas:$openblasVersion :windows-x86_64" )
42+ val opencvVersion = " 4.10.0-1.5.11-ihmc-2"
43+ implementation(" us.ihmc:opencv:$opencvVersion " )
44+ implementation(" us.ihmc:opencv:$opencvVersion :linux-arm64" )
45+ implementation(" us.ihmc:opencv:$opencvVersion :linux-x86_64" )
46+ implementation(" us.ihmc:opencv:$opencvVersion :windows-x86_64" )
7447}
0 commit comments