From 04e30866d7fd036f7ea0f2613a544e6f484cb38a Mon Sep 17 00:00:00 2001 From: tripolar Date: Sun, 20 Apr 2014 10:33:08 +0000 Subject: [PATCH] [packages] rtorrent: update to git head and add 2 distinct rtorrent versions: rtorrent-rpc - rtorrent with rpc support rtorrent - rtorrent without rpc support Signed-off-by: Peter Wagner git-svn-id: svn://svn.openwrt.org/openwrt/packages@40537 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- net/rtorrent/Makefile | 45 ++++++++++++++++++++++++++++++++++++------- 1 file changed, 38 insertions(+), 7 deletions(-) diff --git a/net/rtorrent/Makefile b/net/rtorrent/Makefile index 41031713a..9e3dae594 100644 --- a/net/rtorrent/Makefile +++ b/net/rtorrent/Makefile @@ -9,44 +9,72 @@ include $(TOPDIR)/rules.mk PKG_NAME:=rtorrent PKG_VERSION:=0.9.3-git - PKG_RELEASE:=$(PKG_SOURCE_VERSION)-1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/rakshasa/rtorrent.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=7689059dbc1ee05f855eb28883cbe59d162d4431 +PKG_SOURCE_VERSION:=82a68420f4d90098e00cc92f082f10a8079e9800 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_FIXUP:=autoreconf PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) + include $(INCLUDE_DIR)/package.mk -define Package/rtorrent +define Package/rtorrent/Default SUBMENU:=BitTorrent SECTION:=net CATEGORY:=Network TITLE:=BitTorrent client for ncurses URL:=http://libtorrent.rakshasa.no/ - DEPENDS:=+libcurl +libtorrent +libncursesw +libsigcxx +xmlrpc-c-server +libpthread + DEPENDS:=+libcurl +libtorrent +libncursesw +libsigcxx +libpthread endef -define Package/rtorrent/description +define Package/rtorrent/Default/description rTorrent is a BitTorrent client for ncurses, using the libtorrent library. The client and library is written in C++ with emphasis on speed and efficiency, while delivering equivalent features to those found in GUI based clients in an ncurses client. endef +define Package/rtorrent +$(call Package/rtorrent/Default) + VARIANT:=norpc +endef + +define Package/rtorrent/description +$(call Package/rtorrent/Default/description) + This package is built without xmlrpc support +endef + +define Package/rtorrent-rpc +$(call Package/rtorrent/Default) + VARIANT:=rpc + DEPENDS+=+xmlrpc-c-server + TITLE+=(with rpc support) +endef + +define Package/rtorrent-rpc/description +$(call Package/rtorrent/Default/description) + This package is built with xmlrpc support +endef + TARGET_LDFLAGS += -lpthread -Wl,-rpath-link=$(STAGING_DIR)/usr/lib CONFIGURE_ARGS+= \ --enable-shared \ --disable-static \ - --disable-debug \ - --with-xmlrpc-c + --disable-debug + +ifeq ($(BUILD_VARIANT),rpc) + CONFIGURE_ARGS += \ + --with-xmlrpc-c +endif + define Build/Configure ( cd $(PKG_BUILD_DIR); ./autogen.sh ); @@ -58,4 +86,7 @@ define Package/rtorrent/install $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/rtorrent $(1)/usr/bin/ endef +Package/rtorrent-rpc/install = $(Package/rtorrent/install) + $(eval $(call BuildPackage,rtorrent)) +$(eval $(call BuildPackage,rtorrent-rpc))