4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
32 lines
1.1 KiB
Nix
32 lines
1.1 KiB
Nix
{ lib, stdenv, fetchzip, libpcap, glib, pkgconfig, libnet }:
|
|
stdenv.mkDerivation {
|
|
pname = "libnids";
|
|
version = "1.24";
|
|
src = fetchzip {
|
|
url = "mirror://sourceforge/libnids/libnids-1.24.tar.gz";
|
|
sha256 = "1cblklfdfxcmy0an6xyyzx4l877xdawhjd28daqfsvrh81mb07k1";
|
|
};
|
|
nativeBuildInputs = [ pkgconfig ];
|
|
buildInputs = [ libpcap glib libnet ];
|
|
|
|
/*
|
|
Quoting the documentation of glib: g_thread_init has been deprecated since
|
|
version 2.32 and should not be used in newly-written code. This function is
|
|
no longer necessary. The GLib threading system is automatically initialized
|
|
at the start of your program.
|
|
|
|
this is necessary for dsniff to compile; otherwise g_thread_init is a missing
|
|
symbol when linking (?!?)
|
|
*/
|
|
NIX_CFLAGS_COMPILE="-Dg_thread_init= ";
|
|
|
|
meta = with lib; {
|
|
description = "An E-component of Network Intrusion Detection System which emulates the IP stack of Linux 2.0.x";
|
|
homepage = "http://libnids.sourceforge.net/";
|
|
license = licenses.gpl2;
|
|
maintainers = [ maintainers.symphorien ];
|
|
# probably also bsd and solaris
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|