for defect 3139537;

fixed the defect to handle the relative path related with "../add-on/statelite/rc.statelite".

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@8492 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
mxi1 2010-12-21 03:22:09 +00:00
parent 781417d460
commit 9f6781f316

View File

@ -594,12 +594,13 @@ mkpath "$rootimg_dir/.statelite"; # create place for NFS mounts.
# this script will get the directories.
# TODO: the file is re-copied in liteimg.pm
unless (-f "../add-on/statelite/rc.statelite") {
print "Can't find ../add-on/statelite/rc.statelite!\n";
my $cwd = $FindBin::Bin;
unless (-f "$cwd/../add-on/statelite/rc.statelite") {
print "Can't find $cwd/../add-on/statelite/rc.statelite!\n";
exit 1;
}
system("cp ../add-on/statelite/rc.statelite $rootimg_dir/etc/init.d/statelite");
system("cp $cwd/../add-on/statelite/rc.statelite $rootimg_dir/etc/init.d/statelite");
# also need to add this file:
# may have already been made into a symbolic link, if so ignore it