Split installation/removal parts in prepost-action scripts.

There are two scripts that can be used now:
	- prepost-inst: for pre/post actions at installation.
	- prepost-rm: for pre/post actions at removal.

--HG--
extra : convert_revision : 5e054758f549f5c81693b825795fbb36e2d5513a
This commit is contained in:
Juan RP
2009-02-03 17:32:51 +01:00
parent 388dd30b45
commit 6c252d43d4
8 changed files with 33 additions and 29 deletions

View File

@@ -125,10 +125,15 @@ _EOF
chmod 644 $metadir/*
rm -f $TMPFLIST $TMPFPROPS
if [ -f "$XBPS_TEMPLATESDIR/$pkgname.prepost-action" ]; then
cp -f $XBPS_TEMPLATESDIR/$pkgname.prepost-action \
$destdir/XBPS_PREPOST_ACTION
chmod +x $destdir/XBPS_PREPOST_ACTION
if [ -f "$XBPS_TEMPLATESDIR/$pkgname.prepost-inst" ]; then
cp -f $XBPS_TEMPLATESDIR/$pkgname.prepost-inst \
$destdir/XBPS_PREPOST_INSTALL
chmod +x $destdir/XBPS_PREPOST_INSTALL
fi
if [ -f "$XBPS_TEMPLATESDIR/$pkgname.prepost-rm" ]; then
cp -f $XBPS_TEMPLATESDIR/$pkgname.prepost-rm \
$metadir/prepost-rm
chmod +x $metadir/prepost-rm
fi
}