[BACK]Return to bsd.prog.mk CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / share / mk

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/share/mk/bsd.prog.mk between version 1.67 and 1.98

version 1.67, 1997/03/29 08:02:53 version 1.98, 1999/02/04 11:58:31
Line 1 
Line 1 
 #       $NetBSD$  #       $NetBSD$
 #       @(#)bsd.prog.mk 8.2 (Berkeley) 4/2/94  #       @(#)bsd.prog.mk 8.2 (Berkeley) 4/2/94
   .if !target(__initialized__)
 .if exists(${.CURDIR}/../Makefile.inc)  .if exists(${.CURDIR}/../Makefile.inc)
 .include "${.CURDIR}/../Makefile.inc"  .include "${.CURDIR}/../Makefile.inc"
 .endif  .endif
 .include <bsd.own.mk>  .include <bsd.own.mk>
   .include <bsd.obj.mk>
   .MAIN:          all
 .SUFFIXES: .out .o .c .cc .C .y .l .s .8 .7 .6 .5 .4 .3 .2 .1 .0  .PHONY:         cleanprog proginstall scriptsinstall
   realinstall:    proginstall scriptsinstall
   clean cleandir distclean: cleanprog
 CFLAGS+=        ${COPTS}  CFLAGS+=        ${COPTS}
   # ELF platforms depend on crtbegin.o and crtend.o
   .if (${OBJECT_FMT} == "ELF")
   LIBCRTBEGIN?=   ${DESTDIR}/usr/lib/crtbegin.o
   LIBCRTEND?=     ${DESTDIR}/usr/lib/crtend.o
 LIBCRT0?=       ${DESTDIR}/usr/lib/crt0.o  LIBCRT0?=       ${DESTDIR}/usr/lib/crt0.o
   LIBBFD?=        ${DESTDIR}/usr/lib/libbfd.a
   LIBBZ2?=        ${DESTDIR}/usr/lib/libbz2.a
 LIBC?=          ${DESTDIR}/usr/lib/libc.a  LIBC?=          ${DESTDIR}/usr/lib/libc.a
 LIBC_PIC?=      ${DESTDIR}/usr/lib/libc_pic.a  LIBC_PIC?=      ${DESTDIR}/usr/lib/libc_pic.a
 LIBCOMPAT?=     ${DESTDIR}/usr/lib/libcompat.a  LIBCOMPAT?=     ${DESTDIR}/usr/lib/libcompat.a
Line 28  LIBKVM?= ${DESTDIR}/usr/lib/libkvm.a
Line 46  LIBKVM?= ${DESTDIR}/usr/lib/libkvm.a
 LIBL?=          ${DESTDIR}/usr/lib/libl.a  LIBL?=          ${DESTDIR}/usr/lib/libl.a
 LIBM?=          ${DESTDIR}/usr/lib/libm.a  LIBM?=          ${DESTDIR}/usr/lib/libm.a
 LIBMP?=         ${DESTDIR}/usr/lib/libmp.a  LIBMP?=         ${DESTDIR}/usr/lib/libmp.a
   LIBNTP?=        ${DESTDIR}/usr/lib/libntp.a
   LIBOBJC?=       ${DESTDIR}/usr/lib/libobjc.a
 LIBPC?=         ${DESTDIR}/usr/lib/libpc.a  LIBPC?=         ${DESTDIR}/usr/lib/libpc.a
 LIBPCAP?=       ${DESTDIR}/usr/lib/libpcap.a  LIBPCAP?=       ${DESTDIR}/usr/lib/libpcap.a
 LIBPLOT?=       ${DESTDIR}/usr/lib/libplot.a  LIBPLOT?=       ${DESTDIR}/usr/lib/libplot.a
   LIBPOSIX?=      ${DESTDIR}/usr/lib/libposix.a
 LIBRESOLV?=     ${DESTDIR}/usr/lib/libresolv.a  LIBRESOLV?=     ${DESTDIR}/usr/lib/libresolv.a
 LIBRPCSVC?=     ${DESTDIR}/usr/lib/librpcsvc.a  LIBRPCSVC?=     ${DESTDIR}/usr/lib/librpcsvc.a
 LIBSKEY?=       ${DESTDIR}/usr/lib/libskey.a  LIBSKEY?=       ${DESTDIR}/usr/lib/libskey.a
Line 63  CLEANFILES+=strings
Line 84  CLEANFILES+=strings
 .if defined(PROG)  .if defined(PROG)
 SRCS?=  ${PROG}.c  SRCS?=          ${PROG}.c
   DPSRCS+=        ${SRCS:M*.l:.l=.c} ${SRCS:M*.y:.y=.c}
   .if defined(YHEADER)
   CLEANFILES+=    ${SRCS:M*.y:.y=.h}
 .if !empty(SRCS:N*.h:N*.sh)  .if !empty(SRCS:N*.h:N*.sh)
 OBJS+=  ${SRCS:N*.h:N*.sh:R:S/$/.o/g}  OBJS+=          ${SRCS:N*.h:N*.sh:R:S/$/.o/g}
 LOBJS+= ${LSRCS:.c=.ln} ${SRCS:M*.c:.c=.ln}  LOBJS+=         ${LSRCS:.c=.ln} ${SRCS:M*.c:.c=.ln}
 .endif  .endif
 .if defined(OBJS) && !empty(OBJS)  .if defined(OBJS) && !empty(OBJS)
 .if defined(DESTDIR)  .if defined(DESTDIR)
         ${CC} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} -nostdlib -L${DESTDIR}/usr/lib ${LIBCRT0} ${OBJS} ${LDADD} -lgcc -lc -lgcc          ${CC} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} -nostdlib -L${DESTDIR}/usr/lib ${LIBCRT0} ${LIBCRTBEGIN} ${OBJS} ${LDADD} -lgcc -lc -lgcc ${LIBCRTEND}
 .else  .else
         ${CC} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${OBJS} ${LDADD}          ${CC} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${OBJS} ${LDADD}
 .endif  # defined(DESTDIR)  .endif  # defined(DESTDIR)
Line 88  MAN= ${PROG}.1
Line 117  MAN= ${PROG}.1
 .endif  # !defined(MAN)  .endif  # !defined(MAN)
 .endif  # defined(PROG)  .endif  # defined(PROG)
 .if !target(all)  all: ${PROG}
 .MAIN: all  
 all: ${PROG} _SUBDIRUSE  
 .if !target(clean)  
 cleanprog:  cleanprog:
         rm -f a.out [Ee]rrs mklog core *.core \          rm -f a.out [Ee]rrs mklog core *.core \
             ${PROG} ${OBJS} ${LOBJS} ${CLEANFILES}              ${PROG} ${OBJS} ${LOBJS} ${CLEANFILES}
 clean: _SUBDIRUSE cleanprog  
 cleandir: _SUBDIRUSE cleanprog  
 cleandir: _SUBDIRUSE clean  
 .if defined(SRCS)  .if defined(SRCS)
 afterdepend: .depend  afterdepend: .depend
         @(TMP=/tmp/_depend$$$$; \          @(TMP=/tmp/_depend$$$$; \
Line 112  afterdepend: .depend
Line 131  afterdepend: .depend
             mv $$TMP .depend)              mv $$TMP .depend)
 .endif  .endif
 .if !target(install)  .if defined(PROG) && !target(proginstall)
 .if !target(beforeinstall)  
 .if !target(afterinstall)  
 .if !target(realinstall)  
 .if defined(PROG)  
 proginstall:: ${DESTDIR}${BINDIR}/${PROGNAME}  proginstall:: ${DESTDIR}${BINDIR}/${PROGNAME}
 .if !defined(UPDATE)  .if !defined(UPDATE)
Line 132  proginstall:: ${DESTDIR}${BINDIR}/${PROG
Line 141  proginstall:: ${DESTDIR}${BINDIR}/${PROG
 .endif  .endif
         ${INSTALL} ${COPY} ${STRIP} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \          ${INSTALL} ${RENAME} ${PRESERVE} ${COPY} ${STRIPFLAG} -o ${BINOWN} \
             ${.ALLSRC} ${.TARGET}              -g ${BINGRP} -m ${BINMODE} ${.ALLSRC} ${.TARGET}
   .if !target(proginstall)
 .endif  .endif
 .if defined(SCRIPTS)  .if defined(SCRIPTS) && !target(scriptsinstall)
 .endif  .endif
 proginstall:: ${DESTDIR}${SCRIPTSDIR_${S}}/${SCRIPTSNAME_${S}}  scriptsinstall:: ${DESTDIR}${SCRIPTSDIR_${S}}/${SCRIPTSNAME_${S}}
 .if !defined(UPDATE)  .if !defined(UPDATE)
 .endif  .endif
Line 161  proginstall:: ${DESTDIR}${SCRIPTSDIR_${S
Line 175  proginstall:: ${DESTDIR}${SCRIPTSDIR_${S
 .endif  .endif
         ${INSTALL} ${COPY} -o ${SCRIPTSOWN_${S}} -g ${SCRIPTSGRP_${S}} \          ${INSTALL} ${RENAME} ${PRESERVE} ${COPY} -o ${SCRIPTSOWN_${S}} -g \
                 -m ${SCRIPTSMODE_${S}} ${.ALLSRC} ${.TARGET}              ${SCRIPTSGRP_${S}} -m ${SCRIPTSMODE_${S}} ${.ALLSRC} ${.TARGET}
 .endfor  .endfor
 .endif  .endif
 .if target(proginstall)  .if !target(scriptsinstall)
 realinstall: proginstall filesinstall  scriptsinstall::
 realinstall: filesinstall  
 .endif  .endif
 install: ${MANINSTALL} _SUBDIRUSE linksinstall  
 ${MANINSTALL}: afterinstall  
 afterinstall: realinstall  
 realinstall: beforeinstall  
 .if !target(lint)  
 lint: ${LOBJS}  lint: ${LOBJS}
 .if defined(LOBJS) && !empty(LOBJS)  .if defined(LOBJS) && !empty(LOBJS)
         @${LINT} ${LINTFLAGS} ${LDFLAGS:M-L*} ${LOBJS} ${LDADD}          ${LINT} ${LINTFLAGS} ${LDFLAGS:M-L*} ${LOBJS} ${LDADD}
 .endif  .endif
 .if !defined(NOMAN)  
 .include <bsd.man.mk>  .include <bsd.man.mk>
 .if !defined(NONLS)  
 .include <bsd.nls.mk>  .include <bsd.nls.mk>
 .include <bsd.obj.mk>  
 .include <bsd.links.mk>  
 .include <bsd.files.mk>  .include <bsd.files.mk>
 .include <bsd.inc.mk>  .include <bsd.inc.mk>
   .include <bsd.links.mk>
 .include <bsd.dep.mk>  .include <bsd.dep.mk>
 .include <bsd.subdir.mk>  
 .include <bsd.sys.mk>  .include <bsd.sys.mk>
   # Make sure all of the standard targets are defined, even if they do nothing.

Removed from v.1.67  
changed lines
  Added in v.1.98

CVSweb <webmaster@jp.NetBSD.org>