From 5c22c9f32d2f1aa50a7b22fb09f1cae29c795f83 Mon Sep 17 00:00:00 2001 From: Seonghyun Kim Date: Thu, 14 Nov 2024 17:11:34 +0900 Subject: [PATCH] Update maven release files Signed-off-by: Seonghyun Kim --- build/android/escargot/build.gradle | 30 ++++++++++++++++++++++++++- build/android/publish/android-example | 1 + build/android/publish/mac-example | 2 ++ build/android/publish/ubuntu-example | 2 ++ 4 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 build/android/publish/android-example create mode 100644 build/android/publish/mac-example create mode 100644 build/android/publish/ubuntu-example diff --git a/build/android/escargot/build.gradle b/build/android/escargot/build.gradle index 37be2b7a5..bfdb8cb63 100644 --- a/build/android/escargot/build.gradle +++ b/build/android/escargot/build.gradle @@ -1,10 +1,11 @@ plugins { id 'com.android.library' id 'jacoco' + id 'maven-publish' } ext { - force64Option = System.getProperty("ESCARGOT_BUILD_64BIT_FORCE_LARGE", "OFF") + force64Option = System.getProperty("ESCARGOT_BUILD_64BIT_FORCE_LARGE", "ON") } android { @@ -87,6 +88,33 @@ android { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } + + publishing { + singleVariant("release") { + // if you don't want sources/javadoc, remove these lines + withSourcesJar() + withJavadocJar() + } + } +} + +publishing { + publications { + release(MavenPublication) { + afterEvaluate { + from components.release + } + artifactId "escargot-android" + groupId "com.samsung.lwe.escargot" + version "X.X.X.20XXXXXX.X.XXXXXXXX" + } + } + + repositories { + maven { + url "/XXXXXX/android/releases/" + } + } } def dirForNativeNoNDK = project.layout.buildDirectory.get().dir("native_nondk") diff --git a/build/android/publish/android-example b/build/android/publish/android-example new file mode 100644 index 000000000..258f9257a --- /dev/null +++ b/build/android/publish/android-example @@ -0,0 +1 @@ +./gradlew publish diff --git a/build/android/publish/mac-example b/build/android/publish/mac-example new file mode 100644 index 000000000..e9c4db404 --- /dev/null +++ b/build/android/publish/mac-example @@ -0,0 +1,2 @@ +./gradlew bundleHostJar +MAVEN_OPTS="-Dmaven.repo.local=${MAVEN_LOCAL_PATH}/mac/releases/" mvn install:install-file -Dfile=${HOME}/escargot/build/libs/escargot.jar -DgroupId=com.samsung.lwe.escargot -DartifactId=escargot-mac -Dversion==X.X.X.20XXXXXX.X.XXXXXXX -Dpackaging=jar diff --git a/build/android/publish/ubuntu-example b/build/android/publish/ubuntu-example new file mode 100644 index 000000000..a5f6cf148 --- /dev/null +++ b/build/android/publish/ubuntu-example @@ -0,0 +1,2 @@ +./gradlew bundleHostJar +MAVEN_OPTS="-Dmaven.repo.local=${MAVEN_LOCAL_PATH}/ubuntu/releases/" mvn install:install-file -Dfile=${PWD}/escargot/build/libs/escargot.jar -DgroupId=com.samsung.lwe.escargot -DartifactId=escargot-ubuntu -Dversion=X.X.X.20XXXXXX.X.XXXXXXX -Dpackaging=jar