Support distinct filesystem configs for each architecture

This commit is contained in:
Jeremy Soller 2022-08-26 11:26:05 -06:00
parent 08a98b8b72
commit 1f339004d6
No known key found for this signature in database
GPG key ID: 87F211AF2BE4C2FE
11 changed files with 201 additions and 6 deletions

View file

@ -7,6 +7,8 @@ ARCH?=x86_64
INSTALLER_FLAGS?=--cookbook=cookbook
## Enabled to use binary prefix (much faster)
PREFIX_BINARY?=1
## Select filesystem config
FILESYSTEM_CONFIG?=config/$(ARCH)/desktop.toml
## Filesystem size in MB (256 is the default)
FILESYSTEM_SIZE?=256
## Flags to pass to redoxfs-mkfs. Add --encrypt to set up disk encryption

View file

@ -1,4 +1,4 @@
build/filesystem.bin: prefix filesystem.toml
build/filesystem.bin: prefix $(FILESYSTEM_CONFIG)
$(HOST_CARGO) build --manifest-path cookbook/Cargo.toml --release
$(HOST_CARGO) build --manifest-path installer/Cargo.toml --release
$(HOST_CARGO) build --manifest-path redoxfs/Cargo.toml --release
@ -13,8 +13,8 @@ build/filesystem.bin: prefix filesystem.toml
redoxfs/target/release/redoxfs $@.partial build/filesystem/
sleep 2
pgrep redoxfs
$(INSTALLER) -c filesystem.toml build/filesystem/
cp -v filesystem.toml build/filesystem/filesystem.toml
$(INSTALLER) -c $(FILESYSTEM_CONFIG) build/filesystem/
cp -v $(FILESYSTEM_CONFIG) build/filesystem/filesystem.toml
mkdir -pv build/filesystem/pkg
cp -v cookbook/build/id_ed25519.pub.toml build/filesystem/pkg/id_ed25519.pub.toml
sync