package/xfsprogs: fix linking error when -O0 is used
PATCH 2/2 package/xfsprogs: fix linking error when -O0 is used
Urcu does not like -O0 it needs gcc optimizations. Force -O1 in this case. Inspired by package fwts.
Fixes:
- http://autobuild.buildroot.net/results/3bd/3bd7de784953ab1fa70bf5572eccd7b10e4a0e17
--- package/xfsprogs/xfsprogs.mk | 4 ++++ 1 file changed, 4 insertions(+)
package/xfsprogs/xfsprogs.mk +4 -0
@@ -27,6 +27,10 @@ else XFSPROGS_CONF_OPTS += --disable-libicu endif +ifeq ($(BR2_OPTIMIZE_0),y) +XFSPROGS_CONF_ENV += CFLAGS="$(TARGET_CFLAGS) -O1" +endif + XFSPROGS_INSTALL_TARGET_OPTS = DIST_ROOT=$(TARGET_DIR) install $(eval $(autotools-package))
Signature · 6 lines
2.39.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Hello Waldemar,
Quoted 7 lines · On Fri, 11 Aug 2023 11:43:22 +0200 Waldemar Brodkorb <[email protected]> wrote:
Urcu does not like -O0 it needs gcc optimizations. Force -O1 in this case. Inspired by package fwts.
Fixes:
- http://autobuild.buildroot.net/results/3bd/3bd7de784953ab1fa70bf5572eccd7b10e4a0e17Signed-off-by Waldemar Brodkorb <[email protected]>
Thanks a lot for looking into this.
However, I'm wondering why is this patch 2/2 ? If it's already happening in the autobuilders, I guess it means it should come *before* the version bump, to fix an already existing issue, independent of the version bump ?
Also, since when is this error happening? As explained in my reply to your libedit patch, we need to understand since when issues are happening, so we know which commit introduced the regression.
Very good tools to help in this investigation are:
- Look at http://autobuild.buildroot.net/?reason=xfsprogs% and see in the history of build failures when it started happening
- Obviously, look at the Git history for the package, and how that sometimes translates (in terms of commit dates) with build errors starting to happen, as reported by the autobuilders
At http://autobuild.buildroot.net/?reason=xfsprogs%&step=50&start=100
it seems like we started seeing the issue when it was bumped from 5.8.0 to 5.14.2, or it might be due to us starting to test -O0 builds (which was not the case before).
So here, the issue got introduced in commit 2f8f69012e0eee7f3e98212fb3da118c211f3c0b: before this commit, xfsprogs builds fine at -O0, after this commit, it fails to build at -O0. As this commit went into 2022.02, the fix needs to be backported to stable branches.
Could you resend this patch series, swapping patches 1/2 and 2/2, as well as extending the justification for the fix?
Thanks a lot!
Thomas
Signature · 7 lines
Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot