jansson: moved to github
jansson: moved to github

Signed-off-by: Steven Barth <steven@midlink.org>

git-svn-id: svn://svn.openwrt.org/openwrt/packages@43726 3c298f89-4303-0410-b956-a3cf2f4a3e73

file:a/admin/sudo/Makefile (deleted)
#  
# Copyright (C) 2006-2011 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=sudo  
PKG_VERSION:=1.7.10p8  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=http://www.sudo.ws/sudo/dist  
PKG_MD5SUM:=4620e31c28b387dd9582dfd42e930cfb  
 
PKG_INSTALL:=1  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/sudo  
SECTION:=admin  
CATEGORY:=Administration  
TITLE:=Delegate authority to run commands  
URL:=http://www.sudo.ws/  
endef  
 
define Package/sudo/description  
Sudo (su "do") allows a system administrator to delegate authority to  
give certain users (or groups of users) the ability to run some (or  
all) commands as root or another user while providing an audit trail of  
the commands and their arguments.  
endef  
 
define Package/sudo/conffiles  
/etc/sudoers  
endef  
 
CONFIGURE_ARGS+= \  
--without-pam \  
--disable-pam-session \  
--with-editor=/bin/vi \  
--without-lecture \  
--disable-zlib  
 
CONFIGURE_VARS+= \  
sudo_cv_uid_t_len=10 \  
sudo_cv_func_unsetenv_void=no  
 
define Package/sudo/install  
$(INSTALL_DIR) $(1)/usr/bin  
$(CP) $(PKG_INSTALL_DIR)/usr/bin/sudo $(1)/usr/bin/  
chmod 4755 $(1)/usr/bin/sudo  
$(INSTALL_DIR) $(1)/usr/sbin  
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/visudo $(1)/usr/sbin/  
$(INSTALL_DIR) $(1)/etc  
$(CP) $(PKG_INSTALL_DIR)/etc/sudoers $(1)/etc/  
chmod 0440 $(1)/etc/sudoers  
$(INSTALL_DIR) $(1)/etc/sudoers.d  
$(INSTALL_DIR) $(1)/usr/lib  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/sudo_noexec.so $(1)/usr/lib/  
$(INSTALL_DIR) $(1)/etc/init.d  
$(INSTALL_BIN) ./files/sudo.init $(1)/etc/init.d/sudo  
endef  
 
define Package/sudo/postinst  
#!/bin/sh  
 
[ -n "$$IPKG_INSTROOT" ] || {  
/etc/init.d/sudo enable  
/etc/init.d/sudo start  
}  
endef  
 
$(eval $(call BuildPackage,sudo))  
 
#!/bin/sh /etc/rc.common  
# Copyright (C) 2011 OpenWrt.org  
 
START=99  
 
start() {  
[ -d /var/lib/sudo ] || {  
mkdir -m 0755 -p /var/lib/sudo  
chmod 0700 /var/lib/sudo  
}  
}  
 
file:a/devel/perf/Makefile (deleted)
#  
# Copyright (C) 2011-2013 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
include $(INCLUDE_DIR)/kernel.mk  
 
PKG_NAME:=perf  
PKG_VERSION:=$(LINUX_VERSION)  
PKG_RELEASE:=2  
 
PKG_USE_MIPS16:=0  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/perf  
SECTION:=devel  
CATEGORY:=Development  
DEPENDS:= +libelf1 +libdw +libpthread +librt +binutils  
TITLE:=Linux performance monitoring tool  
VERSION:=$(LINUX_VERSION)-$(PKG_RELEASE)  
URL:=http://www.kernel.org  
endef  
 
define Package/perf/description  
perf is the Linux performance monitoring tool  
endef  
 
# Perf's makefile and headers are not relocatable and must be built from the  
# Linux sources directory  
define Build/Prepare  
$(RM) -r $(PKG_BUILD_DIR)  
ln -s $(LINUX_DIR)/tools/perf $(PKG_BUILD_DIR)  
endef  
 
# MAKE_FLAGS should be passed again upon cleaning because Perf's makefile  
# always performs checks before processing any rule  
define Build/Clean  
-$(MAKE) -C $(PKG_BUILD_DIR) \  
NO_DWARF=1 \  
$(MAKE_FLAGS) \  
clean  
endef  
 
MAKE_FLAGS = \  
ARCH="$(LINUX_KARCH)" \  
NO_LIBPERL=1 \  
NO_LIBPYTHON=1 \  
NO_NEWT=1 \  
CROSS_COMPILE="$(TARGET_CROSS)" \  
CC="$(TARGET_CC)" \  
LD="$(TARGET_CROSS)ld" \  
CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \  
LDFLAGS="$(TARGET_LDFLAGS)" \  
V=1 \  
prefix=/usr  
 
define Package/perf/install  
$(INSTALL_DIR) $(1)/usr/bin  
$(INSTALL_BIN) $(LINUX_DIR)/tools/perf/perf $(1)/usr/bin/  
endef  
 
$(eval $(call BuildPackage,perf))  
 
#  
# Copyright (C) 2011 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=python-imaging-library  
PKG_VERSION:=1.1.7  
PKG_RELEASE:=2  
 
PKG_SOURCE:=Imaging-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=http://effbot.org/downloads  
PKG_MD5SUM:=fc14a54e1ce02a0225be8854bfba478e  
 
PKG_BUILD_DIR:=$(BUILD_DIR)/Imaging-$(PKG_VERSION)  
PKG_BUILD_DEPENDS:=python  
 
include $(INCLUDE_DIR)/package.mk  
$(call include_mk, python-package.mk)  
 
define Package/python-imaging-library  
SECTION:=language-python  
CATEGORY:=Languages  
SUBMENU:=Python  
TITLE:=Python Imaging Library (PIL)  
URL:=http://www.pythonware.com/products/pil/  
DEPENDS:=+python +libfreetype +libjpeg +zlib  
endef  
 
define Package/python-imaging-library/description  
The Python Imaging Library adds image processing capabilities to your  
Python interpreter.  
.  
This library provides extensive file format support, an efficient  
internal representation, and fairly powerful image processing  
capabilities.  
.  
The core image library is designed for fast access to data stored in a  
few basic pixel formats. It should provide a solid foundation for a  
general image processing tool.  
endef  
 
define Build/Compile  
$(call Build/Compile/PyMod,., \  
install --prefix="/usr" --root="$(PKG_INSTALL_DIR)", \  
)  
endef  
 
define Package/python-imaging-library/install  
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)  
$(CP) \  
$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \  
$(1)$(PYTHON_PKG_DIR)/  
endef  
 
$(eval $(call BuildPackage,python-imaging-library))  
 
--- a/setup.py 2011-11-15 01:06:00.000000000 +0100  
+++ b/setup.py 2011-11-15 01:07:32.000000000 +0100  
@@ -147,7 +147,6 @@  
add_directory(library_dirs, "/opt/local/lib")  
add_directory(include_dirs, "/opt/local/include")  
 
- add_directory(library_dirs, "/usr/local/lib")  
# FIXME: check /opt/stuff directories here?  
 
prefix = sysconfig.get_config_var("prefix")  
@@ -199,22 +198,6 @@  
add_directory(include_dirs, include_root)  
 
#  
- # add standard directories  
-  
- # look for tcl specific subdirectory (e.g debian)  
- if _tkinter:  
- tcl_dir = "/usr/include/tcl" + TCL_VERSION  
- if os.path.isfile(os.path.join(tcl_dir, "tk.h")):  
- add_directory(include_dirs, tcl_dir)  
-  
- # standard locations  
- add_directory(library_dirs, "/usr/local/lib")  
- add_directory(include_dirs, "/usr/local/include")  
-  
- add_directory(library_dirs, "/usr/lib")  
- add_directory(include_dirs, "/usr/include")  
-  
- #  
# insert new dirs *before* default libs, to avoid conflicts  
# between Python PYD stub libs and real libraries  
 
 
#  
# Copyright (C) 2011 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=simplejson  
PKG_VERSION:=2.2.1  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=http://pypi.python.org/packages/source/s/simplejson/  
PKG_MD5SUM:=070c6467462bd63306f1756b01df6d70  
PKG_BUILD_DEPENDS:=python  
 
include $(INCLUDE_DIR)/package.mk  
$(call include_mk, python-package.mk)  
 
define Package/simplejson  
SUBMENU:=Python  
SECTION:=lang  
CATEGORY:=Languages  
TITLE:=Simple, fast, extensible JSON encoder/decoder for Python  
URL:=http://simplejson.readthedocs.org/  
DEPENDS:=+python +distribute  
endef  
 
define Package/simplejson/description  
Simple, fast, extensible JSON encoder/decoder for Python  
endef  
 
define Build/Compile  
$(call Build/Compile/PyMod,,install --prefix=/usr --root=$(PKG_INSTALL_DIR))  
endef  
 
define Package/simplejson/install  
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)  
$(CP) \  
$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \  
$(1)$(PYTHON_PKG_DIR)  
endef  
 
$(eval $(call BuildPackage,simplejson))  
 
file:a/lang/vala/Makefile (deleted)
#  
# Copyright (C) 2006-2012 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=vala  
PKG_VERSION:=0.16.0  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz  
PKG_SOURCE_URL:=@GNOME/vala/0.16/  
PKG_MD5SUM:=84b742e9cca4c90fde3026c3793c03c1  
 
PKG_BUILD_DEPENDS:=glib2/host vala/host  
HOST_BUILD_DEPENDS:=glib2/host  
 
include $(INCLUDE_DIR)/host-build.mk  
include $(INCLUDE_DIR)/package.mk  
include $(INCLUDE_DIR)/nls.mk  
 
TARGET_LDFLAGS+=\  
-Wl,-rpath-link=$(STAGING_DIR)/usr/lib  
 
define Package/vala  
SECTION:=lang  
CATEGORY:=Languages  
TITLE:=C-sharp like language for the GObject system  
URL:=http://live.gnome.org/Vala  
endef  
 
define Package/vala/description  
Vala is a C-sharp like language for the GObject system. This package contains  
the Vala-to-C compiler.  
endef  
 
define Build/Compile  
$(MAKE) -C $(PKG_BUILD_DIR) \  
DESTDIR="$(PKG_INSTALL_DIR)" \  
all install  
endef  
 
define Build/InstallDev  
$(INSTALL_DIR) \  
$(1)/usr/share/vala-0.16/vapi \  
$(1)/usr/lib \  
$(1)/usr/share/pkgconfig \  
$(1)/usr/bin  
 
$(INSTALL_DATA) \  
$(PKG_INSTALL_DIR)/usr/share/vala-0.16/vapi/* \  
$(1)/usr/share/vala-0.16/vapi  
 
$(INSTALL_DATA) \  
$(PKG_INSTALL_DIR)/usr/lib/libvala-0.16.{so*,la} \  
$(1)/usr/lib  
 
$(INSTALL_BIN) \  
$(PKG_INSTALL_DIR)/usr/bin/{vala,vala-0.16,valac,valac-0.16,vapicheck,vapicheck-0.16,vapigen,vapigen-0.16,vala-gen-introspect,vala-gen-introspect-0.16} \  
$(1)/usr/bin  
 
$(INSTALL_DATA) \  
$(PKG_INSTALL_DIR)/usr/share/pkgconfig/*.pc \  
$(1)/usr/share/pkgconfig  
endef  
 
$(eval $(call HostBuild))  
$(eval $(call BuildPackage,vala))  
 
file:a/libs/jansson/Makefile (deleted)
#  
# Copyright (C) 2011-2012 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=jansson  
PKG_VERSION:=2.2.1  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=http://www.digip.org/jansson/releases/  
PKG_MD5SUM:=ebf4ebc7af47de27f7b9d79ad5853176  
 
PKG_INSTALL:=1  
PKG_BUILD_PARALLEL:=1  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/jansson  
SECTION:=libs  
CATEGORY:=Libraries  
TITLE:=JSON library  
endef  
 
TARGET_CFLAGS += $(FPIC)  
 
define Build/InstallDev  
$(INSTALL_DIR) $(1)/usr/{lib,include}  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libjansson* $(1)/usr/lib  
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/  
endef  
 
define Package/jansson/install  
$(INSTALL_DIR) $(1)/usr/lib  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libjansson*so* $(1)/usr/lib/  
endef  
 
$(eval $(call BuildPackage,jansson))  
 
This patch adds a function which can be used to update  
json key values on all levels, not just one, automagically  
adding new keys to objects which do not exist in old object.  
 
Signed-off-by: Roman Yeryomin <roman@advem.lv>  
 
--- a/src/value.c 2011-04-21 13:15:58.000000000 +0300  
+++ b/src/value.c 2011-07-01 00:23:05.105103308 +0300  
@@ -215,6 +215,41 @@  
return 0;  
}  
 
+int json_object_deep_update(json_t *object, json_t *other)  
+{  
+ void *iter;  
+  
+ if(!json_is_object(object) || !json_is_object(other))  
+ return -1;  
+  
+ iter = json_object_iter(other);  
+ while(iter) {  
+ const char *key;  
+ json_t *value;  
+  
+ key = json_object_iter_key(iter);  
+ value = json_object_iter_value(iter);  
+  
+ if (!json_is_object(value)) {  
+ if ( json_object_set_nocheck( object, key, value ) )  
+ return -1;  
+ } else {  
+ json_t *subobj = json_object_get(object, key);  
+ if (!subobj) {  
+ json_object_set_nocheck( object, key, value );  
+ iter = json_object_iter_next(other, iter);  
+ continue;  
+ }  
+ if (json_object_deep_update( subobj, value ) == -1)  
+ return -1;  
+ }  
+  
+ iter = json_object_iter_next(other, iter);  
+ }  
+  
+ return 0;  
+}  
+  
void *json_object_iter(json_t *json)  
{  
json_object_t *object;  
 
--- a/src/jansson.h  
+++ b/src/jansson.h  
@@ -126,6 +126,7 @@ int json_object_set_new_nocheck(json_t *  
int json_object_del(json_t *object, const char *key);  
int json_object_clear(json_t *object);  
int json_object_update(json_t *object, json_t *other);  
+int json_object_deep_update(json_t *object, json_t *other);  
void *json_object_iter(json_t *object);  
void *json_object_iter_at(json_t *object, const char *key);  
void *json_object_iter_next(json_t *object, void *iter);  
 
#  
# Copyright (C) 2007-2013 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=libtorrent  
PKG_VERSION:=0.13.3-git  
PKG_RELEASE=$(PKG_SOURCE_VERSION)-1  
 
PKG_SOURCE_PROTO:=git  
PKG_SOURCE_URL:=https://github.com/rakshasa/libtorrent.git  
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)  
PKG_SOURCE_VERSION:=680576e23e7d5f642ee51486fdf301ac0195e188  
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz  
 
PKG_FIXUP:=autoreconf  
PKG_BUILD_PARALLEL:=1  
PKG_INSTALL:=1  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/libtorrent  
SECTION:=libs  
CATEGORY:=Libraries  
TITLE:=Rakshasa's BitTorrent library  
URL:=http://libtorrent.rakshasa.no/  
DEPENDS:=+libopenssl +libsigcxx  
endef  
 
define Package/libtorrent/description  
LibTorrent is a BitTorrent library written in C++ for *nix, with a focus on  
high performance and good code. The library differentiates itself from other  
implementations by transfering directly from file pages to the network stack.  
On high-bandwidth connections it is able to seed at 3 times the speed of the  
official client.  
endef  
 
TARGET_LDFLAGS += $(LIBGCC_S)  
 
CONFIGURE_ARGS+= \  
--enable-shared \  
--enable-static \  
--enable-aligned \  
--disable-debug \  
--enable-openssl \  
--disable-instrumentation  
 
define Build/Configure  
( cd $(PKG_BUILD_DIR); ./autogen.sh );  
$(call Build/Configure/Default)  
endef  
 
define Build/InstallDev  
$(INSTALL_DIR) $(1)/usr/include  
$(CP) $(PKG_INSTALL_DIR)/usr/include/torrent $(1)/usr/include/  
$(INSTALL_DIR) $(1)/usr/lib  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.{a,so*} $(1)/usr/lib/  
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libtorrent.pc $(1)/usr/lib/pkgconfig/  
endef  
 
define Package/libtorrent/install  
$(INSTALL_DIR) $(1)/usr/lib  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtorrent.so.* $(1)/usr/lib/  
endef  
 
$(eval $(call BuildPackage,libtorrent))  
 
--- a/configure.ac  
+++ b/configure.ac  
@@ -19,7 +19,6 @@ AC_SUBST(LIBTORRENT_INTERFACE_VERSION_NO  
 
AM_INIT_AUTOMAKE  
AC_CONFIG_HEADERS(config.h)  
-AM_PATH_CPPUNIT(1.9.6)  
 
AC_PROG_CXX  
 
--- a/scripts/checks.m4  
+++ b/scripts/checks.m4  
@@ -96,7 +96,7 @@ AC_DEFUN([TORRENT_CHECK_KQUEUE], [  
AC_DEFUN([TORRENT_CHECK_KQUEUE_SOCKET_ONLY], [  
AC_MSG_CHECKING(whether kqueue supports pipes and ptys)  
 
- AC_RUN_IFELSE([AC_LANG_SOURCE([  
+ AC_LINK_IFELSE([AC_LANG_SOURCE([  
#include <fcntl.h>  
#include <stdlib.h>  
#include <unistd.h>  
--- a/scripts/common.m4  
+++ b/scripts/common.m4  
@@ -223,7 +223,7 @@ dnl Need to fix this so that it uses t  
AC_DEFUN([TORRENT_CHECK_EXECINFO], [  
AC_MSG_CHECKING(for execinfo.h)  
 
- AC_RUN_IFELSE([AC_LANG_SOURCE([  
+ AC_LINK_IFELSE([AC_LANG_SOURCE([  
#include <execinfo.h>  
int main() { backtrace((void**)0, 0); backtrace_symbols((char**)0, 0); return 0;}  
])],  
@@ -238,7 +238,7 @@ AC_DEFUN([TORRENT_CHECK_EXECINFO], [  
AC_DEFUN([TORRENT_CHECK_ALIGNED], [  
AC_MSG_CHECKING(the byte alignment)  
 
- AC_RUN_IFELSE([AC_LANG_SOURCE([  
+ AC_LINK_IFELSE([AC_LANG_SOURCE([  
#include <inttypes.h>  
int main() {  
char buf@<:@8@:>@ = { 0, 0, 0, 0, 1, 0, 0, 0 };  
 
--- a/src/net/socket_datagram.cc  
+++ b/src/net/socket_datagram.cc  
@@ -73,6 +73,23 @@ SocketDatagram::write_datagram(const voi  
int r;  
 
if (sa != NULL) {  
+#ifdef RAK_USE_INET6  
+ if (m_ipv6_socket && sa->family() == rak::socket_address::pf_inet) {  
+ uint32_t addr32[4];  
+ sockaddr_in6 mapped_addr;  
+ memset(&mapped_addr, 0, sizeof(mapped_addr));  
+ mapped_addr.sin6_family = AF_INET6;  
+ addr32[0] = 0;  
+ addr32[1] = 0;  
+ addr32[2] = htonl(0xffff);  
+ addr32[3] = sa->sa_inet()->address_n();  
+ memcpy(mapped_addr.sin6_addr.s6_addr, addr32, sizeof(uint32_t) * 4);  
+ mapped_addr.sin6_port = sa->sa_inet()->port_n();  
+ r = ::sendto(m_fileDesc, buffer, length, 0, (sockaddr*)&mapped_addr, sizeof(mapped_addr));  
+ } else if (m_ipv6_socket && sa->family() == rak::socket_address::pf_inet6) {  
+ r = ::sendto(m_fileDesc, buffer, length, 0, sa->sa_inet6()->c_sockaddr(), sizeof(rak::socket_address_inet6));  
+ } else  
+#endif  
r = ::sendto(m_fileDesc, buffer, length, 0, sa->sa_inet()->c_sockaddr(), sizeof(rak::socket_address_inet));  
} else {  
r = ::send(m_fileDesc, buffer, length, 0);  
 
diff -Nur uClibc++-0.2.4.orig/Makefile uClibc++-0.2.4/Makefile  
--- uClibc++-0.2.4.orig/Makefile 2012-05-25 23:15:31.000000000 +0200  
+++ uClibc++-0.2.4/Makefile 2013-03-11 11:50:03.000000000 +0100  
@@ -1,4 +1,3 @@  
-MAKE = make  
SUBDIRS = bin include src  
 
# User defines:  
 
# CoovaChilli avanced configuration  
 
menu "Configuration"  
depends on PACKAGE_coova-chilli  
 
config COOVACHILLI_REDIR  
bool "Enable support for redir server. Required for uamregex"  
default n  
 
config COOVACHILLI_MINIPORTAL  
bool "Enable support Coova miniportal"  
default n  
 
config COOVACHILLI_USERAGENT  
bool "Enable recording user-agent"  
default n  
 
config COOVACHILLI_DNSLOG  
bool "Enable support to log DNS name queries"  
default n  
 
config COOVACHILLI_UAMDOMAINFILE  
bool "Enable loading of mass uamdomains from file"  
default n  
 
config COOVACHILLI_LARGELIMITS  
bool "Enable larger limits for use with non-embedded systems"  
default n  
 
choice  
prompt "SSL library"  
default COOVACHILLI_NOSSL  
 
config COOVACHILLI_NOSSL  
bool "No SSL support"  
 
config COOVACHILLI_MATRIXSSL  
bool "MatrixSSL"  
 
config COOVACHILLI_CYASSL  
bool "CyaSSL"  
 
config COOVACHILLI_OPENSSL  
bool "OpenSSL"  
 
endchoice  
 
endmenu  
 
#  
# Copyright (C) 2007-2014 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=coova-chilli  
PKG_VERSION:=1.3.0  
PKG_RELEASE:=5  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=http://ap.coova.org/chilli  
PKG_MD5SUM:=dc0037e3cdebcb60508081b4e42e984a  
 
PKG_INSTALL:=1  
 
PKG_CONFIG_DEPENDS := \  
COOVACHILLI_MINIPORTAL \  
COOVACHILLI_REDIR \  
COOVACHILLI_USERAGENT \  
COOVACHILLI_DNSLOG \  
COOVACHILLI_UAMDOMAINFILE \  
COOVACHILLI_LARGELIMITS \  
COOVACHILLI_NOSSL \  
COOVACHILLI_MATRIXSSL \  
COOVACHILLI_CYASSL \  
COOVACHILLI_OPENSSL  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/coova-chilli  
SUBMENU:=Captive Portals  
SECTION:=net  
CATEGORY:=Network  
DEPENDS:=+kmod-tun +librt +COOVACHILLI_MATRIXSSL:libmatrixssl +COOVACHILLI_CYASSL:libcyassl +COOVACHILLI_OPENSSL:libopenssl  
TITLE:=Wireless LAN HotSpot controller (Coova Chilli Version)  
URL:=http://www.coova.org/CoovaChilli  
MAINTAINER:=Imre Kaloz <kaloz@openwrt.org>  
MENU:=1  
endef  
 
define Package/coova-chilli/description  
CoovaChilli is an open source access controller for wireless LAN  
access points and is based on ChilliSpot. It is used for authenticating  
users of a wireless (or wired) LAN. It supports web based login (UAM)  
which is today's standard for public HotSpots and it supports Wireless  
Protected Access (WPA) which is the standard of the future.  
Authentication, authorization and accounting (AAA) is handled by your  
favorite radius server.  
endef  
 
define Package/coova-chilli/config  
source "$(SOURCE)/Config.in"  
endef  
 
define Build/Configure  
$(call Build/Configure/Default, \  
$(if $(CONFIG_COOVACHILLI_REDIR),--enable,--disable)-chilliredir \  
$(if $(CONFIG_COOVACHILLI_DNSLOG),--enable,--disable)-dnslog \  
$(if $(CONFIG_COOVACHILLI_MINIPORTAL),--enable,--disable)-miniportal \  
$(if $(CONFIG_COOVACHILLI_USERAGENT),--enable,--disable)-useragent \  
$(if $(CONFIG_COOVACHILLI_LARGELIMITS),--enable,--disable)-largelimits \  
$(if $(CONFIG_COOVACHILLI_UAMDOMAINFILE),--enable,--disable)-uamdomainfile \  
$(if $(CONFIG_COOVACHILLI_MATRIXSSL),--with,--without)-matrixssl \  
$(if $(CONFIG_COOVACHILLI_CYASSL),--with,--without)-cyaxssl \  
$(if $(CONFIG_COOVACHILLI_OPENSSL),--with,--without)-openssl \  
)  
endef  
 
define Package/coova-chilli/conffiles  
/etc/chilli.conf  
endef  
 
define Package/coova-chilli/install  
$(INSTALL_DIR) $(1)/etc  
$(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/chilli.conf $(1)/etc/  
$(INSTALL_DIR) $(1)/etc/chilli  
$(CP) $(PKG_INSTALL_DIR)/etc/chilli/* $(1)/etc/chilli/  
$(INSTALL_DIR) $(1)/etc/hotplug.d/iface  
$(INSTALL_DATA) ./files/chilli.hotplug $(1)/etc/hotplug.d/iface/30-chilli  
$(INSTALL_DIR) $(1)/usr/sbin  
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/chilli* $(1)/usr/sbin/  
$(INSTALL_DIR) $(1)/usr/lib/  
$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*.so.* $(1)/usr/lib/  
endef  
 
$(eval $(call BuildPackage,coova-chilli))  
 
#!/bin/sh  
 
[ "$ACTION" == "ifup" ] || exit 0  
 
[ "$INTERFACE" = "wan" ] && {  
/etc/init.d/chilli restart  
}  
 
--- a/src/system.h  
+++ b/src/system.h  
@@ -76,10 +76,6 @@  
#include <sys/stat.h>  
#endif  
 
-#ifdef HAVE_SYS_SYSINFO_H  
-#include <sys/sysinfo.h>  
-#endif  
-  
#ifdef HAVE_TIME_H  
#include <time.h>  
#endif  
@@ -132,6 +128,10 @@  
#include <linux/un.h>  
#endif  
 
+#ifdef HAVE_SYS_SYSINFO_H  
+#include <sys/sysinfo.h>  
+#endif  
+  
#elif defined (__FreeBSD__) || defined (__APPLE__) || defined (__OpenBSD__) || defined (__NetBSD__)  
#include <net/if.h>  
#include <net/bpf.h>  
 
# #
# Copyright (C) 2006-2009 OpenWrt.org # Copyright (C) 2006-2009 OpenWrt.org
# #
# This is free software, licensed under the GNU General Public License v2. # This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information. # See /LICENSE for more information.
# #
   
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk include $(INCLUDE_DIR)/kernel.mk
   
PKG_NAME:=madwifi PKG_NAME:=madwifi
   
PKG_REV:=3314 PKG_REV:=3314
PKG_VERSION:=r$(PKG_REV) PKG_VERSION:=r$(PKG_REV)
PKG_RELEASE:=6 PKG_RELEASE:=6
   
PKG_SOURCE_PROTO:=svn PKG_SOURCE_PROTO:=svn
PKG_SOURCE_VERSION:=$(PKG_REV) PKG_SOURCE_VERSION:=$(PKG_REV)
PKG_SOURCE_SUBDIR:=$(if $(PKG_BRANCH),$(PKG_BRANCH),madwifi-trunk)-$(PKG_VERSION) PKG_SOURCE_SUBDIR:=$(if $(PKG_BRANCH),$(PKG_BRANCH),madwifi-trunk)-$(PKG_VERSION)
PKG_SOURCE_URL:=http://madwifi-project.org/svn/madwifi/$(if $(PKG_BRANCH),branches/$(PKG_BRANCH),trunk) PKG_SOURCE_URL:=http://madwifi-project.org/svn/madwifi/$(if $(PKG_BRANCH),branches/$(PKG_BRANCH),trunk)
PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz
PKG_MIRROR_MD5SUM:=086b026d1c1561be8a949b79b0931404 PKG_MIRROR_MD5SUM:=086b026d1c1561be8a949b79b0931404
   
PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(if $(PKG_BRANCH),$(PKG_BRANCH),madwifi-trunk)-$(PKG_VERSION) PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(if $(PKG_BRANCH),$(PKG_BRANCH),madwifi-trunk)-$(PKG_VERSION)
   
HAL_VERSION:=20090508 HAL_VERSION:=20090508
HAL_FILE:=ath_hal-$(HAL_VERSION).tgz HAL_FILE:=ath_hal-$(HAL_VERSION).tgz
HAL_MD5SUM:=4ab7ae8bdb96c0be388c98bf8f92d5ca HAL_MD5SUM:=4ab7ae8bdb96c0be388c98bf8f92d5ca
   
PKG_BUILD_DEPENDS:=wprobe PKG_BUILD_DEPENDS:=wprobe
   
include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/package.mk
   
ifdef CONFIG_MADWIFI_COMPRESSION ifdef CONFIG_MADWIFI_COMPRESSION
COMPRESSION:=1 COMPRESSION:=1
else else
COMPRESSION:=0 COMPRESSION:=0
endif endif
   
define Download/hal define Download/hal
FILE:=$(HAL_FILE) FILE:=$(HAL_FILE)
URL:=http://mirror2.openwrt.org/sources URL:=http://mirror2.openwrt.org/sources
MD5SUM:=$(HAL_MD5SUM) MD5SUM:=$(HAL_MD5SUM)
endef endef
$(eval $(call Download,hal)) $(eval $(call Download,hal))
   
   
ifneq ($(CONFIG_TARGET_atheros),) ifneq ($(CONFIG_TARGET_atheros),)
BUS:=AHB BUS:=AHB
else else
ifneq ($(CONFIG_PCI_SUPPORT),) ifneq ($(CONFIG_PCI_SUPPORT),)
BUS:=PCI BUS:=PCI
endif endif
endif endif
   
ifneq ($(CONFIG_CPU_MIPS32_R2),) ifneq ($(CONFIG_CPU_MIPS32_R2),)
ifeq ($(ARCH),mips) ifeq ($(ARCH),mips)
HAL_TARGET:=mips32r2-be-elf HAL_TARGET:=mips32r2-be-elf
endif endif
ifeq ($(ARCH),mipsel) ifeq ($(ARCH),mipsel)
HAL_TARGET:=mips32r2-le-elf HAL_TARGET:=mips32r2-le-elf
endif endif
else else
ifeq ($(ARCH),mips) ifeq ($(ARCH),mips)
HAL_TARGET:=mips32-be-elf HAL_TARGET:=mips32-be-elf
endif endif
ifeq ($(ARCH),mipsel) ifeq ($(ARCH),mipsel)
HAL_TARGET:=mips32-le-elf HAL_TARGET:=mips32-le-elf
endif endif
endif endif
ifeq ($(ARCH),i386) ifeq ($(ARCH),i386)
HAL_TARGET:=i386-elf HAL_TARGET:=i386-elf
endif endif
ifeq ($(ARCH),i686) ifeq ($(ARCH),i686)
HAL_TARGET:=i386-elf HAL_TARGET:=i386-elf
endif endif
ifeq ($(ARCH),armeb) ifeq ($(ARCH),armeb)
HAL_TARGET:=xscale-be-elfgnueabi HAL_TARGET:=xscale-be-elfgnueabi
endif endif
ifeq ($(ARCH),arm) ifeq ($(ARCH),arm)
HAL_TARGET:=xscale-le-elfgnueabi HAL_TARGET:=xscale-le-elfgnueabi
ifeq ($(BOARD),cns21xx) ifeq ($(BOARD),cns21xx)
HAL_TARGET:=armv4-le-elfgnueabi HAL_TARGET:=armv4-le-elfgnueabi
endif endif
ifeq ($(BOARD),cns3xxx) ifeq ($(BOARD),cns3xxx)
HAL_TARGET:=arm11-le-elfgnueabi HAL_TARGET:=arm11-le-elfgnueabi
endif endif
ifeq ($(BOARD),gemini) ifeq ($(BOARD),gemini)
HAL_TARGET:=armv4-le-elfgnueabi HAL_TARGET:=armv4-le-elfgnueabi
endif endif
endif endif
ifeq ($(ARCH),powerpc) ifeq ($(ARCH),powerpc)
HAL_TARGET:=powerpc-be-elf HAL_TARGET:=powerpc-be-elf
endif endif
ifneq ($(CONFIG_TARGET_atheros),) ifneq ($(CONFIG_TARGET_atheros),)
HAL_TARGET:=wisoc HAL_TARGET:=wisoc
endif endif
   
ifdef CONFIG_MADWIFI_RCA_MINSTREL ifdef CONFIG_MADWIFI_RCA_MINSTREL
RATE_CONTROL:=minstrel RATE_CONTROL:=minstrel
endif endif
   
ifdef CONFIG_MADWIFI_RCA_ONOE ifdef CONFIG_MADWIFI_RCA_ONOE
RATE_CONTROL:=onoe RATE_CONTROL:=onoe
endif endif
   
ifdef CONFIG_MADWIFI_RCA_AMRR ifdef CONFIG_MADWIFI_RCA_AMRR
RATE_CONTROL:=amrr RATE_CONTROL:=amrr
endif endif
   
ifdef CONFIG_MADWIFI_RCA_SAMPLERATE ifdef CONFIG_MADWIFI_RCA_SAMPLERATE
RATE_CONTROL:=sample RATE_CONTROL:=sample
endif endif
   
ifneq ($(CONFIG_MADWIFI_SINGLE_MODULE),) ifneq ($(CONFIG_MADWIFI_SINGLE_MODULE),)
MADWIFI_FILES:= $(PKG_BUILD_DIR)/ath_hal/ath_hal.ko MADWIFI_FILES:= $(PKG_BUILD_DIR)/ath_hal/ath_hal.ko
else else
MADWIFI_FILES:= \ MADWIFI_FILES:= \
$(PKG_BUILD_DIR)/net80211/wlan.ko \ $(PKG_BUILD_DIR)/net80211/wlan.ko \
$(PKG_BUILD_DIR)/net80211/wlan_scan_ap.ko \ $(PKG_BUILD_DIR)/net80211/wlan_scan_ap.ko \
$(PKG_BUILD_DIR)/net80211/wlan_scan_sta.ko \ $(PKG_BUILD_DIR)/net80211/wlan_scan_sta.ko \
$(PKG_BUILD_DIR)/ath_hal/ath_hal.ko \ $(PKG_BUILD_DIR)/ath_hal/ath_hal.ko \
$(PKG_BUILD_DIR)/ath_rate/$(RATE_CONTROL)/ath_rate_$(RATE_CONTROL).ko \ $(PKG_BUILD_DIR)/ath_rate/$(RATE_CONTROL)/ath_rate_$(RATE_CONTROL).ko \
$(PKG_BUILD_DIR)/net80211/wlan_acl.ko \ $(PKG_BUILD_DIR)/net80211/wlan_acl.ko \
$(PKG_BUILD_DIR)/net80211/wlan_ccmp.ko \ $(PKG_BUILD_DIR)/net80211/wlan_ccmp.ko \
$(PKG_BUILD_DIR)/net80211/wlan_tkip.ko \ $(PKG_BUILD_DIR)/net80211/wlan_tkip.ko \
$(PKG_BUILD_DIR)/net80211/wlan_wep.ko \ $(PKG_BUILD_DIR)/net80211/wlan_wep.ko \
$(PKG_BUILD_DIR)/net80211/wlan_xauth.ko $(PKG_BUILD_DIR)/net80211/wlan_xauth.ko
endif endif
   
ifneq ($(CONFIG_MADWIFI_SINGLE_MODULE),) ifneq ($(CONFIG_MADWIFI_SINGLE_MODULE),)
MADWIFI_AUTOLOAD:= ath_hal MADWIFI_AUTOLOAD:= ath_hal
else else
MADWIFI_AUTOLOAD:= \ MADWIFI_AUTOLOAD:= \
wlan \ wlan \
wlan_scan_ap \ wlan_scan_ap \
wlan_scan_sta \ wlan_scan_sta \
ath_hal \ ath_hal \
ath_rate_$(RATE_CONTROL) \ ath_rate_$(RATE_CONTROL) \
wlan_acl \ wlan_acl \
wlan_ccmp \ wlan_ccmp \
wlan_tkip \ wlan_tkip \
wlan_wep \ wlan_wep \
wlan_xauth wlan_xauth
endif endif
   
ifeq ($(findstring AHB,$(BUS)),AHB) ifeq ($(findstring AHB,$(BUS)),AHB)
MADWIFI_FILES+= $(PKG_BUILD_DIR)/ath/ath_ahb.ko MADWIFI_FILES+= $(PKG_BUILD_DIR)/ath/ath_ahb.ko
MADWIFI_AUTOLOAD+= ath_ahb MADWIFI_AUTOLOAD+= ath_ahb
endif endif
ifeq ($(findstring PCI,$(BUS)),PCI) ifeq ($(findstring PCI,$(BUS)),PCI)
MADWIFI_FILES+= $(PKG_BUILD_DIR)/ath/ath_pci.ko MADWIFI_FILES+= $(PKG_BUILD_DIR)/ath/ath_pci.ko
MADWIFI_AUTOLOAD+= ath_pci MADWIFI_AUTOLOAD+= ath_pci
endif endif
   
MADWIFI_APPLETS:=80211stats athchans athkey athstats wlanconfig ath_info madwifi_multi MADWIFI_APPLETS:=80211stats athchans athkey athstats wlanconfig ath_info madwifi_multi
ifdef CONFIG_MADWIFI_DEBUG ifdef CONFIG_MADWIFI_DEBUG
MADWIFI_APPLETS += athdebug 80211debug MADWIFI_APPLETS += athdebug 80211debug
endif endif
   
define KernelPackage/madwifi define KernelPackage/madwifi
SUBMENU:=Wireless Drivers SUBMENU:=Wireless Drivers
TITLE:=Driver for Atheros wireless chipsets TITLE:=Driver for Atheros wireless chipsets
URL:=http://madwifi-project.org/ URL:=http://madwifi-project.org/
DEPENDS:=+wireless-tools @PCI_SUPPORT @(!(TARGET_avr32||TARGET_brcm63xx||TARGET_cobalt||TARGET_ep93xx||TARGET_etrax||TARGET_octeon||TARGET_pxcab||TARGET_sibyte)||BROKEN) +@DRIVER_WEXT_SUPPORT +hostapd-common-old DEPENDS:=+wireless-tools @PCI_SUPPORT @(!(TARGET_avr32||TARGET_brcm63xx||TARGET_cobalt||TARGET_ep93xx||TARGET_etrax||TARGET_octeon||TARGET_pxcab||TARGET_sibyte)||BROKEN) +@DRIVER_WEXT_SUPPORT +hostapd-common-old @BROKEN
FILES:=$(MADWIFI_FILES) FILES:=$(MADWIFI_FILES)
AUTOLOAD:=$(call AutoLoad,50,$(MADWIFI_AUTOLOAD)) AUTOLOAD:=$(call AutoLoad,50,$(MADWIFI_AUTOLOAD))
MENU:=1 MENU:=1
endef endef
   
define KernelPackage/madwifi/description define KernelPackage/madwifi/description
This package contains a driver for Atheros 802.11a/b/g chipsets. This package contains a driver for Atheros 802.11a/b/g chipsets.
endef endef
   
define KernelPackage/madwifi/config define KernelPackage/madwifi/config
source "$(SOURCE)/Config.in" source "$(SOURCE)/Config.in"
endef endef
   
MADWIFI_INC = \ MADWIFI_INC = \
-I$(PKG_BUILD_DIR) \ -I$(PKG_BUILD_DIR) \
-I$(PKG_BUILD_DIR)/include \ -I$(PKG_BUILD_DIR)/include \
-I$(PKG_BUILD_DIR)/hal \ -I$(PKG_BUILD_DIR)/hal \
-I$(PKG_BUILD_DIR)/ath \ -I$(PKG_BUILD_DIR)/ath \
-I$(PKG_BUILD_DIR)/ath_hal \ -I$(PKG_BUILD_DIR)/ath_hal \
-I$(PKG_BUILD_DIR)/net80211 \ -I$(PKG_BUILD_DIR)/net80211 \
-I$(STAGING_DIR)/usr/include/wprobe \ -I$(STAGING_DIR)/usr/include/wprobe \
-include $(PKG_BUILD_DIR)/include/compat.h -include $(PKG_BUILD_DIR)/include/compat.h
   
MAKE_ARGS:= \ MAKE_ARGS:= \
PATH="$(TARGET_PATH)" \ PATH="$(TARGET_PATH)" \
ARCH="$(LINUX_KARCH)" \ ARCH="$(LINUX_KARCH)" \
ARCH-y="$(LINUX_KARCH)" \ ARCH-y="$(LINUX_KARCH)" \
CROSS_COMPILE="$(TARGET_CROSS)" \ CROSS_COMPILE="$(TARGET_CROSS)" \
TARGET="$(HAL_TARGET)" \ TARGET="$(HAL_TARGET)" \
TOOLPREFIX="$(KERNEL_CROSS)" \ TOOLPREFIX="$(KERNEL_CROSS)" \
TOOLPATH="$(KERNEL_CROSS)" \ TOOLPATH="$(KERNEL_CROSS)" \
KERNELPATH="$(LINUX_DIR)" \ KERNELPATH="$(LINUX_DIR)" \
KERNELRELEASE="$(LINUX_VERSION)" \ KERNELRELEASE="$(LINUX_VERSION)" \
LDOPTS="--no-warn-mismatch " \ LDOPTS="--no-warn-mismatch " \
ATH_RATE="$(RATE_CONTROL)" \ ATH_RATE="$(RATE_CONTROL)" \
ATH_CAP_SUPERG_COMP="$(COMPRESSION)" \ ATH_CAP_SUPERG_COMP="$(COMPRESSION)" \
DO_MULTI=1 \ DO_MULTI=1 \
SINGLE_MODULE=$(if $(CONFIG_MADWIFI_SINGLE_MODULE),1) \ SINGLE_MODULE=$(if $(CONFIG_MADWIFI_SINGLE_MODULE),1) \
INCS="$(MADWIFI_INC)" \ INCS="$(MADWIFI_INC)" \
$(if $(CONFIG_MADWIFI_DEBUG),,DEBUG=) WARNINGS="-Wno-unused" $(if $(CONFIG_MADWIFI_DEBUG),,DEBUG=) WARNINGS="-Wno-unused"
   
MAKE_VARS:= \ MAKE_VARS:= \
COPTS="-DATH_REVERSE_ENGINEERING=1" \ COPTS="-DATH_REVERSE_ENGINEERING=1" \
   
define Build/Prepare/HAL define Build/Prepare/HAL
rm -rf $(PKG_BUILD_DIR)/tmp rm -rf $(PKG_BUILD_DIR)/tmp
mkdir -p $(PKG_BUILD_DIR)/tmp mkdir -p $(PKG_BUILD_DIR)/tmp
tar xvzf $(DL_DIR)/$(HAL_FILE) -C $(PKG_BUILD_DIR)/tmp tar xvzf $(DL_DIR)/$(HAL_FILE) -C $(PKG_BUILD_DIR)/tmp
$(CP) $(PKG_BUILD_DIR)/tmp/ath_hal*/* $(PKG_BUILD_DIR)/hal/ $(CP) $(PKG_BUILD_DIR)/tmp/ath_hal*/* $(PKG_BUILD_DIR)/hal/
rm -rf $(PKG_BUILD_DIR)/tmp rm -rf $(PKG_BUILD_DIR)/tmp
endef endef
   
define Build/Prepare define Build/Prepare
$(call Build/Prepare/Default) $(call Build/Prepare/Default)
$(call Build/Prepare/HAL) $(call Build/Prepare/HAL)
# patch cflags # patch cflags
$(SED) 's, -E[LB],,' \ $(SED) 's, -E[LB],,' \
-e 's, -mips2,,' \ -e 's, -mips2,,' \
-e 's, -mapcs-32,,' \ -e 's, -mapcs-32,,' \
-e 's, -mlong-calls,,' \ -e 's, -mlong-calls,,' \
$(PKG_BUILD_DIR)/hal/public/*.inc $(PKG_BUILD_DIR)/hal/public/*.inc
$(SED) 's,march=armv4,march=armv5te,' \ $(SED) 's,march=armv4,march=armv5te,' \
$(PKG_BUILD_DIR)/hal/public/xscale*.inc $(PKG_BUILD_DIR)/hal/public/xscale*.inc
$(SED) 's,march=armv6j,march=armv6k,' \ $(SED) 's,march=armv6j,march=armv6k,' \
$(PKG_BUILD_DIR)/hal/public/arm11*.inc $(PKG_BUILD_DIR)/hal/public/arm11*.inc
$(SED) 's,mtune=arm1136j-s,mtune=mpcore,' \ $(SED) 's,mtune=arm1136j-s,mtune=mpcore,' \
$(PKG_BUILD_DIR)/hal/public/arm11*.inc $(PKG_BUILD_DIR)/hal/public/arm11*.inc
endef endef
   
ifeq ($(findstring AHB,$(BUS)),AHB) ifeq ($(findstring AHB,$(BUS)),AHB)
define Build/Compile/ahb define Build/Compile/ahb
$(MAKE_VARS) $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) BUS="AHB" modules $(MAKE_VARS) $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) BUS="AHB" modules
$(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) CFLAGS="$(TARGET_CFLAGS)" tools $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) CFLAGS="$(TARGET_CFLAGS)" tools
endef endef
endif endif
   
ifeq ($(findstring PCI,$(BUS)),PCI) ifeq ($(findstring PCI,$(BUS)),PCI)
define Build/Compile/pci define Build/Compile/pci
$(MAKE_VARS) $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) BUS="PCI" modules $(MAKE_VARS) $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) BUS="PCI" modules
$(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) CFLAGS="$(TARGET_CFLAGS)" tools $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_ARGS) CFLAGS="$(TARGET_CFLAGS)" tools
endef endef
endif endif
   
define Build/Configure define Build/Configure
$(SED) 's,-E[LB] ,,g' $(PKG_BUILD_DIR)/hal/public/*.inc $(SED) 's,-E[LB] ,,g' $(PKG_BUILD_DIR)/hal/public/*.inc
endef endef
   
define Build/Compile define Build/Compile
$(call Build/Compile/ahb) $(call Build/Compile/ahb)
$(call Build/Compile/pci) $(call Build/Compile/pci)
endef endef
   
define Build/InstallDev define Build/InstallDev
mkdir -p $(1)/usr/include/madwifi mkdir -p $(1)/usr/include/madwifi
$(CP) $(PKG_BUILD_DIR)/include $(1)/usr/include/madwifi/ $(CP) $(PKG_BUILD_DIR)/include $(1)/usr/include/madwifi/
mkdir -p $(1)/usr/include/madwifi/net80211 mkdir -p $(1)/usr/include/madwifi/net80211
$(CP) $(PKG_BUILD_DIR)/net80211/*.h $(1)/usr/include/madwifi/net80211/ $(CP) $(PKG_BUILD_DIR)/net80211/*.h $(1)/usr/include/madwifi/net80211/
endef endef
   
define KernelPackage/madwifi/install define KernelPackage/madwifi/install
$(INSTALL_DIR) $(1)/usr/sbin $(INSTALL_DIR) $(1)/usr/sbin
$(CP) ./files/* $(1)/ $(CP) ./files/* $(1)/
$(CP) $(foreach applet,$(MADWIFI_APPLETS),$(PKG_BUILD_DIR)/tools/$(applet)) $(1)/usr/sbin/ $(CP) $(foreach applet,$(MADWIFI_APPLETS),$(PKG_BUILD_DIR)/tools/$(applet)) $(1)/usr/sbin/
endef endef
   
$(eval $(call KernelPackage,madwifi)) $(eval $(call KernelPackage,madwifi))
   
file:a/net/privoxy/Makefile (deleted)
#  
# Copyright (C) 2006-2013 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=privoxy  
PKG_VERSION:=3.0.21  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-stable-src.tar.gz  
PKG_SOURCE_URL:=@SF/ijbswa  
PKG_MD5SUM:=79558f2545cfcf9731f7de611646d837  
 
PKG_LICENSE:=GPLv2  
PKG_LICENSE_FILES:=LICENSE  
 
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)-stable  
PKG_FIXUP:=autoreconf  
PKG_INSTALL:=1  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/privoxy  
SECTION:=net  
CATEGORY:=Network  
SUBMENU:=Web Servers/Proxies  
DEPENDS:=+libpcre +libpthread +zlib  
TITLE:=web proxy with advanced filtering capabilities  
URL:=http://www.privoxy.org/  
endef  
 
define Package/privoxy/description  
Privoxy is a web proxy with advanced filtering capabilities for  
protecting privacy, modifying web page content, managing cookies,  
controlling access, and removing ads, banners, pop-ups and other  
obnoxious Internet junk. Privoxy has a very flexible configuration  
and can be customized to suit individual needs and tastes. Privoxy  
has application for both stand-alone systems and multi-user networks.  
endef  
 
CONFIGURE_ARGS += \  
--sysconfdir=/etc/privoxy \  
 
MAKE_FLAGS :=  
 
define Package/privoxy/conffiles  
/etc/privoxy/config  
endef  
 
define Package/privoxy/install  
$(INSTALL_DIR) $(1)/usr/sbin  
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/privoxy $(1)/usr/sbin/  
$(INSTALL_DIR) $(1)/etc/privoxy  
$(CP) $(PKG_INSTALL_DIR)/etc/privoxy/* $(1)/etc/privoxy/  
$(INSTALL_CONF) ./files/privoxy.config $(1)/etc/privoxy/config  
$(INSTALL_DIR) $(1)/etc/init.d  
$(INSTALL_BIN) ./files/privoxy.init $(1)/etc/init.d/privoxy  
endef  
 
$(eval $(call BuildPackage,privoxy))  
 
confdir /etc/privoxy  
logdir /var/log  
filterfile default.filter  
logfile privoxy  
actionsfile match-all.action # Actions that are applied to all sites and maybe overruled later on.  
actionsfile default.action # Main actions file  
#actionsfile user.action # User customizations  
listen-address 127.0.0.1:8118  
toggle 1  
enable-remote-toggle 1  
enable-remote-http-toggle 0  
enable-edit-actions 1  
enforce-blocks 0  
buffer-limit 4096  
forwarded-connect-retries 0  
accept-intercepted-requests 0  
allow-cgi-request-crunching 0  
split-large-forms 0  
keep-alive-timeout 300  
socket-timeout 300  
permit-access 192.168.1.0/24  
debug 1 # show each GET/POST/CONNECT request  
debug 4096 # Startup banner and warnings  
debug 8192 # Errors - *we highly recommended enabling this*  
#admin-address privoxy-admin@example.com  
#proxy-info-url http://www.example.com/proxy-service.html  
 
 
#!/bin/sh /etc/rc.common  
# Copyright (C) 2006-2011 OpenWrt.org  
 
START=80  
STOP=80  
 
SERVICE_USE_PID=1  
 
start() {  
service_start /usr/sbin/privoxy --pidfile /var/run/privoxy.pid \  
/etc/privoxy/config  
}  
 
stop() {  
service_stop /usr/sbin/privoxy  
}  
 
#  
# Copyright (C) 2006-2010 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=cryptsetup  
PKG_VERSION:=1.6.2  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2  
PKG_SOURCE_URL:=http://cryptsetup.googlecode.com/files/  
PKG_MD5SUM:=cd834da49fbe92dd66df02cc5c61280f  
 
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)  
 
include $(INCLUDE_DIR)/package.mk  
 
TARGET_LDFLAGS+=-Wl,-rpath-link=$(STAGING_DIR)/usr/lib  
 
define Package/cryptsetup/Default  
SECTION:=utils  
CATEGORY:=Utilities  
TITLE:=Cryptsetup  
DEPENDS:=+libblkid +libuuid +libpopt +lvm2 +libdevmapper +@KERNEL_DIRECT_IO  
URL:=http://code.google.com/p/cryptsetup/  
endef  
 
define Package/cryptsetup  
$(call Package/cryptsetup/Default)  
DEPENDS+=+libgcrypt  
VARIANT:=gcrypt  
endef  
 
define Package/cryptsetup-openssl  
$(call Package/cryptsetup/Default)  
TITLE+= (with openssl support)  
DEPENDS+=+libopenssl  
VARIANT:=openssl  
endef  
 
define Package/cryptsetup/Default/description  
Cryptsetup-luks  
endef  
 
define Package/cryptsetup/description  
$(call Package/cryptsetup/Default/description)  
linked against libgcrypt  
endef  
 
 
define Package/cryptsetup-openssl/description  
$(call Package/cryptsetup/Default/description)  
linked against openssl  
endef  
 
ifeq ($(BUILD_VARIANT),openssl)  
CONFIGURE_ARGS+= \  
--with-crypto_backend=openssl  
endif  
 
define Package/cryptsetup/install  
$(INSTALL_DIR) $(1)/usr/sbin  
$(CP) $(PKG_BUILD_DIR)/src/.libs/cryptsetup $(1)/usr/sbin  
$(INSTALL_DIR) $(1)/usr/lib  
$(CP) $(PKG_BUILD_DIR)/lib/.libs/libcryptsetup.so* $(1)/usr/lib  
endef  
 
Package/cryptsetup-openssl/install = $(Package/cryptsetup/install)  
 
$(eval $(call BuildPackage,cryptsetup))  
$(eval $(call BuildPackage,cryptsetup-openssl))  
 
file:a/utils/hdparm/Makefile (deleted)
#  
# Copyright (C) 2006-2012 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=hdparm  
PKG_VERSION:=9.39  
PKG_RELEASE:=1  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=@SF/$(PKG_NAME)  
PKG_MD5SUM:=2bc17b72403885d4faf959682944243b  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/hdparm  
SECTION:=utils  
CATEGORY:=Utilities  
SUBMENU:=disc  
TITLE:=Hard disk drive configuration utilitity  
URL:=http://sourceforge.net/projects/hdparm/  
endef  
 
define Package/hdparm/description  
get/set SATA/IDE device parameters  
endef  
 
define Package/hdparm/install  
$(INSTALL_DIR) $(1)/sbin  
$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_NAME) $(1)/sbin  
endef  
 
$(eval $(call BuildPackage,hdparm))  
 
file:a/utils/joe/Makefile (deleted)
#  
# Copyright (C) 2007 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
# changes by David Kuehling <dvdkhlng TA gmx TOD de>:  
#  
# - include support for all emulation modes jmacs jpico etc.  
# - see patches/002-builtinrc.patch  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=joe  
PKG_VERSION:=3.7  
PKG_RELEASE:=3  
 
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz  
PKG_SOURCE_URL:=@SF/joe-editor  
PKG_MD5SUM:=66de1b073e869ba12abbfcde3885c577  
 
PKG_BUILD_DIR=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/joe  
SECTION:=utils  
CATEGORY:=Utilities  
DEPENDS:=+libncurses  
TITLE:=JOE - Joes own editor  
URL:=http://sourceforge.net/projects/joe-editor/  
SUBMENU:=Editors  
endef  
 
define Package/joe/description  
Joe is world-famous Wordstar like text editor, that also features  
Emacs and Pico emulation  
endef  
 
define Package/joe/install  
$(INSTALL_DIR) $(1)/usr/bin  
$(INSTALL_BIN) $(PKG_BUILD_DIR)/joe $(1)/usr/bin/  
for i in jmacs jstar rjoe jpico; do \  
ln -sf joe $(1)/usr/bin/$$$$i; \  
done  
endef  
 
$(eval $(call BuildPackage,joe))  
 
--- a/umath.c  
+++ b/umath.c  
@@ -378,7 +378,6 @@ double m_cos(double n) { return cos(n);  
double m_tan(double n) { return tan(n); }  
double m_exp(double n) { return exp(n); }  
double m_sqrt(double n) { return sqrt(n); }  
-double m_cbrt(double n) { return cbrt(n); }  
double m_log(double n) { return log(n); }  
double m_log10(double n) { return log10(n); }  
double m_asin(double n) { return asin(n); }  
@@ -387,19 +386,10 @@ double m_atan(double n) { return atan(n)  
double m_sinh(double n) { return sinh(n); }  
double m_cosh(double n) { return cosh(n); }  
double m_tanh(double n) { return tanh(n); }  
-double m_asinh(double n) { return asinh(n); }  
-double m_acosh(double n) { return acosh(n); }  
-double m_atanh(double n) { return atanh(n); }  
double m_int(double n) { return (int)(n); }  
double m_floor(double n) { return floor(n); }  
double m_ceil(double n) { return ceil(n); }  
double m_fabs(double n) { return fabs(n); }  
-double m_erf(double n) { return erf(n); }  
-double m_erfc(double n) { return erfc(n); }  
-double m_j0(double n) { return j0(n); }  
-double m_j1(double n) { return j1(n); }  
-double m_y0(double n) { return y0(n); }  
-double m_y1(double n) { return y1(n); }  
 
double calc(BW *bw, unsigned char *s)  
{  
@@ -414,7 +404,6 @@ double calc(BW *bw, unsigned char *s)  
v = get(USTR "tan"); v->func = m_tan;  
v = get(USTR "exp"); v->func = m_exp;  
v = get(USTR "sqrt"); v->func = m_sqrt;  
- v = get(USTR "cbrt"); v->func = m_cbrt;  
v = get(USTR "ln"); v->func = m_log;  
v = get(USTR "log"); v->func = m_log10;  
v = get(USTR "asin"); v->func = m_asin;  
@@ -425,19 +414,10 @@ double calc(BW *bw, unsigned char *s)  
v = get(USTR "sinh"); v->func = m_sinh;  
v = get(USTR "cosh"); v->func = m_cosh;  
v = get(USTR "tanh"); v->func = m_tanh;  
- v = get(USTR "asinh"); v->func = m_asinh;  
- v = get(USTR "acosh"); v->func = m_acosh;  
- v = get(USTR "atanh"); v->func = m_atanh;  
v = get(USTR "int"); v->func = m_int;  
v = get(USTR "floor"); v->func = m_floor;  
v = get(USTR "ceil"); v->func = m_ceil;  
v = get(USTR "abs"); v->func = m_fabs;  
- v = get(USTR "erf"); v->func = m_erf;  
- v = get(USTR "erfc"); v->func = m_erfc;  
- v = get(USTR "j0"); v->func = m_j0;  
- v = get(USTR "j1"); v->func = m_j1;  
- v = get(USTR "y0"); v->func = m_y0;  
- v = get(USTR "y1"); v->func = m_y1;  
}  
 
v = get(USTR "top");  
 
#  
# Copyright (C) 2013 OpenWrt.org  
#  
# This is free software, licensed under the GNU General Public License v2.  
# See /LICENSE for more information.  
#  
 
include $(TOPDIR)/rules.mk  
 
PKG_NAME:=open-plc-utils  
PKG_VERSION:=2013-01-29  
PKG_RELEASE:=$(PKG_SOURCE_VERSION)  
 
PKG_SOURCE_PROTO:=git  
PKG_SOURCE_URL:=git://github.com/qca/open-plc-utils.git  
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)  
PKG_SOURCE_VERSION:=6beeb6fe6ce2b16b14284c26e1b9220b68044591  
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz  
 
PKG_BUILD_PARALLEL:=1  
 
include $(INCLUDE_DIR)/package.mk  
 
define Package/open-plc-utils/Default  
SECTION:=utils  
CATEGORY:=Utilities  
TITLE:=Qualcomm Atheros Power Line Communication utilities  
URL:=https://github.com/qca/open-plc-utils/blob/master/README  
endef  
 
define Package/open-plc-utils  
$(call Package/open-plc-utils/Default)  
MENU:=1  
endef  
 
define GenPlugin  
define Package/$(addprefix open-plc-utils-,$(1))  
$(call Package/open-plc-utils/Default)  
DEPENDS:=open-plc-utils  
TITLE:=Utility $(2) from the Open PLC utilities  
endef  
 
define Package/$(addprefix open-plc-utils-,$(1))/description  
Utility $(2) from the Open PLC utilities package.  
endef  
endef  
 
OPEN_PLC_UTILS_APPS:=efbu efeu efru efsu edru edsu nics \  
hpavkey hpavkeys rkey mac2pw mac2pwd \  
mdioblock mdioblock2 mdiodump mdiogen \  
hpav mme \  
chknvm chknvm2 nvmsplit nvmmerge \  
chkpib chkpib2 setpib getpib modpib pib2xml \  
pibcomp pibdump pibruin xml2pib psin psout pskey \  
psgraph psnotch pibrump \  
int6k int6kboot int6keth int6kf int6khost \  
int64host int6kid int6klist int6klog int6kmdio \  
int6kmdio2 int6kmod int6kstat int6ktest int6krate \  
int6krule int6ktone int6kwait CMEncrypt sada \  
coqos_add coqos_info coqos_man coqos_mod coqos_rel \  
mdustats ampboot amphost ampID amplist amprate \  
ampstat amptest amptool amptone ampwait \  
plcboot plchost plcID plclist plcrate plcrule \  
plcstat plctest plctool plctone \  
plcwait plchostd plcget plcset plcotst plcfwd \  
plcdevs plclog plcmdio16 plcmdio32 \  
config2cfg sdram \  
int6kuart int6kbaud ttysig ptsctl weeder ttysend \  
ttyrecv ttycat int6kdetect  
 
$(foreach a,$(OPEN_PLC_UTILS_APPS),$(eval $(call GenPlugin,$(a))))  
 
define Build/Compile  
$(MAKE) -C $(PKG_BUILD_DIR) \  
EXTRA_CFLAGS="$(TARGET_CPPFLAGS) $(TARGET_CFLAGS)" \  
LDFLAGS="$(TARGET_CFLAGS) $(TARGET_LDFLAGS)" \  
CROSS="$(TARGET_CROSS)" \  
ROOTFS="$(PKG_INSTALL_DIR)" \  
OWNER="$(shell id -u $(shell whoami))" \  
GROUP="$(shell id -g $(shell whoami))" \  
all install  
endef  
 
define Package/open-plc-utils/install  
endef  
 
define BuildPlugin  
define Package/$(1)/install  
$(INSTALL_DIR) $$(1)/usr/bin  
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/local/bin/$(subst open-plc-utils-,,$(1)) \  
$$(1)/usr/bin/  
endef  
 
$$(eval $$(call BuildPackage,$(1)))  
endef  
 
$(eval $(call BuildPackage,open-plc-utils))  
$(foreach a,$(OPEN_PLC_UTILS_APPS),$(eval $(call BuildPlugin,open-plc-utils-$(a))))  
 
comments