summaryrefslogtreecommitdiffstats
path: root/jenkins-builds/funcs_promotion.sh
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/funcs_promotion.sh
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/funcs_promotion.sh')
-rwxr-xr-xjenkins-builds/funcs_promotion.sh75
1 files changed, 74 insertions, 1 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