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: 870bb44a7db9
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: c674fa8eac30
Choose a head ref
  • 4 commits
  • 3 files changed
  • 2 contributors

Commits on May 11, 2018

  1. Copy the full SHA
    341794a View commit details
  2. Merge pull request #40379 from obsidiansystems/lib-platform-sort

    lib/systems: Sort platforms, and space CPUs
    Ericson2314 authored May 11, 2018
    Copy the full SHA
    62ccc23 View commit details
  3. Copy the full SHA
    e3f6c6d View commit details
  4. Merge pull request #40386 from obsidiansystems/lib-android-platforms

    lib: Add 32-bit Android platforms
    Ericson2314 authored May 11, 2018
    Copy the full SHA
    c674fa8 View commit details
Showing with 139 additions and 87 deletions.
  1. +13 −9 lib/systems/examples.nix
  2. +5 −0 lib/systems/parse.nix
  3. +121 −78 lib/systems/platforms.nix
22 changes: 13 additions & 9 deletions lib/systems/examples.nix
Original file line number Diff line number Diff line change
@@ -29,6 +29,18 @@ rec {
platform = platforms.aarch64-multiplatform;
};

armv5te-android-prebuilt = rec {
config = "armv5tel-unknown-linux-androideabi";
platform = platforms.armv5te-android;
useAndroidPrebuilt = true;
};

armv7a-android-prebuilt = rec {
config = "armv7a-unknown-linux-androideabi";
platform = platforms.armv7a-android;
useAndroidPrebuilt = true;
};

aarch64-android-prebuilt = rec {
config = "aarch64-unknown-linux-android";
platform = platforms.aarch64-multiplatform;
@@ -47,15 +59,7 @@ rec {

ben-nanonote = rec {
config = "mipsel-unknown-linux-uclibc";
platform = {
name = "ben_nanonote";
kernelMajor = "2.6";
kernelArch = "mips";
gcc = {
arch = "mips32";
float = "soft";
};
};
platform = platforms.ben_nanonote;
};

fuloongminipc = rec {
5 changes: 5 additions & 0 deletions lib/systems/parse.nix
Original file line number Diff line number Diff line change
@@ -79,15 +79,20 @@ rec {
armv8r = { bits = 32; significantByte = littleEndian; family = "arm"; };
armv8m = { bits = 32; significantByte = littleEndian; family = "arm"; };
aarch64 = { bits = 64; significantByte = littleEndian; family = "arm"; };

i686 = { bits = 32; significantByte = littleEndian; family = "x86"; };
x86_64 = { bits = 64; significantByte = littleEndian; family = "x86"; };

mips = { bits = 32; significantByte = bigEndian; family = "mips"; };
mipsel = { bits = 32; significantByte = littleEndian; family = "mips"; };
mips64 = { bits = 64; significantByte = bigEndian; family = "mips"; };
mips64el = { bits = 64; significantByte = littleEndian; family = "mips"; };

powerpc = { bits = 32; significantByte = bigEndian; family = "power"; };

riscv32 = { bits = 32; significantByte = littleEndian; family = "riscv"; };
riscv64 = { bits = 64; significantByte = littleEndian; family = "riscv"; };

wasm32 = { bits = 32; significantByte = littleEndian; family = "wasm"; };
wasm64 = { bits = 64; significantByte = littleEndian; family = "wasm"; };
};
199 changes: 121 additions & 78 deletions lib/systems/platforms.nix
Original file line number Diff line number Diff line change
@@ -20,6 +20,10 @@ rec {
kernelAutoModules = false;
};

##
## ARM
##

pogoplug4 = {
name = "pogoplug4";

@@ -372,84 +376,6 @@ rec {
kernelBaseConfig = "guruplug_defconfig";
};

fuloong2f_n32 = {
name = "fuloong2f_n32";
kernelMajor = "2.6";
kernelBaseConfig = "lemote2f_defconfig";
kernelArch = "mips";
kernelAutoModules = false;
kernelExtraConfig = ''
MIGRATION n
COMPACTION n
# nixos mounts some cgroup
CGROUPS y
BLK_DEV_RAM y
BLK_DEV_INITRD y
BLK_DEV_CRYPTOLOOP m
BLK_DEV_DM m
DM_CRYPT m
MD y
REISERFS_FS m
EXT4_FS m
USB_STORAGE_CYPRESS_ATACB m
IP_PNP y
IP_PNP_DHCP y
IP_PNP_BOOTP y
NFS_FS y
ROOT_NFS y
TUN m
NFS_V4 y
NFS_V4_1 y
NFS_FSCACHE y
NFSD m
NFSD_V2_ACL y
NFSD_V3 y
NFSD_V3_ACL y
NFSD_V4 y
# Fail to build
DRM n
SCSI_ADVANSYS n
USB_ISP1362_HCD n
SND_SOC n
SND_ALI5451 n
FB_SAVAGE n
SCSI_NSP32 n
ATA_SFF n
SUNGEM n
IRDA n
ATM_HE n
SCSI_ACARD n
BLK_DEV_CMD640_ENHANCED n
FUSE_FS m
# Needed for udev >= 150
SYSFS_DEPRECATED_V2 n
VGA_CONSOLE n
VT_HW_CONSOLE_BINDING y
SERIAL_8250_CONSOLE y
FRAMEBUFFER_CONSOLE y
EXT2_FS y
EXT3_FS y
REISERFS_FS y
MAGIC_SYSRQ y
# The kernel doesn't boot at all, with FTRACE
FTRACE n
'';
kernelTarget = "vmlinux";
gcc = {
arch = "loongson2f";
float = "hard";
abi = "n32";
};
};

beaglebone = armv7l-hf-multiplatform // {
name = "beaglebone";
kernelBaseConfig = "bb.org_defconfig";
@@ -458,6 +384,27 @@ rec {
kernelTarget = "zImage";
};

# https://developer.android.com/ndk/guides/abis#armeabi
armv5te-android = {
name = "armeabi";
gcc = {
arch = "armv5te";
float = "soft";
float-abi = "soft";
};
};

# https://developer.android.com/ndk/guides/abis#v7a
armv7a-android = {
name = "armeabi-v7a";
gcc = {
arch = "armv7-a";
float = "hard";
float-abi = "softfp";
fpu = "vfpv3-d16";
};
};

armv7l-hf-multiplatform = {
name = "armv7l-hf-multiplatform";
kernelMajor = "2.6"; # Using "2.6" enables 2.6 kernel syscalls in glibc.
@@ -537,6 +484,102 @@ rec {
};
};

##
## MIPS
##

ben_nanonote = {
name = "ben_nanonote";
kernelMajor = "2.6";
kernelArch = "mips";
gcc = {
arch = "mips32";
float = "soft";
};
};

fuloong2f_n32 = {
name = "fuloong2f_n32";
kernelMajor = "2.6";
kernelBaseConfig = "lemote2f_defconfig";
kernelArch = "mips";
kernelAutoModules = false;
kernelExtraConfig = ''
MIGRATION n
COMPACTION n
# nixos mounts some cgroup
CGROUPS y
BLK_DEV_RAM y
BLK_DEV_INITRD y
BLK_DEV_CRYPTOLOOP m
BLK_DEV_DM m
DM_CRYPT m
MD y
REISERFS_FS m
EXT4_FS m
USB_STORAGE_CYPRESS_ATACB m
IP_PNP y
IP_PNP_DHCP y
IP_PNP_BOOTP y
NFS_FS y
ROOT_NFS y
TUN m
NFS_V4 y
NFS_V4_1 y
NFS_FSCACHE y
NFSD m
NFSD_V2_ACL y
NFSD_V3 y
NFSD_V3_ACL y
NFSD_V4 y
# Fail to build
DRM n
SCSI_ADVANSYS n
USB_ISP1362_HCD n
SND_SOC n
SND_ALI5451 n
FB_SAVAGE n
SCSI_NSP32 n
ATA_SFF n
SUNGEM n
IRDA n
ATM_HE n
SCSI_ACARD n
BLK_DEV_CMD640_ENHANCED n
FUSE_FS m
# Needed for udev >= 150
SYSFS_DEPRECATED_V2 n
VGA_CONSOLE n
VT_HW_CONSOLE_BINDING y
SERIAL_8250_CONSOLE y
FRAMEBUFFER_CONSOLE y
EXT2_FS y
EXT3_FS y
REISERFS_FS y
MAGIC_SYSRQ y
# The kernel doesn't boot at all, with FTRACE
FTRACE n
'';
kernelTarget = "vmlinux";
gcc = {
arch = "loongson2f";
float = "hard";
abi = "n32";
};
};

##
## Other
##

riscv-multiplatform = bits: {
name = "riscv-multiplatform";
kernelArch = "riscv";