#501 Fix bootstrap guidelines
Closed: Fixed None Opened 4 years ago by vondruch.

The logic in boostrap guidelines [1] is convoluted. When %bootstrap macro is set to 1, there should be less BR required and %check section should not be executed. The guidelines should be IMO

{{{
%{?_with_bootstrap: %global bootstrap 1}

[...]

%if ! 0%{?bootstrap}
# dependencies for %%check
BuildRequires: foo
%endif

[...]

%if ! 0%{?bootstrap}
%check
make check
%endif
}}}

Or the %bootstrap should use past tense, i.e. is should be renamed to %bootstrapped and the initial _with_bootstrap condition should be different. But may ge my english is just poor ...

This is how I implemented this in rubygem-sprockets-rails [2].

[1] https://fedoraproject.org/wiki/Packaging:Guidelines#Bootstrapping

[2] http://pkgs.fedoraproject.org/cgit/rubygem-sprockets-rails.git/commit/?id=3c57bf760f4cfc0dc692a503c51053aada74d284


We discussed this at today's meeting (http://meetbot.fedoraproject.org/fedora-meeting-1/2015-02-26/fpc.2015-02-26-17.01.txt):

  • 501 Fix bootstrap guidelines (geppetto, 17:05:08)

  • LINK: https://fedorahosted.org/fpc/ticket/501 (geppetto, 17:05:12)
  • ACTION: Proposal: Reverse conditionals in bootstrap examples, to
    make it less confusing (+1:7, 0:0, -1:0) (geppetto, 17:13:49)

I would drop the {{{# Set this to 0 after we've bootstrapped.}}} note. The reason for bootstrap macro is to not change the .spec file at all due to bootstraping.

Does koji now somehow provide a way to set --with options? Otherwise you kind of have to change the spec when bootstrapping.

Replying to [comment:6 tibbs]:

Does koji now somehow provide a way to set --with options? Otherwise you kind of have to change the spec when bootstrapping.

Right ... actually I was suggesting to have

{{{
%{?_with_bootstrap: %global bootstrap 1}
}}}

and with this macro, you have to change the value by different means anyway. Or am I missing something? Does the {{{%{!?_with_bootstrap: %global bootstrap 1}}}} works magically somehow unless you specify the --with option?

I've written up and announced the change as voted upon. So that this ticket doesn't become a confusing mess, I have opened a new ticket https://fedorahosted.org/fpc/ticket/509 to discuss the additional issue.

Metadata Update from @james:
- Issue assigned to james

2 years ago

Login to comment on this ticket.

Metadata