Skip to content

Commit

Permalink
[nix] fix online driver exection
Browse files Browse the repository at this point in the history
Signed-off-by: Avimitin <dev@avimit.in>
  • Loading branch information
Avimitin committed Jan 22, 2025
1 parent 5cae2a2 commit 8e1834e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions nix/t1/run/run-emulator.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ stdenvNoCC.mkDerivation (lib.recursiveUpdate
dontUnpack = true;

emuDriverArgs = assert lib.assertMsg (!(emulator ? enableProfile && emulator.enableProfile)) "The provided emulator has `profile` feature enable, which is inherently nondetermistic, use '.<...attr path...>.profile --impure' instead";
lib.escapeShellArgs emuDriverArgs;
toString emuDriverArgs;

passthru = {
# to open 'profileReport.html' in firefox,
Expand Down Expand Up @@ -68,11 +68,12 @@ stdenvNoCC.mkDerivation (lib.recursiveUpdate
exit 1
}
echo "[nix] Running VCS for $caseName with args $emuDriverArgs"
driverPhase="${lib.getExe emulator} $emuDriverArgs"
echo "[nix] Running '$driverPhase'"
export RUST_BACKTRACE=full
rtlEventOutPath="$out/$caseName-rtl-event.jsonl"
if ! "${lib.getExe emulator}" $emuDriverArgs \
if ! eval "$driverPhase" \
1> >(tee $out/online-drive-emu-journal) \
2>$rtlEventOutPath
then
Expand Down

0 comments on commit 8e1834e

Please sign in to comment.