annotate tool_dependencies.xml @ 2:50ffd429060b draft

Uploaded
author wolma
date Tue, 26 Apr 2016 12:24:47 -0400
parents 040f60d3c15b
children 87b8dcebce9b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
3956f4688295 Uploaded
wolma
parents:
diff changeset
1 <?xml version="1.0"?>
3956f4688295 Uploaded
wolma
parents:
diff changeset
2 <tool_dependency>
3956f4688295 Uploaded
wolma
parents:
diff changeset
3 <package name="zlib" version="1.2.8">
3956f4688295 Uploaded
wolma
parents:
diff changeset
4 <repository changeset_revision="63a4a902cda2" name="package_zlib_1_2_8" owner="iuc" prior_installation_required="True" toolshed="https://toolshed.g2.bx.psu.edu" />
3956f4688295 Uploaded
wolma
parents:
diff changeset
5 </package>
3956f4688295 Uploaded
wolma
parents:
diff changeset
6
3956f4688295 Uploaded
wolma
parents:
diff changeset
7 <package name="sqlite" version="3.8.3">
3956f4688295 Uploaded
wolma
parents:
diff changeset
8 <repository changeset_revision="706b1f3b1fc0" name="package_sqlite_3_8_3" owner="iuc" prior_installation_required="True" toolshed="http://toolshed.g2.bx.psu.edu" />
3956f4688295 Uploaded
wolma
parents:
diff changeset
9 </package>
3956f4688295 Uploaded
wolma
parents:
diff changeset
10
3956f4688295 Uploaded
wolma
parents:
diff changeset
11 <package name="python3" version="3.4">
3956f4688295 Uploaded
wolma
parents:
diff changeset
12 <install version="1.0">
3956f4688295 Uploaded
wolma
parents:
diff changeset
13 <actions>
3956f4688295 Uploaded
wolma
parents:
diff changeset
14 <action type="download_by_url">https://www.python.org/ftp/python/3.4.4/Python-3.4.4.tgz</action>
3956f4688295 Uploaded
wolma
parents:
diff changeset
15
3956f4688295 Uploaded
wolma
parents:
diff changeset
16 <action type="set_environment_for_install">
3956f4688295 Uploaded
wolma
parents:
diff changeset
17 <repository changeset_revision="63a4a902cda2" name="package_zlib_1_2_8" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu">
3956f4688295 Uploaded
wolma
parents:
diff changeset
18 <package name="zlib" version="1.2.8" />
3956f4688295 Uploaded
wolma
parents:
diff changeset
19 </repository>
3956f4688295 Uploaded
wolma
parents:
diff changeset
20
3956f4688295 Uploaded
wolma
parents:
diff changeset
21 <repository changeset_revision="706b1f3b1fc0" name="package_sqlite_3_8_3" owner="iuc" toolshed="http://toolshed.g2.bx.psu.edu">
3956f4688295 Uploaded
wolma
parents:
diff changeset
22 <package name="sqlite" version="3.8.3" />
3956f4688295 Uploaded
wolma
parents:
diff changeset
23 </repository>
3956f4688295 Uploaded
wolma
parents:
diff changeset
24 </action>
3956f4688295 Uploaded
wolma
parents:
diff changeset
25
3956f4688295 Uploaded
wolma
parents:
diff changeset
26 <action type="shell_command">
3956f4688295 Uploaded
wolma
parents:
diff changeset
27 # The python build system doesn't check CPATH / C(PLUS)_INCLUDE_PATH which is set by the depended-upon
3956f4688295 Uploaded
wolma
parents:
diff changeset
28 # tool definitions for these sources, but it does check CPPFLAGS / LDFLAGS
3956f4688295 Uploaded
wolma
parents:
diff changeset
29 # Currently not whitespace-safe, I haven't found a way yet to quote the *FLAGS values so that they are
3956f4688295 Uploaded
wolma
parents:
diff changeset
30 # correctly recognized by both the python build process and the compiler. But as galaxy itself isn't
3956f4688295 Uploaded
wolma
parents:
diff changeset
31 # whitespace-safe either it doesn't really matter (currently).
3956f4688295 Uploaded
wolma
parents:
diff changeset
32 oldifs="$IFS"
3956f4688295 Uploaded
wolma
parents:
diff changeset
33 IFS=":"
3956f4688295 Uploaded
wolma
parents:
diff changeset
34 for p in $CPLUS_INCLUDE_PATH
3956f4688295 Uploaded
wolma
parents:
diff changeset
35 do
3956f4688295 Uploaded
wolma
parents:
diff changeset
36 CPPFLAGS="$CPPFLAGS -I$p"
3956f4688295 Uploaded
wolma
parents:
diff changeset
37 done
3956f4688295 Uploaded
wolma
parents:
diff changeset
38 for p in $LD_LIBRARY_PATH
3956f4688295 Uploaded
wolma
parents:
diff changeset
39 do
3956f4688295 Uploaded
wolma
parents:
diff changeset
40 LDFLAGS="$LDFLAGS -L$p"
3956f4688295 Uploaded
wolma
parents:
diff changeset
41 done
3956f4688295 Uploaded
wolma
parents:
diff changeset
42 IFS="$oldifs"
3956f4688295 Uploaded
wolma
parents:
diff changeset
43 export CPPFLAGS
3956f4688295 Uploaded
wolma
parents:
diff changeset
44 export LDFLAGS
3956f4688295 Uploaded
wolma
parents:
diff changeset
45
3956f4688295 Uploaded
wolma
parents:
diff changeset
46 # Clear variables that may be used in Galaxy's extenal python 2 environment
3956f4688295 Uploaded
wolma
parents:
diff changeset
47 unset PYTHONPATH
3956f4688295 Uploaded
wolma
parents:
diff changeset
48 unset PYTHONHOME
3956f4688295 Uploaded
wolma
parents:
diff changeset
49
3956f4688295 Uploaded
wolma
parents:
diff changeset
50 ./configure --prefix="$INSTALL_DIR" \
3956f4688295 Uploaded
wolma
parents:
diff changeset
51 &amp;&amp; make \
3956f4688295 Uploaded
wolma
parents:
diff changeset
52 &amp;&amp; make install
3956f4688295 Uploaded
wolma
parents:
diff changeset
53 </action>
3956f4688295 Uploaded
wolma
parents:
diff changeset
54
3956f4688295 Uploaded
wolma
parents:
diff changeset
55 <action type="set_environment">
3956f4688295 Uploaded
wolma
parents:
diff changeset
56 <environment_variable action="prepend_to" name="PATH">$INSTALL_DIR/bin</environment_variable>
3956f4688295 Uploaded
wolma
parents:
diff changeset
57 <environment_variable action="prepend_to" name="LD_LIBRARY_PATH">$ENV[LD_LIBRARY_PATH]</environment_variable>
3956f4688295 Uploaded
wolma
parents:
diff changeset
58 <!-- clear PYTHONPATH, otherwise we will get Galaxy's Python 2 libraries in the Python 3 path. -->
3956f4688295 Uploaded
wolma
parents:
diff changeset
59 <environment_variable action="set_to" name="PYTHONPATH" />
3956f4688295 Uploaded
wolma
parents:
diff changeset
60 <environment_variable action="set_to" name="PYTHONHOME">$INSTALL_DIR</environment_variable>
3956f4688295 Uploaded
wolma
parents:
diff changeset
61 <environment_variable action="prepend_to" name="PKG_CONFIG_PATH">$INSTALL_DIR/lib/pkgconfig</environment_variable>
3956f4688295 Uploaded
wolma
parents:
diff changeset
62 <!-- fix too strict compiler settings under Python 3.4 -->
2
50ffd429060b Uploaded
wolma
parents: 1
diff changeset
63 <environment_variable action="set_to" name="CFLAGS">"$ENV[CFLAGS] -Wno-error=declaration-after-statement"</environment_variable>
0
3956f4688295 Uploaded
wolma
parents:
diff changeset
64 </action>
3956f4688295 Uploaded
wolma
parents:
diff changeset
65 </actions>
3956f4688295 Uploaded
wolma
parents:
diff changeset
66 </install>
3956f4688295 Uploaded
wolma
parents:
diff changeset
67 <readme>
3956f4688295 Uploaded
wolma
parents:
diff changeset
68 The Python programming language version 3.4
3956f4688295 Uploaded
wolma
parents:
diff changeset
69
3956f4688295 Uploaded
wolma
parents:
diff changeset
70 http://www.python.org
3956f4688295 Uploaded
wolma
parents:
diff changeset
71
3956f4688295 Uploaded
wolma
parents:
diff changeset
72
3956f4688295 Uploaded
wolma
parents:
diff changeset
73 A lean build of Python 3.4.x.
3956f4688295 Uploaded
wolma
parents:
diff changeset
74
3956f4688295 Uploaded
wolma
parents:
diff changeset
75 This package receives bug fixes within the 3.4 release series!
3956f4688295 Uploaded
wolma
parents:
diff changeset
76
3956f4688295 Uploaded
wolma
parents:
diff changeset
77 It contains the zlib and sqlite3 modules as the only stdlib modules with
3956f4688295 Uploaded
wolma
parents:
diff changeset
78 external dependencies (handled in here by depending on package_zlib_1_2_8
3956f4688295 Uploaded
wolma
parents:
diff changeset
79 and package_sqlite_3_8_3).
3956f4688295 Uploaded
wolma
parents:
diff changeset
80
3956f4688295 Uploaded
wolma
parents:
diff changeset
81 In particular, this build does not compile Python's ssl module (which
3956f4688295 Uploaded
wolma
parents:
diff changeset
82 would cause dependency on openssl and, in turn, on Perl).
3956f4688295 Uploaded
wolma
parents:
diff changeset
83
3956f4688295 Uploaded
wolma
parents:
diff changeset
84 This means that **the pip installation tool will not be available with
3956f4688295 Uploaded
wolma
parents:
diff changeset
85 this build** !!
3956f4688295 Uploaded
wolma
parents:
diff changeset
86
3956f4688295 Uploaded
wolma
parents:
diff changeset
87 For a full build (including the ssl module) look at
3956f4688295 Uploaded
wolma
parents:
diff changeset
88 https://toolshed.g2.bx.psu.edu/view/jankanis/package_python3_4
3956f4688295 Uploaded
wolma
parents:
diff changeset
89 written by jankanis, of which this package is a shameless plagiarism.
3956f4688295 Uploaded
wolma
parents:
diff changeset
90
3956f4688295 Uploaded
wolma
parents:
diff changeset
91 This version of Python includes a built-in virtual environment manager.
3956f4688295 Uploaded
wolma
parents:
diff changeset
92 To create a Python 3 virtual env, include the following actions in your
3956f4688295 Uploaded
wolma
parents:
diff changeset
93 tool_dependencies.xml, e.g. for a package MY_TOOL_venv:
3956f4688295 Uploaded
wolma
parents:
diff changeset
94
3956f4688295 Uploaded
wolma
parents:
diff changeset
95 &lt;action type="set_environment_for_install"&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
96 &lt;repository name="package_python3_zlib_dependent_1_0" owner="wolma"&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
97 &lt;package name="python3" version="3.4" /&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
98 &lt;/repository&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
99 &lt;!-- other install time dependencies --&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
100 &lt;/action&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
101
3956f4688295 Uploaded
wolma
parents:
diff changeset
102 &lt;action type="shell_command"&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
103
3956f4688295 Uploaded
wolma
parents:
diff changeset
104 # Create virtual environment MY_TOOL_venv
3956f4688295 Uploaded
wolma
parents:
diff changeset
105 # pip cannot be used for installation because it depends on ssl,
3956f4688295 Uploaded
wolma
parents:
diff changeset
106 # which this build does not provide
3956f4688295 Uploaded
wolma
parents:
diff changeset
107
3956f4688295 Uploaded
wolma
parents:
diff changeset
108 pyvenv --without-pip $INSTALL_DIR/MY_TOOL_venv
3956f4688295 Uploaded
wolma
parents:
diff changeset
109
3956f4688295 Uploaded
wolma
parents:
diff changeset
110 # install python packages
3956f4688295 Uploaded
wolma
parents:
diff changeset
111 # assuming you are in the download directory of the package
3956f4688295 Uploaded
wolma
parents:
diff changeset
112
3956f4688295 Uploaded
wolma
parents:
diff changeset
113 $INSTALL_DIR/MY_TOOL_venv/bin/python3 setup.py install
3956f4688295 Uploaded
wolma
parents:
diff changeset
114 &lt;/action&gt;
3956f4688295 Uploaded
wolma
parents:
diff changeset
115
3956f4688295 Uploaded
wolma
parents:
diff changeset
116 For an example of how this could used by a package look at the
3956f4688295 Uploaded
wolma
parents:
diff changeset
117 tool_dependencies file of:
3956f4688295 Uploaded
wolma
parents:
diff changeset
118
3956f4688295 Uploaded
wolma
parents:
diff changeset
119 https://toolshed.g2.bx.psu.edu/view/wolma/mimodd
3956f4688295 Uploaded
wolma
parents:
diff changeset
120
3956f4688295 Uploaded
wolma
parents:
diff changeset
121 </readme>
3956f4688295 Uploaded
wolma
parents:
diff changeset
122 </package>
3956f4688295 Uploaded
wolma
parents:
diff changeset
123 </tool_dependency>