upgrade to 1.18.4, add build options
authorImre Kaloz <kaloz@openwrt.org>
Thu, 27 Mar 2014 11:04:46 +0000 (11:04 +0000)
committerImre Kaloz <kaloz@openwrt.org>
Thu, 27 Mar 2014 11:04:46 +0000 (11:04 +0000)
Signed-off-by: Imre Kaloz <kaloz@openwrt.org>
SVN-Revision: 40292

net/aria2/Config.in [new file with mode: 0644]
net/aria2/Makefile

diff --git a/net/aria2/Config.in b/net/aria2/Config.in
new file mode 100644 (file)
index 0000000..ec21faf
--- /dev/null
@@ -0,0 +1,28 @@
+menu "Aria2 configuration"
+       depends on PACKAGE_aria2
+
+choice
+       prompt "SSL library"
+       default ARIA2_OPENSSL
+
+config ARIA2_OPENSSL
+       bool "OpenSSL"
+
+config ARIA2_GNUTLS
+       bool "GNUTLS"
+
+config ARIA2_NOSSL
+       bool "No SSL support"
+
+endchoice
+
+config ARIA2_BITTORRENT
+       bool "Enable bittorrent support"
+       depends on ARIA2_OPENSSL
+       default n
+
+config ARIA2_METALINK
+       bool "Enable metalink support"
+       default N
+
+endmenu
index b09b4fdde05b9ecea3c5736c63af1dfc1ad9e527..12f38d6a4e932a98ad4c78275d0f938b08a21ddb 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2012 OpenWrt.org
+# Copyright (C) 2012-2014 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -7,24 +7,38 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=aria2
-PKG_VERSION:=1.17.1
+PKG_VERSION:=1.18.4
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=@SF/aria2
-PKG_MD5SUM:=86229ef8d289893934cb3af25c8fddf6
+PKG_MD5SUM:=d10fc5ee6e708760134e4cb963ecc98e
 PKG_INSTALL:=1
 
+PKG_MAINTAINER:=Imre Kaloz <kaloz@openwrt.org>
+PKG_LICENSE:=GPLv2
+PKG_LICENSE_FILES:=COPYING
+
+PKG_CONFIG_DEPENDS := \
+  ARIA2_NOSSL \
+  ARIA2_OPENSSL \
+  ARIA2_GNUTLS \
+  ARIA2_BITTORRENT \
+  ARIA2_METALINK
+
 include $(INCLUDE_DIR)/package.mk
 
+define Package/aria2/config
+  source "$(SOURCE)/Config.in"
+endef
+
 define Package/aria2
   SECTION:=net
   CATEGORY:=Network
   SUBMENU:=File Transfer
   TITLE:=lightweight download utility
   URL:=http://aria2.sourceforge.net/
-  DEPENDS:=+libopenssl +zlib +libxml2 +libstdcpp \
-       $(INTL_DEPENDS) $(ICONV_DEPENDS)
+  DEPENDS:=+zlib +ARIA2_METALINK:libxml2 +libstdcpp +ARIA2_OPENSSL:libopenssl +ARIA2_GNUTLS:libgnutls
 endef
 
 define Package/aria2/description
@@ -34,21 +48,20 @@ endef
 
 CONFIGURE_ARGS += \
        --disable-nls \
-       --without-gnutls \
+       $(if $(CONFIG_ARIA2_NOSSL),--disable,--enable)-ssl \
+       $(if $(CONFIG_ARIA2_OPENSSL),--with,--without)-openssl \
+       $(if $(CONFIG_ARIA2_GNUTLS),--with,--without)-gnutls \
+       $(if $(CONFIG_ARIA2_BITTORRENT),--enable,--disable)-bittorrent \
+       $(if $(CONFIG_ARIA2_METALINK),--enable,--disable)-metalink \
+       $(if $(CONFIG_ARIA2_METALINK),--with,--without)-libxml2 \
        --without-libnettle \
        --without-libgmp \
        --without-libgcrypt \
        --without-libexpat \
        --without-libcares \
        --without-sqlite3 \
-       --with-openssl \
-       --with-libxml2 \
        --with-libz
 
-CONFIGURE_VARS += \
-       ZLIB_CFLAGS="-I$(STAGING_DIR)/usr/include" \
-       ZLIB_LIBS="-L$(STAGING_DIR)/usr/lib"
-
 define Package/aria2/install
        $(INSTALL_DIR) $(1)/usr/bin
        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/aria2c $(1)/usr/bin