Skip to content
This repository was archived by the owner on Apr 12, 2021. It is now read-only.
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: c7be9f247aaa
Choose a base ref
...
head repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 45cd6090d9a6
Choose a head ref
  • 2 commits
  • 7 files changed
  • 2 contributors

Commits on May 10, 2018

  1. treewide: Get rid of *Platform.arch

    Use `parsed.cpu.name` or `platform.gcc.arch` instead.
    Ericson2314 committed May 10, 2018
    Copy the full SHA
    a02be2b View commit details
  2. Merge pull request #40272 from obsidiansystems/lib-platform-simplify-…

    …18.03
    
    treewide: Get rid of `*Platform.arch`
    Ericson2314 authored May 10, 2018
    Copy the full SHA
    45cd609 View commit details
12 changes: 1 addition & 11 deletions lib/systems/examples.nix
Original file line number Diff line number Diff line change
@@ -11,36 +11,31 @@ rec {

sheevaplug = rec {
config = "armv5tel-unknown-linux-gnueabi";
arch = "armv5tel";
float = "soft";
platform = platforms.sheevaplug;
};

raspberryPi = rec {
config = "armv6l-unknown-linux-gnueabihf";
arch = "armv6l";
float = "hard";
fpu = "vfp";
platform = platforms.raspberrypi;
};

armv7l-hf-multiplatform = rec {
config = "arm-unknown-linux-gnueabihf";
arch = "armv7-a";
config = "armv7a-unknown-linux-gnueabihf";
float = "hard";
fpu = "vfpv3-d16";
platform = platforms.armv7l-hf-multiplatform;
};

aarch64-multiplatform = rec {
config = "aarch64-unknown-linux-gnu";
arch = "aarch64";
platform = platforms.aarch64-multiplatform;
};

aarch64-android-prebuilt = rec {
config = "aarch64-unknown-linux-android";
arch = "aarch64";
platform = platforms.aarch64-multiplatform;
useAndroidPrebuilt = true;
};
@@ -51,15 +46,13 @@ rec {
};

pogoplug4 = rec {
arch = "armv5tel";
config = "armv5tel-unknown-linux-gnueabi";
float = "soft";
platform = platforms.pogoplug4;
};

ben-nanonote = rec {
config = "mipsel-unknown-linux-uclibc";
arch = "mips";
float = "soft";
platform = {
name = "ben_nanonote";
@@ -73,7 +66,6 @@ rec {

fuloongminipc = rec {
config = "mipsel-unknown-linux-gnu";
arch = "mips";
float = "hard";
platform = platforms.fuloong2f_n32;
};
@@ -122,7 +114,6 @@ rec {
# 32 bit mingw-w64
mingw32 = {
config = "i686-pc-mingw32";
arch = "x86"; # Irrelevant
libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain
platform = {};
};
@@ -131,7 +122,6 @@ rec {
mingwW64 = {
# That's the triplet they use in the mingw-w64 docs.
config = "x86_64-pc-mingw32";
arch = "x86_64"; # Irrelevant
libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain
platform = {};
};
2 changes: 1 addition & 1 deletion pkgs/applications/video/omxplayer/default.nix
Original file line number Diff line number Diff line change
@@ -52,7 +52,7 @@ let
"--cross-prefix=${stdenv.cc.targetPrefix}"
"--enable-cross-compile"
"--target_os=linux"
"--arch=${hostPlatform.arch}"
"--arch=${hostPlatform.parsed.cpu.name}"
];
};

2 changes: 1 addition & 1 deletion pkgs/development/libraries/ffmpeg-full/default.nix
Original file line number Diff line number Diff line change
@@ -442,7 +442,7 @@ stdenv.mkDerivation rec {
"--cross-prefix=${stdenv.cc.targetPrefix}"
"--enable-cross-compile"
"--target_os=${hostPlatform.parsed.kernel.name}"
"--arch=${hostPlatform.arch}"
"--arch=${hostPlatform.parsed.cpu.name}"
];
};

2 changes: 1 addition & 1 deletion pkgs/development/libraries/ffmpeg/generic.nix
Original file line number Diff line number Diff line change
@@ -176,7 +176,7 @@ stdenv.mkDerivation rec {
"--cross-prefix=${stdenv.cc.targetPrefix}"
"--enable-cross-compile"
"--target_os=${hostPlatform.parsed.kernel.name}"
"--arch=${hostPlatform.arch}"
"--arch=${hostPlatform.parsed.cpu.name}"
];
};

4 changes: 3 additions & 1 deletion pkgs/development/libraries/fontconfig/2.10.nix
Original file line number Diff line number Diff line change
@@ -24,7 +24,9 @@ stdenv.mkDerivation rec {
];

# We should find a better way to access the arch reliably.
crossArch = hostPlatform.arch or null;
crossArch = if stdenv.hostPlatform != stdenv.buildPlatform
then hostPlatform.parsed.cpu.name
else null;

preConfigure = ''
if test -n "$crossConfig"; then
4 changes: 3 additions & 1 deletion pkgs/development/libraries/fontconfig/default.nix
Original file line number Diff line number Diff line change
@@ -57,7 +57,9 @@ stdenv.mkDerivation rec {
];

# We should find a better way to access the arch reliably.
crossArch = hostPlatform.arch or null;
crossArch = if stdenv.hostPlatform != stdenv.buildPlatform
then hostPlatform.parsed.cpu.name
else null;

preConfigure = ''
if test -n "$crossConfig"; then
2 changes: 1 addition & 1 deletion pkgs/development/libraries/libav/default.nix
Original file line number Diff line number Diff line change
@@ -118,7 +118,7 @@ let
"--cross-prefix=${stdenv.cc.targetPrefix}"
"--enable-cross-compile"
"--target_os=linux"
"--arch=${hostPlatform.arch}"
"--arch=${hostPlatform.parsed.cpu.name}"
];
};