diff options
author | Pedro Alves <palves@redhat.com> | 2014-10-01 11:18:22 +0100 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2014-10-01 12:08:40 +0100 |
commit | db74e4ba014f9ee96e8c8587534811c91c4d8ebb (patch) | |
tree | 1abefa77bb59d5ca09dc4c5c22124921db16b9f5 /gdb/features | |
parent | d63f2f8402c38d106b8508f324da6a5277471a2d (diff) | |
download | gdb-db74e4ba014f9ee96e8c8587534811c91c4d8ebb.zip gdb-db74e4ba014f9ee96e8c8587534811c91c4d8ebb.tar.gz gdb-db74e4ba014f9ee96e8c8587534811c91c4d8ebb.tar.bz2 |
features/Makefile: Make 'make cfiles' default to generating all C files
This makes it easier to rebuild all GDB's generated target description
C files.
It also clarifies the comments a bit. One might think we need a GDB
configured for the particular arquitecture (--target=foo). But a
build that includes support for the target description is sufficient.
(GDB rejects target descriptions that explicitly specify the
architecture, with an <architecture> element, if the architecture is
unknown.)
Tested that "make clean-cfiles" deletes all .c files under
src/gdb/features/, and that "make cfiles" generates them all without
error, and that diffing the newly generated C files against master
comes out an empty diff.
gdb/
2014-10-01 Pedro Alves <palves@redhat.com>
* features/Makefile: Update comments.
(XMLTOC): List all xml files we build C files from.
(clean-cfiles): New rule.
Diffstat (limited to 'gdb/features')
-rw-r--r-- | gdb/features/Makefile | 122 |
1 files changed, 118 insertions, 4 deletions
diff --git a/gdb/features/Makefile b/gdb/features/Makefile index f967e4c..d0ffa52 100644 --- a/gdb/features/Makefile +++ b/gdb/features/Makefile @@ -25,9 +25,22 @@ # GDB repository. # It can also update the C files in the features directory from their -# XML master copies. This relies on a GDB linked with expat and -# configured for the correct architecture, so the files are again kept -# in the GDB repository. To generate C files: +# XML master copies. This relies on a GDB linked with expat and that +# is configured to include support for the architecture, so the files +# are kept in the GDB repository. +# +# By default we'll generate all C files, and you must point make at a +# GDB that has been configured with --enable-targets=all: +# +# make GDB=/path/to/gdb cfiles +# +# To regenerate all C files from scratch: +# +# make GDB=/path/to/gdb clean-cfiles cfiles +# +# To generate specific C files, you can override the XMLTOC make +# variable: +# # make GDB=/path/to/gdb XMLTOC="xml files" cfiles WHICH = aarch64 \ @@ -118,7 +131,103 @@ XSLTPROC = xsltproc outdir = ../regformats OUTPUTS = $(patsubst %,$(outdir)/%.dat,$(WHICH)) -XMLTOC = +# The set of xml files we'll generate .c files for GDB from. By +# default we'll build all .c files, which requires an +# --enable-targets=all GDB. You can override this by passing XMLTOC +# to make on the command line. +XMLTOC = \ + aarch64.xml \ + arm-with-iwmmxt.xml \ + arm-with-m-fpa-layout.xml \ + arm-with-m-vfp-d16.xml \ + arm-with-m.xml \ + arm-with-neon.xml \ + arm-with-vfpv2.xml \ + arm-with-vfpv3.xml \ + i386/amd64-avx-linux.xml \ + i386/amd64-avx.xml \ + i386/amd64-avx512-linux.xml \ + i386/amd64-avx512.xml \ + i386/amd64-linux.xml \ + i386/amd64-mpx-linux.xml \ + i386/amd64-mpx.xml \ + i386/amd64.xml \ + i386/i386-avx-linux.xml \ + i386/i386-avx.xml \ + i386/i386-avx512-linux.xml \ + i386/i386-avx512.xml \ + i386/i386-linux.xml \ + i386/i386-mmx-linux.xml \ + i386/i386-mmx.xml \ + i386/i386-mpx-linux.xml \ + i386/i386-mpx.xml \ + i386/i386.xml \ + i386/x32-avx-linux.xml \ + i386/x32-avx.xml \ + i386/x32-avx512-linux.xml \ + i386/x32-avx512.xml \ + i386/x32-linux.xml \ + i386/x32.xml \ + microblaze-with-stack-protect.xml \ + microblaze.xml \ + mips-dsp-linux.xml \ + mips-linux.xml \ + mips64-dsp-linux.xml \ + mips64-linux.xml \ + nios2-linux.xml \ + nios2.xml \ + rs6000/powerpc-32.xml \ + rs6000/powerpc-32l.xml \ + rs6000/powerpc-403.xml \ + rs6000/powerpc-403gc.xml \ + rs6000/powerpc-405.xml \ + rs6000/powerpc-505.xml \ + rs6000/powerpc-601.xml \ + rs6000/powerpc-602.xml \ + rs6000/powerpc-603.xml \ + rs6000/powerpc-604.xml \ + rs6000/powerpc-64.xml \ + rs6000/powerpc-64l.xml \ + rs6000/powerpc-7400.xml \ + rs6000/powerpc-750.xml \ + rs6000/powerpc-860.xml \ + rs6000/powerpc-altivec32.xml \ + rs6000/powerpc-altivec32l.xml \ + rs6000/powerpc-altivec64.xml \ + rs6000/powerpc-altivec64l.xml \ + rs6000/powerpc-cell32l.xml \ + rs6000/powerpc-cell64l.xml \ + rs6000/powerpc-e500.xml \ + rs6000/powerpc-e500l.xml \ + rs6000/powerpc-isa205-32l.xml \ + rs6000/powerpc-isa205-64l.xml \ + rs6000/powerpc-isa205-altivec32l.xml \ + rs6000/powerpc-isa205-altivec64l.xml \ + rs6000/powerpc-isa205-vsx32l.xml \ + rs6000/powerpc-isa205-vsx64l.xml \ + rs6000/powerpc-vsx32.xml \ + rs6000/powerpc-vsx32l.xml \ + rs6000/powerpc-vsx64.xml \ + rs6000/powerpc-vsx64l.xml \ + rs6000/rs6000.xml \ + s390-linux32.xml \ + s390-linux32v1.xml \ + s390-linux32v2.xml \ + s390-linux64.xml \ + s390-linux64v1.xml \ + s390-linux64v2.xml \ + s390-te-linux64.xml \ + s390x-linux64.xml \ + s390x-linux64v1.xml \ + s390x-linux64v2.xml \ + s390x-te-linux64.xml \ + tic6x-c62x-linux.xml \ + tic6x-c62x.xml \ + tic6x-c64x-linux.xml \ + tic6x-c64x.xml \ + tic6x-c64xp-linux.xml \ + tic6x-c64xp.xml + CFILES = $(patsubst %.xml,%.c,$(XMLTOC)) GDB = false @@ -185,5 +294,10 @@ $(outdir)/i386/x32-avx512.dat: i386/x32-core.xml i386/64bit-avx.xml \ $(outdir)/i386/x32-avx512-linux.dat: i386/x32-core.xml i386/64bit-avx.xml \ i386/64bit-mpx.xml i386/64bit-avx512.xml i386/64bit-linux.xml +# 'all' doesn't build the C files, so don't delete them in 'clean' +# either. +clean-cfiles: + rm -f $(CFILES) + clean: rm -f $(OUTPUTS) |