* [PATCH] gdb/gdbserver: fix uninstall makefile rules
@ 2021-10-06 11:09 Andrew Burgess
2021-10-19 18:56 ` Tom Tromey
0 siblings, 1 reply; 2+ messages in thread
From: Andrew Burgess @ 2021-10-06 11:09 UTC (permalink / raw)
To: gdb-patches
I noticed that after running:
$ make install-gdb install-gdbserver
and then:
$ make -C gdb uninstall && make -C gdbserver uninstall
the install destination looks like:
install
|-- bin
| `-- gdb-add-index
|-- include
| `-- gdb
| `-- jit-reader.h
|-- lib
| `-- libinproctrace.so
`-- share
|-- gdb
|-- info
| `-- dir
`-- man
|-- man1
`-- man5
We've left 3 files behind. This is because the uninstall rules in
gdb/ and gdbserver/ have gotten out of sync with the install rules.
This commit adds the missing commands to the uninstall rules to delete
the extra files.
---
gdb/Makefile.in | 9 +++++++++
gdbserver/Makefile.in | 5 ++++-
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 5a3bb952279..889dbf2abc4 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -1820,6 +1820,7 @@ uninstall: force $(CONFIG_UNINSTALL)
fi ; \
rm -f $(DESTDIR)$(bindir)/$$transformed_name$(EXEEXT) \
$(DESTDIR)$(man1dir)/$$transformed_name.1
+ rm -f $(DESTDIR)$(includedir)/gdb/jit-reader.h
if test "x$(HAVE_NATIVE_GCORE_TARGET)$(HAVE_NATIVE_GCORE_HOST)" != x; \
then \
transformed_name=`t='$(program_transform_name)'; \
@@ -1831,6 +1832,14 @@ uninstall: force $(CONFIG_UNINSTALL)
fi ; \
rm -f $(DESTDIR)$(bindir)/$$transformed_name; \
fi
+ transformed_name=`t='$(program_transform_name)'; \
+ echo gdb-add-index | sed -e "$$t"` ; \
+ if test "x$$transformed_name" = x; then \
+ transformed_name=gdb-add-index ; \
+ else \
+ true ; \
+ fi ; \
+ rm -f $(DESTDIR)$(bindir)/$$transformed_name
@$(MAKE) DO=uninstall "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do
# The C++ name parser can be built standalone for testing.
diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in
index 12e9b2777ae..2de55e393d5 100644
--- a/gdbserver/Makefile.in
+++ b/gdbserver/Makefile.in
@@ -351,7 +351,10 @@ install-strip:
uninstall: force
n=`echo gdbserver | sed '$(program_transform_name)'`; \
if [ x$$n = x ]; then n=gdbserver; else true; fi; \
- rm -f $(DESTDIR)/$(bindir)/$$n$(EXEEXT) $(DESTDIR)$(man1dir)/$$n.1
+ rm -f $(DESTDIR)/$(bindir)/$$n$(EXEEXT) $(DESTDIR)$(man1dir)/$$n.1; \
+ if [ x"$(IPA_DEPFILES)" != x ]; then \
+ rm -f $(DESTDIR)$(libdir)/$(IPA_LIB); \
+ fi;
installcheck:
check:
--
2.25.4
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] gdb/gdbserver: fix uninstall makefile rules
2021-10-06 11:09 [PATCH] gdb/gdbserver: fix uninstall makefile rules Andrew Burgess
@ 2021-10-19 18:56 ` Tom Tromey
0 siblings, 0 replies; 2+ messages in thread
From: Tom Tromey @ 2021-10-19 18:56 UTC (permalink / raw)
To: Andrew Burgess; +Cc: gdb-patches
>>>>> "Andrew" == Andrew Burgess <andrew.burgess@embecosm.com> writes:
Andrew> We've left 3 files behind. This is because the uninstall rules in
Andrew> gdb/ and gdbserver/ have gotten out of sync with the install rules.
Andrew> This commit adds the missing commands to the uninstall rules to delete
Andrew> the extra files.
Thanks. I sent nearly the same patch today, oops.
I didn't read through the whole list before sending...
Anyway yours looks good to me.
Tom
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-10-19 18:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-06 11:09 [PATCH] gdb/gdbserver: fix uninstall makefile rules Andrew Burgess
2021-10-19 18:56 ` Tom Tromey
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).