Append the preferred local filename to fallback url, rather than upstream filename.
In some cases, such as for github revision tarballs, the upstream filename is just ``$HASH.tar.gz``, but the local filename is ``${PACKAGE_NAME}-${HASH}.tar.gz``. With this patch, it's clear which packages each URLs provides *and* it makes the process of updating http://z.cash/depends/sources a simple scp rather than involving some kind of name translation. Closes #622.
This commit is contained in:
parent
6f466aea69
commit
ad71899e5f
|
@ -23,7 +23,7 @@ define fetch_file
|
||||||
(test -f $$($(1)_source_dir)/$(4) || \
|
(test -f $$($(1)_source_dir)/$(4) || \
|
||||||
( mkdir -p $$($(1)_download_dir) && echo Fetching $(1)... && \
|
( mkdir -p $$($(1)_download_dir) && echo Fetching $(1)... && \
|
||||||
( $(build_DOWNLOAD) "$$($(1)_download_dir)/$(4).temp" "$(2)/$(3)" || \
|
( $(build_DOWNLOAD) "$$($(1)_download_dir)/$(4).temp" "$(2)/$(3)" || \
|
||||||
$(build_DOWNLOAD) "$$($(1)_download_dir)/$(4).temp" "$(FALLBACK_DOWNLOAD_PATH)/$(3)" ) && \
|
$(build_DOWNLOAD) "$$($(1)_download_dir)/$(4).temp" "$(FALLBACK_DOWNLOAD_PATH)/$(4)" ) && \
|
||||||
echo "$(5) $$($(1)_download_dir)/$(4).temp" > $$($(1)_download_dir)/.$(4).hash && \
|
echo "$(5) $$($(1)_download_dir)/$(4).temp" > $$($(1)_download_dir)/.$(4).hash && \
|
||||||
$(build_SHA256SUM) -c $$($(1)_download_dir)/.$(4).hash && \
|
$(build_SHA256SUM) -c $$($(1)_download_dir)/.$(4).hash && \
|
||||||
mv $$($(1)_download_dir)/$(4).temp $$($(1)_source_dir)/$(4) && \
|
mv $$($(1)_download_dir)/$(4).temp $$($(1)_source_dir)/$(4) && \
|
||||||
|
|
Loading…
Reference in New Issue