From 7c94f6150650828f0c65527d0b6b0466f926a713 Mon Sep 17 00:00:00 2001 From: Richard Kunze Date: Sun, 16 Nov 2014 09:50:20 +0100 Subject: [PATCH 1/2] sispmctl: import from oldpackages, bump version to 3.1+20120206 (git head) Signed-off-by: Richard Kunze --- utils/sispmctl/Makefile | 55 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 utils/sispmctl/Makefile diff --git a/utils/sispmctl/Makefile b/utils/sispmctl/Makefile new file mode 100644 index 000000000..87e15f58f --- /dev/null +++ b/utils/sispmctl/Makefile @@ -0,0 +1,55 @@ +# +# 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 +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 + +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)) From 773f8d4b1350d85200262758c6f89557c3d7c185 Mon Sep 17 00:00:00 2001 From: Richard Kunze Date: Sun, 16 Nov 2014 10:47:10 +0100 Subject: [PATCH 2/2] sispmctl: fix compilation error with musl Unpatched compile fails because is not included in (provided by "libusb-compat") and consequently the 'u_int*_t' types are not found. This should probably better be fixed in the core "libusb-compat" package instead. Signed-off-by: Richard Kunze --- utils/sispmctl/Makefile | 1 + utils/sispmctl/patches/001-fix-includes.patch | 25 +++++++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 utils/sispmctl/patches/001-fix-includes.patch diff --git a/utils/sispmctl/Makefile b/utils/sispmctl/Makefile index 87e15f58f..ad6c1e352 100644 --- a/utils/sispmctl/Makefile +++ b/utils/sispmctl/Makefile @@ -43,6 +43,7 @@ define Package/sispmctl/description multiple SIS-PM devices, too. endef +TARGET_CFLAGS += -D_GNU_SOURCE CONFIGURE_ARGS += \ --enable-webless \ --disable-dependency-tracking diff --git a/utils/sispmctl/patches/001-fix-includes.patch b/utils/sispmctl/patches/001-fix-includes.patch new file mode 100644 index 000000000..218e22e1c --- /dev/null +++ b/utils/sispmctl/patches/001-fix-includes.patch @@ -0,0 +1,25 @@ +--- a/src/sispm_ctl.c ++++ b/src/sispm_ctl.c +@@ -33,6 +33,7 @@ + #include + #include + #include ++#include + #include + #include + #include "sispm_ctl.h" +--- a/src/main.c ++++ b/src/main.c +@@ -34,11 +34,11 @@ + #define __USE_XOPEN + #include + #include +-#include + #include + #include + #include + #include ++#include + + #include +