|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [PATCH] build: drop the top-level uninstall target
'make uninstall' recurses into hand-written uninstall rules in every
subsystem. Nothing keeps them in sync with the install rules and nothing
tests them automatically, so they keep breaking, e.g. b26ac39144
("tools/ocaml: Add an uninstall target to the bindings test").
Distributions package Xen from DESTDIR and remove it with their package
manager, and the tree already has the debball and rpmball targets for the
same purpose. So, make 'make uninstall' print a message pointing at them,
and fail. List debball and rpmball in 'make help' instead.
The per-subsystem uninstall rules are no longer reachable from the
top-level Makefile, and can be removed separately.
Suggested-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
Signed-off-by: Julian Vetter <julian.vetter@xxxxxxxxxx>
---
This follows a discussion with Andrew on the "tools/ocaml: Add an
uninstall target to the bindings test" patch, where he suggested
dropping the uninstall targets altogether, as they are in a perpetual
state of broken. This patch only changes the top-level Makefile. The
per-subsystem uninstall rules can then be removed in follow-up patches.
If anyone has objections, or still relies on 'make uninstall', please shout
and we can work out an alternative.
---
CHANGELOG.md | 2 ++
Makefile | 34 +++++++++-------------------------
2 files changed, 11 insertions(+), 25 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 8776bed88b..db6774a14f 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -21,6 +21,8 @@ The format is based on [Keep a
Changelog](https://keepachangelog.com/en/1.0.0/)
- R-Car Gen5 PCI host controller support.
### Removed
+ - The top-level 'make uninstall' target, as it isn't tested automatically
+ and keeps breaking. Use the debball or rpmball targets instead.
- On Arm:
- XEN_DOMCTL_CONFIG_GIC_NATIVE has been removed. Toolstacks must now
explicitly request GIC_V2 or GIC_V3 when creating a domain.
diff --git a/Makefile b/Makefile
index ea432e21b0..0751d76c24 100644
--- a/Makefile
+++ b/Makefile
@@ -10,7 +10,6 @@ all: dist
SUBSYSTEMS?=xen tools stubdom docs
TARGS_DIST=$(patsubst %, dist-%, $(SUBSYSTEMS))
TARGS_INSTALL=$(patsubst %, install-%, $(SUBSYSTEMS))
-TARGS_UNINSTALL=$(patsubst %, uninstall-%, $(SUBSYSTEMS))
TARGS_BUILD=$(patsubst %, build-%, $(SUBSYSTEMS))
TARGS_CLEAN=$(patsubst %, clean-%, $(SUBSYSTEMS))
TARGS_DISTCLEAN=$(patsubst %, distclean-%, $(SUBSYSTEMS))
@@ -295,38 +294,23 @@ help:
@echo ' local downloaded files'
@echo ' subtree-force-update - Call *-force-update on all git
subtrees (qemu, seabios, ovmf)'
@echo ''
- @echo 'Miscellaneous targets:'
- @echo ' uninstall - attempt to remove installed Xen tools'
- @echo ' (use with extreme care!)'
- @echo
@echo 'Package targets:'
+ @echo ' debball - package a dist build as a .deb, for
easy removal'
+ @echo ' rpmball - package a dist build as a .rpm, for
easy removal'
@echo ' src-tarball-release - make a source tarball with xen and
qemu tagged with a release'
@echo ' src-tarball - make a source tarball with xen and
qemu tagged with git describe'
@echo
@echo 'Environment:'
@echo ' [ this documentation is sadly not complete ]'
-# Use this target with extreme care!
-
-.PHONY: uninstall-xen
-uninstall-xen:
- $(MAKE) -C xen uninstall
-
-.PHONY: uninstall-tools
-uninstall-tools:
- $(MAKE) -C tools uninstall
-
-.PHONY: uninstall-stubdom
-uninstall-stubdom:
- $(MAKE) -C stubdom uninstall
-
-.PHONY: uninstall-docs
-uninstall-docs:
- $(MAKE) -C docs uninstall
-
+# 'make install' can't be reliably undone. Install from a package instead,
+# which the package manager can remove cleanly.
.PHONY: uninstall
-uninstall: D=$(DESTDIR)
-uninstall: uninstall-tools-public-headers $(TARGS_UNINSTALL)
+uninstall:
+ @echo "'make uninstall' is not supported. To be able to remove Xen
cleanly,"
+ @echo "install it from a package, e.g. built with 'make debball' or"
+ @echo "'make rpmball', and remove it with the package manager."
+ @exit 1
.PHONY: xenversion
xenversion:
--
2.53.0
--
Julian Vetter | Vates Hypervisor & Kernel Developer
XCP-ng & Xen Orchestra - Vates solutions
web: https://vates.tech
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |