replace lots of manual install commands with INSTALL_* variables
[openwrt/svn-archive/archive.git] / net / htpdate / Makefile
1 #
2 # Copyright (C) 2006 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:=htpdate
12 PKG_VERSION:=0.9.0
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://www.clevervest.com/htp/archive/c/
17 PKG_MD5SUM:=12cf883c5619cf4c13a62f77f1a55b54
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/htpdate
26 SECTION:=net
27 CATEGORY:=Network
28 TITLE:=an HTP (Hypertext Time Protocol) implementation
29 URL:=http://www.clevervest.com/htp/
30 endef
31
32 define Package/htpdate/conffiles
33 /etc/default/htpdate
34 endef
35
36 define Build/Compile
37 $(MAKE) -C $(PKG_BUILD_DIR) \
38 $(TARGET_CONFIGURE_OPTS) \
39 CFLAGS="$(TARGET_CFLAGS)"
40 endef
41
42
43 define Package/htpdate/install
44 $(INSTALL_DIR) $(1)/usr/sbin
45 $(INSTALL_BIN) $(PKG_BUILD_DIR)/htpdate $(1)/usr/sbin/
46 $(INSTALL_DIR) $(1)/etc/default/
47 $(INSTALL_DATA) ./files/htpdate.default $(1)/etc/default/htpdate
48 $(INSTALL_DIR) $(1)/etc/init.d/
49 $(INSTALL_BIN) ./files/htpdate.init $(1)/etc/init.d/htpdate
50 endef
51
52 $(eval $(call BuildPackage,htpdate))
53