about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/opendkim
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/opendkim')
-rw-r--r--nixpkgs/pkgs/development/libraries/opendkim/default.nix35
1 files changed, 35 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/opendkim/default.nix b/nixpkgs/pkgs/development/libraries/opendkim/default.nix
new file mode 100644
index 000000000000..3d110910b159
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/opendkim/default.nix
@@ -0,0 +1,35 @@
+{ stdenv, fetchurl, pkgconfig, libbsd, openssl, libmilter
+, perl, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  name = "opendkim-${version}";
+  version = "2.10.3";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/opendkim/files/${name}.tar.gz";
+    sha256 = "06v8bqhh604sz9rh5bvw278issrwjgc4h1wx2pz9a84lpxbvm823";
+  };
+
+  configureFlags= [
+    "--with-milter=${libmilter}"
+    "ac_cv_func_malloc_0_nonnull=yes"
+    "ac_cv_func_realloc_0_nonnull=yes"
+  ];
+
+  nativeBuildInputs = [ pkgconfig makeWrapper ];
+
+  buildInputs = [ libbsd openssl libmilter perl ];
+
+  postInstall = ''
+    wrapProgram $out/sbin/opendkim-genkey \
+      --prefix PATH : ${openssl.bin}/bin
+  '';
+
+  meta = with stdenv.lib; {
+    description = "C library for producing DKIM-aware applications and an open source milter for providing DKIM service";
+    homepage = http://www.opendkim.org/;
+    maintainers = with maintainers; [ abbradar ];
+    license = licenses.bsd3;
+    platforms = platforms.unix;
+  };
+}