summaryrefslogtreecommitdiffstats
path: root/jenkins-builds
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2015-07-29 04:04:49 +0200
committerSven Gothel <[email protected]>2015-07-29 04:04:49 +0200
commite58bf0a5418a777ae79387df1a24a6907df686ba (patch)
tree4ca3a0b544b7d3edafe012ee5a213c9f1b6b04a3 /jenkins-builds
parentbb6b048aca5dce0d6d6edbdf93a2bec3174a9700 (diff)
Bug 1145 - Provide JogAmp Big Fat Jars and Fat 7z Archive
New files: - fat/jogamp-fat.jar - fat/jogamp-fat-test.jar - fat/jogamp-fat-java-src.jar - archive/jogamp-fat-all.7z
Diffstat (limited to 'jenkins-builds')
-rwxr-xr-xjenkins-builds/funcs_promotion.sh75
-rwxr-xr-xjenkins-builds/promote-latest-builds.sh13
2 files changed, 85 insertions, 3 deletions
diff --git a/jenkins-builds/funcs_promotion.sh b/jenkins-builds/funcs_promotion.sh
index 7f5a1ad..d7bcbf1 100755
--- a/jenkins-builds/funcs_promotion.sh
+++ b/jenkins-builds/funcs_promotion.sh
@@ -13,6 +13,7 @@ function prom_setup() {
mkdir $ldest/archive/jogamp-$i/test-results/
done
mkdir $ldest/jar
+ mkdir $ldest/fat
mkdir $ldest/apk
mkdir $ldest/jar/atomic
mkdir $ldest/javadoc
@@ -263,7 +264,7 @@ function prom_promote_module() {
done
cd ..
# copy the master pic JAR files
- # 7z folder verfified above already
+ # 7z folder verified above already
local zfile=archive/jogamp-$masterpick/$module-$masterpick.7z
local zfolder=tmp/`basename $zfile .7z`
if [ -e $zfolder/jar ] ; then
@@ -284,6 +285,78 @@ function prom_promote_module() {
cd $lthisdir
}
+#
+# #1 destination folder of artifacts
+#
+# Example:
+# prom_make_fatjar tmp-archive
+#
+function prom_make_fatjar() {
+ # debug
+ # set -x
+
+ local destdir=$1
+
+ local lthisdir=`pwd`
+
+ local master_gluegen=../../tmp/gluegen-$masterpick
+
+ echo "INFO: Make Fat Jar"
+ cd $destdir
+
+ mkdir tmp/fatjar
+ cd tmp/fatjar
+ fat_native_modules="gluegen-rt-natives joal-natives jogl-all-natives jocl-natives"
+ for h in $fat_native_modules ; do
+ for i in $os_and_archs_minus_android ; do
+ unzip ../../jar/$h-$i.jar
+ rm -rf META-INF
+ mkdir -p natives/$i
+ for j in `find . -maxdepth 1 -name \*.so -o -name \*.dll -o -name \*.jnilib -o -name \*dylib` ; do
+ mv $j natives/$i/
+ done
+ done
+ done
+ #rm -rf jogamp/nativetag
+
+ fat_core_jar_modules="gluegen-rt joal jogl-all jocl"
+ for h in $fat_core_jar_modules ; do
+ unzip ../../jar/$h.jar
+ rm -rf META-INF
+ done
+ jar cfm ../../fat/jogamp-fat.jar $master_gluegen/dist/jogamp-fat.mf .
+ cd ../..
+
+ mkdir tmp/fatjarsrc
+ cd tmp/fatjarsrc
+ fat_java_src_modules="gluegen joal jogl jocl"
+ for i in $fat_java_src_modules ; do
+ unzip ../../tmp/$i-$masterpick/$i-java-src.zip
+ rm -rf META-INF
+ done
+ zip -r ../../fat/jogamp-fat-java-src.zip .
+ cd ../..
+
+ mkdir tmp/testjar
+ cd tmp/testjar
+ fat_test_jar_modules="junit gluegen-test-util joal-test jogl-test jocl-test"
+ for h in $fat_test_jar_modules ; do
+ unzip ../../jar/$h.jar
+ rm -rf META-INF
+ done
+ unzip $master_gluegen/dist/junit.jar
+ rm -rf META-INF
+
+ jar cfm ../../fat/jogamp-fat-test.jar $master_gluegen/dist/jogamp-fat-test.mf .
+ cd ../..
+
+ mv fat jogamp-fat
+ 7z a -r archive/jogamp-fat-all.7z jogamp-fat
+ mv jogamp-fat fat
+
+ cd $lthisdir
+}
+
function prom_promote_demos() {
local module=$1
shift
diff --git a/jenkins-builds/promote-latest-builds.sh b/jenkins-builds/promote-latest-builds.sh
index 519ef82..1a0db20 100755
--- a/jenkins-builds/promote-latest-builds.sh
+++ b/jenkins-builds/promote-latest-builds.sh
@@ -22,7 +22,8 @@ fi
version=autobuild
-sdir=`dirname $0`
+sdir_0=`dirname $0`
+sdir=`readlink -f $sdir_0`
thisdir=`pwd`
@@ -34,8 +35,11 @@ logfile=$thisdir/`basename $0 .sh`.log
archivedir=/srv/www/jogamp.org/deployment/archive/$branch
rootdir=/srv/www/jogamp.org/deployment/autobuilds/$branch
-os_and_archs_minus_one="linux-i586 linux-armv6 linux-armv6hf android-armv6 android-aarch64 macosx-universal windows-amd64 windows-i586 solaris-i586 solaris-amd64"
+os_and_archs_minus_master_android="linux-i586 linux-armv6 linux-armv6hf macosx-universal windows-amd64 windows-i586 solaris-i586 solaris-amd64"
+os_and_archs_android="android-armv6 android-aarch64"
masterpick="linux-amd64"
+os_and_archs_minus_one="$os_and_archs_minus_master_android $os_and_archs_android"
+os_and_archs_minus_android="$masterpick $os_and_archs_minus_master_android"
os_and_archs="$masterpick $os_and_archs_minus_one"
cd $rootdir
@@ -183,6 +187,11 @@ function promote-latest-builds() {
prom_promote_demos jocl-demos slave $jocldemosslave $dest
+ echo
+ echo FAT JAR
+ echo
+ prom_make_fatjar $dest
+
#########################################################
## Integrity Check, Cleanup, aggregation.properties
#########################################################