From 1af0fb4bf3c0c7a3210fe36c68bae7ae0c3d8d9b Mon Sep 17 00:00:00 2001 From: bp-sawyers Date: Wed, 28 Jan 2009 20:26:03 +0000 Subject: [PATCH] Fixed modifyUtils and makeperlxcatrpm to work on AIX git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@2661 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- makeperlxcatrpm | 4 ++-- perl-xCAT/modifyUtils | 9 ++++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/makeperlxcatrpm b/makeperlxcatrpm index 2e5e0b4f6..933ad77bf 100755 --- a/makeperlxcatrpm +++ b/makeperlxcatrpm @@ -17,10 +17,10 @@ then #rpm -ba perl-xCAT.spec source=/opt/freeware/src/packages - rm -f $source/SRPMS/perl-xCAT*rpm $source/RPMS/ppc/perl-xCAT*rpm echo '.svn' > /tmp/xcat-excludes - tar -X /tmp/xcat-excludes -cf $source/perl-xCAT-$VER.tar perl-xCAT + tar -X /tmp/xcat-excludes -cf $source/SOURCES/perl-xCAT-$VER.tar perl-xCAT gzip -f $source/SOURCES/perl-xCAT-$VER.tar + rm -f $source/SRPMS/perl-xCAT*rpm $source/RPMS/ppc/perl-xCAT*rpm rpm -ba perl-xCAT/perl-xCAT.spec #rpm -ta $source/SOURCES/perl-xCAT-$VER.tar.gz else diff --git a/perl-xCAT/modifyUtils b/perl-xCAT/modifyUtils index bd94e8764..0740a5842 100755 --- a/perl-xCAT/modifyUtils +++ b/perl-xCAT/modifyUtils @@ -18,4 +18,11 @@ if [ $? -eq 0 ] fi BUILDDATE=`date` #echo ". '(${SVNREF}built $BUILDDATE)'" -sed -i -e s/#XCATVERSIONSUBHERE/". '$VER'"/ -e s/#XCATSVNBUILDSUBHERE/". ' (${SVNREF}built $BUILDDATE)'"/ xCAT/Utils.pm + +if [ "$(uname)" = "AIX" ] +then + sed -e s/"#XCATVERSIONSUBHERE"/". '$VER'"/ -e s/"#XCATSVNBUILDSUBHERE"/". ' (${SVNREF}built $BUILDDATE)'"/ xCAT/Utils.pm >xCAT/Utils.pm.new + mv xCAT/Utils.pm.new xCAT/Utils.pm +else + sed -i -e s/"#XCATVERSIONSUBHERE"/". '$VER'"/ -e s/"#XCATSVNBUILDSUBHERE"/". ' (${SVNREF}built $BUILDDATE)'"/ xCAT/Utils.pm +fi \ No newline at end of file