Macroize build root policies for consistent disable/override ability
Add a separate macro for each brp we have, using standard naming convention and conditionalize the usage in %__os_install_post. Voilà, we have a standard way to disable (and also override) any brp scripts from specs that need it and a common scheme for new brps to follow. Note that this is not supposed to change the existing behavior and default build root policy invocations at all, any change in those would be a thinko/typo/copy-paste error in this commit.
This commit is contained in:
parent
42f29f31df
commit
c4646d791d
21
macros
21
macros
@ -98,15 +98,24 @@
|
|||||||
|
|
||||||
%__arch_install_post /usr/lib/rpm/check-buildroot
|
%__arch_install_post /usr/lib/rpm/check-buildroot
|
||||||
|
|
||||||
|
# Build root policy macros. Standard naming:
|
||||||
|
# convert all '-' in basename to '_', add two leading underscores.
|
||||||
|
%__brp_compress /usr/lib/rpm/brp-compress
|
||||||
|
%__brp_strip /usr/lib/rpm/brp-strip %{__strip}
|
||||||
|
%__brp_strip_comment_note /usr/lib/rpm/brp-strip-comment-note %{__strip} %{__objdump}
|
||||||
|
%__brp_strip_static_archive /usr/lib/rpm/brp-strip-static-archive %{__strip}
|
||||||
|
%__brp_python_bytecompile /usr/lib/rpm/brp-python-bytecompile %{__python} %{?_python_bytecompile_errors_terminate_build}
|
||||||
|
%__brp_python_hardlink /usr/lib/rpm/brp-python-hardlink
|
||||||
|
|
||||||
%__os_install_post \
|
%__os_install_post \
|
||||||
/usr/lib/rpm/brp-compress \
|
%{?__brp_compress} \
|
||||||
%{!?__debug_package:\
|
%{!?__debug_package:\
|
||||||
/usr/lib/rpm/brp-strip %{__strip} \
|
%{?__brp_strip} \
|
||||||
/usr/lib/rpm/brp-strip-comment-note %{__strip} %{__objdump} \
|
%{?__brp_strip_comment_note} \
|
||||||
} \
|
} \
|
||||||
/usr/lib/rpm/brp-strip-static-archive %{__strip} \
|
%{?__brp_strip_static_archive} \
|
||||||
%{?py_auto_byte_compile:/usr/lib/rpm/brp-python-bytecompile %{__python} %{?_python_bytecompile_errors_terminate_build}} \
|
%{?py_auto_byte_compile:%{?__brp_python_bytecompile} \
|
||||||
/usr/lib/rpm/brp-python-hardlink \
|
%{?__brp_python_hardlink} \
|
||||||
%{nil}
|
%{nil}
|
||||||
|
|
||||||
%__spec_install_post\
|
%__spec_install_post\
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
Summary: Red Hat specific rpm configuration files
|
Summary: Red Hat specific rpm configuration files
|
||||||
Name: redhat-rpm-config
|
Name: redhat-rpm-config
|
||||||
Version: 76
|
Version: 77
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
# No version specified.
|
# No version specified.
|
||||||
License: GPL+
|
License: GPL+
|
||||||
@ -153,6 +153,9 @@ install -p -m 755 -t %{buildroot}%{_rpmconfigdir} kmod.prov
|
|||||||
%{_rpmconfigdir}/macros.d/macros.kmp
|
%{_rpmconfigdir}/macros.d/macros.kmp
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Jan 17 2018 Panu Matilainen <pmatilai@redhat.com> - 77-1
|
||||||
|
- Macroize build root policies for consistent disable/override ability
|
||||||
|
|
||||||
* Wed Jan 17 2018 Florian Weimer <fweimer@redhat.com> - 76-1
|
* Wed Jan 17 2018 Florian Weimer <fweimer@redhat.com> - 76-1
|
||||||
- Add -fstack-clash-protection for supported architectures (#1515865)
|
- Add -fstack-clash-protection for supported architectures (#1515865)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user