Browse Source

Import upstream version 18

Alexander Barton 9 years ago
parent
commit
df8ad4f01d
100 changed files with 9885 additions and 11283 deletions
  1. 2 3
      AUTHORS
  2. 113 4
      ChangeLog
  3. 54 20
      INSTALL
  4. 17 11
      Makefile.am
  5. 165 72
      Makefile.in
  6. 76 3
      NEWS
  7. 2 3
      README
  8. 217 107
      aclocal.m4
  9. 4288 8964
      configure
  10. 11 74
      configure.in
  11. 496 0
      contrib/Anope/0001-Revert-Removed-ngircd.patch
  12. 60 0
      contrib/Anope/0002-ngircd-whitespace-fixes.patch
  13. 20 0
      contrib/Anope/Makefile.am
  14. 361 0
      contrib/Anope/Makefile.in
  15. 36 0
      contrib/Anope/README
  16. 43 12
      contrib/Debian/Makefile.in
  17. 18 0
      contrib/Debian/changelog
  18. 112 37
      contrib/MacOSX/Makefile.in
  19. 0 10
      contrib/MacOSX/config.h
  20. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/01ngircd-contents.xml
  21. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/01ngircd.xml
  22. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/02de-contents.xml
  23. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/02de.xml
  24. 43 12
      contrib/MacOSX/ngIRCd.pmdoc/Makefile.in
  25. 70 22
      contrib/MacOSX/ngIRCd.pmdoc/index.xml
  26. 43 12
      contrib/MacOSX/ngIRCd.xcodeproj/Makefile.in
  27. 3 11
      contrib/MacOSX/ngIRCd.xcodeproj/project.pbxproj
  28. 3 3
      contrib/Makefile.am
  29. 115 40
      contrib/Makefile.in
  30. 5 3
      contrib/README
  31. BIN
      contrib/ngIRCd-Logo.gif
  32. 1 1
      contrib/ngircd.spec
  33. 2 2
      contrib/platformtest.sh
  34. 64 23
      depcomp
  35. 11 2
      doc/GIT.txt
  36. 1 1
      doc/Makefile.am
  37. 114 40
      doc/Makefile.in
  38. 19 17
      doc/Platforms.txt
  39. 22 2
      doc/Protocol.txt
  40. 3 3
      doc/SSL.txt
  41. 33 6
      doc/Services.txt
  42. 0 39
      doc/Zeroconf.txt
  43. 126 89
      doc/sample-ngircd.conf.tmpl
  44. 36 25
      doc/src/Doxyfile
  45. 2 2
      doc/src/Makefile.am
  46. 45 14
      doc/src/Makefile.in
  47. 0 10
      doc/src/header.inc.html
  48. 0 77
      doc/src/ngircd-doc.css
  49. 3 2
      install-sh
  50. 143 92
      man/Makefile.in
  51. 28 3
      man/ngircd.8.tmpl
  52. 251 169
      man/ngircd.conf.5.tmpl
  53. 29 20
      missing
  54. 113 38
      src/Makefile.in
  55. 3 28
      src/config.h.in
  56. 77 29
      src/ipaddr/Makefile.in
  57. 1 1
      src/ipaddr/ansi2knr.c
  58. 5 2
      src/ipaddr/ng_ipaddr.c
  59. 5 2
      src/ipaddr/ng_ipaddr.h
  60. 2 2
      src/ngircd/Makefile.am
  61. 142 68
      src/ngircd/Makefile.in
  62. 13 38
      src/ngircd/array.c
  63. 5 2
      src/ngircd/array.h
  64. 77 7
      src/ngircd/channel.c
  65. 9 4
      src/ngircd/channel.h
  66. 34 15
      src/ngircd/client.c
  67. 8 4
      src/ngircd/client.h
  68. 5 1
      src/ngircd/conf-ssl.h
  69. 882 437
      src/ngircd/conf.c
  70. 108 69
      src/ngircd/conf.h
  71. 5 3
      src/ngircd/conn-func.c
  72. 4 3
      src/ngircd/conn-func.h
  73. 10 5
      src/ngircd/conn-ssl.c
  74. 5 1
      src/ngircd/conn-ssl.h
  75. 8 5
      src/ngircd/conn-zip.c
  76. 4 7
      src/ngircd/conn-zip.h
  77. 303 133
      src/ngircd/conn.c
  78. 12 4
      src/ngircd/conn.h
  79. 6 10
      src/ngircd/defines.h
  80. 54 49
      src/ngircd/hash.c
  81. 5 7
      src/ngircd/hash.h
  82. 4 3
      src/ngircd/io.c
  83. 5 4
      src/ngircd/io.h
  84. 163 43
      src/ngircd/irc-channel.c
  85. 4 7
      src/ngircd/irc-channel.h
  86. 180 74
      src/ngircd/irc-info.c
  87. 4 7
      src/ngircd/irc-info.h
  88. 226 30
      src/ngircd/irc-login.c
  89. 6 4
      src/ngircd/irc-login.h
  90. 31 28
      src/ngircd/irc-mode.c
  91. 4 7
      src/ngircd/irc-mode.h
  92. 5 3
      src/ngircd/irc-op.c
  93. 4 7
      src/ngircd/irc-op.h
  94. 5 3
      src/ngircd/irc-oper.c
  95. 4 7
      src/ngircd/irc-oper.h
  96. 11 4
      src/ngircd/irc-server.c
  97. 4 7
      src/ngircd/irc-server.h
  98. 5 3
      src/ngircd/irc-write.c
  99. 5 2
      src/ngircd/irc-write.h
  100. 0 0
      src/ngircd/irc.c

+ 2 - 3
AUTHORS

@@ -1,9 +1,8 @@
 
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
-                        (c)2001-2009 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
 

+ 113 - 4
ChangeLog

@@ -1,15 +1,124 @@
 
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
 
                                -- ChangeLog --
 
 
+ngIRCd Release 18 (2011-07-10)
+
+  - Update timestamp of ngircd(8) manual page.
+  - Add preliminary ngIRCd protocol module for Anope 1.9 to contrib/Anope/.
+  - Don't register WHOWAS information when "MorePrivacy" option is in effect.
+
+  ngIRCd 18~rc2 (2011-06-29)
+  - Update documentation, fix some wording, and use a spellchecker :-)
+  - ngircd.conf.5: strip "SSL" prefix from variables in [SSL] section.
+  - ngircd.8: document debugging options.
+  - GnuTLS: use 1024 bits as minimum size of the DH prime. This enables
+    ngIRCd to accept incoming connections from other servers and clients
+    that "only" use at least 1024 bits again, like ngIRCd 17 did (and no
+    longer requires 2048 bits for incoming connections).
+
+  ngIRCd 18~rc1 (2011-06-27)
+  - PAM warning message: make clear which "Password" config option is ignored.
+  - New configuration option "MorePrivacy" to "censor" some user information.
+    When enabled, signon time and idle time is left out. Part and quit
+    messages are made to look the same. WHOWAS requests are silently dropped.
+    All of this is useful if one wish to conceal users that access the ngircd
+    servers from TOR or I2P.
+  - New configuration option "ScrubCTCP" to scrub incoming CTCP commands. If
+    activated, the server silently drops incoming CTCP requests from both
+    other servers and from users. The server that scrubs CTCP will not forward
+    the CTCP requests to other servers in the network either, which can spell
+    trouble if not every oper knows about the CTCP-scrubbing. Scrubbing CTCP
+    commands also means that it is not possible to send files between users.
+    There is one exception to the CTCP scrubbing performed: ACTION ("/me
+    commands") requests are not scrubbed.
+  - Display configuration errors more prominent on "--configtest".
+  - Restructure ngIRCd configuration file: introduce new [Limits], [Options],
+    and [SSL] sections. The intention of this restructuring is to make the
+    [Global] section much cleaner, so that it only contains variables that
+    most installations must adjust to the local requirements. All the optional
+    variables are moved to [Limits], for configurable limits and timers of
+    ngIRCd, and [Options], for optional features. All SSL-related variables
+    are moved to [SSL] and the "SSL"-prefix is stripped. The old variables in
+    the [Global] section are deprecated now, but are still recognized.
+    => Don't forget to check your configuration, use "ngircd --configtest"!
+  - New documentation "how to contribute": doc/Contributing.txt.
+  - Slightly fix error handling when connecting to remote servers.
+  - GnuTLS: bump DH-bitsize to 2048: this solves the problem that some clients
+    refuse to connect to severs that only offer 1024. For interoperability it
+    would be best to just use 4096 bits, but that takes minutes, even on
+    current hardware ...
+  - contrib/platformtest.sh: fix gcc version detection.
+  - Avoid needlessly scary 'buffer overflow' messages: When the write buffer
+    space grows too large, ngIRCd has to disconnect the client to avoid
+    wasting too much memory, which is logged with a scary 'write buffer
+    overflow' message. Change this to a more descriptive wording.
+  - Require server prefixes for most commands on RFC2812 links. RFC1459 links
+    (often used by services, for example) are not affected.
+  - Mac OS X: update installer functionality, texts, and add our logo :-)
+  - New configuration option "RequireAuthPing": PING-PONG on login. When
+    enabled, this configuration option lets ngIRCd send a PING with an numeric
+    "token" to clients logging in; and it will not become registered in the
+    network until the client responds with the correct PONG.
+  - New configuration option "NoticeAuth": send NOTICE AUTH on connect. When
+    active, ngircd will send "NOTICE AUTH" messages on client connect time
+    like e.g. snircd (QuakeNet) does.
+  - Generate WALLOPS message on SQUIT from IRC operators; so SQUIT now behaves
+    like CONNECT and DISCONNECT commands, when called by an IRC operator.
+  - Allow servers to send more commands in the first 10 seconds ("burst"). This
+    helps to speed up server login and network synchronization.
+  - Add support for up to 3 targets in WHOIS queries, also allow up to one
+    wildcard query from local hosts. Follows ircd 2.10 implementation rather
+    than RFC 2812. At most 10 entries are returned per wildcard expansion.
+  - ngircd.conf(5) manual page: describe types of configuration variables
+    (booleans, text strings, integer numbers) and add type information to each
+    variable description.
+  - Don't use "the.net" in sample-ngircd.conf, use "example.net".
+  - Terminate incoming connections on HTTP commands "GET" and "POST".
+  - New configuration option "CloakHost": when set, this hostname is used for
+    every client instead of the real DNS hostname (or IP address).
+  - New configuration option "CloakUserToNick": when enabled, ngIRCd sets
+    every clients' user name to their nick name and hides the user name
+    supplied by the IRC client.
+  - doc/Protocol.txt: Update description of the CHANINFO and WEBIRC commands.
+  - Doxygen'ify (document) much more source files; code cleanup ...
+  - Make write buffers bigger, but flush early. Before this change, a client
+    got disconnected if the buffer flushing at 4k failed, now regular clients
+    can store up to 32k and servers up 64k even if flushing is not possible at
+    the moment. This enhances reliability on slow links.
+  - Don't access possibly free'd CLIENT structure. Ooops.
+  - Allow "Port = 0" in [Server] blocks. Port number 0 marks remote servers
+    that try to connect to this daemon, but where this daemon never tries to
+    establish a connection on its own: only incoming connections are allowed.
+  - Configuration: fix 'Value of "..." is not a number!' for negative values.
+  - Enable WHOIS command to return information about services.
+  - Implement channel mode 'O': "IRC operators only". This channel mode is
+    used on DALnet (bahamut), for example.
+  - Remove support for ZeroConf/Bonjour/Rendezvous service registration
+    including the "[No]ZeroConf" configuration option.
+  - TOPIC command: test for channel admin rights correctly: this enables other
+    servers, services and IRC operators to change channel topics, even when
+    the client is not joined to this channel.
+  - Deprecate NoXX-Options in ngircd.conf and move new variants into our new
+    [Options] section: 'NoDNS=no' => 'DNS=yes', 'NoIdent=no' => 'Ident=yes',
+    'NoPAM=no' => 'PAM=yes', and 'NoZeroConf=no' => 'ZeroConf=yes' (and
+    vice-versa). The defaults are adjusted accordingly and the old variables
+    in [Global] are still accepted, so there is no functional change.
+  - Fix confusing "adding to invite list" debug messages: adding entries to
+    ban list produced 'invite list' debug output ...
+  - Don't throttle services and servers being registered.
+  - Xcode: correctly sort files :-)
+  - Don't assert() when searching a client for an invalid server token (this is
+    only relevant when a trusted server on a server-server link sends invalid
+    commands).
+
 ngIRCd Release 17.1 (2010-12-19)
 
   - --configtest: remember if MOTD is configured by file or phrase
@@ -17,7 +126,7 @@ ngIRCd Release 17.1 (2010-12-19)
   - Reset ID of outgoing server link on DNS error correctly
   - Don't log critical (or worse) messages to stderr
   - Manual page ngircd(8): add SIGNALS section
-  - Manual pages: update and simplyfy AUTHORS section
+  - Manual pages: update and simplify AUTHORS section
   - Remove "error file" when compiled with debug code enabled
   - README: Updated list of implemented commands
   - add doc/README-Interix.txt and doc/Bopm.txt to distribution tarball

+ 54 - 20
INSTALL

@@ -1,9 +1,8 @@
 
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
 
@@ -13,6 +12,43 @@
 I. Upgrade Information
 ~~~~~~~~~~~~~~~~~~~~~~
 
+Differences to version 17
+
+- Support for ZeroConf/Bonjour/Rendezvous service registration has been
+  removed. The configuration option "NoZeroconf" is no longer available.
+
+- The structure of ngircd.conf has been cleaned up and three new configuration
+  sections have been introduced: [Limits], [Options], and [SSL].
+  Lots of configuration variables stored in the [Global] section are now
+  deprecated there and should be stored in one of these new sections (but
+  still work in [Global]):
+    "AllowRemoteOper"    -> [Options]
+    "ChrootDir"          -> [Options]
+    "ConnectIPv4"        -> [Options]
+    "ConnectIPv6"        -> [Options]
+    "ConnectRetry"       -> [Limits]
+    "MaxConnections"     -> [Limits]
+    "MaxConnectionsIP"   -> [Limits]
+    "MaxJoins"           -> [Limits]
+    "MaxNickLength"      -> [Limits]
+    "NoDNS"              -> [Options], and renamed to "DNS"
+    "NoIdent"            -> [Options], and renamed to "Ident"
+    "NoPAM"              -> [Options], and renamed to "PAM"
+    "OperCanUseMode"     -> [Options]
+    "OperServerMode"     -> [Options]
+    "PingTimeout"        -> [Limits]
+    "PongTimeout"        -> [Limits]
+    "PredefChannelsOnly" -> [Options]
+    "SSLCertFile"        -> [SSL], and renamed to "CertFile"
+    "SSLDHFile"          -> [SSL], and renamed to "DHFile"
+    "SSLKeyFile"         -> [SSL], and renamed to "KeyFile"
+    "SSLKeyFilePassword" -> [SSL], and renamed to "KeyFilePassword"
+    "SSLPorts"           -> [SSL], and renamed to "Ports"
+    "SyslogFacility"     -> [Options]
+    "WebircPassword"     -> [Options]
+  You should adjust your ngircd.conf and run "ngircd --configtest" to make
+  sure that your settings are correct and up to date!
+
 Differences to version 16
 
 - Changes to the "MotdFile" specified in ngircd.conf now require a ngircd
@@ -69,7 +105,8 @@ location, /usr/local/sbin/.
 
 The next step is to configure and afterwards starting the daemon. Please
 have a look at the ngircd(8) and ngircd.conf(5) manual pages for details
-and all possible options.
+and all possible options -- and don't forget to run "ngircd --configtest"
+to validate your configuration file!
 
 If no previous version of the configuration file exists (the standard name
 is /usr/local/etc/ngircd.conf), a sample configuration file containing all
@@ -97,7 +134,7 @@ Again: "end users" do not need this step!
 
 The configure-script is used to detect local system dependencies.
 
-In the perfect case, configure should recognise all needed libraries, header
+In the perfect case, configure should recognize all needed libraries, header
 files and so on. If this shouldn't work, "./configure --help" shows all
 possible options.
 
@@ -124,11 +161,12 @@ the local system. Normally, root privileges are necessary to complete this
 step. If there is already an older configuration file present, it won't be
 overwritten.
 
-This files will be installed by default:
+These files and folders will be installed by default:
 
 - /usr/local/sbin/ngircd: executable server
 - /usr/local/etc/ngircd.conf: sample configuration (if not already present)
 - /usr/local/share/doc/ngircd/: documentation
+- /usr/local/share/man/: manual pages
 
 
 III. Additional features
@@ -174,13 +212,6 @@ standard locations.
   Include support for IDENT ("AUTH") lookups. The "ident" library is
   required for this option.
 
-* ZeroConf Support:
-  --with-zeroconf[=<path>] 
-
-  Compile ngIRCd with support for ZeroConf multicast DNS service registration.
-  Either the Apple ZeroConf implementation (e. g. Mac OS X) or the Howl
-  library is required. Which one is available is autodetected.
-
 * TCP-Wrappers:
   --with-tcp-wrappers[=<path>] 
 
@@ -229,19 +260,20 @@ V. Sample configuration file ngircd.conf
 In the sample configuration file, there are comments beginning with "#" OR
 ";" -- this is only for the better understanding of the file.
 
-The file is separated in four blocks: [Global], [Operator], [Server], and
-[Channel].
+The file is separated in five blocks: [Global], [Features], [Operator],
+[Server], and [Channel].
 
 In the [Global] section, there is the main configuration like the server
-name and the ports, on which the server should be listening. IRC operators
-of this server are defined in [Operator] blocks. [Server] is the section
-where server links are configured. And [Channel] blocks are used to
-configure pre-defined ("persistent") IRC channels.
+name and the ports, on which the server should be listening. Options in
+the [Features] section enable or disable functionality in the daemon.
+IRC operators of this server are defined in [Operator] blocks, remote
+servers are configured in [Server] sections, and [Channel] blocks are
+used to configure pre-defined ("persistent") IRC channels.
 
 The meaning of the variables in the configuration file is explained in the 
 "doc/sample-ngircd.conf", which is used as sample configuration file in
 /usr/local/etc after running "make install" (if you don't already have one)
-and in the "ngircd.conf" manual page.
+and in the ngircd.conf(5) manual page.
 
 
 VI. Command line options
@@ -266,3 +298,5 @@ These parameters could be passed to the ngIRCd:
 Use "--help" to see a short help text describing all available parameters
 the server understands, with "--version" the ngIRCd shows its version
 number. In both cases the server exits after the output.
+
+Please see the ngircd(8) manual page for complete details!

+ 17 - 11
Makefile.am

@@ -1,6 +1,6 @@
 #
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -37,6 +37,10 @@ have-xcodebuild:
 	 >/dev/null 2>&1 \
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 
+have-packagemaker:
+	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
+	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
+
 xcode: have-xcodebuild
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
@@ -55,10 +59,15 @@ deb:
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	dpkg-buildpackage -rfakeroot -i
 
-osxpkg: have-xcodebuild
-	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
-	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
-	make clean
+osxpkg: have-packagemaker osxpkg-dest
+	cd contrib/MacOSX && packagemaker \
+	 --doc ngIRCd.pmdoc \
+	 --out ../../$(distdir).mpkg
+	rm -f $(distdir).mpkg.zip
+	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
+	rm -rf ngircd.dest $(distdir).mpkg
+
+osxpkg-dest: have-xcodebuild clean
 	./configure --prefix=/opt/ngircd
 	make xcode
 	make -C contrib/MacOSX de.barton.ngircd.plist
@@ -71,11 +80,8 @@ osxpkg: have-xcodebuild
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	chmod -R a-s,og-w,a+rX ngircd.dest
-	cd contrib/MacOSX && packagemaker \
-	 --doc ngIRCd.pmdoc \
-	 --out ../../$(distdir).mpkg
-	rm -f $(distdir).mpkg.zip
-	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
-	rm -rf ngircd.dest $(distdir).mpkg
+
+.PHONY: deb have-packagemaker have-xcodebuild lint osxpkg osxpkg-dest rpm \
+	srcdoc testsuite xcode xcode-clean
 
 # -eof-

+ 165 - 72
Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
@@ -16,7 +17,7 @@
 
 #
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -26,8 +27,9 @@
 #
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
@@ -57,6 +59,13 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -68,6 +77,9 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir dist dist-all distcheck
 ETAGS = etags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
@@ -75,15 +87,41 @@ DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
 top_distdir = $(distdir)
 am__remove_distdir = \
-  { test ! -d $(distdir) \
-    || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \
-         && rm -fr $(distdir); }; }
+  { test ! -d "$(distdir)" \
+    || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
+         && rm -fr "$(distdir)"; }; }
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 DIST_ARCHIVES = $(distdir).tar.gz
 GZIP_ENV = --best
 distuninstallcheck_listfiles = find . -type f -print
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
@@ -120,6 +158,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
@@ -179,6 +218,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = gnu
@@ -192,15 +232,15 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
-	      echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \
-	      cd $(srcdir) && $(AUTOMAKE) --gnu  \
+	      echo ' cd $(srcdir) && $(AUTOMAKE) --gnu'; \
+	      $(am__cd) $(srcdir) && $(AUTOMAKE) --gnu \
 		&& exit 0; \
 	      exit 1;; \
 	  esac; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
@@ -216,9 +256,10 @@ $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENC
 	$(SHELL) ./config.status --recheck
 
 $(top_srcdir)/configure:  $(am__configure_deps)
-	cd $(srcdir) && $(AUTOCONF)
+	$(am__cd) $(srcdir) && $(AUTOCONF)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
-	cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+	$(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+$(am__aclocal_m4_deps):
 
 # This directory's subdirectories are mostly independent; you can cd
 # into them and run `make' without going through this Makefile.
@@ -227,7 +268,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	    *=* | --[!k]*);; \
@@ -244,7 +285,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	    local_target="$$target"; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
@@ -252,7 +293,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	    *=* | --[!k]*);; \
@@ -278,16 +319,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	    local_target="$$target"; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -295,14 +336,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 tags: TAGS
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
@@ -314,7 +355,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
@@ -323,36 +364,41 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
 distdir: $(DISTFILES)
 	$(am__remove_distdir)
-	test -d $(distdir) || mkdir $(distdir)
+	test -d "$(distdir)" || mkdir "$(distdir)"
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
@@ -368,38 +414,55 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	  fi; \
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	      || exit 1; \
 	  fi; \
 	done
-	-find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \
+	-test -n "$(am__skip_mode_fix)" \
+	|| find "$(distdir)" -type d ! -perm -755 \
+		-exec chmod u+rwx,go+rx {} \; -o \
 	  ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
-	|| chmod -R a+r $(distdir)
+	|| chmod -R a+r "$(distdir)"
 dist-gzip: distdir
 	tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
 	$(am__remove_distdir)
@@ -412,6 +475,10 @@ dist-lzma: distdir
 	tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
 	$(am__remove_distdir)
 
+dist-xz: distdir
+	tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz
+	$(am__remove_distdir)
+
 dist-tarZ: distdir
 	tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
 	$(am__remove_distdir)
@@ -435,15 +502,17 @@ dist dist-all: distdir
 distcheck: dist
 	case '$(DIST_ARCHIVES)' in \
 	*.tar.gz*) \
-	  GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\
+	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
 	*.tar.bz2*) \
-	  bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\
+	  bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
 	*.tar.lzma*) \
-	  unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\
+	  lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
+	*.tar.xz*) \
+	  xz -dc $(distdir).tar.xz | $(am__untar) ;;\
 	*.tar.Z*) \
 	  uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
 	*.shar.gz*) \
-	  GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\
+	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
 	*.zip*) \
 	  unzip $(distdir).zip ;;\
 	esac
@@ -451,9 +520,11 @@ distcheck: dist
 	mkdir $(distdir)/_build
 	mkdir $(distdir)/_inst
 	chmod a-w $(distdir)
+	test -d $(distdir)/_build || exit 0; \
 	dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
 	  && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
-	  && cd $(distdir)/_build \
+	  && am__cwd=`pwd` \
+	  && $(am__cd) $(distdir)/_build \
 	  && ../configure --srcdir=.. --prefix="$$dc_install_base" \
 	    $(DISTCHECK_CONFIGURE_FLAGS) \
 	  && $(MAKE) $(AM_MAKEFLAGS) \
@@ -475,13 +546,15 @@ distcheck: dist
 	  && rm -rf "$$dc_destdir" \
 	  && $(MAKE) $(AM_MAKEFLAGS) dist \
 	  && rm -rf $(DIST_ARCHIVES) \
-	  && $(MAKE) $(AM_MAKEFLAGS) distcleancheck
+	  && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
+	  && cd "$$am__cwd" \
+	  || exit 1
 	$(am__remove_distdir)
 	@(echo "$(distdir) archives ready for distribution: "; \
 	  list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
 	  sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
 distuninstallcheck:
-	@cd $(distuninstallcheck_dir) \
+	@$(am__cd) '$(distuninstallcheck_dir)' \
 	&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
 	   || { echo "ERROR: files left after uninstall:" ; \
 	        if test -n "$(DESTDIR)"; then \
@@ -523,6 +596,7 @@ clean-generic:
 
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
@@ -542,6 +616,8 @@ dvi-am:
 
 html: html-recursive
 
+html-am:
+
 info: info-recursive
 
 info-am:
@@ -550,18 +626,28 @@ install-data-am:
 
 install-dvi: install-dvi-recursive
 
+install-dvi-am:
+
 install-exec-am:
 
 install-html: install-html-recursive
 
+install-html-am:
+
 install-info: install-info-recursive
 
+install-info-am:
+
 install-man:
 
 install-pdf: install-pdf-recursive
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 
+install-ps-am:
+
 installcheck-am:
 
 maintainer-clean: maintainer-clean-recursive
@@ -585,21 +671,21 @@ ps-am:
 
 uninstall-am:
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+	install-am install-strip tags-recursive
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am am--refresh check check-am clean clean-generic \
 	clean-local ctags ctags-recursive dist dist-all dist-bzip2 \
-	dist-gzip dist-lzma dist-shar dist-tarZ dist-zip distcheck \
-	distclean distclean-generic distclean-tags distcleancheck \
-	distdir distuninstallcheck dvi dvi-am html html-am info \
-	info-am install install-am install-data install-data-am \
-	install-dvi install-dvi-am install-exec install-exec-am \
-	install-html install-html-am install-info install-info-am \
-	install-man install-pdf install-pdf-am install-ps \
-	install-ps-am install-strip installcheck installcheck-am \
-	installdirs installdirs-am maintainer-clean \
+	dist-gzip dist-lzma dist-shar dist-tarZ dist-xz dist-zip \
+	distcheck distclean distclean-generic distclean-tags \
+	distcleancheck distdir distuninstallcheck dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am install-info \
+	install-info-am install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic maintainer-clean-local mostlyclean \
 	mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \
 	uninstall uninstall-am
@@ -629,6 +715,10 @@ have-xcodebuild:
 	 >/dev/null 2>&1 \
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 
+have-packagemaker:
+	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
+	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
+
 xcode: have-xcodebuild
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
@@ -647,10 +737,15 @@ deb:
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	dpkg-buildpackage -rfakeroot -i
 
-osxpkg: have-xcodebuild
-	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
-	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
-	make clean
+osxpkg: have-packagemaker osxpkg-dest
+	cd contrib/MacOSX && packagemaker \
+	 --doc ngIRCd.pmdoc \
+	 --out ../../$(distdir).mpkg
+	rm -f $(distdir).mpkg.zip
+	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
+	rm -rf ngircd.dest $(distdir).mpkg
+
+osxpkg-dest: have-xcodebuild clean
 	./configure --prefix=/opt/ngircd
 	make xcode
 	make -C contrib/MacOSX de.barton.ngircd.plist
@@ -663,14 +758,12 @@ osxpkg: have-xcodebuild
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	chmod -R a-s,og-w,a+rX ngircd.dest
-	cd contrib/MacOSX && packagemaker \
-	 --doc ngIRCd.pmdoc \
-	 --out ../../$(distdir).mpkg
-	rm -f $(distdir).mpkg.zip
-	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
-	rm -rf ngircd.dest $(distdir).mpkg
+
+.PHONY: deb have-packagemaker have-xcodebuild lint osxpkg osxpkg-dest rpm \
+	srcdoc testsuite xcode xcode-clean
 
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:

+ 76 - 3
NEWS

@@ -1,14 +1,87 @@
 
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
 
                                   -- NEWS --
 
+ngIRCd Release 18 (2011-07-10)
+
+  - Add preliminary ngIRCd protocol module for Anope 1.9 to contrib/Anope/.
+
+  ngIRCd 18~rc2 (2011-06-29)
+  - GnuTLS: use 1024 bits as minimum size of the DH prime. This enables
+    ngIRCd to accept incoming connections from other servers and clients
+    that "only" use at least 1024 bits again, like ngIRCd 17 did (and no
+    longer requires 2048 bits for incoming connections).
+
+  ngIRCd 18~rc1 (2011-06-27)
+  - New configuration option "MorePrivacy" to "censor" some user information.
+    When enabled, signon time and idle time is left out. Part and quit
+    messages are made to look the same. WHOWAS requests are silently dropped.
+    All of this is useful if one wish to conceal users that access the ngircd
+    servers from TOR or I2P.
+  - New configuration option "ScrubCTCP" to scrub incoming CTCP commands. If
+    activated, the server silently drops incoming CTCP requests from both
+    other servers and from users. The server that scrubs CTCP will not forward
+    the CTCP requests to other servers in the network either, which can spell
+    trouble if not every oper knows about the CTCP-scrubbing. Scrubbing CTCP
+    commands also means that it is not possible to send files between users.
+    There is one exception to the CTCP scrubbing performed: ACTION ("/me
+    commands") requests are not scrubbed.
+  - Restructure ngIRCd configuration file: introduce new [Limits], [Options],
+    and [SSL] sections. The intention of this restructuring is to make the
+    [Global] section much cleaner, so that it only contains variables that
+    most installations must adjust to the local requirements. All the optional
+    variables are moved to [Limits], for configurable limits and timers of
+    ngIRCd, and [Options], for optional features. All SSL-related variables
+    are moved to [SSL] and the "SSL"-prefix is stripped. The old variables in
+    the [Global] section are deprecated now, but are still recognized.
+    => Don't forget to check your configuration, use "ngircd --configtest"!
+  - New documentation "how to contribute": doc/Contributing.txt.
+  - Avoid needlessly scary 'buffer overflow' messages: When the write buffer
+    space grows too large, ngIRCd has to disconnect the client to avoid
+    wasting too much memory, which is logged with a scary 'write buffer
+    overflow' message. Change this to a more descriptive wording.
+  - New configuration option "RequireAuthPing": PING-PONG on login. When
+    enabled, this configuration option lets ngIRCd send a PING with an numeric
+    "token" to clients logging in; and it will not become registered in the
+    network until the client responds with the correct PONG.
+  - New configuration option "NoticeAuth": send NOTICE AUTH on connect. When
+    active, ngircd will send "NOTICE AUTH" messages on client connect time
+    like e.g. snircd (QuakeNet) does.
+  - Add support for up to 3 targets in WHOIS queries, also allow up to one
+    wildcard query from local hosts. Follows ircd 2.10 implementation rather
+    than RFC 2812. At most 10 entries are returned per wildcard expansion.
+  - ngircd.conf(5) manual page: describe types of configuration variables
+    (booleans, text strings, integer numbers) and add type information to each
+    variable description.
+  - Terminate incoming connections on HTTP commands "GET" and "POST".
+  - New configuration option "CloakHost": when set, this hostname is used for
+    every client instead of the real DNS hostname (or IP address).
+  - New configuration option "CloakUserToNick": when enabled, ngIRCd sets
+    every clients' user name to their nick name and hides the user name
+    supplied by the IRC client.
+  - Make write buffers bigger, but flush early. Before this change, a client
+    got disconnected if the buffer flushing at 4k failed, now regular clients
+    can store up to 32k and servers up 64k even if flushing is not possible at
+    the moment. This enhances reliability on slow links.
+  - Allow "Port = 0" in [Server] blocks. Port number 0 marks remote servers
+    that try to connect to this daemon, but where this daemon never tries to
+    establish a connection on its own: only incoming connections are allowed.
+  - Enable WHOIS command to return information about services.
+  - Implement channel mode 'O': "IRC operators only". This channel mode is
+    used on DALnet (bahamut), for example.
+  - Remove support for ZeroConf/Bonjour/Rendezvous service registration
+    including the "[No]ZeroConf" configuration option.
+  - Deprecate NoXX-Options in ngircd.conf and move new variants into our new
+    [Options] section: 'NoDNS=no' => 'DNS=yes', 'NoIdent=no' => 'Ident=yes',
+    'NoPAM=no' => 'PAM=yes', and 'NoZeroConf=no' => 'ZeroConf=yes' (and
+    vice-versa). The defaults are adjusted accordingly and the old variables
+    in [Global] are still accepted, so there is no functional change.
 
 ngIRCd Release 17.1 (2010-12-19)
 

+ 2 - 3
README

@@ -1,9 +1,8 @@
 
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
-                        (c)2001-2007 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
 

+ 217 - 107
aclocal.m4

@@ -1,7 +1,7 @@
-# generated automatically by aclocal 1.10.1 -*- Autoconf -*-
+# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2009  Free Software Foundation, Inc.
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
@@ -13,13 +13,13 @@
 
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(AC_AUTOCONF_VERSION, [2.61],,
-[m4_warning([this file was generated for autoconf 2.61.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
+[m4_warning([this file was generated for autoconf 2.67.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically `autoreconf'.])])
 
-# Copyright (C) 2002, 2003, 2005, 2006, 2007  Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -31,10 +31,10 @@ To do so, use the procedure documented by the package, typically `autoreconf'.])
 # generated from the m4 files accompanying Automake X.Y.
 # (This private macro should not be called outside this file.)
 AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.10'
+[am__api_version='1.11'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.10.1], [],
+m4_if([$1], [1.11.1], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 
@@ -48,12 +48,12 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # AM_SET_CURRENT_AUTOMAKE_VERSION
 # -------------------------------
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
-# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
+# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.10.1])dnl
+[AM_AUTOMAKE_VERSION([1.11.1])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-_AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)])
+_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
@@ -110,14 +110,14 @@ am_aux_dir=`cd $ac_aux_dir && pwd`
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
-# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
+# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
 # Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 8
+# serial 9
 
 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
 # -------------------------------------
@@ -130,6 +130,7 @@ AC_SUBST([$1_TRUE])dnl
 AC_SUBST([$1_FALSE])dnl
 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
+m4_define([_AM_COND_VALUE_$1], [$2])dnl
 if $2; then
   $1_TRUE=
   $1_FALSE='#'
@@ -143,14 +144,14 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
 # Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 9
+# serial 10
 
 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
 # written in clear, in which case automake, when reading aclocal.m4,
@@ -207,6 +208,16 @@ AC_CACHE_CHECK([dependency style of $depcc],
   if test "$am_compiler_list" = ""; then
      am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
   fi
+  am__universal=false
+  m4_case([$1], [CC],
+    [case " $depcc " in #(
+     *\ -arch\ *\ -arch\ *) am__universal=true ;;
+     esac],
+    [CXX],
+    [case " $depcc " in #(
+     *\ -arch\ *\ -arch\ *) am__universal=true ;;
+     esac])
+
   for depmode in $am_compiler_list; do
     # Setup a source with many dependencies, because some compilers
     # like to wrap large dependency lists on column 80 (with \), and
@@ -224,7 +235,17 @@ AC_CACHE_CHECK([dependency style of $depcc],
     done
     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
 
+    # We check with `-c' and `-o' for the sake of the "dashmstdout"
+    # mode.  It turns out that the SunPro C++ compiler does not properly
+    # handle `-M -o', and we need to detect this.  Also, some Intel
+    # versions had trouble with output in subdirs
+    am__obj=sub/conftest.${OBJEXT-o}
+    am__minus_obj="-o $am__obj"
     case $depmode in
+    gcc)
+      # This depmode causes a compiler race in universal mode.
+      test "$am__universal" = false || continue
+      ;;
     nosideeffect)
       # after this tag, mechanisms are not by side-effect, so they'll
       # only be used when explicitly requested
@@ -234,19 +255,23 @@ AC_CACHE_CHECK([dependency style of $depcc],
 	break
       fi
       ;;
+    msvisualcpp | msvcmsys)
+      # This compiler won't grok `-c -o', but also, the minuso test has
+      # not run yet.  These depmodes are late enough in the game, and
+      # so weak that their functioning should not be impacted.
+      am__obj=conftest.${OBJEXT-o}
+      am__minus_obj=
+      ;;
     none) break ;;
     esac
-    # We check with `-c' and `-o' for the sake of the "dashmstdout"
-    # mode.  It turns out that the SunPro C++ compiler does not properly
-    # handle `-M -o', and we need to detect this.
     if depmode=$depmode \
-       source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
+       source=sub/conftest.c object=$am__obj \
        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
-       $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
+       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
          >/dev/null 2>conftest.err &&
        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
-       grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
       # icc doesn't choke on unknown options, it will just issue warnings
       # or remarks (even with -Werror).  So we grep stderr for any message
@@ -303,57 +328,68 @@ _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
 # Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-#serial 3
+#serial 5
 
 # _AM_OUTPUT_DEPENDENCY_COMMANDS
 # ------------------------------
 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
-[for mf in $CONFIG_FILES; do
-  # Strip MF so we end up with the name of the file.
-  mf=`echo "$mf" | sed -e 's/:.*$//'`
-  # Check whether this is an Automake generated Makefile or not.
-  # We used to match only the files named `Makefile.in', but
-  # some people rename them; so instead we look at the file content.
-  # Grep'ing the first line is not enough: some people post-process
-  # each Makefile.in and add a new line on top of each file to say so.
-  # Grep'ing the whole file is not good either: AIX grep has a line
-  # limit of 2048, but all sed's we know have understand at least 4000.
-  if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
-    dirpart=`AS_DIRNAME("$mf")`
-  else
-    continue
-  fi
-  # Extract the definition of DEPDIR, am__include, and am__quote
-  # from the Makefile without running `make'.
-  DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
-  test -z "$DEPDIR" && continue
-  am__include=`sed -n 's/^am__include = //p' < "$mf"`
-  test -z "am__include" && continue
-  am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
-  # When using ansi2knr, U may be empty or an underscore; expand it
-  U=`sed -n 's/^U = //p' < "$mf"`
-  # Find all dependency output files, they are included files with
-  # $(DEPDIR) in their names.  We invoke sed twice because it is the
-  # simplest approach to changing $(DEPDIR) to its actual value in the
-  # expansion.
-  for file in `sed -n "
-    s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
-       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
-    # Make sure the directory exists.
-    test -f "$dirpart/$file" && continue
-    fdir=`AS_DIRNAME(["$file"])`
-    AS_MKDIR_P([$dirpart/$fdir])
-    # echo "creating $dirpart/$file"
-    echo '# dummy' > "$dirpart/$file"
+[{
+  # Autoconf 2.62 quotes --file arguments for eval, but not when files
+  # are listed without --file.  Let's play safe and only enable the eval
+  # if we detect the quoting.
+  case $CONFIG_FILES in
+  *\'*) eval set x "$CONFIG_FILES" ;;
+  *)   set x $CONFIG_FILES ;;
+  esac
+  shift
+  for mf
+  do
+    # Strip MF so we end up with the name of the file.
+    mf=`echo "$mf" | sed -e 's/:.*$//'`
+    # Check whether this is an Automake generated Makefile or not.
+    # We used to match only the files named `Makefile.in', but
+    # some people rename them; so instead we look at the file content.
+    # Grep'ing the first line is not enough: some people post-process
+    # each Makefile.in and add a new line on top of each file to say so.
+    # Grep'ing the whole file is not good either: AIX grep has a line
+    # limit of 2048, but all sed's we know have understand at least 4000.
+    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
+      dirpart=`AS_DIRNAME("$mf")`
+    else
+      continue
+    fi
+    # Extract the definition of DEPDIR, am__include, and am__quote
+    # from the Makefile without running `make'.
+    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
+    test -z "$DEPDIR" && continue
+    am__include=`sed -n 's/^am__include = //p' < "$mf"`
+    test -z "am__include" && continue
+    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
+    # When using ansi2knr, U may be empty or an underscore; expand it
+    U=`sed -n 's/^U = //p' < "$mf"`
+    # Find all dependency output files, they are included files with
+    # $(DEPDIR) in their names.  We invoke sed twice because it is the
+    # simplest approach to changing $(DEPDIR) to its actual value in the
+    # expansion.
+    for file in `sed -n "
+      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
+	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
+      # Make sure the directory exists.
+      test -f "$dirpart/$file" && continue
+      fdir=`AS_DIRNAME(["$file"])`
+      AS_MKDIR_P([$dirpart/$fdir])
+      # echo "creating $dirpart/$file"
+      echo '# dummy' > "$dirpart/$file"
+    done
   done
-done
+}
 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
 
@@ -385,13 +421,13 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
 # Do all the work for Automake.                             -*- Autoconf -*-
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2008 Free Software Foundation, Inc.
+# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 13
+# serial 16
 
 # This macro actually does too much.  Some checks are only needed if
 # your package does certain things.  But this isn't really a big deal.
@@ -408,7 +444,7 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
 # arguments mandatory, and then we can depend on a new Autoconf
 # release and drop the old call support.
 AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_PREREQ([2.60])dnl
+[AC_PREREQ([2.62])dnl
 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 dnl the ones we care about.
 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@@ -459,8 +495,8 @@ AM_MISSING_PROG(AUTOCONF, autoconf)
 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
 AM_MISSING_PROG(AUTOHEADER, autoheader)
 AM_MISSING_PROG(MAKEINFO, makeinfo)
-AM_PROG_INSTALL_SH
-AM_PROG_INSTALL_STRIP
+AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
+AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
 # We need awk for the "check" target.  The system "awk" is bad on
 # some platforms.
@@ -468,24 +504,37 @@ AC_REQUIRE([AC_PROG_AWK])dnl
 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
-              [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
-	      		     [_AM_PROG_TAR([v7])])])
+	      [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
+			     [_AM_PROG_TAR([v7])])])
 _AM_IF_OPTION([no-dependencies],,
 [AC_PROVIDE_IFELSE([AC_PROG_CC],
-                  [_AM_DEPENDENCIES(CC)],
-                  [define([AC_PROG_CC],
-                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
+		  [_AM_DEPENDENCIES(CC)],
+		  [define([AC_PROG_CC],
+			  defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
 AC_PROVIDE_IFELSE([AC_PROG_CXX],
-                  [_AM_DEPENDENCIES(CXX)],
-                  [define([AC_PROG_CXX],
-                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
+		  [_AM_DEPENDENCIES(CXX)],
+		  [define([AC_PROG_CXX],
+			  defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
-                  [_AM_DEPENDENCIES(OBJC)],
-                  [define([AC_PROG_OBJC],
-                          defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
+		  [_AM_DEPENDENCIES(OBJC)],
+		  [define([AC_PROG_OBJC],
+			  defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
 ])
+_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
+dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
+dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
+dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
+AC_CONFIG_COMMANDS_PRE(dnl
+[m4_provide_if([_AM_COMPILER_EXEEXT],
+  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 ])
 
+dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
+dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
+dnl mangled by Autoconf and run in a shell conditional statement.
+m4_define([_AC_COMPILER_EXEEXT],
+m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
+
 
 # When config.status generates a header, we must update the stamp-h file.
 # This file resides in the same directory as the config header
@@ -508,7 +557,7 @@ for _am_header in $config_headers :; do
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
-# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2003, 2005, 2008  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -519,7 +568,14 @@ echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_co
 # Define $install_sh.
 AC_DEFUN([AM_PROG_INSTALL_SH],
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
-install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
+if test x"${install_sh}" != xset; then
+  case $am_aux_dir in
+  *\ * | *\	*)
+    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
+  *)
+    install_sh="\${SHELL} $am_aux_dir/install-sh"
+  esac
+fi
 AC_SUBST(install_sh)])
 
 # Copyright (C) 2003, 2005  Free Software Foundation, Inc.
@@ -545,13 +601,13 @@ AC_SUBST([am__leading_dot])])
 
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 
-# Copyright (C) 2001, 2002, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2005, 2009  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 3
+# serial 4
 
 # AM_MAKE_INCLUDE()
 # -----------------
@@ -560,7 +616,7 @@ AC_DEFUN([AM_MAKE_INCLUDE],
 [am_make=${MAKE-make}
 cat > confinc << 'END'
 am__doit:
-	@echo done
+	@echo this is the am__doit target
 .PHONY: am__doit
 END
 # If we don't find an include directive, just comment out the code.
@@ -570,24 +626,24 @@ am__quote=
 _am_result=none
 # First try GNU make style include.
 echo "include confinc" > confmf
-# We grep out `Entering directory' and `Leaving directory'
-# messages which can occur if `w' ends up in MAKEFLAGS.
-# In particular we don't look at `^make:' because GNU make might
-# be invoked under some other name (usually "gmake"), in which
-# case it prints its new name instead of `make'.
-if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
-   am__include=include
-   am__quote=
-   _am_result=GNU
-fi
+# Ignore all kinds of additional output from `make'.
+case `$am_make -s -f confmf 2> /dev/null` in #(
+*the\ am__doit\ target*)
+  am__include=include
+  am__quote=
+  _am_result=GNU
+  ;;
+esac
 # Now try BSD make style include.
 if test "$am__include" = "#"; then
    echo '.include "confinc"' > confmf
-   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
-      am__include=.include
-      am__quote="\""
-      _am_result=BSD
-   fi
+   case `$am_make -s -f confmf 2> /dev/null` in #(
+   *the\ am__doit\ target*)
+     am__include=.include
+     am__quote="\""
+     _am_result=BSD
+     ;;
+   esac
 fi
 AC_SUBST([am__include])
 AC_SUBST([am__quote])
@@ -597,14 +653,14 @@ rm -f confinc confmf
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
-# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
+# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
 # Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 5
+# serial 6
 
 # AM_MISSING_PROG(NAME, PROGRAM)
 # ------------------------------
@@ -621,7 +677,14 @@ AC_SUBST($1)])
 AC_DEFUN([AM_MISSING_HAS_RUN],
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 AC_REQUIRE_AUX_FILE([missing])dnl
-test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
+if test x"${MISSING+set}" != xset; then
+  case $am_aux_dir in
+  *\ * | *\	*)
+    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
+  *)
+    MISSING="\${SHELL} $am_aux_dir/missing" ;;
+  esac
+fi
 # Use eval to expand $SHELL
 if eval "$MISSING --run true"; then
   am_missing_run="$MISSING --run "
@@ -659,13 +722,13 @@ esac
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 
-# Copyright (C) 2001, 2002, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2005, 2008  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 3
+# serial 4
 
 # _AM_MANGLE_OPTION(NAME)
 # -----------------------
@@ -682,7 +745,7 @@ AC_DEFUN([_AM_SET_OPTION],
 # ----------------------------------
 # OPTIONS is a space-separated list of Automake options.
 AC_DEFUN([_AM_SET_OPTIONS],
-[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
+[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 
 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 # -------------------------------------------
@@ -718,14 +781,14 @@ AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES])
 
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
-# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
+# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
 # Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 4
+# serial 5
 
 # AM_SANITY_CHECK
 # ---------------
@@ -734,16 +797,29 @@ AC_DEFUN([AM_SANITY_CHECK],
 # Just in case
 sleep 1
 echo timestamp > conftest.file
+# Reject unsafe characters in $srcdir or the absolute working directory
+# name.  Accept space and tab only in the latter.
+am_lf='
+'
+case `pwd` in
+  *[[\\\"\#\$\&\'\`$am_lf]]*)
+    AC_MSG_ERROR([unsafe absolute working directory name]);;
+esac
+case $srcdir in
+  *[[\\\"\#\$\&\'\`$am_lf\ \	]]*)
+    AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
+esac
+
 # Do `set' in a subshell so we don't clobber the current shell's
 # arguments.  Must try -L first in case configure is actually a
 # symlink; some systems play weird games with the mod time of symlinks
 # (eg FreeBSD returns the mod time of the symlink's containing
 # directory).
 if (
-   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
+   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
    if test "$[*]" = "X"; then
       # -L didn't work.
-      set X `ls -t $srcdir/configure conftest.file`
+      set X `ls -t "$srcdir/configure" conftest.file`
    fi
    rm -f conftest.file
    if test "$[*]" != "X $srcdir/configure conftest.file" \
@@ -768,6 +844,33 @@ Check your system clock])
 fi
 AC_MSG_RESULT(yes)])
 
+# Copyright (C) 2009  Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# serial 1
+
+# AM_SILENT_RULES([DEFAULT])
+# --------------------------
+# Enable less verbose build rules; with the default set to DEFAULT
+# (`yes' being less verbose, `no' or empty being verbose).
+AC_DEFUN([AM_SILENT_RULES],
+[AC_ARG_ENABLE([silent-rules],
+[  --enable-silent-rules          less verbose build output (undo: `make V=1')
+  --disable-silent-rules         verbose build output (undo: `make V=0')])
+case $enable_silent_rules in
+yes) AM_DEFAULT_VERBOSITY=0;;
+no)  AM_DEFAULT_VERBOSITY=1;;
+*)   AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
+esac
+AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
+AM_BACKSLASH='\'
+AC_SUBST([AM_BACKSLASH])dnl
+_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
+])
+
 # Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
@@ -796,18 +899,25 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
-# Copyright (C) 2006  Free Software Foundation, Inc.
+# Copyright (C) 2006, 2008  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
+# serial 2
+
 # _AM_SUBST_NOTMAKE(VARIABLE)
 # ---------------------------
 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 # This macro is traced by Automake.
 AC_DEFUN([_AM_SUBST_NOTMAKE])
 
+# AM_SUBST_NOTMAKE(VARIABLE)
+# ---------------------------
+# Public sister of _AM_SUBST_NOTMAKE.
+AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
+
 # Check how to create a tarball.                            -*- Autoconf -*-
 
 # Copyright (C) 2004, 2005  Free Software Foundation, Inc.

File diff suppressed because it is too large
+ 4288 - 8964
configure


+ 11 - 74
configure.in

@@ -1,6 +1,6 @@
 #
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton <alex@barton.de>
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -33,7 +33,6 @@ AH_TEMPLATE([ZLIB], [Define if zlib compression should be enabled])
 AH_TEMPLATE([TCPWRAP], [Define if TCP wrappers should be used])
 AH_TEMPLATE([IRCPLUS], [Define if IRC+ protocol should be used])
 AH_TEMPLATE([WANT_IPV6], [Define if IPV6 protocol should be enabled])
-AH_TEMPLATE([ZEROCONF], [Define if support for Zeroconf should be included])
 AH_TEMPLATE([IDENTAUTH], [Define if the server should do IDENT requests])
 AH_TEMPLATE([PAM], [Define if PAM should be used])
 AH_TEMPLATE([HAVE_sockaddr_in_len], [Define if sockaddr_in.sin_len exists])
@@ -163,7 +162,7 @@ AC_CHECK_FUNCS([ \
 	bind gethostbyaddr gethostbyname gethostname inet_ntoa \
 	setsid setsockopt socket strcasecmp waitpid],,AC_MSG_ERROR([required function missing!]))
 
-AC_CHECK_FUNCS(getaddrinfo getnameinfo inet_aton isdigit sigaction sigprocmask snprintf \
+AC_CHECK_FUNCS(getaddrinfo getnameinfo inet_aton sigaction sigprocmask snprintf \
  vsnprintf strdup strlcpy strlcat strtok_r)
 
 # -- Configuration options --
@@ -411,56 +410,6 @@ int deny_severity = 0;
 	]
 )
 
-# include support for "zeroconf"?
-
-x_zeroconf_on=no
-AC_ARG_WITH(zeroconf,
-	[  --with-zeroconf         enable support for "Zeroconf"],
-	[	if test "$withval" != "no"; then
-			if test "$withval" != "yes"; then
-				CFLAGS="-I$withval/include $CFLAGS"
-				CPPFLAGS="-I$withval/include $CPPFLAGS"
-				LDFLAGS="-L$withval/lib $LDFLAGS"
-			fi
-			AC_CHECK_FUNCS(DNSServiceRegistrationCreate, x_zeroconf_on=osx,
-			[
-				AC_CHECK_LIB(pthread, pthread_mutexattr_init)
-				AC_CHECK_LIB(howl, sw_discovery_init)
-				AC_CHECK_FUNCS(sw_discovery_init, \
-				 x_zeroconf_on=howl, \
-				 AC_MSG_ERROR([Can't enable Zeroconf!]))
-			])
-		fi
-	]
-)
-if test "$x_zeroconf_on" = "osx"; then
-	AC_CHECK_HEADERS([DNSServiceDiscovery/DNSServiceDiscovery.h \
-	 mach/port.h],,AC_MSG_ERROR([required C header missing!]))
-	AC_DEFINE(ZEROCONF, 1)
-fi
-if test "$x_zeroconf_on" = "howl"; then
-	for dir in /usr/local/include /usr/local/include/howl* \
-	 /usr/include /usr/include/howl* \
-	 /usr/local/include/avahi* /usr/include/avahi*; do
-	 	test -d "$dir" || continue
-		AC_MSG_CHECKING([for Howl headers in $dir])
-		if test -f "$dir/rendezvous/rendezvous.h"; then
-			if test "$dir" != "/usr/local/include" -a \
-			 "$dir" != "/usr/include"; then
-				CFLAGS="-I$dir $CFLAGS"
-				CPPFLAGS="-I$dir $CPPFLAGS"
-			fi
-			AC_MSG_RESULT(yes)
-			break
-		else
-			AC_MSG_RESULT(no)
-		fi
-	done
-	AC_CHECK_HEADERS([rendezvous/rendezvous.h],, \
-	 AC_MSG_ERROR([required C header missing!]))
-	AC_DEFINE(ZEROCONF, 1)
-fi
-
 # do IDENT requests using libident?
 
 x_identauth_on=no
@@ -595,6 +544,7 @@ AC_OUTPUT([ \
 	src/testsuite/Makefile \
 	man/Makefile \
 	contrib/Makefile \
+	contrib/Anope/Makefile \
 	contrib/Debian/Makefile \
 	contrib/MacOSX/Makefile \
 	contrib/MacOSX/ngIRCd.xcodeproj/Makefile \
@@ -663,42 +613,29 @@ test "$x_strict_rfc_on" = "yes" \
 	&& echo "yes" \
 	|| echo "no"
 
-echo $ECHO_N "   Zeroconf support: $ECHO_C"
-case "$x_zeroconf_on" in
-	osx)
-		echo $ECHO_N "Apple $ECHO_C"
-		;;
-	howl)
-		echo $ECHO_N "Howl  $ECHO_C"
-		;;
-	*)
-		echo $ECHO_N "no    $ECHO_C"
-		;;
-esac
+echo $ECHO_N "      IDENT support: $ECHO_C"
+test "$x_identauth_on" = "yes" \
+	&& echo $ECHO_N "yes   $ECHO_C" \
+	|| echo $ECHO_N "no    $ECHO_C"
 echo $ECHO_N "      IRC+ protocol: $ECHO_C"
 test "$x_ircplus_on" = "yes" \
 	&& echo "yes" \
 	|| echo "no"
 
-echo $ECHO_N "      IDENT support: $ECHO_C"
-test "$x_identauth_on" = "yes" \
+echo $ECHO_N "      IPv6 protocol: $ECHO_C"
+test "$x_ipv6_on" = "yes" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	|| echo $ECHO_N "no    $ECHO_C"
 echo $ECHO_N "        I/O backend: $ECHO_C"
 	echo "\"$x_io_backend\""
 
-echo $ECHO_N "      IPv6 protocol: $ECHO_C"
-test "$x_ipv6_on" = "yes" \
+echo $ECHO_N "        PAM support: $ECHO_C"
+test "$x_pam_on" = "yes" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	|| echo $ECHO_N "no    $ECHO_C"
 echo $ECHO_N "        SSL support: $ECHO_C"
 echo "$x_ssl_lib"
 
-echo $ECHO_N "        PAM support: $ECHO_C"
-test "$x_pam_on" = "yes" \
-	&& echo "yes" \
-	|| echo "no"
-
 echo
 
 # -eof-

+ 496 - 0
contrib/Anope/0001-Revert-Removed-ngircd.patch

@@ -0,0 +1,496 @@
+From bc5023fdba8091ab7eee29fe0deeca6843159743 Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Mon, 16 May 2011 18:23:01 +0200
+Subject: [PATCH 1/2] Revert "Removed ngircd as we've decided not to support it at this time"
+
+This reverts commit 605b5d57171d2f0fac56ee2ee3e1b1bbdadeb24f and re-enables
+the ngIRCd protocol module for Anope.
+---
+ modules/protocol/ngircd.cpp |  475 +++++++++++++++++++++++++++++++++++++++++++
+ 1 files changed, 475 insertions(+), 0 deletions(-)
+ create mode 100644 modules/protocol/ngircd.cpp
+
+diff --git a/modules/protocol/ngircd.cpp b/modules/protocol/ngircd.cpp
+new file mode 100644
+index 0000000..6e1f21f
+--- /dev/null
++++ b/modules/protocol/ngircd.cpp
+@@ -0,0 +1,475 @@
++/* ngIRCd IRCD functions
++ *
++ * (C) 2003-2011 Anope Team
++ * Contact us at team@anope.org
++ *
++ * Please read COPYING and README for further details.
++ *
++ * Based on the original code of Epona by Lara.
++ * Based on the original code of Services by Andy Church.
++ */
++
++#include "services.h"
++#include "modules.h"
++
++IRCDVar myIrcd[] = {
++	{"ngIRCd",	/* ircd name */
++	 "+oi",		/* Modes used by pseudoclients */
++	 0,		/* SVSNICK */
++	 0,		/* Vhost */
++	 0,		/* Supports SNlines */
++	 0,		/* Supports SQlines */
++	 0,		/* Supports SZlines */
++	 0,		/* Join 2 Message */
++	 0,		/* Chan SQlines */
++	 1,		/* Quit on Kill */
++	 0,		/* vidents */
++	 0,		/* svshold */
++	 0,		/* time stamp on mode */
++	 0,		/* UMODE */
++	 0,		/* O:LINE */
++	 0,		/* No Knock requires +i */
++	 0,		/* Can remove User Channel Modes with SVSMODE */
++	 0,		/* Sglines are not enforced until user reconnects */
++	 0,		/* ts6 */
++	 "$",		/* TLD Prefix for Global */
++	 20,		/* Max number of modes we can send per line */
++	 0,		/* IRCd sends a SSL users certificate fingerprint */
++	 }
++	,
++	{NULL}
++};
++
++/* PASS */
++class ngIRCdProto : public IRCDProto
++{
++	void SendAkill(User *u, const XLine *x)
++	{
++		if (SGLine && u == NULL)
++			for (Anope::insensitive_map<User *>::iterator it = UserListByNick.begin(); it != UserListByNick.end();)
++			{
++				u = it->second;
++				++it;
++				if (SGLine->Check(u) != NULL)
++					break;
++			}
++	}
++
++	void SendAkillDel(const XLine*) { }
++
++	void SendGlobopsInternal(const BotInfo *source, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->ServerName, "WALLOPS :%s", buf.c_str());
++	}
++
++	void SendJoin(BotInfo *user, Channel *c, const ChannelStatus *status)
++	{
++		send_cmd(user->nick, "JOIN %s", c->name.c_str());
++		if (status)
++			for (unsigned i = 0; i < ModeManager::ChannelModes.size(); ++i)
++				if (status->HasFlag(ModeManager::ChannelModes[i]->Name))
++					c->SetMode(user, ModeManager::ChannelModes[i], user->nick, false);
++	}
++
++	void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->ServerName, "KILL %s :%s", user->nick.c_str(), buf.c_str());
++	}
++
++	/* SERVER name hop descript */
++	void SendServer(const Server *server)
++	{
++		send_cmd("", "SERVER %s %d :%s", server->GetName().c_str(), server->GetHops(), server->GetDescription().c_str());
++	}
++
++	void SendConnect()
++	{
++		send_cmd("", "PASS %s 0210-IRC+ Anope|%s:CLHSo P", uplink_server->password.c_str(), Anope::VersionShort().c_str());
++		/* Make myself known to myself in the serverlist */
++		SendServer(Me);
++		/* finish the enhanced server handshake and register the connection */
++		this->SendNumeric(Config->ServerName, 376, "*", ":End of MOTD command");
++	}
++
++	// Received: :dev.anope.de NICK DukeP 1 ~DukePyro p57ABF9C9.dip.t-dialin.net 1 +i :DukePyrolator
++	void SendClientIntroduction(const User *u, const Anope::string &modes)
++	{
++		EnforceQlinedNick(u->nick, "");
++		send_cmd(Config->ServerName, "NICK %s 1 %s %s 1 %s :%s", u->nick.c_str(), u->GetIdent().c_str(), u->host.c_str(), modes.c_str(), u->realname.c_str());
++	}
++
++	void SendPartInternal(const BotInfo *bi, const Channel *chan, const Anope::string &buf)
++	{
++		if (!buf.empty())
++			send_cmd(bi->nick, "PART %s :%s", chan->name.c_str(), buf.c_str());
++		else
++			send_cmd(bi->nick, "PART %s", chan->name.c_str());
++	}
++
++	void SendModeInternal(const BotInfo *bi, const Channel *dest, const Anope::string &buf)
++	{
++		send_cmd(bi ? bi->nick : Config->ServerName, "MODE %s %s", dest->name.c_str(), buf.c_str());
++	}
++
++	void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf)
++	{
++		send_cmd(bi ? bi->nick : Config->ServerName, "MODE %s %s", u->nick.c_str(), buf.c_str());
++	}
++
++	void SendKickInternal(const BotInfo *bi, const Channel *chan, const User *user, const Anope::string &buf)
++	{
++		if (!buf.empty())
++			send_cmd(bi->nick, "KICK %s %s :%s", chan->name.c_str(), user->nick.c_str(), buf.c_str());
++		else
++			send_cmd(bi->nick, "KICK %s %s", chan->name.c_str(), user->nick.c_str());
++	}
++
++	void SendNoticeChanopsInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->s_ChanServ, "NOTICE @%s :%s", dest->name.c_str(), buf.c_str());
++	}
++
++	/* INVITE */
++	void SendInvite(BotInfo *source, const Anope::string &chan, const Anope::string &nick)
++	{
++		send_cmd(source->nick, "INVITE %s %s", nick.c_str(), chan.c_str());
++	}
++
++	void SendChannel(Channel *c)
++	{
++		Anope::string mlock_modes = get_mlock_modes(c->ci, true);
++		if (mlock_modes.empty())
++			mlock_modes = "+";
++		send_cmd(Config->ServerName, "CHANINFO %s %s", c->name.c_str(), mlock_modes.c_str());
++	}
++	void SendTopic(BotInfo *bi, Channel *c)
++	{
++		send_cmd(bi->nick, "TOPIC %s :%s", c->name.c_str(), c->topic.c_str());
++	}
++};
++
++class ngIRCdIRCdMessage : public IRCdMessage
++{
++ public:
++	bool OnSJoin(const Anope::string&, const std::vector<Anope::string>&) { return false; }
++
++	/*
++	 * Received: :dev.anope.de MODE #anope +b *!*@*aol*
++	 */
++	bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() < 2)
++			return true;
++
++		Anope::string modes = params[1];
++		for (unsigned i = 2; i < params.size(); ++i)
++			modes += " " + params[i];
++
++		if (params[0][0] == '#' || params[0][0] == '&')
++			do_cmode(source, params[0], modes, "");
++		else
++			do_umode(params[0], params[1]);
++
++		return true;
++	}
++
++	/*
++	  Received: :DukeP_ NICK :test2
++	  Received: :dev.anope.de NICK DukeP_ 1 ~DukePyro ip-2-201-236-154.web.vodafone.de 1 + :DukePyrolator
++	  source = nickname on nickchange, servername on newuser
++	  params[0] = nick
++	  params[1] = <unknown>
++	  params[2] = username
++	  params[3] = host
++	  params[4] = <unknown>
++	  params[5] = modes
++	  params[6] = info
++	*/
++	bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() == 1)
++		{
++			// we have a nickchange
++			do_nick(source, params[0], "", "", "", "", Anope::CurTime, "", "", "", "");
++		}
++		else if (params.size() == 7)
++		{
++			// a new user is connecting to the network
++			User *user = do_nick("", params[0], params[2], params[3], source, params[6], Anope::CurTime, "", "", "", params[5]);
++			if (user)
++				validate_user(user);
++		}
++		else
++		{
++			Log() << "Received NICK with invalid number of parameters. source = " << source << "param[0] = " << params[0] << "params.size() = " << params.size();
++		}
++		return true;
++	}
++
++	bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() == 3)
++			do_server("", params[0], 0, params[2], params[1]);
++		else
++			do_server(source, params[0], params[1].is_pos_number_only() ? convertTo<unsigned>(params[1]) : 0, params[3], params[2]);
++		return true;
++	}
++
++	bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		Channel *c = findchan(params[0]);
++		if (!c)
++		{
++			Log() << "TOPIC for nonexistant channel " << params[0];
++			return true;
++		}
++
++		c->ChangeTopicInternal(source, params[1]);
++		return true;
++	}
++
++	/*
++	 * <@po||ux> DukeP: RFC 2813, 4.2.1: the JOIN command on server-server links
++	 * separates the modes ("o") with ASCII 7, not space. And you can't see ASCII 7.
++	 *
++	 * if a user joins a new channel, the ircd sends <channelname>\7<umode>
++	 */
++	bool OnJoin (const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (!params.empty())
++		{
++			size_t pos = params[0].find('\7');
++			if (pos != Anope::string::npos)
++			{
++				Anope::string channel = params[0].substr(0, pos);
++				Anope::string mode = '+' + params[0].substr(pos, params[0].length()) + " " + source;
++				do_join(source, channel, "");
++				do_cmode(source, channel, mode, "");
++			}
++			else
++				do_join(source, params[0], "");
++		}
++		return true;
++	}
++};
++
++/*
++ * CHANINFO <chan> +<modes>
++ * CHANINFO <chan> +<modes> :<topic>
++ * CHANINFO <chan> +<modes> <key> <limit> :<topic>
++ */
++bool event_chaninfo(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++
++	Channel *c = findchan(params[0]);
++	if (!c)
++		c = new Channel(params[0]);
++
++	Anope::string modes = params[1];
++	
++	if (params.size() == 3)
++	{
++		c->ChangeTopicInternal(source, params[2], Anope::CurTime);
++	} 
++	else if (params.size() == 5)
++	{
++		for (size_t i = 0, end = params[1].length(); i < end; ++i)
++		{
++			switch(params[1][i])
++			{
++				case 'k':
++					modes += " " + params[2];
++					continue;
++				case 'l':
++					modes += " " + params[3];
++					continue;
++			}
++		}
++		c->ChangeTopicInternal(source, params[4], Anope::CurTime);
++	}
++
++	c->SetModesInternal(NULL, modes);
++
++	return true;
++}
++
++/*
++ * Received: :dev.anope.de NJOIN #test :DukeP2,@DukeP
++ */
++bool event_njoin(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	Channel *c = findchan(params[0]);
++	commasepstream sep(params[1]);
++	Anope::string buf;
++
++	if (!c)
++	{
++		c = new Channel(params[0], Anope::CurTime);
++		c->SetFlag(CH_SYNCING);
++	}
++	
++	while (sep.GetToken(buf))
++	{
++		std::list<ChannelMode *> Status;
++		char ch;
++
++		/* Get prefixes from the nick */
++		while ((ch = ModeManager::GetStatusChar(buf[0])))
++		{
++			buf.erase(buf.begin());
++			ChannelMode *cm = ModeManager::FindChannelModeByChar(ch);
++			if (!cm)
++			{
++				Log() << "Received unknown mode prefix " << ch << " in NJOIN string.";
++				continue;
++			}
++			Status.push_back(cm);
++		}
++		User *u = finduser(buf);
++		if (!u)
++		{
++			Log(LOG_DEBUG) << "NJOIN for nonexistant user " << buf << " on " << c->name;
++			continue;
++		}
++
++		EventReturn MOD_RESULT;
++		FOREACH_RESULT(I_OnPreJoinChannel, OnPreJoinChannel(u, c));
++
++		/* Add the user to the Channel */
++		c->JoinUser(u);
++
++		/* Update their status internally on the channel
++		 * This will enforce secureops etc on the user
++		 */
++		for (std::list<ChannelMode *>::iterator it = Status.begin(), it_end = Status.end(); it != it_end; ++it)
++			c->SetModeInternal(*it, buf);
++		/* Now set whatever modes this user is allowed to have on the channel */
++		chan_set_correct_modes(u, c, 1);
++
++		/* Check to see if modules want the user to join, if they do
++		 * check to see if they are allowed to join (CheckKick will kick/ban them)
++		 * Don't trigger OnJoinChannel event then as the user will be destroyed
++		 */
++		if (MOD_RESULT != EVENT_STOP && c->ci && c->ci->CheckKick(u))
++			continue;
++
++		FOREACH_MOD(I_OnJoinChannel, OnJoinChannel(u, c));
++	} /* while */
++
++	if (c->HasFlag(CH_SYNCING))
++	{
++		c->UnsetFlag(CH_SYNCING);
++		c->Sync();
++	}
++
++	return true;
++}
++
++bool event_kick(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	if (params.size() > 2)
++		do_kick(source, params[0], params[1], params[2]);
++	return true;
++}
++
++bool event_pass(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++bool event_005(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	size_t pos;
++	Anope::string name, data;
++	for (unsigned i = 0, end = params.size(); i < end; ++i)
++	{
++		pos = params[i].find('=');
++		if (pos != Anope::string::npos)
++		{
++			name = params[i].substr(0, pos);
++			data = params[i].substr(pos+1, params[i].length());
++			if (name == "NICKLEN")
++			{
++				unsigned newlen = convertTo<unsigned>(data);
++				if (Config->NickLen != newlen)
++				{
++					Log() << "Config->NickLen changed from " << Config->NickLen << " to " << newlen;
++					Config->NickLen = newlen;
++				}
++			}
++		}
++	}
++	return true;
++}
++
++bool event_442(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++bool event_376(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++
++class ProtongIRCd : public Module
++{
++	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005, 
++		message_442, message_376;
++	
++	ngIRCdProto ircd_proto;
++	ngIRCdIRCdMessage ircd_message;
++
++	void AddModes()
++	{
++		/* Add user modes */
++		ModeManager::AddUserMode(new UserMode(UMODE_ADMIN, 'a'));
++		ModeManager::AddUserMode(new UserMode(UMODE_INVIS, 'i'));
++		ModeManager::AddUserMode(new UserMode(UMODE_OPER, 'o'));
++		ModeManager::AddUserMode(new UserMode(UMODE_RESTRICTED, 'r'));
++		ModeManager::AddUserMode(new UserMode(UMODE_SNOMASK, 's'));
++		ModeManager::AddUserMode(new UserMode(UMODE_WALLOPS, 'w'));
++		ModeManager::AddUserMode(new UserMode(UMODE_CLOAK, 'x'));
++
++		/* b/e/I */
++		ModeManager::AddChannelMode(new ChannelModeBan(CMODE_BAN, 'b'));
++		ModeManager::AddChannelMode(new ChannelModeList(CMODE_INVITEOVERRIDE, 'I'));
++
++		/* v/h/o/a/q */
++		ModeManager::AddChannelMode(new ChannelModeStatus(CMODE_VOICE, 'v', '+'));
++		ModeManager::AddChannelMode(new ChannelModeStatus(CMODE_OP, 'o', '@'));
++
++		/* Add channel modes */
++		// channel modes: biIklmnoPstvz
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_INVITE, 'i'));
++		ModeManager::AddChannelMode(new ChannelModeKey('k'));
++		ModeManager::AddChannelMode(new ChannelModeParam(CMODE_LIMIT, 'l'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_MODERATED, 'm'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_NOEXTERNAL, 'n'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_PERM, 'P'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_SECRET, 's'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_TOPIC, 't'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_SSL, 'z'));
++	}
++
++ public:
++	ProtongIRCd(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator),
++		message_kick("KICK", event_kick), message_pass("PASS", event_pass),
++		message_njoin("NJOIN", event_njoin), message_chaninfo("CHANINFO", event_chaninfo),
++		message_005("005", event_005), message_442("442", event_442), message_376("376", event_376)
++	{
++		this->SetAuthor("Anope");
++		this->SetType(PROTOCOL);
++		
++		Capab.SetFlag(CAPAB_QS);
++
++		pmodule_ircd_var(myIrcd);
++		pmodule_ircd_proto(&this->ircd_proto);
++		pmodule_ircd_message(&this->ircd_message);
++
++		this->AddModes();
++	}
++};
++
++MODULE_INIT(ProtongIRCd)
+-- 
+1.7.2.5
+

+ 60 - 0
contrib/Anope/0002-ngircd-whitespace-fixes.patch

@@ -0,0 +1,60 @@
+From 1ea1dd2095e63cef34edbebb729edc687f410a96 Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Mon, 16 May 2011 18:26:56 +0200
+Subject: [PATCH 2/2] ngircd: whitespace fixes
+
+---
+ modules/protocol/ngircd.cpp |   12 ++++++------
+ 1 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/modules/protocol/ngircd.cpp b/modules/protocol/ngircd.cpp
+index 6e1f21f..e546d05 100644
+--- a/modules/protocol/ngircd.cpp
++++ b/modules/protocol/ngircd.cpp
+@@ -266,11 +266,11 @@ bool event_chaninfo(const Anope::string &source, const std::vector<Anope::string
+ 		c = new Channel(params[0]);
+ 
+ 	Anope::string modes = params[1];
+-	
++
+ 	if (params.size() == 3)
+ 	{
+ 		c->ChangeTopicInternal(source, params[2], Anope::CurTime);
+-	} 
++	}
+ 	else if (params.size() == 5)
+ 	{
+ 		for (size_t i = 0, end = params[1].length(); i < end; ++i)
+@@ -307,7 +307,7 @@ bool event_njoin(const Anope::string &source, const std::vector<Anope::string> &
+ 		c = new Channel(params[0], Anope::CurTime);
+ 		c->SetFlag(CH_SYNCING);
+ 	}
+-	
++
+ 	while (sep.GetToken(buf))
+ 	{
+ 		std::list<ChannelMode *> Status;
+@@ -415,9 +415,9 @@ bool event_376(const Anope::string &source, const std::vector<Anope::string> &pa
+ 
+ class ProtongIRCd : public Module
+ {
+-	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005, 
++	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005,
+ 		message_442, message_376;
+-	
++
+ 	ngIRCdProto ircd_proto;
+ 	ngIRCdIRCdMessage ircd_message;
+ 
+@@ -461,7 +461,7 @@ class ProtongIRCd : public Module
+ 	{
+ 		this->SetAuthor("Anope");
+ 		this->SetType(PROTOCOL);
+-		
++
+ 		Capab.SetFlag(CAPAB_QS);
+ 
+ 		pmodule_ircd_var(myIrcd);
+-- 
+1.7.2.5
+

+ 20 - 0
contrib/Anope/Makefile.am

@@ -0,0 +1,20 @@
+#
+# ngIRCd -- The Next Generation IRC Daemon
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+# Please read the file COPYING, README and AUTHORS for more information.
+#
+
+EXTRA_DIST = \
+	README \
+	0001-Revert-Removed-ngircd.patch \
+	0002-ngircd-whitespace-fixes.patch
+
+maintainer-clean-local:
+	rm -f Makefile Makefile.in
+
+# -eof-

+ 361 - 0
contrib/Anope/Makefile.in

@@ -0,0 +1,361 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+#
+# ngIRCd -- The Next Generation IRC Daemon
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+# Please read the file COPYING, README and AUTHORS for more information.
+#
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = contrib/Anope
+DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+	$(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/src/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LDFLAGS = @LDFLAGS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAKEINFO = @MAKEINFO@
+MKDIR_P = @MKDIR_P@
+OBJEXT = @OBJEXT@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+RANLIB = @RANLIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+U = @U@
+VERSION = @VERSION@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+	README \
+	0001-Revert-Removed-ngircd.patch \
+	0002-ngircd-whitespace-fixes.patch
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
+	@for dep in $?; do \
+	  case '$(am__configure_deps)' in \
+	    *$$dep*) \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
+	      exit 1;; \
+	  esac; \
+	done; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/Anope/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/Anope/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+	@case '$?' in \
+	  *config.status*) \
+	    cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+	  *) \
+	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+	esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure:  $(am__configure_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4):  $(am__aclocal_m4_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	list='$(DISTFILES)'; \
+	  dist_files=`for file in $$list; do echo $$file; done | \
+	  sed -e "s|^$$srcdirstrip/||;t" \
+	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+	case $$dist_files in \
+	  */*) $(MKDIR_P) `echo "$$dist_files" | \
+			   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+			   sort -u` ;; \
+	esac; \
+	for file in $$dist_files; do \
+	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+	  if test -d $$d/$$file; then \
+	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+	  else \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
+	    || exit 1; \
+	  fi; \
+	done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+	$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+	  install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+	  `test -z '$(STRIP)' || \
+	    echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+	@echo "This command is intended for maintainers to use"
+	@echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic mostlyclean-am
+
+distclean: distclean-am
+	-rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+	-rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic \