Skip to content

Commit 25acd0e

Browse files
committed
build: Force pip install to not check for already installed module
This previously broke distro package builds when they happened with the `cockpit-bridge` package installed: ``` Processing ./tmp/wheel/cockpit-0-py3-none-any.whl Installing collected packages: cockpit Attempting uninstall: cockpit Found existing installation: cockpit 311 ERROR: Cannot uninstall cockpit 311, RECORD file not found. Hint: The package was installed by debian. ``` This is a `pip` bug (pypa/pip#3063), work around it with `--ignore-installed`.
1 parent a9bf92a commit 25acd0e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Makefile.am

+2-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ install-python:
2626
@# wheel-based installation with .dist-info.
2727
@# This needs to work on RHEL8 up through modern Fedora, offline, with
2828
@# system packages available to the build.
29-
python3 -m pip install --no-index --force-reinstall --root='$(DESTDIR)/' --prefix='$(prefix)' \
29+
@# See https://github.com/pypa/pip/issues/3063 for --ignore-installed
30+
python3 -m pip install --no-index --force-reinstall --ignore-installed --root='$(DESTDIR)/' --prefix='$(prefix)' \
3031
"$$(python3 '$(srcdir)'/src/build_backend.py --wheel '$(srcdir)' tmp/wheel)"
3132
mkdir -p $(DESTDIR)$(libexecdir)
3233
mv -t $(DESTDIR)$(libexecdir) $(DESTDIR)$(bindir)/cockpit-askpass

0 commit comments

Comments
 (0)