On Tue, 18 Nov 2003, Eli Carter wrote:
All,
Is there a way to get rpmbuild to display the BuildPreReqs given a spec file, but without initiating a build?
And then, what about PreReqs and Requires?
Not really. To some extent you can get PreReqs and Requires out of a spec with 'rpm -q --specfile --requires foo.spec' but that (obviously) doesn't include automatically generated dependencies and for build dependencies I don't think there's a way to get that out of a spec file.
That said, "mach" does exactly that by parsing the spec manually, if you wish you could extract the relevant code from there... http://thomas.apestaart.org/projects/mach/
Well, for what I'm doing, I can live with
grep -i -e '^[[:space:]]*BuildPreReq' $SRCDIR/$package/$package.spec | sed 's/.*://' | sed 's/,/ /g
It just gets false positives when there's a %ifdef around a Buildprereq.
Thanks for the pointer to "mach"... I'll have to look into that another time.
Eli --------------------. "If it ain't broke now, Eli Carter \ it will be soon." -- crypto-gram eli.carter(a)inet.com `-------------------------------------------------
_______________________________________________ Rpm-list mailing list Rpm-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/rpm-list