1
0
mirror of git://projects.qi-hardware.com/openwrt-packages.git synced 2024-12-22 08:34:16 +02:00

cgminer: add a simple monitor file for cron job

This commit is contained in:
Xiangfu 2012-05-20 18:05:35 +08:00
parent a459845e1e
commit f12878f893
2 changed files with 9 additions and 2 deletions

View File

@ -12,7 +12,7 @@ PKG_NAME:=cgminer
PKG_VERSION:=20120516
PKG_REV:=b69d735cfe468c489a24677ffef1d6d998818cac
# this is upstream version 2.4.1
PKG_RELEASE:=3
PKG_RELEASE:=4
PKG_INSTALL:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_REV).tar.gz
@ -55,7 +55,8 @@ define Package/cgminer/install
$(INSTALL_BIN) $(PKG_BUILD_DIR)/cgminer-api $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/cgminer $(1)/usr/bin
$(INSTALL_BIN) $(FILES_DIR)/cgminer.init $(1)/etc/init.d/cgminer
$(INSTALL_BIN) $(FILES_DIR)/cgminer-monitor $(1)/usr/bin
$(INSTALL_BIN) $(FILES_DIR)/cgminer.init $(1)/etc/init.d/cgminer
$(CP) $(FILES_DIR)/20-cgminer.hotplug $(1)/etc/hotplug.d/usb/20-cgminer
endef

6
cgminer/files/cgminer-monitor Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
# This file is for cron job
if ! pidof cgminer; then
/etc/init.d/cgminer start
fi