Use uname -m instead of uname -i

-i (and -p) just say "unknown", since Fedora 38:
https://bugzilla.redhat.com/show_bug.cgi?id=2203350
-m still seems to do the right thing.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
Adam Williamson 2023-08-17 10:02:13 -07:00
parent ec1bac1bd2
commit 78d9a63f8b
2 changed files with 3 additions and 3 deletions

View File

@ -35,7 +35,7 @@ REQUIRES="${REQUIRES:-kernel-debuginfo}"
__have_kernel_debuginfo () { __have_kernel_debuginfo () {
local RELEASE ARCH TEMPDIR local RELEASE ARCH TEMPDIR
rlRun "RELEASE=$(uname -r)" rlRun "RELEASE=$(uname -r)"
rlRun "ARCH=$(uname -i)" rlRun "ARCH=$(uname -m)"
if ! rpm -q kernel-debuginfo-$RELEASE &>/dev/null; then if ! rpm -q kernel-debuginfo-$RELEASE &>/dev/null; then
rlLogInfo 'kernel-debuginfo not present, trying to install it' rlLogInfo 'kernel-debuginfo not present, trying to install it'
rlRun "TEMPDIR=$(mktemp -d -p $HOME)" # $HOME to avoid "small" tmpfs rlRun "TEMPDIR=$(mktemp -d -p $HOME)" # $HOME to avoid "small" tmpfs

View File

@ -111,7 +111,7 @@ rlJournalStart
./popcnt > a ./popcnt > a
rlRun "$ADDR2LINE -e popcnt $(cat a) > r" rlRun "$ADDR2LINE -e popcnt $(cat a) > r"
# We know that main is at line 4. But on PPC we get ??:0... # We know that main is at line 4. But on PPC we get ??:0...
if test ! $(uname -i) = "ppc64"; then if test ! $(uname -m) = "ppc64"; then
rlAssertGrep "popcnt.c:4" r rlAssertGrep "popcnt.c:4" r
fi fi
rm -vf [ra] rm -vf [ra]
@ -182,7 +182,7 @@ fi
rlAssertGrep "__libc_start_main@GLIBC" u rlAssertGrep "__libc_start_main@GLIBC" u
# Try -P --size-sort. # Try -P --size-sort.
rlRun "$NM -P --size-sort localplt > p" rlRun "$NM -P --size-sort localplt > p"
if test $(uname -i) = "ppc64" -a $(rlGetDistroRelease) -gt 5; then if test $(uname -m) = "ppc64" -a $(rlGetDistroRelease) -gt 5; then
rlAssertGrep "main D" p rlAssertGrep "main D" p
else else
rlAssertGrep "main T" p rlAssertGrep "main T" p