# HG changeset patch
# User wolma
# Date 1465686461 14400
# Node ID 83407422ec16e46c0cccce1f5152434c8ab532d7
# Parent 5e5653b689ca78292f0640dfff99587180134898
Uploaded
diff -r 5e5653b689ca -r 83407422ec16 tool_dependencies.xml
--- a/tool_dependencies.xml Fri Apr 29 06:00:29 2016 -0400
+++ b/tool_dependencies.xml Sat Jun 11 19:07:41 2016 -0400
@@ -59,8 +59,10 @@
$ENV[ZLIB_ROOT_PATH]/lib
$ENV[SQLITE_ROOT_DIR]/lib
-
+ $INSTALL_DIR
$INSTALL_DIR
+ True
+ lib/python3.4/site-packages
$INSTALL_DIR/lib/pkgconfig
@@ -86,10 +88,7 @@
This means that **the pip installation tool will not be available with
this build** !!
- For a full build (including the ssl module) look at
- https://toolshed.g2.bx.psu.edu/view/iuc/package_python_3_4/
- issued by the IUC.
-
+
This version of Python includes a built-in virtual environment manager.
To create a Python 3 virtual env, include the following actions in your
tool_dependencies.xml, e.g. for a package MY_TOOL_venv:
@@ -101,8 +100,7 @@
<!-- other install time dependencies -->
</action>
- <action type="shell_command">
-
+ <action type="shell_command">
# Create virtual environment MY_TOOL_venv
# pip cannot be used for installation because it depends on ssl,
# which this build does not provide
@@ -117,7 +115,23 @@
$INSTALL_DIR/MY_TOOL_venv/bin/python3 setup.py install
</action>
- For a full example look at the tool_dependencies file of:
+ <action type="set_environment">
+ <!-- prepend the bin directory of the virtual environment to PATH -->
+ <environment_variable name="PATH" action="prepend_to">$INSTALL_DIR/MY_TOOL_venv/bin</environment_variable>
+ <!-- prepend the site-packages directory of the virtual environment
+ to PYTHONPATH; using SITE_PACKAGES_RELPATH here makes it easy to migrate to
+ a different version of Python -->
+ <environment_variable name="PYTHONPATH" action="prepend_to">$INSTALL_DIR/MY_TOOL_venv/$SITE_PACKAGES_RELPATH</environment_variable>
+ </action>
+
+ Then, in your MY_TOOL.xml add the following requirements (in that order):
+
+ <requirements>
+ <requirement name="package" version="3.4">python3</requirement>
+ <requirement name="package" version="XXX">MY_TOOL</requirement>
+ </requirements>
+
+ For a concrete example look at the tool_dependencies file of:
https://toolshed.g2.bx.psu.edu/view/wolma/mimodd