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.

76 lines
2.2 KiB

  1. #
  2. # Copyright (C) 2019 EWSI
  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:=dcwapd
  9. PKG_VERSION:=1.1.0
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=https://codeload.github.com/ewsi/$(PKG_NAME)/tar.gz/v$(PKG_VERSION)?
  13. PKG_HASH:=58e52bf4e7526b2f26319740549dbcc6f6ab505f587815ee8731e40f7fecb625
  14. PKG_MAINTAINER:=Carey Sonsino <careys@edgewaterwireless.com>
  15. PKG_LICENSE:=Apache-2.0
  16. PKG_LICENSE_FILES:=COPYING
  17. PKG_FIXUP:=autoreconf
  18. PKG_INSTALL:=1
  19. PKG_BUILD_PARALLEL:=1
  20. include $(INCLUDE_DIR)/uclibc++.mk
  21. include $(INCLUDE_DIR)/package.mk
  22. define Package/dcwapd
  23. SECTION:=net
  24. CATEGORY:=Network
  25. SUBMENU:=Routing and Redirection
  26. TITLE:=Dual-Channel WiFi AP daemon
  27. URL:=https://www.edgewaterwireless.com
  28. DEPENDS:=$(CXX_DEPENDS) +kmod-macremapper +libdcwsocket +libdcwproto +mrmctl +libuci
  29. endef
  30. define Package/dcwapd/description
  31. Implementation of the Dual-Channel WiFi AP daemon
  32. endef
  33. CONFIGURE_ARGS += \
  34. --enable-platform=linuxjsonstatic \
  35. --enable-shared
  36. TARGET_CXXFLAGS += -std=c++11 -DRAPIDJSON_HAS_CXX11_RVALUE_REFS=0 -ffunction-sections -fdata-sections -flto
  37. TARGET_LDFLAGS += -ldcwproto -ldcwsocket -lmrmfilterparser -luci -Wl,--gc-sections,--as-needed
  38. define Build/InstallDev
  39. $(INSTALL_DIR) $(1)/usr/lib
  40. $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/
  41. endef
  42. define Package/dcwapd/install
  43. $(INSTALL_DIR) $(1)/bin
  44. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/$(PKG_NAME) $(1)/bin/
  45. $(INSTALL_DIR) $(1)/usr/lib
  46. # Note: $(INSTALL_BIN) does not keep symlinks, so use $(CP)
  47. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
  48. # Utility files
  49. $(INSTALL_DIR) $(1)/etc/$(PKG_NAME)
  50. $(INSTALL_DATA) ./files/*.inc $(1)/etc/$(PKG_NAME)/
  51. $(INSTALL_BIN) ./files/*.sh $(1)/etc/$(PKG_NAME)/
  52. # UCI config file copy - this is here for convenience and reference only
  53. $(INSTALL_DATA) ./files/dcwapd.uci $(1)/etc/$(PKG_NAME)/
  54. # UCI config file
  55. $(INSTALL_DIR) $(1)/etc/config
  56. $(INSTALL_DATA) ./files/dcwapd.uci $(1)/etc/config/dcwapd
  57. # Init script
  58. $(INSTALL_DIR) $(1)/etc/init.d
  59. $(INSTALL_BIN) ./files/dcwapd.init.d $(1)/etc/init.d/dcwapd
  60. endef
  61. $(eval $(call BuildPackage,dcwapd))