Add aria2 dependency.
kiwix-desktop needs the aria2 binary to download content. kiwix-desktop will use aria2 throw lib-kiwix so it is somehow a kiwix-lib dependency, but it is used only by kiwix-desktop. And we know to install it only on platforms where we are supporting kiwix-destkop.
This commit is contained in:
parent
d375cc06bc
commit
ed63ffe24c
|
@ -4,6 +4,7 @@ from . import (
|
||||||
all_dependencies,
|
all_dependencies,
|
||||||
android_ndk,
|
android_ndk,
|
||||||
android_sdk,
|
android_sdk,
|
||||||
|
aria2,
|
||||||
armhf,
|
armhf,
|
||||||
ctpp2,
|
ctpp2,
|
||||||
flatpak,
|
flatpak,
|
||||||
|
|
|
@ -0,0 +1,26 @@
|
||||||
|
from .base import (
|
||||||
|
Dependency,
|
||||||
|
ReleaseDownload,
|
||||||
|
MakeBuilder
|
||||||
|
)
|
||||||
|
|
||||||
|
from kiwixbuild.utils import Remotefile, run_command
|
||||||
|
|
||||||
|
class Aria2(Dependency):
|
||||||
|
name = "aria2"
|
||||||
|
|
||||||
|
class Source(ReleaseDownload):
|
||||||
|
archive = Remotefile('aria2-1.34.0.tar.xz',
|
||||||
|
'3a44a802631606e138a9e172a3e9f5bcbaac43ce2895c1d8e2b46f30487e77a3',
|
||||||
|
'https://github.com/aria2/aria2/releases/download/release-1.34.0/aria2-1.34.0.tar.xz')
|
||||||
|
|
||||||
|
patches = ["libaria2_android.patch"]
|
||||||
|
|
||||||
|
def _post_prepare_script(self, context):
|
||||||
|
context.try_skip(self.extract_path)
|
||||||
|
command = "autoreconf -i"
|
||||||
|
run_command(command, self.extract_path, context)
|
||||||
|
|
||||||
|
class Builder(MakeBuilder):
|
||||||
|
dependencies = ['zlib']
|
||||||
|
configure_option = "--disable-libaria2 --without-sqlite3"
|
|
@ -11,7 +11,7 @@ class KiwixDesktop(Dependency):
|
||||||
git_dir = "kiwix-desktop"
|
git_dir = "kiwix-desktop"
|
||||||
|
|
||||||
class Builder(QMakeBuilder):
|
class Builder(QMakeBuilder):
|
||||||
dependencies = ["qt", "qtwebengine", "kiwix-lib"]
|
dependencies = ["qt", "qtwebengine", "kiwix-lib", "aria2"]
|
||||||
@property
|
@property
|
||||||
def configure_option(self):
|
def configure_option(self):
|
||||||
options = ["PREFIX={}".format(self.buildEnv.install_dir)]
|
options = ["PREFIX={}".format(self.buildEnv.install_dir)]
|
||||||
|
|
|
@ -28,6 +28,7 @@ PACKAGE_NAME_MAPPERS = {
|
||||||
'zimlib': None,
|
'zimlib': None,
|
||||||
'file' : ['file-devel'],
|
'file' : ['file-devel'],
|
||||||
'gumbo' : ['gumbo-parser-devel'],
|
'gumbo' : ['gumbo-parser-devel'],
|
||||||
|
'aria2': ['aria2'],
|
||||||
},
|
},
|
||||||
'fedora_native_static': {
|
'fedora_native_static': {
|
||||||
'COMMON': _fedora_common + ['glibc-static', 'libstdc++-static'],
|
'COMMON': _fedora_common + ['glibc-static', 'libstdc++-static'],
|
||||||
|
@ -72,6 +73,7 @@ PACKAGE_NAME_MAPPERS = {
|
||||||
'libmicrohttpd': ['libmicrohttpd-dev', 'ccache'],
|
'libmicrohttpd': ['libmicrohttpd-dev', 'ccache'],
|
||||||
'qt' : ['libqt5gui5', 'qtbase5-dev', 'qt5-default'],
|
'qt' : ['libqt5gui5', 'qtbase5-dev', 'qt5-default'],
|
||||||
'qtwebengine' : ['qtwebengine5-dev'],
|
'qtwebengine' : ['qtwebengine5-dev'],
|
||||||
|
'aria2': ['aria2'],
|
||||||
},
|
},
|
||||||
'debian_native_static': {
|
'debian_native_static': {
|
||||||
'COMMON': _debian_common + ['libbz2-dev', 'libmagic-dev'],
|
'COMMON': _debian_common + ['libbz2-dev', 'libmagic-dev'],
|
||||||
|
|
|
@ -33,6 +33,7 @@ RUN \
|
||||||
ctpp2-utils \
|
ctpp2-utils \
|
||||||
libctpp2-dev \
|
libctpp2-dev \
|
||||||
libmicrohttpd-dev \
|
libmicrohttpd-dev \
|
||||||
|
aria2 \
|
||||||
# Qt packages
|
# Qt packages
|
||||||
libqt5gui5 \
|
libqt5gui5 \
|
||||||
qtbase5-dev \
|
qtbase5-dev \
|
||||||
|
|
Loading…
Reference in New Issue