xbps-src: check_pkg_arch now exits with errcode 2.

This commit is contained in:
Juan RP 2015-03-19 10:26:19 +01:00
parent 0337b86f43
commit 95ca05e6e6
2 changed files with 3 additions and 3 deletions

View file

@ -1,7 +1,7 @@
# vim: set ts=4 sw=4 et:
check_pkg_arch() {
local cross="$1" err="$2" _arch f found
local cross="$1" _arch f found
if [ -n "$only_for_archs" ]; then
if [ -n "$cross" ]; then
@ -19,7 +19,7 @@ check_pkg_arch() {
done
if [ -z "$found" ]; then
msg_red "$pkgname: this package cannot be built for ${_arch}.\n"
exit ${err:=0}
exit 2
fi
fi
}

View file

@ -50,7 +50,7 @@ show_pkg_files() {
show_pkg_build_deps() {
local f x _pkgname _dep found
check_pkg_arch "$XBPS_CROSS_BUILD" 1
check_pkg_arch "$XBPS_CROSS_BUILD"
setup_pkg_depends
# build time deps
for f in ${host_build_depends} ${build_depends} ${run_depends}; do