Skip to contentSkip to conversation

package/libpcap: fix m68k-cf compile issue

PATCH Applied Waldemar Brodkorb 2 participants 2 messages Aug 14, 2024 – Aug 15, 2024

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/libpcap: fix m68k-cf compile issue

Compilation with -Os triggers this assembler problem. The problematic C code contains a long switch statement, so everything looks like GCC Bug 104028 is triggered.

Fixes:
- http://autobuild.buildroot.net/results/db5/db58215fb3c7f30b6c0f0764a84271010346edfb

---
v1->v2:
- use GCC_BUG_XXXXXX instead of arch sepcific stuff, requested by Thomas Petazzoni

---
 package/libpcap/libpcap.mk | 4 ++++
 1 file changed, 4 insertions(+)
package/libpcap/libpcap.mk +4 -0
index a4523f2218..3d05590da3 100644
@@ -57,5 +57,9 @@ ifeq ($(BR2_microblaze)$(BR2_sparc)$(BR2_sparc64),y)
 LIBPCAP_CFLAGS += -fPIC
 endif
 
+ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_104028),y)
+LIBPCAP_CFLAGS += -O2
+endif
+
 $(eval $(autotools-package))
 $(eval $(host-autotools-package))
Signature · 6 lines
2.39.2

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw
Quoted 7 lines · On Thu, 15 Aug 2024 01:52:49 +0200 Waldemar Brodkorb <[email protected]> wrote:

Compilation with -Os triggers this assembler problem. The problematic C code contains a long switch statement, so everything looks like GCC Bug 104028 is triggered.

Fixes:
- http://autobuild.buildroot.net/results/db5/db58215fb3c7f30b6c0f0764a84271010346edfb

Quoted 8 lines

---
v1->v2:
- use GCC_BUG_XXXXXX instead of arch sepcific stuff, requested by Thomas Petazzoni

---
 package/libpcap/libpcap.mk | 4 ++++
 1 file changed, 4 insertions(+)

Applied to master, thanks.

Thomas

Signature · 7 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot