From c49b9a97559d2009e9076e063b2e9acbc13fb9ef Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Sat, 14 Feb 2015 14:59:30 -0600 Subject: Make egrep and fgrep build standalone. --- toys/posix/grep.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'toys/posix') diff --git a/toys/posix/grep.c b/toys/posix/grep.c index 18a27e3e..61df08ea 100644 --- a/toys/posix/grep.c +++ b/toys/posix/grep.c @@ -5,8 +5,8 @@ * See http://pubs.opengroup.org/onlinepubs/9699919799/utilities/grep.html USE_GREP(NEWTOY(grep, "ZzEFHabhinorsvwclqe*f*m#x[!wx][!EFw]", TOYFLAG_BIN)) -USE_GREP(OLDTOY(egrep, grep, TOYFLAG_BIN)) -USE_GREP(OLDTOY(fgrep, grep, TOYFLAG_BIN)) +USE_EGREP(OLDTOY(egrep, grep, TOYFLAG_BIN)) +USE_FGREP(OLDTOY(fgrep, grep, TOYFLAG_BIN)) config GREP bool "grep" @@ -36,6 +36,16 @@ config GREP output prefix (default: filename if checking more than 1 file) -H force filename -b byte offset of match -h hide filename -n line number of match + +config EGREP + bool + default y + depends on GREP + +config FGREP + bool + default y + depends on GREP */ #define FOR_grep -- cgit v1.2.3