Merge pull request #549 from rkunze/sispmctl
sispmctl: import from oldpackages
This commit is contained in:
commit
78210c2255
2 changed files with 81 additions and 0 deletions
56
utils/sispmctl/Makefile
Normal file
56
utils/sispmctl/Makefile
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
#
|
||||||
|
# Copyright (C) 2008-2014 OpenWrt.org
|
||||||
|
#
|
||||||
|
# This is free software, licensed under the GNU General Public License v2.
|
||||||
|
# See /LICENSE for more information.
|
||||||
|
#
|
||||||
|
|
||||||
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
|
PKG_NAME:=sispmctl
|
||||||
|
PKG_VERSION:=3.1+20120206
|
||||||
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
|
PKG_SOURCE_PROTO:=git
|
||||||
|
PKG_SOURCE_VERSION:=5ff4a05a5bcb6a64a9d6f77fed47014512f66b11
|
||||||
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||||
|
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||||
|
PKG_SOURCE_URL:=git://git.code.sf.net/p/sispmctl/git
|
||||||
|
PKG_MAINTAINER:=Richard Kunze <richard.kunze@web.de>
|
||||||
|
PKG_LICENSE:=GPL-2.0+
|
||||||
|
|
||||||
|
PKG_INSTALL:=1
|
||||||
|
PKG_FIXUP:=autoreconf
|
||||||
|
|
||||||
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
|
||||||
|
define Package/sispmctl
|
||||||
|
SECTION:=utils
|
||||||
|
CATEGORY:=Utilities
|
||||||
|
TITLE:=Silver Shield PM Control for Linux
|
||||||
|
URL:=http://sispmctl.sourceforge.net/
|
||||||
|
DEPENDS:=+libusb-compat
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/sispmctl/description
|
||||||
|
The sispmctl tool can control Gembird SIS-PM Silver Shield
|
||||||
|
programmable power outlet strips (also known under the name
|
||||||
|
Revolt Intelli-Plug) from the command line.
|
||||||
|
.
|
||||||
|
It can be used to switch on or off any of the programmable
|
||||||
|
power sockets of the SIS-PM via USB. It can also show the
|
||||||
|
current status of each power socket, and it can handle
|
||||||
|
multiple SIS-PM devices, too.
|
||||||
|
endef
|
||||||
|
|
||||||
|
TARGET_CFLAGS += -D_GNU_SOURCE
|
||||||
|
CONFIGURE_ARGS += \
|
||||||
|
--enable-webless \
|
||||||
|
--disable-dependency-tracking
|
||||||
|
|
||||||
|
define Package/sispmctl/install
|
||||||
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/$(PKG_NAME) $(1)/usr/bin/
|
||||||
|
endef
|
||||||
|
|
||||||
|
$(eval $(call BuildPackage,sispmctl))
|
25
utils/sispmctl/patches/001-fix-includes.patch
Normal file
25
utils/sispmctl/patches/001-fix-includes.patch
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
--- a/src/sispm_ctl.c
|
||||||
|
+++ b/src/sispm_ctl.c
|
||||||
|
@@ -33,6 +33,7 @@
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <time.h>
|
||||||
|
+#include <sys/types.h>
|
||||||
|
#include <usb.h>
|
||||||
|
#include <assert.h>
|
||||||
|
#include "sispm_ctl.h"
|
||||||
|
--- a/src/main.c
|
||||||
|
+++ b/src/main.c
|
||||||
|
@@ -34,11 +34,11 @@
|
||||||
|
#define __USE_XOPEN
|
||||||
|
#include <time.h>
|
||||||
|
#include <signal.h>
|
||||||
|
-#include <usb.h>
|
||||||
|
#include <assert.h>
|
||||||
|
#include <getopt.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/socket.h>
|
||||||
|
+#include <usb.h>
|
||||||
|
|
||||||
|
#include <fcntl.h>
|
||||||
|
|
Loading…
Reference in a new issue