* CBI update
[project/luci.git] / contrib / package / ffluci / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=ffluci
4 PKG_VERSION:=0.2
5 PKG_RELEASE:=1
6
7 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
8 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
9
10 MAKE_ACTION:=dist-source
11
12 include $(INCLUDE_DIR)/package.mk
13
14 define Package/ffluci
15 SECTION:=admin
16 CATEGORY:=Administration
17 TITLE:=FFLuCI
18 DEPENDS:=+liblua +luafilesystem +haserl
19 MAINTAINER:=Steven Barth <steven-at-midlink-dot-org>
20 endef
21
22 define Build/Prepare
23 mkdir -p $(PKG_BUILD_DIR)
24 $(CP) ./src/* $(PKG_BUILD_DIR)/ -R
25 endef
26
27 define Build/Configure
28 endef
29
30 define Build/Compile
31 $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ACTION)
32 endef
33
34 define Package/ffluci/install
35 $(INSTALL_DIR) $(1)/usr/lib/lua
36 $(INSTALL_DIR) $(1)/www/cgi-bin
37 $(INSTALL_DIR) $(1)/www/ffluci
38 $(CP) $(PKG_BUILD_DIR)/dist/* $(1)/usr/lib/lua/ -R
39 $(CP) $(PKG_BUILD_DIR)/contrib/media $(1)/www/ffluci/ -R
40 $(INSTALL_BIN) $(PKG_BUILD_DIR)/contrib/ffluci $(1)/www/cgi-bin
41 $(INSTALL_BIN) $(PKG_BUILD_DIR)/contrib/index.cgi $(1)/www/cgi-bin
42 $(CP) $(PKG_BUILD_DIR)/contrib/ffluci.uci $(1)/etc/config/luci
43 $(CP) -a ./ipkg/ffluci.postinst $(1)/CONTROL/postinst
44 $(CP) -a ./ipkg/conffiles $(1)/CONTROL/conffiles
45 endef
46
47 $(eval $(call BuildPackage,ffluci))