From 2c8d6621f948065da0b796422d8e17b46462e22a Mon Sep 17 00:00:00 2001 From: Josh W Lewis Date: Tue, 17 Dec 2024 13:32:12 -0600 Subject: [PATCH 1/2] Update package.toml for arch specific deps --- .github/workflows/_buildpacks-release.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/_buildpacks-release.yml b/.github/workflows/_buildpacks-release.yml index e464a26..8d0edc8 100644 --- a/.github/workflows/_buildpacks-release.yml +++ b/.github/workflows/_buildpacks-release.yml @@ -132,6 +132,9 @@ jobs: echo "Packaging ${buildpack_dir}." triple=$(jq --exit-status -r '.rust_triple' <<< "${target}") cargo libcnb package --release --package-dir "${package_dir}" --target "${triple}" + os=$(jq --exit-status -r '.os' <<< "${target}") + arch=$(jq --exit-status -r '.arch' <<< "${target}") + sed -r -i "s/(docker:\/\/.+:[0-9.]+)/\0_${os}-${arch}/" "${package_dir}/package.toml" done done From 6c2d302d58184f84b2e01788194ee6ec88f8e597 Mon Sep 17 00:00:00 2001 From: Josh W Lewis Date: Tue, 17 Dec 2024 14:19:02 -0600 Subject: [PATCH 2/2] Use output_dir over packaged dir --- .github/workflows/_buildpacks-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_buildpacks-release.yml b/.github/workflows/_buildpacks-release.yml index 8d0edc8..5c6839b 100644 --- a/.github/workflows/_buildpacks-release.yml +++ b/.github/workflows/_buildpacks-release.yml @@ -134,7 +134,7 @@ jobs: cargo libcnb package --release --package-dir "${package_dir}" --target "${triple}" os=$(jq --exit-status -r '.os' <<< "${target}") arch=$(jq --exit-status -r '.arch' <<< "${target}") - sed -r -i "s/(docker:\/\/.+:[0-9.]+)/\0_${os}-${arch}/" "${package_dir}/package.toml" + sed -r -i "s/(docker:\/\/.+:[0-9.]+)/\0_${os}-${arch}/" "${output_dir}/package.toml" done done