%bcond macros in Fedora spec files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello all,

I was wondering if there were any guidelines about the use of %bcond_*
macros in Fedora spec files?  I checked the wiki, and there are three
pages that contain the string bcond in their text, but those are only in
passing.

Of course, the %bcond_* macros can give people flexibility in the
features of the package should they need to use the src.rpm.  (For
example, needing to back-port a package to FC-4, say.)  However, fwiw,
my general observation of Fedora has been a tendency to include as many
features as possible in packages.  (Some people will probably think that
this is a bad thing.  Personally, I like this trend in general.  But
that's a discussion for an entirely different thread...)  The main
reason that I could see these macros being used in Fedora would be to
allow people to exclude a feature that they weren't able to build with.

For example, in some distant future, a package gets released for FC-8,
and someone wants to backport that package to their FC-4 machine.
However, the FC-8 package requires some devel packages that aren't
available for FC-4.  A %bcond_* macro would let that person just drop
that feature from that package that they built using --without flags
instead of going in, editing the spec file, and re-creating a new
package.  In this sense, %bcond_* macros could be a type of courtesy for
legacy systems.

On the other hand, however, the %bcond_* macros do lead to a certain
lack of reproduceability in RPM builds.  Of course, the exact command
"rpmbuild --rebuild blah.src.rpm" will always produce the same package,
even with %bcond_* macros.  However, the general set of rebuild commands
for blah.src.rpm would now include "rpmbuild --rebuild blah.src.rpm" and
"rpmbuild --rebuild --with foo blah.src.rpm" which would probably *not*
be the same package.  So that we could conceivably end up having to ask
people who have problems with such a package, "Did you build with the
flag '--with foo'?"

So is there some kind of policy (or more appropriately a guideline)
regarding this kind of macro in spec files?  Should even be there be
such a guideline or not?  (That is, do we even care?)

-- 
John Guthrie
guthrie@xxxxxxxxxxxxxxxxxx

--
Fedora-maintainers mailing list
Fedora-maintainers@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-maintainers

--
Fedora-maintainers-readonly mailing list
Fedora-maintainers-readonly@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-maintainers-readonly

[Index of Archives]     [Fedora Users]     [Fedora Development]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux