summaryrefslogtreecommitdiff
path: root/pavement.py
diff options
context:
space:
mode:
authorDavid Cournapeau <cournape@gmail.com>2009-03-28 11:11:43 +0000
committerDavid Cournapeau <cournape@gmail.com>2009-03-28 11:11:43 +0000
commitc7927eb658b9616b42368e9496cb0304bdd2e4ae (patch)
tree13916a8c8750e4831565e6a0b5dca278c4169853 /pavement.py
parenta7499c34e30559ad2ff8f1a103fea5348a99440e (diff)
downloadnumpy-c7927eb658b9616b42368e9496cb0304bdd2e4ae.tar.gz
Copy tarballs and superpack into release dir.
Diffstat (limited to 'pavement.py')
-rw-r--r--pavement.py30
1 files changed, 29 insertions, 1 deletions
diff --git a/pavement.py b/pavement.py
index 403b1d98b..55ba9ae41 100644
--- a/pavement.py
+++ b/pavement.py
@@ -35,6 +35,7 @@ import os
import sys
import subprocess
import re
+import shutil
try:
from hash import md5
except ImportError:
@@ -91,7 +92,7 @@ BOOTSTRAP_SCRIPT = "%s/bootstrap.py" % BOOTSTRAP_DIR
DMG_CONTENT = paver.path.path('numpy-macosx-installer') / 'content'
# Where to put the final installers, as put on sourceforge
-INSTALLERS_DIR = 'installers'
+INSTALLERS_DIR = 'release/installers'
options(sphinx=Bunch(builddir="build", sourcedir="source", docroot='doc'),
virtualenv=Bunch(script_name=BOOTSTRAP_SCRIPT),
@@ -221,12 +222,29 @@ def pdf():
ref = paths.latexdir / "numpy-ref.pdf"
ref.copy(PDF_DESTDIR / "reference.pdf")
+def tarball_name(type='gztar'):
+ root = 'numpy-%s' % FULLVERSION
+ if type == 'gztar':
+ return root + '.tar.gz'
+ elif type == 'zip':
+ return root + '.zip'
+ raise ValueError("Unknown type %s" % type)
+
@task
def sdist():
# To be sure to bypass paver when building sdist... paver + numpy.distutils
# do not play well together.
sh('python setup.py sdist --formats=gztar,zip')
+ # Copy the superpack into installers dir
+ if not os.path.exists(INSTALLERS_DIR):
+ os.makedirs(INSTALLERS_DIR)
+
+ for t in ['gztar', 'zip']:
+ source = os.path.join('dist', tarball_name(t))
+ target = os.path.join(INSTALLERS_DIR, tarball_name(t))
+ shutil.copy(source, target)
+
#------------------
# Wine-based builds
#------------------
@@ -317,6 +335,16 @@ def bdist_superpack(options):
subprocess.check_call(['makensis', 'numpy-superinstaller.nsi'],
cwd=SUPERPACK_BUILD)
+ # Copy the superpack into installers dir
+ if not os.path.exists(INSTALLERS_DIR):
+ os.makedirs(INSTALLERS_DIR)
+
+ source = os.path.join(SUPERPACK_BUILD,
+ superpack_name(options.wininst.pyver, FULLVERSION))
+ target = os.path.join(INSTALLERS_DIR,
+ superpack_name(options.wininst.pyver, FULLVERSION))
+ shutil.copy(source, target)
+
@task
@needs('clean', 'bdist_wininst')
def bdist_wininst_simple():