On my Enterprise Linux installation, the default "macrofiles" setup is
/usr/lib/rpm/macros:/usr/lib/rpm/%{_target}/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.prelink:/etc/rpm/macros.solve:/etc/rpm/macros.up2date:/etc/rpm/macros:/etc/rpm/%{_target}/macros:~/.rpmmacros
I thought this meant that if I did
rpmbuild --target <something>
then /usr/lib/rpm/<something>/macros and /etc/rpm/<something>/macros
would be loaded (among other things), [ ... ]
You can always use --define.
Replace %{_target} on your macrofiles setup for, say: %{customtag},
then:
rpmbuild --define 'customtag XXXX'
I just tested this, and noticed something slightly odd:
I now have an rpmrc on the current directory containing
macrofiles:
/usr/lib/rpm/macros:/usr/lib/rpm/%{mytarget}/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.prelink:/etc/rpm/macros.solve:/etc/rpm/macros.up2date:/etc/rpm/macros:/etc/rpm/%{mytarget}/macros:~/.rpmmacros
The macrofile I want loaded is /etc/rpm/i386-mingw32/macros.
Now if I do just
rpmbuild --rcfile '/usr/lib/rpm/rpmrc:./rpmrc' --define 'mytarget i386-mingw32' -bb tst.spec
this is indeed correctly loaded, but if I change the command to
rpmbuild --rcfile '/usr/lib/rpm/rpmrc:./rpmrc' --define 'mytarget i386-mingw32' --target i386-mingw32
-bb tst.spec
it is not.
Help, anyone?
- Toralf
_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list