Bug 13331

Summary: openrc-0.42.1 compilation failure on gcc-10
Product: buildroot Reporter: mscdex <mscdex>
Component: OtherAssignee: unassigned
Status: RESOLVED FIXED    
Severity: normal CC: buildroot
Priority: P5    
Version: 2020.08.2   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Host: Target:
Build:
Attachments: Fix for GCC 10

Description mscdex 2020-11-23 16:27:20 UTC
Created attachment 8676 [details]
Fix for GCC 10

Host machine: Ubuntu 18.04
Buildroot version: 2020.08.2
Target: i586-buildroot-linux-musl-gcc (GCC 10.2.0)

Trying to build OpenRC 0.42.1 fails when compiling with GCC 10.x. It evidently will also fail with prior major versions when the '-fno-common' flag is explicitly used (this flag seems to be the default now on GCC 10.x, hence the failure).

I've attached a patch I found from Gentoo that fixes this issue.
Comment 1 Heiko Thiery 2020-11-23 19:20:21 UTC
I send a patch for including the fix.

https://patchwork.ozlabs.org/project/buildroot/patch/20201123191729.2557-1-heiko.thiery@gmail.com/

Thank you
Comment 2 Peter Korsgaard 2020-11-23 21:48:04 UTC
Fixed in master by Heiko's patch, thanks