Skip to content

Commit

Permalink
ref(bao_recipe): update local/remote srcs assignment
Browse files Browse the repository at this point in the history
Signed-off-by: Diogo Costa <[email protected]>
  • Loading branch information
Diogo21Costa authored and ESCristiano committed Feb 23, 2024
1 parent e7b83bc commit 4d54d42
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 71 deletions.
14 changes: 11 additions & 3 deletions pkgs/bao/bao_local.nix → pkgs/bao/bao.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
, fetchurl
, rsync
, toolchain
, bao_srcs_path
, bao_srcs_path ? " "
, bao_cfg_repo
, bao_cfg
, platform_cfg
Expand All @@ -23,7 +23,16 @@ stdenv.mkDerivation rec {
plat_arch = platform_cfg.platforms-arch.${platform};
plat_toolchain = platform_cfg.platforms-toolchain.${platform};

srcs = bao_srcs_path;
srcs = if bao_srcs_path == " " || bao_srcs_path == null then
fetchFromGitHub {
owner = "bao-project";
repo = "bao-hypervisor";
rev = "0575782359132465128491ab2fa44c16e76b57f8"; # branch: demo
sha256 = "sha256-pCsVpSOuCCQ86HbLbyGpi6nHi5dxa7hbQIuoemE/fSA=";
}
else
bao_srcs_path;


nativeBuildInputs = [ toolchain guests ]; #build time dependencies
buildInputs = [ rsync ];
Expand All @@ -37,7 +46,6 @@ stdenv.mkDerivation rec {
mkdir -p $out/guests
rsync -r $srcs/ $out/srcs
# cp -r ${srcs}/* $out/srcs
cp -r ${bao_cfg_repo}/* $out/configs
for guest in ${toString guests}; do
cp $guest/bin/*.bin $out/guests/
Expand Down
68 changes: 0 additions & 68 deletions pkgs/bao/bao_remote.nix

This file was deleted.

0 comments on commit 4d54d42

Please sign in to comment.