Print this page
8858 /usr/bin/grep doesn't support -E option
4580 /usr/bin/grep can't handle multibyte characters
8929 8868 tests are not delivered with system/test/utiltest
8860 Example in grep(1) is incorrect
Reviewed by: Peter Tribble <peter.tribble@gmail.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Yuri Pankov <yuripv@gmx.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/grep/Makefile
          +++ new/usr/src/cmd/grep/Makefile
↓ open down ↓ 12 lines elided ↑ open up ↑
  13   13  #
  14   14  # When distributing Covered Code, include this CDDL HEADER in each
  15   15  # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16   16  # If applicable, add the following below this CDDL HEADER, with the
  17   17  # fields enclosed by brackets "[]" replaced with your own identifying
  18   18  # information: Portions Copyright [yyyy] [name of copyright owner]
  19   19  #
  20   20  # CDDL HEADER END
  21   21  #
  22   22  #
  23      -#ident  "%Z%%M% %I%     %E% SMI"
  24      -#
  25      -# Copyright (c) 1989,1996, by Sun Microsystems, Inc.
  26      -# All rights reserved.
       23 +# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
       24 +# Use is subject to license terms.
  27   25  #
  28   26  
  29      -PROG= grep 
       27 +PROG= grep
       28 +FFILE= fgrep
       29 +EFILE= egrep
  30   30  
  31   31  include ../Makefile.cmd
  32   32  
       33 +CERRWARN += -_gcc=-Wno-parentheses
       34 +CERRWARN += -_gcc=-Wno-uninitialized
       35 +
       36 +ROOTXPG4LINKS = $(ROOTXPG4BIN)/$(FFILE) $(ROOTXPG4BIN)/$(EFILE) $(ROOTXPG4BIN)/$(PROG)
       37 +ROOTLINKS = $(ROOTBIN)/$(FFILE) $(ROOTBIN)/$(EFILE)
       38 +
       39 +CFLAGS += $(CCVERBOSE)
  33   40  CPPFLAGS += -D_FILE_OFFSET_BITS=64
  34      -LDLIBS += -lgen
  35      -XGETFLAGS += -a -x grep.xcl
  36   41  
       42 +POFILE= grep_xpg4.po
       43 +POFILES= grep.po
  37   44  
  38   45  .KEEP_STATE:
  39   46  
  40      -all: $(PROG) 
       47 +all: $(PROG)
       48 +
       49 +install: all $(ROOTPROG) $(ROOTLINKS) $(ROOTXPG4LINKS)
       50 +
       51 +$(ROOTLINKS):   $(ROOTPROG)
       52 +        -$(RM) $@
       53 +        -$(LN) $(ROOTPROG) $@
       54 +
       55 +$(ROOTXPG4LINKS):       $(ROOTPROG)
       56 +        -$(RM) $@
       57 +        -$(SYMLINK) ../../bin/grep $@
       58 +
       59 +$(POFILE): $(POFILES)
       60 +        $(RM) $@
       61 +        $(CP) $(POFILES) $@
       62 +
       63 +# Make the links locally for test purposes
       64 +test:   $(FFILE) $(EFILE)
       65 +
       66 +$(FFILE):      $(PROG)
       67 +                @$(RM) $(FFILE); $(LN) $(PROG) $(FFILE)
  41   68  
  42      -install: all $(ROOTPROG)
       69 +$(EFILE):      $(PROG)
       70 +                @$(RM) $(EFILE); $(LN) $(PROG) $(EFILE)
  43   71  
  44   72  clean:
  45   73  
  46   74  lint:   lint_PROG
  47   75  
  48   76  include ../Makefile.targ
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX