aboutsummaryrefslogtreecommitdiff
path: root/net/nqptp
diff options
context:
space:
mode:
authorBen Klang <bklang@wirehack.net>2023-12-28 14:40:49 -0500
committerRosen Penev <rosenp@gmail.com>2024-01-02 15:15:00 -0800
commitd8dbf368103a3c73d8b7b5100a56b4d822980e09 (patch)
treea90222e55c18fc5ec4d5013341f7d19a58f01d06 /net/nqptp
parent0b95fe757fa23a5cbf092bcdbfa4f1b54e200550 (diff)
nqptp: Add new port nqptp for use with shairport-sync
Signed-off-by: Ben Klang <bklang@wirehack.net>
Diffstat (limited to 'net/nqptp')
-rw-r--r--net/nqptp/Makefile48
-rw-r--r--net/nqptp/files/nqptp.init15
2 files changed, 63 insertions, 0 deletions
diff --git a/net/nqptp/Makefile b/net/nqptp/Makefile
new file mode 100644
index 000000000..b16efecd3
--- /dev/null
+++ b/net/nqptp/Makefile
@@ -0,0 +1,48 @@
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+# updated to work with latest source from abrasive
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=nqptp
+PKG_VERSION:=1.2.4
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=https://codeload.github.com/mikebrady/nqptp/tar.gz/$(PKG_VERSION)?
+PKG_HASH:=1df1d5edd5b713010d6495b3abca4c1cf4ad8fa6029df0abeb9e4de8e0eb707a
+
+PKG_MAINTAINER:=Ben Klang <bklang@wirehack.net>
+PKG_LICENSE:=GPL-2.0-only
+PKG_LICENSE_FILES:=COPYING LICENSES nqptp.c
+
+PKG_FIXUP:=autoreconf
+PKG_BUILD_PARALLEL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/nqptp
+ SECTION:=net
+ CATEGORY:=Network
+ TITLE:=Not Quite Peer-to-Peer
+ URL:=https://github.com/mikebrady/nqptp
+endef
+
+define Package/nqptp/description
+ nqptp is a daemon that monitors timing data from PTP clocks it sees on ports
+ 319 and 320. It maintains records for one clock, identified by its Clock ID.
+
+ It is a companion application to Shairport Sync and provides timing
+ information for AirPlay 2 operation.
+endef
+
+define Package/nqptp/install
+ $(INSTALL_DIR) $(1)/usr/bin
+ $(INSTALL_BIN) $(PKG_BUILD_DIR)/nqptp $(1)/usr/bin/
+ $(INSTALL_DIR) $(1)/etc/init.d
+ $(INSTALL_BIN) ./files/nqptp.init $(1)/etc/init.d/nqptp
+endef
+
+$(eval $(call BuildPackage,nqptp))
diff --git a/net/nqptp/files/nqptp.init b/net/nqptp/files/nqptp.init
new file mode 100644
index 000000000..d40ef87dd
--- /dev/null
+++ b/net/nqptp/files/nqptp.init
@@ -0,0 +1,15 @@
+#!/bin/sh /etc/rc.common
+# Copyright (C) 2023 Ben Klang <bklang@wirehack.net>
+
+START=99
+USE_PROCD=1
+
+service_triggers() {
+ procd_add_reload_trigger "nqptp"
+}
+
+start_service() {
+ procd_open_instance
+ procd_set_param command /usr/bin/nqptp
+ procd_close_instance
+}