summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2012-05-19 18:05:00 +0000
committermarcel <marcel@FreeBSD.org>2012-05-19 18:05:00 +0000
commit23744f4adf091dc055613bde36a09cfd90bcdd6c (patch)
tree235104bc59ab252f904970051992881db1df9ceb
parentc2132f894f2faf5bf926c486b5dc392749576312 (diff)
downloadFreeBSD-src-23744f4adf091dc055613bde36a09cfd90bcdd6c.zip
FreeBSD-src-23744f4adf091dc055613bde36a09cfd90bcdd6c.tar.gz
Add build opton MK_LS_COLORS to control whether ls(1) supports colors
(and thus needs to depend on libtermcap). Embedded systems may not want or need colors. Obtained from: Juniper Networks, Inc.
-rw-r--r--bin/ls/Makefile5
-rw-r--r--share/mk/bsd.own.mk1
2 files changed, 5 insertions, 1 deletions
diff --git a/bin/ls/Makefile b/bin/ls/Makefile
index 2af1203..4d02a7e 100644
--- a/bin/ls/Makefile
+++ b/bin/ls/Makefile
@@ -1,12 +1,15 @@
# @(#)Makefile 8.1 (Berkeley) 6/2/93
# $FreeBSD$
+.include <bsd.own.mk>
+
PROG= ls
SRCS= cmp.c ls.c print.c util.c
DPADD= ${LIBUTIL}
LDADD= -lutil
-.if !defined(RELEASE_CRUNCH)
+.if !defined(RELEASE_CRUNCH) && \
+ ${MK_LS_COLORS} != no
CFLAGS+= -DCOLORLS
DPADD+= ${LIBTERMCAP}
LDADD+= -ltermcap
diff --git a/share/mk/bsd.own.mk b/share/mk/bsd.own.mk
index 2da997b..924e9ce 100644
--- a/share/mk/bsd.own.mk
+++ b/share/mk/bsd.own.mk
@@ -367,6 +367,7 @@ __DEFAULT_YES_OPTIONS = \
LOCALES \
LOCATE \
LPR \
+ LS_COLORS \
MAIL \
MAILWRAPPER \
MAKE \
OpenPOWER on IntegriCloud