[Python-modules-commits] r8635 - in packages/python-repoze.who-plugins/trunk (2 files)
zack at users.alioth.debian.org
zack at users.alioth.debian.org
Sat May 30 12:47:04 UTC 2009
Date: Saturday, May 30, 2009 @ 12:47:04
Author: zack
Revision: 8635
add setup.py multiplexer, to recurse on the shipped plugins
Added:
packages/python-repoze.who-plugins/trunk/setup.py
Modified:
packages/python-repoze.who-plugins/trunk/debian/rules
Modified: packages/python-repoze.who-plugins/trunk/debian/rules
===================================================================
--- packages/python-repoze.who-plugins/trunk/debian/rules 2009-05-30 11:09:22 UTC (rev 8634)
+++ packages/python-repoze.who-plugins/trunk/debian/rules 2009-05-30 12:47:04 UTC (rev 8635)
@@ -9,6 +9,7 @@
repoze.who.plugins.sa \
repoze.who-testutil \
$(NULL)
+export SUBDIRS = $(UPSTREAMS)
DEB_PYTHON_INSTALL_ARGS_ALL += --single-version-externally-managed
Added: packages/python-repoze.who-plugins/trunk/setup.py
===================================================================
--- packages/python-repoze.who-plugins/trunk/setup.py (rev 0)
+++ packages/python-repoze.who-plugins/trunk/setup.py 2009-05-30 12:47:04 UTC (rev 8635)
@@ -0,0 +1,24 @@
+#!/usr/bin/python
+# Multiplexer for invoking multiple setup.py in subdir
+# Copyright (C) 2009 Stefano Zacchiroli <zack at debian.org>
+# License: GNU GPL version 3 or above
+import os, string, sys
+
+if not os.environ.has_key('SUBDIRS') or not os.environ['SUBDIRS']:
+ print >> sys.stderr, "Can't find subdirs, please set SUBDIRS envvar"
+ sys.exit(3)
+else:
+ subdirs = os.environ['SUBDIRS'].split()
+setup_cmd = "python setup.py %s" % string.join(sys.argv[1:])
+
+topdir = os.getcwd()
+for d in subdirs:
+ if not os.path.isdir(d):
+ print >> sys.stderr, "WARNING: can't find subdir %s" % d
+ continue
+ os.chdir(d)
+ retcode = os.system(setup_cmd)
+ if retcode:
+ print >> sys.stderr, "ERROR: setup.py in subdir %s failed" % d
+ sys.exit(retcode >> 8)
+ os.chdir(topdir)
Property changes on: packages/python-repoze.who-plugins/trunk/setup.py
___________________________________________________________________
Added: svn:executable
+ *
More information about the Python-modules-commits
mailing list