aboutsummaryrefslogtreecommitdiff
path: root/gas/configure
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2021-02-23 21:54:25 +1030
committerAlan Modra <amodra@gmail.com>2021-02-24 10:13:00 +1030
commit55add51eef6b4f89d44e1a6753d4dd926cab70c7 (patch)
treeddd4d9c9242b7d4d9d7a6eb69bfb43a3fa5cb45b /gas/configure
parentc42c71a1527dd70417d3966dce7ba9edbcf4bdb4 (diff)
downloadgdb-55add51eef6b4f89d44e1a6753d4dd926cab70c7.zip
gdb-55add51eef6b4f89d44e1a6753d4dd926cab70c7.tar.gz
gdb-55add51eef6b4f89d44e1a6753d4dd926cab70c7.tar.bz2
PR23691, gas .y files vs. automatic make dependencies
A number of targets, bfin, rl78, rx, can show odd failures when bfd/reloc.c changes BFD_RELOC_* enum values, if recompiling over a build dir with existing objects. The problem is caused by bfin-parse.o and similar not being recompiled and so using stale BFD_RELOC_* values. This isn't fixed by making bfin-parse.c depend on bfd/reloc.c, which isn't necessary anyway. bfin-parse.o should have been recompiled due to bfd/bfd.h changing when extracted bfd/reloc.c BFD_RELOC_* values change, but that wasn't happening. The problem is that automake generates a makefile that loads gas/config/.deps/ dependency file for objects with corresponding sources mentioned in EXTRA_as_new_SOURCES. Unless we want to mess around generating explicit dependencies, I think that mean moving some object files to the build gas/config/. This patch does that, removing some hacks for m68k-parse.c that should no longer be necessary, and removes some rules that catered to old bison producing code that triggers compiler warnings. PR 23691 * Makefile.am (TARGET_CPU_CFILES): Split off config/xtensa-relax.c.. (TARGET_CPU_HFILES): ..and config/xtensa-relax.h.. (TARGET_EXTRA_FILES): ..to here. Add config/bfin-lex-wrapper.c, and use alongside TARGET_CPU_CFILES. (EXTRA_DIST): Update location of generated .c files. (config/m68k-parse.c): New rule replacing m68k-parse.c rule. (config/bfin-parse.c, config/rl78-parse.cm config/rx-parse.c), (config/bfin-lex.c, config/bfin-lex-wrapper.@OBJEXT@): Similarly. (itbl-lex-wrapper.@OBJEXT@): Simplify to just the needed dependencies. (itbl-parse.@OBJEXT@): Delete rule using NO_WERROR. (itbl-parse.c, itbl-parse.h): Tidy. * config/bfin-lex-wrapper.c: Include config/bfin-lex.c. * config/bfin-lex.l: Include config/bfin-parse.h. * configure.ac (extra_objects): Move object files corresponding to .y and .l files now in config/ to config/. * Makefile.in: Regenerate. * configure: Regenerate. * po/POTFILES.in: Regenerate.
Diffstat (limited to 'gas/configure')
-rwxr-xr-xgas/configure8
1 files changed, 4 insertions, 4 deletions
diff --git a/gas/configure b/gas/configure
index d253147..5965f2b 100755
--- a/gas/configure
+++ b/gas/configure
@@ -12893,7 +12893,7 @@ _ACEOF
case ${cpu_type} in
bfin)
- for f in bfin-parse.o bfin-lex-wrapper.o; do
+ for f in config/bfin-parse.o config/bfin-lex-wrapper.o; do
case " $extra_objects " in
*" $f "*) ;;
*) extra_objects="$extra_objects $f" ;;
@@ -12922,7 +12922,7 @@ _ACEOF
using_cgen=yes
;;
m68k)
- f=m68k-parse.o
+ f=config/m68k-parse.o
case " $extra_objects " in
*" $f "*) ;;
*) extra_objects="$extra_objects $f" ;;
@@ -13140,7 +13140,7 @@ $as_echo "$with_priv_spec" >&6; }
;;
rl78)
- f=rl78-parse.o
+ f=config/rl78-parse.o
case " $extra_objects " in
*" $f "*) ;;
*) extra_objects="$extra_objects $f" ;;
@@ -13148,7 +13148,7 @@ $as_echo "$with_priv_spec" >&6; }
;;
rx)
- f=rx-parse.o
+ f=config/rx-parse.o
case " $extra_objects " in
*" $f "*) ;;
*) extra_objects="$extra_objects $f" ;;