-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
1668 lines (1509 loc) · 81.8 KB
/
Makefile
File metadata and controls
1668 lines (1509 loc) · 81.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# SPDX-License-Identifier: AGPL-3.0-or-later
# Copyright (C) 2024-2026 Jason Ricca
# CambiOS Makefile - Build kernel and Limine bootable ISO
#
# Usage:
# make all - Build kernel + ISO
# make run - Build + run in QEMU (BIOS)
# make run-uefi - Build + run in QEMU (UEFI)
# make clean - Remove build artifacts
# make test - Run unit tests
#
# Signing modes:
# make run # YubiKey signing (default, requires CAMBIO_SIGN_PIN)
# make run SIGN_MODE=seed # Seed-based signing (CI/testing)
# CAMBIO_SIGN_PIN=123456 make run # YubiKey with PIN via env var
KERNEL := target/x86_64-unknown-none/release/cambios_microkernel
ISO := cambios.iso
LIMINE_DIR := $(HOME)/.cache/cambios/limine
LIMINE_BRANCH := v8.x-binary
LIMINE_REPO := https://github.com/limine-bootloader/limine.git
# User-space ELF binaries (x86_64)
USER_ELF := user/hello.elf
USER_SRC := user/hello.S
USER_LD := user/user.ld
FS_SERVICE_DIR := user/fs-service
FS_SERVICE_ELF := $(FS_SERVICE_DIR)/target/x86_64-unknown-none/release/cambios-fs-service
KS_SERVICE_DIR := user/key-store-service
KS_SERVICE_ELF := $(KS_SERVICE_DIR)/target/x86_64-unknown-none/release/cambios-key-store-service
NET_DRIVER_DIR := user/virtio-net
NET_DRIVER_ELF := $(NET_DRIVER_DIR)/target/x86_64-unknown-none/release/cambios-virtio-net
BLK_DRIVER_DIR := user/virtio-blk
BLK_DRIVER_ELF := $(BLK_DRIVER_DIR)/target/x86_64-unknown-none/release/cambios-virtio-blk
USB_HOST_DIR := user/usb-host
USB_HOST_ELF := $(USB_HOST_DIR)/target/x86_64-unknown-none/release/cambios-usb-host
CCID_DIR := user/ccid
CCID_ELF := $(CCID_DIR)/target/x86_64-unknown-none/release/cambios-ccid
I219_DRIVER_DIR := user/i219-net
I219_DRIVER_ELF := $(I219_DRIVER_DIR)/target/x86_64-unknown-none/release/cambios-i219-net
UDP_STACK_DIR := user/udp-stack
UDP_STACK_ELF := $(UDP_STACK_DIR)/target/x86_64-unknown-none/release/cambios-udp-stack
SHELL_DIR := user/shell
SHELL_ELF := $(SHELL_DIR)/target/x86_64-unknown-none/release/cambios-shell
POLICY_SERVICE_DIR := user/policy-service
POLICY_SERVICE_ELF := $(POLICY_SERVICE_DIR)/target/x86_64-unknown-none/release/cambios-policy-service
FB_DEMO_DIR := user/fb-demo
FB_DEMO_ELF := $(FB_DEMO_DIR)/target/x86_64-unknown-none/release/cambios-fb-demo
COMPOSITOR_DIR := user/compositor
COMPOSITOR_ELF := $(COMPOSITOR_DIR)/target/x86_64-unknown-none/release/cambios-compositor
SCANOUT_LIMINE_DIR := user/scanout-limine
SCANOUT_LIMINE_ELF := $(SCANOUT_LIMINE_DIR)/target/x86_64-unknown-none/release/cambios-scanout-limine
SCANOUT_VGPU_DIR := user/scanout-virtio-gpu
SCANOUT_VGPU_ELF := $(SCANOUT_VGPU_DIR)/target/x86_64-unknown-none/release/cambios-scanout-virtio-gpu
VIRTIO_INPUT_DIR := user/virtio-input
VIRTIO_INPUT_ELF := $(VIRTIO_INPUT_DIR)/target/x86_64-unknown-none/release/cambios-virtio-input
HELLO_WINDOW_DIR := user/hello-window
HELLO_WINDOW_ELF := $(HELLO_WINDOW_DIR)/target/x86_64-unknown-none/release/cambios-hello-window
TREE_DIR := user/tree
TREE_ELF := $(TREE_DIR)/target/x86_64-unknown-none/release/cambios-tree
WORM_DIR := user/worm
WORM_ELF := $(WORM_DIR)/target/x86_64-unknown-none/release/cambios-worm
PING_DIR := user/ping
PING_ELF := $(PING_DIR)/target/x86_64-unknown-none/release/cambios-ping
SPROUTY_DIR := user/sprouty
SPROUTY_ELF := $(SPROUTY_DIR)/target/x86_64-unknown-none/release/cambios-sprouty
TERMINAL_WINDOW_DIR := user/terminal-window
TERMINAL_WINDOW_ELF := $(TERMINAL_WINDOW_DIR)/target/x86_64-unknown-none/release/cambios-terminal-window
AUDIT_TAIL_DIR := user/audit-tail
AUDIT_TAIL_ELF := $(AUDIT_TAIL_DIR)/target/x86_64-unknown-none/release/cambios-audit-tail
FDE_MOUNT_DIR := user/fde-mount
FDE_MOUNT_ELF := $(FDE_MOUNT_DIR)/target/x86_64-unknown-none/release/cambios-fde-mount
# User-space ELF binaries (RISC-V)
FS_SERVICE_ELF_RISCV64 := $(FS_SERVICE_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-fs-service
KS_SERVICE_ELF_RISCV64 := $(KS_SERVICE_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-key-store-service
BLK_DRIVER_ELF_RISCV64 := $(BLK_DRIVER_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-virtio-blk
USB_HOST_ELF_RISCV64 := $(USB_HOST_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-usb-host
CCID_ELF_RISCV64 := $(CCID_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-ccid
NET_DRIVER_ELF_RISCV64 := $(NET_DRIVER_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-virtio-net
UDP_STACK_ELF_RISCV64 := $(UDP_STACK_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-udp-stack
SHELL_ELF_RISCV64 := $(SHELL_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-shell
POLICY_SERVICE_ELF_RISCV64 := $(POLICY_SERVICE_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-policy-service
# RISC-V initrd artifacts
INITRD_RISCV64 := initrd-riscv64.img
MKINITRD_DIR := tools/mkinitrd
MKINITRD := $(MKINITRD_DIR)/target/aarch64-apple-darwin/release/mkinitrd
# User-space ELF binaries (AArch64)
USER_ELF_AARCH64 := user/hello-aarch64.elf
USER_SRC_AARCH64 := user/hello-aarch64.S
USER_LD_AARCH64 := user/user-aarch64.ld
FS_SERVICE_ELF_AARCH64 := $(FS_SERVICE_DIR)/target/aarch64-unknown-none/release/cambios-fs-service
KS_SERVICE_ELF_AARCH64 := $(KS_SERVICE_DIR)/target/aarch64-unknown-none/release/cambios-key-store-service
NET_DRIVER_ELF_AARCH64 := $(NET_DRIVER_DIR)/target/aarch64-unknown-none/release/cambios-virtio-net
BLK_DRIVER_ELF_AARCH64 := $(BLK_DRIVER_DIR)/target/aarch64-unknown-none/release/cambios-virtio-blk
USB_HOST_ELF_AARCH64 := $(USB_HOST_DIR)/target/aarch64-unknown-none/release/cambios-usb-host
CCID_ELF_AARCH64 := $(CCID_DIR)/target/aarch64-unknown-none/release/cambios-ccid
I219_DRIVER_ELF_AARCH64 := $(I219_DRIVER_DIR)/target/aarch64-unknown-none/release/cambios-i219-net
UDP_STACK_ELF_AARCH64 := $(UDP_STACK_DIR)/target/aarch64-unknown-none/release/cambios-udp-stack
SHELL_ELF_AARCH64 := $(SHELL_DIR)/target/aarch64-unknown-none/release/cambios-shell
POLICY_SERVICE_ELF_AARCH64 := $(POLICY_SERVICE_DIR)/target/aarch64-unknown-none/release/cambios-policy-service
FB_DEMO_ELF_AARCH64 := $(FB_DEMO_DIR)/target/aarch64-unknown-none/release/cambios-fb-demo
COMPOSITOR_ELF_AARCH64 := $(COMPOSITOR_DIR)/target/aarch64-unknown-none/release/cambios-compositor
SCANOUT_LIMINE_ELF_AARCH64 := $(SCANOUT_LIMINE_DIR)/target/aarch64-unknown-none/release/cambios-scanout-limine
SCANOUT_VGPU_ELF_AARCH64 := $(SCANOUT_VGPU_DIR)/target/aarch64-unknown-none/release/cambios-scanout-virtio-gpu
VIRTIO_INPUT_ELF_AARCH64 := $(VIRTIO_INPUT_DIR)/target/aarch64-unknown-none/release/cambios-virtio-input
HELLO_WINDOW_ELF_AARCH64 := $(HELLO_WINDOW_DIR)/target/aarch64-unknown-none/release/cambios-hello-window
TREE_ELF_AARCH64 := $(TREE_DIR)/target/aarch64-unknown-none/release/cambios-tree
WORM_ELF_AARCH64 := $(WORM_DIR)/target/aarch64-unknown-none/release/cambios-worm
PING_ELF_AARCH64 := $(PING_DIR)/target/aarch64-unknown-none/release/cambios-ping
SPROUTY_ELF_AARCH64 := $(SPROUTY_DIR)/target/aarch64-unknown-none/release/cambios-sprouty
TERMINAL_WINDOW_ELF_AARCH64 := $(TERMINAL_WINDOW_DIR)/target/aarch64-unknown-none/release/cambios-terminal-window
AUDIT_TAIL_ELF_AARCH64 := $(AUDIT_TAIL_DIR)/target/aarch64-unknown-none/release/cambios-audit-tail
FDE_MOUNT_ELF_AARCH64 := $(FDE_MOUNT_DIR)/target/aarch64-unknown-none/release/cambios-fde-mount
# User-space ELF binaries (RISC-V) — scanout + input extension for Scanout-4.c
SCANOUT_VGPU_ELF_RISCV64 := $(SCANOUT_VGPU_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-scanout-virtio-gpu
VIRTIO_INPUT_ELF_RISCV64 := $(VIRTIO_INPUT_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-virtio-input
# User-space ELF binaries (RISC-V) — GUI stack (ADR-011). libgui is
# arch-agnostic; each app ships a link-riscv64.ld matching the
# virtio-net riscv64 shape. Runtime requires kernel ECAM PCI + a
# virtio-gpu-pci QEMU device; build infra lands first so the cross-
# arch port is unblocked.
COMPOSITOR_ELF_RISCV64 := $(COMPOSITOR_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-compositor
HELLO_WINDOW_ELF_RISCV64 := $(HELLO_WINDOW_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-hello-window
TREE_ELF_RISCV64 := $(TREE_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-tree
WORM_ELF_RISCV64 := $(WORM_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-worm
PING_ELF_RISCV64 := $(PING_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-ping
SPROUTY_ELF_RISCV64 := $(SPROUTY_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-sprouty
TERMINAL_WINDOW_ELF_RISCV64 := $(TERMINAL_WINDOW_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-terminal-window
AUDIT_TAIL_ELF_RISCV64 := $(AUDIT_TAIL_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-audit-tail
FDE_MOUNT_ELF_RISCV64 := $(FDE_MOUNT_DIR)/target/riscv64gc-unknown-none-elf/release/cambios-fde-mount
# ELF signing tool
SIGN_ELF_DIR := tools/sign-elf
SIGN_ELF := $(SIGN_ELF_DIR)/target/aarch64-apple-darwin/release/sign-elf
# Dev-PIV keypair generator (host-side). Derives Ed25519+X25519 keys from a
# persistent per-developer seed; writes dev_bootstrap_pubkey.bin (consumed by
# the kernel under --features dev-piv) and user/key-store-service/
# dev_piv_secret.bin (consumed by SwPivBackend under --features dev-piv).
GEN_DEV_PIV_DIR := tools/gen-dev-piv-keys
GEN_DEV_PIV := $(GEN_DEV_PIV_DIR)/target/aarch64-apple-darwin/release/gen-dev-piv-keys
DEV_BOOTSTRAP_PUBKEY := dev_bootstrap_pubkey.bin
DEV_PIV_SECRET := user/key-store-service/dev_piv_secret.bin
# Format-volume host tool (stream A A-v.e). Writes a fresh signed
# ADR-032 § 4 volume header to a raw disk image file using the
# DPIV bundle gen-dev-piv-keys produced. Sibling to sign-elf.
FORMAT_VOLUME_DIR := tools/format-volume
FORMAT_VOLUME := $(FORMAT_VOLUME_DIR)/target/aarch64-apple-darwin/release/format-volume
# Signing mode: "yubikey" (default) or "seed" (for CI/testing without hardware key)
SIGN_MODE ?= seed
# Bootstrap seed hex — only used when SIGN_MODE=seed (for dev/CI builds)
BOOTSTRAP_SEED_HEX := 4172634f532d426f6f7473747261702d4964656e746974792d50686173653021
# Resolve sign-elf flags based on signing mode
ifeq ($(SIGN_MODE),seed)
SIGN_FLAGS := --seed $(BOOTSTRAP_SEED_HEX)
else ifeq ($(SIGN_MODE),dev-piv)
# Sign ELFs with the dev-PIV slot-9C Ed25519 seed (matches the
# bootstrap pubkey baked into a kernel built with `--features
# dev-piv`). Requires `make gen-dev-piv-keys` to have produced
# dev_slot_9c_seed.bin. NOTE: this is the *derived* slot-9C
# seed (blake3(.dev-seed.bin || "cambios-dev-piv:slot-9c-
# ed25519")), not .dev-seed.bin itself — the bootstrap pubkey
# under `--features dev-piv` is the slot-9C public key, so
# sign-elf needs the slot-9C secret to produce signatures the
# kernel accepts.
DEV_PIV_SEED_HEX := $(shell xxd -p -c 32 dev_slot_9c_seed.bin)
SIGN_FLAGS := --seed $(DEV_PIV_SEED_HEX)
else
SIGN_FLAGS :=
endif
.PHONY: all kernel iso run run-gui run-uefi test clean symbols img-x86 run-img-x86 img-usb run-img-usb usb verify-usb disk-img kernel-aarch64 img-aarch64 run-aarch64 run-aarch64-gui kernel-riscv64 img-riscv64 run-riscv64 check-all check-stable check-x86 check-aarch64 check-riscv64 check-adrs check-index-isolation check-deferrals update-deferrals-baseline claude-preflight sync-site sync-site-check user-elf fs-service key-store-service virtio-net virtio-blk virtio-input usb-host ccid i219-net udp-stack shell policy-service fb-demo compositor scanout-limine scanout-virtio-gpu hello-window tree worm ping sprouty terminal-window audit-tail fde-mount user-elf-aarch64 fs-service-aarch64 key-store-service-aarch64 virtio-net-aarch64 virtio-blk-aarch64 usb-host-aarch64 ccid-aarch64 i219-net-aarch64 udp-stack-aarch64 shell-aarch64 policy-service-aarch64 fb-demo-aarch64 compositor-aarch64 scanout-limine-aarch64 scanout-virtio-gpu-aarch64 virtio-input-aarch64 hello-window-aarch64 tree-aarch64 worm-aarch64 ping-aarch64 sprouty-aarch64 terminal-window-aarch64 audit-tail-aarch64 fde-mount-aarch64 fs-service-riscv64 key-store-service-riscv64 virtio-blk-riscv64 usb-host-riscv64 ccid-riscv64 virtio-net-riscv64 udp-stack-riscv64 shell-riscv64 policy-service-riscv64 scanout-virtio-gpu-riscv64 virtio-input-riscv64 compositor-riscv64 hello-window-riscv64 tree-riscv64 worm-riscv64 ping-riscv64 sprouty-riscv64 terminal-window-riscv64 audit-tail-riscv64 fde-mount-riscv64 sign-tool mkinitrd gen-dev-piv-keys format-volume bake-font export-pubkey kernel-dev-piv key-store-service-dev-piv iso-dev-piv run-quiet-dev-piv
all: iso
kernel:
cargo build --target x86_64-unknown-none --release
# Kernel built with `--features dev-piv` — replaces the committed
# bootstrap pubkey with the per-developer dev one from
# tools/gen-dev-piv-keys/.dev-seed.bin. Used end-to-end by
# `run-dev-piv` for the stream A FDE unlock smoke test.
kernel-dev-piv:
cargo build --target x86_64-unknown-none --release --features dev-piv
# Key-store-service built with `--features dev-piv` — loads
# SwPivBackend with the slot-9C/9D keys from
# user/key-store-service/dev_piv_secret.bin so the kernel's PIV
# IPC clients can talk to a virtual YubiKey without real hardware.
key-store-service-dev-piv:
@echo "=== Building Key Store service (--features dev-piv) ==="
cd $(KS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release --features dev-piv
@echo "=== Key Store service ready (dev-piv) ==="
user-elf:
@echo "=== Building user-space ELF ==="
clang -target x86_64-unknown-none -nostdlib -ffreestanding -c $(USER_SRC) -o user/hello.o
ld.lld -T $(USER_LD) -nostdlib --no-dynamic-linker -static user/hello.o -o $(USER_ELF)
@echo "=== $(USER_ELF) ready ==="
fs-service:
@echo "=== Building FS service ==="
cd $(FS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== FS service ready ==="
key-store-service:
@echo "=== Building Key Store service ==="
cd $(KS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== Key Store service ready ==="
virtio-net:
@echo "=== Building Virtio-Net driver ==="
cd $(NET_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== Virtio-Net driver ready ==="
virtio-blk:
@echo "=== Building Virtio-Blk driver ==="
cd $(BLK_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== Virtio-Blk driver ready ==="
usb-host:
@echo "=== Building USB-Host driver ==="
cd $(USB_HOST_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== USB-Host driver ready ==="
ccid:
@echo "=== Building CCID class driver ==="
cd $(CCID_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== CCID class driver ready ==="
i219-net:
@echo "=== Building Intel I219-LM driver ==="
cd $(I219_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== I219-LM driver ready ==="
udp-stack:
@echo "=== Building UDP stack ==="
cd $(UDP_STACK_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== UDP stack ready ==="
shell:
@echo "=== Building Shell ==="
cd $(SHELL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== Shell ready ==="
policy-service:
@echo "=== Building Policy service ==="
cd $(POLICY_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== Policy service ready ==="
fb-demo:
@echo "=== Building fb-demo (Phase GUI-1) ==="
cd $(FB_DEMO_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== fb-demo ready ==="
audit-tail:
@echo "=== Building audit-tail (ADR-023) ==="
cd $(AUDIT_TAIL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== audit-tail ready ==="
fde-mount:
@echo "=== Building fde-mount (ADR-032 § Architecture, stream A A-v.a) ==="
cd $(FDE_MOUNT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== fde-mount ready ==="
compositor:
@echo "=== Building compositor (Phase Scanout-1, ADR-014) ==="
cd $(COMPOSITOR_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== compositor ready ==="
scanout-limine:
@echo "=== Building scanout-limine (Phase Scanout-2, ADR-014) ==="
cd $(SCANOUT_LIMINE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== scanout-limine ready ==="
scanout-virtio-gpu:
@echo "=== Building scanout-virtio-gpu (Phase Scanout-4.a, ADR-014) ==="
cd $(SCANOUT_VGPU_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== scanout-virtio-gpu ready ==="
virtio-input:
@echo "=== Building virtio-input (ADR-012 Input-1) ==="
cd $(VIRTIO_INPUT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== virtio-input ready ==="
hello-window:
@echo "=== Building hello-window (Phase Scanout-3, ADR-011) ==="
cd $(HELLO_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== hello-window ready ==="
tree:
@echo "=== Building tree (first-party app, ADR-011 / ADR-012) ==="
cd $(TREE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== tree ready ==="
worm:
@echo "=== Building worm (first-party app, ADR-011 / ADR-012) ==="
cd $(WORM_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== worm ready ==="
ping:
@echo "=== Building ping (first-party app, ADR-011 / ADR-012) ==="
cd $(PING_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== ping ready ==="
sprouty:
@echo "=== Building sprouty (first-party app, ADR-011 / ADR-012) ==="
cd $(SPROUTY_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== sprouty ready ==="
terminal-window:
@echo "=== Building terminal-window (GUI shell host) ==="
cd $(TERMINAL_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --release
@echo "=== terminal-window ready ==="
# AArch64 user-space build targets
user-elf-aarch64:
@echo "=== Building user-space ELF (AArch64) ==="
clang -target aarch64-unknown-none -nostdlib -ffreestanding -c $(USER_SRC_AARCH64) -o user/hello-aarch64.o
ld.lld -T $(USER_LD_AARCH64) -nostdlib --no-dynamic-linker -static user/hello-aarch64.o -o $(USER_ELF_AARCH64)
@echo "=== $(USER_ELF_AARCH64) ready ==="
fs-service-aarch64:
@echo "=== Building FS service (AArch64) ==="
cd $(FS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== FS service (AArch64) ready ==="
key-store-service-aarch64:
@echo "=== Building Key Store service (AArch64) ==="
cd $(KS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== Key Store service (AArch64) ready ==="
virtio-net-aarch64:
@echo "=== Building Virtio-Net driver (AArch64) ==="
cd $(NET_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== Virtio-Net driver (AArch64) ready ==="
virtio-blk-aarch64:
@echo "=== Building Virtio-Blk driver (AArch64) ==="
cd $(BLK_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== Virtio-Blk driver (AArch64) ready ==="
usb-host-aarch64:
@echo "=== Building USB-Host driver (AArch64) ==="
cd $(USB_HOST_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== USB-Host driver (AArch64) ready ==="
ccid-aarch64:
@echo "=== Building CCID class driver (AArch64) ==="
cd $(CCID_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== CCID class driver (AArch64) ready ==="
i219-net-aarch64:
@echo "=== Building Intel I219-LM driver (AArch64) ==="
cd $(I219_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== I219-LM driver (AArch64) ready ==="
udp-stack-aarch64:
@echo "=== Building UDP stack (AArch64) ==="
cd $(UDP_STACK_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== UDP stack (AArch64) ready ==="
shell-aarch64:
@echo "=== Building Shell (AArch64) ==="
cd $(SHELL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== Shell (AArch64) ready ==="
policy-service-aarch64:
@echo "=== Building Policy service (AArch64) ==="
cd $(POLICY_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== Policy service (AArch64) ready ==="
fb-demo-aarch64:
@echo "=== Building fb-demo (AArch64) ==="
cd $(FB_DEMO_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== fb-demo (AArch64) ready ==="
audit-tail-aarch64:
@echo "=== Building audit-tail (AArch64) ==="
cd $(AUDIT_TAIL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== audit-tail (AArch64) ready ==="
fde-mount-aarch64:
@echo "=== Building fde-mount (AArch64) ==="
cd $(FDE_MOUNT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== fde-mount (AArch64) ready ==="
compositor-aarch64:
@echo "=== Building compositor (AArch64) ==="
cd $(COMPOSITOR_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== compositor (AArch64) ready ==="
scanout-limine-aarch64:
@echo "=== Building scanout-limine (AArch64) ==="
cd $(SCANOUT_LIMINE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== scanout-limine (AArch64) ready ==="
scanout-virtio-gpu-aarch64:
@echo "=== Building scanout-virtio-gpu (AArch64, Scanout-4.c ADR-014) ==="
cd $(SCANOUT_VGPU_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== scanout-virtio-gpu (AArch64) ready ==="
virtio-input-aarch64:
@echo "=== Building virtio-input (AArch64, ADR-012 Input-1) ==="
cd $(VIRTIO_INPUT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== virtio-input (AArch64) ready ==="
hello-window-aarch64:
@echo "=== Building hello-window (AArch64) ==="
cd $(HELLO_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== hello-window (AArch64) ready ==="
tree-aarch64:
@echo "=== Building tree (AArch64) ==="
cd $(TREE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== tree (AArch64) ready ==="
worm-aarch64:
@echo "=== Building worm (AArch64) ==="
cd $(WORM_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== worm (AArch64) ready ==="
ping-aarch64:
@echo "=== Building ping (AArch64) ==="
cd $(PING_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== ping (AArch64) ready ==="
sprouty-aarch64:
@echo "=== Building sprouty (AArch64) ==="
cd $(SPROUTY_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== sprouty (AArch64) ready ==="
terminal-window-aarch64:
@echo "=== Building terminal-window (AArch64) ==="
cd $(TERMINAL_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-aarch64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target aarch64-unknown-none --release
@echo "=== terminal-window (AArch64) ready ==="
# RISC-V user-space build targets (R-6 / ADR-013)
# Services build with the same CARGO_ENCODED_RUSTFLAGS shape as x86_64/aarch64;
# only the linker script and target triple differ.
fs-service-riscv64:
@echo "=== Building FS service (RISC-V) ==="
cd $(FS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== FS service (RISC-V) ready ==="
key-store-service-riscv64:
@echo "=== Building Key Store service (RISC-V) ==="
cd $(KS_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== Key Store service (RISC-V) ready ==="
virtio-blk-riscv64:
@echo "=== Building Virtio-Blk driver (RISC-V) ==="
cd $(BLK_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== Virtio-Blk driver (RISC-V) ready ==="
usb-host-riscv64:
@echo "=== Building USB-Host driver (RISC-V) ==="
cd $(USB_HOST_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== USB-Host driver (RISC-V) ready ==="
ccid-riscv64:
@echo "=== Building CCID class driver (RISC-V) ==="
cd $(CCID_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== CCID class driver (RISC-V) ready ==="
virtio-net-riscv64:
@echo "=== Building Virtio-Net driver (RISC-V) ==="
cd $(NET_DRIVER_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== Virtio-Net driver (RISC-V) ready ==="
udp-stack-riscv64:
@echo "=== Building UDP stack (RISC-V) ==="
cd $(UDP_STACK_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== UDP stack (RISC-V) ready ==="
shell-riscv64:
@echo "=== Building Shell (RISC-V) ==="
cd $(SHELL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== Shell (RISC-V) ready ==="
policy-service-riscv64:
@echo "=== Building Policy service (RISC-V) ==="
cd $(POLICY_SERVICE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== Policy service (RISC-V) ready ==="
audit-tail-riscv64:
@echo "=== Building audit-tail (RISC-V) ==="
cd $(AUDIT_TAIL_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== audit-tail (RISC-V) ready ==="
fde-mount-riscv64:
@echo "=== Building fde-mount (RISC-V) ==="
cd $(FDE_MOUNT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== fde-mount (RISC-V) ready ==="
scanout-virtio-gpu-riscv64:
@echo "=== Building scanout-virtio-gpu (RISC-V, Scanout-4.c ADR-014) ==="
cd $(SCANOUT_VGPU_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== scanout-virtio-gpu (RISC-V) ready ==="
virtio-input-riscv64:
@echo "=== Building virtio-input (RISC-V, ADR-012 Input-1) ==="
cd $(VIRTIO_INPUT_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== virtio-input (RISC-V) ready ==="
compositor-riscv64:
@echo "=== Building compositor (RISC-V, ADR-014) ==="
cd $(COMPOSITOR_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== compositor (RISC-V) ready ==="
hello-window-riscv64:
@echo "=== Building hello-window (RISC-V, ADR-011) ==="
cd $(HELLO_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== hello-window (RISC-V) ready ==="
tree-riscv64:
@echo "=== Building tree (RISC-V, ADR-011/012) ==="
cd $(TREE_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== tree (RISC-V) ready ==="
worm-riscv64:
@echo "=== Building worm (RISC-V, ADR-011/012) ==="
cd $(WORM_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== worm (RISC-V) ready ==="
ping-riscv64:
@echo "=== Building ping (RISC-V, ADR-011/012) ==="
cd $(PING_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== ping (RISC-V) ready ==="
sprouty-riscv64:
@echo "=== Building sprouty (RISC-V, ADR-011/012) ==="
cd $(SPROUTY_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== sprouty (RISC-V) ready ==="
terminal-window-riscv64:
@echo "=== Building terminal-window (RISC-V) ==="
cd $(TERMINAL_WINDOW_DIR) && CARGO_ENCODED_RUSTFLAGS=$$(printf '%s\x1f%s\x1f%s\x1f%s' \
'-Clink-arg=--script=link-riscv64.ld' '-Clink-arg=-z' '-Clink-arg=noexecstack' \
'-Crelocation-model=static') cargo build --target riscv64gc-unknown-none-elf --release
@echo "=== terminal-window (RISC-V) ready ==="
sign-tool:
@echo "=== Building ELF signing tool ==="
cd $(SIGN_ELF_DIR) && cargo build --release
@echo "=== sign-elf ready ==="
mkinitrd:
@echo "=== Building mkinitrd host tool ==="
cd $(MKINITRD_DIR) && cargo build --release
@echo "=== mkinitrd ready ==="
# Builds the gen-dev-piv-keys tool (idempotent; rebuilds only on source
# change) and runs it. Idempotent at the file-output level: same seed →
# byte-identical dev_bootstrap_pubkey.bin and dev_piv_secret.bin.
# Required before any build with `--features dev-piv` enabled.
gen-dev-piv-keys:
@echo "=== Building dev-PIV keypair generator ==="
cd $(GEN_DEV_PIV_DIR) && cargo build --release
@echo "=== Generating dev-PIV keypair files ==="
$(GEN_DEV_PIV)
@echo "=== dev-PIV keypair files ready ==="
# Builds the format-volume host tool. Doesn't run it — invoke
# directly with a disk image path (e.g.,
# `$(FORMAT_VOLUME) disk.img`). Requires gen-dev-piv-keys to have
# run at least once (consumes user/key-store-service/dev_piv_secret.bin).
format-volume:
@echo "=== Building format-volume host tool ==="
cd $(FORMAT_VOLUME_DIR) && cargo build --release
@echo "=== format-volume ready: $(FORMAT_VOLUME) ==="
# Re-bake the JetBrains Mono Regular TTF in assets/fonts/ into the
# antialiased glyph table consumed by user/libgui at compile time. Run
# only when the font, target cell size, or pixel height changes — the
# generated file is checked in. Bake parameters live here as the source
# of truth (the tool's CLI lets you override at the command line).
JBM_PX_HEIGHT := 24
JBM_CELL := 16x32
bake-font:
@echo "=== Building bake-font host tool ==="
cd tools/bake-font && cargo build --release
@echo "=== Re-baking JetBrains Mono into user/libgui/src/font_jbmono_data.rs ==="
./tools/bake-font/target/aarch64-apple-darwin/release/bake-font \
assets/fonts/JetBrainsMono-Regular.ttf \
user/libgui/src/font_jbmono_data.rs \
--px $(JBM_PX_HEIGHT) --cell $(JBM_CELL) --const-prefix JBM
@echo "=== bake-font ready ==="
# Export the bootstrap public key from the signing source.
# Run this once after setting up your YubiKey to generate bootstrap_pubkey.bin.
# Usage: make export-pubkey (from YubiKey)
# make export-pubkey SIGN_MODE=seed (from seed, for dev)
export-pubkey: sign-tool
$(SIGN_ELF) $(SIGN_FLAGS) --export-pubkey bootstrap_pubkey.bin
# Auto-clone Limine if $(LIMINE_DIR) was cleaned or partially nibbled.
# rm -rf before clone defends against the macOS /tmp daily-cleanup case
# that prompted the move out of /tmp: per-file atime cleanup can leave
# the dir present but missing key files (e.g., BOOTX64.EFI gone while
# BOOTAA64.EFI survives), and `git clone` refuses a non-empty target.
$(LIMINE_DIR)/BOOTX64.EFI $(LIMINE_DIR)/BOOTAA64.EFI:
@echo "=== Cloning Limine $(LIMINE_BRANCH) ==="
rm -rf $(LIMINE_DIR)
mkdir -p $(dir $(LIMINE_DIR))
git clone $(LIMINE_REPO) --branch=$(LIMINE_BRANCH) --depth=1 $(LIMINE_DIR)
# Upstream's `limine-binary` branch ships the pre-built EFI stages but
# NOT the compiled macOS host tool `limine` (the `xxx bios-install $(ISO)`
# call at the bottom of `iso:`). The clone includes the single-file
# `limine.c` source; compile it in-place. Depends on BOOTX64.EFI to
# guarantee the clone has run.
$(LIMINE_DIR)/limine: $(LIMINE_DIR)/BOOTX64.EFI
@echo "=== Building Limine host tool ==="
$(MAKE) -C $(LIMINE_DIR)
limine: $(LIMINE_DIR)/BOOTX64.EFI $(LIMINE_DIR)/limine
# `iso-dev-piv` produces the same ISO as `iso`, but with the kernel
# and key-store-service binaries built under `--features dev-piv`
# (stream A FDE end-to-end). Approach: build the dev-piv variants
# first, then re-invoke `iso` with `--assume-old` so make doesn't
# clobber them with the default (non-dev-piv) cargo build.
iso-dev-piv: kernel-dev-piv key-store-service-dev-piv gen-dev-piv-keys format-volume fde-mount sign-tool
@echo "=== Re-assembling ISO with --features dev-piv binaries ==="
$(MAKE) --assume-old=kernel --assume-old=key-store-service SIGN_MODE=dev-piv iso
iso: kernel fs-service key-store-service virtio-blk virtio-net udp-stack virtio-input usb-host ccid shell policy-service fb-demo compositor scanout-virtio-gpu tree worm ping sprouty terminal-window audit-tail fde-mount sign-tool limine
@echo "=== Building ISO (signing mode: $(SIGN_MODE)) ==="
rm -rf iso_root
mkdir -p iso_root/boot
mkdir -p iso_root/boot/limine
mkdir -p iso_root/EFI/BOOT
# Copy kernel binary
cp $(KERNEL) iso_root/boot/cambios_microkernel
# Copy + sign boot modules (must match limine.conf module order).
# scanout-limine is not loaded in the default manifest as of
# Scanout-4.b — kept buildable out-of-tree for non-virtio-gpu
# hosts. The default `run` / `run-gui` targets include
# -device virtio-gpu-pci so scanout-virtio-gpu is the driver.
cp $(POLICY_SERVICE_ELF) iso_root/boot/policy-service.elf
cp $(KS_SERVICE_ELF) iso_root/boot/key-store-service.elf
cp $(FS_SERVICE_ELF) iso_root/boot/fs-service.elf
cp $(BLK_DRIVER_ELF) iso_root/boot/virtio-blk.elf
cp $(USB_HOST_ELF) iso_root/boot/usb-host.elf
cp $(CCID_ELF) iso_root/boot/ccid.elf
cp $(NET_DRIVER_ELF) iso_root/boot/virtio-net.elf
cp $(UDP_STACK_ELF) iso_root/boot/udp-stack.elf
cp $(SHELL_ELF) iso_root/boot/shell.elf
cp $(FB_DEMO_ELF) iso_root/boot/fb-demo.elf
cp $(COMPOSITOR_ELF) iso_root/boot/compositor.elf
cp $(SCANOUT_VGPU_ELF) iso_root/boot/scanout-virtio-gpu.elf
cp $(VIRTIO_INPUT_ELF) iso_root/boot/virtio-input.elf
cp $(TERMINAL_WINDOW_ELF) iso_root/boot/terminal-window.elf
cp $(PING_ELF) iso_root/boot/ping.elf
cp $(SPROUTY_ELF) iso_root/boot/sprouty.elf
cp $(TREE_ELF) iso_root/boot/tree.elf
cp $(WORM_ELF) iso_root/boot/worm.elf
cp $(AUDIT_TAIL_ELF) iso_root/boot/audit-tail.elf
cp $(FDE_MOUNT_ELF) iso_root/boot/fde-mount.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/policy-service.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/key-store-service.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/fs-service.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/virtio-blk.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/usb-host.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/ccid.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/virtio-net.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/udp-stack.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/shell.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/fb-demo.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/compositor.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/scanout-virtio-gpu.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/virtio-input.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/terminal-window.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/ping.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/sprouty.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/tree.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/worm.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/audit-tail.elf
$(SIGN_ELF) $(SIGN_FLAGS) iso_root/boot/fde-mount.elf
# Copy Limine config (root + standard location)
cp limine.conf iso_root/limine.conf
cp limine.conf iso_root/boot/limine/limine.conf
# Copy Limine BIOS files
cp $(LIMINE_DIR)/limine-bios.sys iso_root/boot/limine/
cp $(LIMINE_DIR)/limine-bios-cd.bin iso_root/boot/limine/
# Copy Limine UEFI files
cp $(LIMINE_DIR)/BOOTX64.EFI iso_root/EFI/BOOT/
cp $(LIMINE_DIR)/BOOTIA32.EFI iso_root/EFI/BOOT/
# Create ISO
xorriso -as mkisofs \
-b boot/limine/limine-bios-cd.bin \
-no-emul-boot -boot-load-size 4 -boot-info-table \
--efi-boot EFI/BOOT/BOOTX64.EFI \
-efi-boot-part --efi-boot-image --protective-msdos-label \
iso_root -o $(ISO) 2>&1
# Install Limine BIOS stages
$(LIMINE_DIR)/limine bios-install $(ISO)
rm -rf iso_root
@echo "=== $(ISO) ready ==="
# Persistent backing file for the virtio-blk device. 64 MiB is enough for
# the Phase 4a.i DiskObjectStore with 4096-slot capacity (~32 MiB used) plus
# room to grow. The image file persists across `make run` invocations, which
# is the whole point — reboot-cycle testing needs the bytes to survive.
DISK_IMG := cambios-disk.img
DISK_SIZE_MB := 64
disk-img:
@if [ ! -f $(DISK_IMG) ]; then \
echo "=== Creating $(DISK_IMG) ($(DISK_SIZE_MB) MiB) ==="; \
qemu-img create -f raw $(DISK_IMG) $(DISK_SIZE_MB)M; \
else \
echo "=== $(DISK_IMG) already exists; leaving it alone ==="; \
fi
# `-vga virtio` replaces QEMU's default cirrus VGA with virtio-vga.
# virtio-vga is a virtio-gpu device (vendor 0x1AF4, device 0x1050,
# probed identically to virtio-gpu-pci) plus a VGA compatibility
# mode Limine uses for its boot framebuffer. With default `-vga std`
# + a *separate* `-device virtio-gpu-pci`, the Cocoa window shows
# the primary cirrus adapter — nobody writes to it in Scanout-4.b
# and the window is black. Unifying the adapter means what our
# driver programs (SET_SCANOUT / TRANSFER / FLUSH) is what Cocoa
# displays.
run: iso disk-img
qemu-system-x86_64 \
-cdrom $(ISO) \
-serial mon:stdio \
-smp 2 \
-m 4G \
-netdev user,id=net0 \
-device virtio-net-pci,netdev=net0 \
-drive file=$(DISK_IMG),if=none,format=raw,id=cambios-disk0 \
-device virtio-blk-pci,drive=cambios-disk0 \
-device qemu-xhci,id=xhci0 \
-device usb-ccid,bus=xhci0.0 \
-vga virtio \
-no-reboot
# Filtered `run`: streams kernel output through tools/qemu-run-quiet.py,
# suppressing memory-map / Limine noise and exiting with a status code
# that reflects outcome (0 = success sentinel seen, 1 = panic/exception,
# 2 = hang). Default success sentinel is `cambios> ` (full boot to shell);
# override for pre-shell testing: make run-quiet SUCCESS="virtio-net ready"
# Keep this QEMU command in sync with `run:` above.
run-quiet: iso disk-img
python3 tools/qemu-run-quiet.py \
$(if $(TIMEOUT),--timeout $(TIMEOUT),) \
$(if $(SUCCESS),--success "$(SUCCESS)",) \
-- qemu-system-x86_64 \
-cdrom $(ISO) \
-serial mon:stdio \
-smp 2 \
-m 4G \
-netdev user,id=net0 \
-device virtio-net-pci,netdev=net0 \
-drive file=$(DISK_IMG),if=none,format=raw,id=cambios-disk0 \
-device virtio-blk-pci,drive=cambios-disk0 \
-device qemu-xhci,id=xhci0 \
-device usb-ccid,bus=xhci0.0 \
-vga virtio \
-no-reboot
# Quiet run under `--features dev-piv` — the stream A FDE end-to-end
# smoke test. Formats the disk image with a fresh signed volume
# header (idempotent under a constant master via --master-key-hex
# would be possible, but the default random master is what matches
# production semantics). Boots; fde-mount unwraps the master key
# via SwPivBackend; SYS_INSTALL_MASTER_KEY installs
# EncryptedBlockDevice<VirtioBlkDevice> as OBJECT_STORE; substrate
# now lives on XTS-AES-256. Success sentinel default
# `cambios> ` indicates the boot reached the shell.
run-quiet-dev-piv: iso-dev-piv disk-img
@echo "=== Zeroing substrate superblock (LBA 4) for fresh-wrap detection ==="
@# format-volume randomizes the master key each invocation, so any
@# substrate state at LBA 4+ from a prior boot decrypts to garbage
@# under the new master — kernel's open_strict refuses (correct
@# wrong-master behavior, see A-v.d.4 design). Smoke test wants the
@# fresh-wrap → format() path each run, so we zero just LBA 4 (the
@# substrate's SUPERBLOCK_LBA after the FDE_SUBSTRATE_LBA_OFFSET = 4
@# shift) to force the kernel's `is_fresh_wrap` check to fire.
@# Leaves LBA 5+ untouched; persistence semantics are unchanged when
@# the master is held stable (e.g., via --master-key-hex).
dd if=/dev/zero of=$(DISK_IMG) bs=4096 count=1 seek=4 conv=notrunc status=none
@echo "=== Formatting cambios-disk.img with fresh signed FDE header ==="
$(FORMAT_VOLUME) $(DISK_IMG)
python3 tools/qemu-run-quiet.py \
$(if $(TIMEOUT),--timeout $(TIMEOUT),) \
$(if $(SUCCESS),--success "$(SUCCESS)",) \
-- qemu-system-x86_64 \
-cdrom $(ISO) \
-serial mon:stdio \
-smp 2 \
-m 4G \
-netdev user,id=net0 \
-device virtio-net-pci,netdev=net0 \
-drive file=$(DISK_IMG),if=none,format=raw,id=cambios-disk0 \
-device virtio-blk-pci,drive=cambios-disk0 \
-device qemu-xhci,id=xhci0 \
-device usb-ccid,bus=xhci0.0 \
-vga virtio \
-no-reboot
# Same as `run`, plus a graphical QEMU window (macOS Cocoa backend) so
# compositor / scanout output is visible. Use for Scanout-3+ visual
# verification; `run` stays headless (serial-only) for CI / text-mode
# workflows. For Linux change `cocoa` to `gtk`; for remote sessions
# swap to `-vnc :0` and connect via Screen Sharing.
run-gui: iso disk-img
qemu-system-x86_64 \
-cdrom $(ISO) \
-serial mon:stdio \
-smp 2 \
-m 4G \
-netdev user,id=net0 \
-device virtio-net-pci,netdev=net0 \
-drive file=$(DISK_IMG),if=none,format=raw,id=cambios-disk0 \
-device virtio-blk-pci,drive=cambios-disk0 \
-device virtio-keyboard-pci \
-device virtio-mouse-pci \
-device qemu-xhci,id=xhci0 \
-device usb-ccid,bus=xhci0.0 \
-vga virtio \
-no-reboot \
-display cocoa
run-uefi: iso
@cp $(EFI_VARS_X86) /tmp/cambios-efivars.fd
qemu-system-x86_64 \
-cdrom $(ISO) \
-drive if=pflash,format=raw,readonly=on,file=$(EFI_FW_X86) \
-drive if=pflash,format=raw,file=/tmp/cambios-efivars.fd \
-serial mon:stdio \
-m 4G \
-no-reboot
# x86_64 FAT32 UEFI image — for USB boot on bare-metal x86_64 hardware.
# Usage: make img-x86 && sudo dd if=cambios-x86.img of=/dev/diskN bs=1M
IMG_X86 := cambios-x86.img
img-x86: kernel user-elf fs-service key-store-service virtio-net i219-net udp-stack shell policy-service virtio-blk compositor audit-tail sign-tool limine
@echo "=== Building x86_64 FAT boot image (signing mode: $(SIGN_MODE)) ==="
rm -f $(IMG_X86)
dd if=/dev/zero of=$(IMG_X86) bs=1M count=64
mformat -i $(IMG_X86) -F ::
mmd -i $(IMG_X86) ::/EFI
mmd -i $(IMG_X86) ::/EFI/BOOT
mmd -i $(IMG_X86) ::/boot
mmd -i $(IMG_X86) ::/boot/limine
mcopy -i $(IMG_X86) $(LIMINE_DIR)/BOOTX64.EFI ::/EFI/BOOT/BOOTX64.EFI
mcopy -i $(IMG_X86) $(KERNEL) ::/boot/cambios_microkernel
# Copy + sign all x86_64 user-space modules
cp $(USER_ELF) /tmp/hello-signed.elf
cp $(KS_SERVICE_ELF) /tmp/key-store-service-signed.elf
cp $(FS_SERVICE_ELF) /tmp/fs-service-signed.elf
cp $(NET_DRIVER_ELF) /tmp/virtio-net-signed.elf
cp $(I219_DRIVER_ELF) /tmp/i219-net-signed.elf