lint_pkgbuild/arch: always perform some checks
When using --ignorearch or options that imply it (e.g. --printsrcinfo), all checks of the arch array were skipped. Instead, perform all checks apart from confirming that the package can be built on that architecture. Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
faea473550
commit
bc7b8e2eb2
1 changed files with 5 additions and 7 deletions
|
@ -44,11 +44,13 @@ validate_arch() {
|
||||||
ret=1
|
ret=1
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
|
if (( ! IGNOREARCH )); then
|
||||||
if ! in_array "$CARCH" "${a[@]}"; then
|
if ! in_array "$CARCH" "${a[@]}"; then
|
||||||
error "$(gettext "%s is not available for the '%s' architecture.")" "$n" "$CARCH"
|
error "$(gettext "%s is not available for the '%s' architecture.")" "$n" "$CARCH"
|
||||||
ret=1
|
ret=1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
for a in "${arch[@]}"; do
|
for a in "${arch[@]}"; do
|
||||||
if [[ $a = *[![:alnum:]_]* ]]; then
|
if [[ $a = *[![:alnum:]_]* ]]; then
|
||||||
|
@ -68,10 +70,6 @@ validate_arch() {
|
||||||
lint_arch() {
|
lint_arch() {
|
||||||
local name list ret=0
|
local name list ret=0
|
||||||
|
|
||||||
if (( IGNOREARCH )); then
|
|
||||||
return 0;
|
|
||||||
fi
|
|
||||||
|
|
||||||
validate_arch "$pkgbase" "${arch[@]}"
|
validate_arch "$pkgbase" "${arch[@]}"
|
||||||
|
|
||||||
if (( ret == 0 )); then
|
if (( ret == 0 )); then
|
||||||
|
|
Loading…
Add table
Reference in a new issue