Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions pkgs/by-name/tc/tcp_wrappers/package.nix
Original file line number Diff line number Diff line change
@@ -1,34 +1,38 @@
{
fetchurl,
fetchFromGitLab,
lib,
stdenv,
libnsl,
}:

let
vanillaVersion = "7.6.q";
patchLevel = "33";
patchLevel = "36";
in
stdenv.mkDerivation rec {
pname = "tcp-wrappers";
version = "${vanillaVersion}-${patchLevel}";

src = fetchurl {
url = "mirror://debian/pool/main/t/tcp-wrappers/tcp-wrappers_${vanillaVersion}.orig.tar.gz";
sha256 = "0p9ilj4v96q32klavx0phw9va21fjp8vpk11nbh6v2ppxnnxfhwm";
url = "http://ftp.porcupine.org/pub/security/tcp_wrappers_7.6.tar.gz";
hash = "sha256-lUPXre33im3gsiHMu9GVLgi1E4cX9K3oFAObtImkMV0=";
};

debian = fetchurl {
url = "mirror://debian/pool/main/t/tcp-wrappers/tcp-wrappers_${version}.debian.tar.xz";
hash = "sha256-Lykjyu4hKDS/DqQ8JAFhKDffHrbJ9W1gjBKNpdaNRew=";
debian = fetchFromGitLab {
domain = "salsa.debian.org";
owner = "md";
repo = "tcp-wrappers";
tag = "debian/${version}";
hash = "sha256-SPJmhtgysChnxlta5l1huRq66YcEmHvx1Xs4k7iznTg=";
};

prePatch = ''
tar -xaf $debian
cp -r $debian/debian .
patches="$(cat debian/patches/series | sed 's,^,debian/patches/,') $patches"

substituteInPlace Makefile --replace STRINGS STRINGDEFS
substituteInPlace debian/patches/13_shlib_weaksym --replace STRINGS STRINGDEFS
substituteInPlace Makefile --replace-fail STRINGS STRINGDEFS
substituteInPlace debian/patches/13_shlib_weaksym --replace-fail STRINGS STRINGDEFS
'';

# Fix __BEGIN_DECLS usage (even if it wasn't non-standard, this doesn't include sys/cdefs.h)
Expand Down
Loading