diff options
author | obrien <obrien@FreeBSD.org> | 2002-05-13 03:27:03 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2002-05-13 03:27:03 +0000 |
commit | 1daa12366ea8f47d1f39acc0c349daa368fd853b (patch) | |
tree | 6eea9fac75fc54638a3a34609d1dc66e991cd2a2 | |
parent | fbb890cb8c4b4a71a687d4e66ef3e5d5e8047b4e (diff) | |
download | FreeBSD-src-1daa12366ea8f47d1f39acc0c349daa368fd853b.zip FreeBSD-src-1daa12366ea8f47d1f39acc0c349daa368fd853b.tar.gz |
Restore some of the implementation from the Bmake gcc 2.95 bits.
In the end, I can do things more like the previous Bmake bits than was
apparent in the middle of the gcc31 WIP.
-rw-r--r-- | gnu/usr.bin/cc/cc1/Makefile | 21 | ||||
-rw-r--r-- | gnu/usr.bin/cc/cc1obj/Makefile | 21 | ||||
-rw-r--r-- | gnu/usr.bin/cc/cc1plus/Makefile | 17 | ||||
-rw-r--r-- | gnu/usr.bin/cc/cccp/Makefile | 20 | ||||
-rw-r--r-- | gnu/usr.bin/cc/cpp0/Makefile | 20 | ||||
-rw-r--r-- | gnu/usr.bin/cc/tradcpp0/Makefile | 11 |
6 files changed, 59 insertions, 51 deletions
diff --git a/gnu/usr.bin/cc/cc1/Makefile b/gnu/usr.bin/cc/cc1/Makefile index 2dc48a0..09a89b5 100644 --- a/gnu/usr.bin/cc/cc1/Makefile +++ b/gnu/usr.bin/cc/cc1/Makefile @@ -2,10 +2,10 @@ .include "../Makefile.inc" -.PATH: ../cc_tools ${GCCDIR} +.PATH: ${GCCDIR} PROG= cc1 -SRCS= main.c c-parse.c c-lang.c c-decl.c +SRCS= main.c c-parse+%DIKED.c c-lang.c c-decl.c BINDIR= /usr/libexec NOMAN= 1 NOSHARED?=yes @@ -17,17 +17,18 @@ LDADD+= ${LIBCC_INT} #----------------------------------------------------------------------- # C parser -.ORDER: c-parse.c -c-parse.c: c-parse.in +c-parse+%DIKED.c: c-parse.c + sed -e "s/malloc/xmalloc/g" \ + -e "s/realloc/xrealloc/g" \ + ${.ALLSRC} > ${.TARGET} + +c-parse.y: c-parse.in sed -e "/^ifobjc$$/,/^end ifobjc$$/d" \ -e "/^ifc$$/d" \ -e "/^end ifc$$/d" \ - ${GCCDIR}/c-parse.in > c-parse.y - ${YACC} -o c-parse.c.in c-parse.y - sed -e "s/malloc/xmalloc/g" \ - -e "s/realloc/xrealloc/g" \ - c-parse.c.in >c-parse.c + ${.ALLSRC} > ${.TARGET} -CLEANFILES= c-parse.c c-parse.y +CLEANFILES= c-parse+%DIKED.c c-parse.c c-parse.y +CLEANFILES+= y.tab.h # we don't use it, but the system YACC rules are naive .include <bsd.prog.mk> diff --git a/gnu/usr.bin/cc/cc1obj/Makefile b/gnu/usr.bin/cc/cc1obj/Makefile index 9258d0e..d4ecd8c 100644 --- a/gnu/usr.bin/cc/cc1obj/Makefile +++ b/gnu/usr.bin/cc/cc1obj/Makefile @@ -2,10 +2,10 @@ .include "../Makefile.inc" -.PATH: ../cc_tools ${GCCDIR}/objc ${GCCDIR} +.PATH: ${GCCDIR}/objc ${GCCDIR} PROG= cc1obj -SRCS= objc-parse.c objc-act.c objc-lang.c main.c c-decl.c +SRCS= objc-parse+DIKED.c objc-act.c objc-lang.c main.c c-decl.c BINDIR= /usr/libexec NOMAN= 1 NOSHARED?=yes @@ -17,18 +17,19 @@ LDADD+= ${LIBCC_INT} #----------------------------------------------------------------------- # objc parser -.ORDER: objc-parse.c -objc-parse.c: c-parse.in +objc-parse+DIKED.c: objc-parse.c + sed -e "s/malloc/xmalloc/g" \ + -e "s/realloc/xrealloc/g" \ + ${.ALLSRC} > ${.TARGET} + +objc-parse.y: c-parse.in sed -e "/^ifc$$/,/^end ifc$$/d" \ -e "/^ifobjc$$/d" \ -e "/^end ifobjc$$/d" \ - ${GCCDIR}/c-parse.in > objc-parse.y - ${YACC} -o objc-parse.c.in objc-parse.y - sed -e "s/malloc/xmalloc/g" \ - -e "s/realloc/xrealloc/g" \ - objc-parse.c.in >objc-parse.c + ${.ALLSRC} > ${.TARGET} -CLEANFILES= objc-parse.c objc-parse.y +CLEANFILES= objc-parse+DIKED.c objc-parse.c objc-parse.y +CLEANFILES+= y.tab.h # we don't use it, but the system YACC rules are naive #----------------------------------------------------------------------- diff --git a/gnu/usr.bin/cc/cc1plus/Makefile b/gnu/usr.bin/cc/cc1plus/Makefile index 094cf59..97ccdcf 100644 --- a/gnu/usr.bin/cc/cc1plus/Makefile +++ b/gnu/usr.bin/cc/cc1plus/Makefile @@ -5,11 +5,11 @@ .PATH: ${GCCDIR}/cp ${GCCDIR} PROG= cc1plus -SRCS= parse-%DIKED.c parse.h cfns.h -SRCS+= main.c cp-lang.c -SRCS+= call.c class.c cvt.c decl.c decl2.c error.c except.c expr.c \ - friend.c init.c lex.c mangle.c method.c pt.c ptree.c repo.c rtti.c \ - search.c semantics.c spew.c tree.c typeck.c typeck2.c dump.c optimize.c +SRCS= parse+%DIKED.c parse.h cfns.h +SRCS+= main.c cp-lang.c \ + call.c class.c cvt.c decl.c decl2.c error.c except.c expr.c friend.c \ + init.c lex.c mangle.c method.c pt.c ptree.c repo.c rtti.c search.c \ + semantics.c spew.c tree.c typeck.c typeck2.c dump.c optimize.c BINDIR= /usr/libexec NOMAN= 1 @@ -20,9 +20,10 @@ CFLAGS+= -I${GCCDIR}/cp -I. DPADD+= ${LIBCC_INT} LDADD+= ${LIBCC_INT} -CLEANFILES= parse-%DIKED.c parse.c parse.h y.tab.h cfns.h +#----------------------------------------------------------------------- +# C++ parser -parse-%DIKED.c y.tab.h: parse.c +parse+%DIKED.c y.tab.h: parse.c sed -e "s/malloc/xmalloc/g" \ -e "s/realloc/xrealloc/g" \ ${.ALLSRC:M*c} > ${.TARGET} @@ -35,4 +36,6 @@ cfns.h: cfns.gperf gperf -o -C -E -k '1-6,$$' -j1 -D -N 'libc_name_p' \ ${.ALLSRC} > ${.TARGET} +CLEANFILES= parse+%DIKED.c parse.c parse.h y.tab.h cfns.h + .include <bsd.prog.mk> diff --git a/gnu/usr.bin/cc/cccp/Makefile b/gnu/usr.bin/cc/cccp/Makefile index a63467d..eb0bc72 100644 --- a/gnu/usr.bin/cc/cccp/Makefile +++ b/gnu/usr.bin/cc/cccp/Makefile @@ -5,7 +5,7 @@ .PATH: ${GCCDIR} PROG= cpp0 -SRCS= cppmain.c c-parse.c c-lang.c c-decl.c +SRCS= cppmain.c c-parse+%DIKED.c c-lang.c c-decl.c BINDIR= /usr/libexec NOMAN= 1 @@ -16,18 +16,20 @@ LDADD+= ${LIBCC_INT} #----------------------------------------------------------------------- # C parser -.ORDER: c-parse.c -c-parse.c: c-parse.in + +c-parse+%DIKED.c: c-parse.c + sed -e "s/malloc/xmalloc/g" \ + -e "s/realloc/xrealloc/g" \ + ${.ALLSRC} > ${.TARGET} + +c-parse.y: c-parse.in sed -e "/^ifobjc$$/,/^end ifobjc$$/d" \ -e "/^ifc$$/d" \ -e "/^end ifc$$/d" \ - ${GCCDIR}/c-parse.in > c-parse.y - ${YACC} -o c-parse.c.in c-parse.y - sed -e "s/malloc/xmalloc/g" \ - -e "s/realloc/xrealloc/g" \ - c-parse.c.in >c-parse.c + ${.ALLSRC} > ${.TARGET} -CLEANFILES= c-parse.c c-parse.y +CLEANFILES= c-parse+%DIKED.c c-parse.c c-parse.y +CLEANFILES+= y.tab.h # we don't use it, but the system YACC rules are naive #----------------------------------------------------------------------- diff --git a/gnu/usr.bin/cc/cpp0/Makefile b/gnu/usr.bin/cc/cpp0/Makefile index a63467d..eb0bc72 100644 --- a/gnu/usr.bin/cc/cpp0/Makefile +++ b/gnu/usr.bin/cc/cpp0/Makefile @@ -5,7 +5,7 @@ .PATH: ${GCCDIR} PROG= cpp0 -SRCS= cppmain.c c-parse.c c-lang.c c-decl.c +SRCS= cppmain.c c-parse+%DIKED.c c-lang.c c-decl.c BINDIR= /usr/libexec NOMAN= 1 @@ -16,18 +16,20 @@ LDADD+= ${LIBCC_INT} #----------------------------------------------------------------------- # C parser -.ORDER: c-parse.c -c-parse.c: c-parse.in + +c-parse+%DIKED.c: c-parse.c + sed -e "s/malloc/xmalloc/g" \ + -e "s/realloc/xrealloc/g" \ + ${.ALLSRC} > ${.TARGET} + +c-parse.y: c-parse.in sed -e "/^ifobjc$$/,/^end ifobjc$$/d" \ -e "/^ifc$$/d" \ -e "/^end ifc$$/d" \ - ${GCCDIR}/c-parse.in > c-parse.y - ${YACC} -o c-parse.c.in c-parse.y - sed -e "s/malloc/xmalloc/g" \ - -e "s/realloc/xrealloc/g" \ - c-parse.c.in >c-parse.c + ${.ALLSRC} > ${.TARGET} -CLEANFILES= c-parse.c c-parse.y +CLEANFILES= c-parse+%DIKED.c c-parse.c c-parse.y +CLEANFILES+= y.tab.h # we don't use it, but the system YACC rules are naive #----------------------------------------------------------------------- diff --git a/gnu/usr.bin/cc/tradcpp0/Makefile b/gnu/usr.bin/cc/tradcpp0/Makefile index 000eb86..3ec8968 100644 --- a/gnu/usr.bin/cc/tradcpp0/Makefile +++ b/gnu/usr.bin/cc/tradcpp0/Makefile @@ -5,20 +5,19 @@ .PATH: ${GCCDIR} PROG= tradcpp0 -SRCS= tradcpp.c tradcif.c +SRCS= tradcpp.c tradcif+%DIKED.c BINDIR= /usr/libexec NOMAN= 1 DPADD+= ${LIBCC_INT} LDADD+= ${LIBCC_INT} -# ${YACC} ${GCCDIR}/tradcif.y -tradcif.c: tradcif.y - ${YACC} ${.ALLSRC} +tradcif+%DIKED.c: tradcif.c sed -e "s/malloc/xmalloc/g" \ -e "s/realloc/xrealloc/g" \ - y.tab.c >${.TARGET} + ${.ALLSRC} >${.TARGET} -CLEANFILES= y.tab.c tradcif.c +CLEANFILES= tradcif+%DIKED.c tradcif.c +CLEANFILES+= y.tab.h # we don't use it, but the system YACC rules are naive .include <bsd.prog.mk> |