f559e23bd4
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@2583 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
31 lines
909 B
Bash
Executable File
31 lines
909 B
Bash
Executable File
#!/bin/sh
|
|
|
|
OSNAME=$(uname)
|
|
VER=2.2
|
|
|
|
if [ "$OSNAME" = "AIX" ]
|
|
then
|
|
|
|
echo '.svn' > /tmp/xcat-excludes
|
|
tar -X /tmp/xcat-excludes -cf /opt/freeware/src/packages/SOURCES/xCAT-server-$VER.tar xCAT-server
|
|
gzip -f /opt/freeware/src/packages/SOURCES/xCAT-server-$VER.tar
|
|
cd ./xCAT-server
|
|
rm -f /opt/freeware/src/packages/SRPMS/xCAT-server-$VER*rpm /opt/freeware/src/packages/RPMS/ppc/xCAT-server-$VER*rpm
|
|
rpm -ba xCAT-server.spec
|
|
#rpm -Uvh /opt/freeware/src/packages/RPMS/ppc/xCAT-server-$VER*rpm
|
|
|
|
else
|
|
|
|
if [ -f /etc/redhat-release ]
|
|
then
|
|
pkg="redhat"
|
|
else
|
|
pkg="packages"
|
|
fi
|
|
|
|
tar --exclude .svn -czf /usr/src/$pkg/SOURCES/xCAT-server-$VER.tar.gz xCAT-server;
|
|
rm -f /usr/src/$pkg/SRPMS/xCAT-server-$VER*rpm /usr/src/$pkg/RPMS/noarch/xCAT-server-$VER*rpm
|
|
rpmbuild -ta /usr/src/$pkg/SOURCES/xCAT-server-$VER.tar.gz ;
|
|
#rpm -Uvh /usr/src/$pkg/RPMS/noarch/xCAT-server-$VER*rpm
|
|
fi
|