Makefile 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=gluon-mesh-batman-adv
  3. PKG_VERSION:=1
  4. PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
  5. PKG_BUILD_DEPENDS := respondd
  6. include ../gluon.mk
  7. define Package/gluon-mesh-batman-adv/common
  8. SECTION:=gluon
  9. CATEGORY:=Gluon
  10. PROVIDES:=gluon-mesh-batman-adv
  11. DEPENDS:=+gluon-core +libgluonutil +gluon-client-bridge +gluon-ebtables +firewall +libiwinfo +kmod-dummy +libnl-tiny
  12. endef
  13. define Package/gluon-mesh-batman-adv-14
  14. $(Package/gluon-mesh-batman-adv/common)
  15. TITLE:=Support for batman-adv meshing (compat level 14)
  16. CONFLICTS:=gluon-mesh-batman-adv-15
  17. DEPENDS+=+kmod-batman-adv-legacy
  18. endef
  19. define Package/gluon-mesh-batman-adv-15
  20. $(Package/gluon-mesh-batman-adv/common)
  21. TITLE:=Support for batman-adv meshing (compat level 15)
  22. DEPENDS+=+kmod-batman-adv +batctl
  23. endef
  24. define Build/Prepare
  25. mkdir -p $(PKG_BUILD_DIR)
  26. $(CP) ./src/* $(PKG_BUILD_DIR)/
  27. endef
  28. define Build/Compile
  29. $(call Build/Compile/Default)
  30. $(call GluonSrcDiet,./luasrc,$(PKG_BUILD_DIR)/luadest/)
  31. endef
  32. define Package/gluon-mesh-batman-adv/common/install
  33. $(CP) ./files/* $(1)/
  34. $(CP) $(PKG_BUILD_DIR)/luadest/* $(1)/
  35. $(INSTALL_DIR) $(1)/lib/gluon/respondd
  36. $(CP) $(PKG_BUILD_DIR)/respondd.so $(1)/lib/gluon/respondd/mesh-batman-adv.so
  37. $(INSTALL_DIR) $(1)/lib/gluon/mesh-batman-adv
  38. endef
  39. define Package/gluon-mesh-batman-adv-14/install
  40. $(Package/gluon-mesh-batman-adv/common/install)
  41. echo 14 > $(1)/lib/gluon/mesh-batman-adv/compat
  42. endef
  43. define Package/gluon-mesh-batman-adv-15/install
  44. $(Package/gluon-mesh-batman-adv/common/install)
  45. echo 15 > $(1)/lib/gluon/mesh-batman-adv/compat
  46. endef
  47. define Package/gluon-mesh-batman-adv/common/postinst
  48. #!/bin/sh
  49. $(call GluonCheckSite,check_site.lua)
  50. endef
  51. Package/gluon-mesh-batman-adv-14/postinst := $(Package/gluon-mesh-batman-adv/common/postinst)
  52. Package/gluon-mesh-batman-adv-15/postinst := $(Package/gluon-mesh-batman-adv/common/postinst)
  53. $(eval $(call BuildPackage,gluon-mesh-batman-adv-14))
  54. $(eval $(call BuildPackage,gluon-mesh-batman-adv-15))