]> arthur.barton.de Git - ngircd-alex.git/blob - INSTALL
Merge branch 'automake-am11-am12'
[ngircd-alex.git] / INSTALL
1
2                      ngIRCd - Next Generation IRC Server
3                            http://ngircd.barton.de/
4
5                (c)2001-2012 Alexander Barton and Contributors.
6                ngIRCd is free software and published under the
7                    terms of the GNU General Public License.
8
9                                 -- INSTALL --
10
11
12 I. Upgrade Information
13 ~~~~~~~~~~~~~~~~~~~~~~
14
15 Differences to version 17
16
17 - Support for ZeroConf/Bonjour/Rendezvous service registration has been
18   removed. The configuration option "NoZeroconf" is no longer available.
19
20 - The structure of ngircd.conf has been cleaned up and three new configuration
21   sections have been introduced: [Limits], [Options], and [SSL].
22   Lots of configuration variables stored in the [Global] section are now
23   deprecated there and should be stored in one of these new sections (but
24   still work in [Global]):
25     "AllowRemoteOper"    -> [Options]
26     "ChrootDir"          -> [Options]
27     "ConnectIPv4"        -> [Options]
28     "ConnectIPv6"        -> [Options]
29     "ConnectRetry"       -> [Limits]
30     "MaxConnections"     -> [Limits]
31     "MaxConnectionsIP"   -> [Limits]
32     "MaxJoins"           -> [Limits]
33     "MaxNickLength"      -> [Limits]
34     "NoDNS"              -> [Options], and renamed to "DNS"
35     "NoIdent"            -> [Options], and renamed to "Ident"
36     "NoPAM"              -> [Options], and renamed to "PAM"
37     "OperCanUseMode"     -> [Options]
38     "OperServerMode"     -> [Options]
39     "PingTimeout"        -> [Limits]
40     "PongTimeout"        -> [Limits]
41     "PredefChannelsOnly" -> [Options]
42     "SSLCertFile"        -> [SSL], and renamed to "CertFile"
43     "SSLDHFile"          -> [SSL], and renamed to "DHFile"
44     "SSLKeyFile"         -> [SSL], and renamed to "KeyFile"
45     "SSLKeyFilePassword" -> [SSL], and renamed to "KeyFilePassword"
46     "SSLPorts"           -> [SSL], and renamed to "Ports"
47     "SyslogFacility"     -> [Options]
48     "WebircPassword"     -> [Options]
49   You should adjust your ngircd.conf and run "ngircd --configtest" to make
50   sure that your settings are correct and up to date!
51
52 Differences to version 16
53
54 - Changes to the "MotdFile" specified in ngircd.conf now require a ngircd
55   configuration reload to take effect (HUP signal, REHASH command).
56
57 Differences to version 0.9.x
58
59 - The option of the configure script to enable support for Zeroconf/Bonjour/
60   Rendezvous/WhateverItIsNamedToday has been renamed:
61     --with-rendezvous  ->  --with-zeroconf
62
63 Differences to version 0.8.x
64
65 - The maximum length of passwords has been raised to 20 characters (instead
66   of 8 characters). If your passwords are longer than 8 characters then they
67   are cut at an other position now.
68
69 Differences to version 0.6.x
70
71 - Some options of the configure script have been renamed:
72     --disable-syslog  ->  --without-syslog
73     --disable-zlib    ->  --without-zlib
74   Please call "./configure --help" to review the full list of options!
75
76 Differences to version 0.5.x
77
78 - Starting with version 0.6.0, other servers are identified using asynchronous
79   passwords: therefore the variable "Password" in [Server]-sections has been
80   replaced by "MyPassword" and "PeerPassword".
81
82 - New configuration variables, section [Global]: MaxConnections, MaxJoins
83   (see example configuration file "doc/sample-ngircd.conf"!).
84
85
86 II. Standard Installation
87 ~~~~~~~~~~~~~~~~~~~~~~~~~
88
89 ngIRCd is developed for UNIX-based systems, which means that the installation
90 on modern UNIX-like systems that are supported by GNU autoconf and GNU
91 automake ("configure") should be no problem.
92
93 The normal installation procedure after getting (and expanding) the source
94 files (using a distribution archive or GIT) is as following:
95
96   0) Satisfy prerequisites
97   1) ./autogen.sh  [only necessary when using GIT]
98   2) ./configure
99   3) make
100   4) make install
101
102 (Please see details below!)
103
104 Now the newly compiled executable "ngircd" is installed in its standard
105 location, /usr/local/sbin/.
106
107 The next step is to configure and afterwards starting the daemon. Please
108 have a look at the ngircd(8) and ngircd.conf(5) manual pages for details
109 and all possible options -- and don't forget to run "ngircd --configtest"
110 to validate your configuration file!
111
112 If no previous version of the configuration file exists (the standard name
113 is /usr/local/etc/ngircd.conf), a sample configuration file containing all
114 possible options will be installed there. You'll find its template in the
115 doc/ directory: sample-ngircd.conf.
116
117
118 0): Satisfy prerequisites
119
120 When building from source, you'll need some other software to build ngIRCd:
121 for example a working C compiler, make tool, GNU automake and autoconf (only
122 when not using a distribution archive), and a few libraries depending on the
123 features you want to compile in (like IDENT support, SSL, and PAM).
124
125 If you are using one of the "big" operating systems or Linux distributions,
126 you can use the following commands to install all the required packages to
127 build the sources including all optional features and to run the test suite:
128
129 * RedHat / Fedora based distributions:
130
131   yum install \
132     autoconf automake expect gcc glibc-devel gnutls-devel \
133     libident-devel make pam-devel tcp_wrappers-devel telnet zlib-devel
134
135 * Debian / Ubuntu based distributions:
136
137   apt-get install \
138     autoconf automake build-essential expect libgnutls-dev \
139     libident-dev libpam-dev libwrap0-dev libz-dev telnet
140
141
142 1): "autogen.sh"
143
144 The first step, autogen.sh, is only necessary if the configure-script isn't
145 already generated. This never happens in official ("stable") releases in
146 tar.gz-archives, but when using GIT.
147
148 This step is therefore only interesting for developers.
149
150 autogen.sh produces the Makefile.in's, which are necessary for the configure
151 script itself, and some more files for make. To run autogen.sh you'll need
152 GNU autoconf and GNU automake: at least autoconf 2.61 and automake 1.10 are
153 requird, newer is better. But don't use automake 1.12 or newer for creating
154 distribution archives: it will work but lack "de-ANSI-fucation" support in the
155 generated Makefile's! Stick with automake 1.11.x for this purpose ...
156 So automake 1.11.x and autoconf 2.67+ is recommended.
157
158 Again: "end users" do not need this step and neither need GNU autoconf nor GNU
159 automake at all!
160
161
162 2): "./configure"
163
164 The configure-script is used to detect local system dependencies.
165
166 In the perfect case, configure should recognize all needed libraries, header
167 files and so on. If this shouldn't work, "./configure --help" shows all
168 possible options.
169
170 In addition, you can pass some command line options to "configure" to enable
171 and/or disable some features of ngIRCd. All these options are shown using
172 "./configure --help", too.
173
174 Compiling a static binary will avoid you the hassle of feeding a chroot dir
175 (if you want use the chroot feature). Just do something like:
176   CFLAGS=-static ./configure [--your-options ...]
177 Then you can use a void directory as ChrootDir (like OpenSSH's /var/empty).
178
179
180 3): "make"
181
182 The make command uses the Makefiles produced by configure and compiles the
183 ngIRCd daemon.
184
185
186 4): "make install"
187
188 Use "make install" to install the server and a sample configuration file on
189 the local system. Normally, root privileges are necessary to complete this
190 step. If there is already an older configuration file present, it won't be
191 overwritten.
192
193 These files and folders will be installed by default:
194
195 - /usr/local/sbin/ngircd: executable server
196 - /usr/local/etc/ngircd.conf: sample configuration (if not already present)
197 - /usr/local/share/doc/ngircd/: documentation
198 - /usr/local/share/man/: manual pages
199
200
201 III. Additional features
202 ~~~~~~~~~~~~~~~~~~~~~~~~
203
204 The following optional features can be compiled into the daemon by passing
205 options to the "configure" script. Most options can handle a <path> argument
206 which will be used to search for the required libraries and header files in
207 the given paths ("<path>/lib/...", "<path>/include/...") in addition to the
208 standard locations.
209
210 * Syslog Logging (autodetected by default): 
211   --with-syslog[=<path>] / --without-syslog
212
213   Enable (disable) support for logging to "syslog", which should be
214   available on most modern UNIX-like operating systems by default.
215
216 * ZLib Compression (autodetected by default):
217   --with-zlib[=<path>] / --without-zlib
218
219   Enable (disable) support for compressed server-server links.
220   The Z compression library ("libz") is required for this option.
221   
222 * IO Backend (autodetected by default):
223   --with-select[=<path>] / --without-select
224   --with-poll[=<path>] / --without-poll
225   --with-devpoll[=<path>] / --without-devpoll
226   --with-epoll[=<path>] / --without-epoll
227   --with-kqueue[=<path>] / --without-kqueue  
228
229   ngIRCd can use different IO "backends": the "old school" select() and poll()
230   API which should be supported by most UNIX-like operating systems, or the
231   more efficient and flexible epoll() (Linux >=2.6), kqueue() (BSD) and
232   /dev/poll APIs.
233   By default the IO backend is autodetected, but you can use "--without-xxx"
234   to disable a more enhanced API.
235   When using the epoll() API, support for select() is compiled in as well by
236   default to enable the binary to run on older Linux kernels (<2.6), too.
237
238 * IDENT-Support:
239   --with-ident[=<path>]
240
241   Include support for IDENT ("AUTH") lookups. The "ident" library is
242   required for this option.
243
244 * TCP-Wrappers:
245   --with-tcp-wrappers[=<path>] 
246
247   Include support for Wietse Venemas "TCP Wrappers" to limit client access
248   to the daemon, for example by using "/etc/hosts.{allow|deny}".
249   The "libwrap" is required for this option.
250
251 * PAM:
252   --with-pam[=<path>]
253
254   Enable support for PAM, the Pluggable Authentication Modules library.
255   See doc/PAM.txt for details.
256
257 * SSL:
258   --with-openssl[=<path>]
259   --with-gnutls[=<path>]
260
261   Enable support for SSL/TLS using OpenSSL or gnutls libraries.
262   See doc/SSL.txt for details.
263
264 * IPv6:
265   --enable-ipv6
266
267   Adds support for version 6 of the Internet Protocol.
268
269
270 IV. Useful make-targets
271 ~~~~~~~~~~~~~~~~~~~~~~~
272
273 The Makefile produced by the configure-script contains always these useful
274 targets:
275
276  - clean: delete every product from the compiler/linker
277    next step: -> make
278
279  - distclean: the above plus erase all generated Makefiles
280    next step: -> ./configure
281
282  - maintainer-clean: erase all automatic generated files
283    next step: -> ./autogen.sh
284
285
286 V. Sample configuration file ngircd.conf
287 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
288
289 In the sample configuration file, there are comments beginning with "#" OR
290 ";" -- this is only for the better understanding of the file.
291
292 The file is separated in five blocks: [Global], [Features], [Operator],
293 [Server], and [Channel].
294
295 In the [Global] section, there is the main configuration like the server
296 name and the ports, on which the server should be listening. Options in
297 the [Features] section enable or disable functionality in the daemon.
298 IRC operators of this server are defined in [Operator] blocks, remote
299 servers are configured in [Server] sections, and [Channel] blocks are
300 used to configure pre-defined ("persistent") IRC channels.
301
302 The meaning of the variables in the configuration file is explained in the 
303 "doc/sample-ngircd.conf", which is used as sample configuration file in
304 /usr/local/etc after running "make install" (if you don't already have one)
305 and in the ngircd.conf(5) manual page.
306
307
308 VI. Command line options
309 ~~~~~~~~~~~~~~~~~~~~~~~~
310
311 These parameters could be passed to the ngIRCd:
312
313 -f, --config <file>
314         The daemon uses the file <file> as configuration file rather than
315         the standard configuration /usr/local/etc/ngircd.conf.
316
317 -n, --nodaemon
318         ngIRCd should be running as a foreground process.
319
320 -p, --passive
321         Server-links won't be automatically established.
322
323 -t, --configtest
324         Reads, validates and dumps the configuration file as interpreted
325         by the server. Then exits.
326
327 Use "--help" to see a short help text describing all available parameters
328 the server understands, with "--version" the ngIRCd shows its version
329 number. In both cases the server exits after the output.
330
331 Please see the ngircd(8) manual page for complete details!