File arch-symbols of Package kernel-docs
xxxxxxxxxx
1
#!/bin/bash
2
3
#############################################################################
4
# Copyright (c) 2003-2005,2009 Novell, Inc.
5
# All Rights Reserved.
6
#
7
# This program is free software; you can redistribute it and/or
8
# modify it under the terms of version 2 of the GNU General Public License as
9
# published by the Free Software Foundation.
10
#
11
# This program is distributed in the hope that it will be useful,
12
# but WITHOUT ANY WARRANTY; without even the implied warranty of
13
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
# GNU General Public License for more details.
15
#
16
# You should have received a copy of the GNU General Public License
17
# along with this program; if not, contact Novell, Inc.
18
#
19
# To contact Novell about this file by physical or electronic mail,
20
# you may find current contact information at www.novell.com
21
#############################################################################
22
23
# With --list, list all known architectures, otherwise print the generic
24
# name for this architecture (or the one specified on command line).
25
26
if [ "$1" = "--list" ]; then
27
# List all known architectures
28
echo i386 mips{,64} sparc{,64} ppc{,64,64le} s390{,x} ia64 x86_64 alpha parisc armv6hl armv7hl arm64 riscv64
29
exit 0
30
fi
31
32
if [ -n "$1" ]; then
33
ARCH="$1"
34
else
35
ARCH="`arch`"
36
fi
37
case "$ARCH" in
38
# from rpm --eval '%ix86'
39
i?86 | pentium3 | pentium4 | athlon | geode)
40
echo i386
41
;;
42
aarch64)
43
echo arm64
44
;;
45
*)
46
echo "$ARCH"
47
;;
48
esac
49