Menu

[2275f9]: / install-python.xml  Maximize  Restore  History

Download this file

132 lines (111 with data), 5.1 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<?xml version='1.0' encoding='utf-8'?>
<html lang="en">
<program name='0install'
title='Install from Source'
author='Thomas Leonard'
git='https://github.com/0install/0install'
license='GNU Lesser General Public License'>
<p>
<strong>This is the older (but better tested) version of 0install. Consider trying the newer <a href='install-source.html'>OCaml version</a> (faster, but less well tested).</strong>
0install 2.3 is written entirely in Python, so installing from source is quite simple.
</p>
</program>
<p>
To use 0install, you will need the following (these are installed on most Linux systems by default):
</p>
<ul>
<li><a href="http://python.org">Python</a> (version 2.6, 2.7 or 3.2+).</li>
<li><a href="https://live.gnome.org/PyGObject/">PyGObject</a> (this is a dependency of PyGTK, but is also available separately). If PyGObject is not available, 0install can use <a href='http://code.google.com/p/tulip/'>Tulip</a> instead (which is pure Python, but requires Python >= 3.3).</li>
<li><a href="http://www.gnupg.org/">GnuPG</a> (to check the digital signatures).</li>
</ul>
<p>Note: the last version to support Python 2.5 was 0install 1.0.</p>
<p>
For the optional (but recommended) GUI:
</p>
<ul>
<li>If using <b>Python 2</b>: <a href="http://freshmeat.net/projects/pygtk/?branch_id=12503">PyGTK 2.12</a> or later.</li>
<li>If using <b>Python 3</b>: GTK3, including the GIRepository bindings (gir1.2-gtk-3.0).</li>
<li><a href="http://portland.freedesktop.org/wiki/">xdg-utils</a> (optional; GNOME and KDE desktop integration).</li>
</ul>
<p>
If you are looking for a package, try the <a href='injector.html'>main downloads page</a>.
</p>
<h2>Instructions</h2>
<p>
Download the latest .tar.bz2 archive from <a
href="https://sourceforge.net/projects/zero-install/files/0install/">the
SF.net download page</a> (and the corresponding .sig file if you want to verify it), or using wget:
</p>
<pre>
$ <b>wget https://downloads.sf.net/project/zero-install/0install/2.3.4/0install-2.3.4.tar.bz2</b>
$ <b>wget https://downloads.sf.net/project/zero-install/0install/2.3.4/0install-2.3.4.tar.bz2.sig</b>
</pre>
<p>
Check that the signature is correct using GPG (this also ensures that GPG is installed correctly).
You'll need <a href="http://0install.net/public_key.gpg">my GPG key</a>, which you can download and import
using --recv-key (or <a href='http://rox.sourceforge.net/desktop/GPG'>manually</a>):
</p>
<pre>
$ <b>gpg --recv-key --keyserver pgp.mit.edu CA74D8BA</b>
$ <b>gpg 0install-2.3.4.tar.bz2.sig</b>
gpg: Signature made Sun Nov 16 17:21:21 2014 UTC using RSA key ID CA74D8BA
gpg: Good signature from "Thomas Leonard &lt;XXXXX@gmail.com>"
gpg: Good signature from "Thomas Leonard &lt;XXXXX@users.sourceforge.net&gt;"
gpg: WARNING: This key is not certified with a trusted signature!
gpg: There is no indication that the signature belongs to the owner.
Primary key fingerprint: DA98 25AE CAD0 8975 7CDA BD8E 0713 3F96 CA74 D8BA
</pre>
<p>
The warning is just to tell you that you haven't yet established that the key really
belongs to me (ultra-paranoid users will now cross-check the finger-print using
some other source of information).
</p>
<p>
You should now extract the archive, and change directory inside it:
</p>
<pre>
$ <b>tar xjf 0install-2.3.4.tar.bz2</b>
$ <b>cd 0install-2.3.4</b>
</pre>
<table class='split'>
<col id="col1"/>
<tr><th>Installing normally</th><th>Installing without root access</th></tr>
<tr>
<td>
<p>For a normal install, either su to root, install, and exit from root, or use sudo:</p>
<pre>$ <b>sudo python setup.py install</b>
</pre>
</td><td>
<p>
If you don't have the root password, use this command.
You'll need to make sure that ~/bin is in $PATH in this case.
</p>
<pre>$ <b>python setup.py install --home ~ --install-data ~/.local</b>
$ <b>export PATH=$HOME/bin:$PATH</b>
</pre>
<p>
Logging out and back in again will ensure $PATH and the Applications menu get updated correctly,
on Ubuntu at least.
</p>
</td>
</tr>
</table>
<dl>
<dt>choosing the Python version</dt>
<dd>The installed scripts will use whichever version of python you used for the install. e.g. use "<b>python3 setup.py ...</b>" if you want to force Python 3.</dd>
<dt>error: invalid Python installation: unable to open /usr/lib/python2.X/config/Makefile</dt>
<dd>You need to install the <i>python-dev</i> package, not just <i>python</i>.</dd>
<dt>package init file 'zeroinstall/0launch-gui/__init__.py' not found (or not a regular file)</dt>
<dd>This is just a warning and is harmless.</dd>
</dl>
<p>
You now have some new commands: <b>0launch</b>, which takes the URL of a program and runs it, and
<b>0install</b>, which provides access to other features.
</p>
<div class='note'>Note (mainly for packagers): there is an optional OCaml front-end, which makes starting
applications (and tab-completion) faster. Do "make ocaml" before installing to get that. You'll need to
install OCaml and various extra library packages to build this.</div>
<quicklinks>
<link href='users.html' img='tango/go-next.png'>Continue to tutorial</link>
</quicklinks>
</html>
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.