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.

56 lines
1.5 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:=libdcwsocket
  9. PKG_VERSION:=1.1.0
  10. PKG_RELEASE:=2
  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_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  14. PKG_HASH:=71383c4d8c5f58c1299a3717d7de9a8b5dabfd51a2dcf9993248f2709908d23a
  15. PKG_MAINTAINER:=Carey Sonsino <careys@edgewaterwireless.com>
  16. PKG_LICENSE:=Apache-2.0
  17. PKG_LICENSE_FILES:=COPYING
  18. PKG_INSTALL:=1
  19. PKG_BUILD_PARALLEL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/libdcwsocket
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. SUBMENU:=Networking
  25. TITLE:=Dual-Channel socket library
  26. URL:=https://www.edgewaterwireless.com
  27. endef
  28. define Package/libdcwsocket/description
  29. User-land C library for sending and receiving DCW "EtherType"d messages
  30. endef
  31. TARGET_CFLAGS += -std=c89 -ffunction-sections -fdata-sections -flto
  32. TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed
  33. define Build/InstallDev
  34. $(INSTALL_DIR) $(1)/usr/include
  35. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
  36. $(INSTALL_DIR) $(1)/usr/lib
  37. $(CP) $(PKG_INSTALL_DIR)/usr/lib/$(PKG_NAME)*.so* $(1)/usr/lib/
  38. endef
  39. define Package/libdcwsocket/install
  40. $(INSTALL_DIR) $(1)/usr/lib
  41. # Note: $(INSTALL_BIN) does not keep symlinks, so use $(CP)
  42. $(CP) $(PKG_INSTALL_DIR)/usr/lib/$(PKG_NAME)*.so* $(1)/usr/lib/
  43. endef
  44. $(eval $(call BuildPackage,libdcwsocket))