97110bca2b
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1926 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
43 lines
966 B
Bash
Executable File
43 lines
966 B
Bash
Executable File
#!/bin/sh
|
|
|
|
OSNAME=$(uname)
|
|
VER=2.1
|
|
|
|
if [ "$OSNAME" = "AIX" ]
|
|
then
|
|
cd `dirname $0`
|
|
echo '.svn' > /tmp/xcat-excludes
|
|
|
|
tar -X /tmp/xcat-excludes -cf /opt/freeware/src/packages/SOURCES/license.tar LICENSE.html
|
|
gzip -f /opt/freeware/src/packages/SOURCES/license.tar
|
|
|
|
cp xcat.conf /opt/freeware/src/packages/SOURCES
|
|
rm -f /opt/freeware/src/packages/SRPMS/xCATsn-$VER*rpm /opt/freeware/src/packages/RPMS/ppc/xCATsn-$VER*rpm
|
|
|
|
rpm -ba xCATsn.spec
|
|
|
|
# don't install
|
|
#rpm -Uvh /opt/freeware/src/packages/RPMS/ppc/xCATsn-$VER*rpm
|
|
cd -
|
|
|
|
else
|
|
|
|
if [ -f /etc/redhat-release ]
|
|
then
|
|
pkg="redhat"
|
|
else
|
|
pkg="packages"
|
|
fi
|
|
|
|
cd `dirname $0`
|
|
tar --exclude .svn -czf /usr/src/$pkg/SOURCES/license.tar.gz LICENSE.html
|
|
cp xcat.conf /usr/src/$pkg/SOURCES
|
|
rm -f /usr/src/$pkg/SRPMS/xCATsn-$VER*rpm /usr/src/$pkg/RPMS/*/xCATsn-$VER*rpm
|
|
if [ ! -z "$1" ]; then
|
|
rpmbuild -ba xCAT.spec --target $1
|
|
else
|
|
rpmbuild -ba xCAT.spec
|
|
fi
|
|
cd -
|
|
fi
|