From e5fea0a0a27269ff7e45fa257553be336ab96a44 Mon Sep 17 00:00:00 2001 From: soochoi Date: Wed, 7 Feb 2007 19:44:54 +0000 Subject: [PATCH] CASA-auth-token-java: check in build config file for autobuild --- .../server-java/build_config/linux/autobuild | 59 ++++++++++++++++++ .../build_config/linux/oes-autobuild | 60 +++++++++++++++++++ 2 files changed, 119 insertions(+) create mode 100755 CASA-auth-token/server-java/build_config/linux/autobuild create mode 100755 CASA-auth-token/server-java/build_config/linux/oes-autobuild diff --git a/CASA-auth-token/server-java/build_config/linux/autobuild b/CASA-auth-token/server-java/build_config/linux/autobuild new file mode 100755 index 00000000..db7b860c --- /dev/null +++ b/CASA-auth-token/server-java/build_config/linux/autobuild @@ -0,0 +1,59 @@ +#!/bin/bash + +## creating ENV varaibles +SOURCE_DIR=`pwd` +export BUILD_ROOT=$SOURCE_DIR/../autobuild/BUILD +PACKAGE=CASA_auth_token_svc +VERSION=1.7.$1 +TEMP_DIR=$SOURCE_DIR/SOURCES +RPMS_DIR=$BUILD_ROOT/usr/src/packages + +##creating tar.gz +rm -rf ../bld_tst +mkdir ../bld_tst +mkdir ../bld_tst/CASA_auth_token_svc-1.7.$1 +cp -R ./* ../bld_tst/CASA_auth_token_svc-1.7.$1 + +cd ../bld_tst/CASA_auth_token_svc-1.7.$1 +sed -i "s/\(AM_INIT_AUTOMAKE.*\))/\AM_INIT_AUTOMAKE\(CASA_auth_token_svc, 1\.7\.$1\)/" ./configure.in + +find . -name "*.lux" | xargs dos2unix > /dev/null 2>&1 +find . -name "mk*" | xargs dos2unix > /dev/null 2>&1 +find . -name "mk*" | xargs chmod +x > /dev/null 2>&1 +find . -name "Make*" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.c" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cs" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cpp" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.h" | xargs dos2unix > /dev/null 2>&1 +find . -name "link*" | xargs dos2unix > /dev/null 2>&1 +find . -name ".svn" | xargs rm -rf > /dev/null 2>&1 +find . -name "*.sh" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.sh" | xargs chmod +x > /dev/null 2>&1 +find . -name "*ver.txt" | xargs dos2unix > /dev/null 2>&1 +find . -name "*build.txt" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.mak" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cl" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.spec" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.patch" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.changes" | xargs dos2unix > /dev/null 2>&1 + +cd .. +tar cjf ../CASA_auth_token_svc-1.7.$1.tar.bz2 ./CASA_auth_token_svc-1.7.$1 + +#creating spec file +cd $SOURCE_DIR +mkdir --parents $PRODUCTS_DIR $TEMP_DIR +cp ../CASA_auth_token_svc-1.7.$1.tar.bz2 $TEMP_DIR +cp $SOURCE_DIR/package/linux/CASA_auth_token_svc.spec.in $TEMP_DIR/CASA_auth_token_svc.spec +sed -i "s/@VERSION@/1.7.$1/" $TEMP_DIR/CASA_auth_token_svc.spec +sed -i "s/@PACKAGE@/CASA_auth_token_svc/" $TEMP_DIR/CASA_auth_token_svc.spec +cp $SOURCE_DIR/package/linux/CASA_auth_token_svc.changes $TEMP_DIR +cd $TEMP_DIR + +##call autobuild +. /opt/SuSE/bin/.profile +sudo build --clean + +##copy rpms to temp directoy +cp -rf $RPMS_DIR/RPMS $TEMP_DIR +cp -rf $RPMS_DIR/SRPMS $TEMP_DIR diff --git a/CASA-auth-token/server-java/build_config/linux/oes-autobuild b/CASA-auth-token/server-java/build_config/linux/oes-autobuild new file mode 100755 index 00000000..1b35ae9d --- /dev/null +++ b/CASA-auth-token/server-java/build_config/linux/oes-autobuild @@ -0,0 +1,60 @@ +#!/bin/bash + +## creating ENV varaibles +SOURCE_DIR=`pwd` +export BUILD_ROOT=$SOURCE_DIR/../autobuild/BUILD +PACKAGE=CASA_auth_token_svc +VERSION=1.7.$1 +TEMP_DIR=$SOURCE_DIR/SOURCES +RPMS_DIR=$BUILD_ROOT/usr/src/packages + +##creating tar.gz +rm -rf ../bld_tst +mkdir ../bld_tst +mkdir ../bld_tst/CASA_auth_token_svc-1.7.$1 +cp -R ./* ../bld_tst/CASA_auth_token_svc-1.7.$1 + +cd ../bld_tst/CASA_auth_token_svc-1.7.$1 +sed -i "s/\(AM_INIT_AUTOMAKE.*\))/\AM_INIT_AUTOMAKE\(CASA_auth_token_svc, 1\.7\.$1\)/" ./configure.in + +find . -name "*.lux" | xargs dos2unix > /dev/null 2>&1 +find . -name "mk*" | xargs dos2unix > /dev/null 2>&1 +find . -name "mk*" | xargs chmod +x > /dev/null 2>&1 +find . -name "Make*" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.c" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cs" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cpp" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.h" | xargs dos2unix > /dev/null 2>&1 +find . -name "link*" | xargs dos2unix > /dev/null 2>&1 +find . -name ".svn" | xargs rm -rf > /dev/null 2>&1 +find . -name "*.sh" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.sh" | xargs chmod +x > /dev/null 2>&1 +find . -name "*ver.txt" | xargs dos2unix > /dev/null 2>&1 +find . -name "*build.txt" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.mak" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.cl" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.spec" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.patch" | xargs dos2unix > /dev/null 2>&1 +find . -name "*.changes" | xargs dos2unix > /dev/null 2>&1 + +cd .. +tar cjf ../CASA_auth_token_svc-1.7.$1.tar.bz2 ./CASA_auth_token_svc-1.7.$1 + +#creating spec file +cd $SOURCE_DIR +mkdir --parents $PRODUCTS_DIR $TEMP_DIR +cp ../CASA_auth_token_svc-1.7.$1.tar.bz2 $TEMP_DIR +cp $SOURCE_DIR/package/linux/CASA_auth_token_svc_4zen.spec.in $TEMP_DIR/CASA_auth_token_svc_4zen.spec +sed -i "s/@VERSION@/1.7.$1/" $TEMP_DIR/CASA_auth_token_svc_4zen.spec +sed -i "s/@PACKAGE@/CASA_auth_token_svc/" $TEMP_DIR/CASA_auth_token_svc_4zen.spec +cp $SOURCE_DIR/package/linux/CASA_auth_token_svc.changes $TEMP_DIR +cd $TEMP_DIR + +##call autobuild +. /opt/SuSE/bin/.profile +echo $ID +sudo build --clean --prefer-rpms=$ID + +##copy rpms to temp directoy +cp -rf $RPMS_DIR/RPMS $TEMP_DIR +cp -rf $RPMS_DIR/SRPMS $TEMP_DIR