aboutsummaryrefslogtreecommitdiff
path: root/doc/documentation
diff options
context:
space:
mode:
Diffstat (limited to 'doc/documentation')
-rw-r--r--doc/documentation/Makefile.am1
-rw-r--r--doc/documentation/chapters/installation.texi158
-rw-r--r--doc/documentation/gnunet.texi7
3 files changed, 166 insertions, 0 deletions
diff --git a/doc/documentation/Makefile.am b/doc/documentation/Makefile.am
index 12f40f147..0ee81304e 100644
--- a/doc/documentation/Makefile.am
+++ b/doc/documentation/Makefile.am
@@ -114,6 +114,7 @@ gnunet_TEXINFOS = \
114 chapters/developer.texi \ 114 chapters/developer.texi \
115 chapters/preface.texi \ 115 chapters/preface.texi \
116 chapters/philosophy.texi \ 116 chapters/philosophy.texi \
117 chapters/installation.texi \
117 chapters/user.texi \ 118 chapters/user.texi \
118 chapters/vocabulary.texi \ 119 chapters/vocabulary.texi \
119 chapters/configuration.texi \ 120 chapters/configuration.texi \
diff --git a/doc/documentation/chapters/installation.texi b/doc/documentation/chapters/installation.texi
new file mode 100644
index 000000000..d66d72ae5
--- /dev/null
+++ b/doc/documentation/chapters/installation.texi
@@ -0,0 +1,158 @@
1@node Installing GNUnet
2@chapter Installing GNUnet
3
4This guide is intended for those who want to install Gnunet from source. For instructions on how to install GNUnet as a binary package please refer to the official documentation of your operating system or package manager.
5
6@node Getting the Source Code
7@section Installing dependencies
8GNUnet needs few libraries and applications for being able to run and another few optional ones for using certain features. Preferably they should be installed with a package manager. Just in case we include a link to the project websites.
9
10The mandatory libraries and applications are
11@itemize @bullet
12@item libtool
13@item autoconf >= version 2.59
14@item automake >= version 1.11.1
15@item pkg-config
16@item libgcrypt >= version 1.6
17@item libextractor
18@item libidn
19@item libmicrohttpd >= version 0.9.52
20@item libnss
21@item libunistring
22@item gettext
23@item glibc
24@item libgmp
25@item gnutls
26@item libcurl (has to be linked to GnuTLS) or libgnurl
27@item zlib
28@end itemize
29
30In addition GNUnet needs one of of these three databases
31@itemize @bullet
32@item sqlite + libsqlite (the default, requires no further configuration)
33@item postgres + libpq
34@item mysql + libmysqlclient
35@end itemize
36
37These are the dependencies only required for certain features
38@itemize @bullet
39@item Texinfo (for building the documentation)
40@item Texlive (for building the documentation)
41@item miniupnpc (for traversing NAT boxes more reliably)
42@item libopus (for running the GNUnet conversation telephony application)
43@item libpulse (for running the GNUnet conversation telephony application)
44@item libogg (for running the GNUnet conversation telephony application)
45@item bluez (for bluetooth support)
46@item libpbc (for attribute-based encryption and the identity provider subsystem)
47@item libgabe (for attribute-based encryption and the identity provider subsystem)
48@end itemize
49
50
51@section Getting the Source Code
52You can either download the source code using git (you obviously need git installed) or as an archive.
53
54Using git type
55@example
56git clone https://gnunet.org/git/gnunet.git
57@end example
58
59The archive can be found at @uref{https://gnunet.org/downloads}. Extract it using a graphical archive tool or @code{tar}:
60@example
61tar xzvf gnunet-0.11.0pre66.tar.gz
62@end example
63
64In the next chapter we will assume that the source code is available in the home directory at @code{~/gnunet}.
65
66@section Create @code{gnunet} user and group
67The GNUnet services should be run as a dedicated user called @code{gnunet}. For using them a user should be in the same group as this system user.
68
69Create user @code{gnunet} who is member of the group @code{gnunet} and specify a home directory where the GNUnet services will store persistant data such as information about peers.
70@example
71$ sudo useradd --system --groups gnunet --home-dir /var/lib/gnunet
72@end example
73
74Now add your own user to the @code{gnunet} group.
75@example
76$ sudo adduser alice gnunet
77@end example
78
79@section Preparing and Compiling the Source Code
80For preparing the source code for compilation a bootstrap script and @code{configure} has to be run from the source code directory. When running @code{configure} the following options can be specified to customize the compilation and installation process:
81
82@itemize @bullet
83@item @code{--disable-documentation} - don't build the configuration documents
84@item @code{--enable-looging=[LOGLEVEL]} - choose a loglevel (@code{debug}, @code{info}, @code{warning} or @code{error})
85@item @code{--prefix=[PATH]} - the directory where the GNUnet libraries and binaries will be installed
86@item @code{--with-extractor=[PATH]} - the path to libextractor
87@item @code{--with-libidn=[PATH]} - the path to libidn
88@item @code{--with-microhttpd=[PATH]} - the path to libmicrohttpd
89@item @code{--with-sqlite=[PATH]} - the path to libsqlite
90@item @code{--with-zlib=[PATH]} - the path to zlib
91@item @code{--with-sudo=[PATH]} - path to the sudo binary (no need to run @code{make install} as root if specified)
92@end itemize
93
94The following example configures the installation prefix @code{/usr/lib} and disables building the documentation
95@example
96$ cd ~/gnunet
97$ ./bootstrap
98$ configure --prefix=/usr/lib --disable-configuration
99@end example
100
101After running the bootstrap script and @code{configure} successfully the source code can be compiled with make. Here @code{-j5} specifies that 5 threads should be used.
102@example
103$ make -j5
104@end example
105
106
107@section Installation
108The compiled binaries can be installed using @code{make install}. It needs to be run as root (or with sudo) because some binaries need the @code{suid} bit set. Without that some GNUnet subsystems (such as VPN) will not work.
109
110@example
111$ sudo make install
112@end example
113
114One important library is the GNS plugin for NSS (the name services switch) which allows using GNS (the GNU name system) in the normal DNS resolution process. Unfortunately NSS expects it in a specific location (probably @code{/lib}) which may differ from the installation prefix (see @code{--prefix} option in the previous section). This is why the pugin has to be installed manually.
115
116Find the directory where nss plugins are installed on your system, e.g.
117
118@example
119$ ls -l /lib/libnss_*
120/lib/libnss_mymachines.so.2
121/lib/libnss_resolve.so.2
122/lib/libnss_myhostname.so.2
123/lib/libnss_systemd.so.2
124@end example
125
126Copy the GNS NSS plugin to that directory:
127
128@example
129cp ~/gnunet/src/gns/nss/libnss_gns.so.2 /lib
130@end example
131
132Now, to activate the plugin, you need to edit your @code{/etc/nsswitch.conf} where you should find a line like this:
133
134@example
135hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
136@end example
137
138The exact details may differ a bit, which is fine. Add the text @code{"gns [NOTFOUND=return]"} after @code{"files"}.
139
140@example
141hosts: files gns [NOTFOUND=return] mdns4_minimal [NOTFOUND=return] dns mdns4
142@end example
143
144Optionally, if GNS shall be used with a browser, execute the GNS CA-setup script. It will isetup the GNS Certificate Authority with the user's browser.
145@example
146$ gnunet-gns-proxy-setup-ca
147@end example
148
149Finally install a configuration file in @code{~/.gnunet/gnunet.conf}. Below you find an example config which allows you to start GNUnet.
150
151@example
152[arm]
153SYSTEM_ONLY = NO
154USER_ONLY = NO
155
156[transport]
157PLUGINS = tcp
158@end example
diff --git a/doc/documentation/gnunet.texi b/doc/documentation/gnunet.texi
index cd2f04399..0d539a9d7 100644
--- a/doc/documentation/gnunet.texi
+++ b/doc/documentation/gnunet.texi
@@ -83,6 +83,7 @@ This document is the Reference Manual for GNUnet version @value{VERSION}.
83* Preface:: Chapter 0 83* Preface:: Chapter 0
84* Philosophy:: About GNUnet 84* Philosophy:: About GNUnet
85@c * Vocabulary:: Vocabulary 85@c * Vocabulary:: Vocabulary
86* Installing GNUnet:: Installing GNUnet
86* Using GNUnet:: Using GNUnet 87* Using GNUnet:: Using GNUnet
87@c * Configuration Handbook:: Configuring GNUnet 88@c * Configuration Handbook:: Configuring GNUnet
88* GNUnet Contributors Handbook:: Contributing to GNUnet 89* GNUnet Contributors Handbook:: Contributing to GNUnet
@@ -120,6 +121,8 @@ Philosophy
120* Backup of Identities and Egos:: 121* Backup of Identities and Egos::
121* Revocation:: 122* Revocation::
122 123
124Installing GNUnet
125
123Using GNUnet 126Using GNUnet
124 127
125* Checking the Installation:: 128* Checking the Installation::
@@ -193,6 +196,10 @@ GNUnet Developer Handbook
193@c ********************************************************************* 196@c *********************************************************************
194 197
195@c ********************************************************************* 198@c *********************************************************************
199@include chapters/installation.texi
200@c *********************************************************************
201
202@c *********************************************************************
196@include chapters/user.texi 203@include chapters/user.texi
197@c ********************************************************************* 204@c *********************************************************************
198 205