On Thu, Jan 27, 2022 at 11:29:13AM +0100, Iñaki Ucar wrote:
On Thu, 27 Jan 2022 at 11:19, Iñaki Ucar
<iucar(a)fedoraproject.org> wrote:
>
> On Thu, 27 Jan 2022 at 10:58, Zbigniew Jędrzejewski-Szmek
> <zbyszek(a)in.waw.pl> wrote:
> >
> > > I think this change should be reverted until a cleaner way can be
> > > found to implement it.
> > I'm all for making better, but please make concrete proposals.
>
> Here's a concrete proposal:
>
> - Copy %build_*flags to another private macro, let's say %_build_*flags.
> - Add there the stuff that is not valid once the current build
> finishes (e.g., the flag that this change adds).
> - Use that in %set_build_flags and leave %build_*flags as it was.
This wouldn't help: CFLAGS/CXXFLAGS/LDFLAGS would still contain
the problematic flags. So packages which embed those flags in a place where
they shouldn't would still have a problem.
We *do* have a macro that has build flags with "problematic" flags removed:
%extension_{c,cxx,ld}flags.
Or even better:
- Define a new set of build-specific build flags, let's say
%build_specific_*flags
- Add the stuff there.
- Add them to %set_build_flags along %build_*flags
This has the same problem as above.
Zbyszek