You are here

Revision of Build instructions for Ubuntu 10.04 using Subversion from Tue, 08/17/2010 - 09:21

First, make sure Subversion is installed on your system:

# sudo apt-get install subversion

Then, you check out the source code from Subversion:

$ svn checkout https://ng.gnunet.org/svn/gnunet/

Following, install all the dependencies which should be installed before the installation of GNUnet. Now install GNU libextractor 0.6.x. If your distribution includes an recent version of GNU libextractor, you can use the version from your distribution.

• Installing libextractor from subversion:

Dependencies:

# sudo apt-get installl automake autoconf libtool make gcc g++
# sudo apt-get installl zlib1g-dev libgsf-1-dev libmpeg2-4-dev libpoppler-dev

# svn checkout https://ng.gnunet.org/svn/Extractor
# cd Extractor
# ./bootstrap
# ./configure
# make; sudo make install; make check

• Installing GNU libmicrohttpd from subversion:

Install libmicrohttpd dependencies:

# sudo apt-get install gnutls-dev libcurl4-gnutls-dev

Build libmicrohttpd:

# svn co https://ng.gnunet.org/svn/libmicrohttpd
# cd libmicrohttpd/
# ./bootstrap
# ./configure --with-gnutls --enable-messages --enable-curl
# make; sudo make install; make check

You can use following three commands to install all the other dependencies, for example:

# sudo apt-get install libltdl7-dev automake autoconf libtool make gcc texinfo
# sudo apt-get install libgcrypt11-dev libgmp3-dev libcurl4-gnutls-dev cvs
# sudo apt-get install libmysqlclient15-dev libsqlite3-dev libpq-dev
# sudo apt-get install libesmtp-dev libpcap-dev

The first command installs the required compiler tools. The second one the various dependencies and finally the last line adds (optional) database libraries. For testing, you will additionally need to install and configure the respective database servers (except for sqLite, which does not need one). Once all the dependencies needed are installed, you can just run the bootstrap file:

$ ./bootstrap

Then configure it with your designated directory:

$ ./configure --prefix=/home/username --with-extractor=/home/username --enable-coverage

After it you can run the coverage.sh shell script from the contrib/ directory to compute information about test coverage:

$ contrib/coverage.sh

At last you can open the HTML file index.html that was created under the doc/coverage/ directory to check the current test coverage for all tested files. For example, using firefox as the browser:

$ firefox doc/coverage/index.html &

Note that, before next time you run the coverage.sh, you should delete all the .gcda files under the directory ../../src/util, simply by

$ rm -f `find -name "*.gcda"`

afterwards, be sure all the old compiled files under ../../gnunet should also be cleaned,

$ make clean

then, you can calculate coverage again.