From: Geoff Levand Date: Wed, 29 May 2013 20:42:16 +0000 (-0700) Subject: test/parser: Remove gawk specifics X-Git-Tag: v1.0.0~591 X-Git-Url: https://git.ozlabs.org/?p=petitboot;a=commitdiff_plain;h=f7d58f3945a5b1325e451d3d98018ebeb7d14741 test/parser: Remove gawk specifics Remove the GNU awk specifics to allow the use of a standard awk program. Fixes build errors on older distros. Signed-off-by: Geoff Levand --- diff --git a/test/parser/Makefile.am b/test/parser/Makefile.am index af4fbd6..84ff2e1 100644 --- a/test/parser/Makefile.am +++ b/test/parser/Makefile.am @@ -66,7 +66,7 @@ $(check_PROGRAMS): LDADD += $@.embedded-config.o extract_config = $(srcdir)/extract-config.awk %.embedded-config.c: %.c $(extract_config) - gawk --file=$(extract_config) $^ > $@ + $(AWK) -f $(extract_config) $< > $@ EXTRA_DIST = $(check_DATA) $(extract_config) diff --git a/test/parser/extract-config.awk b/test/parser/extract-config.awk index e7a5b33..9c85853 100644 --- a/test/parser/extract-config.awk +++ b/test/parser/extract-config.awk @@ -2,7 +2,7 @@ BEGIN { config=0 } -/^#if\s*0\s*\/\*\s*PARSER_EMBEDDED_CONFIG/ { +/^#if[ \t]*0[ \t]*\/\*[ \t]*PARSER_EMBEDDED_CONFIG/ { config=1 print "#include " print "const char __embedded_config[] = "