removed contributed build tutorial in favor of the wiki
This commit is contained in:
parent
40804a829b
commit
bc856b768e
|
@ -23,12 +23,11 @@
|
|||
<p class="topic-title first"><a name="table-of-contents">Table of contents</a></p>
|
||||
<ul class="simple">
|
||||
<li><a class="reference" href="#downloading-and-building" id="id8" name="id8">downloading and building</a><ul>
|
||||
<li><a class="reference" href="#contributed-build-tutorials" id="id9" name="id9">Contributed build tutorials</a></li>
|
||||
<li><a class="reference" href="#building-from-svn" id="id10" name="id10">building from svn</a></li>
|
||||
<li><a class="reference" href="#building-with-bbv2" id="id11" name="id11">building with BBv2</a></li>
|
||||
<li><a class="reference" href="#building-with-autotools" id="id12" name="id12">building with autotools</a></li>
|
||||
<li><a class="reference" href="#building-with-other-build-systems" id="id13" name="id13">building with other build systems</a></li>
|
||||
<li><a class="reference" href="#build-configurations" id="id14" name="id14">build configurations</a></li>
|
||||
<li><a class="reference" href="#building-from-svn" id="id9" name="id9">building from svn</a></li>
|
||||
<li><a class="reference" href="#building-with-bbv2" id="id10" name="id10">building with BBv2</a></li>
|
||||
<li><a class="reference" href="#building-with-autotools" id="id11" name="id11">building with autotools</a></li>
|
||||
<li><a class="reference" href="#building-with-other-build-systems" id="id12" name="id12">building with other build systems</a></li>
|
||||
<li><a class="reference" href="#build-configurations" id="id13" name="id13">build configurations</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
@ -41,18 +40,7 @@ You'll find instructions on how to do this <a class="reference" href="http://sou
|
|||
(BBv2) and autotools (for unix-like systems). If you still can't build after
|
||||
following these instructions, you can usually get help in the <tt class="docutils literal"><span class="pre">#libtorrent</span></tt>
|
||||
IRC channel on <tt class="docutils literal"><span class="pre">irc.freenode.net</span></tt>.</p>
|
||||
<div class="section">
|
||||
<h2><a id="contributed-build-tutorials" name="contributed-build-tutorials">Contributed build tutorials</a></h2>
|
||||
<ul class="simple">
|
||||
<li>libtorrent svn, <a class="reference" href="ubuntu_build_notes.html">ubuntu</a></li>
|
||||
<li><a class="reference" href="ubuntu_6_build_notes.html">ubuntu 6.10</a></li>
|
||||
<li><a class="reference" href="suse_build_notes.html">suse</a></li>
|
||||
<li><a class="reference" href="vs2005_build_notes.html">visual studio 2005</a></li>
|
||||
</ul>
|
||||
<p>These tutorials may work on similar linux distros as well.</p>
|
||||
<p>For Gentoo there is an ebuild called "rb_libtorrent" in portage. Another
|
||||
Gentoo ebuild is provided by the <a class="reference" href="http://www.peerweb.nl/gentoo/net-libs/rblibtorrent/">BTG project</a>.</p>
|
||||
</div>
|
||||
<p>Community contributed build tutorials can be found on the <a class="reference" href="http://code.rasterbar.com/libtorrent/wiki/Building">wiki</a>.</p>
|
||||
<div class="section">
|
||||
<h2><a id="building-from-svn" name="building-from-svn">building from svn</a></h2>
|
||||
<p>To build libtorrent from svn you need to check out the libtorrent sources from
|
||||
|
@ -85,10 +73,8 @@ usually not set by the package installer).</p>
|
|||
<p>Extract the archive to some directory where you want it. For the sake of this
|
||||
guide, let's assume you extract the package to <tt class="docutils literal"><span class="pre">c:\boost_1_33_1</span></tt> (I'm using
|
||||
a windows path in this example since if you're on linux/unix you're more likely
|
||||
to use the autotools). You'll need at least version 1.32 of the boost library
|
||||
to use the autotools). You'll need at least version 1.33.1 of the boost library
|
||||
in order to build libtorrent.</p>
|
||||
<p>If you use 1.32, you need to download BBv2 separately, so for now, let's
|
||||
assume you will use version 1.33.1.</p>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h3><a id="step-2-setup-bbv2" name="step-2-setup-bbv2">Step 2: Setup BBv2</a></h3>
|
||||
|
|
|
@ -21,25 +21,9 @@ The build systems supported "out of the box" in libtorrent are boost-build v2
|
|||
following these instructions, you can usually get help in the ``#libtorrent``
|
||||
IRC channel on ``irc.freenode.net``.
|
||||
|
||||
Contributed build tutorials
|
||||
---------------------------
|
||||
Community contributed build tutorials can be found on the wiki_.
|
||||
|
||||
* libtorrent svn, ubuntu_
|
||||
* `ubuntu 6.10`_
|
||||
* suse_
|
||||
* `visual studio 2005`_
|
||||
|
||||
These tutorials may work on similar linux distros as well.
|
||||
|
||||
.. _ubuntu: ubuntu_build_notes.html
|
||||
.. _`ubuntu 6.10`: ubuntu_6_build_notes.html
|
||||
.. _suse: suse_build_notes.html
|
||||
.. _`visual studio 2005`: vs2005_build_notes.html
|
||||
|
||||
For Gentoo there is an ebuild called "rb_libtorrent" in portage. Another
|
||||
Gentoo ebuild is provided by the `BTG project`_.
|
||||
|
||||
.. _`BTG project`: http://www.peerweb.nl/gentoo/net-libs/rblibtorrent/
|
||||
.. _wiki: http://code.rasterbar.com/libtorrent/wiki/Building
|
||||
|
||||
building from svn
|
||||
-----------------
|
||||
|
@ -88,12 +72,9 @@ __ http://sourceforge.net/project/showfiles.php?group_id=7586&package_id=8041&re
|
|||
Extract the archive to some directory where you want it. For the sake of this
|
||||
guide, let's assume you extract the package to ``c:\boost_1_33_1`` (I'm using
|
||||
a windows path in this example since if you're on linux/unix you're more likely
|
||||
to use the autotools). You'll need at least version 1.32 of the boost library
|
||||
to use the autotools). You'll need at least version 1.33.1 of the boost library
|
||||
in order to build libtorrent.
|
||||
|
||||
If you use 1.32, you need to download BBv2 separately, so for now, let's
|
||||
assume you will use version 1.33.1.
|
||||
|
||||
|
||||
Step 2: Setup BBv2
|
||||
~~~~~~~~~~~~~~~~~~
|
||||
|
|
|
@ -1,60 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
|
||||
<title></title>
|
||||
<meta name="author" content="Torsten Bergander" />
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="document">
|
||||
|
||||
<table class="docinfo" frame="void" rules="none">
|
||||
<col class="docinfo-name" />
|
||||
<col class="docinfo-content" />
|
||||
<tbody valign="top">
|
||||
<tr><th class="docinfo-name">Author:</th>
|
||||
<td>Torsten Bergander</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="section">
|
||||
<h1><a id="building-libtorrent-on-suse-10-1-i586" name="building-libtorrent-on-suse-10-1-i586">building libtorrent on SuSE 10.1 (i586)</a></h1>
|
||||
<ol class="arabic" start="0">
|
||||
<li><dl class="first docutils">
|
||||
<dt>Prerequisites</dt>
|
||||
<dd><p class="first">Install packages <tt class="docutils literal"><span class="pre">boost</span></tt> and <tt class="docutils literal"><span class="pre">boost-devel</span></tt> from packman:
|
||||
<a class="reference" href="http://packman.links2linux.org/package/boost/10887">http://packman.links2linux.org/package/boost/10887</a></p>
|
||||
<p class="last">There are standard packages delivered with the distribution. They give
|
||||
some headaches when building new stuff, so the above mentioned ones fix
|
||||
these problems.
|
||||
All other potential prerequisites are available via yast in the standard
|
||||
distribution.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</li>
|
||||
<li><dl class="first docutils">
|
||||
<dt>Building and installing the lib</dt>
|
||||
<dd><p class="first">Get the libtorrent-011 release tarbal, unpack and change into its
|
||||
directory. Then:</p>
|
||||
<pre class="literal-block">
|
||||
./configure --with-boost-date-time=boost_date_time
|
||||
--with-boost-filesystem=boost_filesystem
|
||||
--with-boost-thread=boost_thread-mt --with-boost-regex=boost_regex
|
||||
--with-boost-program-options=boost_program_options --disable-debug
|
||||
make
|
||||
sudo make install
|
||||
</pre>
|
||||
<p class="last">If you don't give the --with-boost parameters configure does not find
|
||||
the main in the libs and fails. Also, when later installing e.g. btg,
|
||||
you have to make sure to use the same parameters there, otherwise it is
|
||||
bound to fail.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,31 +0,0 @@
|
|||
:Author: Torsten Bergander
|
||||
|
||||
building libtorrent on SuSE 10.1 (i586)
|
||||
=======================================
|
||||
|
||||
0. Prerequisites
|
||||
Install packages ``boost`` and ``boost-devel`` from packman:
|
||||
http://packman.links2linux.org/package/boost/10887
|
||||
|
||||
There are standard packages delivered with the distribution. They give
|
||||
some headaches when building new stuff, so the above mentioned ones fix
|
||||
these problems.
|
||||
All other potential prerequisites are available via yast in the standard
|
||||
distribution.
|
||||
|
||||
1. Building and installing the lib
|
||||
Get the libtorrent-011 release tarbal, unpack and change into its
|
||||
directory. Then::
|
||||
|
||||
./configure --with-boost-date-time=boost_date_time
|
||||
--with-boost-filesystem=boost_filesystem
|
||||
--with-boost-thread=boost_thread-mt --with-boost-regex=boost_regex
|
||||
--with-boost-program-options=boost_program_options --disable-debug
|
||||
make
|
||||
sudo make install
|
||||
|
||||
If you don't give the --with-boost parameters configure does not find
|
||||
the main in the libs and fails. Also, when later installing e.g. btg,
|
||||
you have to make sure to use the same parameters there, otherwise it is
|
||||
bound to fail.
|
||||
|
|
@ -1,55 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
|
||||
<title></title>
|
||||
<meta name="author" content="Torsten Bergander" />
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="document">
|
||||
|
||||
<table class="docinfo" frame="void" rules="none">
|
||||
<col class="docinfo-name" />
|
||||
<col class="docinfo-content" />
|
||||
<tbody valign="top">
|
||||
<tr><th class="docinfo-name">Author:</th>
|
||||
<td>Torsten Bergander</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="section">
|
||||
<h1><a id="building-libtorrent-0-11-on-ubuntu-edy-eft-6-10" name="building-libtorrent-0-11-on-ubuntu-edy-eft-6-10">building libtorrent-0.11 on ubuntu Edy Eft 6.10</a></h1>
|
||||
<ol class="arabic">
|
||||
<li><p class="first">Install prerequisites (maybe cann be stripped down but it works):</p>
|
||||
<pre class="literal-block">
|
||||
sudo apt-get install bjam boost-build libboost-date-time-dev
|
||||
libboost-date-time1.33.1 libboost-filesystem-dev
|
||||
libboost-filesystem1.33.1 libboost-graph-dev libboost-graph1.33.1
|
||||
libboost-iostreams-dev libboost-iostreams1.33.1
|
||||
libboost-program-options-dev libboost-program-options1.33.1
|
||||
libboost-regex-dev libboost-regex1.33.1 libboost-serialization-dev
|
||||
libboost-signals-dev libboost-signals1.33.1 libboost-test-dev
|
||||
libboost-test1.33.1 libboost-thread-dev libboost-thread1.33.1
|
||||
libboost-wave-dev libboost-dev
|
||||
</pre>
|
||||
</li>
|
||||
<li><p class="first">Get release tar ball (0.11 at time of writing), unpack, change into:</p>
|
||||
<pre class="literal-block">
|
||||
libtorrent-0.11 dir
|
||||
</pre>
|
||||
</li>
|
||||
<li><p class="first">Build and install:</p>
|
||||
<pre class="literal-block">
|
||||
export BOOST_BUILD_PATH=/usr/share/boost-build/tools
|
||||
./configure
|
||||
make
|
||||
sudo make install
|
||||
</pre>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,29 +0,0 @@
|
|||
:Author: Torsten Bergander
|
||||
|
||||
building libtorrent-0.11 on ubuntu Edy Eft 6.10
|
||||
===============================================
|
||||
|
||||
1. Install prerequisites (maybe cann be stripped down but it works)::
|
||||
|
||||
sudo apt-get install bjam boost-build libboost-date-time-dev
|
||||
libboost-date-time1.33.1 libboost-filesystem-dev
|
||||
libboost-filesystem1.33.1 libboost-graph-dev libboost-graph1.33.1
|
||||
libboost-iostreams-dev libboost-iostreams1.33.1
|
||||
libboost-program-options-dev libboost-program-options1.33.1
|
||||
libboost-regex-dev libboost-regex1.33.1 libboost-serialization-dev
|
||||
libboost-signals-dev libboost-signals1.33.1 libboost-test-dev
|
||||
libboost-test1.33.1 libboost-thread-dev libboost-thread1.33.1
|
||||
libboost-wave-dev libboost-dev
|
||||
|
||||
2. Get release tar ball (0.11 at time of writing), unpack, change into::
|
||||
|
||||
libtorrent-0.11 dir
|
||||
|
||||
3. Build and install::
|
||||
|
||||
export BOOST_BUILD_PATH=/usr/share/boost-build/tools
|
||||
./configure
|
||||
make
|
||||
sudo make install
|
||||
|
||||
|
|
@ -1,155 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
|
||||
<title>Building libtorrent on Ubuntu 6.06</title>
|
||||
<meta name="date" content="Nov 6, 2006" />
|
||||
<meta name="authors" content="Xi Stan Francois Dermu" />
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="document" id="building-libtorrent-on-ubuntu-6-06">
|
||||
<h1 class="title">Building libtorrent on Ubuntu 6.06</h1>
|
||||
<table class="docinfo" frame="void" rules="none">
|
||||
<col class="docinfo-name" />
|
||||
<col class="docinfo-content" />
|
||||
<tbody valign="top">
|
||||
<tr><th class="docinfo-name">Date:</th>
|
||||
<td>Nov 6, 2006</td></tr>
|
||||
<tr><th class="docinfo-name">Authors:</th>
|
||||
<td>Xi Stan
|
||||
<br />Francois Dermu</td></tr>
|
||||
<tr><th class="docinfo-name">Contact:</th>
|
||||
<td><a class="first last reference" href="mailto:stan8688@gmail.com">stan8688@gmail.com</a></td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="section">
|
||||
<h1><a id="prerequisites" name="prerequisites">Prerequisites</a></h1>
|
||||
<p>To build libtorrent, you need the following libraries:</p>
|
||||
<ul class="simple">
|
||||
<li><a class="reference" href="http://www.rasterbar.com/products/libtorrent/index.html">http://www.rasterbar.com/products/libtorrent/index.html</a></li>
|
||||
<li><a class="reference" href="http://www.boost.org">http://www.boost.org</a></li>
|
||||
<li><a class="reference" href="http://asio.sourceforge.net/">http://asio.sourceforge.net/</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="step-1-acquire-the-source-code-from-cvs" name="step-1-acquire-the-source-code-from-cvs">Step 1: Acquire the source code from cvs</a></h1>
|
||||
<p>Create a directory for the project:</p>
|
||||
<pre class="literal-block">
|
||||
mkdir ${HOME}/work
|
||||
cd ${HOME}/work
|
||||
</pre>
|
||||
<p>Check out <tt class="docutils literal"><span class="pre">boost</span></tt>, <tt class="docutils literal"><span class="pre">libtorrent</span></tt>, <tt class="docutils literal"><span class="pre">asio</span></tt> source code from cvs
|
||||
by executing the following commands:</p>
|
||||
<p><em>No password needed (just hit enter when prompted)</em></p>
|
||||
<pre class="literal-block">
|
||||
cvs -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost login
|
||||
cvs -z3 -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost checkout boost
|
||||
cvs -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost logout
|
||||
|
||||
cvs -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent login
|
||||
cvs -z3 -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent co -P libtorrent
|
||||
cvs -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent logout
|
||||
|
||||
cvs -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio login
|
||||
cvs -z3 -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio co -P asio
|
||||
cvs -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio login
|
||||
</pre>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="step-2-building-boost" name="step-2-building-boost">Step 2: Building boost</a></h1>
|
||||
<p>To build boost, first build boost-build and then use that to build
|
||||
the libraries themselves:</p>
|
||||
<pre class="literal-block">
|
||||
BASE_DIR=${HOME} <em>### Feel free to change this one.</em>
|
||||
BOOST_ROOT=${BASE_DIR}/boost
|
||||
BOOST_BUILD_PATH=${BOOST_ROOT}/tools/build/v2
|
||||
cd ${BOOST_ROOT}/tools/jam/src
|
||||
./build.sh
|
||||
sudo cp ./bin.linuxx86/bjam /usr/bin
|
||||
cd $BOOST_ROOT
|
||||
sudo bjam -sTOOLS=gcc install
|
||||
</pre>
|
||||
<p><em>It takes about 45 min. (so if you want to grap a coke, now is the time)</em></p>
|
||||
<p>If you're successful you will see the following files in <tt class="docutils literal"><span class="pre">/usr/local/lib</span></tt>:</p>
|
||||
<pre class="literal-block">
|
||||
libboost_date_time-gcc-d-1_31.so
|
||||
libboost_date_time-gcc-mt-d-1_31.so
|
||||
libboost_date_time-gcc-1_31.so
|
||||
libboost_date_time-gcc-mt-1_31.so
|
||||
libboost_date_time-gcc-d-1_31.a
|
||||
libboost_date_time-gcc-mt-d-1_31.a
|
||||
libboost_date_time-gcc-1_31.a
|
||||
libboost_date_time-gcc-mt-1_31.a
|
||||
</pre>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="step-3-copy-asio-into-the-libtorrent-directory" name="step-3-copy-asio-into-the-libtorrent-directory">Step 3: Copy asio into the libtorrent directory</a></h1>
|
||||
<p>Skip this step if you're using a released tarball.</p>
|
||||
<p>Execute the following command:</p>
|
||||
<pre class="literal-block">
|
||||
cp -R ${BASE_DIR}/asio/include/asio* ${BASE_DIR}/libtorrent/include/libtorrent
|
||||
</pre>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="step-4-building-libtorrent" name="step-4-building-libtorrent">Step 4: Building libtorrent</a></h1>
|
||||
<div class="section">
|
||||
<h2><a id="building-with-autotools" name="building-with-autotools">building with autotools</a></h2>
|
||||
<p>First of all, you need to install automake and autoconf. Many unix/linux systems
|
||||
comes with these preinstalled. The prerequisites for building libtorrent are
|
||||
boost.thread, boost.date_time and boost.filesystem. Those are the <em>compiled</em> boost
|
||||
libraries needed. The headers-only libraries needed include (but is not necessarily
|
||||
limited to) boost.bind, boost.ref, boost.multi_index, boost.optional,
|
||||
boost.lexical_cast, boost.integer, boost.iterator, boost.tuple, boost.array,
|
||||
boost.function, boost.smart_ptr, boost.preprocessor, boost.static_assert.</p>
|
||||
<p>If you want to build the client_test example, you'll also need boost.regex and boost.program_options.</p>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h2><a id="generating-the-build-system" name="generating-the-build-system">generating the build system</a></h2>
|
||||
<p>No build system is present if libtorrent is checked out from CVS - it needs to be
|
||||
generated first. If you're building from a released tarball, you may skip directly
|
||||
to <a class="reference" href="#running-configure">running configure</a>.</p>
|
||||
<p>Execute the following commands, in the given order, to generate the build system:</p>
|
||||
<pre class="literal-block">
|
||||
cd ${BASE_DIR}/libtorrent
|
||||
CXXFLAGS="-I/usr/local/include/boost-1_35 -I${BASE_DIR}/libtorrent/include/libtorrent"
|
||||
LDFLAGS=-L/usr/local/lib
|
||||
|
||||
aclocal -I m4
|
||||
autoheader
|
||||
libtoolize --copy --force
|
||||
automake --add-missing --copy --gnu
|
||||
autoconf
|
||||
</pre>
|
||||
<p>On darwin/OSX you have to run glibtoolize instead of libtoolize.</p>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h2><a id="running-configure" name="running-configure">running configure</a></h2>
|
||||
<p>To use the auto tools to build libtorrent, execute the following commands:</p>
|
||||
<pre class="literal-block">
|
||||
cd ${BASE_DIR}/libtorrent
|
||||
CXXFLAGS="-I/usr/local/include/boost-1_35 -I${BASE_DIR}/libtorrent/include/libtorrent"
|
||||
LDFLAGS=-L/usr/local/lib
|
||||
|
||||
./configure --with-boost-date-time=boost_date_time-gcc \
|
||||
--with-boost-filesystem=boost_filesystem-gcc \
|
||||
--with-boost-thread=boost_thread-gcc-mt
|
||||
|
||||
make
|
||||
sudo make install
|
||||
</pre>
|
||||
<p>If successful, you will see the following files:</p>
|
||||
<pre class="literal-block">
|
||||
/usr/local/lib/libtorrent.a
|
||||
/usr/local/lib/libtorrent.so.0
|
||||
/usr/local/lib/libtorrent.la
|
||||
/usr/local/lib/libtorrent.so.0.1.0
|
||||
/usr/local/lib/libtorrent.so
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,146 +0,0 @@
|
|||
==================================
|
||||
Building libtorrent on Ubuntu 6.06
|
||||
==================================
|
||||
|
||||
:Date: Nov 6, 2006
|
||||
:Authors: Xi Stan, Francois Dermu
|
||||
:Contact: stan8688@gmail.com
|
||||
|
||||
|
||||
Prerequisites
|
||||
=============
|
||||
|
||||
To build libtorrent, you need the following libraries:
|
||||
|
||||
* http://www.rasterbar.com/products/libtorrent/index.html
|
||||
* http://www.boost.org
|
||||
* http://asio.sourceforge.net/
|
||||
|
||||
Step 1: Acquire the source code from cvs
|
||||
========================================
|
||||
|
||||
Create a directory for the project::
|
||||
|
||||
mkdir ${HOME}/work
|
||||
cd ${HOME}/work
|
||||
|
||||
Check out ``boost``, ``libtorrent``, ``asio`` source code from cvs
|
||||
by executing the following commands:
|
||||
|
||||
*No password needed (just hit enter when prompted)*
|
||||
|
||||
::
|
||||
|
||||
cvs -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost login
|
||||
cvs -z3 -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost checkout boost
|
||||
cvs -d:pserver:anonymous@boost.cvs.sourceforge.net:/cvsroot/boost logout
|
||||
|
||||
cvs -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent login
|
||||
cvs -z3 -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent co -P libtorrent
|
||||
cvs -d:pserver:anonymous@libtorrent.cvs.sourceforge.net:/cvsroot/libtorrent logout
|
||||
|
||||
cvs -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio login
|
||||
cvs -z3 -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio co -P asio
|
||||
cvs -d:pserver:anonymous@asio.cvs.sourceforge.net:/cvsroot/asio login
|
||||
|
||||
Step 2: Building boost
|
||||
======================
|
||||
|
||||
To build boost, first build boost-build and then use that to build
|
||||
the libraries themselves:
|
||||
|
||||
.. parsed-literal::
|
||||
|
||||
BASE_DIR=${HOME} *### Feel free to change this one.*
|
||||
BOOST_ROOT=${BASE_DIR}/boost
|
||||
BOOST_BUILD_PATH=${BOOST_ROOT}/tools/build/v2
|
||||
cd ${BOOST_ROOT}/tools/jam/src
|
||||
./build.sh
|
||||
sudo cp ./bin.linuxx86/bjam /usr/bin
|
||||
cd $BOOST_ROOT
|
||||
sudo bjam -sTOOLS=gcc install
|
||||
|
||||
*It takes about 45 min. (so if you want to grap a coke, now is the time)*
|
||||
|
||||
|
||||
If you're successful you will see the following files in ``/usr/local/lib``::
|
||||
|
||||
libboost_date_time-gcc-d-1_31.so
|
||||
libboost_date_time-gcc-mt-d-1_31.so
|
||||
libboost_date_time-gcc-1_31.so
|
||||
libboost_date_time-gcc-mt-1_31.so
|
||||
libboost_date_time-gcc-d-1_31.a
|
||||
libboost_date_time-gcc-mt-d-1_31.a
|
||||
libboost_date_time-gcc-1_31.a
|
||||
libboost_date_time-gcc-mt-1_31.a
|
||||
|
||||
Step 3: Copy asio into the libtorrent directory
|
||||
===============================================
|
||||
|
||||
Skip this step if you're using a released tarball.
|
||||
|
||||
Execute the following command::
|
||||
|
||||
cp -R ${BASE_DIR}/asio/include/asio* ${BASE_DIR}/libtorrent/include/libtorrent
|
||||
|
||||
Step 4: Building libtorrent
|
||||
===========================
|
||||
|
||||
building with autotools
|
||||
-----------------------
|
||||
|
||||
First of all, you need to install automake and autoconf. Many unix/linux systems
|
||||
comes with these preinstalled. The prerequisites for building libtorrent are
|
||||
boost.thread, boost.date_time and boost.filesystem. Those are the *compiled* boost
|
||||
libraries needed. The headers-only libraries needed include (but is not necessarily
|
||||
limited to) boost.bind, boost.ref, boost.multi_index, boost.optional,
|
||||
boost.lexical_cast, boost.integer, boost.iterator, boost.tuple, boost.array,
|
||||
boost.function, boost.smart_ptr, boost.preprocessor, boost.static_assert.
|
||||
|
||||
If you want to build the client_test example, you'll also need boost.regex and boost.program_options.
|
||||
|
||||
generating the build system
|
||||
---------------------------
|
||||
|
||||
No build system is present if libtorrent is checked out from CVS - it needs to be
|
||||
generated first. If you're building from a released tarball, you may skip directly
|
||||
to `running configure`_.
|
||||
|
||||
Execute the following commands, in the given order, to generate the build system::
|
||||
|
||||
cd ${BASE_DIR}/libtorrent
|
||||
CXXFLAGS="-I/usr/local/include/boost-1_35 -I${BASE_DIR}/libtorrent/include/libtorrent"
|
||||
LDFLAGS=-L/usr/local/lib
|
||||
|
||||
aclocal -I m4
|
||||
autoheader
|
||||
libtoolize --copy --force
|
||||
automake --add-missing --copy --gnu
|
||||
autoconf
|
||||
|
||||
On darwin/OSX you have to run glibtoolize instead of libtoolize.
|
||||
|
||||
running configure
|
||||
-----------------
|
||||
|
||||
To use the auto tools to build libtorrent, execute the following commands::
|
||||
|
||||
cd ${BASE_DIR}/libtorrent
|
||||
CXXFLAGS="-I/usr/local/include/boost-1_35 -I${BASE_DIR}/libtorrent/include/libtorrent"
|
||||
LDFLAGS=-L/usr/local/lib
|
||||
|
||||
./configure --with-boost-date-time=boost_date_time-gcc \
|
||||
--with-boost-filesystem=boost_filesystem-gcc \
|
||||
--with-boost-thread=boost_thread-gcc-mt
|
||||
|
||||
make
|
||||
sudo make install
|
||||
|
||||
If successful, you will see the following files::
|
||||
|
||||
/usr/local/lib/libtorrent.a
|
||||
/usr/local/lib/libtorrent.so.0
|
||||
/usr/local/lib/libtorrent.la
|
||||
/usr/local/lib/libtorrent.so.0.1.0
|
||||
/usr/local/lib/libtorrent.so
|
||||
|
|
@ -1,117 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
|
||||
<title>libtorrent setup for VS.NET 2005 Development</title>
|
||||
<meta name="author" content="THOMAS GODDARD" />
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="document" id="libtorrent-setup-for-vs-net-2005-development">
|
||||
<h1 class="title">libtorrent setup for VS.NET 2005 Development</h1>
|
||||
<table class="docinfo" frame="void" rules="none">
|
||||
<col class="docinfo-name" />
|
||||
<col class="docinfo-content" />
|
||||
<tbody valign="top">
|
||||
<tr><th class="docinfo-name">Author:</th>
|
||||
<td>THOMAS GODDARD</td></tr>
|
||||
<tr><th class="docinfo-name">Contact:</th>
|
||||
<td>www.thomasgoddard.com</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="section">
|
||||
<h1><a id="prerequisites" name="prerequisites">Prerequisites</a></h1>
|
||||
<ol class="arabic simple">
|
||||
<li>Download boost from boost.org</li>
|
||||
<li>Download libtorrent</li>
|
||||
<li>Extract both to a folder called libtorrent</li>
|
||||
</ol>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="compiling-boost-for-vs-net-2005" name="compiling-boost-for-vs-net-2005">Compiling boost for VS.NET 2005</a></h1>
|
||||
<ol class="arabic simple">
|
||||
<li>Copy bjam.exe to libtorrent\boost_[version]\tools\build</li>
|
||||
<li>Add the path "libtorrent\boost_[version]\tools\build" to the windows path environment variable</li>
|
||||
<li>Log off / log back on</li>
|
||||
<li>Open the file "libtorrent\boost_[version]\tools\build\user-config.jam" in notepad</li>
|
||||
<li>Uncomment the <tt class="docutils literal"><span class="pre">#</span> <span class="pre">using</span> <span class="pre">msvc;</span></tt> line by removing the #</li>
|
||||
<li>Replace the line with: <tt class="docutils literal"><span class="pre">using</span> <span class="pre">vc-8_0</span> <span class="pre">;</span></tt></li>
|
||||
<li>Save the file and close it</li>
|
||||
<li>Open the visual studio .net command line in the VS.net 2005 folder in your start menu</li>
|
||||
<li>CD to the "libtorrent\boost_[version]" folder</li>
|
||||
<li>Type: <tt class="docutils literal"><span class="pre">bjam</span> <span class="pre">"-sTOOLS=vc-8_0"</span> <span class="pre">install</span></tt> and hit enter</li>
|
||||
<li>Be patient and wait for it to finish</li>
|
||||
</ol>
|
||||
<div class="section">
|
||||
<h2><a id="troubleshooting" name="troubleshooting">Troubleshooting</a></h2>
|
||||
<ul class="simple">
|
||||
<li>Make sure to CD to the root of the boost directory before running the install.</li>
|
||||
<li>For additional details and information on using Visual Studio 2005 Express addition, see the Boost Getting Started Guide.</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h1><a id="setting-up-and-compiling-libtorrent-with-vs-net-2005" name="setting-up-and-compiling-libtorrent-with-vs-net-2005">Setting up and compiling libtorrent with VS.NET 2005</a></h1>
|
||||
<ol class="arabic">
|
||||
<li><p class="first">Create a new vs.net 2005 MFC project and solution file in the root of the libtorrent folder where you extracted all of the libtorrent files.</p>
|
||||
</li>
|
||||
<li><p class="first">Include the files contained in the src folder, excluding the makefiles.
|
||||
<strong>NOTE:</strong>
|
||||
Only include either file.cpp or file_win.cpp. Read here to determine which file to include:
|
||||
<a class="reference" href="http://www.rasterbar.com/products/libtorrent/docs.html#building-with-other-build-systems">http://www.rasterbar.com/products/libtorrent/docs.html#building-with-other-build-systems</a></p>
|
||||
</li>
|
||||
<li><p class="first">Include all .c files in the zlib folder.</p>
|
||||
</li>
|
||||
<li><p class="first">Add the following Additional Include Header Files:</p>
|
||||
<pre class="literal-block">
|
||||
"libtorrent\include"
|
||||
"C:\Boost\include\boost-1_33_1"
|
||||
"libtorrent\zlib"
|
||||
"libtorrent\include\libtorrent"
|
||||
</pre>
|
||||
</li>
|
||||
<li><p class="first">Add the following Preprocessor Definitions:</p>
|
||||
<pre class="literal-block">
|
||||
WIN32
|
||||
WIN32_LEAN_AND_MEAN
|
||||
_WIN32_WINNT=0x0500
|
||||
BOOST_ALL_NO_LIB
|
||||
_FILE_OFFSET_BITS=64
|
||||
BOOST_THREAD_USE_LIB
|
||||
TORRENT_BUILDING_SHARED
|
||||
TORRENT_LINKING_SHARED
|
||||
UNICODE
|
||||
</pre>
|
||||
</li>
|
||||
<li><p class="first">Add <tt class="docutils literal"><span class="pre">C:\Boost\lib</span></tt> to Additional Library Directories</p>
|
||||
</li>
|
||||
<li><p class="first">Add the following Additional Dependencies:</p>
|
||||
<pre class="literal-block">
|
||||
wsock32.lib
|
||||
libboost_thread-vc80-mt.lib
|
||||
libboost_filesystem-vc80-mt.lib
|
||||
libboost_date_time-vc80-mt.lib
|
||||
</pre>
|
||||
</li>
|
||||
<li><p class="first">Set the Runtime Library to Multi-threaded Debug DLL (/MDd) under the code generation section.</p>
|
||||
</li>
|
||||
</ol>
|
||||
<div class="section">
|
||||
<h2><a id="id1" name="id1">Troubleshooting</a></h2>
|
||||
<dl class="docutils">
|
||||
<dt>Error: error LNK2005:already defined etc...</dt>
|
||||
<dd>Make sure you use the Multi-threaded Debug DLL (/MDd)</dd>
|
||||
<dt>Error: error linking zlib related files...</dt>
|
||||
<dd>Make sure to include all .c files in the zlib folder.</dd>
|
||||
<dt>Runtime error in client_test.exe</dt>
|
||||
<dd>If you're using boost-1.33.1, there is a bug in the program options
|
||||
library which will make VS.NET 2005 assert. For a patch, see:
|
||||
<a class="reference" href="http://thread.gmane.org/gmane.comp.lib.boost.devel/140932/focus=140932">http://thread.gmane.org/gmane.comp.lib.boost.devel/140932/focus=140932</a></dd>
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,92 +0,0 @@
|
|||
============================================
|
||||
libtorrent setup for VS.NET 2005 Development
|
||||
============================================
|
||||
|
||||
:Author: THOMAS GODDARD
|
||||
:Contact: www.thomasgoddard.com
|
||||
|
||||
Prerequisites
|
||||
-------------
|
||||
|
||||
1. Download boost from boost.org
|
||||
2. Download libtorrent
|
||||
3. Extract both to a folder called libtorrent
|
||||
|
||||
Compiling boost for VS.NET 2005
|
||||
-------------------------------
|
||||
|
||||
1. Copy bjam.exe to libtorrent\\boost_[version]\\tools\\build
|
||||
2. Add the path "libtorrent\\boost_[version]\\tools\\build" to the windows path environment variable
|
||||
3. Log off / log back on
|
||||
4. Open the file "libtorrent\\boost_[version]\\tools\\build\\user-config.jam" in notepad
|
||||
5. Uncomment the ``# using msvc;`` line by removing the #
|
||||
6. Replace the line with: ``using vc-8_0 ;``
|
||||
7. Save the file and close it
|
||||
8. Open the visual studio .net command line in the VS.net 2005 folder in your start menu
|
||||
9. CD to the "libtorrent\\boost_[version]" folder
|
||||
10. Type: ``bjam "-sTOOLS=vc-8_0" install`` and hit enter
|
||||
11. Be patient and wait for it to finish
|
||||
|
||||
Troubleshooting
|
||||
...............
|
||||
|
||||
* Make sure to CD to the root of the boost directory before running the install.
|
||||
|
||||
* For additional details and information on using Visual Studio 2005 Express addition, see the Boost Getting Started Guide.
|
||||
|
||||
Setting up and compiling libtorrent with VS.NET 2005
|
||||
-----------------------------------------------------
|
||||
|
||||
1. Create a new vs.net 2005 MFC project and solution file in the root of the libtorrent folder where you extracted all of the libtorrent files.
|
||||
2. Include the files contained in the src folder, excluding the makefiles.
|
||||
**NOTE:**
|
||||
Only include either file.cpp or file_win.cpp. Read here to determine which file to include:
|
||||
http://www.rasterbar.com/products/libtorrent/docs.html#building-with-other-build-systems
|
||||
|
||||
3. Include all .c files in the zlib folder.
|
||||
|
||||
4. Add the following Additional Include Header Files::
|
||||
|
||||
"libtorrent\include"
|
||||
"C:\Boost\include\boost-1_33_1"
|
||||
"libtorrent\zlib"
|
||||
"libtorrent\include\libtorrent"
|
||||
|
||||
5. Add the following Preprocessor Definitions::
|
||||
|
||||
WIN32
|
||||
WIN32_LEAN_AND_MEAN
|
||||
_WIN32_WINNT=0x0500
|
||||
BOOST_ALL_NO_LIB
|
||||
_FILE_OFFSET_BITS=64
|
||||
BOOST_THREAD_USE_LIB
|
||||
TORRENT_BUILDING_SHARED
|
||||
TORRENT_LINKING_SHARED
|
||||
UNICODE
|
||||
|
||||
6. Add ``C:\Boost\lib`` to Additional Library Directories
|
||||
|
||||
7. Add the following Additional Dependencies::
|
||||
|
||||
wsock32.lib
|
||||
libboost_thread-vc80-mt.lib
|
||||
libboost_filesystem-vc80-mt.lib
|
||||
libboost_date_time-vc80-mt.lib
|
||||
|
||||
8. Set the Runtime Library to Multi-threaded Debug DLL (/MDd) under the code generation section.
|
||||
|
||||
|
||||
Troubleshooting
|
||||
...............
|
||||
|
||||
Error: error LNK2005:already defined etc...
|
||||
Make sure you use the Multi-threaded Debug DLL (/MDd)
|
||||
|
||||
Error: error linking zlib related files...
|
||||
Make sure to include all .c files in the zlib folder.
|
||||
|
||||
Runtime error in client_test.exe
|
||||
If you're using boost-1.33.1, there is a bug in the program options
|
||||
library which will make VS.NET 2005 assert. For a patch, see:
|
||||
http://thread.gmane.org/gmane.comp.lib.boost.devel/140932/focus=140932
|
||||
|
Loading…
Reference in New Issue