lede/include
Albert Xu 6c4e5d7b47
scripts/download.pl: Make the download tool configurable (#10291)
* rules.mk: Move DOWNLOAD_CHECK_CERTIFICATE to include/download.mk

Move DOWNLOAD_CHECK_CERTIFICATE to include/download.mk as it's a better
place than exporting it in the global rules.mk makefile.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>

* scripts/download.pl: Make the download tool configurable

Introduce a new option in the "Advanced configuration options" to
configure a custom download tool.

By declaring a string in "Use custom download tool" an user can force
what command to use to download package. With the string empty the
default tool used is curl, with wget as a fallback if not available.

download.pl supports 3 tools officially aria2c, curl and wget.
If one of the tool is used in this config, download.pl will use the
default args to make use of them.

If the provided string is different than aria2c, curl or wget, the command
is used as is and the download url will be appended at the end of such command.

While at it also tweak the tool selection logic and chose the tool only
once when the script is called and move aria2c specific variables in the
relevant section.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>

* scripts/download.pl: Pass aria2 config in ENV only

The aria2c command tries to load config from
${XDG_CONFIG_HOME:-${HOME}/.config}/aria2/aria2.conf by default,
which may result unexpected behavior.

As a replacement, people can use environment variable ARIA2C_OPTIONS
to custom arguments passed to aria2c like curl and wget below.
Including --conf-path=/path/to/config.conf in ARIA2C_OPTIONS can
also set a custom config file path easily if needed.

Signed-off-by: Zhang Hua <zhanghuadedn@gmail.com>

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Signed-off-by: Zhang Hua <zhanghuadedn@gmail.com>
Co-authored-by: Christian Marangi <ansuelsmth@gmail.com>
Co-authored-by: Zhang Hua <zhanghuadedn@gmail.com>
2022-10-21 12:47:28 +08:00
..
site Merge branch 'master' of https://github.com/lede-project/source 2018-01-09 14:38:15 +08:00
autotools.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
bpf.mk toolchain: add llvm-bpf 2022-04-07 01:01:05 +08:00
cmake.mk cmake.mk: fix for install llvm-bdf (#10109) 2022-09-14 22:38:59 +08:00
debug.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
depends.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
device_table.txt update source 2017-09-06 19:19:45 +08:00
download.mk scripts/download.pl: Make the download tool configurable (#10291) 2022-10-21 12:47:28 +08:00
feeds.mk build: ensure that dash isn't prepended twice to abi version suffix 2021-06-16 18:13:00 +08:00
hardened-ld-pie.specs Merge branch 'master' of github.com:lede-project/source 2018-04-23 18:50:49 +08:00
hardening.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
host-build.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
image-commands.mk build: move Build/copy-file to image-commands.mk 2022-10-19 21:57:13 +08:00
image.mk build: move Build/copy-file to image-commands.mk 2022-10-19 21:57:13 +08:00
kernel-5.4 Kernel: bump 5.4 to 5.4.219 (#10279) 2022-10-19 15:55:34 +08:00
kernel-5.10 kernel: bump 5.10 to 5.10.149 (#10278) 2022-10-19 15:55:47 +08:00
kernel-5.15 kernel: bump 5.15 to 5.15.74 (#10263) 2022-10-16 15:15:29 +00:00
kernel-5.19 kernel: bump 5.19 to 5.19.16 2022-10-15 18:12:00 +08:00
kernel-6.0 kernel: bump 6.0 to 6.0.2 2022-10-15 18:10:39 +08:00
kernel-build.mk kernel: backport flow offload fixes 2022-05-31 23:00:41 +08:00
kernel-defaults.mk x86: improve Intel gen 11/12th GPU i915 and GVT-g capability 2022-02-12 20:29:20 +08:00
kernel-version.mk kernel: split kernel version to dedicated files (#8692) 2022-01-15 10:40:27 +08:00
kernel.mk netfilter.mk : backport kernel config 2022-07-14 15:04:47 +08:00
logo.png x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
logo.svg x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
meson.mk tools/meson: update to 0.61.4 2022-10-01 10:03:52 +08:00
netfilter.mk netfilter.mk : add ip6table mangle depend 2022-10-01 23:50:32 +08:00
nls.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
openssl-engine.mk openssl: move engine.mk to INCLUDE_DIR (#9127) 2022-03-25 15:03:58 +08:00
package-bin.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
package-defaults.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
package-dumpinfo.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
package-ipkg.mk tools: build bash on macOS and use it for ipkg-build 2022-08-24 10:53:47 +08:00
package-seccomp.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
package.mk x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
prereq-build.mk build: provide xxd -i with scripts/xxdi.pl 2022-09-13 00:07:40 +08:00
prereq.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
quilt.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
rootfs.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
scan.awk update source 2017-09-06 19:19:45 +08:00
scan.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
shell.sh x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
subdir.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
target.mk Revert "rockchip: default smp tune on" 2022-09-15 15:20:13 +08:00
toolchain-build.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
toplevel.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
trusted-firmware-a.mk trusted-firmware-a.mk: pass DTC path similar to u-boot.mk 2022-08-29 11:20:19 +08:00
u-boot.mk x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
uclibc++.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
unpack.mk x64: fix grub2 booting 2021-06-15 17:58:07 +08:00
verbose.mk add kernel 5.10 support and sync with upstream 2021-06-14 18:30:08 +08:00
version.mk x64: fix grub2 booting 2021-06-15 17:58:07 +08:00