Merge pull request #4820 from dibdot/adblock
[feed/packages.git] / utils / relayctl / Makefile
1 # Copyright (C) 2016 OpenWrt.org
2 #
3 # This is free software, licensed under the GNU General Public License v2.
4 # See /LICENSE for more information.
5 #
6
7 include $(TOPDIR)/rules.mk
8
9 PKG_NAME:=relayctl
10 PKG_VERSION:=0.1
11 PKG_RELEASE:=3
12
13 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
14 PKG_SOURCE_URL:=@SF/relayctl/relayctl-$(PKG_VERSION)
15 PKG_MAINTAINER:=Heinrich Schuchardt <xypron.glpk@gmx.de>
16 PKG_HASH:=74ce41ebd5d18816d52b5f9b1071f658f5a814b8194257f20700214bbee9de1e
17 PKG_LICENSE:=BSD-3-Clause
18 PKG_LICENSE_FILES:=COPYING
19
20 PKG_INSTALL:=1
21 PKG_FIXUP:=autoreconf
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/relayctl
26 SECTION:=utils
27 CATEGORY:=Utilities
28 TITLE:=Simple command-line control of SainSmart USB relay boards
29 URL:=https://github.com/darryln/relayctl
30 DEPENDS:= +libftdi1
31 endef
32
33 define Package/relayctl/description
34 Simple command-line control of SainSmart USB relay boards based on
35 FTDI chips using bitbang mode.
36 endef
37
38 TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/libftdi1
39
40 define Package/relayctl/install
41 $(INSTALL_DIR) $(1)/usr/bin
42 $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/$(PKG_NAME) $(1)/usr/bin/
43 $(INSTALL_DIR) $(1)/lib/udev/rules.d/
44 $(CP) $(PKG_BUILD_DIR)/examples/60-relayctl.rules $(1)/lib/udev/rules.d/
45 endef
46
47 $(eval $(call BuildPackage,relayctl))