aboutsummaryrefslogtreecommitdiff
path: root/gdb/Makefile.in
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-07-02 07:29:03 -0600
committerTom Tromey <tom@tromey.com>2018-07-09 08:03:49 -0600
commite5fd1493fd9c2d8d55fd15b9bd6539781ee56209 (patch)
treea7e9a7e94569c65acd4c59bf047e5dcfa511b2f6 /gdb/Makefile.in
parent981e0c0c1aabcd78409184c79e8f88b5de918e38 (diff)
downloadfsf-binutils-gdb-e5fd1493fd9c2d8d55fd15b9bd6539781ee56209.zip
fsf-binutils-gdb-e5fd1493fd9c2d8d55fd15b9bd6539781ee56209.tar.gz
fsf-binutils-gdb-e5fd1493fd9c2d8d55fd15b9bd6539781ee56209.tar.bz2
Minimize yacc and lex output
This minimizes the "make" output from the yacc and lex rules, following the same technique as the rest of the Makefile. The lex rule had a special case to deal with the situation where flex is not available. I don't think this is needed, so I removed it. If flex is truly unavailable, the person building gdb can simply "touch" the output file. gdb/ChangeLog 2018-07-09 Tom Tromey <tom@tromey.com> * Makefile.in (%.c: %.y): Use ECHO_YACC. (%.c: %.l): Use ECHO_LEX. Just fail if flex not available. * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
Diffstat (limited to 'gdb/Makefile.in')
-rw-r--r--gdb/Makefile.in17
1 files changed, 5 insertions, 12 deletions
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 047d06b..36d2c44 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -2477,9 +2477,9 @@ po/$(PACKAGE).pot: force
# Makefile.in, but that was a pretty big annoyance.
%.c: %.y
- $(SHELL) $(YLWRAP) $< y.tab.c $@.tmp -- $(YACC) $(YFLAGS) \
- || (rm -f $@.tmp; false)
- sed -e '/extern.*malloc/d' \
+ $(ECHO_YACC) $(SHELL) $(YLWRAP) $< y.tab.c $@.tmp -- \
+ $(YACC) $(YFLAGS) || (rm -f $@.tmp; false)
+ @sed -e '/extern.*malloc/d' \
-e '/extern.*realloc/d' \
-e '/extern.*free/d' \
-e '/include.*malloc.h/d' \
@@ -2493,8 +2493,7 @@ po/$(PACKAGE).pot: force
rm -f $@.tmp && \
mv $@.new $@
%.c: %.l
- if [ "$(FLEX)" ] && $(FLEX) --version >/dev/null 2>&1; then \
- $(FLEX) -t $< \
+ $(ECHO_LEX) $(FLEX) -t $< \
| sed -e '/extern.*malloc/d' \
-e '/extern.*realloc/d' \
-e '/extern.*free/d' \
@@ -2505,13 +2504,7 @@ po/$(PACKAGE).pot: force
-e 's/\([ \t;,(]\)free$$/\1xfree/g' \
-e 's/yy_flex_xrealloc/yyxrealloc/g' \
> $@.new && \
- mv $@.new $@; \
- elif [ -f $@ ]; then \
- echo "Warning: $*.c older than $*.l and flex not available."; \
- else \
- echo "$@ missing and flex not available."; \
- false; \
- fi
+ mv $@.new $@
.PRECIOUS: ada-lex.c