summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2017-10-30 22:30:14 +0100
committerVladimír Čunát <vcunat@gmail.com>2017-10-30 22:30:14 +0100
commit687943763c57016b5fc96df14ea49c5f2ad3b7ef (patch)
treea73ce1d5a41d5f2cd8eee42f696e08989037c548 /pkgs
parent5d41dda02db3f538fb253056575c151192d4ce41 (diff)
parent9d74a615ce99da0516d31de25d96ac9c9cd7576e (diff)
downloadnixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar.gz
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar.bz2
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar.lz
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar.xz
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.tar.zst
nixlib-687943763c57016b5fc96df14ea49c5f2ad3b7ef.zip
Merge branch 'master' into staging
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/graphics/sxiv/default.nix5
-rw-r--r--pkgs/applications/networking/instant-messengers/mikutter/default.nix1
-rw-r--r--pkgs/applications/science/math/pari/default.nix27
-rw-r--r--pkgs/applications/version-management/git-and-tools/default.nix2
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-codeowners/default.nix21
-rw-r--r--pkgs/build-support/fetchadc/builder.sh7
-rw-r--r--pkgs/build-support/fetchadc/default.nix36
-rw-r--r--pkgs/build-support/fetchbower/default.nix6
-rw-r--r--pkgs/build-support/fetchgitrevision/default.nix10
-rw-r--r--pkgs/development/idris-modules/with-packages.nix4
-rw-r--r--pkgs/development/interpreters/php/default.nix12
-rw-r--r--pkgs/development/node-packages/default-v4.nix4
-rw-r--r--pkgs/development/node-packages/default-v6.nix4
-rw-r--r--pkgs/development/python-modules/pandas/default.nix6
-rw-r--r--pkgs/development/tools/build-managers/gradle/default.nix4
-rw-r--r--pkgs/development/tools/continuous-integration/jenkins/default.nix4
-rw-r--r--pkgs/development/tools/ocaml/camlp5/default.nix6
-rw-r--r--pkgs/development/tools/rust/rustup/0001-dynamically-patchelf-binaries.patch54
-rw-r--r--pkgs/development/tools/rust/rustup/0001-use-hardcoded-dynamic-linker.patch75
-rw-r--r--pkgs/development/tools/rust/rustup/default.nix16
-rw-r--r--pkgs/os-specific/linux/kernel/cpu-cgroup-v2-patches/4.4.patch407
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.4.nix11
-rw-r--r--pkgs/os-specific/linux/kernel/linux-testing.nix6
-rw-r--r--pkgs/servers/monitoring/prometheus/alertmanager.nix4
-rw-r--r--pkgs/tools/text/highlight/default.nix14
-rw-r--r--pkgs/top-level/all-packages.nix26
-rw-r--r--pkgs/top-level/node-packages.nix2
-rw-r--r--pkgs/top-level/python-packages.nix2
28 files changed, 584 insertions, 192 deletions
diff --git a/pkgs/applications/graphics/sxiv/default.nix b/pkgs/applications/graphics/sxiv/default.nix
index 93bb5f151d94..68597a23ca65 100644
--- a/pkgs/applications/graphics/sxiv/default.nix
+++ b/pkgs/applications/graphics/sxiv/default.nix
@@ -23,6 +23,11 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 imlib2 giflib libexif ];
 
+  postInstall = ''
+    mkdir -p $out/share/applications/
+    cp -v sxiv.desktop $out/share/applications/
+  '';
+
   meta = {
     description = "Simple X Image Viewer";
     homepage = https://github.com/muennich/sxiv;
diff --git a/pkgs/applications/networking/instant-messengers/mikutter/default.nix b/pkgs/applications/networking/instant-messengers/mikutter/default.nix
index 1fa7a2fe7e95..e00468d9a4c6 100644
--- a/pkgs/applications/networking/instant-messengers/mikutter/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mikutter/default.nix
@@ -54,6 +54,7 @@ stdenv.mkDerivation rec {
   '';
 
   meta = with stdenv.lib; {
+    broken = true;
     description = "An extensible Twitter client";
     homepage = https://mikutter.hachune.net;
     maintainers = with maintainers; [ midchildan ];
diff --git a/pkgs/applications/science/math/pari/default.nix b/pkgs/applications/science/math/pari/default.nix
index 64784facfb96..86d4d289c2a6 100644
--- a/pkgs/applications/science/math/pari/default.nix
+++ b/pkgs/applications/science/math/pari/default.nix
@@ -14,12 +14,21 @@ stdenv.mkDerivation rec {
   buildInputs = [ gmp readline libX11 libpthreadstubs tex perl ];
 
   configureScript = "./Configure";
-  configureFlags =
-    "--mt=pthread" +
-    "--with-gmp=${gmp.dev} " +
-    "--with-readline=${readline.dev}";
+  configureFlags = [
+    "--mt=pthread"
+    "--with-gmp=${gmp.dev}"
+    "--with-readline=${readline.dev}"
+  ] ++ stdenv.lib.optional stdenv.isDarwin "--host=x86_64-darwin";
 
-  makeFlags = "all";
+  preConfigure = ''
+    export LD=$CC
+  '';
+
+  postConfigure = stdenv.lib.optionalString stdenv.isDarwin ''
+    echo 'echo x86_64-darwin' > config/arch-osname
+  '';
+
+  makeFlags = [ "all" ];
 
   meta = with stdenv.lib; {
     description = "Computer algebra system for high-performance number theory computations";
@@ -36,12 +45,12 @@ stdenv.mkDerivation rec {
        Bordeaux I, France), PARI is now under the GPL and maintained by Karim
        Belabas with the help of many volunteer contributors.
 
-       - PARI is a C library, allowing fast computations.  
+       - PARI is a C library, allowing fast computations.
        - gp is an easy-to-use interactive shell giving access to the
           PARI functions.
        - GP is the name of gp's scripting language.
-       - gp2c, the GP-to-C compiler, combines the best of both worlds 
-          by compiling GP scripts to the C language and transparently loading 
+       - gp2c, the GP-to-C compiler, combines the best of both worlds
+          by compiling GP scripts to the C language and transparently loading
           the resulting functions into gp. (gp2c-compiled scripts will typically
           run 3 or 4 times faster.) gp2c currently only understands a subset
            of the GP language.
@@ -50,7 +59,7 @@ stdenv.mkDerivation rec {
     downloadPage = "http://pari.math.u-bordeaux.fr/download.html";
     license     = licenses.gpl2Plus;
     maintainers = with maintainers; [ ertes raskin AndersonTorres ];
-    platforms   = platforms.linux;
+    platforms   = platforms.linux ++ platforms.darwin;
     updateWalker = true;
   };
 }
diff --git a/pkgs/applications/version-management/git-and-tools/default.nix b/pkgs/applications/version-management/git-and-tools/default.nix
index 82846a564cd9..58a9e8089230 100644
--- a/pkgs/applications/version-management/git-and-tools/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/default.nix
@@ -58,6 +58,8 @@ rec {
   # support for bugzilla
   git-bz = callPackage ./git-bz { };
 
+  git-codeowners = callPackage ./git-codeowners { };
+
   git-cola = callPackage ./git-cola { };
 
   git-crypt = callPackage ./git-crypt { };
diff --git a/pkgs/applications/version-management/git-and-tools/git-codeowners/default.nix b/pkgs/applications/version-management/git-and-tools/git-codeowners/default.nix
new file mode 100644
index 000000000000..07e0ce80c5d6
--- /dev/null
+++ b/pkgs/applications/version-management/git-and-tools/git-codeowners/default.nix
@@ -0,0 +1,21 @@
+{ lib, rustPlatform, fetchFromGitHub }:
+rustPlatform.buildRustPackage rec {
+  name = "git-codeowners-${version}";
+  version = "0.1.1";
+
+  src = fetchFromGitHub {
+    owner = "softprops";
+    repo = "git-codeowners";
+    rev = "v${version}";
+    sha256 = "0imxbi6y1165bi2rik0n98v79fkgp8alb615qh41idg1p2krzyy5";
+  };
+
+  cargoSha256 = "0h831rf5vlvpzfm4sr3fvwlc0ys776fqis90y414mczphkxvz437";
+
+  meta = with lib; {
+    homepage = "https://github.com/softprops/git-codeowners";
+    description = "a git extension to work with CODEOWNERS files";
+    license = licenses.mit;
+    maintainers = with maintainers; [ zimbatm ];
+  };
+}
diff --git a/pkgs/build-support/fetchadc/builder.sh b/pkgs/build-support/fetchadc/builder.sh
deleted file mode 100644
index ceeaa9213d65..000000000000
--- a/pkgs/build-support/fetchadc/builder.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-source $stdenv/setup
-
-loginpage=`curl --insecure -s -L -b cookies.txt "$url"`
-
-[[ $loginpage =~ form[^\>]+action=\"([^\"]+)\" ]] && loginurl=${BASH_REMATCH[1]}
-
-curl  --insecure -s --output "$out" -L -b cookies.txt --data "appleId=${adc_user}&accountPassword=${adc_pass}" "https://idmsa.apple.com/IDMSWebAuth/${loginurl}"
diff --git a/pkgs/build-support/fetchadc/default.nix b/pkgs/build-support/fetchadc/default.nix
deleted file mode 100644
index 4d759e6f7f18..000000000000
--- a/pkgs/build-support/fetchadc/default.nix
+++ /dev/null
@@ -1,36 +0,0 @@
-{ stdenv, curl, adc_user, adc_pass }:
-
-{ # Path to fetch.
-  path
-
-  # Hash of the downloaded file
-, sha256
-
-, # Additional curl options needed for the download to succeed.
-  curlOpts ? ""
-
-, # Name of the file.  If empty, use the basename of `path'.
-  name ? ""
-}:
-
-stdenv.mkDerivation {
-  url = "https://developer.apple.com/downloads/download.action?path=${path}";
-
-  name    = if name != "" then name else baseNameOf path;
-  builder = ./builder.sh;
-
-  buildInputs = [ curl ];
-
-  meta = {
-    # Password-guarded files from ADC are certainly unfree, as far as we're concerned!
-    license = stdenv.lib.licenses.unfree;
-  };
-
-  outputHashAlgo = "sha256";
-  outputHash     =  sha256;
-  outputHashMode = "flat";
-
-  inherit curlOpts adc_user adc_pass;
-
-  preferLocalBuild = true;
-}
diff --git a/pkgs/build-support/fetchbower/default.nix b/pkgs/build-support/fetchbower/default.nix
index dd0bac49cb6d..3e1f0eff84af 100644
--- a/pkgs/build-support/fetchbower/default.nix
+++ b/pkgs/build-support/fetchbower/default.nix
@@ -4,13 +4,13 @@ let
     let
       components = lib.splitString "#" version;
       hash = lib.last components;
-      ver = if builtins.length components == 1 then version else hash;
+      ver = if builtins.length components == 1 then (cleanName version) else hash;
     in ver;
 
-  bowerName = name: lib.replaceStrings ["/"] ["-"] name;
+  cleanName = name: lib.replaceStrings ["/" ":"] ["-" "-"] name;
 
   fetchbower = name: version: target: outputHash: stdenv.mkDerivation {
-    name = "${bowerName name}-${bowerVersion version}";
+    name = "${cleanName name}-${bowerVersion version}";
     SSL_CERT_FILE = "${cacert}/etc/ssl/certs/ca-bundle.crt";
     buildCommand = ''
       fetch-bower --quiet --out=$PWD/out "${name}" "${target}" "${version}"
diff --git a/pkgs/build-support/fetchgitrevision/default.nix b/pkgs/build-support/fetchgitrevision/default.nix
deleted file mode 100644
index e877648978d9..000000000000
--- a/pkgs/build-support/fetchgitrevision/default.nix
+++ /dev/null
@@ -1,10 +0,0 @@
-runCommand: git: repository: branch:
-  import (runCommand "head-revision"
-    { buildInputs = [ git ];
-      dummy = builtins.currentTime;
-    }
-    ''
-      rev=$(git ls-remote ${repository} | grep "refs/${branch}$" | awk '{ print $1 }')
-      echo "[ \"$rev\" ]" > $out
-      echo Latest revision in ${branch} is $rev
-    '')
diff --git a/pkgs/development/idris-modules/with-packages.nix b/pkgs/development/idris-modules/with-packages.nix
index edcd20c10978..d2b09808ec15 100644
--- a/pkgs/development/idris-modules/with-packages.nix
+++ b/pkgs/development/idris-modules/with-packages.nix
@@ -10,7 +10,7 @@
 
     installIdrisLib () {
       if [ -d $1/lib/${idris.name} ]; then
-        ln -sv $1/lib/${idris.name}/* $out/lib/${idris.name}
+        ln -fsv $1/lib/${idris.name}/* $out/lib/${idris.name}
       fi
     }
 
@@ -34,7 +34,7 @@
   '';
 
   buildPhase = ''
-    gcc -O3 -o idris idris.c
+    $CC -O3 -o idris idris.c
   '';
 
   installPhase = ''
diff --git a/pkgs/development/interpreters/php/default.nix b/pkgs/development/interpreters/php/default.nix
index 57383fa34126..be9aab50cb9f 100644
--- a/pkgs/development/interpreters/php/default.nix
+++ b/pkgs/development/interpreters/php/default.nix
@@ -326,17 +326,17 @@ let
 
 in {
   php56 = generic {
-    version = "5.6.31";
-    sha256 = "03xixkvfp64bqp97p8vlj3hp63bpjw7hc16b7fgm7w35rdlp2fcg";
+    version = "5.6.32";
+    sha256 = "0lfbmdkvijkm6xc4p9sykv66y8xwhws0vsmka8v5cax4bxx4xr1y";
   };
 
   php70 = generic {
-    version = "7.0.24";
-    sha256 = "06fgpljz6xpxxkpf4cv9rqz8g504l9ikbw5aq0hqh5sgd611kycv";
+    version = "7.0.25";
+    sha256 = "09fc2lj447phprvilvq2sb6n0r1snj142f8faphrd896s6b4v8lm";
   };
 
   php71 = generic {
-    version = "7.1.9";
-    sha256 = "1blvzm2js8mrdbmwks0v6nlb5wj4789ixzmlxm1l8z6xvw8cqk9i";
+    version = "7.1.11";
+    sha256 = "0ww5493w8w3jlks0xqlfm3v6mm53vpnv5vjy63inkj8zf3gdfikn";
   };
 }
diff --git a/pkgs/development/node-packages/default-v4.nix b/pkgs/development/node-packages/default-v4.nix
index 99cb7ca40441..c058154a9969 100644
--- a/pkgs/development/node-packages/default-v4.nix
+++ b/pkgs/development/node-packages/default-v4.nix
@@ -1,4 +1,4 @@
-{pkgs, system, nodejs}:
+{pkgs, system, nodejs, stdenv}:
 
 let
   nodePackages = import ./composition-v4.nix {
@@ -43,7 +43,7 @@ nodePackages // {
     buildInputs = oldAttrs.buildInputs ++ [ pkgs.makeWrapper ];
     postInstall = ''
       for prog in bower2nix fetch-bower; do
-        wrapProgram "$out/bin/$prog" --prefix PATH : "${pkgs.git}/bin"
+        wrapProgram "$out/bin/$prog" --prefix PATH : ${stdenv.lib.makeBinPath [ pkgs.git pkgs.nix ]}
       done
     '';
   });
diff --git a/pkgs/development/node-packages/default-v6.nix b/pkgs/development/node-packages/default-v6.nix
index 334c79a82672..3deee40812ae 100644
--- a/pkgs/development/node-packages/default-v6.nix
+++ b/pkgs/development/node-packages/default-v6.nix
@@ -1,4 +1,4 @@
-{pkgs, system, nodejs}:
+{pkgs, system, nodejs, stdenv}:
 
 let
   nodePackages = import ./composition-v6.nix {
@@ -41,7 +41,7 @@ nodePackages // {
     buildInputs = oldAttrs.buildInputs ++ [ pkgs.makeWrapper ];
     postInstall = ''
       for prog in bower2nix fetch-bower; do
-        wrapProgram "$out/bin/$prog" --prefix PATH : "${pkgs.git}/bin"
+        wrapProgram "$out/bin/$prog" --prefix PATH : ${stdenv.lib.makeBinPath [ pkgs.git pkgs.nix ]}
       done
     '';
   });
diff --git a/pkgs/development/python-modules/pandas/default.nix b/pkgs/development/python-modules/pandas/default.nix
index 7bab184bb2a0..2cbb67545a06 100644
--- a/pkgs/development/python-modules/pandas/default.nix
+++ b/pkgs/development/python-modules/pandas/default.nix
@@ -8,6 +8,7 @@
 , cython
 , dateutil
 , scipy
+, moto
 , numexpr
 , pytz
 , xlrd
@@ -27,12 +28,12 @@ let
   inherit (stdenv) isDarwin;
 in buildPythonPackage rec {
   pname = "pandas";
-  version = "0.20.3";
+  version = "0.21.0";
   name = "${pname}-${version}";
 
   src = fetchPypi {
     inherit pname version;
-    sha256 = "a777e07633d83d546c55706420179551c8e01075b53c497dcf8ae4036766bc66";
+    sha256 = "0nf50ls2cnlsd2635nyji7l70xc91dw81qg5y01g5sifwwqcpmaw";
   };
 
   LC_ALL = "en_US.UTF-8";
@@ -64,6 +65,7 @@ in buildPythonPackage rec {
                 "['pandas/src/klib', 'pandas/src', '$cpp_sdk']"
   '';
 
+  checkInputs = [ moto ];
   checkPhase = ''
     runHook preCheck
   ''
diff --git a/pkgs/development/tools/build-managers/gradle/default.nix b/pkgs/development/tools/build-managers/gradle/default.nix
index a5ea6df3c8df..bbfcc8513078 100644
--- a/pkgs/development/tools/build-managers/gradle/default.nix
+++ b/pkgs/development/tools/build-managers/gradle/default.nix
@@ -52,12 +52,12 @@ rec {
   };
 
   gradle_latest = gradleGen rec {
-    name = "gradle-4.2.1";
+    name = "gradle-4.3";
     nativeVersion = "0.14";
 
     src = fetchurl {
       url = "http://services.gradle.org/distributions/${name}-bin.zip";
-      sha256 = "1h7v133rm81jf0bgv9mgvydl7rgh4430dnsfs66wflfay82cqldm";
+      sha256 = "0k358y18pp2809kn5il4kv3qvlqrbwmy276bbm3mnmwjxx7g9jwd";
     };
   };
 
diff --git a/pkgs/development/tools/continuous-integration/jenkins/default.nix b/pkgs/development/tools/continuous-integration/jenkins/default.nix
index de0321109d7d..e6f01ba5c93d 100644
--- a/pkgs/development/tools/continuous-integration/jenkins/default.nix
+++ b/pkgs/development/tools/continuous-integration/jenkins/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   name = "jenkins-${version}";
-  version = "2.86";
+  version = "2.87";
 
   src = fetchurl {
     url = "http://mirrors.jenkins-ci.org/war/${version}/jenkins.war";
-    sha256 = "198fcj2wkz8qxawk3mq29kwl51pxlbd7ivndcpvdvg42g0caqyi0";
+    sha256 = "1nzs9nn1nr2jav59v1xj39rzmrh1zmwaqnpaiqsll8kixkr9rb8f";
   };
 
   buildCommand = ''
diff --git a/pkgs/development/tools/ocaml/camlp5/default.nix b/pkgs/development/tools/ocaml/camlp5/default.nix
index e5c79f534b0c..0acd70b424a8 100644
--- a/pkgs/development/tools/ocaml/camlp5/default.nix
+++ b/pkgs/development/tools/ocaml/camlp5/default.nix
@@ -6,11 +6,11 @@ in
 
 stdenv.mkDerivation {
 
-  name = "camlp5${if transitional then "_transitional" else ""}-7.02";
+  name = "camlp5${if transitional then "_transitional" else ""}-7.03";
 
   src = fetchzip {
-    url = https://github.com/camlp5/camlp5/archive/rel702.tar.gz;
-    sha256 = "1m2d55zrgllidhgslvzgmr27f56qzdahz2sv56bvjs3bg7grmhnc";
+    url = https://github.com/camlp5/camlp5/archive/rel703.tar.gz;
+    sha256 = "0bwzhp4qjypfa0x8drp8w434dfixm1nzrm6pcy9s5akpmqvb50a8";
   };
 
   buildInputs = [ ocaml ];
diff --git a/pkgs/development/tools/rust/rustup/0001-dynamically-patchelf-binaries.patch b/pkgs/development/tools/rust/rustup/0001-dynamically-patchelf-binaries.patch
new file mode 100644
index 000000000000..4d77cf45d417
--- /dev/null
+++ b/pkgs/development/tools/rust/rustup/0001-dynamically-patchelf-binaries.patch
@@ -0,0 +1,54 @@
+From c21cc756b69a5f33c8a7758b746a816f40f55932 Mon Sep 17 00:00:00 2001
+From: Leon Isenberg <ljli@users.noreply.github.com>
+Date: Sat, 28 Oct 2017 17:58:17 +0200
+Subject: [PATCH] nix customization: patchelf installed binaries
+
+---
+ src/rustup-dist/src/component/package.rs | 24 +++++++++++++++++++++++-
+ 1 file changed, 23 insertions(+), 1 deletion(-)
+
+diff --git a/src/rustup-dist/src/component/package.rs b/src/rustup-dist/src/component/package.rs
+index 8aa63db9..4d219826 100644
+--- a/src/rustup-dist/src/component/package.rs
++++ b/src/rustup-dist/src/component/package.rs
+@@ -99,7 +99,13 @@ impl Package for DirectoryPackage {
+             let src_path = root.join(&path);
+ 
+             match &*part.0 {
+-                "file" => try!(builder.copy_file(path.clone(), &src_path)),
++                "file" => {
++                    try!(builder.copy_file(path.clone(), &src_path));
++                    nix_patchelf_if_needed(
++                        &target.prefix().path().join(path.clone()),
++                        &src_path,
++                    )
++                }
+                 "dir" => try!(builder.copy_dir(path.clone(), &src_path)),
+                 _ => return Err(ErrorKind::CorruptComponent(name.to_owned()).into()),
+             }
+@@ -117,6 +123,22 @@ impl Package for DirectoryPackage {
+     }
+ }
+ 
++fn nix_patchelf_if_needed(dest_path: &Path, src_path: &Path) {
++    let is_bin = if let Some(p) = src_path.parent() {
++        p.ends_with("bin")
++    } else {
++        false
++    };
++
++    if is_bin {
++        let _ = ::std::process::Command::new("@patchelf@/bin/patchelf")
++            .arg("--set-interpreter")
++            .arg("@dynamicLinker@")
++            .arg(dest_path)
++            .output();
++    }
++}
++
+ // On Unix we need to set up the file permissions correctly so
+ // binaries are executable and directories readable. This shouldn't be
+ // necessary: the source files *should* have the right permissions,
+-- 
+2.14.1
+
diff --git a/pkgs/development/tools/rust/rustup/0001-use-hardcoded-dynamic-linker.patch b/pkgs/development/tools/rust/rustup/0001-use-hardcoded-dynamic-linker.patch
deleted file mode 100644
index 3b429c1745e4..000000000000
--- a/pkgs/development/tools/rust/rustup/0001-use-hardcoded-dynamic-linker.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From 36c053f37670c6003f9e8dc001741f7c49e9526a Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= <joerg@thalheim.io>
-Date: Sat, 15 Apr 2017 20:42:10 +0200
-Subject: [PATCH] use hardcoded dynamic-linker
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Signed-off-by: Jörg Thalheim <joerg@thalheim.io>
----
- src/rustup-cli/common.rs |  3 ++-
- src/rustup/toolchain.rs  | 22 ++++++++++++++++++++--
- 2 files changed, 22 insertions(+), 3 deletions(-)
-
-diff --git a/src/rustup-cli/common.rs b/src/rustup-cli/common.rs
-index 1abf345..21096e7 100644
---- a/src/rustup-cli/common.rs
-+++ b/src/rustup-cli/common.rs
-@@ -220,7 +220,8 @@ pub fn rustc_version(toolchain: &Toolchain) -> String {
-     if toolchain.exists() {
-         let rustc_path = toolchain.binary_file("rustc");
-         if utils::is_file(&rustc_path) {
--            let mut cmd = Command::new(&rustc_path);
-+            let mut cmd = Command::new("@dynamicLinker@");
-+            cmd.arg(&rustc_path);
-             cmd.arg("--version");
-             toolchain.set_ldpath(&mut cmd);
- 
-diff --git a/src/rustup/toolchain.rs b/src/rustup/toolchain.rs
-index dc29c32..212a4ab 100644
---- a/src/rustup/toolchain.rs
-+++ b/src/rustup/toolchain.rs
-@@ -315,7 +315,7 @@ impl<'a> Toolchain<'a> {
-             }
-             Path::new(&binary)
-         };
--        let mut cmd = Command::new(&path);
-+        let mut cmd = wrap_elf_interpreter(&path);
-         self.set_env(&mut cmd);
-         Ok(cmd)
-     }
-@@ -363,7 +363,7 @@ impl<'a> Toolchain<'a> {
-         } else {
-             src_file
-         };
--        let mut cmd = Command::new(exe_path);
-+        let mut cmd = wrap_elf_interpreter(exe_path);
-         self.set_env(&mut cmd);
-         cmd.env("RUSTUP_TOOLCHAIN", &primary_toolchain.name);
-         Ok(cmd)
-@@ -648,3 +648,21 @@ impl<'a> Toolchain<'a> {
-         path
-     }
- }
-+
-+fn wrap_elf_interpreter<S: AsRef<OsStr>>(p: S) -> Command {
-+    use std::fs::File;
-+    use std::io::Read;
-+    let path = Path::new(&p);
-+    let is_elf = File::open(path).map(|mut f| {
-+        let mut buf = [0; 4];
-+        let _ = f.read(&mut buf);
-+        buf == b"\x7fELF"[..]
-+    }).unwrap_or(false);
-+    if is_elf {
-+        let mut cmd = Command::new("@dynamicLinker@");
-+        cmd.arg(&path);
-+        cmd
-+    } else {
-+        Command::new(&path)
-+    }
-+}
--- 
-2.12.2
-
diff --git a/pkgs/development/tools/rust/rustup/default.nix b/pkgs/development/tools/rust/rustup/default.nix
index 65599ad8d18f..b7065cc5d7da 100644
--- a/pkgs/development/tools/rust/rustup/default.nix
+++ b/pkgs/development/tools/rust/rustup/default.nix
@@ -1,18 +1,18 @@
-{ stdenv, lib, runCommand
+{ stdenv, lib, runCommand, patchelf
 , fetchFromGitHub, rustPlatform
 , pkgconfig, curl, Security }:
 
 rustPlatform.buildRustPackage rec {
   name = "rustup-${version}";
-  version = "1.3.0";
+  version = "2017-10-29";
 
-  cargoSha256 = "1yd7k0jpx78p5bp6iyzgbyj7pjz8vyjg9g7fmf1bl60jsbdpgv3g";
+  cargoSha256 = "1xwxv8y9xjgdmm92ldrn9m9fml2zb5h7qqm7dhw63j6psb3ajqrw";
 
   src = fetchFromGitHub {
     owner = "rust-lang-nursery";
     repo = "rustup.rs";
-    rev = version;
-    sha256 = "199jlqqidzak7nxmv2nzjzv7zfzy9z7hw6h8d8wf1rbfdwd9l6hs";
+    rev = "13c8092507bf646f3ef6a621fe2c5a68212e800f";
+    sha256 = "1qd01rjk9qpfzgqs35f5nxrcf00kmf76zwmgj3yzdig9zymjwndg";
   };
 
   nativeBuildInputs = [ pkgconfig ];
@@ -24,9 +24,11 @@ rustPlatform.buildRustPackage rec {
   cargoBuildFlags = [ "--features no-self-update" ];
 
   patches = lib.optionals stdenv.isLinux [
-    (runCommand "0001-use-hardcoded-dynamic-linker.patch" { CC=stdenv.cc; } ''
+    (runCommand "0001-dynamically-patchelf-binaries.patch" { CC=stdenv.cc; patchelf = patchelf; } ''
        export dynamicLinker=$(cat $CC/nix-support/dynamic-linker)
-       substituteAll ${./0001-use-hardcoded-dynamic-linker.patch} $out
+       substitute ${./0001-dynamically-patchelf-binaries.patch} $out \
+         --subst-var patchelf \
+         --subst-var dynamicLinker
     '')
   ];
 
diff --git a/pkgs/os-specific/linux/kernel/cpu-cgroup-v2-patches/4.4.patch b/pkgs/os-specific/linux/kernel/cpu-cgroup-v2-patches/4.4.patch
new file mode 100644
index 000000000000..8f2418c9efce
--- /dev/null
+++ b/pkgs/os-specific/linux/kernel/cpu-cgroup-v2-patches/4.4.patch
@@ -0,0 +1,407 @@
+commit e7cae741f6d645ac68fe8823ca6ef45dbbf6891b
+Author: Tejun Heo <tj@kernel.org>
+Date:   Fri Mar 11 07:31:23 2016 -0500
+
+    sched: Misc preps for cgroup unified hierarchy interface
+    
+    Make the following changes in preparation for the cpu controller
+    interface implementation for the unified hierarchy.  This patch
+    doesn't cause any functional differences.
+    
+    * s/cpu_stats_show()/cpu_cfs_stats_show()/
+    
+    * s/cpu_files/cpu_legacy_files/
+    
+    * Separate out cpuacct_stats_read() from cpuacct_stats_show().  While
+      at it, remove pointless cpuacct_stat_desc[] array.
+    
+    Signed-off-by: Tejun Heo <tj@kernel.org>
+    Cc: Ingo Molnar <mingo@redhat.com>
+    Cc: Peter Zijlstra <peterz@infradead.org>
+    Cc: Li Zefan <lizefan@huawei.com>
+    Cc: Johannes Weiner <hannes@cmpxchg.org>
+
+diff --git a/kernel/sched/core.c b/kernel/sched/core.c
+index 732e993..77f3ddd 100644
+--- a/kernel/sched/core.c
++++ b/kernel/sched/core.c
+@@ -8512,7 +8512,7 @@ static int __cfs_schedulable(struct task_group *tg, u64 period, u64 quota)
+ 	return ret;
+ }
+ 
+-static int cpu_stats_show(struct seq_file *sf, void *v)
++static int cpu_cfs_stats_show(struct seq_file *sf, void *v)
+ {
+ 	struct task_group *tg = css_tg(seq_css(sf));
+ 	struct cfs_bandwidth *cfs_b = &tg->cfs_bandwidth;
+@@ -8552,7 +8552,7 @@ static u64 cpu_rt_period_read_uint(struct cgroup_subsys_state *css,
+ }
+ #endif /* CONFIG_RT_GROUP_SCHED */
+ 
+-static struct cftype cpu_files[] = {
++static struct cftype cpu_legacy_files[] = {
+ #ifdef CONFIG_FAIR_GROUP_SCHED
+ 	{
+ 		.name = "shares",
+@@ -8573,7 +8573,7 @@ static struct cftype cpu_files[] = {
+ 	},
+ 	{
+ 		.name = "stat",
+-		.seq_show = cpu_stats_show,
++		.seq_show = cpu_cfs_stats_show,
+ 	},
+ #endif
+ #ifdef CONFIG_RT_GROUP_SCHED
+@@ -8599,7 +8599,7 @@ struct cgroup_subsys cpu_cgrp_subsys = {
+ 	.fork		= cpu_cgroup_fork,
+ 	.can_attach	= cpu_cgroup_can_attach,
+ 	.attach		= cpu_cgroup_attach,
+-	.legacy_cftypes	= cpu_files,
++	.legacy_cftypes	= cpu_legacy_files,
+ 	.early_init	= 1,
+ };
+ 
+diff --git a/kernel/sched/cpuacct.c b/kernel/sched/cpuacct.c
+index dd7cbb5..42b2dd5 100644
+--- a/kernel/sched/cpuacct.c
++++ b/kernel/sched/cpuacct.c
+@@ -177,36 +177,33 @@ static int cpuacct_percpu_seq_show(struct seq_file *m, void *V)
+ 	return 0;
+ }
+ 
+-static const char * const cpuacct_stat_desc[] = {
+-	[CPUACCT_STAT_USER] = "user",
+-	[CPUACCT_STAT_SYSTEM] = "system",
+-};
+-
+-static int cpuacct_stats_show(struct seq_file *sf, void *v)
++static void cpuacct_stats_read(struct cpuacct *ca, u64 *userp, u64 *sysp)
+ {
+-	struct cpuacct *ca = css_ca(seq_css(sf));
+ 	int cpu;
+-	s64 val = 0;
+ 
++	*userp = 0;
+ 	for_each_online_cpu(cpu) {
+ 		struct kernel_cpustat *kcpustat = per_cpu_ptr(ca->cpustat, cpu);
+-		val += kcpustat->cpustat[CPUTIME_USER];
+-		val += kcpustat->cpustat[CPUTIME_NICE];
++		*userp += kcpustat->cpustat[CPUTIME_USER];
++		*userp += kcpustat->cpustat[CPUTIME_NICE];
+ 	}
+-	val = cputime64_to_clock_t(val);
+-	seq_printf(sf, "%s %lld\n", cpuacct_stat_desc[CPUACCT_STAT_USER], val);
+ 
+-	val = 0;
++	*sysp = 0;
+ 	for_each_online_cpu(cpu) {
+ 		struct kernel_cpustat *kcpustat = per_cpu_ptr(ca->cpustat, cpu);
+-		val += kcpustat->cpustat[CPUTIME_SYSTEM];
+-		val += kcpustat->cpustat[CPUTIME_IRQ];
+-		val += kcpustat->cpustat[CPUTIME_SOFTIRQ];
++		*sysp += kcpustat->cpustat[CPUTIME_SYSTEM];
++		*sysp += kcpustat->cpustat[CPUTIME_IRQ];
++		*sysp += kcpustat->cpustat[CPUTIME_SOFTIRQ];
+ 	}
++}
+ 
+-	val = cputime64_to_clock_t(val);
+-	seq_printf(sf, "%s %lld\n", cpuacct_stat_desc[CPUACCT_STAT_SYSTEM], val);
++static int cpuacct_stats_show(struct seq_file *sf, void *v)
++{
++	cputime64_t user, sys;
+ 
++	cpuacct_stats_read(css_ca(seq_css(sf)), &user, &sys);
++	seq_printf(sf, "user %lld\n", cputime64_to_clock_t(user));
++	seq_printf(sf, "system %lld\n", cputime64_to_clock_t(sys));
+ 	return 0;
+ }
+ 
+
+commit 1bb33e8a69f089f2d3f58a0e681d4ff352e11c97
+Author: Tejun Heo <tj@kernel.org>
+Date:   Fri Mar 11 07:31:23 2016 -0500
+
+    sched: Implement interface for cgroup unified hierarchy
+    
+    While the cpu controller doesn't have any functional problems, there
+    are a couple interface issues which can be addressed in the v2
+    interface.
+    
+    * cpuacct being a separate controller.  This separation is artificial
+      and rather pointless as demonstrated by most use cases co-mounting
+      the two controllers.  It also forces certain information to be
+      accounted twice.
+    
+    * Use of different time units.  Writable control knobs use
+      microseconds, some stat fields use nanoseconds while other cpuacct
+      stat fields use centiseconds.
+    
+    * Control knobs which can't be used in the root cgroup still show up
+      in the root.
+    
+    * Control knob names and semantics aren't consistent with other
+      controllers.
+    
+    This patchset implements cpu controller's interface on the unified
+    hierarchy which adheres to the controller file conventions described
+    in Documentation/cgroups/unified-hierarchy.txt.  Overall, the
+    following changes are made.
+    
+    * cpuacct is implictly enabled and disabled by cpu and its information
+      is reported through "cpu.stat" which now uses microseconds for all
+      time durations.  All time duration fields now have "_usec" appended
+      to them for clarity.  While this doesn't solve the double accounting
+      immediately, once majority of users switch to v2, cpu can directly
+      account and report the relevant stats and cpuacct can be disabled on
+      the unified hierarchy.
+    
+      Note that cpuacct.usage_percpu is currently not included in
+      "cpu.stat".  If this information is actually called for, it can be
+      added later.
+    
+    * "cpu.shares" is replaced with "cpu.weight" and operates on the
+      standard scale defined by CGROUP_WEIGHT_MIN/DFL/MAX (1, 100, 10000).
+      The weight is scaled to scheduler weight so that 100 maps to 1024
+      and the ratio relationship is preserved - if weight is W and its
+      scaled value is S, W / 100 == S / 1024.  While the mapped range is a
+      bit smaller than the orignal scheduler weight range, the dead zones
+      on both sides are relatively small and covers wider range than the
+      nice value mappings.  This file doesn't make sense in the root
+      cgroup and isn't create on root.
+    
+    * "cpu.cfs_quota_us" and "cpu.cfs_period_us" are replaced by "cpu.max"
+      which contains both quota and period.
+    
+    * "cpu.rt_runtime_us" and "cpu.rt_period_us" are replaced by
+      "cpu.rt.max" which contains both runtime and period.
+    
+    v2: cpu_stats_show() was incorrectly using CONFIG_FAIR_GROUP_SCHED for
+        CFS bandwidth stats and also using raw division for u64.  Use
+        CONFIG_CFS_BANDWITH and do_div() instead.
+    
+        The semantics of "cpu.rt.max" is not fully decided yet.  Dropped
+        for now.
+    
+    Signed-off-by: Tejun Heo <tj@kernel.org>
+    Cc: Ingo Molnar <mingo@redhat.com>
+    Cc: Peter Zijlstra <peterz@infradead.org>
+    Cc: Li Zefan <lizefan@huawei.com>
+    Cc: Johannes Weiner <hannes@cmpxchg.org>
+
+diff --git a/kernel/sched/core.c b/kernel/sched/core.c
+index 77f3ddd..7aafe63 100644
+--- a/kernel/sched/core.c
++++ b/kernel/sched/core.c
+@@ -8591,6 +8591,139 @@ static struct cftype cpu_legacy_files[] = {
+ 	{ }	/* terminate */
+ };
+ 
++static int cpu_stats_show(struct seq_file *sf, void *v)
++{
++	cpuacct_cpu_stats_show(sf);
++
++#ifdef CONFIG_CFS_BANDWIDTH
++	{
++		struct task_group *tg = css_tg(seq_css(sf));
++		struct cfs_bandwidth *cfs_b = &tg->cfs_bandwidth;
++		u64 throttled_usec;
++
++		throttled_usec = cfs_b->throttled_time;
++		do_div(throttled_usec, NSEC_PER_USEC);
++
++		seq_printf(sf, "nr_periods %d\n"
++			   "nr_throttled %d\n"
++			   "throttled_usec %llu\n",
++			   cfs_b->nr_periods, cfs_b->nr_throttled,
++			   throttled_usec);
++	}
++#endif
++	return 0;
++}
++
++#ifdef CONFIG_FAIR_GROUP_SCHED
++static u64 cpu_weight_read_u64(struct cgroup_subsys_state *css,
++			       struct cftype *cft)
++{
++	struct task_group *tg = css_tg(css);
++	u64 weight = scale_load_down(tg->shares);
++
++	return DIV_ROUND_CLOSEST_ULL(weight * CGROUP_WEIGHT_DFL, 1024);
++}
++
++static int cpu_weight_write_u64(struct cgroup_subsys_state *css,
++				struct cftype *cftype, u64 weight)
++{
++	/*
++	 * cgroup weight knobs should use the common MIN, DFL and MAX
++	 * values which are 1, 100 and 10000 respectively.  While it loses
++	 * a bit of range on both ends, it maps pretty well onto the shares
++	 * value used by scheduler and the round-trip conversions preserve
++	 * the original value over the entire range.
++	 */
++	if (weight < CGROUP_WEIGHT_MIN || weight > CGROUP_WEIGHT_MAX)
++		return -ERANGE;
++
++	weight = DIV_ROUND_CLOSEST_ULL(weight * 1024, CGROUP_WEIGHT_DFL);
++
++	return sched_group_set_shares(css_tg(css), scale_load(weight));
++}
++#endif
++
++static void __maybe_unused cpu_period_quota_print(struct seq_file *sf,
++						  long period, long quota)
++{
++	if (quota < 0)
++		seq_puts(sf, "max");
++	else
++		seq_printf(sf, "%ld", quota);
++
++	seq_printf(sf, " %ld\n", period);
++}
++
++/* caller should put the current value in *@periodp before calling */
++static int __maybe_unused cpu_period_quota_parse(char *buf,
++						 u64 *periodp, u64 *quotap)
++{
++	char tok[21];	/* U64_MAX */
++
++	if (!sscanf(buf, "%s %llu", tok, periodp))
++		return -EINVAL;
++
++	*periodp *= NSEC_PER_USEC;
++
++	if (sscanf(tok, "%llu", quotap))
++		*quotap *= NSEC_PER_USEC;
++	else if (!strcmp(tok, "max"))
++		*quotap = RUNTIME_INF;
++	else
++		return -EINVAL;
++
++	return 0;
++}
++
++#ifdef CONFIG_CFS_BANDWIDTH
++static int cpu_max_show(struct seq_file *sf, void *v)
++{
++	struct task_group *tg = css_tg(seq_css(sf));
++
++	cpu_period_quota_print(sf, tg_get_cfs_period(tg), tg_get_cfs_quota(tg));
++	return 0;
++}
++
++static ssize_t cpu_max_write(struct kernfs_open_file *of,
++			     char *buf, size_t nbytes, loff_t off)
++{
++	struct task_group *tg = css_tg(of_css(of));
++	u64 period = tg_get_cfs_period(tg);
++	u64 quota;
++	int ret;
++
++	ret = cpu_period_quota_parse(buf, &period, &quota);
++	if (!ret)
++		ret = tg_set_cfs_bandwidth(tg, period, quota);
++	return ret ?: nbytes;
++}
++#endif
++
++static struct cftype cpu_files[] = {
++	{
++		.name = "stat",
++		.flags = CFTYPE_NOT_ON_ROOT,
++		.seq_show = cpu_stats_show,
++	},
++#ifdef CONFIG_FAIR_GROUP_SCHED
++	{
++		.name = "weight",
++		.flags = CFTYPE_NOT_ON_ROOT,
++		.read_u64 = cpu_weight_read_u64,
++		.write_u64 = cpu_weight_write_u64,
++	},
++#endif
++#ifdef CONFIG_CFS_BANDWIDTH
++	{
++		.name = "max",
++		.flags = CFTYPE_NOT_ON_ROOT,
++		.seq_show = cpu_max_show,
++		.write = cpu_max_write,
++	},
++#endif
++	{ }	/* terminate */
++};
++
+ struct cgroup_subsys cpu_cgrp_subsys = {
+ 	.css_alloc	= cpu_cgroup_css_alloc,
+ 	.css_free	= cpu_cgroup_css_free,
+@@ -8600,7 +8733,15 @@ struct cgroup_subsys cpu_cgrp_subsys = {
+ 	.can_attach	= cpu_cgroup_can_attach,
+ 	.attach		= cpu_cgroup_attach,
+ 	.legacy_cftypes	= cpu_legacy_files,
++	.dfl_cftypes	= cpu_files,
+ 	.early_init	= 1,
++#ifdef CONFIG_CGROUP_CPUACCT
++	/*
++	 * cpuacct is enabled together with cpu on the unified hierarchy
++	 * and its stats are reported through "cpu.stat".
++	 */
++	.depends_on	= 1 << cpuacct_cgrp_id,
++#endif
+ };
+ 
+ #endif	/* CONFIG_CGROUP_SCHED */
+diff --git a/kernel/sched/cpuacct.c b/kernel/sched/cpuacct.c
+index 42b2dd5..b4d32a6 100644
+--- a/kernel/sched/cpuacct.c
++++ b/kernel/sched/cpuacct.c
+@@ -224,6 +224,30 @@ static struct cftype files[] = {
+ 	{ }	/* terminate */
+ };
+ 
++/* used to print cpuacct stats in cpu.stat on the unified hierarchy */
++void cpuacct_cpu_stats_show(struct seq_file *sf)
++{
++	struct cgroup_subsys_state *css;
++	u64 usage, user, sys;
++
++	css = cgroup_get_e_css(seq_css(sf)->cgroup, &cpuacct_cgrp_subsys);
++
++	usage = cpuusage_read(css, seq_cft(sf));
++	cpuacct_stats_read(css_ca(css), &user, &sys);
++
++	user *= TICK_NSEC;
++	sys *= TICK_NSEC;
++	do_div(usage, NSEC_PER_USEC);
++	do_div(user, NSEC_PER_USEC);
++	do_div(sys, NSEC_PER_USEC);
++
++	seq_printf(sf, "usage_usec %llu\n"
++		   "user_usec %llu\n"
++		   "system_usec %llu\n", usage, user, sys);
++
++	css_put(css);
++}
++
+ /*
+  * charge this task's execution time to its accounting group.
+  *
+diff --git a/kernel/sched/cpuacct.h b/kernel/sched/cpuacct.h
+index ed60562..44eace9 100644
+--- a/kernel/sched/cpuacct.h
++++ b/kernel/sched/cpuacct.h
+@@ -2,6 +2,7 @@
+ 
+ extern void cpuacct_charge(struct task_struct *tsk, u64 cputime);
+ extern void cpuacct_account_field(struct task_struct *p, int index, u64 val);
++extern void cpuacct_cpu_stats_show(struct seq_file *sf);
+ 
+ #else
+ 
+@@ -14,4 +15,8 @@ cpuacct_account_field(struct task_struct *p, int index, u64 val)
+ {
+ }
+ 
++static inline void cpuacct_cpu_stats_show(struct seq_file *sf)
++{
++}
++
+ #endif
diff --git a/pkgs/os-specific/linux/kernel/linux-4.4.nix b/pkgs/os-specific/linux/kernel/linux-4.4.nix
new file mode 100644
index 000000000000..a695fe34cd68
--- /dev/null
+++ b/pkgs/os-specific/linux/kernel/linux-4.4.nix
@@ -0,0 +1,11 @@
+{ stdenv, hostPlatform, fetchurl, perl, buildLinux, ... } @ args:
+
+import ./generic.nix (args // rec {
+  version = "4.4.95";
+  extraMeta.branch = "4.4";
+
+  src = fetchurl {
+    url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
+    sha256 = "07vkxhh435gilxsh9ag6zvf2r9k5l9ffqp72900c50nsfjrdgdrx";
+  };
+} // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-testing.nix b/pkgs/os-specific/linux/kernel/linux-testing.nix
index 3a8d82cdb269..8c8fd3c97337 100644
--- a/pkgs/os-specific/linux/kernel/linux-testing.nix
+++ b/pkgs/os-specific/linux/kernel/linux-testing.nix
@@ -1,13 +1,13 @@
 { stdenv, hostPlatform, fetchurl, perl, buildLinux, ... } @ args:
 
 import ./generic.nix (args // rec {
-  version = "4.14-rc6";
-  modDirVersion = "4.14.0-rc6";
+  version = "4.14-rc7";
+  modDirVersion = "4.14.0-rc7";
   extraMeta.branch = "4.14";
 
   src = fetchurl {
     url = "https://git.kernel.org/torvalds/t/linux-${version}.tar.gz";
-    sha256 = "0gmxrf4jmw8xl5gx487chyx94yas7rva5jbkczm9iw9sw0c8gwcb";
+    sha256 = "1w7b1sc5dsxcqywsdbwgs92i8jpj7hsnss67yzb58z3bz3hb73m3";
   };
 
   # Should the testing kernels ever be built on Hydra?
diff --git a/pkgs/servers/monitoring/prometheus/alertmanager.nix b/pkgs/servers/monitoring/prometheus/alertmanager.nix
index 3ae2a45ca6d0..444aa92ec2e6 100644
--- a/pkgs/servers/monitoring/prometheus/alertmanager.nix
+++ b/pkgs/servers/monitoring/prometheus/alertmanager.nix
@@ -2,7 +2,7 @@
 
 buildGoPackage rec {
   name = "alertmanager-${version}";
-  version = "0.8.0";
+  version = "0.9.1";
   rev = "v${version}";
 
   goPackagePath = "github.com/prometheus/alertmanager";
@@ -11,7 +11,7 @@ buildGoPackage rec {
     inherit rev;
     owner = "prometheus";
     repo = "alertmanager";
-    sha256 = "0bqc58j0nrq7y8nbd927z7x74m8mcd2782cxkqwscpq6d9983qql";
+    sha256 = "1lkfj63pp4jf58xmn015r7s42p1wyj6fryihpmdn0k76b0ccwqzj";
   };
 
   # Tests exist, but seem to clash with the firewall.
diff --git a/pkgs/tools/text/highlight/default.nix b/pkgs/tools/text/highlight/default.nix
index 71c5e352b949..275d65e7c370 100644
--- a/pkgs/tools/text/highlight/default.nix
+++ b/pkgs/tools/text/highlight/default.nix
@@ -1,14 +1,16 @@
-{ stdenv, fetchurl, getopt, lua, boost, pkgconfig, gcc }:
+{ stdenv, fetchFromGitHub, getopt, lua, boost, pkgconfig, gcc }:
 
 with stdenv.lib;
 
 stdenv.mkDerivation rec {
   name = "highlight-${version}";
-  version = "3.39";
+  version = "3.40";
 
-  src = fetchurl {
-    url = "http://www.andre-simon.de/zip/${name}.tar.bz2";
-    sha256 = "0z8gs69sqlyis4kvl8wwdgzywi199k73kkvn1mf9pf60npvcxwj4";
+  src = fetchFromGitHub {
+    owner = "andre-simon";
+    repo = "highlight";
+    rev = "${version}";
+    sha256 = "0bkywhz4y10qcajimdha1ck5mvn7fsrv3yn8nd6rqbva39gbfmfd";
   };
 
   nativeBuildInputs = [ pkgconfig ] ++ optional stdenv.isDarwin  gcc ;
@@ -28,6 +30,6 @@ stdenv.mkDerivation rec {
     description = "Source code highlighting tool";
     homepage = http://www.andre-simon.de/doku/highlight/en/highlight.php;
     platforms = platforms.unix;
-    maintainers = [ maintainers.ndowens ];
+    maintainers = with maintainers; [ ndowens willibutz ];
   };
 }
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 7295ce09c239..4b28a7b59689 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -126,15 +126,6 @@ with pkgs;
     vs = vs90wrapper;
   };
 
-  fetchadc = callPackage ../build-support/fetchadc {
-    adc_user = if config ? adc_user
-      then config.adc_user
-      else throw "You need an adc_user attribute in your config to download files from Apple Developer Connection";
-    adc_pass = if config ? adc_pass
-      then config.adc_pass
-      else throw "You need an adc_pass attribute in your config to download files from Apple Developer Connection";
-  };
-
   fetchbower = callPackage ../build-support/fetchbower {
     inherit (nodePackages) bower2nix;
   };
@@ -153,8 +144,6 @@ with pkgs;
 
   fetchgitPrivate = callPackage ../build-support/fetchgit/private.nix { };
 
-  fetchgitrevision = import ../build-support/fetchgitrevision runCommand git;
-
   fetchgitLocal = callPackage ../build-support/fetchgitlocal { };
 
   fetchmtn = callPackage ../build-support/fetchmtn (config.fetchmtn or {});
@@ -12442,6 +12431,20 @@ with pkgs;
     ];
   };
 
+  linux_4_4 = callPackage ../os-specific/linux/kernel/linux-4.4.nix {
+    kernelPatches =
+      [ kernelPatches.bridge_stp_helper
+        kernelPatches.p9_fixes
+        kernelPatches.cpu-cgroup-v2."4.4"
+        kernelPatches.modinst_arg_list_too_long
+      ]
+      ++ lib.optionals ((platform.kernelArch or null) == "mips")
+      [ kernelPatches.mips_fpureg_emu
+        kernelPatches.mips_fpu_sigill
+        kernelPatches.mips_ext3_n32
+      ];
+  };
+
   linux_4_9 = callPackage ../os-specific/linux/kernel/linux-4.9.nix {
     kernelPatches =
       [ kernelPatches.bridge_stp_helper
@@ -12664,6 +12667,7 @@ with pkgs;
   linuxPackages_hardened_copperhead = linuxPackagesFor pkgs.linux_hardened_copperhead;
   linuxPackages_mptcp = linuxPackagesFor pkgs.linux_mptcp;
   linuxPackages_rpi = linuxPackagesFor pkgs.linux_rpi;
+  linuxPackages_4_4 = recurseIntoAttrs (linuxPackagesFor pkgs.linux_4_4);
   linuxPackages_4_9 = recurseIntoAttrs (linuxPackagesFor pkgs.linux_4_9);
   linuxPackages_4_13 = recurseIntoAttrs (linuxPackagesFor pkgs.linux_4_13);
   # Don't forget to update linuxPackages_latest!
diff --git a/pkgs/top-level/node-packages.nix b/pkgs/top-level/node-packages.nix
index d8eb668107be..4f72b4206998 100644
--- a/pkgs/top-level/node-packages.nix
+++ b/pkgs/top-level/node-packages.nix
@@ -66,7 +66,7 @@ in rec {
     bower2nix.buildInputs = [ pkgs.makeWrapper ];
     bower2nix.postInstall = ''
       for prog in bower2nix fetch-bower; do
-        wrapProgram "$out/bin/$prog" --prefix PATH : "${pkgs.git}/bin"
+        wrapProgram "$out/bin/$prog" --prefix PATH : ${stdenv.lib.makeBinPath [ pkgs.git pkgs.nix ]}
       done
     '';
   } // args.overrides or {};
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index d83ac0df11b0..9ce0e45284b7 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -12469,7 +12469,7 @@ in {
     patches = [
       (pkgs.fetchpatch {
         url = https://github.com/drkjam/netaddr/commit/2ab73f10be7069c9412e853d2d0caf29bd624012.patch;
-        sha256 = "08rn1s3w9424jhandy4j9sksy852ny00088zh15nirw5ajqg1dn7";
+        sha256 = "0s1cdn9v5alpviabhcjmzc0m2pnpq9dh2fnnk2x96dnry1pshg39";
       })
     ];