package for Fedora and EPEL from one spec source?
Kevin Kofler
kevin.kofler at chello.at
Tue Feb 1 16:28:34 UTC 2011
Gerd v. Egidy wrote:
> I've seen code like "%if 0%{?rhel}" somewhere on the net, but that didn't
> work for me. I guess the %rhel-macro should be defined in
> /etc/rpm/macros.dist where I usually find stuff like %fedora but that
> doesn't exist on my Centos 5.
%{rhel} is defined in the EPEL build system. If you want to use it in local
builds, you have to use the EPEL mock configs (which also define this) or
define it yourself (but normally you're supposed to use mock for builds, not
rpmbuild directly).
Alternatively, you can use if !0%{?fedora} instead. Fedora always defines
%{fedora}.
Kevin Kofler
More information about the devel
mailing list