spm and buildreqs

Enrico Scholz enrico.scholz at informatik.tu-chemnitz.de
Thu May 12 05:40:16 UTC 2005


skvidal at phy.duke.edu (seth vidal) writes:

> 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.

To be correct, the used algorithm should be:

deps = ''
do {
   old-deps = deps
   rpm -Uvh --nodeps ....src.rpm
   rpmbuild -bs --nodeps --force ....spec <other-opts>*
   calculate-deps
   install deps
} while deps != old-deps


Else, wrong results will be produced for cases like

| BuildRequires: foo
| %macrofoo

whereas the macro is defined in /etc/rpm/macros.foo (shipped by package
'foo') and expands to

| BuildRequires: bar




Enrico
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 480 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-buildsys-list/attachments/20050512/fc3408d8/attachment.sig>


More information about the Fedora-buildsys-list mailing list