summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElan Ruusamäe2005-08-28 20:06:22 (GMT)
committercvs2git2012-06-24 12:13:13 (GMT)
commitf0854606a3ab806c7a4a687034b8544508c5c5ad (patch)
tree51cfb700855f70b29fd604d407e8471c83b4fd92
parent674f3ae7ae08ae95380ca3ddfb7948194f3db760 (diff)
downloadfonts-TTF-microsoft-f0854606a3ab806c7a4a687034b8544508c5c5ad.zip
fonts-TTF-microsoft-f0854606a3ab806c7a4a687034b8544508c5c5ad.tar.gz
- add @COPYSOURCES@ for adobe install
Changed files: license-installer.sh -> 1.5
-rw-r--r--license-installer.sh33
1 files changed, 32 insertions, 1 deletions
diff --git a/license-installer.sh b/license-installer.sh
index 4604162..0d3933c 100644
--- a/license-installer.sh
+++ b/license-installer.sh
@@ -12,6 +12,14 @@ if [ "$1" = "--with" -a "$2" = "license_agreement" ]; then
BACKUP=1
mv -f $SPECDIR/@BASE_NAME@.spec $SPECDIR/@BASE_NAME@.spec.prev
fi
+ if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
+ for i in @COPYSOURCES@; do
+ if [ -f $SOURCEDIR/$i ]; then
+ mv -f $SOURCEDIR/$i $SOURCEDIR/$i.prev
+ BACKUP=1
+ fi
+ done
+ fi
if echo "$3" | grep '\.src\.rpm$' >/dev/null; then
( cd $SRPMDIR
if echo "$3" | grep '://' >/dev/null; then
@@ -20,10 +28,25 @@ if [ "$1" = "--with" -a "$2" = "license_agreement" ]; then
cp -f "$3" .
fi
rpm2cpio `basename "$3"` | ( cd $TMPDIR; cpio -i @BASE_NAME@.spec )
- )
+ if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
+ for i in @COPYSOURCES@; do
+ rpm2cpio $i | ( cd $TMPDIR; cpio -i $i )
+ done
+ fi
+ )
cp -i $TMPDIR/@BASE_NAME@.spec $SPECDIR/@BASE_NAME@.spec || exit 1
+ if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
+ for i in @COPYSOURCES@; do
+ cp -i $TMPDIR/$i $SOURCEDIR/$i || exit 1
+ done
+ fi
else
cp -i "$3" $SPECDIR || exit 1
+ if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
+ for i in @COPYSOURCES@; do
+ cp -i @DATADIR@/$i $SOURCEDIR/$i || exit 1
+ done
+ fi
fi
( cd $SPECDIR
/usr/bin/builder -nm -nc -ncs --with license_agreement --opts --target=@TARGET_CPU@ @BASE_NAME@.spec
@@ -36,6 +59,14 @@ if [ "$1" = "--with" -a "$2" = "license_agreement" ]; then
if [ -f $SPECDIR/@BASE_NAME@.spec.prev ]; then
mv -f $SPECDIR/@BASE_NAME@.spec.prev $SPECDIR/@BASE_NAME@.spec
fi
+ if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
+ for i in @COPYSOURCES@; do
+ if [ -f $SOURCEDIR/$i ]; then
+ mv -f $SOURCEDIR/$i.prev $SOURCEDIR/$i
+ BACKUP=1
+ fi
+ done
+ fi
fi
else
if [ "@LICENSE@" != '@'LICENSE'@' ]; then