[Buildroot] Problem when $(PKG)_SOURCE does not contain $(PKG)_VERSION

Eric Le Bihan eric.le.bihan.dev at free.fr
Sat Mar 25 14:34:56 UTC 2017


Hi all!

I will soon post a new patch series to add support for the Rust programming
language (version 1.16.0).

One of the patches adds a package named host-cargo-bootstrap, which
fetches a binary version of Cargo, the build tool for Rust.

The package Makefile looks like this:

```
CARGO_BOOTSTRAP_VERSION = 6e0c18cccc8b0c06fba8a8d76486f81a792fb420
CARGO_BOOTSTRAP_SITE = https://s3.amazonaws.com/rust-lang-ci/cargo-builds/$(CARGO_BOOTSTRAP_VERSION)
CARGO_BOOTSTRAP_SOURCE = cargo-nightly-$(HOSTARCH)-unknown-linux-gnu.tar.gz
```

As you can see, $(CARGO_BOOTSTRAP_SOURCE) does not refer to
$(CARGO_BOOTSTRAP_VERSION), only $(CARGO_BOOTSTRAP_SITE) does.

In my build environment, I already had a previous version of
cargo-nightly-$(HOSTARCH)-unknown-linux-gnu.tar.gz in my dl directory,
so when I bumped the version, Buildroot did not download the new
version.

Is there a way to fix this problem, by renaming the tarball in a
post-download hook or using a hash verification trick?

Best regards,

--
ELB


More information about the buildroot mailing list