aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjasle <jasle@riseup.net>2024-01-14 17:38:33 +0100
committerDaniel Golle <daniel@makrotopia.org>2024-03-04 00:28:42 +0000
commit0ee552762632f3e33ad697db1a96da15eaafa1fc (patch)
tree55f0767c19411e3b642db74ae7a42ee059e1f128
parent315b58a488e9347f756042ae88c7dfbc4d6442e6 (diff)
mt5311: add package
mt5311 are utilities for working with Metanoia/Proscend VDSL2 SFP Modems. Resulting package: * mt5311 Signed-off-by: jasle <jasle@riseup.net>
-rw-r--r--utils/mt5311/Makefile46
-rw-r--r--utils/mt5311/files/ebm-read4
2 files changed, 50 insertions, 0 deletions
diff --git a/utils/mt5311/Makefile b/utils/mt5311/Makefile
new file mode 100644
index 000000000..a0d43695b
--- /dev/null
+++ b/utils/mt5311/Makefile
@@ -0,0 +1,46 @@
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=mt5311
+PKG_RELEASE:=1
+
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/jimdigriz/mt5311.git
+PKG_SOURCE_VERSION:=2cb13045cd82474416e7f454b36f3a07b0de49d7
+PKG_MIRROR_HASH:=a1e1e9354fe9b9d6aa5da6b38ff6ef84458761533f9dbc55758dd403868c42ed
+
+PKG_MAINTAINER:=jasle <jasle@riseup.net>
+PKG_LICENSE:=AGPL-3.0-or-later
+PKG_LICENSE_FILES:=LICENSE
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/mt5311
+ SECTION:=utils
+ CATEGORY:=Utilities
+ TITLE:=Utilities for working with Metanoia/Proscend VDSL2 SFP Modems
+ URL:=https://github.com/jimdigriz/mt5311
+ DEPENDS:=+lua +luaposix +lua-struct
+endef
+
+define Package/mt5311/description
+ mt5311 is a tool to read status informationen from Metanoia/Proscend
+ VDSL2/Proscend VDSL2 SFP Modems.
+endef
+
+define Build/Compile
+ echo "Nothing to compile, pure lua package"
+endef
+
+define Package/mt5311/install
+ $(INSTALL_DIR) $(1)/usr/lib/lua/mt5311
+ $(INSTALL_DATA) $(PKG_BUILD_DIR)/ebm-read.lua $(1)/usr/lib/lua/mt5311/
+ $(INSTALL_DATA) $(PKG_BUILD_DIR)/ebm.lua $(1)/usr/lib/lua/mt5311/
+ $(INSTALL_DATA) $(PKG_BUILD_DIR)/register.lua $(1)/usr/lib/lua/mt5311/
+ $(INSTALL_DATA) $(PKG_BUILD_DIR)/register.map $(1)/usr/lib/lua/mt5311/
+
+ $(INSTALL_DIR) $(1)/usr/bin
+ $(INSTALL_BIN) ./files/ebm-read $(1)/usr/bin/
+endef
+
+$(eval $(call BuildPackage,mt5311))
+
diff --git a/utils/mt5311/files/ebm-read b/utils/mt5311/files/ebm-read
new file mode 100644
index 000000000..035f38588
--- /dev/null
+++ b/utils/mt5311/files/ebm-read
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+exec lua /usr/lib/lua/mt5311/ebm-read.lua "$@"
+