[PATCH] Add support for Appweb Embedded WebServer with Server-Side Javascript
[openwrt/svn-archive/archive.git] / net / appweb / Makefile
1 #
2 # Makefile for the Appweb Web Server
3 #
4 # Copyright (C) 2009 Embedthis Software
5 #
6 # This software is licensed under the GPLv2. Commercial and other licenses
7 # are available from http://www.embedthis.com.
8 #
9 # $Id$
10
11 include $(TOPDIR)/rules.mk
12
13 PKG_NAME:=appweb
14 PKG_RELEASE:=1
15
16 #
17 # Build 3.0B.3
18 #
19 PKG_SOURCE_URL:=http://www.appwebserver.org/software/
20 PKG_VERSION:=3.0B.2-3
21 PKG_MD5SUM:=b54a99d388a5588a9af33aa1c6354e06
22 PKG_SOURCE:=$(PKG_NAME)-src-$(PKG_VERSION).tar.gz
23 #
24 # Build the latest snapshot from the default trunk
25 #
26 # PKG_SOURCE:=tip.tar.gz
27 # PKG_SOURCE_URL:= http://hg.embedthis.com/appweb/archive/
28 # PKG_VERSION:=default
29 # PKG_MD5SUM:=
30
31 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
32
33 include $(INCLUDE_DIR)/package.mk
34
35 CONFIGURE_ARGS += -q --defaults=release --shared --tune=size --without-php \
36 --without-ssl --disable-angel --disable-samples --disable-access-log \
37 --disable-complete-native --disable-complete-cross --webdir=/www \
38 --logdir=/var/log --port=8000 --sslPort=8443 --config=flat
39
40 define Package/appweb
41 SECTION:=net
42 CATEGORY:=Network
43 TITLE:=Appweb Web Server
44 VERSION:=$(PKG_VERSION)
45 endef
46
47 define Package/appweb/description
48 Appweb is a powerful, compact embedded web server designed for dynamic web
49 applications.
50 endef
51
52 define Build/Prepare
53 rm -rf $(PKG_BUILD_DIR)
54 mkdir -p $(PKG_BUILD_DIR)
55 tar xzf "$(DL_DIR)/$(PKG_SOURCE)" --strip-components 1 -C "$(PKG_BUILD_DIR)"
56 endef
57
58 define Build/Configure
59 $(call Build/Configure/Default)
60 endef
61
62 define Build/Compile
63 $(MAKE) -C $(PKG_BUILD_DIR) $(TARGET_CONFIGURE_OPTS)
64 endef
65
66 define Package/appweb/install
67 ( cd $(PKG_BUILD_DIR) ; $(PKG_BUILD_DIR)/build/bin/makeInstall \
68 --root=$(1) --install --with-openwrt=1 binary )
69 endef
70
71 $(eval $(call BuildPackage,appweb))
72