On Wed, Jun 07, 2006 at 07:57:10PM -0400, Oliver Schulze L. wrote: > it is posible to determine the version of RHEL in a rpm .spec file? > > I have to build an rpm and do different things if I'm n RHEL3, 4 or > Fedora Core. At build time? Then do something like: %define is_fedora %(test -f /etc/fedora-release && echo 1 || echo 0) %define distrorel %(rpm -qf --qf '%{version}' /etc/redhat-release) and then you can use something like: %if ! %is_fedora %if %distrorel == 3 # we're in RHEL3 %endif %endif etc... -- -- -- Jos Vos <jos@xxxxxx> -- X/OS Experts in Open Systems BV | Phone: +31 20 6938364 -- Amsterdam, The Netherlands | Fax: +31 20 6948204 _______________________________________________ Rpm-list mailing list Rpm-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/rpm-list