From effad70c7b8f2d9f736e5e14f712ad71a6dcb0a6 Mon Sep 17 00:00:00 2001 From: Vít Ondruch Date: Mar 28 2019 08:17:20 +0000 Subject: [PATCH 1/3] Describe how to disble the `~boostrap` dist tag suffix. --- diff --git a/guidelines/modules/ROOT/pages/index.adoc b/guidelines/modules/ROOT/pages/index.adoc index c75df23..0d33750 100644 --- a/guidelines/modules/ROOT/pages/index.adoc +++ b/guidelines/modules/ROOT/pages/index.adoc @@ -1588,6 +1588,8 @@ make check %endif .... +As a nice side-effect, when bootstrapping mode is enabled, the `~bootstrap` suffix is appended to the dist tag. This avoids the need to bump release between bootstrap and final build. You can disable the automatic suffix addition by specifying `%define _bootstrap %nil` in your spec file. + If your package explicitly `+Provides:+` some functionality that is missing when bootstrapped, then that `+Provides:+` should look like: .... From c933c067ae5c41885d8a4c156fbc97bcaaf05e7f Mon Sep 17 00:00:00 2001 From: Vít Ondruch Date: Mar 28 2019 08:17:20 +0000 Subject: [PATCH 2/3] Convert bootstrapping guidelines to bcond_with macro. The macro is not really intuitive, OTOH it enables to use standard --with{,out}= options understood by RPM as well as Mock. --- diff --git a/guidelines/modules/ROOT/pages/index.adoc b/guidelines/modules/ROOT/pages/index.adoc index 0d33750..beeb841 100644 --- a/guidelines/modules/ROOT/pages/index.adoc +++ b/guidelines/modules/ROOT/pages/index.adoc @@ -1571,18 +1571,18 @@ If your package introduces build time circular dependencies, you should use this .... # When we are bootstrapping, we drop some dependencies, and/or build time tests. -%{?_with_bootstrap: %global bootstrap 1} +%bcond_with bootstrap [...] -%if ! 0%{?bootstrap} +%if %{without bootstrap} # dependencies for %%check BuildRequires: foo %endif [...] -%if ! 0%{?bootstrap} +%if %{without bootstrap} %check make check %endif From a016ca68eb3c1ad522740b743d10ee3196bebf9b Mon Sep 17 00:00:00 2001 From: Vít Ondruch Date: Mar 28 2019 08:17:20 +0000 Subject: [PATCH 3/3] Provide hint how to enable/disable bootstrapping. --- diff --git a/guidelines/modules/ROOT/pages/index.adoc b/guidelines/modules/ROOT/pages/index.adoc index beeb841..dfdd6e3 100644 --- a/guidelines/modules/ROOT/pages/index.adoc +++ b/guidelines/modules/ROOT/pages/index.adoc @@ -1588,7 +1588,7 @@ make check %endif .... -As a nice side-effect, when bootstrapping mode is enabled, the `~bootstrap` suffix is appended to the dist tag. This avoids the need to bump release between bootstrap and final build. You can disable the automatic suffix addition by specifying `%define _bootstrap %nil` in your spec file. +As a nice side-effect, when bootstrapping mode is enabled, the `~bootstrap` suffix is appended to the dist tag. This avoids the need to bump release between bootstrap and final build. You can temporarily enable bootstrapping by commit, which places `%global with_bootstrap 1` after `%bcond_with bootstrap` and later reverting the commit to do final build. You can disable the automatic suffix addition by specifying `%define _bootstrap %nil` in your spec file. If your package explicitly `+Provides:+` some functionality that is missing when bootstrapped, then that `+Provides:+` should look like: