feat: inital support for x86_64-linux

This commit is contained in:
isabel roses 2024-06-13 22:37:53 +01:00
parent 9c29945531
commit e068db6843
Signed by: isabelroses
GPG key ID: 08A97B9A107A1798
69 changed files with 1155 additions and 968 deletions

View file

@ -4,11 +4,7 @@
modules = import ./src; modules = import ./src;
result = lib.modules.run { result = lib.modules.run {
modules = modules = (builtins.attrValues modules) ++ [{config.aux.system = system;}];
(builtins.attrValues modules)
++ [
{config.aux.system = system;}
];
}; };
in in
result.config.exports.resolved.packages result.config.exports.resolved.packages

View file

@ -3,10 +3,10 @@
"lib": { "lib": {
"locked": { "locked": {
"dir": "lib", "dir": "lib",
"dirtyRev": "f24f0876a9103c7adb8120ce9709fb90c73f2a7c-dirty", "dirtyRev": "9c29945531c58ad81f05cd1f4958c8894a733216-dirty",
"dirtyShortRev": "f24f087-dirty", "dirtyShortRev": "9c29945-dirty",
"lastModified": 1718105966, "lastModified": 1718255029,
"narHash": "sha256-L68G29+bPmwZSERg3VYXdfont/w+mssmWnrs6tyBijk=", "narHash": "sha256-cyVYhw84W1s8u305BJR0YoNtdvCuRCd5DT+G3v3Lo4E=",
"type": "git", "type": "git",
"url": "file:../?dir=lib" "url": "file:../?dir=lib"
}, },

View file

@ -14,24 +14,18 @@
forEachSystem = lib.attrs.generate [ forEachSystem = lib.attrs.generate [
"i686-linux" "i686-linux"
"x86_64-linux"
]; ];
in { in {
extras = let extras = let
result = lib.modules.run { result = lib.modules.run {modules = builtins.attrValues modules;};
modules =
builtins.attrValues modules;
};
in in
result.config.exports.resolved.extras; result.config.exports.resolved.extras;
packages = forEachSystem ( packages = forEachSystem (
system: let system: let
result = lib.modules.run { result = lib.modules.run {
modules = modules = (builtins.attrValues modules) ++ [{config.aux.system = system;}];
(builtins.attrValues modules)
++ [
{config.aux.system = system;}
];
}; };
in in
result.config.exports.resolved.packages result.config.exports.resolved.packages

View file

@ -2,7 +2,7 @@
lib, lib,
config, config,
}: let }: let
system = config.aux.system; inherit (config.aux) system;
architecture = architecture =
if system == "x86_64-linux" if system == "x86_64-linux"

View file

@ -35,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -47,7 +50,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.kaem = { aux.foundation.stages.stage0.kaem = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "kaem"; pname = "kaem";
version = "1.6.0"; version = "1.6.0";
@ -64,7 +68,8 @@ in {
kaemUnwrapped = kaem-unwrapped.package; kaemUnwrapped = kaem-unwrapped.package;
PATH = lib.paths.bin [mescc-tools-extra.package]; PATH = lib.paths.bin [mescc-tools-extra.package];
}); }
);
}; };
}; };
} }

View file

@ -43,7 +43,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -55,7 +58,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.mescc-tools-extra = { aux.foundation.stages.stage0.mescc-tools-extra = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "mescc-tools-tools"; pname = "mescc-tools-tools";
version = "1.6.0"; version = "1.6.0";
@ -75,7 +79,8 @@ in {
m2libcOS = "linux"; m2libcOS = "linux";
m2libcArch = architecture.m2libc; m2libcArch = architecture.m2libc;
mesccTools = mescc-tools.package; mesccTools = mescc-tools.package;
}); }
);
}; };
}; };
} }

View file

@ -129,7 +129,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -141,7 +144,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.mescc-tools = { aux.foundation.stages.stage0.mescc-tools = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "mescc-tools"; pname = "mescc-tools";
version = "1.6.0"; version = "1.6.0";
@ -176,7 +180,8 @@ in {
cp = getExtraUtil "cp"; cp = getExtraUtil "cp";
chmod = getExtraUtil "chmod"; chmod = getExtraUtil "chmod";
replace = getExtraUtil "replace"; replace = getExtraUtil "replace";
}); }
);
}; };
}; };
} }

View file

@ -41,7 +41,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -66,7 +69,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.hex0 = { aux.foundation.stages.stage0.hex0 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "hex0"; pname = "hex0";
version = "1.6.0"; version = "1.6.0";
@ -82,7 +86,8 @@ in {
outputHashMode = "recursive"; outputHashMode = "recursive";
outputHashAlgo = "sha256"; outputHashAlgo = "sha256";
outputHash = cfg.hash; outputHash = cfg.hash;
}); }
);
hash = lib.modules.overrides.default ( hash = lib.modules.overrides.default (
if system == "x86_64-linux" if system == "x86_64-linux"
@ -94,12 +99,14 @@ in {
else null else null
); );
executable = lib.modules.overrides.default (import <nix/fetchurl.nix> { executable = lib.modules.overrides.default (
import <nix/fetchurl.nix> {
name = "hex0-seed"; name = "hex0-seed";
url = "https://github.com/oriansj/bootstrap-seeds/raw/b1263ff14a17835f4d12539226208c426ced4fba/POSIX/${architecture}/hex0-seed"; url = "https://github.com/oriansj/bootstrap-seeds/raw/b1263ff14a17835f4d12539226208c426ced4fba/POSIX/${architecture}/hex0-seed";
executable = true; executable = true;
hash = cfg.hash; hash = cfg.hash;
}); }
);
}; };
}; };
} }

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -46,7 +49,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.hex1 = { aux.foundation.stages.stage0.hex1 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "hex1"; pname = "hex1";
version = "1.6.0"; version = "1.6.0";
@ -58,7 +62,8 @@ in {
"${sources.base}/hex1_${architecture.base}.hex0" "${sources.base}/hex1_${architecture.base}.hex0"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -35,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -47,7 +50,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.hex2-0 = { aux.foundation.stages.stage0.hex2-0 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "hex2-0"; pname = "hex2-0";
version = "1.6.0"; version = "1.6.0";
@ -59,7 +63,8 @@ in {
"${sources.base}/hex2_${architecture.base}.hex1" "${sources.base}/hex2_${architecture.base}.hex1"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -36,7 +36,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -48,7 +51,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.catm = { aux.foundation.stages.stage0.catm = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "catm"; pname = "catm";
version = "1.6.0"; version = "1.6.0";
@ -69,7 +73,8 @@ in {
"${sources.base}/catm_${architecture.base}.hex2" "${sources.base}/catm_${architecture.base}.hex2"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -36,7 +36,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -48,7 +51,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.M0 = { aux.foundation.stages.stage0.M0 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "M0"; pname = "M0";
version = "1.6.0"; version = "1.6.0";
@ -75,7 +79,8 @@ in {
M0_hex2-0 M0_hex2-0
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -37,7 +37,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -49,7 +52,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.cc_arch = { aux.foundation.stages.stage0.cc_arch = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "cc_arch"; pname = "cc_arch";
version = "1.6.0"; version = "1.6.0";
@ -89,7 +93,8 @@ in {
cc_arch1_hex2-0 cc_arch1_hex2-0
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -38,7 +38,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -50,7 +53,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.M2 = { aux.foundation.stages.stage0.M2 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "M2"; pname = "M2";
version = "1.6.0"; version = "1.6.0";
@ -140,7 +144,8 @@ in {
M2_hex2-0' M2_hex2-0'
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -39,7 +39,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -51,7 +54,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.blood-elf = { aux.foundation.stages.stage0.blood-elf = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "blood-elf"; pname = "blood-elf";
version = "1.6.0"; version = "1.6.0";
@ -130,7 +134,8 @@ in {
blood-elf_hex2-0' blood-elf_hex2-0'
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -40,7 +40,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -52,7 +55,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.M1-0 = { aux.foundation.stages.stage0.M1-0 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "M1-0"; pname = "M1-0";
version = "1.6.0"; version = "1.6.0";
@ -155,7 +159,8 @@ in {
M1-macro-0_hex2-0' M1-macro-0_hex2-0'
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -41,7 +41,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -53,7 +56,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.hex2-1 = { aux.foundation.stages.stage0.hex2-1 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "hex2-1"; pname = "hex2-1";
version = "1.6.0"; version = "1.6.0";
@ -174,7 +178,8 @@ in {
hex2_linker_hex2' hex2_linker_hex2'
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -42,7 +42,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -54,7 +57,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.M1 = { aux.foundation.stages.stage0.M1 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "M1"; pname = "M1";
version = "1.6.0"; version = "1.6.0";
@ -180,7 +184,8 @@ in {
"-o" "-o"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -41,7 +41,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -53,7 +56,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.hex2 = { aux.foundation.stages.stage0.hex2 = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "hex2"; pname = "hex2";
version = "1.6.0"; version = "1.6.0";
@ -181,7 +185,8 @@ in {
"-o" "-o"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -41,7 +41,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -53,7 +56,8 @@ in {
config = { config = {
aux.foundation.stages.stage0.kaem-unwrapped = { aux.foundation.stages.stage0.kaem-unwrapped = {
package = lib.modules.overrides.default (builders.raw.build { package = lib.modules.overrides.default (
builders.raw.build {
pname = "kaem-unwrapped"; pname = "kaem-unwrapped";
version = "1.6.0"; version = "1.6.0";
@ -183,7 +187,8 @@ in {
"-o" "-o"
(builtins.placeholder "out") (builtins.placeholder "out")
]; ];
}); }
);
}; };
}; };
} }

View file

@ -32,7 +32,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.bash = { options.aux.foundation.stages.stage1.bash = {
meta = { meta = {
@ -37,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -34,7 +34,10 @@ in {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
# TODO: Support more platforms. # TODO: Support more platforms.
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.coreutils = { options.aux.foundation.stages.stage1.coreutils = {
meta = { meta = {
@ -37,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.gawk = { options.aux.foundation.stages.stage1.gawk = {
meta = { meta = {
@ -37,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -39,7 +39,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -32,7 +32,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.gnumake = { options.aux.foundation.stages.stage1.gnumake = {
meta = { meta = {
@ -37,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -32,7 +32,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };
@ -118,13 +121,8 @@ in {
]; ];
objects = objects =
builtins.map builtins.map (
( value: builtins.replaceStrings [".c"] [".o"] (builtins.baseNameOf value)
value:
builtins.replaceStrings
[".c"]
[".o"]
(builtins.baseNameOf value)
) )
sources; sources;
in in
@ -134,9 +132,7 @@ in {
meta = cfg.meta; meta = cfg.meta;
src = cfg.src; src = cfg.src;
deps.build.host = [ deps.build.host = [stage1.tinycc.mes.compiler.package];
stage1.tinycc.mes.compiler.package
];
script = '' script = ''
# Unpack # Unpack

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.gnused = { options.aux.foundation.stages.stage1.gnused = {
meta = { meta = {
@ -37,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -38,7 +38,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -32,7 +32,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -10,9 +10,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
stage2 = config.aux.foundation.stages.stage2; stage2 = config.aux.foundation.stages.stage2;
in { in {
includes = [ includes = [./devtools.nix];
./devtools.nix
];
options.aux.foundation.stages.stage1.heirloom = { options.aux.foundation.stages.stage1.heirloom = {
meta = { meta = {
@ -48,7 +46,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -54,7 +54,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };
}; };

View file

@ -27,7 +27,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };
@ -79,11 +82,9 @@ in {
sources = import ./sources.nix; sources = import ./sources.nix;
files = files = lib.strings.concatMapSep " " (getSourcePath ".o") (
lib.strings.concatMapSep builtins.map compile sources.x86.linux.mescc.mes
" " );
(getSourcePath ".o")
(builtins.map compile sources.x86.linux.mescc.mes);
in in
builders.kaem.build { builders.kaem.build {
name = "mes-${stage1.mes.version}"; name = "mes-${stage1.mes.version}";

View file

@ -32,7 +32,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };
@ -57,9 +60,7 @@ in {
meta = cfg.meta; meta = cfg.meta;
deps.build.host = [ deps.build.host = [stage1.ln-boot.package];
stage1.ln-boot.package
];
script = '' script = ''
cd ${stage1.mes.libs.prefix} cd ${stage1.mes.libs.prefix}

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };
@ -199,11 +202,13 @@ in {
libc-mini = createLib "libc-mini" sources.x86.linux.mescc.libc_mini; libc-mini = createLib "libc-mini" sources.x86.linux.mescc.libc_mini;
libmescc = createLib "libmescc" sources.x86.linux.mescc.libmescc; libmescc = createLib "libmescc" sources.x86.linux.mescc.libmescc;
libc = createLib "libc" sources.x86.linux.mescc.libc; libc = createLib "libc" sources.x86.linux.mescc.libc;
libc_tcc = createLib "libc+tcc" (sources.x86.linux.mescc.libc_tcc libc_tcc = createLib "libc+tcc" (
sources.x86.linux.mescc.libc_tcc
++ [ ++ [
# We need `symlink` support for `ln-boot` to work. # We need `symlink` support for `ln-boot` to work.
"lib/linux/symlink.c" "lib/linux/symlink.c"
]); ]
);
in in
builders.kaem.build { builders.kaem.build {
name = "mes-m2-libs-${stage1.mes.version}"; name = "mes-m2-libs-${stage1.mes.version}";

View file

@ -131,7 +131,6 @@ in {
# Install # Install
make install make install
cp ${stage1.tinycc.mes.libs.package}/lib/libtcc1.a $out/lib cp ${stage1.tinycc.mes.libs.package}/lib/libtcc1.a $out/lib
''; '';
}; };
}; };

View file

@ -9,9 +9,7 @@
stage1 = config.aux.foundation.stages.stage1; stage1 = config.aux.foundation.stages.stage1;
in { in {
includes = [ includes = [./boot.nix];
./boot.nix
];
options.aux.foundation.stages.stage1.musl = { options.aux.foundation.stages.stage1.musl = {
meta = { meta = {
@ -38,7 +36,10 @@ in {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
# TODO: Support more platforms. # TODO: Support more platforms.
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86-64_linux"
];
}; };
}; };

View file

@ -35,7 +35,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"i686-linux"
"x86_64-linux"
];
}; };
}; };

View file

@ -38,7 +38,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -36,7 +36,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };
@ -64,9 +67,7 @@ in {
}; };
package = let package = let
patches = [ patches = [./patches/busybox-in-store.patch];
./patches/busybox-in-store.patch
];
busyboxConfig = [ busyboxConfig = [
"CC=musl-gcc" "CC=musl-gcc"

View file

@ -34,7 +34,10 @@ in {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
# TODO: Support more platforms. # TODO: Support more platforms.
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
mainProgram = lib.options.create { mainProgram = lib.options.create {

View file

@ -33,7 +33,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -34,7 +34,10 @@ in {
platforms = lib.options.create { platforms = lib.options.create {
type = lib.types.list.of lib.types.string; type = lib.types.list.of lib.types.string;
description = "Platforms the package supports."; description = "Platforms the package supports.";
default.value = ["i686-linux"]; default.value = [
"x86_64-linux"
"i686-linux"
];
}; };
}; };

View file

@ -2,7 +2,7 @@
options.aux = { options.aux = {
system = lib.options.create { system = lib.options.create {
type = lib.types.string; type = lib.types.string;
default.value = "i686-linux"; default.value = "x86_64-linux";
description = '' description = ''
The system to build packages for. This value can be provided as either The system to build packages for. This value can be provided as either
`config.aux.system` or by setting the `system` argument for modules. `config.aux.system` or by setting the `system` argument for modules.