Quash .eh_frame unwind tables in boot code.
This commit is contained in:
parent
bf646ffdb7
commit
8cfb8991bc
@ -1,3 +1,8 @@
|
||||
# $NetBSD: Makefile.inc,v 1.3 2000/02/07 16:26:59 tsubai Exp $
|
||||
# $NetBSD: Makefile.inc,v 1.4 2017/04/20 19:09:29 uwe Exp $
|
||||
|
||||
BINDIR= /usr/mdec
|
||||
|
||||
CFLAGS_UNWIND.gcc= -fno-unwind-tables -fno-asynchronous-unwind-tables
|
||||
CFLAGS_UNWIND.clang= -fno-unwind-tables
|
||||
|
||||
LINKFLAGS_UNWIND= --no-ld-generated-unwind-info
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.15 2014/08/10 17:44:26 joerg Exp $
|
||||
# $NetBSD: Makefile,v 1.16 2017/04/20 19:09:29 uwe Exp $
|
||||
|
||||
S!= cd ${.CURDIR}/../../../..; pwd
|
||||
|
||||
@ -14,9 +14,11 @@ LIBC= # nothing
|
||||
|
||||
CFLAGS= -Os -Wall -ffreestanding
|
||||
CFLAGS+= ${${ACTIVE_CC} == "gcc":? -msoft-float :}
|
||||
CFLAGS+= ${CFLAGS_UNWIND.${ACTIVE_CC}}
|
||||
CPPFLAGS+= -D_STANDALONE -DPPC_OEA -I${.OBJDIR} -I${S}
|
||||
STRIPFLAG=
|
||||
LINKFLAGS= -x -N -Ttext 4000 -e _start
|
||||
LINKFLAGS+= ${LINKFLAGS_UNWIND}
|
||||
CLEANFILES+= ${PROG}.sym
|
||||
|
||||
${PROG}: ${OBJS}
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.57 2017/04/20 18:39:28 uwe Exp $
|
||||
# $NetBSD: Makefile,v 1.58 2017/04/20 19:09:29 uwe Exp $
|
||||
|
||||
S= ${.CURDIR}/../../../..
|
||||
|
||||
@ -9,6 +9,7 @@ XCOFFXTRA= Xcoffxtra.c
|
||||
XCOFFXTRAOBJ= Xcoffxtra.o
|
||||
CFLAGS+= -ffreestanding
|
||||
CFLAGS+= ${${ACTIVE_CC} == "gcc":? -msoft-float :}
|
||||
CFLAGS+= ${CFLAGS_UNWIND.${ACTIVE_CC}}
|
||||
CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith
|
||||
#CPPFLAGS+= -DDEBUG -DNETIF_DEBUG
|
||||
CPPFLAGS+= -D_STANDALONE -DSUPPORT_DHCP
|
||||
@ -55,6 +56,9 @@ CPPFLAGS+= -I. -I${.CURDIR} -I${.CURDIR}/../../.. -I${.CURDIR}/../../../..
|
||||
CPPFLAGS+= -DRELOC=0x${RELOC} -DRELOC_FLATFILE=0x${RELOC_FLATFILE}
|
||||
#CPPFLAGS+= -DXCOFF_GLUE # for booting PCI Powermacs
|
||||
|
||||
LINKFLAGS= -N -Ttext ${RELOC} -Bstatic
|
||||
LINKFLAGS+= ${LINKFLAGS_UNWIND}
|
||||
|
||||
### find out what to use for libkern
|
||||
KERN_AS= library
|
||||
.include "${S}/lib/libkern/Makefile.inc"
|
||||
@ -82,7 +86,7 @@ all realall: ${PROG} ${PROG}.xcf ${PROG}.elf
|
||||
|
||||
${PROG}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
${_MKTARGET_LINK}
|
||||
${LD} -s -N -Ttext ${RELOC} -Bstatic -o ${PROG}.el1 \
|
||||
${LD} -s -o ${PROG}.el1 ${LINKFLAGS} \
|
||||
${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
${OBJCOPY} -O binary ${PROG}.el1 ${PROG}
|
||||
|
||||
@ -91,13 +95,14 @@ ${PROG}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
|
||||
${PROG}.elf: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
${_MKTARGET_LINK}
|
||||
${LD} -s -N -Ttext ${RELOC} -Bstatic -o ${PROG}.elf \
|
||||
${LD} -s -o ${PROG}.elf ${LINKFLAGS} \
|
||||
${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
|
||||
${PROG}.xcf: ${OBJS} ${XCOFFXTRAOBJ} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
${_MKTARGET_LINK}
|
||||
${LD} -N -T ${.CURDIR}/../fixcoff/elf32_powerpc_merge.x -e _entry \
|
||||
-Ttext ${RELOC} -Bstatic -o ${PROG}.mrg ${XCOFFXTRAOBJ} \
|
||||
${LD} -o ${PROG}.mrg ${LINKFLAGS} \
|
||||
-T ${.CURDIR}/../fixcoff/elf32_powerpc_merge.x \
|
||||
-e _entry ${XCOFFXTRAOBJ} \
|
||||
${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
||||
${OBJCOPY} -O aixcoff-rs6000 -R .comment -R .note \
|
||||
${PROG}.mrg ${PROG}.xcf
|
||||
|
Loading…
Reference in New Issue
Block a user