From Fedora Project Wiki

Revision as of 07:12, 5 May 2017 by Vondruch (talk | contribs) (Created page with "== Bootstrapping == If your package introduces build time circular dependencies, you should use this macro to bootstrap your package: <pre> # When we are bootstrapping, we d...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Bootstrapping

If your package introduces build time circular dependencies, you should use this macro to bootstrap your package:

# When we are bootstrapping, we drop some dependencies, and/or build time tests.
# Set this to 0 after we've bootstrapped.
%{!?_with_bootstrap: %global bootstrap 1}

[...]

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

[...]

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

If your package explicitly Provides: some functionality that is missing when bootstrapped, then that Provides: should look like:

%if ! 0%{?bootstrap}
Provides: bar(some_functionality)
%endif

Please note that usage of pre-built binaries in bootstrap still needs an exception from the Packaging Committee as stated in Packaging:Guidelines#Exceptions