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