On Tue, 22 Oct 2002, Mike Chambers wrote:
>Date: Tue, 22 Oct 2002 22:10:21 -0500
>From: Mike Chambers <[EMAIL PROTECTED]>
>To: RedHat - Psyche <[EMAIL PROTECTED]>
>Content-Type: text/plain;
> charset="iso-8859-1"
>List-Id: Discussion of Red Hat Linux 8.0 (Psyche) <psyche-list.redhat.com>
>Subject: i386 package name
>
>Except for those packages that are built against multiple architectures, why
>do we even need the i386 in the name anyway?
Because it indicates the CPU instruction set that the package
will compatibly run on.
>Things like kernel, glibc and such I understand. But if packages are built
>to run on just about every machine, then why not just leave it off?
What benefit does that provide anyone with at all? It would
cause only confusion, since there is no way to distinguish
between different architectures. For example:
If you have a package which is currently i386.rpm, and you have a
package which is alpha.rpm, the i386 package will work on any
i386 or higher class machine. The alpha rpm will work on any
alpha hardware. By removing the architecture from the package
name you end up with:
foo-1.0-1.i386.rpm becomes foo-1.0-1.rpm
foo-1.0-1.alpha.rpm becomes foo-1.0-1.rpm
foo-1.0-1.sparc.rpm becomes foo-1.0-1.rpm
Which one of the two foo-1.0-1.rpm packages do you install on
your Pentium IV? If you get the alpha one, of course it wont
work. You wont have the foggiest idea why, because the filename
doesn't let you know anything about what processor it was made
for.
The %{arch} in the filename is for *your* convenience only. RPM
doesn't care what the files are named as it gets the information
from the header inside the file itself. You can rename the files
to klasdfjlsjdfaklsdfj.rpm if you want and then install it. RPM
doesn't mind at all. It will install properly as if it had been
named the original name, and there will be no differences on your
system. Querying RPM for klasdfjlsjdfaklsdfj will result in it
not being found since the package name isn't taken from the file
name, but from the RPM header inside the file.
The arch field in the filename is thus required to differentiate
packages between different CPU instruction sets, and that
includes both different CPU architectures, as well as different
generations of CPU in a single CPU architecture.
Hope this helps.
TTYL
--
Mike A. Harris ftp://people.redhat.com/mharris
OS Systems Engineer
XFree86 maintainer
Red Hat Inc.