gnu/lib/csu: Add -fno-asynchronous-unwind-tables to the CFLAGS.
authorSascha Wildner <saw@online.de>
Sun, 27 Feb 2011 18:25:38 +0000 (19:25 +0100)
committerSascha Wildner <saw@online.de>
Sun, 27 Feb 2011 18:26:17 +0000 (19:26 +0100)
Quoth FreeBSD's commit msg:

Often reported issue with newer ld is:
error in /usr/lib/crtendS.o(.eh_frame); no .eh_frame_hdr table will
be created.

The issue is that crtend is compiled with unwind table, and also it
places the special CIE into the .eh_frame indicating the end of
section, that is located before generated unwind table. New ld has
assertion that verifies that closing CIE is indeed the last CIE,
causing the crypting message to be issued, and refusing to generate
dwarf unwind.

Add -fno-asynchronous-unwind-tables to disable unwind table generation
for crtbegin/crtend.

Taken-from: FreeBSD

gnu/lib/csu/Makefile.csu

index 46908ae..71522e5 100644 (file)
@@ -1,5 +1,4 @@
 # $FreeBSD: src/gnu/lib/csu/Makefile,v 1.24 2004/09/10 06:48:04 ru Exp $
-# $DragonFly: src/gnu/lib/csu/Makefile.csu,v 1.2 2007/08/23 06:52:02 corecode Exp $
 
 SRCS+=         crtstuff.c
 HDRS+=         tm.h
@@ -14,7 +13,8 @@ OBJS+=        ${SRCS:N*.h:R:S/$/.o/g}
 
 CFLAGS+=       -finhibit-size-directive -fno-inline-functions \
                -fno-exceptions -fno-zero-initialized-in-bss \
-               -fno-omit-frame-pointer -fno-unit-at-a-time
+               -fno-omit-frame-pointer -fno-unit-at-a-time \
+               -fno-asynchronous-unwind-tables
 CFLAGS+=       -I.
 
 CRTS_CFLAGS=   -DCRTSTUFFS_O -DSHARED ${PICFLAG}