Reduced the filesize of the conda builds

This commit is contained in:
Jorrit Wronski
2015-07-09 23:35:33 +02:00
parent fbebec00aa
commit 575a8b357f

View File

@@ -423,22 +423,24 @@ def pythonFactory(pyID, pyCFG=PythonSlaveConfig("name")):
if checkID(pyID, teID=101, strict=False):
pkgs.append("ndg-httpsclient") # Add Windows-only and python2 dependency
#
# Create the factory to add the actions to
factory = getBaseFactory()
# Remove the temporary folder for installs
factory.addStep(RemoveDirectory(dir=os.path.join('build',installFolder), haltOnFailure = False))
#
activateCMD = " ".join([pyact, pyenv]) # We always activate an environment, regardless of the host
def combinedCMD(cmd): return " && ".join([activateCMD, cmd])
#
# Create the factory to add the actions to
factory = getBaseFactory()
#
if buildPyPI:
# Install dependencies
if installPackages and False:
if installPackages and False: # disabled
installCMD = " ".join(["pip", "install"]) + " " + " ".join(pkgs)
factory.addStep(ShellCommand(command=combinedCMD(installCMD), haltOnFailure=True))
# setuptools installation for PyPI packages
factory.addStep(RemoveDirectory(dir=os.path.join('build',installFolder), haltOnFailure = False))
installCMD = " ".join(["python", "setup.py"] + pyins)
factory.addStep(ShellCommand(command=combinedCMD(installCMD), workdir=workingFolder, haltOnFailure=True))
installCMD = " ".join(["python", "setup.py", "clean"])
factory.addStep(ShellCommand(command=combinedCMD(installCMD), workdir=workingFolder, haltOnFailure=True))
upload_command(factory, installFolder, pyID=pyID)
if buildConda:
# Install dependencies
@@ -446,12 +448,13 @@ def pythonFactory(pyID, pyCFG=PythonSlaveConfig("name")):
installCMD = " ".join(["conda", "install", "-yq"]) + " " + " ".join(pkgs)
factory.addStep(ShellCommand(command=combinedCMD(installCMD), haltOnFailure=True))
# conda installation for binstar packages
factory.addStep(RemoveDirectory(dir=os.path.join('build',installFolder), haltOnFailure = False))
factory.addStep(RemoveDirectory(dir=os.path.join(workingFolder,'build'), haltOnFailure = False))
factory.addStep(RemoveDirectory(dir=os.path.join(workingFolder,'src'), haltOnFailure = False))
installCMD = " ".join(["python", "generate_meta.yaml.py"])
factory.addStep(ShellCommand(command=combinedCMD(installCMD), workdir=workingFolder, haltOnFailure=True))
installCMD = " ".join(["python", "runner.py"])
factory.addStep(ShellCommand(command=combinedCMD(installCMD), workdir='build', haltOnFailure=True))
if buildPyPI or buildConda:
upload_command(factory, installFolder, pyID=pyID)
return factory