From 67b887147fc935ab8587d9b712541dcbf902b48a Mon Sep 17 00:00:00 2001 From: Armeen Mahdian Date: Tue, 26 Apr 2022 09:35:10 -0500 Subject: nmap: remove graphical support --- pkgs/tools/security/nmap/default.nix | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) (limited to 'pkgs/tools/security/nmap/default.nix') diff --git a/pkgs/tools/security/nmap/default.nix b/pkgs/tools/security/nmap/default.nix index 0a6733e993d..5e71c2e1655 100644 --- a/pkgs/tools/security/nmap/default.nix +++ b/pkgs/tools/security/nmap/default.nix @@ -1,9 +1,7 @@ { lib, stdenv, fetchurl, fetchpatch, libpcap, pkg-config, openssl, lua5_3 , pcre, libssh2 -, graphicalSupport ? false , libX11 ? null , gtk2 ? null -, python2 ? null , makeWrapper ? null , withLua ? true }: @@ -11,7 +9,7 @@ with lib; stdenv.mkDerivation rec { - pname = "nmap${optionalString graphicalSupport "-graphical"}"; + pname = "nmap"; version = "7.92"; src = fetchurl { @@ -41,7 +39,9 @@ stdenv.mkDerivation rec { configureFlags = [ (if withLua then "--with-liblua=${lua5_3}" else "--without-liblua") "--with-liblinear=included" - ] ++ optionals (!graphicalSupport) [ "--without-ndiff" "--without-zenmap" ]; + "--without-ndiff" + "--without-zenmap" + ]; makeFlags = optionals (stdenv.buildPlatform != stdenv.hostPlatform) [ "AR=${stdenv.cc.bintools.targetPrefix}ar" @@ -49,20 +49,8 @@ stdenv.mkDerivation rec { "CC=${stdenv.cc.targetPrefix}gcc" ]; - pythonPath = with python2.pkgs; optionals graphicalSupport [ - pygtk pysqlite pygobject2 pycairo - ]; - - nativeBuildInputs = [ pkg-config ] ++ optionals graphicalSupport [ python2.pkgs.wrapPython ]; - buildInputs = [ pcre libssh2 libpcap openssl ] ++ optionals graphicalSupport (with python2.pkgs; [ - python2 libX11 gtk2 - ]); - - postInstall = optionalString graphicalSupport '' - buildPythonPath "$out $pythonPath" - patchPythonScript $out/bin/ndiff - patchPythonScript $out/bin/zenmap - ''; + nativeBuildInputs = [ pkg-config ]; + buildInputs = [ pcre libssh2 libpcap openssl ]; enableParallelBuilding = true; -- cgit 1.4.1