version 1.36, 1994/03/24 16:11:40 |
version 1.44, 1994/06/30 05:31:21 |
|
|
# from: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91 |
# $NetBSD$ |
# $Id$ |
# @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91 |
|
|
.if exists(${.CURDIR}/../Makefile.inc) |
.if exists(${.CURDIR}/../Makefile.inc) |
.include "${.CURDIR}/../Makefile.inc" |
.include "${.CURDIR}/../Makefile.inc" |
Line 26 LIBPC?= /usr/lib/libpc.a |
|
Line 26 LIBPC?= /usr/lib/libpc.a |
|
LIBPLOT?= /usr/lib/libplot.a |
LIBPLOT?= /usr/lib/libplot.a |
LIBRESOLV?= /usr/lib/libresolv.a |
LIBRESOLV?= /usr/lib/libresolv.a |
LIBRPCSVC?= /usr/lib/librpcsvc.a |
LIBRPCSVC?= /usr/lib/librpcsvc.a |
|
LIBSKEY?= /usr/lib/libskey.a |
LIBTERMCAP?= /usr/lib/libtermcap.a |
LIBTERMCAP?= /usr/lib/libtermcap.a |
LIBUTIL?= /usr/lib/libutil.a |
LIBUTIL?= /usr/lib/libutil.a |
|
|
Line 49 CLEANFILES+=strings |
|
Line 50 CLEANFILES+=strings |
|
@rm -f x.C |
@rm -f x.C |
.endif |
.endif |
|
|
.if defined(PROG) |
|
.if defined(SRCS) |
|
|
|
OBJS+= ${SRCS:N*.h:R:S/$/.o/g} |
.if defined(PROG) |
|
SRCS?= ${PROG}.c |
|
OBJS+= ${SRCS:N*.h:N*.sh:R:S/$/.o/g} |
|
|
.if defined(LDONLY) |
.if defined(LDONLY) |
|
|
Line 66 ${PROG}: ${LIBCRT0} ${OBJS} ${LIBC} ${DP |
|
Line 67 ${PROG}: ${LIBCRT0} ${OBJS} ${LIBC} ${DP |
|
|
|
.endif |
.endif |
|
|
.else |
|
|
|
SRCS= ${PROG}.c |
|
|
|
${PROG}: ${SRCS} ${LIBC} ${DPADD} |
|
${CC} ${LDFLAGS} ${LDSTATIC} ${CFLAGS} -o ${.TARGET} ${.CURDIR}/${SRCS} ${LDADD} |
|
|
|
MKDEP= -p |
|
|
|
.endif |
|
|
|
.if !defined(MAN1) && !defined(MAN2) && !defined(MAN3) && \ |
.if !defined(MAN1) && !defined(MAN2) && !defined(MAN3) && \ |
!defined(MAN4) && !defined(MAN5) && !defined(MAN6) && \ |
!defined(MAN4) && !defined(MAN5) && !defined(MAN6) && \ |
!defined(MAN7) && !defined(MAN8) |
!defined(MAN7) && !defined(MAN8) |
|
|
.endif |
.endif |
|
|
.MAIN: all |
.MAIN: all |
all: ${PROG} |
all: ${PROG} _SUBDIRUSE |
|
|
.if !target(clean) |
.if !target(clean) |
clean: |
clean: _SUBDIRUSE |
rm -f a.out [Ee]rrs mklog core *.core ${PROG} ${OBJS} ${CLEANFILES} |
rm -f a.out [Ee]rrs mklog core *.core ${PROG} ${OBJS} ${CLEANFILES} |
.endif |
.endif |
|
|
cleandir: clean |
cleandir: _SUBDIRUSE clean |
|
|
.if !target(install) |
.if !target(install) |
.if !target(beforeinstall) |
.if !target(beforeinstall) |
|
|
${PROG} ${DESTDIR}${BINDIR} |
${PROG} ${DESTDIR}${BINDIR} |
.endif |
.endif |
.if defined(HIDEGAME) |
.if defined(HIDEGAME) |
(cd ${DESTDIR}/usr/games; rm -f ${PROG}; ln -s dm ${PROG}; \ |
(cd ${DESTDIR}/usr/games; rm -f ${PROG}; ln -s dm ${PROG}) |
chown games.bin ${PROG}) |
|
.endif |
.endif |
.endif |
.endif |
|
|
Line 134 realinstall: beforeinstall |
|
Line 123 realinstall: beforeinstall |
|
.endif |
.endif |
|
|
.if !target(lint) |
.if !target(lint) |
lint: ${SRCS} |
lint: ${SRCS} _SUBDIRUSE |
.if defined(PROG) |
.if defined(PROG) |
@${LINT} ${LINTFLAGS} ${CFLAGS} ${.ALLSRC} | more 2>&1 |
@${LINT} ${LINTFLAGS} ${CFLAGS} ${.ALLSRC} | more 2>&1 |
.endif |
.endif |