From 8c5d37129fc5097d9fb52e95fb07de75392d1c3c Mon Sep 17 00:00:00 2001 From: Ben Siraphob Date: Fri, 15 Jan 2021 16:19:50 +0700 Subject: pkgs/tools: stdenv.lib -> lib --- pkgs/tools/security/tor/default.nix | 8 ++++---- pkgs/tools/security/tor/tor-arm.nix | 8 ++++---- pkgs/tools/security/tor/torsocks.nix | 12 ++++++------ 3 files changed, 14 insertions(+), 14 deletions(-) (limited to 'pkgs/tools/security/tor') diff --git a/pkgs/tools/security/tor/default.nix b/pkgs/tools/security/tor/default.nix index 038f4040d31af..a96dae5f5efd5 100644 --- a/pkgs/tools/security/tor/default.nix +++ b/pkgs/tools/security/tor/default.nix @@ -15,7 +15,7 @@ }: let tor-client-auth-gen = writeShellScript "tor-client-auth-gen" '' - PATH="${stdenv.lib.makeBinPath [coreutils gnugrep openssl]}" + PATH="${lib.makeBinPath [coreutils gnugrep openssl]}" pem="$(openssl genpkey -algorithm x25519)" printf private_key=descriptor:x25519: @@ -41,15 +41,15 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ pkgconfig ]; buildInputs = [ libevent openssl zlib lzma zstd scrypt ] ++ - stdenv.lib.optionals stdenv.isLinux [ libseccomp systemd libcap ]; + lib.optionals stdenv.isLinux [ libseccomp systemd libcap ]; patches = [ ./disable-monotonic-timer-tests.patch ]; # cross compiles correctly but needs the following - configureFlags = stdenv.lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) + configureFlags = lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) "--disable-tool-name-check"; - NIX_CFLAGS_LINK = stdenv.lib.optionalString stdenv.cc.isGNU "-lgcc_s"; + NIX_CFLAGS_LINK = lib.optionalString stdenv.cc.isGNU "-lgcc_s"; postPatch = '' substituteInPlace contrib/client-tools/torify \ diff --git a/pkgs/tools/security/tor/tor-arm.nix b/pkgs/tools/security/tor/tor-arm.nix index 896ab50562d8a..fcdb628e0f4aa 100644 --- a/pkgs/tools/security/tor/tor-arm.nix +++ b/pkgs/tools/security/tor/tor-arm.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, makeWrapper +{ lib, stdenv, fetchurl, makeWrapper , python2Packages, ncurses, lsof, nettools }: @@ -48,8 +48,8 @@ stdenv.mkDerivation rec { meta = { description = "A terminal status monitor for Tor relays"; homepage = "https://www.atagar.com/arm/"; - license = stdenv.lib.licenses.gpl3; - platforms = stdenv.lib.platforms.unix; - maintainers = [ stdenv.lib.maintainers.thoughtpolice ]; + license = lib.licenses.gpl3; + platforms = lib.platforms.unix; + maintainers = [ lib.maintainers.thoughtpolice ]; }; } diff --git a/pkgs/tools/security/tor/torsocks.nix b/pkgs/tools/security/tor/torsocks.nix index 381377032d6e0..22cfa51d4e52a 100644 --- a/pkgs/tools/security/tor/torsocks.nix +++ b/pkgs/tools/security/tor/torsocks.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, fetchurl, autoreconfHook, libcap }: +{ lib, stdenv, fetchgit, fetchurl, autoreconfHook, libcap }: stdenv.mkDerivation rec { pname = "torsocks"; @@ -12,7 +12,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ autoreconfHook ]; - patches = stdenv.lib.optional stdenv.isDarwin + patches = lib.optional stdenv.isDarwin (fetchurl { url = "https://trac.torproject.org/projects/tor/raw-attachment/ticket/28538/0001-Fix-macros-for-accept4-2.patch"; sha256 = "97881f0b59b3512acc4acb58a0d6dfc840d7633ead2f400fad70dda9b2ba30b0"; @@ -23,7 +23,7 @@ stdenv.mkDerivation rec { sed -i \ -e 's,\(local app_path\)=`which $1`,\1=`type -P $1`,' \ src/bin/torsocks.in - '' + stdenv.lib.optionalString stdenv.isLinux '' + '' + lib.optionalString stdenv.isLinux '' sed -i \ -e 's,\(local getcap\)=.*,\1=${libcap}/bin/getcap,' \ src/bin/torsocks.in @@ -36,8 +36,8 @@ stdenv.mkDerivation rec { description = "Wrapper to safely torify applications"; homepage = "https://github.com/dgoulet/torsocks"; repositories.git = "https://git.torproject.org/torsocks.git"; - license = stdenv.lib.licenses.gpl2; - platforms = stdenv.lib.platforms.unix; - maintainers = with stdenv.lib.maintainers; [ phreedom thoughtpolice ]; + license = lib.licenses.gpl2; + platforms = lib.platforms.unix; + maintainers = with lib.maintainers; [ phreedom thoughtpolice ]; }; } -- cgit 1.4.1