Merge pull request #142616 from r-burns/toplevel-system

treewide: remove toplevel `system` attr
This commit is contained in:
Ryan Burns 2021-10-27 10:03:24 -07:00 committed by GitHub
commit f67d4dd9c1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 13 additions and 14 deletions

View file

@ -11,7 +11,6 @@
, yajl
, nixosTests
, criu
, system
}:
let
@ -52,7 +51,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libcap libseccomp systemd yajl ]
# Criu currently only builds on x86_64-linux
++ lib.optional (lib.elem system criu.meta.platforms) criu;
++ lib.optional (lib.elem stdenv.hostPlatform.system criu.meta.platforms) criu;
enableParallelBuilding = true;

View file

@ -31,8 +31,6 @@
, writeText
, writeTextDir
, writePython3
, system
, # Note: This is the cross system we're compiling for
}:
let

View file

@ -1,10 +1,10 @@
{ lib, stdenv, fetchurl, fetchzip, system ? stdenv.targetPlatform }:
{ lib, stdenv, fetchurl, fetchzip }:
stdenv.mkDerivation rec {
pname = "adguardhome";
version = "0.106.3";
src = (import ./bins.nix { inherit fetchurl fetchzip; }).${system};
src = (import ./bins.nix { inherit fetchurl fetchzip; }).${stdenv.hostPlatform.system};
installPhase = ''
install -m755 -D ./AdGuardHome $out/bin/adguardhome

View file

@ -1,4 +1,4 @@
{ lib, stdenv, pkgs, fetchurl, ffmpeg, ffmpegSupport ? true, makeWrapper, nixosTests }:
{ lib, stdenv, fetchurl, ffmpeg, ffmpegSupport ? true, makeWrapper, nixosTests }:
with lib;
@ -7,7 +7,7 @@ stdenv.mkDerivation rec {
version = "0.45.1";
src = fetchurl (if pkgs.system == "x86_64-linux"
src = fetchurl (if stdenv.hostPlatform.system == "x86_64-linux"
then {
url = "https://github.com/deluan/navidrome/releases/download/v${version}/navidrome_${version}_Linux_x86_64.tar.gz";
sha256 = "sha256-TZcXq51sKoeLPmcRpv4VILDmS6dsS7lxlJzTDH0tEWM=";

View file

@ -1,8 +1,9 @@
{ pkgs, system, lib, fetchFromGitHub, dataDir ? "/var/lib/bookstack" }:
{ pkgs, stdenv, lib, fetchFromGitHub, dataDir ? "/var/lib/bookstack" }:
let
package = (import ./composition.nix {
inherit pkgs system;
inherit pkgs;
inherit (stdenv.hostPlatform) system;
noDev = true; # Disable development dependencies
}).overrideAttrs (attrs : {
installPhase = attrs.installPhase + ''

View file

@ -1,6 +1,6 @@
{ pkgs, system, dataDir ? "/opt/zigbee2mqtt/data", nixosTests }:
{ pkgs, stdenv, dataDir ? "/opt/zigbee2mqtt/data", nixosTests }:
let
package = (import ./node.nix { inherit pkgs system; }).package;
package = (import ./node.nix { inherit pkgs; inherit (stdenv.hostPlatform) system; }).package;
in
package.override rec {
# don't upgrade! Newer versions cause stack overflows and fail trunk-combined

View file

@ -8,7 +8,7 @@
# nix run nixpkgs.nodePackages.node2nix -c node2nix -l package-lock.json -d
# cp -v node-*.nix package*.json ~/p/nixpkgs/pkgs/tools/misc/fx_cast/app
# ```
{ pkgs, stdenv, system }: let
{ pkgs, stdenv }: let
nodeEnv = import ./node-env.nix {
inherit (pkgs) nodejs stdenv lib python2 runCommand writeTextFile;
inherit pkgs;

View file

@ -1214,4 +1214,6 @@ mapAliases ({
targetLlvmLibraries = targetPackages.llvmPackages_git.libraries;
});
inherit (stdenv.hostPlatform) system; # added 2021-10-22
})

View file

@ -116,7 +116,6 @@ let
inherit (super.stdenv) buildPlatform hostPlatform targetPlatform;
in {
inherit buildPlatform hostPlatform targetPlatform;
inherit (hostPlatform) system;
};
splice = self: super: import ./splice.nix lib self (adjacentPackages != null);