forked from mirrors/nixpkgs
Remove duplicate tcp-wrappers package
This commit is contained in:
parent
ea1d49d0a1
commit
59e979177d
|
@ -1,74 +0,0 @@
|
|||
x@{builderDefsPackage
|
||||
, flex, bison
|
||||
, ...}:
|
||||
builderDefsPackage
|
||||
(a :
|
||||
let
|
||||
helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++
|
||||
[];
|
||||
|
||||
buildInputs = map (n: builtins.getAttr n x)
|
||||
(builtins.attrNames (builtins.removeAttrs x helperArgNames));
|
||||
sourceInfo = rec {
|
||||
baseName="tcp-wrappers";
|
||||
version="7.6";
|
||||
name="${baseName}-${version}";
|
||||
url="http://ftp.porcupine.org/pub/security/tcp_wrappers_${version}.tar.gz";
|
||||
hash="0p9ilj4v96q32klavx0phw9va21fjp8vpk11nbh6v2ppxnnxfhwm";
|
||||
};
|
||||
in
|
||||
rec {
|
||||
src = a.fetchurl {
|
||||
url = sourceInfo.url;
|
||||
sha256 = sourceInfo.hash;
|
||||
};
|
||||
|
||||
inherit (sourceInfo) name version;
|
||||
inherit buildInputs;
|
||||
|
||||
/* doConfigure should be removed if not needed */
|
||||
phaseNames = ["setVars" "doUnpack" "fixMakefile" "doPatch"
|
||||
"doMake" "doDeploy"];
|
||||
|
||||
patches = [./have-strerror.patch ./trivial-fixes.patch];
|
||||
|
||||
makeFlags = [
|
||||
"REAL_DAEMON_DIR=$out/bin"
|
||||
"STYLE='\"-DHAVE_STRERROR -DSYS_ERRLIST_DEFINED\"'"
|
||||
"generic"
|
||||
];
|
||||
|
||||
setVars = a.noDepEntry ''
|
||||
export NIX_LDFLAGS="$NIX_LDFLAGS -lnsl"
|
||||
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -fPIC"
|
||||
'';
|
||||
|
||||
fixMakefile = a.fullDepEntry ''
|
||||
chmod u+w Makefile
|
||||
echo 'libwrap.so: $(LIB_OBJ)' >> Makefile
|
||||
echo ' ld $(LIB_OBJ) --shared -o libwrap.so' >> Makefile
|
||||
'' ["minInit"];
|
||||
|
||||
doDeploy = a.fullDepEntry ''
|
||||
mkdir -p "$out"/{sbin,lib}
|
||||
make libwrap.so
|
||||
cp libwrap.{a,so} "$out/lib"
|
||||
find . -perm +111 -a ! -name '*.*' -exec cp '{}' "$out/sbin" ';'
|
||||
'' ["defEnsureDir" "minInit"];
|
||||
|
||||
meta = {
|
||||
description = "Network logging TCP wrappers";
|
||||
maintainers = with a.lib.maintainers;
|
||||
[
|
||||
raskin
|
||||
];
|
||||
platforms = with a.lib.platforms;
|
||||
linux;
|
||||
license = "free-noncopyleft";
|
||||
};
|
||||
passthru = {
|
||||
updateInfo = {
|
||||
downloadPage = "http://ftp.porcupine.org/pub/security/index.html";
|
||||
};
|
||||
};
|
||||
}) x
|
|
@ -1,20 +0,0 @@
|
|||
Debian patch
|
||||
diff -ruN tcp_wrappers_7.6.orig/percent_m.c tcp_wrappers_7.6/percent_m.c
|
||||
--- tcp_wrappers_7.6.orig/percent_m.c 1994-12-28 17:42:37.000000000 +0100
|
||||
+++ tcp_wrappers_7.6/percent_m.c 2003-08-21 02:45:31.000000000 +0200
|
||||
@@ -29,11 +29,15 @@
|
||||
|
||||
while (*bp = *cp)
|
||||
if (*cp == '%' && cp[1] == 'm') {
|
||||
+#ifdef HAVE_STRERROR
|
||||
+ strcpy(bp, strerror(errno));
|
||||
+#else
|
||||
if (errno < sys_nerr && errno > 0) {
|
||||
strcpy(bp, sys_errlist[errno]);
|
||||
} else {
|
||||
sprintf(bp, "Unknown error %d", errno);
|
||||
}
|
||||
+#endif
|
||||
bp += strlen(bp);
|
||||
cp += 2;
|
||||
} else {
|
|
@ -1,27 +0,0 @@
|
|||
Debian patch
|
||||
diff -ruNp tcp_wrappers_7.6.orig/options.c tcp_wrappers_7.6/options.c
|
||||
--- tcp_wrappers_7.6.orig/options.c 2006-03-01 23:45:28.000000000 +0100
|
||||
+++ tcp_wrappers_7.6/options.c 2006-03-01 22:55:44.000000000 +0100
|
||||
@@ -41,6 +41,7 @@ static char sccsid[] = "@(#) options.c 1
|
||||
#include <netinet/in.h>
|
||||
#include <netdb.h>
|
||||
#include <stdio.h>
|
||||
+#include <unistd.h>
|
||||
#include <syslog.h>
|
||||
#include <pwd.h>
|
||||
#include <grp.h>
|
||||
diff -ruNp tcp_wrappers_7.6.orig/scaffold.c tcp_wrappers_7.6/scaffold.c
|
||||
--- tcp_wrappers_7.6.orig/scaffold.c 2006-03-01 23:45:28.000000000 +0100
|
||||
+++ tcp_wrappers_7.6/scaffold.c 2006-03-01 22:56:13.000000000 +0100
|
||||
@@ -17,6 +17,7 @@ static char sccs_id[] = "@(#) scaffold.c
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
#include <stdio.h>
|
||||
+#include <stdlib.h>
|
||||
#include <syslog.h>
|
||||
#include <setjmp.h>
|
||||
#include <string.h>
|
||||
@@ -28,3 +28,2 @@
|
||||
|
||||
-extern char *malloc();
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ fetchurl, stdenv, tcpWrapper, utillinux, libcap, libtirpc, libevent, libnfsidmap
|
||||
{ fetchurl, stdenv, tcp_wrappers, utillinux, libcap, libtirpc, libevent, libnfsidmap
|
||||
, lvm2, e2fsprogs }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
|
|||
};
|
||||
|
||||
buildInputs =
|
||||
[ tcpWrapper utillinux libcap libtirpc libevent libnfsidmap
|
||||
[ tcp_wrappers utillinux libcap libtirpc libevent libnfsidmap
|
||||
lvm2 e2fsprogs
|
||||
];
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ fetchurl, stdenv, lib, tcpWrapper
|
||||
{ fetchurl, stdenv, lib, tcp_wrappers
|
||||
, daemonUser ? false, daemonUID ? false, daemonGID ? false }:
|
||||
|
||||
assert daemonUser -> (!daemonUID && !daemonGID);
|
||||
|
@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
|
|||
++ lib.optional (daemonUID != false) "DAEMON_UID=${toString daemonUID}"
|
||||
++ lib.optional (daemonGID != false) "DAEMON_GID=${toString daemonGID}";
|
||||
|
||||
buildInputs = [ tcpWrapper ];
|
||||
buildInputs = [ tcp_wrappers ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p "$out/sbin" "$out/man/man8"
|
||||
|
|
|
@ -4916,8 +4916,6 @@ let
|
|||
|
||||
tcltls = callPackage ../development/libraries/tcltls { };
|
||||
|
||||
tcp_wrappers = callPackage ../development/libraries/tcp-wrappers {};
|
||||
|
||||
tdb = callPackage ../development/libraries/tdb { };
|
||||
|
||||
tecla = callPackage ../development/libraries/tecla { };
|
||||
|
@ -6193,7 +6191,7 @@ let
|
|||
};
|
||||
|
||||
# FIXME: `tcp-wrapper' is actually not OS-specific.
|
||||
tcpWrapper = callPackage ../os-specific/linux/tcp-wrapper { };
|
||||
tcp_wrappers = callPackage ../os-specific/linux/tcp-wrappers { };
|
||||
|
||||
trackballs = callPackage ../games/trackballs {
|
||||
debug = false;
|
||||
|
|
Loading…
Reference in a new issue