This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: sed command garbled when generating macro_list on Solaris
- From: Andreas Schwab <schwab at suse dot de>
- To: Paul Eggert <eggert at CS dot UCLA dot EDU>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 20 Mar 2006 20:04:35 +0100
- Subject: Re: sed command garbled when generating macro_list on Solaris
- References: <87zmjlotn9.fsf@penguin.cs.ucla.edu>
Paul Eggert <eggert@CS.UCLA.EDU> writes:
> --- gcc/Makefile.in-4.1.0 2006-02-16 07:23:24.000000000 -0800
> +++ gcc/Makefile.in 2006-03-19 22:13:05.101697000 -0800
> @@ -3146,8 +3146,7 @@ install-gcc-tooldir:
> macro_list: s-macro_list; @true
> s-macro_list : $(GCC_PASSES)
> echo | $(GCC_FOR_TARGET) -E -dM - | \
> - sed -n 's/^#define \([^_][a-zA-Z0-9_]*\).*/\1/p ; \
> - s/^#define \(_[^_A-Z][a-zA-Z0-9_]*\).*/\1/p' | \
> + sed -n 's/^#define \([^_][a-zA-Z0-9_]*\).*/\1/p; s/^#define \(_[^_A-Z][a-zA-Z0-9_]*\).*/\1/p' | \
Would it be portable to use multiple -e options? That way the long line
could be avoided.
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."