You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
1.9 KiB

  1. #
  2. # Copyright (C) 2007-2013 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=libtorrent
  9. PKG_VERSION:=0.13.4-git
  10. PKG_RELEASE=$(PKG_SOURCE_VERSION)-1
  11. PKG_SOURCE_PROTO:=git
  12. PKG_SOURCE_URL:=https://github.com/rakshasa/libtorrent.git
  13. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  14. PKG_SOURCE_VERSION:=51cd5ea8913a5f5062813d9f5b6256c76d41ea11
  15. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
  16. PKG_FIXUP:=autoreconf
  17. PKG_BUILD_PARALLEL:=1
  18. PKG_INSTALL:=1
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/libtorrent
  21. SECTION:=libs
  22. CATEGORY:=Libraries
  23. TITLE:=Rakshasa's BitTorrent library
  24. URL:=http://libtorrent.rakshasa.no/
  25. DEPENDS:=+libopenssl +libsigcxx
  26. endef
  27. define Package/libtorrent/description
  28. LibTorrent is a BitTorrent library written in C++ for *nix, with a focus on
  29. high performance and good code. The library differentiates itself from other
  30. implementations by transfering directly from file pages to the network stack.
  31. On high-bandwidth connections it is able to seed at 3 times the speed of the
  32. official client.
  33. endef
  34. TARGET_LDFLAGS += $(LIBGCC_S)
  35. CONFIGURE_ARGS+= \
  36. --enable-shared \
  37. --enable-static \
  38. --enable-aligned \
  39. --disable-debug \
  40. --enable-openssl \
  41. --disable-instrumentation
  42. define Build/Configure
  43. ( cd $(PKG_BUILD_DIR); ./autogen.sh );
  44. $(call Build/Configure/Default)
  45. endef
  46. define Build/InstallDev
  47. $(INSTALL_DIR) $(1)/usr/include
  48. $(CP) $(PKG_INSTALL_DIR)/usr/include/torrent $(1)/usr/include/
  49. $(INSTALL_DIR) $(1)/usr/lib
  50. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.{a,so*} $(1)/usr/lib/
  51. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  52. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libtorrent.pc $(1)/usr/lib/pkgconfig/
  53. endef
  54. define Package/libtorrent/install
  55. $(INSTALL_DIR) $(1)/usr/lib
  56. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.so.* $(1)/usr/lib/
  57. endef
  58. $(eval $(call BuildPackage,libtorrent))