On Thu, Sep 15, 2011 at 12:40 AM, Garrett Holmstrom <ho...@physics.umn.edu> wrote: > On 2011-09-14 18:20, Nico Kadel-Garcia wrote: >> >> And unfortunately, it can be confusing as all get-out for building >> SRPM's for multiple releases. Subversion, for example, has different >> dependencies in "el5" than in "el6", or in "f14" or later, and working >> out the logic for selecting the right options for your OS is a bit of >> an adventure when unpredictable and non-major-release "%dist" settings >> are used. > > Thankfully, when you're building with mock or you're building natively on > nearly anything that isn't el < 6, you can use other macros that are > designed to solve precisely this problem. > > %if 0%{?el5} > # SL 5-specific dependency info > %endif
I use this myself! It's been handy, but some SRPM authors, especially 3rdparty ones, have used some very strange logic based on %dist.. I try to straighten it out, but it can be hard with low maintenance projects. If you want *weird* logic, go look in the Samba SRPM's from http://ftp.sernet.de/pub/samba/3.6/src/rpm/samba3-3.6.0-44.src.rpm. That scan's /etc/*-release files.....