RPM Community Forums

Mailing List Message of <rpm-devel>

Re: Question regarding "rpm -qplv" on SRPM

From: Jeff Johnson <n3npq@mac.com>
Date: Tue 18 Dec 2007 - 01:45:53 CET
Message-Id: <22DD9834-732C-44F7-A43E-F19D010DD464@mac.com>

On Dec 17, 2007, at 2:23 PM, Ralf S. Engelschall wrote:

> This is RPM 4 on a SRPM:
>
> | $ /usr/opkg/bin/openpkg rpm -qplv /v/openpkg/SRC/CURRENT/CORE/ 
> make-3.81-20071211.src.rpm
> | -rwxrwxr-- 1 rse           openpkg-membe  1564560 Apr  1  2006  
> make-3.81.tar.gz
> | -rw-r--r-- 1 rse           rse                896 Apr  1  2006  
> make.patch
> | -rw-r--r-- 1 rse           rse               3399 Dec 11 14:06  
> make.spec
>
> This is RPM 5 on the same SRPM:
>
> | $ /openpkg/bin/openpkg rpm -qplv /v/openpkg/SRC/CURRENT/CORE/ 
> make-3.81-20071211.src.rpm
> | -rwxrwxr-- 1 rse           openpkg-membe  1564560 Apr  1  2006 / 
> d2/u/rse/prj/openpkg-2008/src/pkg.dst/%{name}/make-3.81.tar.gz
> | -rw-r--r-- 1 rse           rse                896 Apr  1  2006 / 
> d2/u/rse/prj/openpkg-2008/src/pkg.dst/%{name}/make.patch
> | -rw-r--r-- 1 rse           rse               3399 Dec 11 14:06 / 
> d2/u/rse/prj/openpkg-2008/src/pkg.src/%{name}/make.spec
>
> Seems like RPM 5 now shows the path into which the file later would be
> installed. Nice idea, but what is very confusing and not so nice is
> that the contained %{name} is not expanded. I comes from defintions  
> for
> %_sourcedir and %_specdir in ~/.openpkg/rpmmacros which contain % 
> {name}.
>

Yah, I pushed *.src.rpm onto a common code path with binary *.rpm's
installs through rpmtsRun() (in July iirc) to start to phase out the  
like 3
goofy srpm code paths that always burn me when I focus on mainline
installation code paths.

Now if I break something, _EVERYTHING_ breaks, not some
weird random corner case using *.src.rpm's that isn't noticed until
after I release.

The full path for srpm's wasn't intentional, entirely accidental,  
populating a
rpmfi structure from a srpm.

> I think we need another level of expansion somewhere...
>

The expansion is likely there in lib/rpmfi.c, the per-package macro  
context
that defines %name is likely what is missing. Undefined expansions  
are returned
literally.

todo++. Add to TODO please (or I will, I too have %{name} in my  
rpmbuild configgery)

73 de Jeff
Received on Tue Dec 18 01:46:05 2007
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.