diff options
author | jkh <jkh@FreeBSD.org> | 1994-09-16 14:30:25 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1994-09-16 14:30:25 +0000 |
commit | 7aa31544d63c08b97a4c9b329c2e33d97d17d977 (patch) | |
tree | a12ad3c3e705a4ec43a69b9e00f35a66b65f4ad6 | |
parent | f40d319a8685d1524f17f2e46cffef6bf9763224 (diff) | |
download | FreeBSD-src-7aa31544d63c08b97a4c9b329c2e33d97d17d977.zip FreeBSD-src-7aa31544d63c08b97a4c9b329c2e33d97d17d977.tar.gz |
Add support for DEBUG_FLAGS. If you say something like:
make DEBUG_FLAGS=-g2
You can compile something for debugging at debugging level 2.
It will also take care not to strip the resulting executable(s).
-rw-r--r-- | share/mk/bsd.lib.mk | 8 | ||||
-rw-r--r-- | share/mk/bsd.own.mk | 4 | ||||
-rw-r--r-- | share/mk/bsd.port.subdir.mk | 4 | ||||
-rw-r--r-- | share/mk/bsd.prog.mk | 6 | ||||
-rw-r--r-- | share/mk/bsd.subdir.mk | 4 |
5 files changed, 20 insertions, 6 deletions
diff --git a/share/mk/bsd.lib.mk b/share/mk/bsd.lib.mk index 2dad907..8d9fac5 100644 --- a/share/mk/bsd.lib.mk +++ b/share/mk/bsd.lib.mk @@ -1,5 +1,5 @@ # from: @(#)bsd.lib.mk 5.26 (Berkeley) 5/2/91 -# $Id: bsd.lib.mk,v 1.5 1994/08/26 18:58:10 wollman Exp $ +# $Id: bsd.lib.mk,v 1.6 1994/08/28 15:37:39 bde Exp $ # .if exists(${.CURDIR}/../Makefile.inc) @@ -16,6 +16,10 @@ CFLAGS+= -I${DESTDIR}/usr/include CXXINCLUDES+= -I${DESTDIR}/usr/include/${CXX} .endif +.if defined(DEBUG_FLAGS) +CFLAGS+= ${DEBUG_FLAGS} +.endif + INSTALL?= install LIBDIR?= /usr/lib LINTLIBDIR?= /usr/libdata/lint @@ -23,7 +27,9 @@ LIBGRP?= bin LIBOWN?= bin LIBMODE?= 444 +.if !defined(DEBUG_FLAGS) STRIP?= -s +.endif BINGRP?= bin BINOWN?= bin diff --git a/share/mk/bsd.own.mk b/share/mk/bsd.own.mk index dc17f18..e6ea911 100644 --- a/share/mk/bsd.own.mk +++ b/share/mk/bsd.own.mk @@ -1,10 +1,12 @@ -# $Id: bsd.own.mk,v 1.5 1994/03/19 22:02:35 jkh Exp $ +# $Id: bsd.own.mk,v 1.1 1994/08/04 21:10:08 wollman Exp $ BINGRP?= bin BINOWN?= bin BINMODE?= 555 +.if !defined(DEBUG_FLAGS) STRIP?= -s +.endif COPY?= -c diff --git a/share/mk/bsd.port.subdir.mk b/share/mk/bsd.port.subdir.mk index ef3e567..ce81a18 100644 --- a/share/mk/bsd.port.subdir.mk +++ b/share/mk/bsd.port.subdir.mk @@ -1,9 +1,11 @@ # from: @(#)bsd.subdir.mk 5.9 (Berkeley) 2/1/91 -# $Id: bsd.port.subdir.mk,v 1.3 1994/08/22 13:02:16 jkh Exp $ +# $Id: bsd.port.subdir.mk,v 1.4 1994/09/14 16:42:37 jkh Exp $ .MAIN: all +.if !defined(DEBUG_FLAGS) STRIP?= -s +.endif BINGRP?= bin BINOWN?= bin diff --git a/share/mk/bsd.prog.mk b/share/mk/bsd.prog.mk index 9d6c6573..a60a1ab 100644 --- a/share/mk/bsd.prog.mk +++ b/share/mk/bsd.prog.mk @@ -1,5 +1,5 @@ # from: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91 -# $Id: bsd.prog.mk,v 1.4 1994/08/28 15:32:10 bde Exp $ +# $Id: bsd.prog.mk,v 1.5 1994/09/11 21:28:30 rgrimes Exp $ .if exists(${.CURDIR}/../Makefile.inc) .include "${.CURDIR}/../Makefile.inc" @@ -7,13 +7,15 @@ .SUFFIXES: .out .o .c .cc .cxx .C .y .l .s .S -CFLAGS+=${COPTS} +CFLAGS+=${COPTS} ${DEBUG_FLAGS} .if defined(DESTDIR) CFLAGS+= -I${DESTDIR}/usr/include CXXINCLUDES+= -I${DESTDIR}/usr/include/${CXX} .endif +.if !defined(DEBUG_FLAGS) STRIP?= -s +.endif BINGRP?= bin BINOWN?= bin diff --git a/share/mk/bsd.subdir.mk b/share/mk/bsd.subdir.mk index 68d9c38..b712afe 100644 --- a/share/mk/bsd.subdir.mk +++ b/share/mk/bsd.subdir.mk @@ -1,9 +1,11 @@ # from: @(#)bsd.subdir.mk 5.9 (Berkeley) 2/1/91 -# $Id: bsd.subdir.mk,v 1.2 1994/08/04 21:09:26 wollman Exp $ +# $Id: bsd.subdir.mk,v 1.3 1994/08/28 15:35:30 bde Exp $ .MAIN: all +.if !defined(DEBUG_FLAGS) STRIP?= -s +.endif BINGRP?= bin BINOWN?= bin |