[PATCH v2 1/2] git_remote_cvs: Honor DESTDIR in the Makefile
- From
David Aguilar <davvid@gmail.com>
- Date
- Aug 16, 2009, 21:25 UTC
- Message-ID
- <1250457908-27376-1-git-send-email-davvid@gmail.com>
- In-Reply-To
- <alpine.DEB.1.00.0908162251360.8306@pacific.mpi-cbg.de>
This modifies the setup.py invocation so that user-defined DESTDIRs are taken into account.
Signed-off-by: David Aguilar <davvid@gmail.com> ---
setup.py gets confused if we use --root like in v1 of this patch. I think this is simpler. Thoughts?
git_remote_cvs/Makefile | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/git_remote_cvs/Makefile b/git_remote_cvs/Makefile index 8dbf3fa..2e26dbe 100644 --- a/git_remote_cvs/Makefile +++ b/git_remote_cvs/Makefile @@ -3,6 +3,9 @@ # pysetupfile:=setup.py +# Shell quote (do not use $(call) to accommodate ancient setups); +DESTDIR_SQ = $(subst ','\'',$(DESTDIR)) + ifndef PYTHON_PATH PYTHON_PATH = /usr/bin/python endif @@ -19,7 +22,8 @@ PYLIBDIR=`$(PYTHON_PATH) -c "import sys; print 'lib/python%i.%i/site-packages' % all: $(pysetupfile) $(QUIET)$(PYTHON_PATH) $(pysetupfile) $(QUIETSETUP) build install: $(pysetupfile) - $(PYTHON_PATH) $(pysetupfile) install --prefix $(prefix) + $(PYTHON_PATH) $(pysetupfile) install --prefix $(DESTDIR_SQ)$(prefix) + instlibdir: $(pysetupfile) @echo "$(prefix)/$(PYLIBDIR)" clean:
-- 1.6.4.314.g034e1