]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
setup: simplify makefile's path manipulation now that we rely on setup.py develop
authorZooko O'Whielacronx <zooko@zooko.com>
Wed, 26 Mar 2008 17:00:33 +0000 (10:00 -0700)
committerZooko O'Whielacronx <zooko@zooko.com>
Wed, 26 Mar 2008 17:00:33 +0000 (10:00 -0700)
GNUmakefile
misc/find-dep-eggs.py [deleted file]

index 6617bb24cb05f7deeb8105b40d54e8bd345e4c26..4d9d39dd9de182d9538ab921133a65eee99e37bb 100644 (file)
@@ -48,26 +48,22 @@ endif
 build-deps:
        echo "This is done automatically (by delegating to setuptools) now."
 
-EGGSPATH = $(shell $(PYTHON) misc/find-dep-eggs.py)
-
 ifneq ($(PYTHONPATH),)
-       PYTHONPATH := $(PYTHONPATH)$(PATHSEP)
+        PP=PYTHONPATH="$(PYTHONPATH)$(PATHSEP)$(SUPPORTLIB)"
+else
+        PP=PYTHONPATH="$(SUPPORTLIB)"
 endif
-PP=PYTHONPATH="$(SRCPATH)$(PATHSEP)$(PYTHONPATH)$(PATHSEP)$(EGGSPATH)"
 
 TRIALCMD = $(shell $(PP) $(PYTHON) misc/find_trial.py)
 TRIAL=PYTHONUNBUFFERED=1 $(TRIALCMD) --rterrors $(REACTOROPT)
 
 .PHONY: make-version build
 
-show-eggspath:
-       @echo $(EGGSPATH)
-
 # The 'darcsver' setup.py command comes in the 'darcsver' package:
 # http://pypi.python.org/pypi/darcsver It is necessary only if you want to
 # automatically produce a new _version.py file from the current darcs history.
 make-version:
-       $(PYTHON) ./setup.py darcsver --count-all-patches
+       $(PP) $(PYTHON) ./setup.py darcsver --count-all-patches
 
 # We want src/allmydata/_version.py to be up-to-date, but it's a fairly
 # expensive operation (about 6 seconds on a just-before-0.7.0 tree, probably
@@ -100,8 +96,7 @@ src/allmydata/_version.py:
 
 build: src/allmydata/_version.py
        mkdir -p "$(SUPPORTLIB)"
-       PYTHONPATH="$(PYTHONPATH)$(PATHSEP)$(SUPPORTLIB)$(PATHSEP)" \
-               $(PYTHON) ./setup.py develop --prefix="$(SUPPORT)"
+       $(PP) $(PYTHON) ./setup.py develop --prefix="$(SUPPORT)"
        chmod +x bin/tahoe
        touch .built
 
@@ -167,13 +162,13 @@ check-auto-deps:
 check-all-deps: check-deps check-auto-deps
 
 check-twisted-dep:
-       @$(PYTHON) -c 'import twisted, zope.interface' || $(MAKE) signal-error-twisted-dep
+       @$(PP) $(PYTHON) -c 'import twisted, zope.interface' || $(MAKE) signal-error-twisted-dep
 
 check-pywin32-dep:
-       @$(PYTHON) -c 'import win32process' || $(MAKE) signal-error-pywin32-dep
+       @$(PP) $(PYTHON) -c 'import win32process' || $(MAKE) signal-error-pywin32-dep
 
 check-pyopenssl-dep:
-       @$(PYTHON) -c 'import OpenSSL' || $(MAKE) signal-error-pyopenssl-dep
+       @$(PP) $(PYTHON) -c 'import OpenSSL' || $(MAKE) signal-error-pyopenssl-dep
 
 check-deps: check-twisted-dep $(CHECK_PYWIN32_DEP) check-pyopenssl-dep
 
diff --git a/misc/find-dep-eggs.py b/misc/find-dep-eggs.py
deleted file mode 100644 (file)
index 6a2fef1..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-#! /usr/bin/python
-
-import os.path, sys
-
-path = []
-if sys.platform == 'win32':
-    support_lib = "support/Lib/site-packages"
-else:
-    pyver = "python%d.%d" % (sys.version_info[:2])
-    support_lib = "support/lib/%s/site-packages" % pyver
-
-if os.path.exists(support_lib):
-    for fn in os.listdir(support_lib):
-        if fn.endswith(".egg"):
-            path.append(os.path.abspath(os.path.join(support_lib, fn)))
-
-# We also need to include .egg's in the CWD, because if there is an .egg there
-# then "make build-deps" will take that as satisfying its requirements.
-for fn in os.listdir("."):
-    if fn.endswith(".egg"):
-        path.append(os.path.abspath(os.path.join(os.getcwd(), fn)))
-
-print os.pathsep.join(path)