mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-02-23 13:21:43 +08:00
Allow initialization functions in .y files
If you add an initialization function to a .y file, it will not show up in init.c, because if the yacc output is in the build tree, it won't be found. This patch changes the Makefile to be more robust in this situation.
This commit is contained in:
parent
6bc4d69d3d
commit
d1587e198f
@ -2177,7 +2177,9 @@ INIT_FILES = \
|
||||
init.c: stamp-init; @true
|
||||
stamp-init: $(INIT_FILES) config.status $(srcdir)/make-init-c
|
||||
$(ECHO_INIT_C)
|
||||
$(SILENCE) $(srcdir)/make-init-c $(addprefix $(srcdir)/,$(INIT_FILES)) > init.c-tmp
|
||||
$(SILENCE) $(srcdir)/make-init-c \
|
||||
$(filter-out config.status $(srcdir)/make-init-c,$^) \
|
||||
> init.c-tmp
|
||||
$(SILENCE) $(SHELL) $(srcdir)/../move-if-change init.c-tmp init.c
|
||||
$(SILENCE) echo stamp > stamp-init
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user