From 871ec8960924f477379d520fd477c1958cad4e33 Mon Sep 17 00:00:00 2001 From: Joern Rennecke Date: Mon, 5 Jul 2004 13:35:44 +0000 Subject: [PATCH] 2004-06-30 Andrew Stubbs bfd: * elf32-sh.c: Include ../opcodes/sh-opc.h . * Makefile.am: Ran make dep-am . * Makefile.in: Ran make dep-in . gas: * config/tc-sh.c (md_assemble): Change isspace to ISSPACE. (md_parse_option): Remove redundant -isa testing. Make bfd_arch variable const. (md_show_usage): Make bfd_arch variable const. --- bfd/ChangeLog | 6 ++++++ bfd/Makefile.am | 9 ++++++--- bfd/Makefile.in | 13 ++++++------- bfd/elf32-sh.c | 1 + gas/ChangeLog | 8 ++++++++ gas/config/tc-sh.c | 19 +++++-------------- 6 files changed, 32 insertions(+), 24 deletions(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 198494653e9..ad7b8a4119e 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,9 @@ +2004-07-05 Andrew Stubbs + + * elf32-sh.c: Include ../opcodes/sh-opc.h . + * Makefile.am: Ran make dep-am . + * Makefile.in: Ran make dep-in . + 2004-07-03 Aaron W. LaFramboise * cofflink.c (_bfd_coff_generic_relocate_section): Resolve PE weak diff --git a/bfd/Makefile.am b/bfd/Makefile.am index 076eec2d82c..c7ef7d7af94 100644 --- a/bfd/Makefile.am +++ b/bfd/Makefile.am @@ -908,7 +908,8 @@ syms.lo: syms.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \ $(INCDIR)/bfdlink.h $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def targets.lo: targets.c $(INCDIR)/filenames.h $(INCDIR)/fnmatch.h \ targmatch.h -hash.lo: hash.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h $(INCDIR)/libiberty.h +hash.lo: hash.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h \ + $(INCDIR)/libiberty.h linker.lo: linker.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ genlink.h srec.lo: srec.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \ @@ -1294,7 +1295,8 @@ elf32-sh64.lo: elf32-sh64.c $(INCDIR)/filenames.h elf-bfd.h \ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \ $(INCDIR)/bfdlink.h $(srcdir)/../opcodes/sh64-opc.h \ elf32-sh64.h elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \ - $(INCDIR)/libiberty.h elf32-target.h + $(INCDIR)/libiberty.h $(srcdir)/../opcodes/sh-opc.h \ + elf32-target.h elf32-sh64-com.lo: elf32-sh64-com.c $(INCDIR)/filenames.h \ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h \ @@ -1306,7 +1308,8 @@ elf32-s390.lo: elf32-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ elf32-sh.lo: elf32-sh.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \ $(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \ - $(INCDIR)/libiberty.h elf32-target.h + $(INCDIR)/libiberty.h $(srcdir)/../opcodes/sh-opc.h \ + elf32-target.h elf32-sparc.lo: elf32-sparc.c $(INCDIR)/filenames.h \ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sparc.h \ diff --git a/bfd/Makefile.in b/bfd/Makefile.in index 4795750de42..240e5fd7423 100644 --- a/bfd/Makefile.in +++ b/bfd/Makefile.in @@ -1441,7 +1441,8 @@ syms.lo: syms.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \ $(INCDIR)/bfdlink.h $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def targets.lo: targets.c $(INCDIR)/filenames.h $(INCDIR)/fnmatch.h \ targmatch.h -hash.lo: hash.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h $(INCDIR)/libiberty.h +hash.lo: hash.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h \ + $(INCDIR)/libiberty.h linker.lo: linker.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ genlink.h srec.lo: srec.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \ @@ -1827,7 +1828,8 @@ elf32-sh64.lo: elf32-sh64.c $(INCDIR)/filenames.h elf-bfd.h \ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \ $(INCDIR)/bfdlink.h $(srcdir)/../opcodes/sh64-opc.h \ elf32-sh64.h elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \ - $(INCDIR)/libiberty.h elf32-target.h + $(INCDIR)/libiberty.h $(srcdir)/../opcodes/sh-opc.h \ + elf32-target.h elf32-sh64-com.lo: elf32-sh64-com.c $(INCDIR)/filenames.h \ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h \ @@ -1839,7 +1841,8 @@ elf32-s390.lo: elf32-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ elf32-sh.lo: elf32-sh.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \ $(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \ - $(INCDIR)/libiberty.h elf32-target.h + $(INCDIR)/libiberty.h $(srcdir)/../opcodes/sh-opc.h \ + elf32-target.h elf32-sparc.lo: elf32-sparc.c $(INCDIR)/filenames.h \ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sparc.h \ @@ -2186,7 +2189,3 @@ pepigen.lo: pepigen.c $(INCDIR)/filenames.h $(INCDIR)/coff/internal.h \ $(INCDIR)/coff/ia64.h $(INCDIR)/coff/external.h $(INCDIR)/coff/pe.h \ libcoff.h $(INCDIR)/bfdlink.h libpei.h # IF YOU PUT ANYTHING HERE IT WILL GO AWAY - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/bfd/elf32-sh.c b/bfd/elf32-sh.c index fb45aebc55e..e1d7e1a5050 100644 --- a/bfd/elf32-sh.c +++ b/bfd/elf32-sh.c @@ -26,6 +26,7 @@ #include "elf-bfd.h" #include "elf/sh.h" #include "libiberty.h" +#include "../opcodes/sh-opc.h" static bfd_reloc_status_type sh_elf_reloc (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **); diff --git a/gas/ChangeLog b/gas/ChangeLog index 86101d4fd42..6c1c22f75ec 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,11 @@ +2004-07-05 Andrew Stubbs + + gas: + * config/tc-sh.c (md_assemble): Change isspace to ISSPACE. + (md_parse_option): Remove redundant -isa testing. + Make bfd_arch variable const. + (md_show_usage): Make bfd_arch variable const. + 2004-07-03 James E Wilson * config/tc-ia64.c (emit_one_bundle): Check and set insn_addr. diff --git a/gas/config/tc-sh.c b/gas/config/tc-sh.c index a7e60ea9d0b..f33925bb5e4 100644 --- a/gas/config/tc-sh.c +++ b/gas/config/tc-sh.c @@ -2631,11 +2631,11 @@ md_assemble (char *str) int found = 0; /* identify opcode in string */ - while (isspace (*name)) + while (ISSPACE (*name)) { name++; } - while (!isspace (name[name_length])) + while (!ISSPACE (name[name_length])) { name_length++; } @@ -2945,15 +2945,7 @@ md_parse_option (int c, char *arg ATTRIBUTE_UNUSED) break; case OPTION_ISA: - if (strcasecmp (arg, "sh4") == 0) - preset_target_arch = arch_sh4; - else if (strcasecmp (arg, "sh4-nofpu") == 0) - preset_target_arch = arch_sh4_nofpu; - else if (strcasecmp (arg, "sh4-nommu-nofpu") == 0) - preset_target_arch = arch_sh4_nommu_nofpu; - else if (strcasecmp (arg, "sh4a") == 0) - preset_target_arch = arch_sh4a; - else if (strcasecmp (arg, "dsp") == 0) + if (strcasecmp (arg, "dsp") == 0) preset_target_arch = arch_sh1_up & ~(arch_sh_sp_fpu|arch_sh_dp_fpu); else if (strcasecmp (arg, "fp") == 0) preset_target_arch = arch_sh1_up & ~arch_sh_has_dsp; @@ -2978,8 +2970,7 @@ md_parse_option (int c, char *arg ATTRIBUTE_UNUSED) else { extern const bfd_arch_info_type bfd_sh_arch; - extern unsigned int sh_ef_archset_table[]; - bfd_arch_info_type *bfd_arch = &bfd_sh_arch; + bfd_arch_info_type const *bfd_arch = &bfd_sh_arch; preset_target_arch = 0; for (; bfd_arch; bfd_arch=bfd_arch->next) { @@ -3068,7 +3059,7 @@ SH options:\n\ | fp")); { extern const bfd_arch_info_type bfd_sh_arch; - bfd_arch_info_type *bfd_arch = &bfd_sh_arch; + bfd_arch_info_type const *bfd_arch = &bfd_sh_arch; for (; bfd_arch; bfd_arch=bfd_arch->next) if (bfd_arch->mach != bfd_mach_sh5) { -- 2.30.2