summaryrefslogtreecommitdiffstats
path: root/scripts/makepkg.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/makepkg.sh.in')
-rw-r--r--scripts/makepkg.sh.in7
1 files changed, 4 insertions, 3 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 929f43f9..f58e2742 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -385,10 +385,11 @@ handledeps() {
fi
# we might need the new system environment
- # set -e can cause problems during sourcing profile scripts
- set +e
+ # avoid triggering the ERR trap
+ local restoretrap=$(trap -p ERR)
+ trap - ERR
source /etc/profile &>/dev/null
- set -e
+ eval $restoretrap
return $R_DEPS_SATISFIED
}