diff options
| author | thorpej <thorpej@NetBSD.org> | 2001-12-12 17:27:50 +0000 |
|---|---|---|
| committer | thorpej <thorpej@NetBSD.org> | 2001-12-12 17:27:50 +0000 |
| commit | 5722ce0152834e92013a3853d44e0209904fcdfe (patch) | |
| tree | e111688a251ca27f359bf97aaba870f870cf86ea /gnu | |
| parent | e2970b134f081d8b18e09f3cee32a35738e32b63 (diff) | |
Make LIB2FUNCS_EH work like the rest of LIB2FUNCS, and clean
up the special rules required to build those objects.
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/lib/libgcc/Makefile | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile index 1f444126c2e..5672aeee763 100644 --- a/gnu/lib/libgcc/Makefile +++ b/gnu/lib/libgcc/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.34 2001/12/12 09:30:55 lukem Exp $ +# $NetBSD: Makefile,v 1.35 2001/12/12 17:27:50 thorpej Exp $ REQUIRETOOLS= yes @@ -26,9 +26,12 @@ CFLAGS+= -msoft-quad-float .endif LIB2FUNCS= ${G_LIB2FUNCS:=.c} +.if defined(G_LIB2FUNCS_EH) +LIB2FUNCS_EH= ${G_LIB2FUNCS_EH:=.c} +.endif CXX_LIB2FUNCS= ${G_CXX_LIB2FUNCS:Mop*:S/opdel.o/opdelete.o/:.o=.cc} -SRCS+= ${LIB2FUNCS} ${CXX_LIB2FUNCS} \ +SRCS+= ${LIB2FUNCS} ${LIB2FUNCS_EH} ${CXX_LIB2FUNCS} \ ${G_CXX_LIB2FUNCS:Nop*:.o=.cc} ${G_LIB2ADD:M*.c:T} OBJS+= ${G_LIB2FUNCS_EH:=.o} @@ -38,14 +41,19 @@ CLEANFILES+= ${LIB2FUNCS} ${CXX_LIB2FUNCS} dp-bit.c fp-bit.c ${LIB2FUNCS}: ${.CURDIR}/Makefile printf '#define L${.PREFIX}\n#include <libgcc2.c>\n' >${.TARGET} -${G_LIB2FUNCS_EH:=.o}: libgcc2.c - ${COMPILE.c} -fexceptions -o $@ ${>:M*.c} +.if defined(G_LIB2FUNCS_EH) +${LIB2FUNCS_EH}: ${.CURDIR}/Makefile + printf '#define L${.PREFIX}\n#include <libgcc2.c>\n' >${.TARGET} + +${G_LIB2FUNCS_EH:=.o}: + ${COMPILE.c} -fexceptions -o ${.TARGET} ${.IMPSRC} -${G_LIB2FUNCS_EH:=.po}: libgcc2.c - ${COMPILE.c} -pg -fexceptions -o $@ ${>:M*.c} +${G_LIB2FUNCS_EH:=.po}: + ${COMPILE.c} -pg -fexceptions -o ${.TARGET} ${.IMPSRC} -${G_LIB2FUNCS_EH:=.so}: libgcc2.c - ${COMPILE.c} ${CPICFLAGS} -fexceptions -o $@ ${>:M*.c} +${G_LIB2FUNCS_EH:=.so}: + ${COMPILE.c} ${CPICFLAGS} -fexceptions -o ${.TARGET} ${.IMPSRC} +.endif # G_LIB2FUNCS_EH ${CXX_LIB2FUNCS}: ${.CURDIR}/Makefile printf '#define L_op_${.PREFIX:S/^op//}\n#include <new1.cc>\n#include <new2.cc>\n' >${.TARGET} |
