source: INSTALL@ 9745

Last change on this file since 9745 was 9745, checked in by bless, 13 years ago
  • language fix and hint for make -j
File size: 6.5 KB
Line 
1Please see the latest Installation instructions on http://ariba-underlay.org/
2here: http://ariba-underlay.org/trac/spovnet-base/wiki/BaseInstall
3
4Please see also http://spovnet.de/ for further information
5about Ariba and its application.
6
7Prerequisites
8=============
9ariba depends on libraries that may not be installed on your system:
10
11 * Boost (version >=1.39)
12 * Log4cxx (version >= 0.10.0)
13 * GMP (no specific version)
14
15Furthermore, you need default development tools - that are most likely already installed on your system - such as
16gcc/g++, autoconf, automake, aclocal, libtool, liblt-dev ...
17
18Quick Install (If all dependencies are satisfied)
19=============
20
21ariba currently build on Linux systems. Our reference platform is
22Ubuntu 8.04 with the g++ compiler version 4.1. Download the latest
23ariba package from the the download site
24http://ariba-underlay.org/downloads
25
26Extract the archive and change into the project directory:
27
28> tar xfz ./ariba-x.x.x.tar.gz
29> cd ariba-x.x.x
30
31Now, configure, compile, and install ariba (if not all libraries
32needed by Ariba are available on your system, read the section
33'Prequisites').
34
35If no configure script is available (e.g. when you checked out an svn
36version), run the ./bootstrap script first and then type:
37
38> ./configure
39> make
40> make install
41
42HINT: you may use
43> make -j 2
44for a double processor/core system to speed up the compilation,
45make -j 4 if you have quad-core respectively, and so on. If
46the compilation stops, try make without the -j option again.
47
48
49In case you don't want to install Ariba into your system but to a
50local place, do:
51
52> mkdir build
53> ./configure --prefix=$PWD/build
54> make
55> make install
56
57
58Local install (Download library dependencies and install ariba in a
59============= local subdirectory)
60
61
62If the required libraries are not available on your system or don't
63want to install them to the system you can use the bootstrap_libs
64script that comes with the ariba package. It will download all
65dependencies, compile and install them locally, and compile and
66install ariba:
67
68> tar xfz ./ariba-x.x.x.tar.gz
69> cd ariba-x.x.x
70> ./bootstrap_libs
71
72This script will automatically download all necessary libraries and
73compile them inside a new ./libs subdirectory and install them into
74./build. In the end the ariba library itself is compiled to
75./build. You can safely delete the ./libs subdirectory after the
76process.
77
78Here is the manual way to go: If you install Ariba locally and have
79the required libraries also installed locally, you can use a
80config.site script to make it easier. The config.site file must reside
81in a folder called share. If your install path is /home/foo/local and
82you do a ./configure --prefix=/home/foo/local, ariba headers will be
83installed in /home/foo/local/include, and the ariba library in
84/home/foo/local/lib. To use a config.site script, create a folder
85/home/foo/local/share and create a file config.site. Such a file has
86paths towards required header files and libraries.
87
88with_boost=/home/foo/Libraries/include
89test -z "$CPPFLAGS" && CPPFLAGS='-I/home/foo/Libraries/include'
90test -z "$LDFLAGS" && LDFLAGS='-L/home/foo/Libraries/lib'
91
92If you now do a ./configure --prefix=/home/foo/local, the config.site
93will be found and the paths therein used for finding libraries. If you
94e.g. have multiple libraries distributed in their own include folders,
95you can also have multiple includes:
96
97test -z "$CPPFLAGS" && CPPFLAGS='-I/home/foo/Libraries/include -I/home/foo/otherlibrary/include'
98
99Running the PingPong Sample
100===========================
101The PingPong binary pingpong is installed in build/bin. It has one
102parameter, a configuration file. You can find sample configuration
103files in the etc/pingpongconfig folder. If no configuration file is
104given, the node will randomly select its NodeID but will not find
105other nodes. This is because bootstrap modules are selected in the
106configuration file.
107
108> ./pingpong ../../etc/pingpong/settings_node1.cnf
109
110If this fails to find the libariba you may have to set
111the LD_LIBRARY_PATH correctly in your current terminal,
112or better add it to your .bashrc
113
114> export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/user/ariba/build/lib
115
116When running the pingpong application it will output a large number of
117log messages and the initiator will wait for other nodes to join. You
118can start them using the configuration files settings_node1.cnf and
119settings_node2.cnf. You may need to adjust the configurations files:
120currently both node1 and node2 try to join the initiator on the local
121machine. This will only work if you start all instances on a local
122machine.
123
124Once the PingPong sample is running and the nodes have connected, each
125node will send out ping messages to every node he knows in the overlay
126structure every 5 seconds. You can now e.g. test mobility of Ariba and
127change the IP address of a node, or swith from LAN connection to
128WLAN. The links established by the PingPong sample through Ariba are
129mobility invariant and automatically repaired. Selecting a compiler
130
131As the g++-4.3 compiler is very restrictive when compiling C++ and you
132will have some trouble with Boost and Log4cxx, we suggest to use
133e.g. g++-4.1. You then have to compile the libraries and Ariba with
134this compiler. You can tell Log4cxx and Ariba to use a different
135compiler using:
136
137./configure --prefix=... CXX=g++-4.1
138
139This will not work in Boost as the configure script is just a wrapper around the Boost Build.System bjam. You can edit the jamfile in the Boost root directory:
140
141using gcc : 4.1 ;
142
143and then build using bjam as described in http://www.boost.org/doc/libs/1_38_0/more/getting_started/unix-variants.html.
144
145Cross-Comiling for Maemo
146========================
147Ariba runs on Nokia Maemo 4 (tested) and probably Maemo 5. We have
148tested Ariba on an N810 device. Cross-Compiling is done using
149Scratchbox. Use the preassembled Scratchbox version provided by Nokia
150which will install and configure the complete Scratchbox system
151automatically.
152
153The Ariba configure will test for Maemo systems. Internally there are
154a number of special cases where handling on Maemo is different from
155normal Linux. If you require special handling, do the following in
156your code:
157
158#include "ariba/config.h"
159...
160#ifdef HAVE_MAEMO
161 // special Maemo handling
162#endif
163
164Overview of special configure options
165=====================================
166There are several options to configure that are specific to Ariba:
167
168 * --enable-debug=yes - for building a debug build
169 * --enable-profiling=yes - for profiling with gprof
170 * --enable-logcolors=yes - for colorful logging output
171 * --enable-doxygen=yes - for generating doxygen documentation (do a make html-local in ariba/docu/doxygen)
Note: See TracBrowser for help on using the repository browser.