From 5fcba0aa21ee750d7d3ffa8c13f70ab6b4d33c22 Mon Sep 17 00:00:00 2001 From: Tom Binder Date: Wed, 22 Jan 2025 16:48:36 +0000 Subject: [PATCH] Remove call by cargo for snp_measurement, thereby fixing the stage0_bin build. Remove the dispensable intermediate target. Bug: 391513240 Change-Id: I8792a62b447eceb9938eee72d88726ed90ef21f0 --- buildconfigs/stage0_bin.sh | 16 ++++++++-------- justfile | 14 ++++++-------- 2 files changed, 14 insertions(+), 16 deletions(-) diff --git a/buildconfigs/stage0_bin.sh b/buildconfigs/stage0_bin.sh index 84a670b80b..0e644e02e9 100644 --- a/buildconfigs/stage0_bin.sh +++ b/buildconfigs/stage0_bin.sh @@ -9,17 +9,17 @@ export BUILD_COMMAND=( develop --command just - stage0_provenance_subjects + stage0_bin ) # The first element must be the Transparent Release binary (the main binary). export SUBJECT_PATHS=( artifacts/stage0_bin - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_01_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_02_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_04_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_08_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_16_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_32_vcpu - stage0_bin/bin/subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_64_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_01_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_02_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_04_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_08_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_16_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_32_vcpu + artifacts/stage0_bin_subjects/sha2_384_measurement_of_initial_memory_with_stage0_and_64_vcpu ) diff --git a/justfile b/justfile index 42bdc680ca..2e07974b6e 100644 --- a/justfile +++ b/justfile @@ -191,6 +191,12 @@ stage0_bin: cp --force --preserve=timestamps --no-preserve=mode \ bazel-bin/stage0_bin/stage0_bin \ artifacts/stage0_bin + mkdir -p artifacts/stage0_bin_subjects + rm --force artifacts/stage0_bin_subjects/* + bazel run {{BAZEL_CONFIG_FLAG}} //snp_measurement -- \ + --vcpu-count=1,2,4,8,16,32,64 \ + --stage0-rom=$(realpath artifacts/stage0_bin) \ + --attestation-measurements-output-dir=$(realpath artifacts/stage0_bin_subjects) stage0_bin_tdx: bazel build {{BAZEL_CONFIG_FLAG}} --platforms=//:x86_64-firmware \ @@ -199,14 +205,6 @@ stage0_bin_tdx: bazel-bin/stage0_bin_tdx/stage0_bin_tdx \ artifacts/stage0_bin_tdx -stage0_provenance_subjects output_dir="stage0_bin/bin/subjects": stage0_bin - rm --recursive --force {{output_dir}} - mkdir --parents {{output_dir}} - cargo run --package=snp_measurement --quiet -- \ - --vcpu-count=1,2,4,8,16,32,64 \ - --stage0-rom=bazel-bin/stage0_bin/stage0_bin \ - --attestation-measurements-output-dir={{output_dir}} - stage1_cpio: bazel build {{BAZEL_CONFIG_FLAG}} //oak_containers/stage1_bin cp --force --preserve=timestamps --no-preserve=mode \