spm and buildreqs

Ignacio Vazquez-Abrams ivazquez at ivazquez.net
Tue May 24 18:39:48 UTC 2005


On Thu, 2005-05-12 at 01:00 -0400, seth vidal wrote:
> Going through this a few more times as I work on some bits inside the
> buildsystem.
> 
> We're given an srpm - we don't know where it was made, on what arch,
> nothing - so we cannot trust the buildreqs it provides.
> 
> If we're inside the chroot and on the arch we want to build on then
> running:
>  rpm -Uvh /path/to/our/srpm
>  rpmbuild -bs --nodeps /path/to/the/generated/spec
>  
> should result in a srpm for us that will have valid build reqs.
> So that if we grab the requires from that srpm we'll have a pretty good
> idea of what we'll need to install to build the package.
> 
> is that correct/accurate/etc?

You can actually glean that info from the spec without having to build a
SRPM:

rpmbuild foo.spec 2>&1 | awk 'BEGIN { FS = "[ \t]" } $1 !~ /^error:$/ {print $2}'

-- 
Ignacio Vazquez-Abrams <ivazquez at ivazquez.net>
http://fedora.ivazquez.net/

gpg --keyserver hkp://subkeys.pgp.net --recv-key 38028b72
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.fedoraproject.org/pipermail/buildsys/attachments/20050524/48d61c05/attachment.bin 


More information about the buildsys mailing list