This documents how to compile the latest sources from Retroshare subversion repository on Linux.
First, you need to install the packages needed for compiling RetroShare.
sudo apt-get install g++ libgnome-keyring-dev libqt4-dev libxss-dev libssl-dev \ libupnp-dev subversion libbz2-dev libprotobuf-dev protobuf-compiler cmake libsqlite3-dev
If you just want to build retroshare-gui, you won't need "libprotobuf-dev", "protobuf-compiler", "cmake" and "libbz2-dev".
If you want to compile the VOIP plugin, you will need to also install qtmobility-dev as:
sudo apt-get install qtmobility-dev
pacman -S pkg-config subversion openssl libupnp libgnome-keyring libxss qt4 protobuf cmake
- bzip2 is in the "base" package, and thus should be installed already.
- pkg-config is in "base-devel" and is likely to be installed, too. (Using the Raspberry-Pi-Arch-Image it seems to be necessary to install it.)
- If you just want to build retroshare-gui, you won't need "protobuf" and "cmake".
Note: In the this section, you can use another directory instead of ~, too.
Note: The -j parameter to make is the number of cores used, and should be changed accordingly to fasten compilation.
To get version 0.6 (which is the current trunk, and is not backward compatible to 0.5.*):
cd ~/ svn co svn://svn.code.sf.net/p/retroshare/code/trunk retroshare06
To get version 0.5.*, which is not forward compatible to 0.6.*:
cd ~ svn checkout svn://svn.code.sf.net/p/retroshare/code/branches/v0.5.5/ retroshare05
You can keep the checked-out source code up-to-date by running
Note: replace the "qmake" command with "qmake-qt4" on Arch Linux, Debian (and maybe other distros).
Note: The make -j[number] makes the compiler use more cores. If you have more than 2 cores, change to the appropriate number.
cd ~/retroshare/libbitdht/src && qmake && make clean && make -j2 cd ~/retroshare/openpgpsdk/src && qmake && make clean && make -j2 cd ~/retroshare/libretroshare/src && qmake && make clean && make -j2 cd ~/retroshare/retroshare-gui/src && qmake && make clean && make -j2
retroshare-nogui depends on the libssh library 0.5.4, which is used for the RPC via SSH protocol.
If your distribution already provides the current libssh version, you can install the libssh-dev package from your distribution, otherwise, you need to download and build this library yourself:
cd ~ mkdir lib/ && cd lib/ wget https://red.libssh.org/attachments/download/41/libssh-0.5.4.tar.gz tar zxvf libssh-0.5.4.tar.gz cd libssh-0.5.4/ mkdir build/ && cd build/ cmake -DWITH_STATIC_LIB=ON .. make -j2
Now you can build retroshare-nogui:
cd ~/retroshare/rsctrl/src && make -j2 cd ~/retroshare/retroshare-nogui/src && qmake && make clean && make -j2
Please note that after compiling, you must copy the .so. files into you ~/.retroshare/extensions folder, enable them in RetroShare, and then restart RetroShare.
You should recompile them after every update to a new release.
VOIPYou will find this plugin in
Call qmake and make.
The qtmobility library is needed on Debian.
In version 0.6.*, there are some additional requirements:
sudo apt-get install libopencv-dev sudo apt-get install build-essential checkinstall cmake pkg-config yasm sudo apt-get install libtiff4-dev libjpeg-dev libjasper-dev
You may need some or all of these packages to add video capturing/encoding capabilitys to the highgui module.
sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev libdc1394-22-dev libxine-dev libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev libv4l-dev
Packages needed to build the Python wrappers
sudo apt-get install python-dev python-numpy
Install Intel TBB to enable parallel code in OpenCV.
sudo apt-get install libtbb-dev
Now Download OpenCV Open Source Computer Vision Library from http://sourceforge.net/projects/opencvlibrary/ Compile and Install ( adjust version # if different ).
tar -xvf OpenCV-2.4.0.tar.bz2 cd OpenCV-2.4.0/ mkdir build cd build cmake -D WITH_QT=ON -D WITH_XINE=ON -D WITH_OPENGL=ON -D WITH_TBB=ON -D BUILD_EXAMPLES=ON ..
Notice, that by adding the -D WITH_QT=ON, the highgui module will use QT instead of GTK. If you want to go with GTK just remove this. For more information on the options, look at the CMakeLists.txt file. When you are happy with the configuration you have, you can start/finish compiling the OpenCV
make sudo make install
Finally, make sure that your programs can link to the OpenCV library in run-time by adding the following line at the end of your /etc/ld.so.conf:
And then configure the dynamic linker run-time bindings:
Now with the successful compile of the OpenCV Library we can perform some quick tests using some examples in the source as well as possible small test additions.
Reference for OpenCV
OpenCV Open Source Computer Vision Library http://sourceforge.net/projects/opencvlibrary/
This plugin allows news feeds into Retroshare. You can keep them as local for yourself, or feed through to a forum to share with others.You will find this plugin in
Call qmake and make.
This plugin allows sharing of web links.You will find this plugin in
Call qmake and make.
The information in this section is how to compile retroshare-gui with the new experimental GXS cache system. As librarys/dependancies may change, the instructions here may change a lot and may be incomplete.
You will need libsqlite3 (should be included in your distro) and the sqlcipher extension library.
You will need sqlcipher library for encrypting the gxs local storage. Using the same directory structure as above:
cd ~/lib/ git clone https://github.com/sqlcipher/sqlcipher.git cd sqlcipher/ ./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="-lcrypto" make -j2
If it doesn't work, try changing the linker flags to LDFLAGS="/usr/lib/libcrypto.a" (change the path to the location of "libcrypto.a" on your distribution).
cd ~/retroshare/supportlibs/pegmarkdown && qmake && make clean && make -j2
enable gxs in *.pro files
Uncomment the line
#config += gxs debug
in both "~/retroshare/libretroshare/src/libretroshare.pro" and "~/retroshare/retroshare-gui/src/retroshare-gui.pro". Then do a CLEAN build, if you had not enabled gxs before.