[packagers] Setting up an rpmforge/rpmrepo dev environment

Dag Wieers dag at wieers.com
Fri Nov 30 11:03:56 CET 2007


On Fri, 30 Nov 2007, Tom G. Christensen wrote:

> Dag Wieers wrote:
> > On Fri, 30 Nov 2007, Tom G. Christensen wrote:
> >
> > > Dag, if you're listening I'd strongly prefer rpmforge/rpmrepo to include
> > > %{?dist} in the specfiles directly :)
> >
> > Dries and I am not in favor of this.
> >
> If you don't mind me asking, why not?
>
> In my view it makes it easier that you don't have to massage the specfile
> before putting it through the buildsystem.

You should not care about this, as you do not need to care about what
flags you send to rpmbuild, or whether you have to install dependencies
yourself. All this should be done by the buildsystem.

The fact that it is not done right now is not an excuse to not implement
it or make it happen. The easy way is to add this %{?dist} and also
include the repotag in this dist macro, but I am not in favor of that. The
release indicates a number and the additional fields are mandatory and
added by the buildsystem.

Besides, 2%{?dist} just looks ugly and makes it hard to see what the
release is. It is useless.


> > > I'd also prefer that you only used %dtag to create a disttag ie. now you
> > > have
> > > (from mplayer.spec):
> > > %{?dtag: %{expand: %%define %dtag 1}}
> > > %{?fedora: %{expand: %%define fc%{fedora} 1}}
> > > I'd prefer that you just used %dtag to expand to fcX/fX as appropriate
> > > aswell
> > > as elX instead of what seems to be an extra unecessary step.
> >
> > Sure, sadly %{fedora} %{rhel} are tags used by Fedora and these have been
> > added by Matthias to work in the Fedora environment.
>
> Defining rhel and fedora (and perhaps rhl too) is fine, I do that aswell but I
> only use them to make checks like rhel > 4 or similar.
> I see no advantage in having two seperate ways to expand a disttag like above.

Well, this is done to make it work on Fedora. As I said Matthias added
these to build them as-is on Fedora (that does not know about the dtag).

In fact, Fedora abused our dist-tag invention and used it _only_ for added
a disttag to the release. Something we did not use it for. That forced us
(recently) to use dtag as the new macro.

Checks like rhel > 4 make the SPEC file hard to understand and can lead to
unexpected results. We prefer not to use it as such. If complete blocks
are different it may be better to either keep the difference outside of
the SPEC file or fork the SPEC file.

Up till now that was never necessary though (and in fact we only fork a
SPEC file to keep older versions for older distributions).


> > > Most of all though, I'd prefer documentation on how to setup an
> > > rpmforge/rpmrepo compatible buildsystem in just a few easy steps :)
> >
> > Yes, I would like that as well. But there are a few missing pieces and I
> > do not have the time to work on this. I hope this is done within the
> > rpmrepo project though.
>
> Good! It's one of the things I really hope will come together for rpmrepo, a
> well documented standard for building packages within the project.

http://wiki.rpmrepo.org/ is the place we need to add this information.

-- 
--   dag wieers,  dag at wieers.com,  http://dag.wieers.com/   --
[Any errors in spelling, tact or fact are transmission errors]


More information about the packagers mailing list