mirror of
https://github.com/moparisthebest/pacman
synced 2024-12-22 15:58:50 -05:00
* Fix bug where 'makepkg -L' doesn't stop on build failure.
Andrew Fyfe <andrew@neptune-one.net> * Add testing to etc/pacman.d/.cvsignore * Fix scriptlet001.py test to work during 'make check'.
This commit is contained in:
parent
a07b490344
commit
58fe79eef6
@ -6,3 +6,4 @@ extra
|
|||||||
mirrorlist
|
mirrorlist
|
||||||
release
|
release
|
||||||
unstable
|
unstable
|
||||||
|
testing
|
||||||
|
@ -8,7 +8,8 @@ p1.install['pre_install'] = "ls /etc";
|
|||||||
p1.install['post_install'] = "ls /etc";
|
p1.install['post_install'] = "ls /etc";
|
||||||
self.addpkg(p1)
|
self.addpkg(p1)
|
||||||
|
|
||||||
self.args = "-U %s" % p1.filename()
|
# --debug is necessary to check PACMAN_OUTPUT
|
||||||
|
self.args = "--debug -U %s" % p1.filename()
|
||||||
|
|
||||||
self.addrule("PACMAN_RETCODE=0")
|
self.addrule("PACMAN_RETCODE=0")
|
||||||
self.addrule("PACMAN_OUTPUT=pre_install")
|
self.addrule("PACMAN_OUTPUT=pre_install")
|
||||||
|
@ -883,6 +883,7 @@ else
|
|||||||
echo $SHELLOPTS | grep errexit 2>&1 >/dev/null
|
echo $SHELLOPTS | grep errexit 2>&1 >/dev/null
|
||||||
set_e=$?
|
set_e=$?
|
||||||
|
|
||||||
|
ret=0
|
||||||
if [ "$LOGGING" = "1" ]; then
|
if [ "$LOGGING" = "1" ]; then
|
||||||
BUILDLOG="${startdir}/${pkgname}-${pkgver}-${pkgrel}-${CARCH}.log"
|
BUILDLOG="${startdir}/${pkgname}-${pkgver}-${pkgrel}-${CARCH}.log"
|
||||||
if [ -f "$BUILDLOG" ]; then
|
if [ -f "$BUILDLOG" ]; then
|
||||||
@ -899,24 +900,18 @@ else
|
|||||||
|
|
||||||
#use 'errexit' to bail on syntax error
|
#use 'errexit' to bail on syntax error
|
||||||
[ $set_e -eq 1 ] && set -e
|
[ $set_e -eq 1 ] && set -e
|
||||||
build 2>&1 | tee "$BUILDLOG"
|
build 2>&1 | tee "$BUILDLOG"; ret=${PIPESTATUS[0]}
|
||||||
[ $set_e -eq 1 ] && set +e
|
[ $set_e -eq 1 ] && set +e
|
||||||
|
|
||||||
if [ ${PIPESTATUS[0]} -gt 0 ]; then
|
|
||||||
error "Build Failed. Aborting..."
|
|
||||||
removedeps
|
|
||||||
exit 2
|
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
#use 'errexit' to bail on syntax error
|
#use 'errexit' to bail on syntax error
|
||||||
[ $set_e -eq 1 ] && set -e
|
[ $set_e -eq 1 ] && set -e
|
||||||
build 2>&1
|
build 2>&1 || ret=$?
|
||||||
[ $set_e -eq 1 ] && set +e
|
[ $set_e -eq 1 ] && set +e
|
||||||
if [ $? -gt 0 ]; then
|
fi
|
||||||
error "Build Failed. Aborting..."
|
if [ $ret -gt 0 ]; then
|
||||||
removedeps
|
error "Build Failed. Aborting..."
|
||||||
exit 2
|
removedeps
|
||||||
fi
|
exit 2
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user