File tree Expand file tree Collapse file tree 1 file changed +71
-0
lines changed
tests/recipes/single-baremetal Expand file tree Collapse file tree 1 file changed +71
-0
lines changed Original file line number Diff line number Diff line change 1+ {
2+ pkgs ? import ( fetchTarball {
3+ url = "https://github.com/NixOS/nixpkgs/archive/refs/tags/22.11.tar.gz" ;
4+ sha256 = "sha256:11w3wn2yjhaa5pv20gbfbirvjq6i3m7pqrq2msf0g7cv44vijwgw" ;
5+ } ) { } ,
6+ platform ? " " ,
7+ bao_cfg_repo ? " " ,
8+ bao_cfg ? " " ,
9+ list_tests ? " " ,
10+ list_suites ? " " ,
11+ log_level ? " " ,
12+ GIC_VERSION ? " " ,
13+ IRQC ? " " ,
14+ IPIC ? " " ,
15+ } :
16+
17+ with pkgs ;
18+
19+ let
20+ packages = rec {
21+
22+ setup-cfg = callPackage ../../bao-nix/pkgs/setup-cfg/setup-cfg.nix {
23+ inherit platform ;
24+ inherit GIC_VERSION ;
25+ inherit IRQC ;
26+ inherit IPIC ;
27+ bao-tests = ../../bao-tests ;
28+ tests_srcs = ./src ;
29+ baremetal_patch = ./baremetal.patch ;
30+ } ;
31+
32+ #Build toolchain
33+ toolchain = callPackage ../../bao-nix/pkgs/toolchains/${ setup-cfg . toolchain_name } .nix { } ;
34+
35+ #Build guests
36+ guests = [
37+ ( callPackage ( ../../bao-nix/pkgs/guest/tf/baremetal.nix )
38+ {
39+ inherit setup-cfg ;
40+ inherit toolchain ;
41+ guest_name = "baremetal" ;
42+ list_tests = "" ;
43+ list_suites = "CPU_BOOT_CHECK" ;
44+ inherit log_level ;
45+ }
46+ )
47+ ] ;
48+
49+ bao_cfg_repo = ./configs ;
50+
51+ #Build Hypervisor
52+ bao = callPackage ../../bao-nix/pkgs/bao/bao.nix
53+ {
54+ inherit setup-cfg ;
55+ inherit toolchain ;
56+ inherit bao_cfg_repo ;
57+ inherit bao_cfg ;
58+ inherit guests ;
59+ #bao_srcs_path = /home/mafs/bao-hypervisor;
60+ } ;
61+
62+ # Build Firmware
63+ firmware = callPackage ../../bao-nix/pkgs/firmware/${ platform } .nix {
64+ inherit toolchain ;
65+ inherit platform ;
66+ inherit setup-cfg ;
67+ } ;
68+ inherit pkgs ;
69+ } ;
70+ in
71+ packages
You can’t perform that action at this time.
0 commit comments