diff options
author | Jan Beulich <jbeulich@novell.com> | 2018-07-19 08:28:29 +0200 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2018-07-19 08:28:29 +0200 |
commit | c30be56ebf7989e36f5c7d4a703cb00f7d4ca2ab (patch) | |
tree | 6f5a4a23c2d56878e002fe9b566dc9dc81f06503 /opcodes/Makefile.am | |
parent | Automatic date update in version.in (diff) | |
download | binutils-gdb-c30be56ebf7989e36f5c7d4a703cb00f7d4ca2ab.tar.gz binutils-gdb-c30be56ebf7989e36f5c7d4a703cb00f7d4ca2ab.tar.bz2 binutils-gdb-c30be56ebf7989e36f5c7d4a703cb00f7d4ca2ab.zip |
x86: pre-process opcodes table before parsing
Instead of expanding macro-like constructs in i386-gen, have the C pre-
processor do this for us. Besides being a prerequisite for the next
template folding steps, this also paves the way for removing various
hidden dependencies between #define-s in i386-opc.h and plain literal
numbers used in i386-opc.tbl.
The #undef of None is solely to leave the generated i386-tbl.h entirely
unchanged.
Diffstat (limited to 'opcodes/Makefile.am')
-rw-r--r-- | opcodes/Makefile.am | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/opcodes/Makefile.am b/opcodes/Makefile.am index 11d3f76ac30..a571f2b158a 100644 --- a/opcodes/Makefile.am +++ b/opcodes/Makefile.am @@ -544,8 +544,10 @@ i386-gen.o: i386-gen.c i386-opc.h $(srcdir)/../include/opcode/i386.h \ $(srcdir)/i386-tbl.h: $(srcdir)/i386-init.h @echo $@ -$(srcdir)/i386-init.h: @MAINT@ i386-gen$(EXEEXT_FOR_BUILD) i386-opc.tbl i386-reg.tbl - ./i386-gen$(EXEEXT_FOR_BUILD) --srcdir $(srcdir) +$(srcdir)/i386-init.h: @MAINT@ i386-gen$(EXEEXT_FOR_BUILD) i386-opc.tbl i386-reg.tbl i386-opc.h + $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) - \ + < $(srcdir)/i386-opc.tbl \ + | ./i386-gen$(EXEEXT_FOR_BUILD) --srcdir $(srcdir) i386-opc.lo: $(srcdir)/i386-tbl.h |