* Added preliminary HTTPD construct
[project/luci.git] / Makefile
1 include build/config.mk
2
3 MODULES = applications/* libs/* modules/* themes/* i18n/* contrib/luaposix
4 LUA_TARGET = source
5
6 OS:=$(shell uname)
7 export OS
8
9 .PHONY: all build gccbuild luabuild clean host gcchost luahost hostcopy hostclean
10
11 all: build
12
13 build: luabuild gccbuild
14
15 gccbuild:
16         for i in $(MODULES); do make -C$$i compile; done        
17
18 luabuild:
19         for i in $(MODULES); do make -C$$i lua$(LUA_TARGET); done
20
21 clean:
22         for i in $(MODULES); do make -C$$i clean; done
23
24
25 host: build hostcopy
26
27 gcchost: gccbuild hostcopy
28
29 luahost: luabuild hostcopy
30
31 hostcopy: 
32         mkdir -p host
33         for i in $(MODULES); do cp -a $$i/dist/* host/ -R 2>/dev/null || true; done
34         rm -f host/luci
35         ln -s .$(LUCI_MODULEDIR) host/luci
36
37 run: host
38         libs/sgi-webuci/host/buildconfig.sh `pwd`/host  > host/etc/boa/boa.conf
39         ./host/usr/bin/boa -c ./host/etc/boa -d
40
41 hostclean: clean
42         rm -rf host