Skip to content

Commit

Permalink
inetutils: fix service name
Browse files Browse the repository at this point in the history
  • Loading branch information
Mic92 committed Apr 20, 2017
1 parent 1aadcd7 commit 67adf69
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 3 deletions.
10 changes: 7 additions & 3 deletions pkgs/tools/networking/inetutils/default.nix
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, ncurses, perl }:
{ stdenv, fetchurl, ncurses, perl, help2man }:

stdenv.mkDerivation rec {
name = "inetutils-1.9.4";
Expand All @@ -8,16 +8,20 @@ stdenv.mkDerivation rec {
sha256 = "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy";
};

patches = [ ./whois-Update-Canadian-TLD-server.patch ];
patches = [
./whois-Update-Canadian-TLD-server.patch
./service-name.patch
];

buildInputs = [ ncurses /* for `talk' */ perl /* for `whois' */ ];
buildInputs = [ ncurses /* for `talk' */ perl /* for `whois' */ help2man ];

configureFlags = "--with-ncurses-include-dir=${ncurses.dev}/include";

# Test fails with "UNIX socket name too long", probably because our
# $TMPDIR is too long.
#doCheck = true;


postInstall = ''
# XXX: These programs are normally installed setuid but since it
# fails, they end up being non-executable, hence this hack.
Expand Down
11 changes: 11 additions & 0 deletions pkgs/tools/networking/inetutils/service-name.patch
@@ -0,0 +1,11 @@
--- inetutils-1.9.4.org/whois/whois.c 2015-03-31 17:40:50.000000000 +0200
+++ inetutils-1.9.4/whois/whois.c 2017-04-20 10:23:38.487358708 +0200
@@ -576,7 +576,7 @@
hints.ai_family = AF_UNSPEC;
hints.ai_socktype = SOCK_STREAM;

- if ((i = getaddrinfo (server, port ? port : "whois", &hints, &res)) != 0)
+ if ((i = getaddrinfo (server, port ? port : "nicname", &hints, &res)) != 0)
err_quit ("getaddrinfo: %s", gai_strerror (i));

for (ressave = res; res; res = res->ai_next)

0 comments on commit 67adf69

Please sign in to comment.