diff options
-rw-r--r-- | NEWS | 2 | ||||
-rw-r--r-- | macros.in | 11 |
2 files changed, 13 insertions, 0 deletions
@@ -1,3 +1,5 @@ +- macros: automatically use %set_build_flags macro for build, check, and install phases + Version 2.81 - 11 November 2024, by Jani Välimaa - macros: add redhat-hardened-clang-ld.cfg (from Fedora) to pass -pie when linking with clang - macros: add %dist_vendor (Mageia) and %dist_name (Mageia Linux) macros @@ -293,6 +293,16 @@ GCONF_CONFIG_SOURCE=`%{_gconftool_bin} --get-default-source` %{_gconftool_bin} - %{warn:%%setup_compile_flags is deprecated, use %%set_build_flags instead} \ %set_build_flags +# Automatically use set_build_flags macro for build, check, and +# install phases. +# Use "%undefine _auto_set_build_flags" to disable" +%_auto_set_build_flags 1 +%__spec_build_pre %{___build_pre} \ + %{?_auto_set_build_flags:%{set_build_flags}} + +%__spec_check_pre %{___build_pre} \ + %{?_auto_set_build_flags:%{set_build_flags}} + %debugcflags %{?_enable_debug_packages:-g} %_fortify_level 3 @@ -518,6 +528,7 @@ if [ %{_with install} -eq 1 ]; then\ [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf "${RPM_BUILD_ROOT}"\ mkdir -p `dirname "$RPM_BUILD_ROOT"`\ mkdir "$RPM_BUILD_ROOT"\ + %{?_auto_set_build_flags:%{set_build_flags}}\ fi #--------------------------------------------------------------------- |