aboutsummaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorTed Hess <thess@kitschensync.net>2015-08-21 14:40:30 -0400
committerTed Hess <thess@kitschensync.net>2015-08-21 14:40:30 -0400
commiteed20a34ff99a268bf6e5b80bf8c1db1afa8ed2b (patch)
tree9b4fcff0daf3b8b2d7bdca6f00da522d750f0ccd /utils
parent28804d8d9792d8e10c6008d8ea84c1cb3ce9d3e3 (diff)
crelay: Update to V0.9, add startup config file
Signed-off-by: Ted Hess <thess@kitschensync.net>
Diffstat (limited to 'utils')
-rw-r--r--utils/crelay/Makefile5
-rw-r--r--utils/crelay/files/crelay.init9
-rw-r--r--utils/crelay/patches/010-link_with_ftdi1.patch4
3 files changed, 8 insertions, 10 deletions
diff --git a/utils/crelay/Makefile b/utils/crelay/Makefile
index 59c763f9a..8a5f7dc90 100644
--- a/utils/crelay/Makefile
+++ b/utils/crelay/Makefile
@@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=crelay
-PKG_VERSION:=0.8-081415
+PKG_VERSION:=0.9
PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/ondrej1024/crelay
-PKG_SOURCE_VERSION:=037360cf143d705ea97b32ae22460f346ad2586f
+PKG_SOURCE_VERSION:=V$(PKG_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
@@ -65,6 +65,7 @@ define Package/crelay/install
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/crelay $(1)/usr/bin/
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/crelay.init $(1)/etc/init.d/crelay
+ $(INSTALL_CONF) $(PKG_BUILD_DIR)/conf/crelay.conf $(1)/etc
endef
$(eval $(call BuildPackage,crelay))
diff --git a/utils/crelay/files/crelay.init b/utils/crelay/files/crelay.init
index 2f4647500..e00396118 100644
--- a/utils/crelay/files/crelay.init
+++ b/utils/crelay/files/crelay.init
@@ -8,17 +8,14 @@ PROG=/usr/bin/${NAME}
USE_PROCD=1
-# Custom relay labels (for Web GUI)
-LABEL1=""
-LABEL2=""
-LABEL3=""
-LABEL4=""
+# Custom relay labels (for Web GUI) are defined in /etc/crelay.conf
start_service() {
procd_open_instance
procd_set_param command "$PROG"
- procd_append_param command -d "$LABEL1 $LABEL2 $LABEL3 $LABEL4"
+ # daemon mode (not daemonized) - starts HTTP server
+ procd_append_param command -d
procd_close_instance
}
diff --git a/utils/crelay/patches/010-link_with_ftdi1.patch b/utils/crelay/patches/010-link_with_ftdi1.patch
index 756d45a9c..bc4ff1ed3 100644
--- a/utils/crelay/patches/010-link_with_ftdi1.patch
+++ b/utils/crelay/patches/010-link_with_ftdi1.patch
@@ -1,10 +1,10 @@
--- a/src/Makefile
+++ b/src/Makefile
-@@ -44,7 +44,7 @@ endif
+@@ -45,7 +45,7 @@ endif
#ifdef DRV_SAINSMART
ifeq ($(DRV_SAINSMART), y)
SRC += relay_drv_sainsmart.c
--LIBS += -lftdi
+-LIBS += -lftdi
+LIBS += -lftdi1
OPTS += -DDRV_SAINSMART
endif