* [PATCH] gnu: Add ngircd.
@ 2015-01-31 21:49 "Taylan Ulrich Bayırlı/Kammer"
2015-01-31 23:58 ` Taylan Ulrich Bayırlı/Kammer
0 siblings, 1 reply; 8+ messages in thread
From: "Taylan Ulrich Bayırlı/Kammer" @ 2015-01-31 21:49 UTC (permalink / raw
To: guix-devel
===File /home/tub/media/src/guix/0001-gnu-Add-ngircd.patch===
From 5b4569f28f675f7091484133ae430384db585f8f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
<taylanbayirli@gmail.com>
Date: Sat, 31 Jan 2015 22:03:25 +0100
Subject: [PATCH] gnu: Add ngircd.
* gnu-system.am (GNU_SYSTEM_MODULES): Add ngircd.scm.
* gnu/packages/ngircd.scm: New file.
---
gnu-system.am | 1 +
gnu/packages/ngircd.scm | 54 +++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 55 insertions(+)
create mode 100644 gnu/packages/ngircd.scm
diff --git a/gnu-system.am b/gnu-system.am
index 706ad57..488e7a5 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -197,6 +197,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/ncurses.scm \
gnu/packages/netpbm.scm \
gnu/packages/nettle.scm \
+ gnu/packages/ngircd.scm \
gnu/packages/ninja.scm \
gnu/packages/node.scm \
gnu/packages/noweb.scm \
diff --git a/gnu/packages/ngircd.scm b/gnu/packages/ngircd.scm
new file mode 100644
index 0000000..b947076
--- /dev/null
+++ b/gnu/packages/ngircd.scm
@@ -0,0 +1,54 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix 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 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages ngircd)
+ #:use-module (guix licenses)
+ #:use-module (guix packages)
+ #:use-module (guix download)
+ #:use-module (guix build-system gnu))
+
+(define-public ngircd
+ (package
+ (name "ngircd")
+ (version "22")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:phases
+ ;; Necessary for the test suite, should it be enabled in the future.
+ (alist-cons-after
+ 'configure 'post-configure
+ (lambda _
+ (substitute* "src/ngircd/Makefile"
+ (("#!/bin/sh") (which "sh"))))
+ %standard-phases)
+ ;; Test-suite inflates our dependencies with e.g. expect(1).
+ #:tests? #f))
+ (home-page "http://ngircd.barton.de/")
+ (synopsis "Lightweight Internet Relay Chat server for small networks")
+ (description
+ "ngIRCd is a lightweight Internet Relay Chat server for small or private
+networks. It is easy to configure, can cope with dynamic IP addresses, and
+supports IPv6, SSL-protected connections as well as PAM for authentication.")
+ (license gpl2+)))
--
2.2.1
============================================================
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-01-31 21:49 [PATCH] gnu: Add ngircd "Taylan Ulrich Bayırlı/Kammer"
@ 2015-01-31 23:58 ` Taylan Ulrich Bayırlı/Kammer
2015-02-01 6:58 ` Mark H Weaver
0 siblings, 1 reply; 8+ messages in thread
From: Taylan Ulrich Bayırlı/Kammer @ 2015-01-31 23:58 UTC (permalink / raw
To: guix-devel
[-- Attachment #1: Type: text/plain, Size: 74 bytes --]
Please use this updated patch; it adds zlib and gnutls and enables IPv6:
[-- Attachment #2: gnu: Add ngircd. --]
[-- Type: text/x-diff, Size: 3715 bytes --]
From 444dc72eff46ceb343fcdfdfc368390417201002 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
<taylanbayirli@gmail.com>
Date: Sat, 31 Jan 2015 22:03:25 +0100
Subject: [PATCH] gnu: Add ngircd.
* gnu-system.am (GNU_SYSTEM_MODULES): Add ngircd.scm.
* gnu/packages/ngircd.scm: New file.
---
gnu-system.am | 1 +
gnu/packages/ngircd.scm | 61 +++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 62 insertions(+)
create mode 100644 gnu/packages/ngircd.scm
diff --git a/gnu-system.am b/gnu-system.am
index 706ad57..488e7a5 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -197,6 +197,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/ncurses.scm \
gnu/packages/netpbm.scm \
gnu/packages/nettle.scm \
+ gnu/packages/ngircd.scm \
gnu/packages/ninja.scm \
gnu/packages/node.scm \
gnu/packages/noweb.scm \
diff --git a/gnu/packages/ngircd.scm b/gnu/packages/ngircd.scm
new file mode 100644
index 0000000..4636df5
--- /dev/null
+++ b/gnu/packages/ngircd.scm
@@ -0,0 +1,61 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix 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 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages ngircd)
+ #:use-module ((guix licenses) #:prefix l:)
+ #:use-module (guix packages)
+ #:use-module (guix download)
+ #:use-module (guix build-system gnu)
+ #:use-module (gnu packages gnutls)
+ #:use-module (gnu packages compression))
+
+(define-public ngircd
+ (package
+ (name "ngircd")
+ (version "22")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))))
+ (build-system gnu-build-system)
+ ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
+ (inputs `(("zlib" ,zlib)
+ ("gnutls" ,gnutls)))
+ (arguments
+ `(#:configure-flags
+ `("--with-gnutls" "--enable-ipv6")
+ #:phases
+ ;; Necessary for the test suite, should it be enabled in the future.
+ (alist-cons-after
+ 'configure 'post-configure
+ (lambda _
+ (substitute* "src/ngircd/Makefile"
+ (("#!/bin/sh") (which "sh"))))
+ %standard-phases)
+ ;; Test-suite inflates our dependencies with e.g. expect(1).
+ #:tests? #f))
+ (home-page "http://ngircd.barton.de/")
+ (synopsis "Lightweight Internet Relay Chat server for small networks")
+ (description
+ "ngIRCd is a lightweight Internet Relay Chat server for small or private
+networks. It is easy to configure, can cope with dynamic IP addresses, and
+supports IPv6, SSL-protected connections as well as PAM for authentication.")
+ (license l:gpl2+)))
--
2.2.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-01-31 23:58 ` Taylan Ulrich Bayırlı/Kammer
@ 2015-02-01 6:58 ` Mark H Weaver
2015-02-01 23:23 ` Taylan Ulrich Bayırlı/Kammer
2015-02-05 11:53 ` Taylan Ulrich Bayırlı/Kammer
0 siblings, 2 replies; 8+ messages in thread
From: Mark H Weaver @ 2015-02-01 6:58 UTC (permalink / raw
To: Taylan Ulrich "Bayırlı/Kammer"; +Cc: guix-devel
taylanbayirli@gmail.com (Taylan Ulrich "Bayırlı/Kammer") writes:
> From 444dc72eff46ceb343fcdfdfc368390417201002 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
> <taylanbayirli@gmail.com>
> Date: Sat, 31 Jan 2015 22:03:25 +0100
> Subject: [PATCH] gnu: Add ngircd.
>
> * gnu-system.am (GNU_SYSTEM_MODULES): Add ngircd.scm.
> * gnu/packages/ngircd.scm: New file.
> ---
> gnu-system.am | 1 +
> gnu/packages/ngircd.scm | 61 +++++++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 62 insertions(+)
> create mode 100644 gnu/packages/ngircd.scm
How about adding this package to messaging.scm instead?
> diff --git a/gnu/packages/ngircd.scm b/gnu/packages/ngircd.scm
> new file mode 100644
> index 0000000..4636df5
> --- /dev/null
> +++ b/gnu/packages/ngircd.scm
> @@ -0,0 +1,61 @@
> +;;; GNU Guix --- Functional package management for GNU
> +;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
It's 2015 :)
> +;;;
> +;;; This file is part of GNU Guix.
> +;;;
> +;;; GNU Guix 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 3 of the License, or (at
> +;;; your option) any later version.
> +;;;
> +;;; GNU Guix is distributed in the hope that it will be useful, but
> +;;; WITHOUT ANY WARRANTY; without even the implied warranty of
> +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> +;;; GNU General Public License for more details.
> +;;;
> +;;; You should have received a copy of the GNU General Public License
> +;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
> +
> +(define-module (gnu packages ngircd)
> + #:use-module ((guix licenses) #:prefix l:)
> + #:use-module (guix packages)
> + #:use-module (guix download)
> + #:use-module (guix build-system gnu)
> + #:use-module (gnu packages gnutls)
> + #:use-module (gnu packages compression))
> +
> +(define-public ngircd
> + (package
> + (name "ngircd")
> + (version "22")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
> + version ".tar.xz"))
> + (sha256
> + (base32
> + "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))))
> + (build-system gnu-build-system)
> + ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
> + (inputs `(("zlib" ,zlib)
> + ("gnutls" ,gnutls)))
> + (arguments
> + `(#:configure-flags
> + `("--with-gnutls" "--enable-ipv6")
> + #:phases
> + ;; Necessary for the test suite, should it be enabled in the future.
> + (alist-cons-after
> + 'configure 'post-configure
> + (lambda _
> + (substitute* "src/ngircd/Makefile"
> + (("#!/bin/sh") (which "sh"))))
This substitution will remove the "#!", which we want to keep.
> + %standard-phases)
> + ;; Test-suite inflates our dependencies with e.g. expect(1).
> + #:tests? #f))
I think it would be good to enable the test suite if possible. Adding
'expect' as an input is not a problem. Can you try it and see if you
run into other serious difficulties?
> + (home-page "http://ngircd.barton.de/")
> + (synopsis "Lightweight Internet Relay Chat server for small networks")
> + (description
> + "ngIRCd is a lightweight Internet Relay Chat server for small or private
> +networks. It is easy to configure, can cope with dynamic IP addresses, and
> +supports IPv6, SSL-protected connections as well as PAM for authentication.")
> + (license l:gpl2+)))
Otherwise looks good to me. Can you send an updated patch?
Thanks!
Mark
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-02-01 6:58 ` Mark H Weaver
@ 2015-02-01 23:23 ` Taylan Ulrich Bayırlı/Kammer
2015-02-05 12:46 ` Ludovic Courtès
2015-02-05 11:53 ` Taylan Ulrich Bayırlı/Kammer
1 sibling, 1 reply; 8+ messages in thread
From: Taylan Ulrich Bayırlı/Kammer @ 2015-02-01 23:23 UTC (permalink / raw
To: Mark H Weaver; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 364 bytes --]
Here's the new patch.
For those who weren't on IRC: the test suite of this package has an
interesting problem. Our build process doesn't reap zombie processes,
which makes them continue responding to 'kill -0' (which tests whether a
process exists), so the test suite thinks it can't kill a certain
process. The test suite has therefore been disabled for now.
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 15500 bytes --]
From 34b2efd8244caf0cd16c1aa510209a54def148b7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
<taylanbayirli@gmail.com>
Date: Sat, 31 Jan 2015 22:03:25 +0100
Subject: [PATCH] gnu: Add ngircd.
* gnu/packages/messaging.scm (ngircd): New variable.
* gnu/packages/patches/ngircd-no-dns-in-tests.patch: New file.
* gnu-system.am (dist_patch_DATA): Add it.
---
gnu-system.am | 2 +
gnu/packages/messaging.scm | 48 ++-
gnu/packages/patches/ngircd-no-dns-in-tests.patch | 368 ++++++++++++++++++++++
3 files changed, 417 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/ngircd-no-dns-in-tests.patch
diff --git a/gnu-system.am b/gnu-system.am
index 706ad57..afa9580 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -197,6 +197,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/ncurses.scm \
gnu/packages/netpbm.scm \
gnu/packages/nettle.scm \
+ gnu/packages/ngircd.scm \
gnu/packages/ninja.scm \
gnu/packages/node.scm \
gnu/packages/noweb.scm \
@@ -433,6 +434,7 @@ dist_patch_DATA = \
gnu/packages/patches/mupdf-buildsystem-fix.patch \
gnu/packages/patches/mutt-CVE-2014-9116.patch \
gnu/packages/patches/net-tools-bitrot.patch \
+ gnu/packages/patches/ngircd-no-dns-in-tests.patch \
gnu/packages/patches/ninja-tests.patch \
gnu/packages/patches/nss-pkgconfig.patch \
gnu/packages/patches/nvi-assume-preserve-path.patch \
diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm
index f6d0cf5..1693178 100644
--- a/gnu/packages/messaging.scm
+++ b/gnu/packages/messaging.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2014 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -36,8 +37,11 @@
#:use-module (gnu packages gnutls)
#:use-module (gnu packages python)
#:use-module (gnu packages perl)
+ #:use-module (gnu packages tcl)
#:use-module (gnu packages compression)
- #:use-module (gnu packages check))
+ #:use-module (gnu packages check)
+ #:use-module (gnu packages admin)
+ #:use-module (gnu packages linux))
(define-public libotr
(package
@@ -159,4 +163,46 @@ dictionaries. HexChat can be extended with multiple addons.")
(home-page "http://hexchat.net/")
(license gpl2+)))
+(define-public ngircd
+ (package
+ (name "ngircd")
+ (version "22")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))
+ (patches (list (search-patch "ngircd-no-dns-in-tests.patch")))))
+ (build-system gnu-build-system)
+ ;; Needed for the test suite.
+ (native-inputs `(("procps" ,procps)
+ ("expect" ,expect)
+ ("inetutils" ,inetutils)))
+ ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
+ (inputs `(("zlib" ,zlib)
+ ("gnutls" ,gnutls)))
+ (arguments
+ `(#:configure-flags
+ `("--with-gnutls" "--enable-ipv6")
+ #:phases
+ ;; Necessary for the test suite, should it be enabled in the future.
+ (alist-cons-after
+ 'configure 'post-configure
+ (lambda _
+ (substitute* "src/ngircd/Makefile"
+ (("/bin/sh") (which "sh"))))
+ %standard-phases)
+ ;; 'stop-server' tests fail because our build process leaves zombie
+ ;; processes which continue to respond to 'kill -0'.
+ #:tests? #f))
+ (home-page "http://ngircd.barton.de/")
+ (synopsis "Lightweight Internet Relay Chat server for small networks")
+ (description
+ "ngIRCd is a lightweight Internet Relay Chat server for small or private
+networks. It is easy to configure, can cope with dynamic IP addresses, and
+supports IPv6, SSL-protected connections as well as PAM for authentication.")
+ (license gpl2+)))
+
;;; messaging.scm ends here
diff --git a/gnu/packages/patches/ngircd-no-dns-in-tests.patch b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
new file mode 100644
index 0000000..748661d
--- /dev/null
+++ b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
@@ -0,0 +1,368 @@
+From 3f807e104572b38143a1015be57d875088ceaebb Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Thu, 17 Apr 2014 23:57:38 +0200
+Subject: [PATCH] Test suite: Don't use DNS lookups
+
+Different operating systems do behave quite differently when doing DNS
+lookups, for example "127.0.0.1" sometimes resolves to "localhost" and
+sometimes to "localhost.localdomain" (for example OpenBSD). And other
+systems resolve "localhost" to the real host name (for example Cygwin).
+
+So not using DNS at all makes the test site much more portable.
+---
+ src/testsuite/channel-test.e | 2 +-
+ src/testsuite/check-idle.e | 2 +-
+ src/testsuite/connect-test.e | 2 +-
+ src/testsuite/invite-test.e | 2 +-
+ src/testsuite/join-test.e | 2 +-
+ src/testsuite/kick-test.e | 2 +-
+ src/testsuite/message-test.e | 31 ++++++++++++-------------------
+ src/testsuite/misc-test.e | 8 ++++----
+ src/testsuite/mode-test.e | 2 +-
+ src/testsuite/ngircd-test1.conf | 1 +
+ src/testsuite/ngircd-test2.conf | 1 +
+ src/testsuite/opless-channel-test.e | 2 +-
+ src/testsuite/server-link-test.e | 2 +-
+ src/testsuite/stress-A.e | 2 +-
+ src/testsuite/who-test.e | 6 +++---
+ src/testsuite/whois-test.e | 14 +++++++-------
+ 16 files changed, 38 insertions(+), 43 deletions(-)
+
+diff --git a/src/testsuite/channel-test.e b/src/testsuite/channel-test.e
+index dd7eb66..39ad16a 100644
+--- a/src/testsuite/channel-test.e
++++ b/src/testsuite/channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/check-idle.e b/src/testsuite/check-idle.e
+index 41b8eb4..ad112b2 100644
+--- a/src/testsuite/check-idle.e
++++ b/src/testsuite/check-idle.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Idle test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/connect-test.e b/src/testsuite/connect-test.e
+index 662f5f7..b51be0d 100644
+--- a/src/testsuite/connect-test.e
++++ b/src/testsuite/connect-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Server connect test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/invite-test.e b/src/testsuite/invite-test.e
+index 3716d19..5179d8a 100644
+--- a/src/testsuite/invite-test.e
++++ b/src/testsuite/invite-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # INVITE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/join-test.e b/src/testsuite/join-test.e
+index 28b4c54..c088f5c 100644
+--- a/src/testsuite/join-test.e
++++ b/src/testsuite/join-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # JOIN test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/kick-test.e b/src/testsuite/kick-test.e
+index 3d3c1ee..89da611 100644
+--- a/src/testsuite/kick-test.e
++++ b/src/testsuite/kick-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # KICK test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/message-test.e b/src/testsuite/message-test.e
+index 0e70640..5dc325d 100644
+--- a/src/testsuite/message-test.e
++++ b/src/testsuite/message-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # PRIVMSG and NOTICE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -72,24 +72,17 @@ expect {
+ "MODE nick :-b"
+ }
+
+-# The following two tests using "localhost" as host name
+-# had to be disabled, because there are operating systems
+-# out there, that use "localhost.<domain>" as host name
+-# for 127.0.0.1 instead of just "localhost".
+-# (for example OpenBSD 4, OpenSolaris, ...)
+-#
+-#send "privmsg ~user\%localhost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-#}
+-#
+-#send "privmsg Nick!~User@LocalHost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-# "401"
+-#}
++send "privmsg ~user\%127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
++
++send "privmsg Nick!~User@127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
+
+ send "away :away\r"
+ expect {
+diff --git a/src/testsuite/misc-test.e b/src/testsuite/misc-test.e
+index a83bc5b..f69e7c3 100644
+--- a/src/testsuite/misc-test.e
++++ b/src/testsuite/misc-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Misc test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -130,7 +130,7 @@ expect {
+ send "userhost nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :?nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :?nick=+.*@127.0.0.1"
+ }
+
+ send "userhost doesnotexist\r"
+@@ -142,7 +142,7 @@ expect {
+ send "userhost nick doesnotexist nick doesnotexist\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=+.*@(localhos.*|127.0.0.1) nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :nick=+.*@127.0.0.1 nick=+.*@127.0.0.1"
+ }
+
+ send "away :testing\r"
+@@ -154,7 +154,7 @@ expect {
+ send "userhost nick nick nick nick nick nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1)\r"
++ -re ":ngircd.test.server 302 nick :nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1\r"
+ }
+
+ send "quit\r"
+diff --git a/src/testsuite/mode-test.e b/src/testsuite/mode-test.e
+index d6726a4..86e4f2d 100644
+--- a/src/testsuite/mode-test.e
++++ b/src/testsuite/mode-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # MODE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/ngircd-test1.conf b/src/testsuite/ngircd-test1.conf
+index 0d0cccc..4dec533 100644
+--- a/src/testsuite/ngircd-test1.conf
++++ b/src/testsuite/ngircd-test1.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/ngircd-test2.conf b/src/testsuite/ngircd-test2.conf
+index c9d7f6c..0d24c4a 100644
+--- a/src/testsuite/ngircd-test2.conf
++++ b/src/testsuite/ngircd-test2.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/opless-channel-test.e b/src/testsuite/opless-channel-test.e
+index 7d94172..4611fe1 100644
+--- a/src/testsuite/opless-channel-test.e
++++ b/src/testsuite/opless-channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Op-less channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/server-link-test.e b/src/testsuite/server-link-test.e
+index cf3fae8..910f8c8 100644
+--- a/src/testsuite/server-link-test.e
++++ b/src/testsuite/server-link-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # server-server link test
+
+-spawn telnet localhost 6790
++spawn telnet 127.0.0.1 6790
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/stress-A.e b/src/testsuite/stress-A.e
+index 256d5d1..d51adaa 100644
+--- a/src/testsuite/stress-A.e
++++ b/src/testsuite/stress-A.e
+@@ -3,7 +3,7 @@
+
+ set timeout 30
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/who-test.e b/src/testsuite/who-test.e
+index a41e6b6..39d50ed 100644
+--- a/src/testsuite/who-test.e
++++ b/src/testsuite/who-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHO test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -62,7 +62,7 @@ expect {
+ ":ngircd.test.server 352 nick #channel * * ngircd.test.server nick G@ :0 Real Name"
+ }
+
+-send "who localhos*\r"
++send "who 127.0.0.*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick G :0 Real Name"
+@@ -120,7 +120,7 @@ expect {
+ "305 nick"
+ }
+
+-send "who ??cal*ho*\r"
++send "who ??7.*0*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick H* :0 Real Name"
+diff --git a/src/testsuite/whois-test.e b/src/testsuite/whois-test.e
+index 16b1184..44eee66 100644
+--- a/src/testsuite/whois-test.e
++++ b/src/testsuite/whois-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHOIS test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -17,7 +17,7 @@ expect {
+ send "whois nick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1 \* :Real Name\r"
+ }
+ expect {
+ timeout { exit 1 }
+@@ -27,25 +27,25 @@ expect {
+ send "whois *\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois n*\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ?ick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ????,n?*k\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois unknown\r"
+@@ -61,7 +61,7 @@ expect {
+ send "whois ngircd.test.server2 nick\r"
+ expect {
+ timeout { exit 1 }
+- ":ngircd.test.server2 311 nick nick ~user localhost* \* :Real Name\r"
++ ":ngircd.test.server2 311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois nosuchserver unknown\r"
+--
+1.9.1
+
--
2.2.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-02-01 6:58 ` Mark H Weaver
2015-02-01 23:23 ` Taylan Ulrich Bayırlı/Kammer
@ 2015-02-05 11:53 ` Taylan Ulrich Bayırlı/Kammer
1 sibling, 0 replies; 8+ messages in thread
From: Taylan Ulrich Bayırlı/Kammer @ 2015-02-05 11:53 UTC (permalink / raw
To: Mark H Weaver; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 354 bytes --]
I had time to tinker around and, with willingness from the ngIRCd
developers to patch their test suite, came up with a relatively simple
solution.
The relevant patch to the test suite is not necessarily as portable as
ngIRCd requires it to be (or maybe it is) so this might not be the patch
that will make it upstream, but on the meanwhile here it is.
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 16838 bytes --]
From fa3385f7f36ab9b7c17d7b80455d96669af24a50 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
<taylanbayirli@gmail.com>
Date: Sat, 31 Jan 2015 22:03:25 +0100
Subject: [PATCH] gnu: Add ngircd.
* gnu/packages/messaging.scm (ngircd): New variable.
* gnu/packages/patches/ngircd-no-dns-in-tests.patch: New file.
* gnu/packages/patches/ngircd-handle-zombies.patch: New file.
* gnu-system.am (dist_patch_DATA): Add them.
---
gnu-system.am | 3 +
gnu/packages/messaging.scm | 46 ++-
gnu/packages/patches/ngircd-handle-zombies.patch | 36 +++
gnu/packages/patches/ngircd-no-dns-in-tests.patch | 368 ++++++++++++++++++++++
4 files changed, 452 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/ngircd-handle-zombies.patch
create mode 100644 gnu/packages/patches/ngircd-no-dns-in-tests.patch
diff --git a/gnu-system.am b/gnu-system.am
index 706ad57..3daec97 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -197,6 +197,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/ncurses.scm \
gnu/packages/netpbm.scm \
gnu/packages/nettle.scm \
+ gnu/packages/ngircd.scm \
gnu/packages/ninja.scm \
gnu/packages/node.scm \
gnu/packages/noweb.scm \
@@ -433,6 +434,8 @@ dist_patch_DATA = \
gnu/packages/patches/mupdf-buildsystem-fix.patch \
gnu/packages/patches/mutt-CVE-2014-9116.patch \
gnu/packages/patches/net-tools-bitrot.patch \
+ gnu/packages/patches/ngircd-handle-zombies.patch \
+ gnu/packages/patches/ngircd-no-dns-in-tests.patch \
gnu/packages/patches/ninja-tests.patch \
gnu/packages/patches/nss-pkgconfig.patch \
gnu/packages/patches/nvi-assume-preserve-path.patch \
diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm
index f6d0cf5..82fdbe6 100644
--- a/gnu/packages/messaging.scm
+++ b/gnu/packages/messaging.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2014 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -36,8 +37,11 @@
#:use-module (gnu packages gnutls)
#:use-module (gnu packages python)
#:use-module (gnu packages perl)
+ #:use-module (gnu packages tcl)
#:use-module (gnu packages compression)
- #:use-module (gnu packages check))
+ #:use-module (gnu packages check)
+ #:use-module (gnu packages admin)
+ #:use-module (gnu packages linux))
(define-public libotr
(package
@@ -159,4 +163,44 @@ dictionaries. HexChat can be extended with multiple addons.")
(home-page "http://hexchat.net/")
(license gpl2+)))
+(define-public ngircd
+ (package
+ (name "ngircd")
+ (version "22")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))
+ (patches (list (search-patch "ngircd-no-dns-in-tests.patch")
+ (search-patch "ngircd-handle-zombies.patch")))))
+ (build-system gnu-build-system)
+ ;; Needed for the test suite.
+ (native-inputs `(("procps" ,procps)
+ ("expect" ,expect)
+ ("inetutils" ,inetutils)))
+ ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
+ (inputs `(("zlib" ,zlib)
+ ("gnutls" ,gnutls)))
+ (arguments
+ `(#:configure-flags
+ `("--with-gnutls" "--enable-ipv6")
+ #:phases
+ ;; Necessary for the test suite, should it be enabled in the future.
+ (alist-cons-after
+ 'configure 'post-configure
+ (lambda _
+ (substitute* "src/ngircd/Makefile"
+ (("/bin/sh") (which "sh"))))
+ %standard-phases)))
+ (home-page "http://ngircd.barton.de/")
+ (synopsis "Lightweight Internet Relay Chat server for small networks")
+ (description
+ "ngIRCd is a lightweight Internet Relay Chat server for small or private
+networks. It is easy to configure, can cope with dynamic IP addresses, and
+supports IPv6, SSL-protected connections as well as PAM for authentication.")
+ (license gpl2+)))
+
;;; messaging.scm ends here
diff --git a/gnu/packages/patches/ngircd-handle-zombies.patch b/gnu/packages/patches/ngircd-handle-zombies.patch
new file mode 100644
index 0000000..99475ba
--- /dev/null
+++ b/gnu/packages/patches/ngircd-handle-zombies.patch
@@ -0,0 +1,36 @@
+The Guile process taking the role of PID 1 during Guix builds does not reap
+zombie processes, which makes them continue responding to "kill -0".
+
+--- a/src/testsuite/stop-server.sh 2015-02-05 11:24:00.535908842 +0100
++++ b/src/testsuite/stop-server.sh 2015-02-05 11:25:00.264351349 +0100
+@@ -1,6 +1,21 @@
+ #!/bin/sh
+ # ngIRCd Test Suite
+
++process_is_alive(){
++ ! process_is_dead "$1" && ! process_is_undead "$1"
++}
++
++process_is_dead(){
++ ! kill -0 "$1"
++}
++
++process_is_undead(){
++ case $(ps -p "$1" -o state=) in
++ (Z*) true ;;
++ (*) false ;;
++ esac
++}
++
+ [ -z "$srcdir" ] && srcdir=`dirname $0`
+
+ # read in functions
+@@ -24,7 +40,7 @@
+
+ # waiting ...
+ for i in 1 2 3 4 5; do
+- kill -0 $pid > /dev/null 2>&1; r=$?
++ process_is_alive $pid > /dev/null 2>&1; r=$?
+ if [ $r -ne 0 ]; then
+ echo " ok".
+ exit 0
diff --git a/gnu/packages/patches/ngircd-no-dns-in-tests.patch b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
new file mode 100644
index 0000000..748661d
--- /dev/null
+++ b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
@@ -0,0 +1,368 @@
+From 3f807e104572b38143a1015be57d875088ceaebb Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Thu, 17 Apr 2014 23:57:38 +0200
+Subject: [PATCH] Test suite: Don't use DNS lookups
+
+Different operating systems do behave quite differently when doing DNS
+lookups, for example "127.0.0.1" sometimes resolves to "localhost" and
+sometimes to "localhost.localdomain" (for example OpenBSD). And other
+systems resolve "localhost" to the real host name (for example Cygwin).
+
+So not using DNS at all makes the test site much more portable.
+---
+ src/testsuite/channel-test.e | 2 +-
+ src/testsuite/check-idle.e | 2 +-
+ src/testsuite/connect-test.e | 2 +-
+ src/testsuite/invite-test.e | 2 +-
+ src/testsuite/join-test.e | 2 +-
+ src/testsuite/kick-test.e | 2 +-
+ src/testsuite/message-test.e | 31 ++++++++++++-------------------
+ src/testsuite/misc-test.e | 8 ++++----
+ src/testsuite/mode-test.e | 2 +-
+ src/testsuite/ngircd-test1.conf | 1 +
+ src/testsuite/ngircd-test2.conf | 1 +
+ src/testsuite/opless-channel-test.e | 2 +-
+ src/testsuite/server-link-test.e | 2 +-
+ src/testsuite/stress-A.e | 2 +-
+ src/testsuite/who-test.e | 6 +++---
+ src/testsuite/whois-test.e | 14 +++++++-------
+ 16 files changed, 38 insertions(+), 43 deletions(-)
+
+diff --git a/src/testsuite/channel-test.e b/src/testsuite/channel-test.e
+index dd7eb66..39ad16a 100644
+--- a/src/testsuite/channel-test.e
++++ b/src/testsuite/channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/check-idle.e b/src/testsuite/check-idle.e
+index 41b8eb4..ad112b2 100644
+--- a/src/testsuite/check-idle.e
++++ b/src/testsuite/check-idle.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Idle test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/connect-test.e b/src/testsuite/connect-test.e
+index 662f5f7..b51be0d 100644
+--- a/src/testsuite/connect-test.e
++++ b/src/testsuite/connect-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Server connect test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/invite-test.e b/src/testsuite/invite-test.e
+index 3716d19..5179d8a 100644
+--- a/src/testsuite/invite-test.e
++++ b/src/testsuite/invite-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # INVITE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/join-test.e b/src/testsuite/join-test.e
+index 28b4c54..c088f5c 100644
+--- a/src/testsuite/join-test.e
++++ b/src/testsuite/join-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # JOIN test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/kick-test.e b/src/testsuite/kick-test.e
+index 3d3c1ee..89da611 100644
+--- a/src/testsuite/kick-test.e
++++ b/src/testsuite/kick-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # KICK test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/message-test.e b/src/testsuite/message-test.e
+index 0e70640..5dc325d 100644
+--- a/src/testsuite/message-test.e
++++ b/src/testsuite/message-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # PRIVMSG and NOTICE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -72,24 +72,17 @@ expect {
+ "MODE nick :-b"
+ }
+
+-# The following two tests using "localhost" as host name
+-# had to be disabled, because there are operating systems
+-# out there, that use "localhost.<domain>" as host name
+-# for 127.0.0.1 instead of just "localhost".
+-# (for example OpenBSD 4, OpenSolaris, ...)
+-#
+-#send "privmsg ~user\%localhost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-#}
+-#
+-#send "privmsg Nick!~User@LocalHost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-# "401"
+-#}
++send "privmsg ~user\%127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
++
++send "privmsg Nick!~User@127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
+
+ send "away :away\r"
+ expect {
+diff --git a/src/testsuite/misc-test.e b/src/testsuite/misc-test.e
+index a83bc5b..f69e7c3 100644
+--- a/src/testsuite/misc-test.e
++++ b/src/testsuite/misc-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Misc test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -130,7 +130,7 @@ expect {
+ send "userhost nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :?nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :?nick=+.*@127.0.0.1"
+ }
+
+ send "userhost doesnotexist\r"
+@@ -142,7 +142,7 @@ expect {
+ send "userhost nick doesnotexist nick doesnotexist\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=+.*@(localhos.*|127.0.0.1) nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :nick=+.*@127.0.0.1 nick=+.*@127.0.0.1"
+ }
+
+ send "away :testing\r"
+@@ -154,7 +154,7 @@ expect {
+ send "userhost nick nick nick nick nick nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1)\r"
++ -re ":ngircd.test.server 302 nick :nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1\r"
+ }
+
+ send "quit\r"
+diff --git a/src/testsuite/mode-test.e b/src/testsuite/mode-test.e
+index d6726a4..86e4f2d 100644
+--- a/src/testsuite/mode-test.e
++++ b/src/testsuite/mode-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # MODE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/ngircd-test1.conf b/src/testsuite/ngircd-test1.conf
+index 0d0cccc..4dec533 100644
+--- a/src/testsuite/ngircd-test1.conf
++++ b/src/testsuite/ngircd-test1.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/ngircd-test2.conf b/src/testsuite/ngircd-test2.conf
+index c9d7f6c..0d24c4a 100644
+--- a/src/testsuite/ngircd-test2.conf
++++ b/src/testsuite/ngircd-test2.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/opless-channel-test.e b/src/testsuite/opless-channel-test.e
+index 7d94172..4611fe1 100644
+--- a/src/testsuite/opless-channel-test.e
++++ b/src/testsuite/opless-channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Op-less channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/server-link-test.e b/src/testsuite/server-link-test.e
+index cf3fae8..910f8c8 100644
+--- a/src/testsuite/server-link-test.e
++++ b/src/testsuite/server-link-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # server-server link test
+
+-spawn telnet localhost 6790
++spawn telnet 127.0.0.1 6790
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/stress-A.e b/src/testsuite/stress-A.e
+index 256d5d1..d51adaa 100644
+--- a/src/testsuite/stress-A.e
++++ b/src/testsuite/stress-A.e
+@@ -3,7 +3,7 @@
+
+ set timeout 30
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/who-test.e b/src/testsuite/who-test.e
+index a41e6b6..39d50ed 100644
+--- a/src/testsuite/who-test.e
++++ b/src/testsuite/who-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHO test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -62,7 +62,7 @@ expect {
+ ":ngircd.test.server 352 nick #channel * * ngircd.test.server nick G@ :0 Real Name"
+ }
+
+-send "who localhos*\r"
++send "who 127.0.0.*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick G :0 Real Name"
+@@ -120,7 +120,7 @@ expect {
+ "305 nick"
+ }
+
+-send "who ??cal*ho*\r"
++send "who ??7.*0*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick H* :0 Real Name"
+diff --git a/src/testsuite/whois-test.e b/src/testsuite/whois-test.e
+index 16b1184..44eee66 100644
+--- a/src/testsuite/whois-test.e
++++ b/src/testsuite/whois-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHOIS test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -17,7 +17,7 @@ expect {
+ send "whois nick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1 \* :Real Name\r"
+ }
+ expect {
+ timeout { exit 1 }
+@@ -27,25 +27,25 @@ expect {
+ send "whois *\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois n*\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ?ick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ????,n?*k\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois unknown\r"
+@@ -61,7 +61,7 @@ expect {
+ send "whois ngircd.test.server2 nick\r"
+ expect {
+ timeout { exit 1 }
+- ":ngircd.test.server2 311 nick nick ~user localhost* \* :Real Name\r"
++ ":ngircd.test.server2 311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois nosuchserver unknown\r"
+--
+1.9.1
+
--
2.2.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-02-01 23:23 ` Taylan Ulrich Bayırlı/Kammer
@ 2015-02-05 12:46 ` Ludovic Courtès
2015-02-05 14:32 ` Taylan Ulrich Bayırlı/Kammer
0 siblings, 1 reply; 8+ messages in thread
From: Ludovic Courtès @ 2015-02-05 12:46 UTC (permalink / raw
To: Taylan Ulrich "Bayırlı/Kammer"; +Cc: guix-devel
taylanbayirli@gmail.com (Taylan Ulrich "Bayırlı/Kammer") skribis:
> From 34b2efd8244caf0cd16c1aa510209a54def148b7 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
> <taylanbayirli@gmail.com>
> Date: Sat, 31 Jan 2015 22:03:25 +0100
> Subject: [PATCH] gnu: Add ngircd.
>
> * gnu/packages/messaging.scm (ngircd): New variable.
> * gnu/packages/patches/ngircd-no-dns-in-tests.patch: New file.
> * gnu-system.am (dist_patch_DATA): Add it.
Perhaps Mark should have the last say, but at least this looks good to me.
> + ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
iconv is part of glibc, so you can remove it from here.
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-02-05 12:46 ` Ludovic Courtès
@ 2015-02-05 14:32 ` Taylan Ulrich Bayırlı/Kammer
2015-02-05 15:46 ` Mark H Weaver
0 siblings, 1 reply; 8+ messages in thread
From: Taylan Ulrich Bayırlı/Kammer @ 2015-02-05 14:32 UTC (permalink / raw
To: Ludovic Courtès; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 1151 bytes --]
ludo@gnu.org (Ludovic Courtès) writes:
> taylanbayirli@gmail.com (Taylan Ulrich "Bayırlı/Kammer") skribis:
>
>> From 34b2efd8244caf0cd16c1aa510209a54def148b7 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
>> <taylanbayirli@gmail.com>
>> Date: Sat, 31 Jan 2015 22:03:25 +0100
>> Subject: [PATCH] gnu: Add ngircd.
>>
>> * gnu/packages/messaging.scm (ngircd): New variable.
>> * gnu/packages/patches/ngircd-no-dns-in-tests.patch: New file.
>> * gnu-system.am (dist_patch_DATA): Add it.
>
> Perhaps Mark should have the last say, but at least this looks good to me.
>
>> + ;; XXX Add more inputs to enable more features, e.g. IDENT, libiconv.
>
> iconv is part of glibc, so you can remove it from here.
>
> Thanks,
> Ludo’.
I see; I just had to explicitly add --with-iconv.
I also added PAM now. There's an ugly form with two layers of
quasiquote and unquote though; tell me if there's a better way to do it.
(And this is based on the version of this patch with the test-suite
patch for zombie processes. Tell me if I should base it on the one
without that patch.)
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 17288 bytes --]
From 00385310b307cc76fb0e4125a7013dbeb558691e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
<taylanbayirli@gmail.com>
Date: Sat, 31 Jan 2015 22:03:25 +0100
Subject: [PATCH] gnu: Add ngircd.
* gnu/packages/messaging.scm (ngircd): New variable.
* gnu/packages/patches/ngircd-no-dns-in-tests.patch: New file.
* gnu/packages/patches/ngircd-handle-zombies.patch: New file.
* gnu-system.am (dist_patch_DATA): Add them.
---
gnu-system.am | 3 +
gnu/packages/messaging.scm | 56 +++-
gnu/packages/patches/ngircd-handle-zombies.patch | 36 +++
gnu/packages/patches/ngircd-no-dns-in-tests.patch | 368 ++++++++++++++++++++++
4 files changed, 462 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/ngircd-handle-zombies.patch
create mode 100644 gnu/packages/patches/ngircd-no-dns-in-tests.patch
diff --git a/gnu-system.am b/gnu-system.am
index 706ad57..3daec97 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -197,6 +197,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/ncurses.scm \
gnu/packages/netpbm.scm \
gnu/packages/nettle.scm \
+ gnu/packages/ngircd.scm \
gnu/packages/ninja.scm \
gnu/packages/node.scm \
gnu/packages/noweb.scm \
@@ -433,6 +434,8 @@ dist_patch_DATA = \
gnu/packages/patches/mupdf-buildsystem-fix.patch \
gnu/packages/patches/mutt-CVE-2014-9116.patch \
gnu/packages/patches/net-tools-bitrot.patch \
+ gnu/packages/patches/ngircd-handle-zombies.patch \
+ gnu/packages/patches/ngircd-no-dns-in-tests.patch \
gnu/packages/patches/ninja-tests.patch \
gnu/packages/patches/nss-pkgconfig.patch \
gnu/packages/patches/nvi-assume-preserve-path.patch \
diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm
index f6d0cf5..520746c 100644
--- a/gnu/packages/messaging.scm
+++ b/gnu/packages/messaging.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2014 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -36,8 +37,11 @@
#:use-module (gnu packages gnutls)
#:use-module (gnu packages python)
#:use-module (gnu packages perl)
+ #:use-module (gnu packages tcl)
#:use-module (gnu packages compression)
- #:use-module (gnu packages check))
+ #:use-module (gnu packages check)
+ #:use-module (gnu packages admin)
+ #:use-module (gnu packages linux))
(define-public libotr
(package
@@ -159,4 +163,54 @@ dictionaries. HexChat can be extended with multiple addons.")
(home-page "http://hexchat.net/")
(license gpl2+)))
+(define-public ngircd
+ (package
+ (name "ngircd")
+ (version "22")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://arthur.barton.de/pub/ngircd/ngircd-"
+ version ".tar.xz"))
+ (sha256
+ (base32
+ "17k3g9qd9d010czk5846qxvzkmw4fihv8l6m2a2287crbxm3xhd4"))
+ (patches (list (search-patch "ngircd-no-dns-in-tests.patch")
+ (search-patch "ngircd-handle-zombies.patch")))))
+ (build-system gnu-build-system)
+ ;; Needed for the test suite.
+ (native-inputs `(("procps" ,procps)
+ ("expect" ,expect)
+ ("inetutils" ,inetutils)))
+ ;; XXX Add libident, libwrap.
+ (inputs `(("zlib" ,zlib)
+ ("gnutls" ,gnutls)
+ ,@(if (string-suffix? "-linux"
+ (or (%current-target-system)
+ (%current-system)))
+ `(("linux-pam" ,linux-pam))
+ '())))
+ (arguments
+ `(#:configure-flags
+ `("--with-gnutls" "--with-iconv" "--enable-ipv6"
+ ,,@(if (string-suffix? "-linux"
+ (or (%current-target-system)
+ (%current-system)))
+ '("--with-pam")
+ '()))
+ #:phases
+ ;; Necessary for the test suite, should it be enabled in the future.
+ (alist-cons-after
+ 'configure 'post-configure
+ (lambda _
+ (substitute* "src/ngircd/Makefile"
+ (("/bin/sh") (which "sh"))))
+ %standard-phases)))
+ (home-page "http://ngircd.barton.de/")
+ (synopsis "Lightweight Internet Relay Chat server for small networks")
+ (description
+ "ngIRCd is a lightweight Internet Relay Chat server for small or private
+networks. It is easy to configure, can cope with dynamic IP addresses, and
+supports IPv6, SSL-protected connections as well as PAM for authentication.")
+ (license gpl2+)))
+
;;; messaging.scm ends here
diff --git a/gnu/packages/patches/ngircd-handle-zombies.patch b/gnu/packages/patches/ngircd-handle-zombies.patch
new file mode 100644
index 0000000..99475ba
--- /dev/null
+++ b/gnu/packages/patches/ngircd-handle-zombies.patch
@@ -0,0 +1,36 @@
+The Guile process taking the role of PID 1 during Guix builds does not reap
+zombie processes, which makes them continue responding to "kill -0".
+
+--- a/src/testsuite/stop-server.sh 2015-02-05 11:24:00.535908842 +0100
++++ b/src/testsuite/stop-server.sh 2015-02-05 11:25:00.264351349 +0100
+@@ -1,6 +1,21 @@
+ #!/bin/sh
+ # ngIRCd Test Suite
+
++process_is_alive(){
++ ! process_is_dead "$1" && ! process_is_undead "$1"
++}
++
++process_is_dead(){
++ ! kill -0 "$1"
++}
++
++process_is_undead(){
++ case $(ps -p "$1" -o state=) in
++ (Z*) true ;;
++ (*) false ;;
++ esac
++}
++
+ [ -z "$srcdir" ] && srcdir=`dirname $0`
+
+ # read in functions
+@@ -24,7 +40,7 @@
+
+ # waiting ...
+ for i in 1 2 3 4 5; do
+- kill -0 $pid > /dev/null 2>&1; r=$?
++ process_is_alive $pid > /dev/null 2>&1; r=$?
+ if [ $r -ne 0 ]; then
+ echo " ok".
+ exit 0
diff --git a/gnu/packages/patches/ngircd-no-dns-in-tests.patch b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
new file mode 100644
index 0000000..748661d
--- /dev/null
+++ b/gnu/packages/patches/ngircd-no-dns-in-tests.patch
@@ -0,0 +1,368 @@
+From 3f807e104572b38143a1015be57d875088ceaebb Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Thu, 17 Apr 2014 23:57:38 +0200
+Subject: [PATCH] Test suite: Don't use DNS lookups
+
+Different operating systems do behave quite differently when doing DNS
+lookups, for example "127.0.0.1" sometimes resolves to "localhost" and
+sometimes to "localhost.localdomain" (for example OpenBSD). And other
+systems resolve "localhost" to the real host name (for example Cygwin).
+
+So not using DNS at all makes the test site much more portable.
+---
+ src/testsuite/channel-test.e | 2 +-
+ src/testsuite/check-idle.e | 2 +-
+ src/testsuite/connect-test.e | 2 +-
+ src/testsuite/invite-test.e | 2 +-
+ src/testsuite/join-test.e | 2 +-
+ src/testsuite/kick-test.e | 2 +-
+ src/testsuite/message-test.e | 31 ++++++++++++-------------------
+ src/testsuite/misc-test.e | 8 ++++----
+ src/testsuite/mode-test.e | 2 +-
+ src/testsuite/ngircd-test1.conf | 1 +
+ src/testsuite/ngircd-test2.conf | 1 +
+ src/testsuite/opless-channel-test.e | 2 +-
+ src/testsuite/server-link-test.e | 2 +-
+ src/testsuite/stress-A.e | 2 +-
+ src/testsuite/who-test.e | 6 +++---
+ src/testsuite/whois-test.e | 14 +++++++-------
+ 16 files changed, 38 insertions(+), 43 deletions(-)
+
+diff --git a/src/testsuite/channel-test.e b/src/testsuite/channel-test.e
+index dd7eb66..39ad16a 100644
+--- a/src/testsuite/channel-test.e
++++ b/src/testsuite/channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/check-idle.e b/src/testsuite/check-idle.e
+index 41b8eb4..ad112b2 100644
+--- a/src/testsuite/check-idle.e
++++ b/src/testsuite/check-idle.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Idle test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/connect-test.e b/src/testsuite/connect-test.e
+index 662f5f7..b51be0d 100644
+--- a/src/testsuite/connect-test.e
++++ b/src/testsuite/connect-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Server connect test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/invite-test.e b/src/testsuite/invite-test.e
+index 3716d19..5179d8a 100644
+--- a/src/testsuite/invite-test.e
++++ b/src/testsuite/invite-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # INVITE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/join-test.e b/src/testsuite/join-test.e
+index 28b4c54..c088f5c 100644
+--- a/src/testsuite/join-test.e
++++ b/src/testsuite/join-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # JOIN test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/kick-test.e b/src/testsuite/kick-test.e
+index 3d3c1ee..89da611 100644
+--- a/src/testsuite/kick-test.e
++++ b/src/testsuite/kick-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # KICK test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/message-test.e b/src/testsuite/message-test.e
+index 0e70640..5dc325d 100644
+--- a/src/testsuite/message-test.e
++++ b/src/testsuite/message-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # PRIVMSG and NOTICE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -72,24 +72,17 @@ expect {
+ "MODE nick :-b"
+ }
+
+-# The following two tests using "localhost" as host name
+-# had to be disabled, because there are operating systems
+-# out there, that use "localhost.<domain>" as host name
+-# for 127.0.0.1 instead of just "localhost".
+-# (for example OpenBSD 4, OpenSolaris, ...)
+-#
+-#send "privmsg ~user\%localhost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-#}
+-#
+-#send "privmsg Nick!~User@LocalHost :test\r"
+-#expect {
+-# timeout { exit 1 }
+-# "@* PRIVMSG nick :test"
+-# "401"
+-#}
++send "privmsg ~user\%127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
++
++send "privmsg Nick!~User@127.0.0.1 :test\r"
++expect {
++ timeout { exit 1 }
++ "@* PRIVMSG nick :test"
++}
+
+ send "away :away\r"
+ expect {
+diff --git a/src/testsuite/misc-test.e b/src/testsuite/misc-test.e
+index a83bc5b..f69e7c3 100644
+--- a/src/testsuite/misc-test.e
++++ b/src/testsuite/misc-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Misc test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -130,7 +130,7 @@ expect {
+ send "userhost nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :?nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :?nick=+.*@127.0.0.1"
+ }
+
+ send "userhost doesnotexist\r"
+@@ -142,7 +142,7 @@ expect {
+ send "userhost nick doesnotexist nick doesnotexist\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=+.*@(localhos.*|127.0.0.1) nick=+.*@(localhos.*|127.0.0.1)"
++ -re ":ngircd.test.server 302 nick :nick=+.*@127.0.0.1 nick=+.*@127.0.0.1"
+ }
+
+ send "away :testing\r"
+@@ -154,7 +154,7 @@ expect {
+ send "userhost nick nick nick nick nick nick\r"
+ expect {
+ timeout { exit 1 }
+- -re ":ngircd.test.server 302 nick :nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1) nick=-.*@(localhos.*|127.0.0.1)\r"
++ -re ":ngircd.test.server 302 nick :nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1 nick=-.*@127.0.0.1\r"
+ }
+
+ send "quit\r"
+diff --git a/src/testsuite/mode-test.e b/src/testsuite/mode-test.e
+index d6726a4..86e4f2d 100644
+--- a/src/testsuite/mode-test.e
++++ b/src/testsuite/mode-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # MODE test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/ngircd-test1.conf b/src/testsuite/ngircd-test1.conf
+index 0d0cccc..4dec533 100644
+--- a/src/testsuite/ngircd-test1.conf
++++ b/src/testsuite/ngircd-test1.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/ngircd-test2.conf b/src/testsuite/ngircd-test2.conf
+index c9d7f6c..0d24c4a 100644
+--- a/src/testsuite/ngircd-test2.conf
++++ b/src/testsuite/ngircd-test2.conf
+@@ -17,6 +17,7 @@
+ OperCanUseMode = yes
+ Ident = no
+ IncludeDir = /var/empty
++ DNS = no
+ PAM = no
+
+ [Operator]
+diff --git a/src/testsuite/opless-channel-test.e b/src/testsuite/opless-channel-test.e
+index 7d94172..4611fe1 100644
+--- a/src/testsuite/opless-channel-test.e
++++ b/src/testsuite/opless-channel-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # Op-less channel test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/server-link-test.e b/src/testsuite/server-link-test.e
+index cf3fae8..910f8c8 100644
+--- a/src/testsuite/server-link-test.e
++++ b/src/testsuite/server-link-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # server-server link test
+
+-spawn telnet localhost 6790
++spawn telnet 127.0.0.1 6790
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/stress-A.e b/src/testsuite/stress-A.e
+index 256d5d1..d51adaa 100644
+--- a/src/testsuite/stress-A.e
++++ b/src/testsuite/stress-A.e
+@@ -3,7 +3,7 @@
+
+ set timeout 30
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+diff --git a/src/testsuite/who-test.e b/src/testsuite/who-test.e
+index a41e6b6..39d50ed 100644
+--- a/src/testsuite/who-test.e
++++ b/src/testsuite/who-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHO test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -62,7 +62,7 @@ expect {
+ ":ngircd.test.server 352 nick #channel * * ngircd.test.server nick G@ :0 Real Name"
+ }
+
+-send "who localhos*\r"
++send "who 127.0.0.*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick G :0 Real Name"
+@@ -120,7 +120,7 @@ expect {
+ "305 nick"
+ }
+
+-send "who ??cal*ho*\r"
++send "who ??7.*0*\r"
+ expect {
+ timeout { exit 1 }
+ ":ngircd.test.server 352 nick \* * * ngircd.test.server nick H* :0 Real Name"
+diff --git a/src/testsuite/whois-test.e b/src/testsuite/whois-test.e
+index 16b1184..44eee66 100644
+--- a/src/testsuite/whois-test.e
++++ b/src/testsuite/whois-test.e
+@@ -1,7 +1,7 @@
+ # ngIRCd test suite
+ # WHOIS test
+
+-spawn telnet localhost 6789
++spawn telnet 127.0.0.1 6789
+ expect {
+ timeout { exit 1 }
+ "Connected"
+@@ -17,7 +17,7 @@ expect {
+ send "whois nick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1 \* :Real Name\r"
+ }
+ expect {
+ timeout { exit 1 }
+@@ -27,25 +27,25 @@ expect {
+ send "whois *\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois n*\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ?ick\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois ????,n?*k\r"
+ expect {
+ timeout { exit 1 }
+- "311 nick nick ~user localhost* \* :Real Name\r"
++ "311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois unknown\r"
+@@ -61,7 +61,7 @@ expect {
+ send "whois ngircd.test.server2 nick\r"
+ expect {
+ timeout { exit 1 }
+- ":ngircd.test.server2 311 nick nick ~user localhost* \* :Real Name\r"
++ ":ngircd.test.server2 311 nick nick ~user 127.0.0.1* \* :Real Name\r"
+ }
+
+ send "whois nosuchserver unknown\r"
+--
+1.9.1
+
--
2.2.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add ngircd.
2015-02-05 14:32 ` Taylan Ulrich Bayırlı/Kammer
@ 2015-02-05 15:46 ` Mark H Weaver
0 siblings, 0 replies; 8+ messages in thread
From: Mark H Weaver @ 2015-02-05 15:46 UTC (permalink / raw
To: Taylan Ulrich "Bayırlı/Kammer"; +Cc: guix-devel
taylanbayirli@gmail.com (Taylan Ulrich "Bayırlı/Kammer") writes:
> + (arguments
> + `(#:configure-flags
> + `("--with-gnutls" "--with-iconv" "--enable-ipv6"
> + ,,@(if (string-suffix? "-linux"
> + (or (%current-target-system)
> + (%current-system)))
> + '("--with-pam")
> + '()))
There's no need for two levels of quasiquote here, and it unnecessarily
complicates the unquoting. How about changing the inner quasiquote to
normal quote? It should come out like this:
(arguments
`(#:configure-flags
'("--with-gnutls" "--with-iconv" "--enable-ipv6"
,@(if (string-suffix? "-linux"
(or (%current-target-system)
(%current-system)))
'("--with-pam")
'()))
> + #:phases
> + ;; Necessary for the test suite, should it be enabled in the future.
You can remove the ", should it be enabled in the future".
Modulo these little nitpicks, it looks good to me. Please push!
Thanks,
Mark
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2015-02-05 15:46 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-31 21:49 [PATCH] gnu: Add ngircd "Taylan Ulrich Bayırlı/Kammer"
2015-01-31 23:58 ` Taylan Ulrich Bayırlı/Kammer
2015-02-01 6:58 ` Mark H Weaver
2015-02-01 23:23 ` Taylan Ulrich Bayırlı/Kammer
2015-02-05 12:46 ` Ludovic Courtès
2015-02-05 14:32 ` Taylan Ulrich Bayırlı/Kammer
2015-02-05 15:46 ` Mark H Weaver
2015-02-05 11:53 ` Taylan Ulrich Bayırlı/Kammer
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.