Merge pull request #312169 from B4dM4n/remove-alias-usage

treewide: Remove usage of pkgs.{system,hostPlatform} aliases

authored by Weijia Wang and committed by GitHub b6f40375 97445937

+6 -6
+1 -1
nixos/modules/system/boot/binfmt.nix
··· 280 }; 281 282 config = { 283 - boot.binfmt.registrations = builtins.listToAttrs (map (system: assert system != pkgs.system; { 284 name = system; 285 value = { config, ... }: let 286 interpreter = getEmulator system;
··· 280 }; 281 282 config = { 283 + boot.binfmt.registrations = builtins.listToAttrs (map (system: assert system != pkgs.stdenv.hostPlatform.system; { 284 name = system; 285 value = { config, ... }: let 286 interpreter = getEmulator system;
+2 -2
nixos/modules/virtualisation/lxc-image-metadata.nix
··· 87 contents = [ 88 { 89 source = toYAML "metadata.yaml" { 90 - architecture = builtins.elemAt (builtins.match "^([a-z0-9_]+).+" (toString pkgs.system)) 0; 91 creation_date = 1; 92 properties = { 93 - description = "${config.system.nixos.distroName} ${config.system.nixos.codeName} ${config.system.nixos.label} ${pkgs.system}"; 94 os = "${config.system.nixos.distroId}"; 95 release = "${config.system.nixos.codeName}"; 96 };
··· 87 contents = [ 88 { 89 source = toYAML "metadata.yaml" { 90 + architecture = builtins.elemAt (builtins.match "^([a-z0-9_]+).+" (toString pkgs.stdenv.hostPlatform.system)) 0; 91 creation_date = 1; 92 properties = { 93 + description = "${config.system.nixos.distroName} ${config.system.nixos.codeName} ${config.system.nixos.label} ${pkgs.stdenv.hostPlatform.system}"; 94 os = "${config.system.nixos.distroId}"; 95 release = "${config.system.nixos.codeName}"; 96 };
+1 -1
nixos/modules/virtualisation/qemu-vm.nix
··· 912 "ppc64-linux" = "tpm-spapr"; 913 "armv7-linux" = "tpm-tis-device"; 914 "aarch64-linux" = "tpm-tis-device"; 915 - }.${pkgs.hostPlatform.system} or (throw "Unsupported system for TPM2 emulation in QEMU")); 916 defaultText = '' 917 Based on the guest platform Linux system: 918
··· 912 "ppc64-linux" = "tpm-spapr"; 913 "armv7-linux" = "tpm-tis-device"; 914 "aarch64-linux" = "tpm-tis-device"; 915 + }.${pkgs.stdenv.hostPlatform.system} or (throw "Unsupported system for TPM2 emulation in QEMU")); 916 defaultText = '' 917 Based on the guest platform Linux system: 918
+2 -2
nixos/tests/stub-ld.nix
··· 45 ${if32 "machine.succeed('test -L /${libDir32}/${ldsoBasename32}')"} 46 47 with subtest("Try FHS executable"): 48 - machine.copy_from_host('${test-exec.${pkgs.system}}','test-exec') 49 machine.succeed('if test-exec/${exec-name} 2>outfile; then false; else [ $? -eq 127 ];fi') 50 machine.succeed('grep -qi nixos outfile') 51 - ${if32 "machine.copy_from_host('${test-exec.${pkgs32.system}}','test-exec32')"} 52 ${if32 "machine.succeed('if test-exec32/${exec-name} 2>outfile32; then false; else [ $? -eq 127 ];fi')"} 53 ${if32 "machine.succeed('grep -qi nixos outfile32')"} 54
··· 45 ${if32 "machine.succeed('test -L /${libDir32}/${ldsoBasename32}')"} 46 47 with subtest("Try FHS executable"): 48 + machine.copy_from_host('${test-exec.${pkgs.stdenv.hostPlatform.system}}','test-exec') 49 machine.succeed('if test-exec/${exec-name} 2>outfile; then false; else [ $? -eq 127 ];fi') 50 machine.succeed('grep -qi nixos outfile') 51 + ${if32 "machine.copy_from_host('${test-exec.${pkgs32.stdenv.hostPlatform.system}}','test-exec32')"} 52 ${if32 "machine.succeed('if test-exec32/${exec-name} 2>outfile32; then false; else [ $? -eq 127 ];fi')"} 53 ${if32 "machine.succeed('grep -qi nixos outfile32')"} 54