Problem when $(PKG)_SOURCE does not contain $(PKG)_VERSION
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
Hello,
Quoted 2 lines · Eric Le Bihan
Is there a way to fix this problem, by renaming the tarball in a post-download hook or using a hash verification trick?
Simply add a hash file, Buildroot will realize the hash is different and re-download the tarball.
You can also poke upstream and tell them that unversioned tarballs is horrible :-)
Best regards,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
Quoted 9 lines · Thomas Petazzoni
Hello,
Quoted 2 lines · Eric Le Bihan
Is there a way to fix this problem, by renaming the tarball in a post-download hook or using a hash verification trick?
Simply add a hash file, Buildroot will realize the hash is different and re-download the tarball.
What puzzles me was that I already had set a hash file. I'll do more tests.
Thanks for the hint.
--
ELB
Hello,
Quoted 9 lines · Eric Le Bihan
Quoted 2 lines · Thomas Petazzoni
Simply add a hash file, Buildroot will realize the hash is different and re-download the tarball.
What puzzles me was that I already had set a hash file. I'll do more tests.
Thanks for the hint.
Well, of course, there might be a bug. Don't hesitate to provide more details, such as a way to reproduce, if you still see the issue.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com