As the follow up of https://github.com/rpm-software-management/rpm/pull/813
I would like to have rpm macros that will do operations on `%optflags`:

Example:
- `%filter-out-optflags '-flto=auto'`
- `%append-if-to-optflags '-flto=auto' -ffat-lto-objects`

I found the example how currently we do it e.g. in MozillaFirefox:
```
%{expand:%%global optflags %(echo "%optflags"|sed -e s/i586/i686/) -march=i686 
-mtune=generic}
```

Which is quite ugly and I bet multiple packages suffer from the same issue. 
Gentoo has a reasonable API for that:
https://devmanual.gentoo.org/eclass-reference/flag-o-matic.eclass/index.html

@pmatilai Is it realistic to come up with the functionality?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/814
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to