Sysadmin > SolarIs > RtorrentSolaris10 > Rtorrent086Solaris10

How to build libtorrent / rtorrent 0.12.6 / 0.8.6 on Solaris 10

I used the instructions on page Building rTorrent on Solaris and modified it.

Getting rTorrent/libTorrent Sources, patching it and building it

These instructions are tested with rTorrent 0.8.5 -- 0.8.6 and libTorrent 0.12.5 -- 0.12.6 but it may work with other versions too.


Patching and building libtorrent

Open a new terminal and untar the libTorrent source and change directory

gtar xzfv libtorrent-0.12.6.tar.gz
cd libtorrent-0.12.6/

Next, get the patches for solairs and apply them with gpatch

The link to the patch doesn't work anymore. I have a copy of the same or a similar patch here.

gpatch -p1 < libtorrent-0.12.5-solaris-madvise.patch

Now, we will build it

export PKG_CONFIG_PATH=/opt/pkg/lib/pkgconfig
./configure --with-gnu-ld --prefix=/opt/local
gmake install

Patching and building rtorrent

Change back to the directory with your rtorrent sources and untar it:

cd ../
tar xzfv rtorrent-0.8.6.tar.gz
cd rtorrent-0.8.6/

Download and patch rtorrent

gpatch -p1 < rtorrent-0.8.5-solaris.patch

And now, build it

export LD_LIBRARY_PATH=/opt/local/lib:/opt/pkg/lib
export PKG_CONFIG_PATH=/opt/pkg/lib/pkgconfig:/opt/local/lib/pkgconfig
export CPPFLAGS="-I/opt/pkg/include/ncurses -I/opt/local/include"
export LDFLAGS="-L/opt/pkg/lib -L/opt/local/lib -R/opt/pkg/lib -R/opt/local/lib -lncurses"
./configure --with-xmlrpc-c=/opt/pkg/bin/xmlrpc-c-config --with-gnu-ld --prefix=/opt/local
gmake install