Changes between Initial Version and Version 1 of InstallDetails


Ignore:
Timestamp:
2008-09-17T22:36:16Z (16 years ago)
Author:
warner
Comment:

add more build/install information

Legend:

Unmodified
Added
Removed
Modified
  • InstallDetails

    v1 v1  
     1= Additional Build/Install Documentation =
     2
     3Hopefully, the basic install docs in
     4[http://allmydata.org/source/tahoe/trunk/docs/install.html docs/install.html]
     5are enough for the most common use cases. This page provides additional
     6information for specific platforms.
     7
     8Please feel free to add sections to this page with anything you might learn
     9while building Tahoe on other platforms. Information which may be useful in
     10the most general cases will be folded into docs/install.html .
     11
     12== Overview ==
     13
     14Tahoe is happy to build and run in-place, from a source tree. It is not
     15necessary to install it (outside the source tree) before use, but if you'd
     16like to do so, please read the "Installing Outside The Source Tree" section
     17below.
     18
     19However, it does need to be "built" before running it in place. While Tahoe
     20itself is pure-python and therefore does not require a distinct compile step,
     21the mechanics that make it easy to run-in-place do require a setup phase. In
     22addition, Tahoe uses several third-party python libraries to work its magic,
     23many of which are unlikely to be just "lying around" and already installed.
     24Several of these use compiled C code, so they '''do''' require a compile
     25step.
     26
     27The "make all" target will download and build any third-party libraries that
     28are not already available on your system. It will also prepare the source
     29tree for running-in-place. The details: this target is equivalent to
     30executing "{{{setup.py build_tahoe}}}", and basically does a
     31"{{{setup.py develop}}}" into a tree-local
     32{{{./support/lib/python2.5/site-packages/}}} directory. The {{{bin/tahoe}}}
     33executable knows that it should add this directory to PYTHONPATH before it
     34does anything else.
     35
     36After building, you can run the source tree's {{{bin/tahoe}}} script to
     37create, configure, and use your new Tahoe node. As long as {{{bin/tahoe}}} is
     38left inside the built source tree, it can be run from anywhere (even through a
     39symlink). So until you delete the source tree, you can
     40symlink {{{~/bin/tahoe}}} to your source tree's {{{bin/tahoe}}} and then use
     41it as you would any other system executable.
     42
     43== Installing Outside The Source Tree ==
     44
     45If you want to use Tahoe without keeping the source tree around, you will
     46need to actually install it somewhere. You have several options.
     47
     48=== Installing The Latest Release ===
     49
     50"{{{easy_install allmydata-tahoe}}}", run from any system that has
     51easy_install and setuptools installed, will download the latest release of
     52Tahoe (and its dependencies, all found via PyPI), build everything, and
     53install it into the standard place for python libraries on your system. On
     54unix platforms this usually goes into {{{/usr/lib/python2.5/site-packages/}}}
     55and {{{/usr/bin/tahoe}}} .
     56
     57On Debian or Ubuntu linux systems, you can install pre-compiled packages by
     58adding the allmydata.org APT repository to your {{{/etc/apt/sources.list}}}
     59and installing the "allmydata-tahoe" package. See DownloadDebianPackages for
     60details.
     61
     62Windows users can use an installer, which also provides the
     63[http://allmydata.com AllMyData] backup client, and a SMB/winfuse -based
     64frontend. These installers can be downloaded from (TODO: they're built, but
     65where are they downloadable?).
     66
     67Mac users can use a .dmg file (also an installer?), which provides a simple
     68GUI app to launch the tahoe node. These can be downloaded from (TODO: same
     69problem).
     70
     71=== Installing From A Source Tree ===
     72
     73These commands will take the current source tree and install its contents
     74somewhere else on your system. This is the traditional meaning of "install".
     75
     76The "{{{setup.py install}}}" target will install Tahoe (but not its
     77dependencies) into the standard place for python libraries on your system: on
     78Unix platforms this usually goes into {{{/usr/lib/python2.5/site-packages/}}}
     79and {{{/usr/bin/tahoe}}} .
     80
     81The "{{{make install}}}" target is a wrapper around "{{{setup.py install}}}"
     82that uses {{{--single-version-externally-managed}}} to bypass the extra
     83checking that setuptools does. This allows "{{{make install}}}" and
     84"{{{make install PREFIX=/usr/local}}}" to work the same way as traditional unix
     85software (via GNU autoconf, etc).
     86
     87TODO: There should be some way to use "{{{setup.py easy_install}}}" to install
     88Tahoe '''and''' its dependencies into the system somewhere, but I haven't
     89been able to figure out how.
     90
     91=== Creating a binary distribution From A Source Tree ===
     92
     93These commands will take the current source tree and create a single-file
     94installer (or some other form of binary distribution). The
     95installer-like-thing can then be moved to some other system and installed
     96there.
     97
     98The "{{{setup.py bdist_egg}}}" command will create a single-file .egg in the
     99{{{dist/}}} directory, which can be manually copied onto your PYTHONPATH
     100somewhere. The .egg will declare its dependencies, but will not include them:
     101you must arrange for them to be installed before the .egg will be usable.
     102
     103The "{{{make deb-PLATFORM-head}}}" target (i.e. {{{make deb-hardy-head}}})
     104will create a debian package with the current tree's Tahoe code. This .deb
     105file will be placed in the parent directory. The debian package will declare
     106dependencies on the other libraries that it needs (like foolscap and zfec),
     107but it will not include any code from them. The allmydata.org APT repository
     108(see DownloadDebianPackages for details) has packages for the dependencies
     109that aren't already in Debian proper.
     110
     111The "{{{make windows-exe}}}" and "{{{make windows-installer}}}" commands will
     112create a windows executable, and the corresponding installer.
     113
     114The "{{{make mac-exe}}}" and "{{{make mac-dist}}}" commands will create a
     115Macintosh OS-X executable and the corresponding installer (.dmg) file.
     116
     117== Platform-specific Notes ==
     118
     119=== Debian/Ubuntu ===
     120
     121The Tahoe build process will download and install many of its dependencies
     122when you run {{{make}}} or {{{setup.py build_tahoe}}}. The base set of
     123functionality that it cannot build on its own are provided by the following
     124debian packages (note that the authoritative list of packages is in the
     125"{{{Build-Depends:}}}" clause of
     126[source:misc/sid/debian/control misc/sid/debian/control]):
     127
     128 * build-essential (this includes gcc, g++, make, and the headers in libc-dev)
     129 * debhelper
     130 * cdbs
     131 * python-central
     132 * python-setuptools
     133 * python
     134 * python-dev
     135
     136In addition, to use the "{{{make deb-PLATFORM-head}}}" target, you will also
     137need the "debchange" utility from the "devscripts" package, and the
     138"fakeroot" package.
     139
     140To actually run a Tahoe node from a debian package, you will need the
     141supporting libraries installed. The authoritative list of packages is in the
     142{{{Depends:}}} clause of
     143[source:misc/sid/debian/control misc/sid/debian/control], and includes:
     144
     145 * python-twisted-core
     146 * python-twisted-names
     147 * python-foolscap
     148 * python-pyopenssl
     149 * python-nevow
     150 * python-simplejson
     151 * python-zfec
     152 * python-pycryptopp
     153
     154Even if you don't intend to create a Tahoe .deb package, you can install the
     155supporting libraries from debian packages to reduce the build-time
     156download-and-compile work.
     157