mirror of
https://github.com/moparisthebest/pacman
synced 2025-02-28 17:31:52 -05:00
Add support for arch='any'
Signed-off-by: Roman Kyrylych <roman@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
parent
0ea43089e1
commit
4a5e7b6bd1
@ -129,6 +129,9 @@ for file in $(find "$rootdir"/* -name "$BUILDSCRIPT"); do
|
|||||||
unset pkgname pkgver pkgrel options
|
unset pkgname pkgver pkgrel options
|
||||||
|
|
||||||
source $file || die "$(gettext "failed to parse parse %s")" $file
|
source $file || die "$(gettext "failed to parse parse %s")" $file
|
||||||
|
if [ "$arch" = 'any' ]; then
|
||||||
|
CARCH='any'
|
||||||
|
fi
|
||||||
if [ "$pkgdir" != "" ]; then
|
if [ "$pkgdir" != "" ]; then
|
||||||
pkgfile="$pkgdir/$pkgname-$pkgver-$pkgrel-$CARCH.$PKGEXT"
|
pkgfile="$pkgdir/$pkgname-$pkgver-$pkgrel-$CARCH.$PKGEXT"
|
||||||
else
|
else
|
||||||
|
@ -1300,6 +1300,10 @@ if [ $(echo "$pkgrel" | grep '-') ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$arch" = 'any' ]; then
|
||||||
|
CARCH='any'
|
||||||
|
fi
|
||||||
|
|
||||||
if ! in_array $CARCH ${arch[@]}; then
|
if ! in_array $CARCH ${arch[@]}; then
|
||||||
if [ "$IGNOREARCH" = "0" ]; then
|
if [ "$IGNOREARCH" = "0" ]; then
|
||||||
error "$(gettext "%s is not available for the '%s' architecture.")" "$pkgname" "$CARCH"
|
error "$(gettext "%s is not available for the '%s' architecture.")" "$pkgname" "$CARCH"
|
||||||
|
@ -127,6 +127,9 @@ if [ "$action" = "upd" ]; then # INSERT / UPDATE
|
|||||||
unset pkgname pkgver pkgrel options
|
unset pkgname pkgver pkgrel options
|
||||||
|
|
||||||
source $option || die "$(gettext "failed to parse %s")" $option
|
source $option || die "$(gettext "failed to parse %s")" $option
|
||||||
|
if [ "$arch" = 'any' ]; then
|
||||||
|
CARCH='any'
|
||||||
|
fi
|
||||||
pkgfile="$pkgdir/$pkgname-$pkgver-$pkgrel-$CARCH.$PKGEXT"
|
pkgfile="$pkgdir/$pkgname-$pkgver-$pkgrel-$CARCH.$PKGEXT"
|
||||||
|
|
||||||
if [ ! -f "$pkgfile" ]; then
|
if [ ! -f "$pkgfile" ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user