Make `make depend' work. For this, it was necessary to remove ${.ALLSRC}

from the build rules; it has been replaced with `${.CURDIR}/${SRCS}'.
Also, avoid "a.out" like <mk/bsd.lib.mk>.
This commit is contained in:
pk 1995-09-29 11:23:15 +00:00
parent ae1d1592ec
commit a9c6e6dfa1
4 changed files with 108 additions and 65 deletions

View File

@ -1,31 +1,42 @@
# from: @(#)Makefile 5.6 (Berkeley) 5/22/91
# $Id: Makefile,v 1.15 1995/06/05 01:57:04 pk Exp $
# from: @(#)Makefile 5.5 (Berkeley) 5/21/91
# $Id: Makefile,v 1.16 1995/09/29 11:23:15 pk Exp $
CFLAGS+= -DLIBC_SCCS -I${.CURDIR}/..
OBJS= crt0.o gcrt0.o scrt0.o
CLEANFILES+= core a.out
SRCS= crt0.c
all: ${OBJS}
crt0.o: crt0.c
${COMPILE.c} -DCRT0 -DDYNAMIC ${.ALLSRC}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
crt0.o: ${SRCS}
@echo "${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
gcrt0.o: crt0.c
${COMPILE.c} -DMCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
gcrt0.o: ${SRCS}
@echo "${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
scrt0.o: crt0.c
${COMPILE.c} -DSCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
scrt0.o: ${SRCS}
@echo "${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
install:
install ${COPY} -o ${BINOWN} -g ${BINGRP} -m 444 ${OBJS} \
${DESTDIR}/usr/lib
depend lint tags:
.if make(depend)
CPPFLAGS+= -DDYNAMIC
.endif
afterdepend: .depend
@(TMP=/tmp/_depend$$$$; \
sed -e 's/^\([^\.]*\).o[ ]*:/\1.o g\1.o s\1.o:/' \
< .depend > $$TMP; \
mv $$TMP .depend)
.include <bsd.prog.mk>

View File

@ -1,31 +1,42 @@
# from: @(#)Makefile 5.6 (Berkeley) 5/22/91
# $Id: Makefile,v 1.6 1995/06/05 01:57:17 pk Exp $
# from: @(#)Makefile 5.5 (Berkeley) 5/21/91
# $Id: Makefile,v 1.7 1995/09/29 11:23:18 pk Exp $
CFLAGS+= -DLIBC_SCCS -I${.CURDIR}/..
OBJS= crt0.o gcrt0.o scrt0.o
CLEANFILES+= core a.out
SRCS= crt0.c
all: ${OBJS}
crt0.o: crt0.c
${COMPILE.c} -DCRT0 -DDYNAMIC ${.ALLSRC}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
crt0.o: ${SRCS}
@echo "${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
gcrt0.o: crt0.c
${COMPILE.c} -DMCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
gcrt0.o: ${SRCS}
@echo "${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
scrt0.o: crt0.c
${COMPILE.c} -DSCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
scrt0.o: ${SRCS}
@echo "${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
install:
install ${COPY} -o ${BINOWN} -g ${BINGRP} -m 444 ${OBJS} \
${DESTDIR}/usr/lib
depend lint tags:
.if make(depend)
CPPFLAGS+= -DDYNAMIC
.endif
afterdepend: .depend
@(TMP=/tmp/_depend$$$$; \
sed -e 's/^\([^\.]*\).o[ ]*:/\1.o g\1.o s\1.o:/' \
< .depend > $$TMP; \
mv $$TMP .depend)
.include <bsd.prog.mk>

View File

@ -1,32 +1,42 @@
# from: @(#)Makefile 5.6 (Berkeley) 5/22/91
# $Id: Makefile,v 1.7 1995/06/05 01:57:24 pk Exp $
# from: @(#)Makefile 5.5 (Berkeley) 5/21/91
# $Id: Makefile,v 1.8 1995/09/29 11:23:20 pk Exp $
CFLAGS+= -DLIBC_SCCS
CFLAGS+= -I${.CURDIR}/..
CFLAGS+= -DLIBC_SCCS -I${.CURDIR}/..
OBJS= crt0.o gcrt0.o scrt0.o
CLEANFILES+= core a.out
SRCS= crt0.c
all: ${OBJS}
crt0.o: crt0.c
${COMPILE.c} -DCRT0 -DDYNAMIC ${.ALLSRC}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
crt0.o: ${SRCS}
@echo "${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
gcrt0.o: crt0.c
${COMPILE.c} -DMCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
gcrt0.o: ${SRCS}
@echo "${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
scrt0.o: crt0.c
${COMPILE.c} -DSCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
scrt0.o: ${SRCS}
@echo "${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
install:
install ${COPY} -o ${BINOWN} -g ${BINGRP} -m 444 ${OBJS} \
${DESTDIR}/usr/lib
depend lint tags:
.if make(depend)
CPPFLAGS+= -DDYNAMIC
.endif
afterdepend: .depend
@(TMP=/tmp/_depend$$$$; \
sed -e 's/^\([^\.]*\).o[ ]*:/\1.o g\1.o s\1.o:/' \
< .depend > $$TMP; \
mv $$TMP .depend)
.include <bsd.prog.mk>

View File

@ -1,31 +1,42 @@
# from: @(#)Makefile 5.5 (Berkeley) 5/21/91
# $Id: Makefile,v 1.7 1995/06/05 01:57:31 pk Exp $
# $Id: Makefile,v 1.8 1995/09/29 11:23:21 pk Exp $
CFLAGS+= -DLIBC_SCCS -I${.CURDIR}/..
OBJS= crt0.o gcrt0.o scrt0.o
CLEANFILES+= core a.out
SRCS= crt0.c
all: ${OBJS}
crt0.o: crt0.c
${COMPILE.c} -DCRT0 -DDYNAMIC ${.ALLSRC}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
crt0.o: ${SRCS}
@echo "${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DCRT0 -DDYNAMIC ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
gcrt0.o: crt0.c
${COMPILE.c} -DMCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
gcrt0.o: ${SRCS}
@echo "${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DMCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
scrt0.o: crt0.c
${COMPILE.c} -DSCRT0 ${.ALLSRC} -o ${.TARGET}
${LD} -x -r ${.TARGET}
mv a.out ${.TARGET}
scrt0.o: ${SRCS}
@echo "${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}"
@${COMPILE.c} -DSCRT0 ${.CURDIR}/${SRCS} -o ${.TARGET}.o
@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
@rm -f ${.TARGET}.o
install:
install ${COPY} -o ${BINOWN} -g ${BINGRP} -m 444 ${OBJS} \
${DESTDIR}/usr/lib
depend lint tags:
.if make(depend)
CPPFLAGS+= -DDYNAMIC
.endif
afterdepend: .depend
@(TMP=/tmp/_depend$$$$; \
sed -e 's/^\([^\.]*\).o[ ]*:/\1.o g\1.o s\1.o:/' \
< .depend > $$TMP; \
mv $$TMP .depend)
.include <bsd.prog.mk>