Merge commit '92b7a814f26ee1d37e989431c18518c67285a332' into staging
This commit is contained in:
@@ -29,8 +29,23 @@ rec {
|
||||
platform = platforms.aarch64-multiplatform;
|
||||
};
|
||||
|
||||
armv5te-android-prebuilt = rec {
|
||||
config = "armv5tel-unknown-linux-androideabi";
|
||||
sdkVer = "21";
|
||||
platform = platforms.armv5te-android;
|
||||
useAndroidPrebuilt = true;
|
||||
};
|
||||
|
||||
armv7a-android-prebuilt = rec {
|
||||
config = "armv7a-unknown-linux-androideabi";
|
||||
sdkVer = "21";
|
||||
platform = platforms.armv7a-android;
|
||||
useAndroidPrebuilt = true;
|
||||
};
|
||||
|
||||
aarch64-android-prebuilt = rec {
|
||||
config = "aarch64-unknown-linux-android";
|
||||
sdkVer = "21";
|
||||
platform = platforms.aarch64-multiplatform;
|
||||
useAndroidPrebuilt = true;
|
||||
};
|
||||
|
||||
@@ -3,6 +3,9 @@ with import ./parse.nix { inherit lib; };
|
||||
with lib.attrsets;
|
||||
with lib.lists;
|
||||
|
||||
let abis_ = abis; in
|
||||
let abis = lib.mapAttrs (_: abi: builtins.removeAttrs abi [ "assertions" ]) abis_; in
|
||||
|
||||
rec {
|
||||
patterns = rec {
|
||||
isi686 = { cpu = cpuTypes.i686; };
|
||||
|
||||
@@ -68,17 +68,17 @@ rec {
|
||||
|
||||
cpuTypes = with significantBytes; setTypes types.openCpuType {
|
||||
arm = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv5tel = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv6m = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv6l = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv7a = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv7r = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv7m = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv7l = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv8a = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv8r = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
armv8m = { bits = 32; significantByte = littleEndian; family = "arm"; };
|
||||
aarch64 = { bits = 64; significantByte = littleEndian; family = "arm"; };
|
||||
armv5tel = { bits = 32; significantByte = littleEndian; family = "arm"; version = "5"; };
|
||||
armv6m = { bits = 32; significantByte = littleEndian; family = "arm"; version = "6"; };
|
||||
armv6l = { bits = 32; significantByte = littleEndian; family = "arm"; version = "6"; };
|
||||
armv7a = { bits = 32; significantByte = littleEndian; family = "arm"; version = "7"; };
|
||||
armv7r = { bits = 32; significantByte = littleEndian; family = "arm"; version = "7"; };
|
||||
armv7m = { bits = 32; significantByte = littleEndian; family = "arm"; version = "7"; };
|
||||
armv7l = { bits = 32; significantByte = littleEndian; family = "arm"; version = "7"; };
|
||||
armv8a = { bits = 32; significantByte = littleEndian; family = "arm"; version = "8"; };
|
||||
armv8r = { bits = 32; significantByte = littleEndian; family = "arm"; version = "8"; };
|
||||
armv8m = { bits = 32; significantByte = littleEndian; family = "arm"; version = "8"; };
|
||||
aarch64 = { bits = 64; significantByte = littleEndian; family = "arm"; version = "8"; };
|
||||
|
||||
i686 = { bits = 32; significantByte = littleEndian; family = "x86"; };
|
||||
x86_64 = { bits = 64; significantByte = littleEndian; family = "x86"; };
|
||||
@@ -200,7 +200,15 @@ rec {
|
||||
eabi = {};
|
||||
|
||||
androideabi = {};
|
||||
android = {};
|
||||
android = {
|
||||
assertions = [
|
||||
{ assertion = platform: !platform.isAarch32;
|
||||
message = ''
|
||||
The "android" ABI is not for 32-bit ARM. Use "androideabi" instead.
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
gnueabi = { float = "soft"; };
|
||||
gnueabihf = { float = "hard"; };
|
||||
@@ -287,7 +295,12 @@ rec {
|
||||
kernel = getKernel args.kernel;
|
||||
abi =
|
||||
/**/ if args ? abi then getAbi args.abi
|
||||
else if isLinux parsed then (if isAarch32 parsed then abis.gnueabi else abis.gnu)
|
||||
else if isLinux parsed then
|
||||
if isAarch32 parsed then
|
||||
if lib.versionAtLeast (parsed.cpu.version or "0") "6"
|
||||
then abis.gnueabihf
|
||||
else abis.gnueabi
|
||||
else abis.gnu
|
||||
else if isWindows parsed then abis.gnu
|
||||
else abis.unknown;
|
||||
};
|
||||
|
||||
@@ -245,7 +245,6 @@ rec {
|
||||
gcc = {
|
||||
arch = "armv6";
|
||||
fpu = "vfp";
|
||||
float = "hard";
|
||||
# TODO(@Ericson2314) what is this and is it a good idea? It was
|
||||
# used in some cross compilation examples but not others.
|
||||
#
|
||||
@@ -384,6 +383,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.
|
||||
|
||||
Reference in New Issue
Block a user