help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Documentation example question


From: Robert Mecklenburg
Subject: Documentation example question
Date: 16 Oct 2003 11:02:55 -0600

In the section Automatic Prerequisites the example rule uses this sed
line:

  sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < address@hidden > $@; \

I was wondering why a simpler expression wasn't used:

  sed 's,$*\.o *:,$*.o $@ :,' < address@hidden > $@; \

- The original uses \(\), but it seems to me the group value will
  always be $*

- The original uses [ :]* which doesn't seem as clear as " *:" since
  there will always be a single colon

- The original uses the g global suffix but there will only ever be
  one target per line

Is there something I've missed (portability considerations, most
likely)?

Thanks!
--
Robert





reply via email to

[Prev in Thread] Current Thread [Next in Thread]