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.

73 lines
1.7 KiB

11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
  1. #
  2. # Copyright (C) 2010-2012 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:=miniupnpc
  9. PKG_VERSION:=2.2.1
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=https://miniupnp.tuxfamily.org/files
  13. PKG_HASH:=3a3167e57727bf1d2a7b4861f7c7b57a663f58b9cf68227762ed2fc64e8ea11f
  14. PKG_MAINTAINER:=
  15. PKG_LICENSE:=BSD-3-Clause
  16. PKG_LICENSE_FILES:=LICENSE
  17. PKG_CPE_ID:=cpe:/a:miniupnp_project:miniupnp
  18. PKG_BUILD_PARALLEL:=1
  19. include $(INCLUDE_DIR)/package.mk
  20. include $(INCLUDE_DIR)/cmake.mk
  21. define Package/miniupnpc/Default
  22. TITLE:=Lightweight UPnP
  23. URL:=https://miniupnp.tuxfamily.org
  24. endef
  25. define Package/miniupnpc
  26. $(call Package/miniupnpc/Default)
  27. SECTION:=net
  28. CATEGORY:=Network
  29. SUBMENU:=Firewall
  30. TITLE+= client
  31. DEPENDS:=+libminiupnpc
  32. endef
  33. define Package/libminiupnpc
  34. $(call Package/miniupnpc/Default)
  35. SECTION:=libs
  36. CATEGORY:=Libraries
  37. TITLE+= library
  38. endef
  39. CMAKE_OPTIONS += -DUPNPC_BUILD_TESTS=OFF
  40. TARGET_CFLAGS += $(FPIC)
  41. TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed
  42. define Build/InstallDev
  43. $(INSTALL_DIR) $(1)/usr/include
  44. $(INSTALL_DIR) $(1)/usr/lib
  45. $(CP) $(PKG_INSTALL_DIR)/usr/include/miniupnpc/ $(1)/usr/include/
  46. $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*.{a,so*} $(1)/usr/lib/
  47. endef
  48. define Package/miniupnpc/install
  49. $(INSTALL_DIR) $(1)/usr/bin
  50. $(INSTALL_BIN) $(PKG_BUILD_DIR)/upnpc-shared $(1)/usr/bin/upnpc
  51. $(INSTALL_BIN) $(PKG_BUILD_DIR)/listdevices $(1)/usr/bin/
  52. endef
  53. define Package/libminiupnpc/install
  54. $(INSTALL_DIR) $(1)/usr/lib
  55. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libminiupnpc.so.* $(1)/usr/lib/
  56. endef
  57. $(eval $(call BuildPackage,miniupnpc))
  58. $(eval $(call BuildPackage,libminiupnpc))