mirror of
https://github.com/samueldr/wip-pinebook-pro.git
synced 2024-11-27 05:19:44 +01:00
Add a way to build the UEFI iso
This commit is contained in:
parent
39788d0c83
commit
f0c875d646
2 changed files with 28 additions and 0 deletions
16
build-iso.sh
Executable file
16
build-iso.sh
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
set -u
|
||||||
|
PS4=" $ "
|
||||||
|
|
||||||
|
# Ugh, I would have liked to do it through a simpler `nix-build`, but as this
|
||||||
|
# needs to set `NIX_PATH` for use of `<nixpkgs/*>` imports, this is the better
|
||||||
|
# way to go.
|
||||||
|
|
||||||
|
set -x
|
||||||
|
exec env -i \
|
||||||
|
NIXPKGS_ALLOW_UNFREE=1 \
|
||||||
|
NIX_PATH="nixpkgs=channel:nixos-unstable" \
|
||||||
|
"$(command -v nix-build)" \
|
||||||
|
iso.nix -A config.system.build.isoImage "$@"
|
12
iso.nix
Normal file
12
iso.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
import <nixpkgs/nixos> {
|
||||||
|
configuration = {
|
||||||
|
imports = [
|
||||||
|
(
|
||||||
|
if builtins.currentSystem == "aarch64-linux"
|
||||||
|
then builtins.toPath (./. + "/configuration.nix")
|
||||||
|
else builtins.toPath (./. + "/with-cross.nix")
|
||||||
|
)
|
||||||
|
<nixpkgs/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix>
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue