Mercurial > repos > jankanis > package_python3_4
annotate tool_dependencies.xml @ 12:4091cf3b81e5 draft
Uploaded
author | jankanis |
---|---|
date | Mon, 26 May 2014 05:11:04 -0400 |
parents | bad79cc1a7b1 |
children | 9dbfc4fcef0a |
rev | line source |
---|---|
0 | 1 <?xml version="1.0"?> |
2 <tool_dependency> | |
3 <package name="openssl" version="1.0.1g"> | |
7 | 4 <repository changeset_revision="23ebff671a20" name="package_openssl" owner="jankanis" prior_installation_required="True" toolshed="http://toolshed.g2.bx.psu.edu" /> |
0 | 5 </package> |
6 | |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
7 <package name="sqlite" version="3.8.3"> |
7 | 8 <repository changeset_revision="706b1f3b1fc0" name="package_sqlite_3_8_3" owner="iuc" prior_installation_required="True" toolshed="http://toolshed.g2.bx.psu.edu" /> |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
9 </package> |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
10 |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
11 <package name="gdbm" version="1.11"> |
7 | 12 <repository changeset_revision="15e7435c2663" name="package_gdbm_1_11" owner="iuc" prior_installation_required="True" toolshed="http://toolshed.g2.bx.psu.edu" /> |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
13 </package> |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
14 |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
15 |
0 | 16 <package name="python3" version="3.4.1"> |
17 <install version="1.0"> | |
18 <actions> | |
1 | 19 <action type="download_by_url">https://www.python.org/ftp/python/3.4.1/Python-3.4.1.tgz</action> |
9
d3ea5f1b4d79
Another attempt at getting the environment settings right.
jankanis
parents:
8
diff
changeset
|
20 |
0 | 21 <action type="set_environment_for_install"> |
7 | 22 <repository changeset_revision="23ebff671a20" name="package_openssl" owner="jankanis" toolshed="http://toolshed.g2.bx.psu.edu"> |
0 | 23 <package name="openssl" version="1.0.1g" /> |
24 </repository> | |
7 | 25 <repository changeset_revision="706b1f3b1fc0" name="package_sqlite_3_8_3" owner="iuc" toolshed="http://toolshed.g2.bx.psu.edu"> |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
26 <package name="sqlite" version="3.8.3" /> |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
27 </repository> |
7 | 28 <repository changeset_revision="15e7435c2663" name="package_gdbm_1_11" owner="iuc" toolshed="http://toolshed.g2.bx.psu.edu"> |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
29 <package name="gdbm" version="1.11" /> |
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
30 </repository> |
0 | 31 </action> |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
32 |
9
d3ea5f1b4d79
Another attempt at getting the environment settings right.
jankanis
parents:
8
diff
changeset
|
33 <action type="shell_command"> |
12 | 34 # The python build system doesn't check CPATH / C(PLUS)_INCLUDE_PATH which is set by the depended-upon |
35 # tool definitions for these sources, but it does check CPPFLAGS / LDFLAGS | |
36 # Currently not whitespace-safe, but galaxy itself isn't whitespace-safe either so it doesn't matter (yet) | |
37 oldifs="$IFS" | |
38 IFS=: | |
39 for p in $CPLUS_INCLUDE_PATH | |
40 do | |
41 CPPFLAGS="$CPPFLAGS -I$p" | |
42 done | |
43 for p in $LD_LIBRARY_PATH | |
44 do | |
45 LDFLAGS="$LDFLAGS -L$p/lib" | |
46 done | |
47 IFS="$oldifs" | |
48 export CPPFLAGS | |
49 export LDFLAGS | |
50 | |
51 # Clear variables that may be used in Galaxy's extenal python 2 environment | |
52 unset PYTHONPATH | |
53 unset PYTHONHOME | |
54 | |
55 ./configure --prefix="$INSTALL_DIR" --with-ensurepip --enable-loadable-sqlite-extensions \ | |
56 && make \ | |
57 && make install | |
58 </action> | |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
59 |
1 | 60 <action type="set_environment"> |
61 <environment_variable action="prepend_to" name="PATH">$INSTALL_DIR/bin</environment_variable> | |
6
321cacd4ae43
Add dependencies and settings for sqlite and gdbm, so that python can build its packages for those.
jankanis
parents:
5
diff
changeset
|
62 <!-- empty PYTHONPATH, otherwise we will get Galaxy's Python 2 libraries in the Python 3 path --> |
1 | 63 <environment_variable action="set_to" name="PYTHONPATH" /> |
64 <environment_variable action="set_to" name="PYTHONHOME">$INSTALL_DIR</environment_variable> | |
4 | 65 <environment_variable action="prepend_to" name="PKG_CONFIG_PATH">$INSTALL_DIR/lib/pkgconfig</environment_variable> |
1 | 66 </action> |
0 | 67 </actions> |
68 </install> | |
69 | |
70 <readme> | |
71 Python 3.4.1. Configured with the default settings, using --prefix=$INSTALL_DIR. | |
72 | |
73 Python as of version 3.3 includes a built-in virtual environment manager. To create a python 3 virtual env, include the following actions in your tool_dependencies.xml: | |
74 | |
75 <action type="set_environment_for_install"> | |
1 | 76 <repository name="python3" owner="jankanis"> |
0 | 77 <package name="python3" version="3.4.1" /> |
1 | 78 </repository> |
0 | 79 </action> |
80 <action type="shell_command"> | |
1 | 81 # Unset any saved environment settings from parent virtual |
82 # environments, e.g. for python 2 or if Galaxy itself is running | |
83 # from within a virtual environment. | |
84 unset _OLD_VIRTUAL_PATH; unset _OLD_VIRTUAL_PYTHONHOME | |
3 | 85 pyvenv {{\$MY_PACKAGE_NAME}} |
86 . {{\$MY_PACKAGE_NAME}}/bin/activate | |
87 pip3 install {{\$PYTHON-PACKAGE}} | |
0 | 88 </action> |
89 <action type="set_environment"> | |
3 | 90 <environment_variable name="PYTHONPATH" action="prepend_to">\$INSTALL_DIR/lib/python3.4/site-packages</environment_variable> |
0 | 91 </action> |
92 | |
93 </readme> | |
94 | |
95 </package> | |
96 </tool_dependency> |