X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=export.sh;h=c99ae22ba1fdaa99d3ec8eabbf095372712946bc;hb=7d048df41aea44c07ea6e1ab774c627053f39dfa;hp=b0fdddf982d89e22cfd429cfd9c832462d274611;hpb=632cc690ac07130a51a947ee0f0b2bfae10b6595;p=nikiroo-utils.git diff --git a/export.sh b/export.sh index b0fdddf..c99ae22 100755 --- a/export.sh +++ b/export.sh @@ -3,6 +3,8 @@ # Export script # # Version: +# - 1.1.1: use the new sjar command to make sources +# - 1.1.0: allow multiple targets # - 1.0.0: add a version comment cd "`dirname "$0"`" @@ -10,16 +12,19 @@ cd "`dirname "$0"`" if [ "$1" = "" ]; then echo "You need to specify where to export it" >&2 exit 1 -elif [ ! -d "$1/libs" ]; then - echo "The target export directory is not compatible" >&2 - exit 2 fi LIBNAME="`cat configure.sh | grep '^echo "NAME = ' | cut -d'"' -f2 | cut -d= -f2`" LIBNAME="`echo $LIBNAME`" make mrpropre -./configure.sh && make \ - && cp "$LIBNAME"-`cat VERSION`-sources.jar "$1"/libs/ \ - && cp "$LIBNAME".jar "$1"/libs/ +./configure.sh && make && make sjar +if [ $? = 0 ]; then + while [ "$1" != "" ]; do + mkdir -p "$1"/libs/ + cp "$LIBNAME"-`cat VERSION`-sources.jar "$1"/libs/ + cp "$LIBNAME".jar "$1"/libs/ + shift + done +fi