contrib/package: make luci-freifunk-community dependant on olsrd-luci-mod-watchdog
[project/luci.git] / contrib / package / luci / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_BRANCH:=trunk
4
5 ifeq ($(DUMP),)
6   USELOCAL:=$(shell grep luci ../../../.project 2>/dev/null >/dev/null && echo 1)
7 endif
8
9 PKG_NAME:=luci
10 PKG_RELEASE:=1
11
12 ifeq ($(USELOCAL),1)
13   PKG_VERSION:=0.9+svn
14 else
15   PKG_SOURCE_URL:=http://svn.luci.subsignal.org/luci/$(PKG_BRANCH)
16   ifeq ($(DUMP),)
17     PKG_REV:=$(shell LC_ALL=C svn info ${PKG_SOURCE_URL} | sed -ne's/^Revision: //p')
18     PKG_VERSION:=0.9+svn$(PKG_REV)
19   endif
20   PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
21   PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz
22   PKG_SOURCE_PROTO:=svn
23   PKG_SOURCE_VERSION:=$(PKG_REV)
24 endif
25
26 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
27 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
28
29 PKG_BUILD_DEPENDS:=libnotimpl
30 LUA_TARGET:=source
31 PKG_SELECTED_MODULES:=
32
33
34 include $(INCLUDE_DIR)/package.mk
35
36 ifeq ($(USELOCAL),1)
37   define Build/Prepare
38         mkdir -p $(PKG_BUILD_DIR)
39         $(TAR) c -C ../../../ . \
40                 --exclude=.pc --exclude=.svn --exclude=.git \
41                 --exclude='boa-0*' --exclude='*.o' --exclude='*.so' \
42                 --exclude=dist | \
43                         tar x -C $(PKG_BUILD_DIR)/
44   endef
45 endif
46
47 define Build/Configure
48 endef
49
50 ### Templates ###
51
52 define Package/luci/libtemplate
53   SECTION:=admin
54   CATEGORY:=Administration
55   TITLE:=LuCI - Lua Configuration Interface
56   URL:=http://luci.freifunk-halle.net/
57   MAINTAINER:=Steven Barth <steven-at-midlink-dot-org>
58   SUBMENU:=LuCI Libraries
59   DEPENDS:=+luci-core
60 endef
61
62 define Package/luci/fftemplate
63   $(call Package/luci/libtemplate)
64   SUBMENU:=LuCI Freifunk Support
65   DEPENDS:=+luci-mod-freifunk
66 endef
67
68 define Package/luci/httpdtemplate
69   $(call Package/luci/libtemplate)
70   SUBMENU:=LuCIttpd
71   DEPENDS:=+luci-httpd
72 endef
73
74 define Package/luci/i18ntemplate
75   $(call Package/luci/libtemplate)
76   SUBMENU:=LuCI Translations
77   DEPENDS:=+luci-web
78 endef
79
80 define Package/luci/thtemplate
81   $(call Package/luci/libtemplate)
82   SUBMENU:=LuCI Themes
83   DEPENDS:=+luci-web
84 endef
85
86 define Package/luci/webtemplate
87   $(call Package/luci/libtemplate)
88   SUBMENU:=LuCI Components
89 endef
90
91
92 define Package/luci/install/template
93         $(CP) -a $(PKG_BUILD_DIR)/$(2)/dist/* $(1)/ -R
94         $(CP) -a $(PKG_BUILD_DIR)/$(2)/ipkg/* $(1)/CONTROL/ 2>/dev/null || true
95 endef
96
97
98
99 ### Core package ###
100
101 define Package/luci-core
102   $(call Package/luci/libtemplate)
103   DEPENDS:=+lua
104   TITLE:=LuCI core libraries
105 endef
106
107 define Package/luci-core/install
108         $(call Package/luci/install/template,$(1),libs/core)
109         $(PKG_BUILD_DIR)/build/mkversion.sh $(1)/usr/lib/lua/luci/version.lua \
110                 "OpenWrt Firmware" \
111                 "$(OPENWRTVERSION)" \
112                 "$(PKG_BRANCH)" \
113                 "$(PKG_VERSION)"
114 endef
115
116 define Package/luci-core/config
117        choice
118                prompt "Build Target"
119                default PACKAGE_luci-core_source
120
121        config PACKAGE_luci-core_compile
122                bool "Precompiled"
123
124        config PACKAGE_luci-core_stripped
125                bool "Stripped"
126
127        config PACKAGE_luci-core_source
128                bool "Full Source"
129
130        endchoice
131 endef
132
133 ifneq ($(CONFIG_PACKAGE_luci-core_compile),)
134   LUA_TARGET:=compile
135 endif
136
137 ifneq ($(CONFIG_PACKAGE_luci-core_stripped),)
138   LUA_TARGET:=strip
139 endif
140
141
142 ### Libraries ###
143 define Package/luci-cbi
144   $(call Package/luci/libtemplate)
145   DEPENDS+=+luci-web +luci-uvl +luci-uci
146   TITLE:=Configuration Binding Interface
147 endef
148
149 define Package/luci-cbi/install
150         $(call Package/luci/install/template,$(1),libs/cbi)
151 endef
152
153
154 define Package/luci-uci
155   $(call Package/luci/libtemplate)
156   DEPENDS+=+libuci-lua
157   TITLE:=High-Level UCI API
158 endef
159
160 define Package/luci-uci/install
161         $(call Package/luci/install/template,$(1),libs/uci)
162 endef
163
164
165 define Package/luci-fastindex
166   $(call Package/luci/libtemplate)
167   TITLE:=Fastindex indexing module
168 endef
169
170 define Package/luci-fastindex/install
171         $(call Package/luci/install/template,$(1),libs/fastindex)
172 endef
173
174
175 define Package/luci-http
176   $(call Package/luci/libtemplate)
177   TITLE:=HTTP Protocol implementation
178 endef
179
180 define Package/luci-http/install
181         $(call Package/luci/install/template,$(1),libs/http)
182 endef
183
184
185 define Package/luci-httpclient
186   $(call Package/luci/libtemplate)
187   TITLE:=HTTP(S) client library
188   DEPENDS+=+luci-http +luci-nixio
189 endef
190
191 define Package/luci-httpclient/install
192         $(call Package/luci/install/template,$(1),libs/httpclient)
193 endef
194
195
196 define Package/luci-ipkg
197   $(call Package/luci/libtemplate)
198   TITLE:=LuCI IPKG/OPKG call abstraction library
199 endef
200
201 define Package/luci-ipkg/install
202         $(call Package/luci/install/template,$(1),libs/ipkg)
203 endef
204
205
206 define Package/luci-json
207   $(call Package/luci/libtemplate)
208   TITLE:=LuCI JSON Library
209 endef
210
211 define Package/luci-json/install
212         $(call Package/luci/install/template,$(1),libs/json)
213 endef
214
215
216
217 NIXIO_TLS:=axtls
218
219 define Package/luci-nixio
220   $(call Package/luci/libtemplate)
221   TITLE:=NIXIO Socket Library
222   DEPENDS:=
223 endef
224
225 define Package/luci-nixio/install
226         $(call Package/luci/install/template,$(1),libs/nixio)
227 endef
228
229 define Package/luci-nixio/config
230         choice
231                 prompt "TLS Provider"
232                 default PACKAGE_luci-nixio_axtls
233
234                 config PACKAGE_luci-nixio_axtls
235                         bool "Builtin (axTLS)"
236                         select PACKAGE_dropbear
237                         select PACKAGE_dropbearconvert
238
239                 config PACKAGE_luci-nixio_openssl
240                         bool "OpenSSL"
241                         select PACKAGE_libopenssl
242         endchoice
243 endef
244
245 ifneq ($(CONFIG_PACKAGE_luci-nixio_openssl),)
246   NIXIO_TLS:=openssl
247 endif
248
249
250 define Package/luci-sys
251   $(call Package/luci/libtemplate)
252   TITLE:=LuCI Linux/POSIX system library
253 endef
254
255 define Package/luci-sys/install
256         $(call Package/luci/install/template,$(1),libs/sys)
257 endef
258
259
260 define Package/luci-web
261   $(call Package/luci/libtemplate)
262   DEPENDS+=+luci-http +luci-sys +luci-uci +luci-sgi-cgi
263   TITLE:=MVC Webframework
264   $(call Config,luci.main.lang,string,en,Default Language)
265 endef
266
267 define Package/luci-web/conffiles
268 /etc/config/luci
269 endef
270
271 define Package/luci-web/install
272         $(call Package/luci/install/template,$(1),libs/web)
273 endef
274
275
276 define Package/luci-uvl
277   $(call Package/luci/libtemplate)
278   DEPENDS+=+luci-sys +luci-uci +luci-core
279   TITLE:=UVL - UCI Validation Layer
280 endef
281
282 define Package/luci-uvl/install
283         $(call Package/luci/install/template,$(1),libs/uvl)
284 endef
285
286
287
288 ### HTTPD ###
289
290 define Package/luci-httpd
291   $(call Package/luci/httpdtemplate)
292   DEPENDS:=+luci-http +libuci
293   TITLE:=Server Core
294 endef
295
296 define Package/luci-httpd/install
297         $(call Package/luci/install/template,$(1),libs/lucittpd)
298 endef
299
300
301
302 ### Community Packages ###
303
304 define Package/luci-freifunk-community
305   $(call Package/luci/fftemplate)
306   DEPENDS+= \
307    +luci-sgi-cgi +luci-app-splash \
308    +luci-app-ffwizard-leipzig \
309    +luci-i18n-german \
310    +PACKAGE_luci-freifunk-community:olsrd-luci +PACKAGE_luci-freifunk-community:olsrd-luci-mod-dyn-gw-plain \
311    +PACKAGE_luci-freifunk-community:olsrd-luci-mod-txtinfo +PACKAGE_luci-freifunk-community:olsrd-luci-mod-nameservice \
312    +PACKAGE_luci-freifunk-community:olsrd-luci-mod-watchdog +PACKAGE_luci-freifunk-community:kmod-tun \
313    +PACKAGE_luci-freifunk-community:ip +luci-app-olsr
314   TITLE:=Freifunk Community Meta-Package
315 endef
316
317 define Package/luci-freifunk-community/install
318         $(call Package/luci/install/template,$(1),applications/freifunk-community)
319 endef
320
321 ### Modules ###
322
323 define Package/luci-admin-core
324   $(call Package/luci/webtemplate)
325   DEPENDS+=+luci-web +luci-cbi +luci-theme-openwrt +luci-i18n-english
326   TITLE:=Web UI Core Module
327 endef
328
329 define Package/luci-admin-core/conffiles
330 /etc/config/luci_hosts
331 /etc/config/luci_ethers
332 endef
333
334 define Package/luci-admin-core/install
335         $(call Package/luci/install/template,$(1),modules/admin-core)
336         touch $(1)/etc/init.d/luci_fixtime || true
337 endef
338
339
340 define Package/luci-admin-mini
341   $(call Package/luci/webtemplate)
342   DEPENDS+=+luci-admin-core
343   TITLE:=LuCI Essentials - stripped down and user-friendly
344 endef
345
346 define Package/luci-admin-mini/install
347         $(call Package/luci/install/template,$(1),modules/admin-mini)
348 endef
349
350
351 define Package/luci-admin-full
352   $(call Package/luci/webtemplate)
353   DEPENDS+=+luci-admin-core +luci-ipkg
354   TITLE:=LuCI Administration - full-featured for full control
355 endef
356
357 define Package/luci-admin-full/install
358         $(call Package/luci/install/template,$(1),modules/admin-full)
359 endef
360
361
362 define Package/luci-admin-rpc
363   $(call Package/luci/webtemplate)
364   DEPENDS+=+luci-json
365   TITLE:=LuCI RPC - JSON-RPC API
366 endef
367
368 define Package/luci-admin-rpc/install
369         $(call Package/luci/install/template,$(1),modules/rpc)
370 endef
371
372
373 define Package/luci-mod-freifunk
374   $(call Package/luci/fftemplate)
375   DEPENDS:=+luci-admin-full +luci-json
376   TITLE:=LuCI Freifunk module
377 endef
378
379 define Package/luci-mod-freifunk/conffiles
380 /etc/config/freifunk
381 endef
382
383 define Package/luci-mod-freifunk/install
384         $(call Package/luci/install/template,$(1),modules/freifunk)
385 endef
386
387
388
389 ### Applications ###
390
391 define Package/luci-app-ffwizard-leipzig
392   $(call Package/luci/fftemplate)
393   TITLE:=Freifunk Leipzig configuration wizard
394 endef
395
396 define Package/luci-app-ffwizard-leipzig/install
397         $(call Package/luci/install/template,$(1),applications/luci-ffwizard-leipzig)
398 endef
399
400
401 define Package/luci-app-siitwizard
402   $(call Package/luci/fftemplate)
403   TITLE:=SIIT IPv4-over-IPv6 configuration wizard
404   DEPENDS:=+luci-admin-core +PACKAGE_luci-app-siitwizard:kmod-siit
405 endef
406
407 define Package/luci-app-siitwizard/install
408         $(call Package/luci/install/template,$(1),applications/luci-siitwizard)
409 endef
410
411
412 define Package/luci-app-firewall
413   $(call Package/luci/webtemplate)
414   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-firewall:firewall
415   TITLE:=Firewall and Portforwarding application
416 endef
417
418 define Package/luci-app-firewall/install
419         $(call Package/luci/install/template,$(1),applications/luci-fw)
420 endef
421
422
423 define Package/luci-app-olsr
424   $(call Package/luci/webtemplate)
425   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-olsr:olsrd-luci +PACKAGE_luci-app-olsr:olsrd-luci-mod-txtinfo
426   TITLE:=OLSR configuration and status module
427 endef
428
429 define Package/luci-app-olsr/install
430         $(call Package/luci/install/template,$(1),applications/luci-olsr)
431 endef
432
433
434 define Package/luci-app-qos
435   $(call Package/luci/webtemplate)
436   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-qos:qos-scripts
437   TITLE:=Quality of Service configuration module
438 endef
439
440 define Package/luci-app-qos/install
441         $(call Package/luci/install/template,$(1),applications/luci-qos)
442 endef
443
444
445 define Package/luci-app-splash
446   $(call Package/luci/fftemplate)
447   DEPENDS+=+PACKAGE_luci-app-splash:luasocket
448   TITLE:=Freifunk DHCP-Splash application
449 endef
450
451 define Package/luci-app-splash/conffiles
452 /etc/config/luci_splash
453 endef
454
455 define Package/luci-app-splash/install
456         $(call Package/luci/install/template,$(1),applications/luci-splash)
457 endef
458
459
460 define Package/luci-app-statistics
461   $(call Package/luci/webtemplate)
462   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-statistics:collectd \
463    +PACKAGE_luci-app-statistics:rrdtool1 \
464    +PACKAGE_luci-app-statistics:collectd-mod-rrdtool1 \
465    +PACKAGE_luci-app-statistics:collectd-mod-wireless \
466    +PACKAGE_luci-app-statistics:collectd-mod-interface \
467    +PACKAGE_luci-app-statistics:collectd-mod-load
468   TITLE:=LuCI Statistics Application
469 endef
470
471 define Package/luci-app-statistics/conffiles
472 /etc/config/luci_statistics
473 endef
474
475 define Package/luci-app-statistics/install
476         $(call Package/luci/install/template,$(1),applications/luci-statistics)
477 endef
478
479
480 define Package/luci-app-upnp
481   $(call Package/luci/webtemplate)
482   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-upnp:miniupnpd
483   TITLE:=Universal Plug & Play configuration module
484 endef
485
486 define Package/luci-app-upnp/install
487         $(call Package/luci/install/template,$(1),applications/luci-upnp)
488 endef
489
490
491 define Package/luci-app-ntpc
492   $(call Package/luci/webtemplate)
493   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-ntpc:ntpclient
494   TITLE:=NTP time synchronisation client configuration module
495 endef
496
497 define Package/luci-app-ntpc/install
498         $(call Package/luci/install/template,$(1),applications/luci-ntpc)
499 endef
500
501
502 define Package/luci-app-ddns
503   $(call Package/luci/webtemplate)
504   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-ddns:ddns-scripts
505   TITLE:=Dynamic DNS configuration module
506 endef
507
508 define Package/luci-app-ddns/install
509         $(call Package/luci/install/template,$(1),applications/luci-ddns)
510 endef
511
512
513 define Package/luci-app-samba
514   $(call Package/luci/webtemplate)
515   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-samba:samba3
516   TITLE:=Network Shares - Samba SMB/CIFS module
517 endef
518
519 define Package/luci-app-samba/install
520         $(call Package/luci/install/template,$(1),applications/luci-samba)
521 endef
522
523
524 define Package/luci-app-uvc_streamer
525   $(call Package/luci/webtemplate)
526   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-uvc_streamer:uvc-streamer
527   TITLE:=Webcam Streaming - UVC-Streamer module
528 endef
529
530 define Package/luci-app-uvc_streamer/install
531         $(call Package/luci/install/template,$(1),applications/luci-uvc_streamer)
532 endef
533
534
535 define Package/luci-app-mmc_over_gpio
536   $(call Package/luci/webtemplate)
537   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-mmc_over_gpio:kmod-mmc-over-gpio
538   TITLE:=mmc_over_gpio
539 endef
540
541 define Package/luci-app-mmc_over_gpio/install
542         $(call Package/luci/install/template,$(1),applications/luci-mmc_over_gpio)
543 endef
544
545
546 define Package/luci-app-p910nd
547   $(call Package/luci/webtemplate)
548   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-p910nd:p910nd
549   TITLE:=p910nd - Printer server module
550 endef
551
552 define Package/luci-app-p910nd/install
553         $(call Package/luci/install/template,$(1),applications/luci-p910nd)
554 endef
555
556
557 define Package/luci-app-ushare
558   $(call Package/luci/webtemplate)
559   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-ushare:ushare
560   TITLE:=ushare - UPnP A/V & DLNA Media Server
561 endef
562
563 define Package/luci-app-ushare/install
564         $(call Package/luci/install/template,$(1),applications/luci-ushare)
565 endef
566
567 define Package/luci-app-hd_idle
568   $(call Package/luci/webtemplate)
569   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-hd_idle:hd-idle
570   TITLE:=hd-idle
571 endef
572
573 define Package/luci-app-hd_idle/install
574         $(call Package/luci/install/template,$(1),applications/luci-hd_idle)
575 endef
576
577 define Package/luci-app-tinyproxy
578   $(call Package/luci/webtemplate)
579   DEPENDS+=+luci-admin-full +PACKAGE_luci-app-tinyproxy:tinyproxy
580   TITLE:=Tinyproxy - HTTP(S)-Proxy
581 endef
582
583 define Package/luci-app-tinyproxy/install
584         $(call Package/luci/install/template,$(1),applications/luci-tinyproxy)
585 endef
586
587 define Package/luci-app-initmgr
588   $(call Package/luci/webtemplate)
589   DEPENDS+=+luci-admin-full
590   TITLE:=LuCI Initscript Management
591 endef
592
593 define Package/luci-app-initmgr/install
594         $(call Package/luci/install/template,$(1),applications/luci-initmgr)
595 endef
596
597 define Package/luci-app-livestats
598   $(call Package/luci/webtemplate)
599   DEPENDS+=+luci-admin-core +luci-admin-rpc
600   TITLE:=LuCI Realtime Statistics
601 endef
602
603 define Package/luci-app-livestats/install
604         $(call Package/luci/install/template,$(1),applications/luci-livestats)
605 endef
606
607 define Package/luci-app-asterisk
608   $(call Package/luci/webtemplate)
609   TITLE:=LuCI Support for Asterisk PBX
610   DEPENDS+=@BROKEN +luci-admin-core +PACKAGE_luci-app-asterisk:asterisk14-xip-core
611 endef
612
613 define Package/luci-app-asterisk/install
614         $(call Package/luci/install/template,$(1),applications/luci-asterisk)
615 endef
616
617 define Package/luci-app-polipo
618   $(call Package/luci/webtemplate)
619   TITLE:=LuCI Support for the Polipo Proxy
620   DEPENDS+=+luci-admin-core +PACKAGE_luci-app-polipo:polipo
621 endef
622
623 define Package/luci-app-polipo/install
624         $(call Package/luci/install/template,$(1),applications/luci-polipo)
625 endef
626
627 define Package/luci-app-openvpn
628   $(call Package/luci/webtemplate)
629   TITLE:=LuCI Support for OpenVPN
630   DEPENDS+=@BROKEN +luci-admin-core +PACKAGE_luci-app-openvpn:openvpn
631 endef
632
633 define Package/luci-app-openvpn/install
634         $(call Package/luci/install/template,$(1),applications/luci-openvpn)
635 endef
636
637
638 ### Server Gateway Interfaces ###
639
640 define Package/luci-sgi-cgi
641   $(call Package/luci/libtemplate)
642   TITLE:=SGI for CGI
643 endef
644
645 define Package/luci-sgi-cgi/install
646         $(call Package/luci/install/template,$(1),libs/sgi-cgi)
647 endef
648
649 define Package/luci-sgi-luci
650   $(call Package/luci/libtemplate)
651   DEPENDS+=+luci-httpd
652   TITLE:=SGI for LuCIttpd
653 endef
654
655 define Package/luci-sgi-luci/install
656         $(call Package/luci/install/template,$(1),libs/sgi-luci)
657 endef
658
659 define Package/luci-sgi-webuci
660   $(call Package/luci/libtemplate)
661   TITLE:=SGI for Webuci
662 endef
663
664 define Package/luci-sgi-webuci/install
665         $(call Package/luci/install/template,$(1),libs/sgi-webuci)
666 endef
667
668 ### Themes ###
669 define Package/luci-theme-base
670   $(call Package/luci/thtemplate)
671   DEPENDS:=+luci-web
672   TITLE:=Common base for all themes
673 endef
674
675 define Package/luci-theme-base/install
676         $(call Package/luci/install/template,$(1),themes/base)
677 endef
678
679 define Package/luci-theme-fledermaus
680   $(call Package/luci/fftemplate)
681   DEPENDS:=+luci-web
682   TITLE:=Fledermaus Theme
683 endef
684
685 define Package/luci-theme-fledermaus/install
686         $(call Package/luci/install/template,$(1),themes/fledermaus)
687 endef
688
689 define Package/luci-theme-freifunk
690   $(call Package/luci/fftemplate)
691   DEPENDS:=+luci-web
692   MAINTAINER:=Stefan Pirwitz <stefan-at-freifunk-bno-dot-de>
693   TITLE:=alternative Freifunk Theme
694 endef
695
696 define Package/luci-theme-freifunk/install
697         $(call Package/luci/install/template,$(1),themes/freifunk)
698 endef
699
700 define Package/luci-theme-freifunk-bno
701   $(call Package/luci/fftemplate)
702   DEPENDS:=+luci-web
703   MAINTAINER:=Stefan Pirwitz <stefan-at-freifunk-bno-dot-de>
704   TITLE:=Freifunk Berlin Nordost Theme
705 endef
706
707 define Package/luci-theme-freifunk-bno/install
708         $(call Package/luci/install/template,$(1),themes/freifunk-bno)
709 endef
710
711 define Package/luci-theme-openwrt
712   $(call Package/luci/thtemplate)
713   TITLE:=OpenWrt.org (default)
714   DEPENDS:=+luci-theme-base
715 endef
716
717 define Package/luci-theme-openwrt/install
718         $(call Package/luci/install/template,$(1),themes/openwrt.org)
719 endef
720
721 define Package/luci-theme-openwrtlight
722   $(call Package/luci/thtemplate)
723   TITLE:=OpenWrt.org - light variant without images
724   DEPENDS:=+luci-theme-base
725 endef
726
727 define Package/luci-theme-openwrtlight/install
728         $(call Package/luci/install/template,$(1),themes/openwrt-light)
729 endef
730
731
732 ### Translations ###
733 define Package/luci-i18n-german
734   $(call Package/luci/i18ntemplate)
735   TITLE:=German
736 endef
737
738 define Package/luci-i18n-german/install
739         $(call Package/luci/install/template,$(1),i18n/german)
740 endef
741
742
743 define Package/luci-i18n-english
744   $(call Package/luci/i18ntemplate)
745   TITLE:=English
746 endef
747
748 define Package/luci-i18n-english/install
749         $(call Package/luci/install/template,$(1),i18n/english)
750 endef
751
752
753 define Package/luci-i18n-french
754   $(call Package/luci/i18ntemplate)
755   TITLE:=French (by Florian Fainelli)
756 endef
757
758 define Package/luci-i18n-french/install
759         $(call Package/luci/install/template,$(1),i18n/french)
760 endef
761
762
763 define Package/luci-i18n-italian
764   $(call Package/luci/i18ntemplate)
765   TITLE:=Italian (by Matteo Croce)
766 endef
767
768 define Package/luci-i18n-italian/install
769         $(call Package/luci/install/template,$(1),i18n/italian)
770 endef
771
772
773 define Package/luci-i18n-russian
774   $(call Package/luci/i18ntemplate)
775   TITLE:=Russian (by Skryabin Dmitry)
776 endef
777
778 define Package/luci-i18n-russian/install
779         $(call Package/luci/install/template,$(1),i18n/russian)
780 endef
781
782
783 define Package/luci-i18n-portuguese_brazilian
784   $(call Package/luci/i18ntemplate)
785   TITLE:=Portuguese (Brazilian) (by Carlos Cesario)
786 endef
787
788 define Package/luci-i18n-portuguese_brazilian/install
789         $(call Package/luci/install/template,$(1),i18n/portuguese_brazilian)
790 endef
791
792
793 ### Compile ###
794 ifneq ($(CONFIG_PACKAGE_luci-core),)
795         PKG_SELECTED_MODULES+=libs/core
796 endif
797 ifneq ($(CONFIG_PACKAGE_luci-cbi),)
798         PKG_SELECTED_MODULES+=libs/cbi
799 endif
800 ifneq ($(CONFIG_PACKAGE_luci-fastindex),)
801         PKG_SELECTED_MODULES+=libs/fastindex
802 endif
803 ifneq ($(CONFIG_PACKAGE_luci-http),)
804         PKG_SELECTED_MODULES+=libs/http
805 endif
806 ifneq ($(CONFIG_PACKAGE_luci-httpclient),)
807         PKG_SELECTED_MODULES+=libs/httpclient
808 endif
809 ifneq ($(CONFIG_PACKAGE_luci-ipkg),)
810         PKG_SELECTED_MODULES+=libs/ipkg
811 endif
812 ifneq ($(CONFIG_PACKAGE_luci-json),)
813         PKG_SELECTED_MODULES+=libs/json
814 endif
815 ifneq ($(CONFIG_PACKAGE_luci-nixio),)
816         PKG_SELECTED_MODULES+=libs/nixio
817 endif
818 ifneq ($(CONFIG_PACKAGE_luci-uci),)
819         PKG_SELECTED_MODULES+=libs/uci
820 endif
821 ifneq ($(CONFIG_PACKAGE_luci-sys),)
822         PKG_SELECTED_MODULES+=libs/sys
823 endif
824 ifneq ($(CONFIG_PACKAGE_luci-web),)
825         PKG_SELECTED_MODULES+=libs/web
826 endif
827 ifneq ($(CONFIG_PACKAGE_luci-uvl),)
828         PKG_SELECTED_MODULES+=libs/uvl
829 endif
830
831 ifneq ($(CONFIG_PACKAGE_luci-httpd),)
832         PKG_SELECTED_MODULES+=libs/lucittpd
833 endif
834
835 ifneq ($(CONFIG_PACKAGE_luci-admin-core),)
836         PKG_SELECTED_MODULES+=modules/admin-core
837 endif
838 ifneq ($(CONFIG_PACKAGE_luci-admin-mini),)
839         PKG_SELECTED_MODULES+=modules/admin-mini
840 endif
841 ifneq ($(CONFIG_PACKAGE_luci-admin-full),)
842         PKG_SELECTED_MODULES+=modules/admin-full
843 endif
844 ifneq ($(CONFIG_PACKAGE_luci-admin-rpc),)
845         PKG_SELECTED_MODULES+=modules/rpc
846 endif
847 ifneq ($(CONFIG_PACKAGE_luci-mod-freifunk),)
848         PKG_SELECTED_MODULES+=modules/freifunk
849 endif
850
851 ifneq ($(CONFIG_PACKAGE_luci-freifunk-community),)
852         PKG_SELECTED_MODULES+=applications/freifunk-community
853 endif
854
855 ifneq ($(CONFIG_PACKAGE_luci-app-ffwizard-leipzig),)
856         PKG_SELECTED_MODULES+=applications/luci-ffwizard-leipzig
857 endif
858 ifneq ($(CONFIG_PACKAGE_luci-app-siitwizard),)
859         PKG_SELECTED_MODULES+=applications/luci-siitwizard
860 endif
861 ifneq ($(CONFIG_PACKAGE_luci-app-firewall),)
862         PKG_SELECTED_MODULES+=applications/luci-fw
863 endif
864 ifneq ($(CONFIG_PACKAGE_luci-app-olsr),)
865         PKG_SELECTED_MODULES+=applications/luci-olsr
866 endif
867 ifneq ($(CONFIG_PACKAGE_luci-app-qos),)
868         PKG_SELECTED_MODULES+=applications/luci-qos
869 endif
870 ifneq ($(CONFIG_PACKAGE_luci-app-splash),)
871         PKG_SELECTED_MODULES+=applications/luci-splash
872 endif
873 ifneq ($(CONFIG_PACKAGE_luci-app-statistics),)
874         PKG_SELECTED_MODULES+=applications/luci-statistics
875 endif
876 ifneq ($(CONFIG_PACKAGE_luci-app-upnp),)
877         PKG_SELECTED_MODULES+=applications/luci-upnp
878 endif
879 ifneq ($(CONFIG_PACKAGE_luci-app-ntpc),)
880         PKG_SELECTED_MODULES+=applications/luci-ntpc
881 endif
882 ifneq ($(CONFIG_PACKAGE_luci-app-ddns),)
883         PKG_SELECTED_MODULES+=applications/luci-ddns
884 endif
885 ifneq ($(CONFIG_PACKAGE_luci-app-samba),)
886         PKG_SELECTED_MODULES+=applications/luci-samba
887 endif
888 ifneq ($(CONFIG_PACKAGE_luci-app-uvc_streamer),)
889         PKG_SELECTED_MODULES+=applications/luci-uvc_streamer
890 endif
891 ifneq ($(CONFIG_PACKAGE_luci-app-mmc_over_gpio),)
892         PKG_SELECTED_MODULES+=applications/luci-mmc_over_gpio
893 endif
894 ifneq ($(CONFIG_PACKAGE_luci-app-p910nd),)
895         PKG_SELECTED_MODULES+=applications/luci-p910nd
896 endif
897 ifneq ($(CONFIG_PACKAGE_luci-app-ushare),)
898         PKG_SELECTED_MODULES+=applications/luci-ushare
899 endif
900 ifneq ($(CONFIG_PACKAGE_luci-app-hd_idle),)
901        PKG_SELECTED_MODULES+=applications/luci-hd_idle
902 endif
903 ifneq ($(CONFIG_PACKAGE_luci-app-tinyproxy),)
904        PKG_SELECTED_MODULES+=applications/luci-tinyproxy
905 endif
906 ifneq ($(CONFIG_PACKAGE_luci-app-initmgr),)
907        PKG_SELECTED_MODULES+=applications/luci-initmgr
908 endif
909 ifneq ($(CONFIG_PACKAGE_luci-app-livestats),)
910        PKG_SELECTED_MODULES+=applications/luci-livestats
911 endif
912 ifneq ($(CONFIG_PACKAGE_luci-app-asterisk),)
913        PKG_SELECTED_MODULES+=applications/luci-asterisk
914 endif
915 ifneq ($(CONFIG_PACKAGE_luci-app-polipo),)
916        PKG_SELECTED_MODULES+=applications/luci-polipo
917 endif
918 ifneq ($(CONFIG_PACKAGE_luci-app-openvpn),)
919        PKG_SELECTED_MODULES+=applications/luci-openvpn
920 endif
921
922
923 ifneq ($(CONFIG_PACKAGE_luci-sgi-cgi),)
924         PKG_SELECTED_MODULES+=libs/sgi-cgi
925 endif
926 ifneq ($(CONFIG_PACKAGE_luci-sgi-luci),)
927         PKG_SELECTED_MODULES+=libs/sgi-luci
928 endif
929 ifneq ($(CONFIG_PACKAGE_luci-sgi-webuci),)
930         PKG_SELECTED_MODULES+=libs/sgi-webuci
931 endif
932
933 ifneq ($(CONFIG_PACKAGE_luci-theme-base),)
934         PKG_SELECTED_MODULES+=themes/base
935 endif
936 ifneq ($(CONFIG_PACKAGE_luci-theme-fledermaus),)
937         PKG_SELECTED_MODULES+=themes/fledermaus
938 endif
939 ifneq ($(CONFIG_PACKAGE_luci-theme-freifunk-bno),)
940         PKG_SELECTED_MODULES+=themes/freifunk-bno
941 endif
942 ifneq ($(CONFIG_PACKAGE_luci-theme-freifunk),)
943         PKG_SELECTED_MODULES+=themes/freifunk
944 endif
945 ifneq ($(CONFIG_PACKAGE_luci-theme-openwrt),)
946         PKG_SELECTED_MODULES+=themes/openwrt.org
947 endif
948 ifneq ($(CONFIG_PACKAGE_luci-theme-openwrtlight),)
949         PKG_SELECTED_MODULES+=themes/openwrt-light
950 endif
951
952 ifneq ($(CONFIG_PACKAGE_luci-i18n-german),)
953         PKG_SELECTED_MODULES+=i18n/german
954 endif
955 ifneq ($(CONFIG_PACKAGE_luci-i18n-english),)
956         PKG_SELECTED_MODULES+=i18n/english
957 endif
958 ifneq ($(CONFIG_PACKAGE_luci-i18n-french),)
959         PKG_SELECTED_MODULES+=i18n/french
960 endif
961 ifneq ($(CONFIG_PACKAGE_luci-i18n-italian),)
962         PKG_SELECTED_MODULES+=i18n/italian
963 endif
964 ifneq ($(CONFIG_PACKAGE_luci-i18n-russian),)
965         PKG_SELECTED_MODULES+=i18n/russian
966 endif
967 ifneq ($(CONFIG_PACKAGE_luci-i18n-portuguese_brazilian),)
968         PKG_SELECTED_MODULES+=i18n/portuguese_brazilian
969 endif
970
971
972 MAKE_FLAGS += \
973         MODULES="$(PKG_SELECTED_MODULES)" \
974         LUA_TARGET="$(LUA_TARGET)" \
975         LUA_SHLIBS="-llua -lm -ldl -lcrypt" \
976         CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" \
977         LDFLAGS="$(TARGET_LDFLAGS) -L$(STAGING_DIR)/usr/lib" \
978         NIXIO_TLS="$(NIXIO_TLS)" OS="Linux"
979
980
981 $(eval $(call BuildPackage,luci-core))
982 $(eval $(call BuildPackage,luci-cbi))
983 $(eval $(call BuildPackage,luci-fastindex))
984 $(eval $(call BuildPackage,luci-http))
985 $(eval $(call BuildPackage,luci-httpclient))
986 $(eval $(call BuildPackage,luci-ipkg))
987 $(eval $(call BuildPackage,luci-json))
988 $(eval $(call BuildPackage,luci-nixio))
989 $(eval $(call BuildPackage,luci-uci))
990 $(eval $(call BuildPackage,luci-sys))
991 $(eval $(call BuildPackage,luci-web))
992 $(eval $(call BuildPackage,luci-uvl))
993
994 $(eval $(call BuildPackage,luci-httpd))
995
996 $(eval $(call BuildPackage,luci-admin-core))
997 $(eval $(call BuildPackage,luci-admin-mini))
998 $(eval $(call BuildPackage,luci-admin-full))
999 $(eval $(call BuildPackage,luci-admin-rpc))
1000 $(eval $(call BuildPackage,luci-mod-freifunk))
1001
1002 $(eval $(call BuildPackage,luci-freifunk-community))
1003
1004 $(eval $(call BuildPackage,luci-app-ffwizard-leipzig))
1005 $(eval $(call BuildPackage,luci-app-siitwizard))
1006 $(eval $(call BuildPackage,luci-app-firewall))
1007 $(eval $(call BuildPackage,luci-app-olsr))
1008 $(eval $(call BuildPackage,luci-app-qos))
1009 $(eval $(call BuildPackage,luci-app-splash))
1010 $(eval $(call BuildPackage,luci-app-statistics))
1011 $(eval $(call BuildPackage,luci-app-upnp))
1012 $(eval $(call BuildPackage,luci-app-ntpc))
1013 $(eval $(call BuildPackage,luci-app-ddns))
1014 $(eval $(call BuildPackage,luci-app-samba))
1015 $(eval $(call BuildPackage,luci-app-uvc_streamer))
1016 $(eval $(call BuildPackage,luci-app-mmc_over_gpio))
1017 $(eval $(call BuildPackage,luci-app-p910nd))
1018 $(eval $(call BuildPackage,luci-app-ushare))
1019 $(eval $(call BuildPackage,luci-app-hd_idle))
1020 $(eval $(call BuildPackage,luci-app-tinyproxy))
1021 $(eval $(call BuildPackage,luci-app-initmgr))
1022 $(eval $(call BuildPackage,luci-app-livestats))
1023 $(eval $(call BuildPackage,luci-app-asterisk))
1024 $(eval $(call BuildPackage,luci-app-polipo))
1025 $(eval $(call BuildPackage,luci-app-openvpn))
1026
1027 $(eval $(call BuildPackage,luci-sgi-cgi))
1028 $(eval $(call BuildPackage,luci-sgi-luci))
1029 $(eval $(call BuildPackage,luci-sgi-webuci))
1030
1031 $(eval $(call BuildPackage,luci-theme-base))
1032 $(eval $(call BuildPackage,luci-theme-fledermaus))
1033 $(eval $(call BuildPackage,luci-theme-freifunk))
1034 $(eval $(call BuildPackage,luci-theme-freifunk-bno))
1035 $(eval $(call BuildPackage,luci-theme-openwrt))
1036 $(eval $(call BuildPackage,luci-theme-openwrtlight))
1037
1038 $(eval $(call BuildPackage,luci-i18n-german))
1039 $(eval $(call BuildPackage,luci-i18n-english))
1040 $(eval $(call BuildPackage,luci-i18n-french))
1041 $(eval $(call BuildPackage,luci-i18n-italian))
1042 $(eval $(call BuildPackage,luci-i18n-russian))
1043 $(eval $(call BuildPackage,luci-i18n-portuguese_brazilian))