summary refs log tree commit diff
path: root/pkgs/tools/networking/ntp
diff options
context:
space:
mode:
authorFranz Pletz <fpletz@fnordicwalking.de>2016-11-21 23:11:05 +0100
committerFranz Pletz <fpletz@fnordicwalking.de>2016-11-21 23:11:05 +0100
commit67fd21a170daac003c8b87c43b3eeeb5a81f28ac (patch)
tree750668b4a365a1afd114d5a03b57f4fc6ea48b1f /pkgs/tools/networking/ntp
parentdb66a95e5b704b8c1e9c55f186f1dccbfb6ce580 (diff)
downloadnixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar.gz
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar.bz2
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar.lz
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar.xz
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.tar.zst
nixpkgs-67fd21a170daac003c8b87c43b3eeeb5a81f28ac.zip
ntp: use seccomp on linux
Diffstat (limited to 'pkgs/tools/networking/ntp')
-rw-r--r--pkgs/tools/networking/ntp/default.nix11
1 files changed, 7 insertions, 4 deletions
diff --git a/pkgs/tools/networking/ntp/default.nix b/pkgs/tools/networking/ntp/default.nix
index 07602fec6ae..445cb1fb393 100644
--- a/pkgs/tools/networking/ntp/default.nix
+++ b/pkgs/tools/networking/ntp/default.nix
@@ -1,6 +1,7 @@
-{ stdenv, fetchurl, autoreconfHook, libcap ? null, openssl ? null }:
+{ stdenv, fetchurl, openssl, libcap ? null, libseccomp ? null }:
 
 assert stdenv.isLinux -> libcap != null;
+assert stdenv.isLinux -> libseccomp != null;
 
 stdenv.mkDerivation rec {
   name = "ntp-4.2.8p9";
@@ -16,10 +17,12 @@ stdenv.mkDerivation rec {
     "--with-openssl-libdir=${openssl.out}/lib"
     "--with-openssl-incdir=${openssl.dev}/include"
     "--enable-ignore-dns-errors"
-  ] ++ stdenv.lib.optional (libcap != null) "--enable-linuxcaps";
+  ] ++ stdenv.lib.optionals stdenv.isLinux [
+    "--enable-linuxcaps"
+    "--enable-libseccomp"
+  ];
 
-  nativeBuildInputs = [ autoreconfHook ];
-  buildInputs = [ libcap openssl ];
+  buildInputs = [ libcap openssl libseccomp ];
 
   hardeningEnable = [ "pie" ];