Just overwrite config.toml

This commit is contained in:
Wildan Mubarok 2025-12-31 04:11:30 +00:00
parent 573bb50cca
commit 802c162cc0
2 changed files with 3 additions and 13 deletions

View File

@ -1,4 +1,3 @@
# Note: this file is not tracked by cookbook, run `make c.rust` after change.
[llvm]
download-ci-llvm = false
static-libstdcpp = false

View File

@ -39,12 +39,9 @@ export CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUSTFLAGS="${RUSTFLAGS_BOOTSTRAP}"
# Don't poison the stage1 compiler (host -> host)
unset AR AS CC CXX LD LDFLAGS NM OBJCOPY OBJDUMP RANLIB READELF RUSTFLAGS STRIP
# modify config.toml to correct path, only do this once as it trigger full rebuild
if [ ! -f config.toml ]; then
cat ${COOKBOOK_RECIPE}/config.toml > config.toml
sed -i "s|COOKBOOK_SYSROOT|${COOKBOOK_SYSROOT}|g" config.toml
sed -i "s|COOKBOOK_TOOLCHAIN|${COOKBOOK_TOOLCHAIN}|g" config.toml
fi
cat ${COOKBOOK_RECIPE}/config.toml > config.toml
sed -i "s|COOKBOOK_SYSROOT|${COOKBOOK_SYSROOT}|g" config.toml
sed -i "s|COOKBOOK_TOOLCHAIN|${COOKBOOK_TOOLCHAIN}|g" config.toml
python3 "${COOKBOOK_SOURCE}/x.py" install \
--config config.toml \
@ -54,12 +51,6 @@ mkdir -p "${COOKBOOK_STAGE}"/usr
rsync -av --delete "${COOKBOOK_BUILD}"/install/* "${COOKBOOK_STAGE}"/usr/
rm -rf "${COOKBOOK_STAGE}"/usr/lib/rustlib/*.log
"""
[package]
# TODO: Not implemented
# version_script = """
# printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
# """
[[optional-packages]]
name = "doc"