Aria2 static builds for GNU/Linux with custom patches.
- option
max-connection-per-server
: change maximum value to∞
- option
min-split-size
: change minimum value to1K
- option
piece-length
: change minimum value to1K
- download: retry on slow speed (
lowest-speed-limit
) and connection close - download: add option
retry-on-400
to retry on http 400 bad request, which only effective ifretry-wait
> 0 - download: add option
retry-on-403
to retry on http 403 forbidden, which only effective ifretry-wait
> 0 - download: add option
retry-on-406
to retry on http 406 not acceptable, which only effective ifretry-wait
> 0 - download: add option
retry-on-unknown
to retry on unknown status code, which only effective ifretry-wait
> 0
curl -fsSL git.io/aria2c.sh | bash
wget https://github.com/P3TERX/aria2-builder/releases/download/[version]/aria2-[version]-static-linux-[arch].tar.gz
tar zxvf aria2-[version]-static-linux-[arch].tar.gz
sudo mv aria2c /usr/local/bin
sudo rm -f /usr/local/bin/aria2c
Download script, execute script.
TIPS: In today's containerization of everything, this is not recommended.
git clone https://github.com/P3TERX/aria2-builder
cd aria2-builder
bash aria2-gnu-linux-build.sh
TIPS: Docker minimum version 19.03, you can also use buildx.
Build Aria2 for current architecture platforms.
DOCKER_BUILDKIT=1 docker build \
-o type=local,dest=. \
github.com/P3TERX/aria2-builder
dest
can define the output directory. If there are no changes, there will be an archive file in the current directory when the build is completed.
$ ls -l
-rw-r--r-- 1 p3terx p3terx 3744106 Jan 17 20:24 aria2-1.35.0-static-linux-amd64.tar.gz
Cross build Aria2 for other platforms, e.g.:
DOCKER_BUILDKIT=1 docker build \
--build-arg BUILDER_IMAGE=ubuntu:14.04 \
--build-arg BUILD_SCRIPT=aria2-gnu-linux-cross-build-armhf.sh \
-o type=local,dest=. \
github.com/P3TERX/aria2-builder
BUILDER_IMAGE
variable defines the system image used for the build. In general, platforms other thanarmhf
don't require it.BUILD_SCRIPT
variable defines the script used for the cross build.