summary refs log tree commit diff
path: root/pkgs/tools
diff options
context:
space:
mode:
authorJörg Thalheim <joerg@thalheim.io>2020-12-31 08:49:13 +0100
committerJörg Thalheim <joerg@thalheim.io>2020-12-31 08:50:36 +0100
commitc2fca99f975c6656f7a7d1355ca098606380f2be (patch)
tree0c8b30af0e0c5b5bda93cfe95490baa761a82617 /pkgs/tools
parentf19b7b03a03b7f1d5beb44471eb9298de4b9e186 (diff)
downloadnixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar.gz
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar.bz2
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar.lz
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar.xz
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.tar.zst
nixpkgs-c2fca99f975c6656f7a7d1355ca098606380f2be.zip
Revert "Merge branch 'master' into staging-next"
This reverts commit f19b7b03a03b7f1d5beb44471eb9298de4b9e186, reversing
changes made to 572a864d024b0c91ac39133f35364362b2376c07.

Sorry. I pushed the wrong staging-next (the one that had my master
merged in). This was not intended.
Diffstat (limited to 'pkgs/tools')
-rw-r--r--pkgs/tools/audio/tts/default.nix13
-rw-r--r--pkgs/tools/security/tor/default.nix18
-rw-r--r--pkgs/tools/typesetting/tex/texlive/bin.nix6
-rw-r--r--pkgs/tools/typesetting/tex/texlive/combine.nix2
-rw-r--r--pkgs/tools/typesetting/tex/texlive/default.nix6
-rw-r--r--pkgs/tools/virtualization/amazon-ec2-utils/default.nix42
-rw-r--r--pkgs/tools/virtualization/ec2-utils/default.nix47
7 files changed, 55 insertions, 79 deletions
diff --git a/pkgs/tools/audio/tts/default.nix b/pkgs/tools/audio/tts/default.nix
index 1634bfa5b30..770e898f2ee 100644
--- a/pkgs/tools/audio/tts/default.nix
+++ b/pkgs/tools/audio/tts/default.nix
@@ -61,18 +61,6 @@ python3Packages.buildPythonApplication rec {
       url = "https://github.com/mozilla/TTS/commit/36fee428b9f3f4ec1914b090a2ec9d785314d9aa.patch";
       sha256 = "sha256-pP0NxiyrsvQ0A7GEleTdT87XO08o7WxPEpb6Bmj66dc=";
     })
-    (fetchpatch {
-      url = "https://github.com/Mic92/TTS/commit/5bf62009e8c19e8c1627d1f7aa54e11bc5fa91d7.patch";
-      sha256 = "sha256-ZxDytieD0zoP0/RXzG0bbVnl0oE+DF8iUVpHb8+2TqM=";
-    })
-    (fetchpatch {
-      url = "https://github.com/mozilla/TTS/commit/3000647e542fce9773f4c5da082630befa5525f1.patch";
-      sha256 = "sha256-dl8Zy0dEw9z4ZZFcuP1WHzCVh2+nn0jDKOncoCK+syM=";
-    })
-    (fetchpatch {
-      url = "https://github.com/mozilla/TTS/commit/fe86a076bb1c7e18078718be0aa36da427f325bd.patch";
-      sha256 = "sha256-cT5HYkLFzmSMwAHLOHgpG+v9HGKIbUxwS8Dt9SKHm+8=";
-    })
   ];
 
   preBuild = ''
@@ -107,7 +95,6 @@ python3Packages.buildPythonApplication rec {
     inflect
     gdown
     pysbd
-    pyworld
   ];
 
   postInstall = ''
diff --git a/pkgs/tools/security/tor/default.nix b/pkgs/tools/security/tor/default.nix
index e46fd4790a3..04bf598d132 100644
--- a/pkgs/tools/security/tor/default.nix
+++ b/pkgs/tools/security/tor/default.nix
@@ -1,6 +1,5 @@
 { stdenv, fetchurl, pkgconfig, libevent, openssl, zlib, torsocks
 , libseccomp, systemd, libcap, lzma, zstd, scrypt, nixosTests
-, writeShellScript
 
 # for update.nix
 , writeScript
@@ -13,21 +12,7 @@
 , gnused
 , nix
 }:
-let
-  tor-client-auth-gen = writeShellScript "tor-client-auth-gen" ''
-    PATH="${stdenv.lib.makeBinPath [coreutils gnugrep openssl]}"
-    pem="$(openssl genpkey -algorithm x25519)"
-
-    printf private_key=descriptor:x25519:
-    echo "$pem" | grep -v " PRIVATE KEY" |
-    base64 -d | tail --bytes=32 | base32 | tr -d =
-
-    printf public_key=descriptor:x25519:
-    echo "$pem" | openssl pkey -in /dev/stdin -pubout |
-    grep -v " PUBLIC KEY" |
-    base64 -d | tail --bytes=32 | base32 | tr -d =
-  '';
-in
+
 stdenv.mkDerivation rec {
   pname = "tor";
   version = "0.4.4.6";
@@ -67,7 +52,6 @@ stdenv.mkDerivation rec {
     mkdir -p $geoip/share/tor
     mv $out/share/tor/geoip{,6} $geoip/share/tor
     rm -rf $out/share/tor
-    ln -s ${tor-client-auth-gen} $out/bin/tor-client-auth-gen
   '';
 
   passthru = {
diff --git a/pkgs/tools/typesetting/tex/texlive/bin.nix b/pkgs/tools/typesetting/tex/texlive/bin.nix
index 4df486a2511..030ac1b43aa 100644
--- a/pkgs/tools/typesetting/tex/texlive/bin.nix
+++ b/pkgs/tools/typesetting/tex/texlive/bin.nix
@@ -2,7 +2,7 @@
 , texlive
 , zlib, libiconv, libpng, libX11
 , freetype, gd, libXaw, icu, ghostscript, libXpm, libXmu, libXext
-, perl, perlPackages, python3Packages, pkgconfig
+, perl, perlPackages, python2Packages, pkgconfig
 , poppler, libpaper, graphite2, zziplib, harfbuzz, potrace, gmp, mpfr
 , brotli, cairo, pixman, xorg, clisp, biber, woff2, xxHash
 , makeWrapper, shortenPerlShebang
@@ -321,13 +321,13 @@ latexindent = perlPackages.buildPerlPackage rec {
 };
 
 
-pygmentex = python3Packages.buildPythonApplication rec {
+pygmentex = python2Packages.buildPythonApplication rec {
   pname = "pygmentex";
   inherit (src) version;
 
   src = stdenv.lib.head (builtins.filter (p: p.tlType == "run") texlive.pygmentex.pkgs);
 
-  propagatedBuildInputs = with python3Packages; [ pygments chardet ];
+  propagatedBuildInputs = with python2Packages; [ pygments chardet ];
 
   dontBuild = true;
 
diff --git a/pkgs/tools/typesetting/tex/texlive/combine.nix b/pkgs/tools/typesetting/tex/texlive/combine.nix
index 33633433575..0625fe16090 100644
--- a/pkgs/tools/typesetting/tex/texlive/combine.nix
+++ b/pkgs/tools/typesetting/tex/texlive/combine.nix
@@ -27,7 +27,7 @@ let
       [ "de-macro" "pythontex" "dviasm" "texliveonfly" ];
     pkgNeedsRuby = pkg: pkg.tlType == "run" && pkg.pname == "match-parens";
     extraInputs =
-      lib.optional (lib.any pkgNeedsPython splitBin.wrong) python3
+      lib.optional (lib.any pkgNeedsPython splitBin.wrong) python
       ++ lib.optional (lib.any pkgNeedsRuby splitBin.wrong) ruby;
   };
 
diff --git a/pkgs/tools/typesetting/tex/texlive/default.nix b/pkgs/tools/typesetting/tex/texlive/default.nix
index 0c7dadc150b..c2e6399ab86 100644
--- a/pkgs/tools/typesetting/tex/texlive/default.nix
+++ b/pkgs/tools/typesetting/tex/texlive/default.nix
@@ -4,7 +4,7 @@
 */
 { stdenv, lib, fetchurl, runCommand, writeText, buildEnv
 , callPackage, ghostscriptX, harfbuzz, poppler_min
-, makeWrapper, python3, ruby, perl
+, makeWrapper, python, ruby, perl
 , useFixedHashes ? true
 , recurseIntoAttrs
 }:
@@ -25,7 +25,7 @@ let
   # function for creating a working environment from a set of TL packages
   combine = import ./combine.nix {
     inherit bin combinePkgs buildEnv lib makeWrapper writeText
-      stdenv python3 ruby perl;
+      stdenv python ruby perl;
     ghostscript = ghostscriptX; # could be without X, probably, but we use X above
   };
 
@@ -110,7 +110,7 @@ let
         #"ftp://tug.org/texlive/historic/2019/tlnet-final/archive"
 
         # Daily snapshots hosted by one of the texlive release managers
-        "https://texlive.info/tlnet-archive/2020/10/09/tlnet/archive"
+        https://texlive.info/tlnet-archive/2020/10/09/tlnet/archive
       ];
 
       src = fetchurl { inherit urls sha512; };
diff --git a/pkgs/tools/virtualization/amazon-ec2-utils/default.nix b/pkgs/tools/virtualization/amazon-ec2-utils/default.nix
deleted file mode 100644
index d7dd6ad0b1e..00000000000
--- a/pkgs/tools/virtualization/amazon-ec2-utils/default.nix
+++ /dev/null
@@ -1,42 +0,0 @@
-{ stdenv, lib, fetchFromGitHub, python3, installShellFiles }:
-
-stdenv.mkDerivation rec {
-  pname = "amazon-ec2-utils";
-  version = "1.3";
-
-  src = fetchFromGitHub {
-    owner = "aws";
-    repo = "amazon-ec2-utils";
-    rev = version;
-    sha256 = "sha256-uxKnbdKGhS32kY3mA7YYtDRwKcEjNZPJUYQExZTqtxE=";
-  };
-
-  buildInputs = [ python3 ];
-  # TODO next version will have manpages
-  #nativeBuildInputs = [ installShellFiles ];
-
-  installPhase = ''
-    # https://github.com/aws/amazon-ec2-utils/blob/8eb2effb1aea2280264d66ae58b3e156e6d429f9/amazon-ec2-utils.spec#L74
-    install -D --target $out/etc/udev/rules.d *.rules
-    install -D --target $out/bin ec2-metadata ebsnvme-id ec2udev-vbd ec2udev-vcpu
-    install -D --target $out/lib/udev/ ec2nvme-nsid
-    # TODO next version will have manpages
-    #installManPage doc/*
-  '';
-
-  postFixup = ''
-    for i in $out/etc/udev/rules.d/*.rules; do
-      substituteInPlace "$i" \
-        --replace '/sbin' "$out/bin"
-    done
-    substituteInPlace "$out/etc/udev/rules.d/70-ec2-nvme-devices.rules" \
-      --replace 'ec2nvme-nsid' "$out/lib/udev/ec2nvme-nsid"
-  '';
-
-  meta = {
-    description = "A set of tools for running in EC2";
-    homepage = "https://aws.amazon.com/amazon-linux-ami/";
-    license = lib.licenses.asl20;
-    maintainers = with lib.maintainers; [ thefloweringash ];
-  };
-}
diff --git a/pkgs/tools/virtualization/ec2-utils/default.nix b/pkgs/tools/virtualization/ec2-utils/default.nix
new file mode 100644
index 00000000000..1605bcfa43b
--- /dev/null
+++ b/pkgs/tools/virtualization/ec2-utils/default.nix
@@ -0,0 +1,47 @@
+{ stdenv, lib, rpmextract, fetchurl, python2, tree }:
+
+stdenv.mkDerivation {
+  name = "ec2-utils";
+  version = "0.5.1";
+
+  # The url can be determined by booting an "Amazon Linux 2" and running:
+  # > yumdownloader --urls ec2-utils
+  src = fetchurl {
+    url = "http://amazonlinux.ap-northeast-1.amazonaws.com/blobstore/a3b4d2c35c2300518fe10381a05b3bd7936ff5cdd3d351143a11bf84073d9e00/ec2-utils-0.5-1.amzn2.0.1.noarch.rpm";
+    sha256 = "004y7l3q9gqi78a53lykrpsnz4yp7dds1083w67m2013bk1x5d53";
+  };
+
+  nativeBuildInputs = [ rpmextract ];
+
+  buildInputs = [ python2 ];
+
+  unpackPhase = ''
+    mkdir source
+    cd source
+    rpmextract "$src"
+  '';
+
+  installPhase = ''
+    mkdir $out
+
+    mv --target-directory $out \
+      etc sbin usr/bin usr/lib
+  '';
+
+  postFixup = ''
+    for i in $out/etc/udev/rules.d/*.rules; do
+      substituteInPlace "$i" \
+        --replace '/sbin' "$out/bin"
+    done
+
+    substituteInPlace "$out/etc/udev/rules.d/70-ec2-nvme-devices.rules" \
+      --replace 'ec2nvme-nsid' "$out/lib/udev/ec2nvme-nsid"
+  '';
+
+  meta = {
+    description = "A set of tools for running in EC2";
+    homepage = "https://aws.amazon.com/amazon-linux-ami/";
+    license = lib.licenses.asl20;
+    maintainers = with lib.maintainers; [ thefloweringash ];
+  };
+}