depends: Use $(package)_file_name when downloading from the fallback #33580

pull achow101 wants to merge 1 commits into bitcoin:master from achow101:depends-fallback-name changing 1 files +1 −1
  1. achow101 commented at 8:26 pm on October 8, 2025: member

    The server hosting the fallbacks uses make download so the files are only available with their overridden names rather than the original name on the upstream source. We should therefore also use the overridden name when downloading from the fallback.

    Fixes https://github.com/bitcoin-core/bitcoincore.org/issues/1168

  2. depends: Use $(package)_file_name when downloading from the fallback 671b774d1b
  3. DrahtBot added the label Build system on Oct 8, 2025
  4. DrahtBot commented at 8:26 pm on October 8, 2025: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/33580.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK theuni, janb84

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

  5. theuni approved
  6. theuni commented at 8:39 pm on October 8, 2025: member

    utACK 671b774d1b58c491b53f2b2f6ee42fb6b65a0e71. I was going to PR the same change.

    For more context: Our sources server runs make download and makes those sources available as a backup host.

    We can’t control upstream filenames, so sometimes we rename them for local storage in depends. For ex “v0.1.tar.gz” may become “libfoo-v0.1.tar.gz”.

    But when we try to fetch “v0.1.tar.gz” from our backup, it doesn’t exist, because it’s been renamed to “libfoo-v0.1.tar.gz” there.

    So instead of requesting the original filename from our backup, request the renamed file. If there’s a hash mismatch, that’ll be detected later on, so there’s no loss of security.

  7. janb84 commented at 12:09 pm on October 9, 2025: contributor

    ut ACK 671b774d1b58c491b53f2b2f6ee42fb6b65a0e71

    PR changes the third argument of fetch_file_inner() in the fallback scenario. This change ensures that, in the fallback scenario, the “friendly filename” is used to download the file instead of the “filename.”

    The file contains only the download logic, and I haven’t been able to verify whether the “friendly filename” is constructed the same way for the upload to the fallback server.

    The code is somewhat confusing to read because of double use of $(4). Once as the fourth argument to fetch_file() and once as the fourth arguments to fetch_file_inner(). Where in the fallback scenario the fourth argument of fetch_file() is used as both the 3rd and 4th argument of fetch_file_inner()

    The 4th argument of fetch_file() is $($(1)_file_name) (line129) which is the “friendly filename name”

    But we can conclude that in the fallback scenario the “friendly file name” is also used to download from the fallback server.

  8. maflcko added the label DrahtBot Guix build requested on Oct 10, 2025

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-10-10 15:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me