wget -O- "https://github.com/aria2/aria2/releases/download/release-1.35.0/aria2-1.35.0.tar.gz" | tar xz
cd aria2-1.35.0
./configure --without-gnutls --with-openssl --without-libxml2 ARIA2_STATIC=yes \
ZLIB_CFLAGS="-I/root/x64/include" \
ZLIB_LIBS="-L/root/x64/lib -lz" \
EXPAT_CFLAGS="-I/root/x64/include" \
EXPAT_LIBS="-L/root/x64/lib -lexpat" \
SQLITE3_CFLAGS="-I/root/x64/include" \
SQLITE3_LIBS="-L/root/x64/lib -lsqlite3" \
OPENSSL_CFLAGS="-I/root/x64/include" \
OPENSSL_LIBS="-L/root/x64/lib -lssl -lcrypto" \
LIBCARES_CFLAGS="-I/root/x64/include" \
LIBCARES_LIBS="-L/root/x64/lib -lcares" \
LIBSSH2_CFLAGS="-I/root/x64/include" \
LIBSSH2_LIBS="-L/root/x64/lib -lssh2"
make LIBS='-ldl -lpthread' -j $(grep "cpu cores" /proc/cpuinfo | wc -l)
mv src/aria2c ../aria2c_x64
strip ../aria2c_x64
cd ..
rm -rf aria2-1.35.0