diff options
author | obrien <obrien@FreeBSD.org> | 2000-10-28 21:26:48 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2000-10-28 21:26:48 +0000 |
commit | 82c32a8a3fa0c616208e6307b4d3d959da533536 (patch) | |
tree | 9ee217684afb0753c0a3a3a7d5180f5bc330dc3e /gnu/lib/csu | |
parent | 24f27bdb948eee33f69437d08daf0617f88ff3d3 (diff) | |
download | FreeBSD-src-82c32a8a3fa0c616208e6307b4d3d959da533536.zip FreeBSD-src-82c32a8a3fa0c616208e6307b4d3d959da533536.tar.gz |
* Bring back the guts of crt{i,n}.S. This allows C++ exceptions to work
when using the egcs and gcc-devel ports, along with GCC built from stock
public FSF sources. With out this change, FreeBSD will be removed from
the list of systems GCC 3.0 must be evaluated on before release. With
the effort some of us put into getting FreeBSD on this list, we should
not turn this effort into a waste, else we might not be worth fighting
for in the future. (note that Alpha and IA-64 versions of crt{i,n}.S
are needed)
* Switch from our own crt{begin,in} to those created from GCC's crtstuff.c.
This will allow us to switch to DWARF2 exceptions in the future, along with
staying in sync with any future GCC requirements.
* Break out our ELF branding bits into a seperate file. Currently this
is now included by our crt1.c files (since this functionality was part of
our native crtbegin.c). Later crtbrand.o will be merged in the creation
of crti.o.
Diffstat (limited to 'gnu/lib/csu')
-rw-r--r-- | gnu/lib/csu/Makefile | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/gnu/lib/csu/Makefile b/gnu/lib/csu/Makefile new file mode 100644 index 0000000..3a94ab8 --- /dev/null +++ b/gnu/lib/csu/Makefile @@ -0,0 +1,56 @@ +# $FreeBSD$ + +GCCDIR= ${.CURDIR}/../../../contrib/gcc.295 +.PATH: ${GCCDIR} + +SRCS= crtstuff.c tm.h +OBJS= crtbegin.o crtend.o +SOBJS= crtbegin.So crtend.So +CFLAGS+= -I${GCCDIR}/config -I. -DIN_GCC \ + -finhibit-size-directive -fno-inline-functions \ + -fno-exceptions -fno-omit-frame-pointer +NOMAN= true +NOPIC= true +NOPROFILE= true +INTERNALLIB= true +CLEANFILES+= tm.h + +CRTS_CFLAGS= -DCRTSTUFFS_O ${PICFLAG} + +all: ${OBJS} ${SOBJS} + +crtbegin.o: crtstuff.c tm.h + ${CC} ${CFLAGS} -g0 -DCRT_BEGIN \ + -c -o ${.TARGET} ${GCCDIR}/crtstuff.c + +crtbegin.So: crtstuff.c tm.h + ${CC} ${CFLAGS} -g0 -DCRT_BEGIN ${CRTS_CFLAGS} \ + -c -o ${.TARGET} ${GCCDIR}/crtstuff.c + +crtend.o: crtstuff.c tm.h + ${CC} ${CFLAGS} -g0 -DCRT_END \ + -c -o ${.TARGET} ${GCCDIR}/crtstuff.c + +crtend.So: crtstuff.c tm.h + ${CC} ${CFLAGS} -g0 -DCRT_END ${CRTS_CFLAGS} \ + -c -o ${.TARGET} ${GCCDIR}/crtstuff.c + +# KEEP THIS IN SYNC with src/gnu/usr.bin/cc/cc_tools/Makefile !! +tm.h: + echo '#include "${MACHINE_ARCH}/${MACHINE_ARCH}.h"' > ${.TARGET} +.if ${MACHINE_ARCH} == "i386" + echo '#include "${MACHINE_ARCH}/att.h"' >> ${.TARGET} +.endif + echo '#include <freebsd.h>' >> ${.TARGET} + echo '#include "${MACHINE_ARCH}/freebsd.h"' >> ${.TARGET} +.if ${MACHINE_ARCH} == "i386" + echo '#include "${MACHINE_ARCH}/perform.h"' >> ${.TARGET} +.endif + +realinstall: +.for file in ${OBJS} ${SOBJS} + ${INSTALL} ${COPY} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ + ${file} ${DESTDIR}${LIBDIR}/${file:S/.So$/S.o/} +.endfor + +.include <bsd.lib.mk> |