RPM Community Forums

Mailing List Message of <rpm-users>

Re: RPM5 On Solaris

From: Jeff Johnson <n3npq@mac.com>
Date: Sun 02 Nov 2008 - 04:43:00 CET
Message-id: <FF329479-80E1-4F76-926B-899A3AC0772C@mac.com>

On Nov 1, 2008, at 11:32 PM, Rob See wrote:

> Jeff,
>>>
>>
>> OK.
>>
>> The first thing is to verify what rpm thinks your platform is,  
>> "i86pc" is atypical.
>>
>> rpm --showrc will show what rpm thinks your platform is.
>
> ARCHITECTURE AND OS:
> build arch            : i86pc
> compatible build archs: i86pc
> build os              : sunos
> compatible build os's : sunos
> install arch          : i86pc
> install os            : sunos
> compatible archs      : i86pc
> compatible os's       : SunOS
>
> uname -ra returns
> SunOS build 5.11 snv_98 i86pc i386 i86pc Solaris
>

OK, you are setting arch from uname(2).

> Putting i386-pc-solaris2.11 into /etc/rpm/platform allows me to use  
> yum to install noarch packages.
>
>
> looks like yum/archwork.py is actually where yum defines  
> compatibility. I'll have to define an i86pc entry in here (or  
> recompile all of my already compiled packages)
>

I'd suggest using "i386" instead of "i86pc", there's nothing  
particularly
special about what uname(2) returns.

Try
	echo "i386-sun-sunos" > /etc/rpm/platform
and verify that indeed, that changes the platform using --showrc.

But adding "i86pc" to yum & rpm tables will likely work as well.

To verify added correctly to rpm, you should be able to
add a ".i86pc" suffix to package queries. Assuming a "foo" pkg
is installed, then
	rpm -q foo.i86pc
should succeed.

The table used by rpm is in either lib/rpmns.c or rpmdb/rpmns.c,
I forget which was used in rpm-5.1.4.

The current location is rpmdb/rpmns.c:

static const char *rpmnsArches[] = {
     "i386", "i486", "i586", "i686", "athlon", "pentium3", "pentium4",
     "x86_64", "amd64", "ia32e",
     "alpha", "alphaev5", "alphaev56", "alphapca56", "alphaev6",  
"alphaev67",
     "sparc", "sun4", "sun4m", "sun4c", "sun4d", "sparcv8",
     "sparcv9", "sparcv9b", "sparcv9v", "sparcv9v2",
     "sparc64", "sun4u", "sparc64v",
     "mips", "mipsel", "IP",
     "ppc", "ppciseries", "ppcpseries",
     "ppc64", "ppc64iseries", "ppc64pseries",
     "m68k",
     "rs6000",
     "ia64",
     "armv3l", "armv4b", "armv4l",
     "armv5teb", "armv5tel", "armv5tejl",
     "armv6l",
     "s390", "i370", "s390x",
     "sh", "sh3", "sh4", "sh4a", "xtensa",
     "noarch", "fat",
     NULL,
};

hth

73 de Jeff
Received on Sun Nov 2 04:43:06 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.