Makefile cleanups, round 4
[openwrt/svn-archive/archive.git] / utils / cmdpad / Makefile
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id: $
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=cmdpad
12 PKG_VERSION:=0.0.3
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
16 PKG_SOURCE_URL:=http://prdownloads.sourceforge.net/cmdpad/
17 PKG_MD5SUM:=6633b2354b7f23f9cd8e2bfb6e735965
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/cmdpad
22 SECTION:=utils
23 CATEGORY:=Utilities
24 TITLE:=execute commands when a key is pressed, released or hold down
25 URL:=http://cmdpad.sourceforge.net/index.php
26 endef
27
28 CONFIGURE_ARGS += \
29 --enable-static \
30 --enable-shared
31
32 define Package/cmdpad/description
33 cmdpad - execute commands when a key is pressed, released or hold down.
34 Should be started from /etc/rc or /etc/rc.local. To run it as deamon you
35 need to start it with '&'. All logs are printed to standard out and standard
36 error (to write the log to disk use cmdpad > /var/log/cmdpad). Cmdpad
37 searches for /etc/cmdpad.conf and load the key bindings. Then wait for
38 key event and check each command to see if it should be run.
39 endef
40
41 MAKE_FLAGS += \
42 $(TARGET_CONFIGURE_OPTS) \
43 $(1)
44
45 define Package/cmdpad/install
46 $(INSTALL_DIR) $(1)/usr/sbin
47 $(INSTALL_DIR) $(1)/etc
48 $(INSTALL_DIR) $(1)/etc/init.d
49 $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/cmdpad $(1)/usr/sbin
50 $(INSTALL_CONF) $(PKG_BUILD_DIR)/src/cmdpad.conf $(1)/etc
51 $(INSTALL_BIN) ./files/cmdpad.init $(1)/etc/init.d/cmdpad
52 endef
53
54 $(eval $(call BuildPackage,cmdpad))