2008-04-20 10:51:16 +00:00
|
|
|
#
|
2010-02-16 03:04:02 +00:00
|
|
|
# Copyright (C) 2007-2010 OpenWrt.org
|
2007-09-22 16:07:24 +00:00
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=libtorrent
|
2010-11-28 18:02:09 +00:00
|
|
|
PKG_REV:=1189
|
2009-12-05 13:52:22 +00:00
|
|
|
PKG_VERSION:=0.12.6_r$(PKG_REV)
|
2010-11-28 18:02:09 +00:00
|
|
|
PKG_RELEASE:=3
|
2010-02-16 03:04:02 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
2009-04-03 09:14:09 +00:00
|
|
|
PKG_SOURCE_URL:=svn://rakshasa.no/libtorrent/trunk/libtorrent
|
|
|
|
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
|
|
|
PKG_SOURCE_VERSION:=$(PKG_REV)
|
|
|
|
PKG_SOURCE_PROTO:=svn
|
2007-09-22 16:07:24 +00:00
|
|
|
|
2010-02-16 03:04:02 +00:00
|
|
|
PKG_FIXUP:=libtool
|
|
|
|
PKG_INSTALL:=1
|
2007-12-27 02:12:04 +00:00
|
|
|
|
2007-09-22 16:07:24 +00:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/libtorrent
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=Rakshasa's BitTorrent library
|
|
|
|
URL:=http://libtorrent.rakshasa.no/
|
2010-10-05 23:56:19 +00:00
|
|
|
DEPENDS:=+libopenssl +libsigcxx @!LINUX_2_4
|
2007-09-22 16:07:24 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libtorrent/description
|
2010-02-16 03:04:02 +00:00
|
|
|
LibTorrent is a BitTorrent library written in C++ for *nix, with a focus
|
|
|
|
on high performance and good code. The library differentiates itself from
|
|
|
|
other implementations by transfering directly from file pages to the
|
|
|
|
network stack. On high-bandwidth connections it is able to seed at 3 times
|
2007-09-22 16:07:24 +00:00
|
|
|
the speed of the official client.
|
|
|
|
endef
|
|
|
|
|
2009-05-27 12:07:38 +00:00
|
|
|
ifneq ($(CONFIG_GCC_VERSION_3_4)$(CONFIG_GCC_VERSION_4_1),)
|
2010-07-16 13:29:10 +00:00
|
|
|
TARGET_CPPFLAGS += -fno-strict-aliasing
|
2009-05-27 12:07:38 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
TARGET_CPPFLAGS += -fno-inline
|
2011-03-02 12:03:40 +00:00
|
|
|
TARGET_LDFLAGS += $(LIBGCC_S)
|
2010-07-16 13:29:10 +00:00
|
|
|
|
2008-05-03 02:30:04 +00:00
|
|
|
# XXX: rtorrent needs encryption (--enable-openssl)
|
2007-09-22 16:07:24 +00:00
|
|
|
CONFIGURE_ARGS+= \
|
|
|
|
--enable-shared \
|
|
|
|
--enable-static \
|
|
|
|
--enable-aligned \
|
|
|
|
--disable-debug \
|
2008-05-03 02:30:04 +00:00
|
|
|
--enable-openssl \
|
2007-09-22 16:07:24 +00:00
|
|
|
|
2009-04-03 09:14:09 +00:00
|
|
|
define Build/Configure
|
|
|
|
(cd $(PKG_BUILD_DIR); ./autogen.sh );
|
|
|
|
$(call Build/Configure/Default)
|
|
|
|
endef
|
|
|
|
|
2007-09-22 16:07:24 +00:00
|
|
|
define Build/InstallDev
|
2008-05-03 02:30:04 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/include
|
2007-10-07 03:20:26 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/torrent $(1)/usr/include/
|
2008-05-03 02:30:04 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2007-10-07 03:20:26 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.{a,so*} $(1)/usr/lib/
|
2008-05-03 02:30:04 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
2007-10-07 03:20:26 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libtorrent.pc $(1)/usr/lib/pkgconfig/
|
2007-09-22 16:07:24 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libtorrent/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.so.* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(call BuildPackage,libtorrent))
|
|
|
|
|