libsoup: fix compilation with libml2 1.12
[feed/packages.git] / net / rtorrent / Makefile
1 #
2 # Copyright (C) 2007-2015 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=rtorrent
11 PKG_VERSION:=0.9.8
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=https://codeload.github.com/rakshasa/rtorrent/tar.gz/v$(PKG_VERSION)?
16 PKG_HASH:=bc889ce1dde475ec56aa72ae996912ff58723226a4f4256fef4f1f8636d991d4
17
18 PKG_MAINTAINER:=Rosen Penev <rosenp@gmail.com>
19 PKG_LICENSE:=GPL-2.0-or-later
20 PKG_LICENSE_FILES:=COPYING
21
22 PKG_FIXUP:=autoreconf
23 PKG_INSTALL:=1
24 PKG_BUILD_PARALLEL:=1
25 PKG_BUILD_DEPENDS:=libtorrent
26
27 include $(INCLUDE_DIR)/package.mk
28
29 define Package/rtorrent/Default
30 SUBMENU:=BitTorrent
31 SECTION:=net
32 CATEGORY:=Network
33 TITLE:=BitTorrent client for ncurses
34 URL:=https://github.com/rakshasa/rtorrent
35 DEPENDS:=+libcurl +libncurses +libpthread +libopenssl +libstdcpp +zlib
36 endef
37
38 define Package/rtorrent/Default/description
39 rTorrent is a BitTorrent client for ncurses, using the libtorrent library.
40 The client and library is written in C++ with emphasis on speed and
41 efficiency, while delivering equivalent features to those found in GUI based
42 clients in an ncurses client.
43 endef
44
45 define Package/rtorrent
46 $(call Package/rtorrent/Default)
47 VARIANT:=norpc
48 endef
49
50 define Package/rtorrent/description
51 $(call Package/rtorrent/Default/description)
52 This package is built without xmlrpc support
53 endef
54
55 define Package/rtorrent-rpc
56 $(call Package/rtorrent/Default)
57 VARIANT:=rpc
58 DEPENDS+=+xmlrpc-c-server
59 TITLE+=(with rpc support)
60 endef
61
62 define Package/rtorrent-rpc/description
63 $(call Package/rtorrent/Default/description)
64 This package is built with xmlrpc support
65 endef
66
67 CONFIGURE_ARGS += \
68 --enable-static \
69 --disable-shared \
70 --disable-debug \
71 --with-libcurl="$(STAGING_DIR)/usr" \
72 --with-ncurses \
73 $(if $(CONFIG_IPV6),--enable,--disable)-ipv6
74
75 ifeq ($(BUILD_VARIANT),rpc)
76 CONFIGURE_ARGS += --with-xmlrpc-c
77 endif
78
79 TARGET_CXXFLAGS += -faligned-new
80 TARGET_LDFLAGS += -lcrypto -lz
81
82 define Package/rtorrent/install
83 $(INSTALL_DIR) $(1)/usr/bin
84 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/rtorrent $(1)/usr/bin/
85 endef
86
87 Package/rtorrent-rpc/install = $(Package/rtorrent/install)
88
89 $(eval $(call BuildPackage,rtorrent))
90 $(eval $(call BuildPackage,rtorrent-rpc))