diff options
author | Simon Marchi <simon.marchi@efficios.com> | 2020-05-11 17:18:25 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@polymtl.ca> | 2020-05-24 11:11:36 -0400 |
commit | 41a77cbaadd63b92362f5ea35b2cd11f90edf170 (patch) | |
tree | 90873d1b17f04d3a6a6117dfe0c8a26dbd0a674b /gdb/gdbarch.h | |
parent | e08bd6c5081f4957ddb60117ac94775dcd618db7 (diff) | |
download | gdb-41a77cbaadd63b92362f5ea35b2cd11f90edf170.zip gdb-41a77cbaadd63b92362f5ea35b2cd11f90edf170.tar.gz gdb-41a77cbaadd63b92362f5ea35b2cd11f90edf170.tar.bz2 |
gdb: make gdbarch.sh write gdbarch.{c,h} directly
It was suggested in this thread [1] that gdbarch.sh should write to
gdbarch.h and gdbarch.c directly. This patch implements that.
When running gdbarch.sh, we currently need to move new-gdbarch.c over
gdbarch.c and new-gdbarch.h over gdbarch.h. It might have been useful
at some point to not have gdbarch.sh overwrite gdbarch.h and gdbarch.c,
but with git it's really unnecessary. Any changes to gdbarch.sh can be
inspected using `git diff`.
A next step would be to have the Makefile automatically run gdbarch.sh
if it sees that gdbarch.c and gdbarch.h are out of date. Or maybe even
remove gdbarch.c and gdbarch.h from the tree and generate them in the
build directory when building. But that requires more thinking and
discussions, and I think that this change is already useful in itself.
[1] https://sourceware.org/pipermail/gdb-patches/2020-May/168265.html
gdb/ChangeLog;
* gdbarch.sh: Write to gdbarch.c/gdbarch.h directly. Don't
compare old and new versions.
(compare_new): Remove.
Change-Id: I7970a9e8af0afc0145cb5a28e73d94fbaa1e25b9
Diffstat (limited to 'gdb/gdbarch.h')
-rw-r--r-- | gdb/gdbarch.h | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h index 6dbb9d5..c7621f2 100644 --- a/gdb/gdbarch.h +++ b/gdb/gdbarch.h @@ -20,17 +20,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. */ -/* This file was created with the aid of ``gdbarch.sh''. - - The Bourne shell script ``gdbarch.sh'' creates the files - ``new-gdbarch.c'' and ``new-gdbarch.h and then compares them - against the existing ``gdbarch.[hc]''. Any differences found - being reported. - - If editing this file, please also run gdbarch.sh and merge any - changes into that script. Conversely, when making sweeping changes - to this file, modifying gdbarch.sh and using its output may prove - easier. */ +/* This file was created with the aid of ``gdbarch.sh''. */ #ifndef GDBARCH_H #define GDBARCH_H |