On Fri, May 5, 2017 at 6:22 PM, Tomasz Kłoczko <kloczko.tomasz(a)gmail.com>
On 5 May 2017 at 15:50, Vít Ondruch <vondruch(a)redhat.com>
> Of course it should be enabled by default. This is not elaborated in the
> guidelines, but there still applied "use your best judgement" I hope ...
If you will go over current Fedora specs you can find that it is not
obvious to many package maintainers :)
Many specs contains possibility to *disable* %check probably only
because in FPG is something about doing this without clear explanation
when it should be used.
> "--nocheck" is nice, but does not disable the "check"
> installation. There was probably some ticket requesting this, not sure
Few weeks ago I've proposed here extend spec syntax by add add
CheckRequires field (-> analog to BuildRequires).
So far I did not seen any comment about this idea .. :)
Dependencies listed in CheckRequires should be validated only if
rpmbuild within own pipeline will be executing %check.
So -bp, -bc, -bb, -bi combined with --short-circuit as well, or when
-ba --nocheck is used should not be checking CheckRequires
IMO such extension will solve this kind of cases without using
functional description (%ifing) and only using declarative form of the
description which could be easily processed as well using %dump macro
("rpmbuild -bp --nodeps --define 'prep %dump' <package>.spec").
IMO CheckRequires is only civilized solution as firing %check is
implemented not on the macros layer.
> > In existing Fedora spec files probably in +95% cases instead %global
should be used %define
"Use %global instead of %define, unless you really need only locally
defined submacros within other macro definitions (a very rare case)."
Looks like this sentence is read by most of the packagers up to only ","
Maybe this form is readable for the layers but it does not work for
("Use %global .. unless" almost everyone will be interpreting as "use
%global" as a general approach with <some exceptions> described after
"unless" .. problems is that what is after "unless" is relevant to
majority of the cases -> *it is not the exception* .. because most of
the packagers "need only locally defined submacros" :)
This sentence is kind of perfect example how to write almost every
time incorrectly understood rule :)
Logically this sentence still is 100% correct but reverse form
(putting majority after "unless") is what is not what you could expect
it looks like about 8 years ago a campaign started to replace **all**
%define with %global
so packagers don't use %define in local scopes by mistake:
Make a googlesearch for "use global instead of define".
Seems as same as there is no clear description in FPG about removing
permanently packages by Obsoletes rules and only part which mentions
something about using obsoletes is related to swapping packages names
most of the packages in absence of those rules are using "what is
possible to find" and this is why most of the packagers "use %global
instead of %define: :)
Ergo: FPG is at least in two points waaaay behind how things should be
used or says something which almost everyone incorrectly understands.
It is only a matter of time when someone will find that it is a clash
with some new global macros connected with other macros because
someone overuse of %global in some specs (this is about this "a very
rare case" :) ).
Tomasz Kłoczko | LinkedIn: http://lnkd.in/FXPWxH
packaging mailing list -- packaging(a)lists.fedoraproject.org
To unsubscribe send an email to packaging-leave(a)lists.fedoraproject.org