Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/share/mk/bsd.prog.mk,v rcsdiff: /ftp/cvs/cvsroot/src/share/mk/bsd.prog.mk,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.16 retrieving revision 1.21 diff -u -p -r1.16 -r1.21 --- src/share/mk/bsd.prog.mk 1993/06/02 14:56:51 1.16 +++ src/share/mk/bsd.prog.mk 1993/07/29 22:04:55 1.21 @@ -4,7 +4,7 @@ .include "${.CURDIR}/../Makefile.inc" .endif -.SUFFIXES: .out .o .c .y .l .s .8 .7 .6 .5 .4 .3 .2 .1 .0 +.SUFFIXES: .out .o .c .cc .C .y .l .s .8 .7 .6 .5 .4 .3 .2 .1 .0 .8.0 .7.0 .6.0 .5.0 .4.0 .3.0 .2.0 .1.0: nroff -mandoc ${.IMPSRC} > ${.TARGET} @@ -35,6 +35,7 @@ LIBPC?= /usr/lib/libpc.a LIBPLOT?= /usr/lib/libplot.a LIBRESOLV?= /usr/lib/libresolv.a LIBRPC?= /usr/lib/librpc.a +LIBRPCSVC?= /usr/lib/librpcsvc.a LIBTERM?= /usr/lib/libterm.a LIBUTIL?= /usr/lib/libutil.a @@ -44,6 +45,16 @@ CLEANFILES+=strings ${CC} -E ${CFLAGS} ${.IMPSRC} | xstr -c - @${CC} ${CFLAGS} -c x.c -o ${.TARGET} @rm -f x.c + +.cc.o: + ${CXX} -E ${CXXFLAGS} ${.IMPSRC} | xstr -c - + @mv -f x.c x.cc + @${CXX} ${CXXFLAGS} -c x.cc -o ${.TARGET} + +.C.o: + ${CXX} -E ${CXXFLAGS} ${.IMPSRC} | xstr -c - + @mv -f x.c x.C + @${CXX} ${CXXFLAGS} -c x.C -o ${.TARGET} .endif .if defined(PROG) @@ -117,7 +128,15 @@ cleandir: _PROGSUBDIR depend: .depend _PROGSUBDIR .depend: ${SRCS} .if defined(PROG) - mkdep ${MKDEP} ${CFLAGS:M-[ID+]*} ${.ALLSRC:M*.c} + rm -f .depend + files="${.ALLSRC:M*.c}"; \ + if [ "$$files" != "" ]; then \ + mkdep -a ${MKDEP} ${CFLAGS:M-[ID]*} $$files; \ + fi + files="${.ALLSRC:M*.cc} ${.ALLSRC:M*.C} ${.ALLSRC:M*.cxx}"; \ + if [ "$$files" != " " ]; then \ + mkdep -a ${MKDEP} -+ ${CXXFLAGS:M-[ID]*} $$files; \ + fi .endif .endif @@ -194,9 +213,9 @@ obj: _PROGSUBDIR else \ true ; \ dest=$$here/obj ; \ - echo "making $$here/obj" ; \ if test ! -d obj ; then \ - mkdir $$here/obj; \ + echo "making $$dest" ; \ + mkdir $$dest; \ fi ; \ fi; .endif