Build From Source
From Resara Server
Following are the instructions on how to build the Resara Server project from source. If you're interesting in obtaining the project in prebuilt binary form please check the Quick Start Guide. In addition, as a point of clarification, we refer to the project as "RDS" in code.
This project is currently under heavy active development so we do not recommend building from source unless you Know What You're Doing(tm).
Ubuntu Super Quick Guide
For the impatient Ubuntu user who doesn't want to read all this stuff, just run this:
# install all the required packages apt-get insall build-essential libqt4-dev libattr1-dev libldap2-dev libsasl2-dev libparted0-dev cmake libavahi-client-dev libavahi-compat-libdnssd-dev mercurial cmake # grab the sources, and get into a shadow build directory hg clone https://bitbucket.org/resara/resara-server cd resara-server/rds/ mkdir build cd build # configure and build! ../configure --debug --prefix /usr/ make sudo make install
Get The RDS Sources
From within the source tree the main project is found in
rds/rds. This will, eventually, be moved directly into the rds directory as it is an artifact of an older build system.
You may also visit our BitBucket page to view the commit log, report issues, or download any of the official releases. Packages are, however, not hosted on this site.
Selecting A Release Version
If you are to build from source, we generally recommend using a tagged version as the tip of the repository may or may not contain new bugs or broken code. To reiterate, this project is in heavy active development.
We tag all releases in the source code for RDS so that you may easily jump to a specific release and build it from source. Once you have a working directory for RDS checked out you can browse a list of tags using
hg tags and jump to a specific tag using hg, for example
hg update alpha2 would jump to the revision released as alpha2.
Once you've updated to the correct revision, follow the build instructions as per usual.
RDS requires the following to build:
- Qt4.6 or later
- DNSSD compatibility layer for Avahi
- A bunch of other stuff...?
In Ubuntu based systems, you can install the following packages. Other systems can use this list as a reference for deriving what they need:
apt-get insall build-essential libqt4-dev libattr1-dev libldap2-dev libsasl2-dev libparted0-dev cmake libavahi-client-dev libavahi-compat-libdnssd-dev
Currently RDS only builds in windows using the MSVC++ compiler. This is because of the Bonjour library only working under this compiler and not with mingw*. In addition, only the client binary builds in Windows, as the server is not intended to run in windows.
- Qt4.6 built with MSVC (This is not the default, you will need to build Qt yourself)
- Bonjour development files
- MSVC++ Compiler
- Mercurial, I recommend TortoiseHg
* If you know of a way to get Bonjour working with mingw, please Chris know by emailing him at
chris at resara dot com
You guys have it easy, seriously. The project comes shipped with a configure script which will take care of all the CMake magic for things like alternate installation directories. To view all of the options currently available, from within rds/rds/ run:
Before running the actual configure script I recommend setting up a shadow build directory, the easiest way to do this is:
../configure [any configure options]
CMake will automatically attempt to find all of the requires components to build the software, once completed you should be ready to build. To build the project simple run
and, optionally, if you wish to install the project onto the local machine run:
sudo make install
QtCreator is a cross platform IDE designed for building Qt4 projects. It can be found here. To build RDS you must configure QtCreator to point at your MSVC++ Qt4 installation as opposed to the mingw one. In addition, you must tell it to use the MSVC++ compiler.
Open the CMakeLists.txt file with QtCreator and follow the prompts to setup the build environment. At this point you should be able to build RDS without any problems.
ctrl+shift+b and the project will be built.
Using Command Line
While a little trickier and annoying due to cmd.exe not being the best CLI interface, I generally prefer using this method of building. First off, you must run the Qt environment batch file, which you will need to modify to work with MSVC++. The file can be found in
[Qt Install Path]/bin/qtenv.bat. Here is an example bat file, using
C:\Qt\2010.05.MSVC\ as my Qt directory:
rem @echo off rem rem This file is generated rem echo Setting up a CMake/VC/Qt only environment... echo -- QTDIR set to C:\Qt\2010.05.MSVC\qt echo -- PATH set to C:\Qt\2010.05.MSVC\qt\bin echo -- Adding C:\Qt\2010.05.MSVC\bin to PATH echo -- Adding %SystemRoot%\System32 to PATH echo -- QMAKESPEC set to win32-msvc2010 echo -- Executing C:\Program Files\Microsoft Visual Studio 10.0\VC\vcvarsall.bat echo -- Adding OpenSSL environment set QTDIR=C:\Qt\2010.05.MSVC\qt set PATH=C:\Qt\2010.05.MSVC\qt\bin set PATH=%PATH%;C:\Qt\2010.05.MSVC\bin; set PATH=%PATH%;%SystemRoot%\System32 set QMAKESPEC=win32-msvc2010 SET LIB=c:\openssl\lib\VC;%LIB% SET INCLUDE=c:\openssl\include;%INCLUDE% SET PATH=%PATH%;c:\openssl; SET PATH=%PATH%;"%PROGRAMFILES%\CMake 2.8\bin"; rem -- The following two lines are not needed for building, but help a lot. SET PATH=%PATH%;"%PROGRAMFILES%\TortoiseHg"; SET PATH=%PATH%;"%PROGRAMFILES%\7-Zip"; @echo on call "%PROGRAMFILES%\Microsoft Visual Studio 10.0\VC\vcvarsall.bat"
You'll notice I call
"%PROGRAMFILES%\Microsoft Visual Studio 10.0\VC\vcvarsall.bat" in this file, too. This is very important.
Once these things have been done,
cd into your shadow build directory (or directory into rds/rds if you do not wish to shadow build). From here, simply run:
cmake.exe [Path To RDS]
... and CMake should take care of everything, returning errors if any part of it fails. At this point you are ready to build the project.
Building the project is rather simple, all must do is run:
If you wish to build the self contained .zip and/or the .exe installer package simply run: