tiff: moved to github
tiff: moved to github

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

file:a/lang/luaexpat/Makefile (deleted)
--- a/lang/luaexpat/Makefile
+++ /dev/null
@@ -1,56 +1,1 @@
-#
-# Copyright (C) 2009 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:=luaexpat
-PKG_VERSION:=1.1
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://luaforge.net/frs/download.php/2469
-PKG_MD5SUM:=6ecb895ccf5cff1e7f2facd438b1f8d0
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/luaexpat
-  SUBMENU:=Lua
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=LuaExpat
-  URL:=http://www.keplerproject.org/luaexpat/
-  DEPENDS:=+lua +libexpat
-endef
-
-define Package/luaexpat/description
-  LuaExpat is a SAX XML parser based on the Expat library.
-endef
-
-define Build/Configure
-endef
-
-define Build/Compile
-	$(CP) files/compat-5.1r5 $(PKG_BUILD_DIR)/compat-5.1r5
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-	EXPAT_INC="$(STAGING_DIR)/usr/include/" \
-	LUA_INC="$(STAGING_DIR)/usr/include/" \
-	LUA_LIBDIR="$(STAGING_DIR)/usr/lib/" \
-	COMPAT_DIR="$(PKG_BUILD_DIR)/compat-5.1r5" \
-	LIB_OPTION="-shared $(TARGET_LDFLAGS)" \
-	CC="$(TARGET_CC) $(TARGET_CFLAGS) $(FPIC) -std=c99" \
-	LD="$(TARGET_CROSS)ld -shared"
-endef
-
-define Package/luaexpat/install
-	$(INSTALL_DIR) $(1)/usr/lib/lua
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/lxp.so.1.1.0 $(1)/usr/lib/lua/lxp.so
-	$(INSTALL_DIR) $(1)/usr/lib/lua/lxp
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/lxp/lom.lua $(1)/usr/lib/lua/lxp
-endef
-
-$(eval $(call BuildPackage,luaexpat))
-

--- a/lang/luaexpat/files/compat-5.1r5/compat-5.1.c
+++ /dev/null
@@ -1,98 +1,1 @@
-/*
-** Compat-5.1
-** Copyright Kepler Project 2004-2006 (http://www.keplerproject.org/compat)
-** $Id: compat-5.1.c,v 1.13 2006/02/20 21:12:47 carregal Exp $
-*/
 
-#include <stdio.h>
-#include <string.h>
-#include "lua.h"
-#include "lauxlib.h"
-#include "compat-5.1.h"
-
-static void getfield(lua_State *L, int idx, const char *name) {
-    const char *end = strchr(name, '.');
-    lua_pushvalue(L, idx);
-    while (end) {
-        lua_pushlstring(L, name, end - name);
-        lua_gettable(L, -2);
-        lua_remove(L, -2);
-        if (lua_isnil(L, -1)) return;
-        name = end+1;
-        end = strchr(name, '.');
-    }
-    lua_pushstring(L, name);
-    lua_gettable(L, -2);
-    lua_remove(L, -2);
-}
-
-static void setfield(lua_State *L, int idx, const char *name) {
-    const char *end = strchr(name, '.');
-    lua_pushvalue(L, idx);
-    while (end) {
-        lua_pushlstring(L, name, end - name);
-        lua_gettable(L, -2);
-        /* create table if not found */
-        if (lua_isnil(L, -1)) {
-            lua_pop(L, 1);
-            lua_newtable(L);
-            lua_pushlstring(L, name, end - name);
-            lua_pushvalue(L, -2);
-            lua_settable(L, -4);
-        }
-        lua_remove(L, -2);
-        name = end+1;
-        end = strchr(name, '.');
-    }
-    lua_pushstring(L, name);
-    lua_pushvalue(L, -3);
-    lua_settable(L, -3);
-    lua_pop(L, 2);
-}
-
-LUALIB_API void luaL_module(lua_State *L, const char *libname,
-                              const luaL_reg *l, int nup) {
-  if (libname) {
-    getfield(L, LUA_GLOBALSINDEX, libname);  /* check whether lib already exists */
-    if (lua_isnil(L, -1)) { 
-      int env, ns;
-      lua_pop(L, 1); /* get rid of nil */
-      lua_pushliteral(L, "require");
-      lua_gettable(L, LUA_GLOBALSINDEX); /* look for require */
-      lua_getfenv(L, -1); /* getfenv(require) */
-      lua_remove(L, -2); /* remove function require */
-      env = lua_gettop(L);
-
-      lua_newtable(L); /* create namespace for lib */
-      ns = lua_gettop(L);
-      getfield(L, env, "package.loaded"); /* get package.loaded table */
-      if (lua_isnil(L, -1)) { /* create package.loaded table */
-          lua_pop(L, 1); /* remove previous result */
-          lua_newtable(L);
-          lua_pushvalue(L, -1);
-          setfield(L, env, "package.loaded");
-      }
-      else if (!lua_istable(L, -1))
-        luaL_error(L, "name conflict for library `%s'", libname);
-      lua_pushstring(L, libname);
-      lua_pushvalue(L, ns); 
-      lua_settable(L, -3); /* package.loaded[libname] = ns */
-      lua_pop(L, 1); /* get rid of package.loaded table */
-      lua_pushvalue(L, ns); /* copy namespace */
-      setfield(L, LUA_GLOBALSINDEX, libname);
-      lua_remove (L, env); /* remove env */
-    }
-    lua_insert(L, -(nup+1));  /* move library table to below upvalues */
-  }
-  for (; l->name; l++) {
-    int i;
-    lua_pushstring(L, l->name);
-    for (i=0; i<nup; i++)  /* copy upvalues to the top */
-      lua_pushvalue(L, -(nup+1));
-    lua_pushcclosure(L, l->func, nup);
-    lua_settable(L, -(nup+3));
-  }
-  lua_pop(L, nup);  /* remove upvalues */
-}
-
-

--- a/lang/luaexpat/files/compat-5.1r5/compat-5.1.h
+++ /dev/null
@@ -1,14 +1,1 @@
-/*
-** Compat-5.1
-** Copyright Kepler Project 2004-2006 (http://www.keplerproject.org/compat/)
-** $Id: compat-5.1.h,v 1.8 2006/02/20 21:12:47 carregal Exp $
-*/
 
-#ifndef COMPAT_H
-
-LUALIB_API void luaL_module(lua_State *L, const char *libname,
-                                       const luaL_reg *l, int nup);
-#define luaL_openlib luaL_module
-
-#endif
-

--- a/lang/luaexpat/files/compat-5.1r5/compat-5.1.lua
+++ /dev/null
@@ -1,268 +1,1 @@
---
--- Compat-5.1
--- Copyright Kepler Project 2004-2006 (http://www.keplerproject.org/compat)
--- According to Lua 5.1
--- $Id: compat-5.1.lua,v 1.22 2006/02/20 21:12:47 carregal Exp $
---
 
-_COMPAT51 = "Compat-5.1 R5"
-
-local LUA_DIRSEP = '/'
-local LUA_OFSEP = '_'
-local OLD_LUA_OFSEP = ''
-local POF = 'luaopen_'
-local LUA_PATH_MARK = '?'
-local LUA_IGMARK = ':'
-
-local assert, error, getfenv, ipairs, loadfile, loadlib, pairs, setfenv, setmetatable, type = assert, error, getfenv, ipairs, loadfile, loadlib, pairs, setfenv, setmetatable, type
-local find, format, gfind, gsub, sub = string.find, string.format, string.gfind, string.gsub, string.sub
-
---
--- avoid overwriting the package table if it's already there
---
-package = package or {}
-local _PACKAGE = package
-
-package.path = LUA_PATH or os.getenv("LUA_PATH") or
-             ("./?.lua;" ..
-              "/usr/local/share/lua/5.0/?.lua;" ..
-              "/usr/local/share/lua/5.0/?/?.lua;" ..
-              "/usr/local/share/lua/5.0/?/init.lua" )
- 
-package.cpath = LUA_CPATH or os.getenv("LUA_CPATH") or
-             "./?.so;" ..
-             "./l?.so;" ..
-             "/usr/local/lib/lua/5.0/?.so;" ..
-             "/usr/local/lib/lua/5.0/l?.so"
-
---
--- make sure require works with standard libraries
---
-package.loaded = package.loaded or {}
-package.loaded.debug = debug
-package.loaded.string = string
-package.loaded.math = math
-package.loaded.io = io
-package.loaded.os = os
-package.loaded.table = table 
-package.loaded.base = _G
-package.loaded.coroutine = coroutine
-local _LOADED = package.loaded
-
---
--- avoid overwriting the package.preload table if it's already there
---
-package.preload = package.preload or {}
-local _PRELOAD = package.preload
-
-
---
--- looks for a file `name' in given path
---
-local function findfile (name, pname)
-	name = gsub (name, "%.", LUA_DIRSEP)
-	local path = _PACKAGE[pname]
-	assert (type(path) == "string", format ("package.%s must be a string", pname))
-	for c in gfind (path, "[^;]+") do
-		c = gsub (c, "%"..LUA_PATH_MARK, name)
-		local f = io.open (c)
-		if f then
-			f:close ()
-			return c
-		end
-	end
-	return nil -- not found
-end
-
-
---
--- check whether library is already loaded
---
-local function loader_preload (name)
-	assert (type(name) == "string", format (
-		"bad argument #1 to `require' (string expected, got %s)", type(name)))
-	assert (type(_PRELOAD) == "table", "`package.preload' must be a table")
-	return _PRELOAD[name]
-end
-
-
---
--- Lua library loader
---
-local function loader_Lua (name)
-	assert (type(name) == "string", format (
-		"bad argument #1 to `require' (string expected, got %s)", type(name)))
-	local filename = findfile (name, "path")
-	if not filename then
-		return false
-	end
-	local f, err = loadfile (filename)
-	if not f then
-		error (format ("error loading module `%s' (%s)", name, err))
-	end
-	return f
-end
-
-
-local function mkfuncname (name)
-	name = gsub (name, "^.*%"..LUA_IGMARK, "")
-	name = gsub (name, "%.", LUA_OFSEP)
-	return POF..name
-end
-
-local function old_mkfuncname (name)
-	--name = gsub (name, "^.*%"..LUA_IGMARK, "")
-	name = gsub (name, "%.", OLD_LUA_OFSEP)
-	return POF..name
-end
-
---
--- C library loader
---
-local function loader_C (name)
-	assert (type(name) == "string", format (
-		"bad argument #1 to `require' (string expected, got %s)", type(name)))
-	local filename = findfile (name, "cpath")
-	if not filename then
-		return false
-	end
-	local funcname = mkfuncname (name)
-	local f, err = loadlib (filename, funcname)
-	if not f then
-		funcname = old_mkfuncname (name)
-		f, err = loadlib (filename, funcname)
-		if not f then
-			error (format ("error loading module `%s' (%s)", name, err))
-		end
-	end
-	return f
-end
-
-
-local function loader_Croot (name)
-	local p = gsub (name, "^([^.]*).-$", "%1")
-	if p == "" then
-		return
-	end
-	local filename = findfile (p, "cpath")
-	if not filename then
-		return
-	end
-	local funcname = mkfuncname (name)
-	local f, err, where = loadlib (filename, funcname)
-	if f then
-		return f
-	elseif where ~= "init" then
-		error (format ("error loading module `%s' (%s)", name, err))
-	end
-end
-
--- create `loaders' table
-package.loaders = package.loaders or { loader_preload, loader_Lua, loader_C, loader_Croot, }
-local _LOADERS = package.loaders
-
-
---
--- iterate over available loaders
---
-local function load (name, loaders)
-	-- iterate over available loaders
-	assert (type (loaders) == "table", "`package.loaders' must be a table")
-	for i, loader in ipairs (loaders) do
-		local f = loader (name)
-		if f then
-			return f
-		end
-	end
-	error (format ("module `%s' not found", name))
-end
-
--- sentinel
-local sentinel = function () end
-
---
--- new require
---
-function _G.require (modname)
-	assert (type(modname) == "string", format (
-		"bad argument #1 to `require' (string expected, got %s)", type(name)))
-	local p = _LOADED[modname]
-	if p then -- is it there?
-		if p == sentinel then
-			error (format ("loop or previous error loading module '%s'", modname))
-		end
-		return p -- package is already loaded
-	end
-	local init = load (modname, _LOADERS)
-	_LOADED[modname] = sentinel
-	local actual_arg = _G.arg
-	_G.arg = { modname }
-	local res = init (modname)
-	if res then
-		_LOADED[modname] = res
-	end
-	_G.arg = actual_arg
-	if _LOADED[modname] == sentinel then
-		_LOADED[modname] = true
-	end
-	return _LOADED[modname]
-end
-
-
--- findtable
-local function findtable (t, f)
-	assert (type(f)=="string", "not a valid field name ("..tostring(f)..")")
-	local ff = f.."."
-	local ok, e, w = find (ff, '(.-)%.', 1)
-	while ok do
-		local nt = rawget (t, w)
-		if not nt then
-			nt = {}
-			t[w] = nt
-		elseif type(t) ~= "table" then
-			return sub (f, e+1)
-		end
-		t = nt
-		ok, e, w = find (ff, '(.-)%.', e+1)
-	end
-	return t
-end
-
---
--- new package.seeall function
---
-function _PACKAGE.seeall (module)
-	local t = type(module)
-	assert (t == "table", "bad argument #1 to package.seeall (table expected, got "..t..")")
-	local meta = getmetatable (module)
-	if not meta then
-		meta = {}
-		setmetatable (module, meta)
-	end
-	meta.__index = _G
-end
-
-
---
--- new module function
---
-function _G.module (modname, ...)
-	local ns = _LOADED[modname]
-	if type(ns) ~= "table" then
-		ns = findtable (_G, modname)
-		if not ns then
-			error (string.format ("name conflict for module '%s'", modname))
-		end
-		_LOADED[modname] = ns
-	end
-	if not ns._NAME then
-		ns._NAME = modname
-		ns._M = ns
-		ns._PACKAGE = gsub (modname, "[^.]*$", "")
-	end
-	setfenv (2, ns)
-	for i, f in ipairs (arg) do
-		f (ns)
-	end
-end
-

--- a/lang/luaexpat/patches/001-compile-fix.patch
+++ /dev/null
@@ -1,11 +1,1 @@
---- a/config
-+++ b/config
-@@ -31,6 +31,6 @@
-         -Wshadow \
-         -Wwrite-strings
- 
--CFLAGS = $(CWARNS) -ansi -O2 -I$(LUA_INC) \
-+CFLAGS = $(CWARNS) -O2 -I$(LUA_INC) \
-    -I$(COMPAT_DIR) -I$(EXPAT_INC)
- CC = gcc
 

--- a/lang/luafilesystem/Makefile
+++ /dev/null
@@ -1,66 +1,1 @@
-#
-# Copyright (C) 2008-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:=luafilesystem
-PKG_VERSION:=1.6.2
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=https://github.com/keplerproject/luafilesystem.git
-PKG_SOURCE_VERSION:=2fd989cd6c777583be1c93616018c55b2cbb1bcf
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/luafilesystem
-  SUBMENU:=Lua
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=LuaFileSystem
-  URL:=http://keplerproject.github.com/luafilesystem/
-  DEPENDS:=+liblua
-endef
-
-define Package/luafilesystem/description
- This package contains the LuaFileSystem library, a set of portable
- functions for directory creation, listing and deletion and for file
- locking.
-endef
-
-define Build/Configure
-endef
-
-TARGET_CFLAGS += $(FPIC) $(TARGET_CPPFLAGS)
-
-TARGET_LDFLAGS += -llua
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		$(TARGET_CONFIGURE_OPTS) \
-		CFLAGS="$(TARGET_CFLAGS) -std=gnu99" \
-		LDFLAGS="$(TARGET_LDFLAGS)"
-	$(TARGET_CROSS)ar r $(PKG_BUILD_DIR)/src/luafilesystem.a $(PKG_BUILD_DIR)/src/lfs.o
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(STAGING_DIR)/usr/include
-	$(INSTALL_DIR) $(STAGING_DIR)/usr/lib/lua
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/lfs.h $(STAGING_DIR)/usr/include
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/lfs.so $(STAGING_DIR)/usr/lib/lua
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/luafilesystem.a $(STAGING_DIR)/usr/lib/lua
-endef
-
-define Package/luafilesystem/install
-	$(INSTALL_DIR) $(1)/usr/lib/lua
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/lfs.so $(1)/usr/lib/lua/lfs.so
-endef
-
-$(eval $(call BuildPackage,luafilesystem))
-

file:a/lang/luasec/Makefile (deleted)
--- a/lang/luasec/Makefile
+++ /dev/null
@@ -1,58 +1,1 @@
-#
-# Copyright (C) 2009-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:=luasec
-PKG_VERSION:=0.4
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://luaforge.net/frs/download.php/4255
-PKG_MD5SUM:=712158d60207bdbb6215fc7e07d8db24
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/luasec
-  SUBMENU:=Lua
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=LuaSec
-  URL:=http://luasec.luaforge.net/
-  DEPENDS:=+lua +libopenssl +luasocket
-endef
-
-define Package/luasec/description
-  LuaSec is a binding for OpenSSL library to provide TLS/SSL communication.
-endef
-
-define Build/Configure
-endef
-
-MAKE_PATH = ./src
-
-MAKE_FLAGS += \
-	INCDIR="$(TARGET_CPPFLAGS)" \
-	LIBDIR="$(TARGET_LDFLAGS)" \
-	CC="$(TARGET_CC) $(TARGET_CFLAGS) -std=gnu99" \
-	LD="$(TARGET_CROSS)ld -shared" \
-	LUACPATH="$(PKG_INSTALL_DIR)/usr/lib/lua" \
-	LUAPATH="$(PKG_INSTALL_DIR)/usr/lib/lua" \
-	linux \
-
-define Package/luasec/install
-	$(INSTALL_DIR) $(1)/usr/lib/lua
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/lua/ssl.so $(1)/usr/lib/lua/
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/lua/ssl.lua $(1)/usr/lib/lua/
-	$(INSTALL_DIR) $(1)/usr/lib/lua/ssl
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/lua/ssl/https.lua $(1)/usr/lib/lua/ssl/
-endef
-
-$(eval $(call BuildPackage,luasec))
-

file:a/lang/luasocket/Makefile (deleted)
--- a/lang/luasocket/Makefile
+++ /dev/null
@@ -1,62 +1,1 @@
-#
-# Copyright (C) 2009-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:=luasocket
-PKG_SOURCE_VERSION:=6d5e40c324c84d9c1453ae88e0ad5bdd0a631448
-PKG_VERSION:=3.0-rc1-20130909
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=https://github.com/diegonehab/luasocket.git
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/luasocket
-  SUBMENU:=Lua
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=LuaSocket
-  URL:=http://luasocket.luaforge.net/
-  DEPENDS:=+lua
-endef
-
-define Package/luasocket/description
-  LuaSocket is the most comprehensive networking support
-  library for the Lua language. It provides easy access to
-  TCP, UDP, DNS, SMTP, FTP, HTTP, MIME and much more.
-endef
-
-define Build/Configure
-endef
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR)/ \
-		LIBDIR="$(TARGET_LDFLAGS)" \
-		CC="$(TARGET_CC) $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) -std=gnu99" \
-		LD="$(TARGET_CROSS)ld -shared" \
-		all
-endef
-
-
-define Package/luasocket/install
-	$(INSTALL_DIR) $(1)/usr/lib/lua
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/{ltn12,mime,socket}.lua $(1)/usr/lib/lua
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mime.so.1.0.3 $(1)/usr/lib/lua
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/socket.so.3.0-rc1 $(1)/usr/lib/lua
-	$(INSTALL_DIR) $(1)/usr/lib/lua/mime
-	ln -sf ../mime.so.1.0.3 $(1)/usr/lib/lua/mime/core.so
-	$(INSTALL_DIR) $(1)/usr/lib/lua/socket
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/{ftp,http,smtp,tp,url,headers}.lua $(1)/usr/lib/lua/socket
-	ln -sf ../socket.so.3.0-rc1 $(1)/usr/lib/lua/socket/core.so
-endef
-
-$(eval $(call BuildPackage,luasocket))
-

--- a/lang/luasocket/patches/0001-Add-interface-support.patch
+++ /dev/null
@@ -1,238 +1,1 @@
-From 96fdf07acf78ecfc9be76a8b0591f38fe6f1a875 Mon Sep 17 00:00:00 2001
-From: Steven Barth <steven@midlink.org>
-Date: Sat, 9 Nov 2013 12:01:42 +0100
-Subject: [PATCH] Add interface resolving
 
----
- src/if.c        | 113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- src/if.h        |  27 ++++++++++++++
- src/luasocket.c |   2 +
- src/makefile    |   2 +
- src/options.c   |   9 +++++
- 5 files changed, 153 insertions(+)
- create mode 100644 src/if.c
- create mode 100644 src/if.h
-
-diff --git a/src/if.c b/src/if.c
-new file mode 100644
-index 0000000..db231aa
---- /dev/null
-+++ b/src/if.c
-@@ -0,0 +1,113 @@
-+/*
-+ * $Id: if.c $
-+ *
-+ * Author: Markus Stenberg <fingon@iki.fi>
-+ *
-+ * Copyright (c) 2012 cisco Systems, Inc.
-+ *
-+ * Created:       Tue Dec  4 14:50:34 2012 mstenber
-+ * Last modified: Wed Dec  5 18:51:08 2012 mstenber
-+ * Edit time:     24 min
-+ *
-+ */
-+
-+#include <sys/types.h>
-+#include <sys/socket.h>
-+#include <net/if.h>
-+
-+#include "if.h"
-+
-+#include "lauxlib.h"
-+
-+static int if_global_indextoname(lua_State *L);
-+static int if_global_nametoindex(lua_State *L);
-+static int if_global_nameindex(lua_State *L);
-+
-+static luaL_Reg func[] = {
-+    { "indextoname", if_global_indextoname},
-+    { "nametoindex", if_global_nametoindex},
-+    { "nameindex", if_global_nameindex},
-+    { NULL, NULL}
-+};
-+
-+int if_open(lua_State *L)
-+{
-+    lua_pushstring(L, "iface");
-+    lua_newtable(L);
-+    luaL_openlib(L, NULL, func, 0);
-+    lua_settable(L, -3);
-+    return 0;
-+}
-+
-+int if_global_indextoname(lua_State *L)
-+{
-+  unsigned int ifnumber;
-+  const char *name;
-+  char buf[IF_NAMESIZE+1];
-+
-+  if (!lua_isnumber(L, 1))
-+    {
-+      lua_pushnil(L);
-+      lua_pushstring(L, "indextoname expects only number argument");
-+      return 2;
-+    }
-+  ifnumber = lua_tonumber(L, 1);
-+  if (!(name = if_indextoname(ifnumber, buf)))
-+    {
-+      lua_pushnil(L);
-+      lua_pushstring(L, "nonexistent interface");
-+      return 2;
-+    }
-+  lua_pushstring(L, name);
-+  return 1;
-+}
-+
-+int if_global_nametoindex(lua_State *L)
-+{
-+  unsigned int ifnumber;
-+  if (!lua_isstring(L, 1))
-+    {
-+      lua_pushnil(L);
-+      lua_pushstring(L, "nametoindex expects only string argument");
-+      return 2;
-+    }
-+  if (!(ifnumber = if_nametoindex(lua_tostring(L, 1))))
-+    {
-+      lua_pushnil(L);
-+      lua_pushstring(L, "nonexistent interface");
-+      return 2;
-+    }
-+  lua_pushnumber(L, ifnumber);
-+  return 1;
-+}
-+
-+int if_global_nameindex(lua_State *L)
-+{
-+  struct if_nameindex *ni, *oni;
-+  int i = 1;
-+  oni = ni = if_nameindex();
-+  lua_newtable(L);
-+  while (ni && ni->if_index && *(ni->if_name))
-+    {
-+      /* at result[i], we store.. */
-+      lua_pushnumber(L, i);
-+
-+      /* new table with two items - index, name*/
-+      lua_newtable(L);
-+      lua_pushstring(L, "index");
-+      lua_pushnumber(L, ni->if_index);
-+      lua_settable(L, -3);
-+
-+      lua_pushstring(L, "name");
-+      lua_pushstring(L, ni->if_name);
-+      lua_settable(L, -3);
-+
-+      /* Then, actually store it */
-+      lua_settable(L, -3);
-+
-+      i++;
-+      ni++;
-+    }
-+  if_freenameindex(oni);
-+  return 1;
-+}
-diff --git a/src/if.h b/src/if.h
-new file mode 100644
-index 0000000..dc7faf8
---- /dev/null
-+++ b/src/if.h
-@@ -0,0 +1,27 @@
-+/*
-+ * $Id: if.h $
-+ *
-+ * Author: Markus Stenberg <fingon@iki.fi>
-+ *
-+ *  Copyright (c) 2012 cisco Systems, Inc.
-+ *
-+ * Created:       Tue Dec  4 14:37:24 2012 mstenber
-+ * Last modified: Tue Dec  4 14:51:43 2012 mstenber
-+ * Edit time:     7 min
-+ *
-+ */
-+
-+/* This module provides Lua wrapping for the advanced socket API
-+ * defined in RFC3542, or mainly, the access to the system's interface
-+ * list. It is necessary for use of recvmsg/sendmsg.
-+ *
-+ * TODO - Do something clever with Windows?
-+ */
-+#ifndef IF_H
-+#define IF_H
-+
-+#include "lua.h"
-+
-+int if_open(lua_State *L);
-+
-+#endif /* IF_H */
-diff --git a/src/luasocket.c b/src/luasocket.c
-index e6ee747..85d41a6 100644
---- a/src/luasocket.c
-+++ b/src/luasocket.c
-@@ -31,6 +31,7 @@
- #include "tcp.h"
- #include "udp.h"
- #include "select.h"
-+#include "if.h"
- 
- /*-------------------------------------------------------------------------*\
- * Internal function prototypes
-@@ -51,6 +52,7 @@ static const luaL_Reg mod[] = {
-     {"tcp", tcp_open},
-     {"udp", udp_open},
-     {"select", select_open},
-+    {"iface", if_open},
-     {NULL, NULL}
- };
- 
-diff --git a/src/makefile b/src/makefile
-index 8d3521e..09d4882 100644
---- a/src/makefile
-+++ b/src/makefile
-@@ -262,6 +262,7 @@ SOCKET_OBJS= \
- 	auxiliar.$(O) \
- 	options.$(O) \
- 	inet.$(O) \
-+	if.$(O) \
- 	$(SOCKET) \
- 	except.$(O) \
- 	select.$(O) \
-@@ -387,6 +388,7 @@ auxiliar.$(O): auxiliar.c auxiliar.h
- buffer.$(O): buffer.c buffer.h io.h timeout.h
- except.$(O): except.c except.h
- inet.$(O): inet.c inet.h socket.h io.h timeout.h usocket.h
-+if.$(O): if.c if.h
- io.$(O): io.c io.h timeout.h
- luasocket.$(O): luasocket.c luasocket.h auxiliar.h except.h \
- 	timeout.h buffer.h io.h inet.h socket.h usocket.h tcp.h \
-diff --git a/src/options.c b/src/options.c
-index 8ac2a14..1c73e6f 100644
---- a/src/options.c
-+++ b/src/options.c
-@@ -3,6 +3,9 @@
- * LuaSocket toolkit
- \*=========================================================================*/
- #include <string.h> 
-+#include <sys/types.h>
-+#include <sys/socket.h>
-+#include <net/if.h>
- 
- #include "lauxlib.h"
- 
-@@ -285,6 +288,12 @@ static int opt_ip6_setmembership(lua_State *L, p_socket ps, int level, int name)
-     if (!lua_isnil(L, -1)) {
-         if (lua_isnumber(L, -1)) {
-             val.ipv6mr_interface = (unsigned int) lua_tonumber(L, -1);
-+        } else if (lua_isstring(L, -1)) {
-+            if (!(val.ipv6mr_interface = if_nametoindex(lua_tostring(L, -1)))) {
-+                lua_pushnil(L);
-+                lua_pushstring(L, "nonexistent interface");
-+                return 2;
-+            }
-         } else
-           luaL_argerror(L, -1, "number 'interface' field expected");
-     }
--- 
-1.8.4.rc3
-
-

--- a/lang/perl-compress-bzip2/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-compress-bzip2
-PKG_VERSION:=2.09
-PKG_RELEASE:=3
-PKG_MD5SUM:=1699fde3e86f2a036f135ae606d456bf
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/A/AR/ARJAY
-PKG_SOURCE:=Compress-Bzip2-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/Compress-Bzip2-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-compress-bzip2
-  SUBMENU:=Perl
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=Perl interface to bzip2 compression library
-  URL:=http://search.cpan.org/dist/Compress-Bzip2/
-  DEPENDS:=perl +libbz2
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,BUILD_BZLIB=0)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-compress-bzip2/install
-	$(call perlmod/Install,$(1),Compress auto/Compress)
-endef
-
-
-$(eval $(call BuildPackage,perl-compress-bzip2))
-

file:a/lang/perl-dbi/Makefile (deleted)
--- a/lang/perl-dbi/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-dbi
-PKG_VERSION:=1.604
-PKG_RELEASE:=1
-PKG_MD5SUM:=358511d60eb3daba913d49236c469802
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/T/TI/TIMB/
-PKG_SOURCE:=DBI-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/DBI-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-dbi
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Database independent interface for Perl
-URL:=http://search.cpan.org/dist/DBI/
-DEPENDS:=perl +perlbase-essential
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-dbi/install
-	$(call perlmod/Install,$(1),DB* auto/DBI,DBI/W32ODBC.pm auto/DBI/*.h)
-endef
-
-
-$(eval $(call BuildPackage,perl-dbi))
-

--- a/lang/perl-html-parser/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-html-parser
-PKG_VERSION:=3.56
-PKG_RELEASE:=1
-PKG_MD5SUM:=bddc432e5ed9df4d4153a62234f04fc2
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/G/GA/GAAS
-PKG_SOURCE:=HTML-Parser-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/HTML-Parser-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-html-parser
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=A collection of modules that parse HTML text documents
-URL:=http://search.cpan.org/dist/HTML-Parser/
-DEPENDS:=perl +perl-html-tagset +perl-uri
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-html-parser/install
-	$(call perlmod/Install,$(1),HTML auto/HTML)
-endef
-
-
-$(eval $(call BuildPackage,perl-html-parser))
-

--- a/lang/perl-html-tagset/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-html-tagset
-PKG_VERSION:=3.20
-PKG_RELEASE:=1
-PKG_MD5SUM:=d2bfa18fe1904df7f683e96611e87437
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/P/PE/PETDANCE
-PKG_SOURCE:=HTML-Tagset-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/HTML-Tagset-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-html-tagset
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Data tables pertaining to HTML
-URL:=http://search.cpan.org/dist/HTML-Tagset/
-DEPENDS:=perl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-html-tagset/install
-	$(call perlmod/Install,$(1),HTML)
-endef
-
-
-$(eval $(call BuildPackage,perl-html-tagset))
-

--- a/lang/perl-html-tree/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-html-tree
-PKG_VERSION:=3.23
-PKG_RELEASE:=2
-PKG_MD5SUM:=6352f50be402301f79b580dd235d7762
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/P/PE/PETEK
-PKG_SOURCE:=HTML-Tree-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/HTML-Tree-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-html-tree
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=represent and create HTML syntax trees
-URL:=http://search.cpan.org/dist/HTML-Tree/
-DEPENDS:=perl +perl-html-parser +perl-html-tagset
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-html-tree/install
-	$(call perlmod/Install,$(1),HTML)
-endef
-
-
-$(eval $(call BuildPackage,perl-html-tree))
-

--- a/lang/perl-lockfile-simple/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-lockfile-simple
-PKG_VERSION:=0.206
-PKG_RELEASE:=1
-PKG_MD5SUM:=d8966c3fb799aefcaaf80f845057a1fa
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/J/JV/JV
-PKG_SOURCE:=LockFile-Simple-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/LockFile-Simple-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-lockfile-simple
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Simple advisory file locking
-URL:=http://search.cpan.org/dist/LockFile-Simple/
-DEPENDS:=perl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-lockfile-simple/install
-	$(call perlmod/Install,$(1),LockFile auto/LockFile)
-endef
-
-
-$(eval $(call BuildPackage,perl-lockfile-simple))
-

--- a/lang/perl-net-telnet/Makefile
+++ /dev/null
@@ -1,45 +1,1 @@
-#
-# 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:=perl-net-telnet
-PKG_VERSION:=3.03
-PKG_RELEASE:=1
-PKG_MD5SUM:=2f7d34b09d6117baefe89d44cff9d5fc
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/J/JR/JROGERS
-PKG_SOURCE:=Net-Telnet-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/Net-Telnet-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-net-telnet
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Telnet client
-URL:=http://search.cpan.org/~jrogers/Net-Telnet-3.03/
-DEPENDS:=perl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-net-telnet/install
-	$(call perlmod/Install,$(1),Net auto/Net)
-endef
-
-$(eval $(call BuildPackage,perl-net-telnet))
-

--- a/lang/perl-test-harness/Makefile
+++ /dev/null
@@ -1,43 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-test-harness
-PKG_VERSION:=3.25
-PKG_RELEASE:=1
-PKG_MD5SUM:=69a8a019eeb952fe97e3ac0767c726da
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/O/OV/OVID
-PKG_SOURCE:=Test-Harness-$(PKG_VERSION).tar.gz
-
-PKG_LICENSE:=GPLv2 ARTISTIC
-PKG_LICENSE_FILES:=
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/Test-Harness-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-test-harness
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Perl Test Harness
-URL:=http://search.cpan.org/~ovid/Test-Harness-3.25/bin/prove
-DEPENDS:=+perl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-test-harness/install
-	$(call perlmod/Install,$(1),App auto/Test TAP Test)
-endef
-
-
-$(eval $(call BuildPackage,perl-test-harness))
-

file:a/lang/perl-uri/Makefile (deleted)
--- a/lang/perl-uri/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-uri
-PKG_VERSION:=1.36
-PKG_RELEASE:=1
-PKG_MD5SUM:=a97bbdd38b31c6b2672fdc3060fae34b
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/G/GA/GAAS
-PKG_SOURCE:=URI-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/URI-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-uri
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Manipulates and accesses URI strings
-URL:=http://search.cpan.org/dist/URI/
-DEPENDS:=perl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-uri/install
-	$(call perlmod/Install,$(1),URI URI.pm)
-endef
-
-
-$(eval $(call BuildPackage,perl-uri))
-

--- a/lang/perl-www-curl/Makefile
+++ /dev/null
@@ -1,40 +1,1 @@
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=perl-www-curl
-PKG_VERSION:=4.00
-PKG_RELEASE:=1
-PKG_MD5SUM:=f34eb29f59a811869a4f77bfc0df2f5d
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/S/SZ/SZBALINT
-PKG_SOURCE:=WWW-Curl-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/WWW-Curl-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-www-curl
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=Perl bindings to libcurl
-URL:=http://search.cpan.org/dist/WWW-Curl/
-DEPENDS:=perl +libcurl
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,$(STAGING_DIR)/usr/include,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-www-curl/install
-	$(call perlmod/Install,$(1),WWW/Curl WWW/Curl.pm auto/WWW/Curl)
-endef
-
-
-$(eval $(call BuildPackage,perl-www-curl))
-

--- a/lang/perl-www-curl/patches/100-perl-www-curl_disable_curl-config_hack.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- WWW-Curl-4.00.config/Makefile.PL	2008-04-21 23:18:39.000000000 +0200
-+++ WWW-Curl-4.00/Makefile.PL	2008-04-21 23:18:52.000000000 +0200
-@@ -11,7 +11,7 @@
- no_index		directory => 'template';
- # This is a hack. If you have libcurl installed, just specify curl.h below
- # and comment out this line.
--requires_external_bin	'curl-config';
-+#requires_external_bin	'curl-config';
- 
- # This utility helper generates the constants function from curl.h
- # It is normally only used by the maintainer, but if you're curl is older
 

--- a/lang/perl-www-mechanize/Makefile
+++ /dev/null
@@ -1,45 +1,1 @@
-#
-# Copyright (C) 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:=perl-www-mechanize
-PKG_VERSION:=1.58
-PKG_RELEASE:=1
-
-PKG_SOURCE:=WWW-Mechanize-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/P/PE/PETDANCE/
-PKG_MD5SUM:=c928d1bf3218bfe0c0d99096cf34db52
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/WWW-Mechanize-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-www-mechanize
-  SUBMENU:=Perl
-  SECTION:=lang
-  CATEGORY:=Languages
-  TITLE:=Perl WWW Mechanize
-  URL:=http://search.cpan.org/dist/WWW-Mechanize/
-  DEPENDS:=perl +perl-www
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,$(STAGING_DIR)/usr/include,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-www-mechanize/install
-	$(call perlmod/Install,$(1),WWW/Mechanize WWW/Mechanize.pm)
-endef
-
-$(eval $(call BuildPackage,perl-www-mechanize))
-

file:a/lang/perl-www/Makefile (deleted)
--- a/lang/perl-www/Makefile
+++ /dev/null
@@ -1,46 +1,1 @@
-#
-# 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:=perl-www
-PKG_VERSION:=5.837
-PKG_RELEASE:=1
-PKG_MD5SUM:=9bbf1bce482b0bac98bb4f04253c03d0
-
-PKG_SOURCE_URL:=http://search.cpan.org/CPAN/authors/id/G/GA/GAAS
-PKG_SOURCE:=libwww-perl-$(PKG_VERSION).tar.gz
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/perl/libwww-perl-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-include ../perl/perlmod.mk
-
-define Package/perl-www
-SUBMENU:=Perl
-SECTION:=lang
-CATEGORY:=Languages
-TITLE:=WWW client/server library for Perl (aka LWP)
-URL:=http://search.cpan.org/dist/libwww-perl/
-DEPENDS:=perl +perl-html-parser +perl-html-tagset +perl-uri
-endef
-
-define Build/Configure
-	$(call perlmod/Configure,-n,)
-endef
-
-define Build/Compile
-	$(call perlmod/Compile,,)
-endef
-
-define Package/perl-www/install
-	$(call perlmod/Install,$(1),File HTML HTTP LWP LWP.pm Net WWW)
-endef
-
-
-$(eval $(call BuildPackage,perl-www))
-

--- a/libs/argp-standalone/Makefile
+++ /dev/null
@@ -1,38 +1,1 @@
-include $(TOPDIR)/rules.mk
 
-PKG_NAME:=argp-standalone
-PKG_VERSION:=1.3
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://www.lysator.liu.se/~nisse/misc/
-PKG_MD5SUM:=720704bac078d067111b32444e24ba69
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/argp-standalone
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=Hierarchial argument parsing broken out from glibc
-  URL:=http://www.lysator.liu.se/~nisse/misc/
-endef
-
-define Package/argp-standalone/description
-  GNU libc hierarchial argument parsing library broken out from glibc.
-endef
-
-MAKE_FLAGS += \
-	CFLAGS="$(TARGET_CFLAGS) $(FPIC)"
-
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP)   $(PKG_BUILD_DIR)/argp.h \
-		$(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP)   $(PKG_BUILD_DIR)/libargp.a \
-		$(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,argp-standalone))
-

--- a/libs/argp-standalone/patches/001-throw-in-funcdef.patch
+++ /dev/null
@@ -1,80 +1,1 @@
-# --- T2-COPYRIGHT-NOTE-BEGIN ---
-# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
-# 
-# T2 SDE: package/.../rng-tools/throw-in-funcdef.patch.argp-standalone
-# Copyright (C) 2006 The T2 SDE Project
-# 
-# More information can be found in the files COPYING and README.
-# 
-# This patch file is dual-licensed. It is available under the license the
-# patched project is licensed under, as long as it is an OpenSource license
-# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
-# of the GNU General Public License as published by the Free Software
-# Foundation; either version 2 of the License, or (at your option) any later
-# version.
-# --- T2-COPYRIGHT-NOTE-END ---
 
-
-No __THROW in function implementation.
-	--jsaw
-
---- argp-standalone-1.4-test2/argp.h.orig	2006-01-06 02:29:59.000000000 +0100
-+++ argp-standalone-1.4-test2/argp.h	2006-01-06 02:41:10.000000000 +0100
-@@ -560,17 +560,17 @@
- # endif
- 
- # ifndef ARGP_EI
--#  define ARGP_EI extern __inline__
-+#  define ARGP_EI extern inline
- # endif
- 
- ARGP_EI void
--__argp_usage (__const struct argp_state *__state) __THROW
-+__argp_usage (__const struct argp_state *__state)
- {
-   __argp_state_help (__state, stderr, ARGP_HELP_STD_USAGE);
- }
- 
- ARGP_EI int
--__option_is_short (__const struct argp_option *__opt) __THROW
-+__option_is_short (__const struct argp_option *__opt)
- {
-   if (__opt->flags & OPTION_DOC)
-     return 0;
-@@ -582,7 +582,7 @@
- }
- 
- ARGP_EI int
--__option_is_end (__const struct argp_option *__opt) __THROW
-+__option_is_end (__const struct argp_option *__opt)
- {
-   return !__opt->key && !__opt->name && !__opt->doc && !__opt->group;
- }
---- argp-standalone-1.4-test2/argp-parse.c.orig	2006-01-06 02:47:48.000000000 +0100
-+++ argp-standalone-1.4-test2/argp-parse.c	2006-01-06 02:48:16.000000000 +0100
-@@ -1290,13 +1290,13 @@
- /* Defined here, in case a user is not inlining the definitions in
-  * argp.h */
- void
--__argp_usage (__const struct argp_state *__state) __THROW
-+__argp_usage (__const struct argp_state *__state)
- {
-   __argp_state_help (__state, stderr, ARGP_HELP_STD_USAGE);
- }
- 
- int
--__option_is_short (__const struct argp_option *__opt) __THROW
-+__option_is_short (__const struct argp_option *__opt) 
- {
-   if (__opt->flags & OPTION_DOC)
-     return 0;
-@@ -1310,7 +1310,7 @@
- }
- 
- int
--__option_is_end (__const struct argp_option *__opt) __THROW
-+__option_is_end (__const struct argp_option *__opt) 
- {
-   return !__opt->key && !__opt->name && !__opt->doc && !__opt->group;
- }
-

file:a/libs/file/Makefile (deleted)
--- a/libs/file/Makefile
+++ /dev/null
@@ -1,95 +1,1 @@
-#
-# Copyright (C) 2007-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:=file
-PKG_VERSION:=5.11
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=ftp://ftp.astron.com/pub/file/
-PKG_MD5SUM:=16a407bd66d6c7a832f3a5c0d609c27b
-
-PKG_LICENSE:=BSD-2c
-PKG_LICENSE_FILES:=COPYING
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-PKG_BUILD_PARALLEL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/file/Default
-  TITLE:=File type determination
-  URL:=ftp://ftp.astron.com/pub/file/
-  MAINTAINER:=Luka Perkov <openwrt@lukaperkov.net>
-endef
-
-define Package/file
-$(call package/file/Default)
-  SECTION:=utils
-  CATEGORY:=Utilities
-  TITLE+= utility
-  DEPENDS:=+libmagic
-endef
-
-define Package/libmagic
-$(call package/file/Default)
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE+= library
-  DEPENDS:=+zlib
-endef
-
-CONFIGURE_ARGS += \
-	--enable-shared \
-	--enable-static \
-
-MAKE_PATH := src
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/Compile/magic
-	( cd $(PKG_BUILD_DIR)/magic/Magdir; \
-		for f in `ls`; do \
-			cat $$$${f}; \
-		done \
-	) > $(PKG_BUILD_DIR)/magic/magic
-endef
-Hooks/Compile/Post += Build/Compile/magic
-
-define Build/Install/magic
-	$(INSTALL_DIR) $(PKG_INSTALL_DIR)/usr/share/file
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/magic/magic $(PKG_INSTALL_DIR)/usr/share/file/
-endef
-Hooks/Install/Post += Build/Install/magic
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/magic.h $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libmagic.{a,so*} $(1)/usr/lib/
-endef
-
-define Package/file/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/file $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/usr/share/misc
-	$(SED) "/^#/d" $(PKG_INSTALL_DIR)/usr/share/file/magic
-	$(SED) "/^$$$$/d" $(PKG_INSTALL_DIR)/usr/share/file/magic
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/file/magic $(1)/usr/share/misc/
-endef
-
-define Package/libmagic/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libmagic.so.* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,file))
-$(eval $(call BuildPackage,libmagic))
-

--- a/libs/giflib/Makefile
+++ b/libs/giflib/Makefile
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006 OpenWrt.org
+# Copyright (C) 2006-2014 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=giflib
-PKG_VERSION:=4.1.6
+PKG_VERSION:=5.1.0
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=@SF/giflib
-PKG_MD5SUM:=7125644155ae6ad33dbc9fc15a14735f
+PKG_MD5SUM:=c7e9f1c10b755ab955156d4c1ac7fc5d
 
 PKG_LICENSE:=MIT
 PKG_LICENSE_FILES:=COPYING

file:a/libs/gsm/Makefile (deleted)
--- a/libs/gsm/Makefile
+++ /dev/null
@@ -1,97 +1,1 @@
-#
-# Copyright (C) 2006-2009 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:=gsm
-PKG_VERSION:=1.0.13
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://user.cs.tu-berlin.de/~jutta/gsm/
-PKG_MD5SUM:=c1ba392ce61dc4aff1c29ea4e92f6df4
-
-PKG_LICENSE:=FREE
-PKG_LICENSE_FILES:=COPYRIGHT
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-1.0-pl13
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/gsm/Default
-  TITLE:=GSM transcoding
-  URL:=http://user.cs.tu-berlin.de/~jutta/toast.html
-endef
-
-define Package/gsm/description/Default
- An implementation of the European GSM 06.10 provisional standard
- for full-rate speech transcoding, prI-ETS 300 036, which uses
- RPE/LTP (residual pulse excitation/long term prediction) coding
- at 13 kbit/s.
-endef
-
-define Package/libgsm
-$(call Package/gsm/Default)
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE+= library
-endef
-
-define Package/libgsm/description
-$(call Package/gsm/description/Default)
- This package contains a shared GSM transcoding library, used by other
- programs.
-endef
-
-define Package/gsm-utils
-$(call Package/gsm/Default)
-  SECTION:=utils
-  CATEGORY:=Utilities
-  DEPENDS:=+libgsm
-  TITLE+= utilities
-endef
-
-define Package/gsm-utils/description
-$(call Package/gsm/description/Default)
- This package contains GSM transcoding utilities.
-endef
-
-define Build/Configure
-endef
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		$(TARGET_CONFIGURE_OPTS) \
-		LD="$(TARGET_CC)" \
-		COPTS="$(TARGET_CFLAGS)" \
-		INSTALL_ROOT="$(PKG_INSTALL_DIR)" \
-		all install
-endef
-
-define Package/libgsm/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgsm.so.* $(1)/usr/lib/
-endef
-
-define Package/gsm-utils/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/toast $(1)/usr/bin/
-	(cd $(1)/usr/bin; ln -sf toast untoast; ln -sf toast tcat)
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include/gsm
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/gsm.h $(1)/usr/include/gsm/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgsm.{a,so*} $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libgsm))
-$(eval $(call BuildPackage,gsm-utils))
-

--- a/libs/gsm/patches/001-debian-libsgm-1.0.10-13.patch
+++ /dev/null
@@ -1,429 +1,1 @@
---- a/Makefile
-+++ b/Makefile
-@@ -8,10 +8,12 @@ SASR	= -DSASR
- ######### Define SASR if >> is a signed arithmetic shift (-1 >> 1 == -1)
- 
- # MULHACK = -DUSE_FLOAT_MUL
-+MULHACK =
- ######### Define this if your host multiplies floats faster than integers,
- ######### e.g. on a SPARCstation.
- 
- # FAST	= -DFAST
-+FAST	=
- ######### Define together with USE_FLOAT_MUL to enable the GSM library's
- ######### approximation option for incorrect, but good-enough results.
- 
-@@ -22,8 +24,8 @@ LTP_CUT	=
- ######### both integer and floating point multiplications.
- ######### This flag is still in the experimental stage.
- 
--WAV49	= -DWAV49
--# WAV49	=
-+# WAV49	= -DWAV49
-+WAV49	=
- ######### Define to enable the GSM library's option to pack GSM frames 
- ######### in the style used by the WAV #49 format.  If you want to write
- ######### a tool that produces .WAV files which contain GSM-encoded data,
-@@ -44,7 +46,8 @@ WAV49	= -DWAV49
- # CCFLAGS 	= -c -O
- 
- CC		= gcc -ansi -pedantic
--CCFLAGS 	= -c -O2 -DNeedFunctionPrototypes=1
-+COPTS		= -O2
-+CCFLAGS 	= -c $(COPTS) -DNeedFunctionPrototypes=1
- 
- LD 		= $(CC)
- 
-@@ -78,10 +81,10 @@ INSTALL_ROOT	=
- # Leave GSM_INSTALL_ROOT empty to not install the GSM library outside of
- # this directory.
- 
--GSM_INSTALL_ROOT = $(INSTALL_ROOT)
-+GSM_INSTALL_ROOT = $(INSTALL_ROOT)/usr
- GSM_INSTALL_LIB = $(GSM_INSTALL_ROOT)/lib
--GSM_INSTALL_INC = $(GSM_INSTALL_ROOT)/inc
--GSM_INSTALL_MAN = $(GSM_INSTALL_ROOT)/man/man3
-+GSM_INSTALL_INC = $(GSM_INSTALL_ROOT)/include
-+GSM_INSTALL_MAN = $(GSM_INSTALL_ROOT)/share/man/man3
- 
- 
- # Where do you want to install the toast binaries and their manpage?
-@@ -89,14 +92,14 @@ GSM_INSTALL_MAN = $(GSM_INSTALL_ROOT)/ma
- # Leave TOAST_INSTALL_ROOT empty to not install the toast binaries outside
- # of this directory.
- 
--TOAST_INSTALL_ROOT	  = $(INSTALL_ROOT)
-+TOAST_INSTALL_ROOT	  = $(INSTALL_ROOT)/usr
- TOAST_INSTALL_BIN = $(TOAST_INSTALL_ROOT)/bin
--TOAST_INSTALL_MAN = $(TOAST_INSTALL_ROOT)/man/man1
-+TOAST_INSTALL_MAN = $(TOAST_INSTALL_ROOT)/share/man/man1
- 
- #  Other tools
- 
- SHELL		= /bin/sh
--LN		= ln
-+LN		= ln -s
- BASENAME 	= basename
- AR		= ar
- ARFLAGS		= cr
-@@ -126,7 +129,7 @@ INC	= $(ROOT)/inc
- 
- # Flags
- 
--# DEBUG	= -DNDEBUG
-+DEBUG	= -DNDEBUG
- ######### Remove -DNDEBUG to enable assertions.
- 
- CFLAGS	= $(CCFLAGS) $(SASR) $(DEBUG) $(MULHACK) $(FAST) $(LTP_CUT) \
-@@ -140,6 +143,7 @@ LFLAGS	= $(LDFLAGS) $(LDINC)
- # Targets
- 
- LIBGSM	= $(LIB)/libgsm.a
-+LIBGSMSO= $(LIB)/libgsm.so
- 
- TOAST	= $(BIN)/toast
- UNTOAST	= $(BIN)/untoast
-@@ -258,6 +262,9 @@ STUFF = 	ChangeLog			\
- 
- GSM_INSTALL_TARGETS =	\
- 		$(GSM_INSTALL_LIB)/libgsm.a		\
-+		$(GSM_INSTALL_LIB)/libgsm.so		\
-+		$(GSM_INSTALL_LIB)/libgsm.so.1		\
-+		$(GSM_INSTALL_LIB)/libgsm.so.1.0.10	\
- 		$(GSM_INSTALL_INC)/gsm.h		\
- 		$(GSM_INSTALL_MAN)/gsm.3		\
- 		$(GSM_INSTALL_MAN)/gsm_explode.3	\
-@@ -279,7 +286,7 @@ TOAST_INSTALL_TARGETS =	\
- 
- # Target rules
- 
--all:		$(LIBGSM) $(TOAST) $(TCAT) $(UNTOAST)
-+all:		$(LIBGSM) $(LIBGSMSO) $(TOAST) $(TCAT) $(UNTOAST)
- 		@-echo $(ROOT): Done.
- 
- tst:		$(TST)/lin2cod $(TST)/cod2lin $(TOAST) $(TST)/test-result
-@@ -299,6 +306,11 @@ install:	toastinstall gsminstall
- 
- # The basic API: libgsm
- 
-+$(LIBGSMSO):	$(LIB) $(GSM_OBJECTS)
-+		$(LD) -o $@.1.0.10 -shared -Xlinker -soname -Xlinker libgsm.so.1 $(GSM_OBJECTS) -lc
-+		ln -fs libgsm.so.1.0.10 lib/libgsm.so.1
-+		ln -fs libgsm.so.1.0.10 lib/libgsm.so
-+
- $(LIBGSM):	$(LIB) $(GSM_OBJECTS)
- 		-rm $(RMFLAGS) $(LIBGSM)
- 		$(AR) $(ARFLAGS) $(LIBGSM) $(GSM_OBJECTS)
-@@ -308,15 +320,15 @@ $(LIBGSM):	$(LIB) $(GSM_OBJECTS)
- # Toast, Untoast and Tcat -- the compress-like frontends to gsm.
- 
- $(TOAST):	$(BIN) $(TOAST_OBJECTS) $(LIBGSM)
--		$(LD) $(LFLAGS) -o $(TOAST) $(TOAST_OBJECTS) $(LIBGSM) $(LDLIB)
-+		$(LD) $(LFLAGS) -o $(TOAST) $(TOAST_OBJECTS) $(LIBGSMSO) $(LDLIB)
- 
- $(UNTOAST):	$(BIN) $(TOAST)
- 		-rm $(RMFLAGS) $(UNTOAST)
--		$(LN) $(TOAST) $(UNTOAST)
-+		$(LN) toast $(UNTOAST)
- 
- $(TCAT):	$(BIN) $(TOAST)
- 		-rm $(RMFLAGS) $(TCAT)
--		$(LN) $(TOAST) $(TCAT)
-+		$(LN) toast $(TCAT)
- 
- 
- # The local bin and lib directories
-@@ -351,53 +363,66 @@ toastuninstall:
- 		fi
- 
- $(TOAST_INSTALL_BIN)/toast:	$(TOAST)
--		-rm $@
--		cp $(TOAST) $@
-+		mkdir -p $(TOAST_INSTALL_BIN)
-+		cp -f $(TOAST) $@
- 		chmod 755 $@
- 
- $(TOAST_INSTALL_BIN)/untoast:	$(TOAST_INSTALL_BIN)/toast
--		-rm $@
--		ln $? $@
-+		mkdir -p $(TOAST_INSTALL_BIN)
-+		ln -sf $? $@
- 
- $(TOAST_INSTALL_BIN)/tcat:	$(TOAST_INSTALL_BIN)/toast
--		-rm $@
--		ln $? $@
-+		mkdir -p $(TOAST_INSTALL_BIN)
-+		ln -sf $? $@
- 
- $(TOAST_INSTALL_MAN)/toast.1:	$(MAN)/toast.1
--		-rm $@
--		cp $? $@
-+		mkdir -p $(TOAST_INSTALL_MAN)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_MAN)/gsm.3:	$(MAN)/gsm.3
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_MAN)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_MAN)/gsm_option.3:	$(MAN)/gsm_option.3
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_MAN)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_MAN)/gsm_explode.3:	$(MAN)/gsm_explode.3
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_MAN)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_MAN)/gsm_print.3:	$(MAN)/gsm_print.3
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_MAN)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_INC)/gsm.h:	$(INC)/gsm.h
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_INC)
-+		cp -f $? $@
- 		chmod 444 $@
- 
- $(GSM_INSTALL_LIB)/libgsm.a:	$(LIBGSM)
--		-rm $@
--		cp $? $@
-+		mkdir -p $(GSM_INSTALL_LIB)
-+		cp -f $? $@
- 		chmod 444 $@
- 
-+$(GSM_INSTALL_LIB)/libgsm.so:	$(LIBGSMSO)
-+		mkdir -p $(GSM_INSTALL_LIB)
-+		cp -f $? $@
-+
-+$(GSM_INSTALL_LIB)/libgsm.so.1:	$(LIBGSMSO)
-+		mkdir -p $(GSM_INSTALL_LIB)
-+		cp -f $? $@
-+
-+$(GSM_INSTALL_LIB)/libgsm.so.1.0.10:	$(LIBGSMSO)
-+		mkdir -p $(GSM_INSTALL_LIB)
-+		cp -f $? $@
-+		chmod 755 $@
-+
- 
- # Distribution
- 
-@@ -426,7 +451,9 @@ semi-clean:
- 
- clean:	semi-clean
- 		-rm $(RMFLAGS) $(LIBGSM) $(ADDTST)/add		\
--			$(TOAST) $(TCAT) $(UNTOAST)	\
-+			$(LIBGSMSO) $(LIB)/libgsm.so.1.0.10	\
-+			$(LIB)libgsm.so.1			\
-+			$(TOAST) $(TCAT) $(UNTOAST)		\
- 			$(ROOT)/gsm-1.0.tar.Z
- 
- 
---- a/inc/config.h
-+++ b/inc/config.h
-@@ -9,8 +9,8 @@
- #ifndef	CONFIG_H
- #define	CONFIG_H
- 
--/*efine	SIGHANDLER_T	int 		/* signal handlers are void	*/
--/*efine HAS_SYSV_SIGNAL	1		/* sigs not blocked/reset?	*/
-+/*efine	SIGHANDLER_T	int 		*//* signal handlers are void	*/
-+/*efine HAS_SYSV_SIGNAL	1		*//* sigs not blocked/reset?	*/
- 
- #define	HAS_STDLIB_H	1		/* /usr/include/stdlib.h	*/
- #define	HAS_LIMITS_H	1		/* /usr/include/limits.h	*/
-@@ -22,16 +22,16 @@
- #define	HAS_CHMOD 	1		/* chmod syscall		*/
- #define	HAS_FCHOWN 	1		/* fchown syscall		*/
- #define	HAS_CHOWN 	1		/* chown syscall		*/
--/*efine	HAS__FSETMODE 	1		/* _fsetmode -- set file mode	*/
-+/*efine	HAS__FSETMODE 	1		*//* _fsetmode -- set file mode	*/
- 
- #define	HAS_STRING_H 	1		/* /usr/include/string.h 	*/
--/*efine	HAS_STRINGS_H	1		/* /usr/include/strings.h 	*/
-+/*efine	HAS_STRINGS_H	1		*//* /usr/include/strings.h 	*/
- 
- #define	HAS_UNISTD_H	1		/* /usr/include/unistd.h	*/
- #define	HAS_UTIME	1		/* POSIX utime(path, times)	*/
--/*efine	HAS_UTIMES	1		/* use utimes()	syscall instead	*/
-+/*efine	HAS_UTIMES	1		*//* use utimes()	syscall instead	*/
- #define	HAS_UTIME_H	1		/* UTIME header file		*/
- #define	HAS_UTIMBUF	1		/* struct utimbuf		*/
--/*efine	HAS_UTIMEUSEC   1		/* microseconds in utimbuf?	*/
-+/*efine	HAS_UTIMEUSEC   1		*//* microseconds in utimbuf?	*/
- 
- #endif	/* CONFIG_H */
---- a/inc/gsm.h
-+++ b/inc/gsm.h
-@@ -54,6 +54,10 @@ typedef gsm_byte 		gsm_frame[33];		/* 33
- #define	GSM_OPT_FRAME_INDEX	5
- #define	GSM_OPT_FRAME_CHAIN	6
- 
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
-+
- extern gsm  gsm_create 	GSM_P((void));
- extern void gsm_destroy GSM_P((gsm));	
- 
-@@ -66,6 +70,10 @@ extern int  gsm_decode  GSM_P((gsm, gsm_
- extern int  gsm_explode GSM_P((gsm, gsm_byte   *, gsm_signal *));
- extern void gsm_implode GSM_P((gsm, gsm_signal *, gsm_byte   *));
- 
-+#ifdef __cplusplus
-+}
-+#endif
-+
- #undef	GSM_P
- 
- #endif	/* GSM_H */
---- a/inc/toast.h
-+++ b/inc/toast.h
-@@ -16,11 +16,12 @@
- 
- #include <stdio.h>
- #include <ctype.h>
-+#include <pthread.h>
- #include <signal.h>
- 
- #include <errno.h>
--#ifndef	HAS_ERRNO_DECL
--	 extern int	errno;
-+#ifndef errno
-+ extern int	errno;
- #endif
- 
- #ifdef	HAS_LIMITS_H
-@@ -37,6 +38,10 @@
- # endif
- #endif
- 
-+#ifdef  HAS_STDIO_H
-+# include <stdio.h>
-+#endif
-+
- #include "gsm.h"
- 
- #ifndef	S_ISREG
---- a/src/code.c
-+++ b/src/code.c
-@@ -9,8 +9,8 @@
- #include	"config.h"
- 
- 
--#ifdef	HAS_STDLIB_H
--#include	<stdlib.h>
-+#ifdef	HAS_STRING_H
-+#include	<string.h>
- #else
- #	include "proto.h"
- 	extern char	* memcpy P((char *, char *, int));
---- a/src/debug.c
-+++ b/src/debug.c
-@@ -49,7 +49,7 @@ void gsm_debug_longwords P4( (name, from
- 	fprintf( stderr, "%s [%d .. %d]: ", name, from, to );
- 	while (from <= to) {
- 
--		fprintf(stderr, "%d ", ptr[ from ] );
-+		fprintf(stderr, "%ld ", ptr[ from ] );
- 		from++;
- 		if (nprinted++ >= 7) {
- 			nprinted = 0;
-@@ -63,14 +63,14 @@ void gsm_debug_longword P2(  (name, valu
- 	char		* name,
- 	longword	  value	)
- {
--	fprintf(stderr, "%s: %d\n", name, (long)value );
-+	fprintf(stderr, "%s: %ld\n", name, (long)value );
- }
- 
- void gsm_debug_word P2(  (name, value),
- 	char	* name,
- 	word	  value	)
- {
--	fprintf(stderr, "%s: %d\n", name, (long)value);
-+	fprintf(stderr, "%s: %ld\n", name, (long)value);
- }
- 
- #endif
---- a/src/toast.c
-+++ b/src/toast.c
-@@ -251,8 +251,8 @@ static char * emalloc P1((len), size_t l
- {
- 	char * s;
- 	if (!(s = malloc(len))) {
--		fprintf(stderr, "%s: failed to malloc %d bytes -- abort\n",
--			progname, len);
-+		fprintf(stderr, "%s: failed to malloc %ld bytes -- abort\n",
-+			progname, (long) len);
- 		onintr();
- 		exit(1);
- 	}
-@@ -270,7 +270,7 @@ static char* normalname P3((name, want, 
- 	maxlen = strlen(name) + 1 + strlen(want) + strlen(cut);
- 	p = strcpy(emalloc(maxlen), name);
- 
--	if (s = suffix(p, cut)) strcpy(s, want);
-+	if ((s = suffix(p, cut))) strcpy(s, want);
- 	else if (*want && !suffix(p, want)) strcat(p, want);
- 
- 	return p;
-@@ -386,7 +386,7 @@ static void update_times P0()
- 		ut[0] = instat.st_atime;
- 		ut[1] = instat.st_mtime;
- 
--		(void) utime(outname, ut);
-+		(void) utime(outname, (struct utimbuf *)ut);
- 
- #endif	/* UTIMBUF */
- 	}
-@@ -416,7 +416,7 @@ static int okay_as_input P3((name,f,st),
- 	}
- 	if (st->st_nlink > 1 && !f_cat && !f_precious) {
- 		fprintf(stderr, 
--		      "%s: \"%s\" has %s other link%s -- unchanged.\n",
-+		      "%s: \"%s\" has %d other link%s -- unchanged.\n",
- 			progname,name,st->st_nlink - 1,"s" + (st->st_nlink<=2));
- 		return 0;
- 	}
-@@ -585,8 +585,8 @@ static int process_decode P0()
- 
- 		if (cc != sizeof(s)) {
- 			if (cc >= 0) fprintf(stderr,
--			"%s: incomplete frame (%d byte%s missing) from %s\n",
--					progname, sizeof(s) - cc,
-+			"%s: incomplete frame (%ld byte%s missing) from %s\n",
-+					progname, (long) sizeof(s) - cc,
- 					"s" + (sizeof(s) - cc == 1),
- 					inname ? inname : "stdin" );
- 			gsm_destroy(r);
-@@ -624,8 +624,6 @@ static int process_decode P0()
- 
- static int process P1((name), char * name)
- {
--	int step = 0;
--
- 	out     = (FILE *)0;
- 	in      = (FILE *)0;
- 
-@@ -779,7 +777,6 @@ int main P2((ac, av), int ac, char **av)
- 	case 'h': help();    exit(0);
- 
- 	default: 
--	usage:
- 		fprintf(stderr,
- 	"Usage: %s [-fcpdhvuaslFC] [files...] (-h for help)\n",
- 			progname);
 

file:a/libs/iksemel/Makefile (deleted)
--- a/libs/iksemel/Makefile
+++ /dev/null
@@ -1,69 +1,1 @@
-#
-# Copyright (C) 2006-2009 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:=iksemel
-PKG_VERSION:=1.4
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://iksemel.googlecode.com/files/
-PKG_MD5SUM:=532e77181694f87ad5eb59435d11c1ca
-
-PKG_FIXUP:=autoreconf
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libiksemel
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=Iksemel Jabber Library
-  URL:=http://code.google.com/p/iksemel/
-  DEPENDS:= +libgnutls +libtasn1 +libgcrypt +libgpg-error
-endef
-
-define Package/libiksemel/description
-  Iksemel is an XML parser library mainly designed for Jabber applications.
-  It provides SAX, DOM, and special Jabber stream APIs. Library is coded
-  in ANSI C except the network code (which is POSIX compatible), thus
-  highly portable.
-endef
-
-TARGET_CFLAGS += $(FPIC)
-TARGET_LDFLAGS += \
-	-Wl,-rpath-link,$(STAGING_DIR)/usr/lib \
-	-lgnutls -lgcrypt -lgpg-error
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-		--enable-shared \
-		--enable-static \
-		--with-libgnutls-prefix="$(STAGING_DIR)/usr" \
-		, \
-		LIBS="$(TARGET_LDFLAGS)" \
-	)
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include/
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/iksemel.h $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libiksemel.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/iksemel.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libiksemel/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libiksemel.so.* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libiksemel))
-

--- a/libs/iksemel/patches/001-missing-macros.patch
+++ /dev/null
@@ -1,164 +1,1 @@
---- /dev/null
-+++ b/gnutls.m4
-@@ -0,0 +1,160 @@
-+dnl Autoconf macros for libgnutls
-+dnl $id$
-+
-+# Modified for LIBGNUTLS -- nmav
-+# Configure paths for LIBGCRYPT
-+# Shamelessly stolen from the one of XDELTA by Owen Taylor
-+# Werner Koch   99-12-09
-+
-+dnl AM_PATH_LIBGNUTLS([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
-+dnl Test for libgnutls, and define LIBGNUTLS_CFLAGS and LIBGNUTLS_LIBS
-+dnl
-+AC_DEFUN([AM_PATH_LIBGNUTLS],
-+[dnl
-+dnl Get the cflags and libraries from the libgnutls-config script
-+dnl
-+AC_ARG_WITH(libgnutls-prefix,
-+          [  --with-libgnutls-prefix=PFX   Prefix where libgnutls is installed (optional)],
-+          libgnutls_config_prefix="$withval", libgnutls_config_prefix="")
-+
-+  if test x$libgnutls_config_prefix != x ; then
-+     if test x${LIBGNUTLS_CONFIG+set} != xset ; then
-+        LIBGNUTLS_CONFIG=$libgnutls_config_prefix/bin/libgnutls-config
-+     fi
-+  fi
-+
-+  AC_PATH_PROG(LIBGNUTLS_CONFIG, libgnutls-config, no)
-+  min_libgnutls_version=ifelse([$1], ,0.1.0,$1)
-+  AC_MSG_CHECKING(for libgnutls - version >= $min_libgnutls_version)
-+  no_libgnutls=""
-+  if test "$LIBGNUTLS_CONFIG" = "no" ; then
-+    no_libgnutls=yes
-+  else
-+    LIBGNUTLS_CFLAGS=`$LIBGNUTLS_CONFIG $libgnutls_config_args --cflags`
-+    LIBGNUTLS_LIBS=`$LIBGNUTLS_CONFIG $libgnutls_config_args --libs`
-+    libgnutls_config_version=`$LIBGNUTLS_CONFIG $libgnutls_config_args --version`
-+
-+
-+      ac_save_CFLAGS="$CFLAGS"
-+      ac_save_LIBS="$LIBS"
-+      CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
-+      LIBS="$LIBS $LIBGNUTLS_LIBS"
-+dnl
-+dnl Now check if the installed libgnutls is sufficiently new. Also sanity
-+dnl checks the results of libgnutls-config to some extent
-+dnl
-+      rm -f conf.libgnutlstest
-+      AC_TRY_RUN([
-+#include <stdio.h>
-+#include <stdlib.h>
-+#include <string.h>
-+#include <gnutls/gnutls.h>
-+
-+int
-+main ()
-+{
-+    system ("touch conf.libgnutlstest");
-+
-+    if( strcmp( gnutls_check_version(NULL), "$libgnutls_config_version" ) )
-+    {
-+      printf("\n*** 'libgnutls-config --version' returned %s, but LIBGNUTLS (%s)\n",
-+             "$libgnutls_config_version", gnutls_check_version(NULL) );
-+      printf("*** was found! If libgnutls-config was correct, then it is best\n");
-+      printf("*** to remove the old version of LIBGNUTLS. You may also be able to fix the error\n");
-+      printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
-+      printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
-+      printf("*** required on your system.\n");
-+      printf("*** If libgnutls-config was wrong, set the environment variable LIBGNUTLS_CONFIG\n");
-+      printf("*** to point to the correct copy of libgnutls-config, and remove the file config.cache\n");
-+      printf("*** before re-running configure\n");
-+    }
-+    else if ( strcmp(gnutls_check_version(NULL), LIBGNUTLS_VERSION ) )
-+    {
-+      printf("\n*** LIBGNUTLS header file (version %s) does not match\n", LIBGNUTLS_VERSION);
-+      printf("*** library (version %s)\n", gnutls_check_version(NULL) );
-+    }
-+    else
-+    {
-+      if ( gnutls_check_version( "$min_libgnutls_version" ) )
-+      {
-+        return 0;
-+      }
-+     else
-+      {
-+        printf("no\n*** An old version of LIBGNUTLS (%s) was found.\n",
-+                gnutls_check_version(NULL) );
-+        printf("*** You need a version of LIBGNUTLS newer than %s. The latest version of\n",
-+               "$min_libgnutls_version" );
-+        printf("*** LIBGNUTLS is always available from ftp://gnutls.hellug.gr/pub/gnutls.\n");
-+        printf("*** \n");
-+        printf("*** If you have already installed a sufficiently new version, this error\n");
-+        printf("*** probably means that the wrong copy of the libgnutls-config shell script is\n");
-+        printf("*** being found. The easiest way to fix this is to remove the old version\n");
-+        printf("*** of LIBGNUTLS, but you can also set the LIBGNUTLS_CONFIG environment to point to the\n");
-+        printf("*** correct copy of libgnutls-config. (In this case, you will have to\n");
-+        printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
-+        printf("*** so that the correct libraries are found at run-time))\n");
-+      }
-+    }
-+  return 1;
-+}
-+],, no_libgnutls=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
-+       CFLAGS="$ac_save_CFLAGS"
-+       LIBS="$ac_save_LIBS"
-+  fi
-+
-+  if test "x$no_libgnutls" = x ; then
-+     AC_MSG_RESULT(yes)
-+     ifelse([$2], , :, [$2])
-+  else
-+     if test -f conf.libgnutlstest ; then
-+        :
-+     else
-+        AC_MSG_RESULT(no)
-+     fi
-+     if test "$LIBGNUTLS_CONFIG" = "no" ; then
-+       echo "*** The libgnutls-config script installed by LIBGNUTLS could not be found"
-+       echo "*** If LIBGNUTLS was installed in PREFIX, make sure PREFIX/bin is in"
-+       echo "*** your path, or set the LIBGNUTLS_CONFIG environment variable to the"
-+       echo "*** full path to libgnutls-config."
-+     else
-+       if test -f conf.libgnutlstest ; then
-+        :
-+       else
-+          echo "*** Could not run libgnutls test program, checking why..."
-+          CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
-+          LIBS="$LIBS $LIBGNUTLS_LIBS"
-+          AC_TRY_LINK([
-+#include <stdio.h>
-+#include <stdlib.h>
-+#include <string.h>
-+#include <gnutls/gnutls.h>
-+],      [ return !!gnutls_check_version(NULL); ],
-+        [ echo "*** The test program compiled, but did not run. This usually means"
-+          echo "*** that the run-time linker is not finding LIBGNUTLS or finding the wrong"
-+          echo "*** version of LIBGNUTLS. If it is not finding LIBGNUTLS, you'll need to set your"
-+          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
-+          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
-+          echo "*** is required on your system"
-+          echo "***"
-+          echo "*** If you have an old version installed, it is best to remove it, although"
-+          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
-+          echo "***" ],
-+        [ echo "*** The test program failed to compile or link. See the file config.log for the"
-+          echo "*** exact error that occured. This usually means LIBGNUTLS was incorrectly installed"
-+          echo "*** or that you have moved LIBGNUTLS since it was installed. In the latter case, you"
-+          echo "*** may want to edit the libgnutls-config script: $LIBGNUTLS_CONFIG" ])
-+          CFLAGS="$ac_save_CFLAGS"
-+          LIBS="$ac_save_LIBS"
-+       fi
-+     fi
-+     LIBGNUTLS_CFLAGS=""
-+     LIBGNUTLS_LIBS=""
-+     ifelse([$3], , :, [$3])
-+  fi
-+  rm -f conf.libgnutlstest
-+  AC_SUBST(LIBGNUTLS_CFLAGS)
-+  AC_SUBST(LIBGNUTLS_LIBS)
-+])
-+
-+dnl *-*wedit:notab*-*  Please keep this as the last line.
 

file:a/libs/libao/Makefile (deleted)
--- a/libs/libao/Makefile
+++ /dev/null
@@ -1,63 +1,1 @@
-#
-# Copyright (C) 2006 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:=libao
-PKG_VERSION:=1.1.0
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://downloads.xiph.org/releases/ao/
-PKG_MD5SUM:=2b2508c29bc97e4dc218fa162cf883c8
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libao
-  SECTION:=libs
-  DEPENDS:=+alsa-lib
-  CATEGORY:=Libraries
-  TITLE:=A cross platform audio library
-  URL:=http://www.xiph.org/ao/
-endef
-
-define Package/libao/description
-	Libao is a cross-platform audio library that allows programs to
-	output audio using a simple API on a wide variety of platforms.
-endef
-
-CONFIGURE_ARGS += \
-	--enable-shared \
-	--enable-static \
-	--disable-esd \
-	--disable-arts \
-	--disable-nas \
-	--disable-pulse
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/ao $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libao.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/ao.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libao/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libao.so.* $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/ao/plugins-4
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/ao/plugins-4/lib*.so $(1)/usr/lib/ao/plugins-4/
-endef
-
-$(eval $(call BuildPackage,libao))
-

file:a/libs/libexif/Makefile (deleted)
--- a/libs/libexif/Makefile
+++ /dev/null
@@ -1,63 +1,1 @@
-#
-# Copyright (C) 2006-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:=libexif
-PKG_VERSION:=0.6.21
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=@SF/libexif
-PKG_MD5SUM:=27339b89850f28c8f1c237f233e05b27
-
-PKG_LICENSE:=LGPLv2.1
-PKG_LICENSE_FILES:=COPYING
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libexif
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=library for jpeg files with exif tags
-  URL:=http://libexif.sourceforge.net/
-endef
-
-define Package/libexif/description
-  libexif is a library for parsing, editing, and saving EXIF data. It is
-  intended to replace lots of redundant implementations in command-line
-  utilities and programs with GUIs.
-endef
-
-CONFIGURE_ARGS+= \
-	--enable-shared \
-	--enable-static \
-	--disable-rpath \
-	--without-libiconv-prefix \
-	--without-libintl-prefix \
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/libexif $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libexif*.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libexif.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libexif/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libexif*.so.* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libexif))
-

--- a/libs/libexif/patches/100-no_doc.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -289,7 +289,7 @@ target_alias = @target_alias@
- top_build_prefix = @top_build_prefix@
- top_builddir = @top_builddir@
- top_srcdir = @top_srcdir@
--SUBDIRS = m4m po libexif test doc binary contrib
-+SUBDIRS = m4m po libexif test binary contrib
- EXTRA_DIST = @PACKAGE_TARNAME@.spec README-Win32.txt libexif.pc.in \
- 	libexif-uninstalled.pc.in
- pkgconfigdir = $(libdir)/pkgconfig
 

file:a/libs/libgcrypt/Makefile (deleted)
--- a/libs/libgcrypt/Makefile
+++ /dev/null
@@ -1,71 +1,1 @@
-#
-# Copyright (C) 2005-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:=libgcrypt
-PKG_VERSION:=1.5.3
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=ftp://ftp.gnupg.org/gcrypt/libgcrypt
-PKG_MD5SUM:=993159b2924ae7b0e4eaff0743c2db35
-
-PKG_FIXUP:=patch-libtool
-PKG_INSTALL:=1
-PKG_BUILD_PARALLEL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libgcrypt
-  SECTION:=libs
-  CATEGORY:=Libraries
-  DEPENDS:=+libgpg-error
-  TITLE:=GNU crypto library
-  URL:=http://directory.fsf.org/security/libgcrypt.html
-endef
-
-define Package/libgcrypt/description
- This is a general purpose cryptographic library based on the code from
- GnuPG. It provides functions for all cryptograhic building blocks:
- symmetric ciphers (AES, DES, Arcfour, CAST5), hash algorithms (MD5, SHA-1,
- RIPE-MD160, SHA-224/256, SHA-384/512), MACs (HMAC for all hash
- algorithms), public key algorithms (RSA, DSA), large integer functions,
- random numbers and a lot of supporting functions. Some algorithms have
- been disabled to reduce size (Blowfish, Twofish, Serpent,
- RC2, SEED, Camellia, CRC, MD4, TIGER-192, Whirlpool, ElGamal, ECC).
-endef
-
-CONFIGURE_ARGS += \
-	--enable-shared \
-	--enable-static \
-	--disable-asm \
-	--with-gpg-error-prefix="$(STAGING_DIR)/usr" \
-	--enable-digests="md5 rmd160 sha1 sha256 sha512" \
-	--enable-ciphers="arcfour des aes cast5" \
-	--enable-pubkey-ciphers="rsa dsa"
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/bin $(2)/bin $(1)/usr/include $(1)/usr/lib $(1)/usr/share/aclocal
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libgcrypt-config $(1)/usr/bin/
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/gcrypt*.h $(1)/usr/include/
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgcrypt.{la,a,so*} $(1)/usr/lib/
-	$(CP) $(PKG_INSTALL_DIR)/usr/share/aclocal/libgcrypt.m4 $(1)/usr/share/aclocal/
-	$(SED) 's,^libdir=\"$$$${exec_prefix}/lib,libdir=\"$(STAGING_DIR)/usr/lib,g' $(1)/usr/bin/libgcrypt-config
-	$(SED) 's,^includedir=\"$$$${prefix}/include/,includedir=\"$(STAGING_DIR)/usr/include/,g' $(1)/usr/bin/libgcrypt-config
-	ln -sf $(STAGING_DIR)/usr/bin/libgcrypt-config $(2)/bin/
-endef
-
-define Package/libgcrypt/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgcrypt.so.* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libgcrypt))
-

--- a/libs/libgpg-error/Makefile
+++ /dev/null
@@ -1,80 +1,1 @@
-#
-# Copyright (C) 2005-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:=libgpg-error
-PKG_VERSION:=1.9
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=ftp://ftp.gnupg.org/gcrypt/libgpg-error
-PKG_MD5SUM:=521b98aa9395e7eaf0ef2236233a0796
-
-PKG_BUILD_PARALLEL:=1
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libgpg-error
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=GnuPG error handling helper library
-  URL:=http://www.gnupg.org/related_software/libgpg-error/
-endef
-
-define Package/libgpg-error/description
-	An helper library for common error codes and descriptions.
-	This is a library that defines common error values for all GnuPG
-	components. Among these are GPG, GPGSM, GPGME, GPG-Agent, libgcrypt,
-	Libksba, DirMngr, Pinentry, SmartCard Daemon and possibly more in the
-	future.
-endef
-
-TARGET_CFLAGS += $(FPIC)
-
-CONFIGURE_ARGS += \
-	--enable-shared \
-	--enable-static \
-	--disable-rpath
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(2)/bin $(1)/usr/bin
-	$(INSTALL_BIN) \
-		$(PKG_INSTALL_DIR)/usr/bin/gpg-error-config \
-		$(2)/bin/
-	$(SED) \
-		's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
-		$(2)/bin/gpg-error-config
-	ln -sf $(STAGING_DIR)/host/bin/gpg-error-config $(1)/usr/bin/gpg-error-config
-
-	$(INSTALL_DIR) $(1)/usr/include
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/include/gpg-error.h \
-		$(1)/usr/include/
-
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libgpg-error.{la,a,so*} \
-		$(1)/usr/lib/
-
-	$(INSTALL_DIR) $(1)/usr/share/aclocal
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/share/aclocal/gpg-error.m4 \
-		$(1)/usr/share/aclocal/
-endef
-
-define Package/libgpg-error/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libgpg-error.so.* \
-		$(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libgpg-error))
-

file:a/libs/libmpeg2/Makefile (deleted)
--- a/libs/libmpeg2/Makefile
+++ /dev/null
@@ -1,61 +1,1 @@
-#
-# 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:=libmpeg2
-PKG_VERSION:=0.5.1
-PKG_RELEASE:=1
-
-PKG_SOURCE:=libmpeg2-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://libmpeg2.sourceforge.net/files/
-PKG_MD5SUM:=0f92c7454e58379b4a5a378485bbd8ef
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libmpeg2
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=MPEG-1 & -2 decoding library
-  URL:=http://libmpeg2.sourceforge.net/
-  MAINTAINER:=W. Michael Petullo <mike@flyn.org>
-endef
-
-define Package/libmpeg2/decription
-  Libmpeg2 is a library for decoding MPEG-1 and MPEG-2 video streams
-endef
-
-CONFIGURE_ARGS += \
-	--disable-sdl \
-	--without-x \
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/include/mpeg2dec \
-		$(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libmpeg2{,convert}.{a,so*} \
-		$(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libmpeg2{,convert}.pc \
-		$(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libmpeg2/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libmpeg2{,convert}.so.* \
-		$(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libmpeg2))
-

--- a/libs/libmpeg2/patches/101-ppc_no_altivec.patch
+++ /dev/null
@@ -1,67 +1,1 @@
---- a/libmpeg2/motion_comp_altivec.c
-+++ b/libmpeg2/motion_comp_altivec.c
-@@ -25,6 +25,8 @@
- 
- #ifdef ARCH_PPC
- 
-+#ifdef __I_WANT_ALTIVEC__
-+
- #ifdef HAVE_ALTIVEC_H
- #include <altivec.h>
- #endif
-@@ -1007,4 +1009,6 @@ static void MC_avg_xy_8_altivec (uint8_t
- 
- MPEG2_MC_EXTERN (altivec)
- 
-+#endif /* __I_WANT_ALTIVEC__ */
-+
- #endif
---- a/libmpeg2/idct_altivec.c
-+++ b/libmpeg2/idct_altivec.c
-@@ -25,6 +25,8 @@
- 
- #ifdef ARCH_PPC
- 
-+#ifdef __I_WANT_ALTIVEC__
-+
- #ifdef HAVE_ALTIVEC_H
- #include <altivec.h>
- #endif
-@@ -283,4 +285,6 @@ void mpeg2_idct_altivec_init (void)
-     }
- }
- 
-+#endif /* __I_WANT_ALTIVEC__ */
-+
- #endif
---- a/libmpeg2/idct.c
-+++ b/libmpeg2/idct.c
-@@ -251,11 +251,13 @@ void mpeg2_idct_init (uint32_t accel)
-     } else
- #endif
- #ifdef ARCH_PPC
-+#ifdef __I_WANT_ALTIVEC__
-     if (accel & MPEG2_ACCEL_PPC_ALTIVEC) {
- 	mpeg2_idct_copy = mpeg2_idct_copy_altivec;
- 	mpeg2_idct_add = mpeg2_idct_add_altivec;
- 	mpeg2_idct_altivec_init ();
-     } else
-+#endif /* __I_WANT_ALTIVEC__ */
- #endif
- #ifdef ARCH_ALPHA
-     if (accel & MPEG2_ACCEL_ALPHA_MVI) {
---- a/libmpeg2/motion_comp.c
-+++ b/libmpeg2/motion_comp.c
-@@ -43,9 +43,11 @@ void mpeg2_mc_init (uint32_t accel)
-     else
- #endif
- #ifdef ARCH_PPC
-+#ifdef __I_WANT_ALTIVEC__
-     if (accel & MPEG2_ACCEL_PPC_ALTIVEC)
- 	mpeg2_mc = mpeg2_mc_altivec;
-     else
-+#endif /* __I_WANT_ALTIVEC__ */
- #endif
- #ifdef ARCH_ALPHA
-     if (accel & MPEG2_ACCEL_ALPHA)
 

--- a/libs/libmpeg2/patches/102-arm_data_preload_check.patch
+++ /dev/null
@@ -1,20 +1,1 @@
-diff -urN libmpeg2-0.5.1/libmpeg2/motion_comp_arm_s.S libmpeg2-0.5.1.new/libmpeg2/motion_comp_arm_s.S
---- libmpeg2-0.5.1/libmpeg2/motion_comp_arm_s.S	2008-07-09 21:16:05.000000000 +0200
-+++ libmpeg2-0.5.1.new/libmpeg2/motion_comp_arm_s.S	2012-07-30 15:22:58.664964215 +0200
-@@ -19,6 +19,15 @@
- @ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- 
- 
-+@ Data preload is supported only by ARM V5TE and above
-+
-+#if (defined (__ARM_ARCH_2__) || defined (__ARM_ARCH_3__) \
-+     || defined (__ARM_ARCH_3M__) || defined (__ARM_ARCH_4__) \
-+     || defined (__ARM_ARCH_4T__) || defined (__ARM_ARCH_5__) \
-+     || defined (__ARM_ARCH_5T__))
-+.macro pld reg
-+.endm
-+#endif
- 	.text
- 
- @ ----------------------------------------------------------------
 

file:a/libs/liboil/Makefile (deleted)
--- a/libs/liboil/Makefile
+++ /dev/null
@@ -1,66 +1,1 @@
-#
-# Copyright (C) 2007-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:=liboil
-PKG_VERSION:=0.3.17
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://liboil.freedesktop.org/download/
-PKG_MD5SUM:=47dc734f82faeb2964d97771cfd2e701
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/liboil
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=simple functions optimized for various CPUs
-  URL:=http://liboil.freedesktop.org/wiki/
-  DEPENDS:=+librt
-endef
-
-define Package/liboil/description
-  Liboil is a library of simple functions that are optimized for various CPUs.
-  These functions are generally loops implementing simple algorithms, such as
-  converting an array of N integers to floating-point numbers or multiplying
-  and summing an array of N numbers. Such functions are candidates for significant
-  optimization using various techniques, especially by using extended instructions
-  provided by modern CPUs (Altivec, MMX, SSE, etc.).
-endef
-
-CONFIGURE_ARGS += \
-	--enable-shared \
-	--enable-static \
-
-TARGET_CFLAGS += $(FPIC)
-
-# XXX: VFP_CFLAGS is set to '-mfpu=vfp' on arm by configure, but that breaks
-# final linking stages, so override it until we find why
-MAKE_FLAGS += \
-	VFP_CFLAGS="" \
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/liboil-0.3/* $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/liboil-0.3.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/liboil-0.3.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/liboil/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/liboil-0.3.so.* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,liboil))
-

--- a/libs/liboil/patches/001-no-tools-docs-examples.patch
+++ /dev/null
@@ -1,23 +1,1 @@
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -1,7 +1,7 @@
- 
- AUTOMAKE_OPTIONS = foreign
- 
--SUBDIRS = liboil testsuite examples doc
-+SUBDIRS = liboil
- 
- EXTRA_DIST = COPYING autogen.sh gtk-doc.make HACKING BUG-REPORTING
- 
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -278,7 +278,7 @@ top_build_prefix = @top_build_prefix@
- top_builddir = @top_builddir@
- top_srcdir = @top_srcdir@
- AUTOMAKE_OPTIONS = foreign
--SUBDIRS = liboil testsuite examples doc
-+SUBDIRS = liboil
- EXTRA_DIST = COPYING autogen.sh gtk-doc.make HACKING BUG-REPORTING
- DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
- pkgconfig_DATA = liboil-$(LIBOIL_MAJORMINOR).pc
 

--- a/libs/liboil/patches/002-pkgconfig.patch
+++ /dev/null
@@ -1,20 +1,1 @@
---- a/liboil.pc.in
-+++ b/liboil.pc.in
-@@ -1,7 +1,7 @@
- prefix=@prefix@
- exec_prefix=@exec_prefix@
- libdir=@libdir@
--includedir=@includedir@/liboil-@LIBOIL_MAJORMINOR@
-+includedir=@includedir@
- toolsdir=${exec_prefix}/bin
- 
- 
-@@ -9,6 +9,6 @@ Name: liboil-@LIBOIL_MAJORMINOR@
- Description: Library of Optimized Inner Loops
- Version: @VERSION@
- Libs: -L${libdir} -loil-@LIBOIL_MAJORMINOR@ @LIBM@ @LIBRT@
--Cflags: -I${includedir}
-+Cflags: -I${includedir}/liboil-@LIBOIL_MAJORMINOR@
- 
- 
 

file:a/libs/libtheora/Makefile (deleted)
--- a/libs/libtheora/Makefile
+++ /dev/null
@@ -1,65 +1,1 @@
-#
-# Copyright (C) 2008-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:=libtheora
-PKG_VERSION:=1.1.1
-PKG_RELEASE:=1
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=http://downloads.xiph.org/releases/theora/
-PKG_MD5SUM:=292ab65cedd5021d6b7ddd117e07cd8e
-PKG_FIXUP:=autoreconf
-
-PKG_BUILD_DEPENDS:=libvorbis
-
-include $(INCLUDE_DIR)/package.mk
-
-PKG_INSTALL=1
-
-define Package/libtheora
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE:=libtheora
-  URL:=http://xiph.org/theora/
-  DEPENDS:=+libogg
-endef
-
-define Package/libtheora/description
-Theora is Xiph.Org's first publicly released video codec, intended
-for use within the Foundation's Ogg multimedia streaming system.
-Theora is derived directly from On2's VP3 codec; Currently the
-encoders are nearly identical, but Theora will make use of new
-features supported by the decoder to improve over what is
-is possible with VP3.
-endef
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-		--disable-examples \
-		--disable-oggtest \
-		--disable-vorbistest \
-		--disable-sdltest \
-	)
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include/theora/
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/theora/* $(1)/usr/include/theora/
-	$(INSTALL_DIR) $(1)/usr/lib/
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{so*,a,la} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libtheora/install
-	$(INSTALL_DIR) $(1)/usr/lib/
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,libtheora))
-

--- a/libs/libtheora/patches/001-no_docs_tests.patch
+++ /dev/null
@@ -1,34 +1,1 @@
-diff -urN libtheora-1.1.1/Makefile.am libtheora-1.1.1.new/Makefile.am
---- libtheora-1.1.1/Makefile.am	2009-07-14 01:55:02.000000000 +0200
-+++ libtheora-1.1.1.new/Makefile.am	2012-12-05 14:21:06.103521554 +0100
-@@ -8,7 +8,7 @@
- EXAMPLES_DIR =
- endif
- 
--SUBDIRS = lib include doc tests m4 $(EXAMPLES_DIR)
-+SUBDIRS = lib include m4 $(EXAMPLES_DIR)
- 
- 
- # we include the whole debian/ dir in EXTRA_DIST because there's a problem
-diff -urN libtheora-1.1.1/Makefile.in libtheora-1.1.1.new/Makefile.in
---- libtheora-1.1.1/Makefile.in	2009-10-01 20:04:07.000000000 +0200
-+++ libtheora-1.1.1.new/Makefile.in	2012-12-05 14:21:18.239521864 +0100
-@@ -164,7 +164,7 @@
- @THEORA_ENABLE_EXAMPLES_TRUE@EXAMPLES_DIR = examples
- @THEORA_ENABLE_EXAMPLES_FALSE@EXAMPLES_DIR = 
- 
--SUBDIRS = lib include doc tests m4 $(EXAMPLES_DIR)
-+SUBDIRS = lib include m4 $(EXAMPLES_DIR)
- 
- # we include the whole debian/ dir in EXTRA_DIST because there's a problem
- # with autotools and HFS+ MacOSX file systems that caused debian/Makefile.am
-@@ -200,7 +200,7 @@
- 	missing mkinstalldirs theora-uninstalled.pc.in theora.pc.in \
- 	theoradec-uninstalled.pc.in theoradec.pc.in \
- 	theoraenc-uninstalled.pc.in theoraenc.pc.in
--DIST_SUBDIRS = lib include doc tests m4 examples
-+DIST_SUBDIRS = lib include m4 examples
- all: config.h
- 	$(MAKE) $(AM_MAKEFLAGS) all-recursive
- 
 

--- a/libs/libtheora/patches/002-no_sdl_check.patch
+++ /dev/null
@@ -1,15 +1,1 @@
---- libtheora-1.1.1/configure.ac	2009-10-01 20:00:33.000000000 +0200
-+++ libtheora-1.1.1.new/configure.ac	2012-12-05 14:22:26.319523608 +0100
-@@ -313,11 +313,6 @@
- dnl check for SDL
- HAVE_SDL=no
- 
--AM_PATH_SDL(,[
--  HAVE_SDL=yes
--  SDL_LIBS=`$SDL_CONFIG --libs`
--],AC_MSG_WARN([*** Unable to find SDL -- Not compiling example players ***]))
--
- dnl check for OSS
- HAVE_OSS=no
- AC_CHECK_HEADERS([sys/soundcard.h soundcard.h machine/soundcard.h],[
 

file:a/libs/libv4l/Makefile (deleted)
--- a/libs/libv4l/Makefile
+++ /dev/null
@@ -1,114 +1,1 @@
-#
-# Copyright (C) 2009-2012 OpenWrt.org
-# Copyright (C) 2009 David Cooper <dave@kupesoft.com>
-#
-# This is free software, licensed under the GNU General Public License v2.
-# See /LICENSE for more information.
-#
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=v4l-utils
-PKG_VERSION:=0.8.6
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=http://www.linuxtv.org/downloads/v4l-utils
-PKG_MD5SUM:=80062780ae90e5955473b09b31e9828a
-
-PKG_BUILD_DEPENDS:=argp-standalone
-
-include $(INCLUDE_DIR)/uclibc++.mk
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libv4l/Default
-  TITLE:=Video 4 Linux
-  URL:=http://www.linuxtv.org/
-endef
-
-define Package/libv4l/Default/description
-  libv4l is a collection of libraries which adds a thin abstraction layer on
-  top of video4linux2 devices. The purpose of this (thin) layer is to make it
-  easy for application writers to support a wide variety of devices without
-  having to write separate code for different devices in the same class. libv4l
-  consists of 3 different libraries: libv4lconvert, libv4l1 and libv4l2.
-
-  libv4l1 offers the (deprecated) v4l1 API on top of v4l2 devices, independent
-  of the drivers for those devices supporting v4l1 compatibility (which many
-  v4l2 drivers do not).
-
-  libv4l2 offers the v4l2 API on top of v4l2 devices, while adding for the
-  application transparent libv4lconvert conversion where necessary.
-endef
-
-define Package/libv4l
-  $(call Package/libv4l/Default)
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE+= wrapper libraries
-  DEPENDS := +libpthread +librt
-endef
-
-define Package/libv4l/description
-  $(call Package/libv4l/Default/description)
-endef
-
-define Package/v4l-utils
-  $(call Package/libv4l/Default)
-  SECTION:=utils
-  CATEGORY:=Utilities
-  TITLE+= utilities
-  DEPENDS := +libv4l $(CXX_DEPENDS)
-endef
-
-define Package/v4l-utils/description
-  $(call Package/libv4l/Default/description)
-  This package contains the video4linux utilities.
-endef
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		DESTDIR="$(PKG_INSTALL_DIR)" PREFIX="/usr" \
-		DISABLE_LIBJPEG="1" \
-		$(CONFIGURE_VARS) \
-		all install
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		DESTDIR="$(PKG_INSTALL_DIR)" PREFIX="/usr" \
-		DISABLE_LIBJPEG="1" \
-		$(CONFIGURE_VARS) \
-		LINKTYPE="static" \
-		all install
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libv4l{1,2,convert}.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libv4l{1,2,convert}.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Package/libv4l/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libv4l{1,2,convert}.so.* $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/libv4l
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libv4l/v4l{1compat,2convert}.so $(1)/usr/lib/libv4l/
-endef
-
-define Package/v4l-utils/install
-	$(INSTALL_DIR) $(1)/etc
-	$(CP) $(PKG_INSTALL_DIR)/etc/rc_maps.cfg $(1)/etc/
-	$(CP) $(PKG_INSTALL_DIR)/etc/rc_keymaps $(1)/etc/
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/{cx18,ivtv}-ctl $(1)/usr/bin/
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/decode_tm6000 $(1)/usr/bin/
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/ir-keytable $(1)/usr/bin/
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/v4l2-{compliance,ctl,sysfs-path} $(1)/usr/bin/
-endef
-
-$(eval $(call BuildPackage,libv4l))
-$(eval $(call BuildPackage,v4l-utils))
-

--- a/libs/libv4l/patches/001-no-shm_open-fix.patch
+++ /dev/null
@@ -1,58 +1,1 @@
---- a/lib/libv4lconvert/control/libv4lcontrol.c
-+++ b/lib/libv4lconvert/control/libv4lcontrol.c
-@@ -525,7 +525,7 @@ static void v4lcontrol_get_flags_from_db
- 
- struct v4lcontrol_data *v4lcontrol_create(int fd, int always_needs_conversion)
- {
--	int shm_fd;
-+	int shm_fd, fdflags;
- 	int i, rc, got_usb_info, speed, init = 0;
- 	char *s, shm_name[256], pwd_buf[1024];
- 	struct v4l2_capability cap;
-@@ -638,33 +638,38 @@ struct v4lcontrol_data *v4lcontrol_creat
- 
- 	if (getpwuid_r(geteuid(), &pwd, pwd_buf, sizeof(pwd_buf), &pwd_p) == 0) {
- 		if (got_usb_info)
--			snprintf(shm_name, 256, "/libv4l-%s:%s:%04x:%04x:%s", pwd.pw_name,
-+			snprintf(shm_name, 256, "/dev/shm/libv4l-%s:%s:%04x:%04x:%s", pwd.pw_name,
- 					cap.bus_info, (int)vendor_id, (int)product_id, cap.card);
- 		else
--			snprintf(shm_name, 256, "/libv4l-%s:%s:%s", pwd.pw_name,
-+			snprintf(shm_name, 256, "/dev/shm/libv4l-%s:%s:%s", pwd.pw_name,
- 					cap.bus_info, cap.card);
- 	} else {
- 		perror("libv4lcontrol: error getting username using uid instead");
- 		if (got_usb_info)
--			snprintf(shm_name, 256, "/libv4l-%lu:%s:%04x:%04x:%s",
-+			snprintf(shm_name, 256, "/dev/shm/libv4l-%lu:%s:%04x:%04x:%s",
- 					(unsigned long)geteuid(), cap.bus_info,
- 					(int)vendor_id, (int)product_id, cap.card);
- 		else
--			snprintf(shm_name, 256, "/libv4l-%lu:%s:%s", (unsigned long)geteuid(),
-+			snprintf(shm_name, 256, "/dev/shm/libv4l-%lu:%s:%s", (unsigned long)geteuid(),
- 					cap.bus_info, cap.card);
- 	}
- 
- 	/* / is not allowed inside shm names */
--	for (i = 1; shm_name[i]; i++)
-+	for (i = 9; shm_name[i]; i++) /* start after "/dev/shm", i = 9 */
- 		if (shm_name[i] == '/')
- 			shm_name[i] = '-';
- 
- 	/* Open the shared memory object identified by shm_name */
--	shm_fd = shm_open(shm_name, (O_CREAT | O_EXCL | O_RDWR), (S_IREAD | S_IWRITE));
-+	shm_fd = open(shm_name, (O_CREAT | O_EXCL | O_RDWR), (S_IREAD | S_IWRITE));
- 	if (shm_fd >= 0)
- 		init = 1;
- 	else
--		shm_fd = shm_open(shm_name, O_RDWR, (S_IREAD | S_IWRITE));
-+		shm_fd = open(shm_name, O_RDWR, (S_IREAD | S_IWRITE));
-+
-+	/* This is all uClibc > 0.9.30 seems to do for shm_open() in librt/shm.c */
-+	fdflags = fcntl(shm_fd, F_GETFD, 0);
-+	if (fdflags >= 0)
-+		fdflags = fcntl(fd, F_SETFD, fdflags | FD_CLOEXEC);
- 
- 	if (shm_fd >= 0) {
- 		/* Set the shared memory size */
 

--- a/libs/libv4l/patches/002-allow-disabling-libjpeg.patch
+++ /dev/null
@@ -1,161 +1,1 @@
---- a/lib/libv4lconvert/Makefile
-+++ b/lib/libv4lconvert/Makefile
-@@ -1,6 +1,6 @@
- override CPPFLAGS += -I../include -fvisibility=hidden
- 
--LIBS_libv4lconvert = -lrt -lm -ljpeg
-+LIBS_libv4lconvert = -lrt -lm
- 
- ifeq ($(LINKTYPE),static)
- CONVERT_LIB   = libv4lconvert.a
-@@ -10,16 +10,22 @@ override CPPFLAGS += -fPIC
- endif
- 
- CONVERT_OBJS  = libv4lconvert.o tinyjpeg.o sn9c10x.o sn9c20x.o pac207.o \
--		jl2005bcd.o \
- 		mr97310a.o flip.o crop.o jidctflt.o spca561-decompress.o \
- 		rgbyuv.o sn9c2028-decomp.o spca501.o sq905c.o bayer.o hm12.o \
--		stv0680.o cpia1.o se401.o jpgl.o jpeg.o jpeg_memsrcdest.o \
-+		stv0680.o cpia1.o se401.o jpgl.o jpeg.o \
- 		control/libv4lcontrol.o processing/libv4lprocessing.o \
- 		processing/whitebalance.o processing/autogain.o \
- 		processing/gamma.o helper.o
- TARGETS       = $(CONVERT_LIB) libv4lconvert.pc ov511-decomp ov518-decomp
- INCLUDES      = ../include/libv4lconvert.h
- 
-+ifeq ($(DISABLE_LIBJPEG),1)
-+override CFLAGS += -DDISABLE_LIBJPEG
-+else
-+LIBS_libv4lconvert += -ljpeg
-+CONVERT_OBJS += jl2005bcd.o jpeg_memsrcdest.o
-+endif
-+
- override CPPFLAGS += -DLIBDIR=\"$(LIBDIR)\" -DLIBSUBDIR=\"$(LIBSUBDIR)\"
- 
- all: $(TARGETS)
---- a/lib/libv4lconvert/jpeg.c
-+++ b/lib/libv4lconvert/jpeg.c
-@@ -19,7 +19,9 @@
- #include <errno.h>
- #include <stdlib.h>
- #include "libv4lconvert-priv.h"
-+#ifndef DISABLE_LIBJPEG
- #include "jpeg_memsrcdest.h"
-+#endif
- 
- int v4lconvert_decode_jpeg_tinyjpeg(struct v4lconvert_data *data,
- 	unsigned char *src, int src_size, unsigned char *dest,
-@@ -107,6 +109,8 @@ int v4lconvert_decode_jpeg_tinyjpeg(stru
- 	return 0;
- }
- 
-+#ifndef DISABLE_LIBJPEG
-+
- static void jerr_error_exit(j_common_ptr cinfo)
- {
- 	struct v4lconvert_data *data = cinfo->client_data;
-@@ -405,3 +409,6 @@ int v4lconvert_decode_jpeg_libjpeg(struc
- 
- 	return result;
- }
-+
-+#endif
-+
---- a/lib/libv4lconvert/libv4lconvert-priv.h
-+++ b/lib/libv4lconvert/libv4lconvert-priv.h
-@@ -22,7 +22,9 @@
- #include <stdio.h>
- #include <stdint.h>
- #include <sys/types.h>
-+#ifndef DISABLE_LIBJPEG
- #include <jpeglib.h>
-+#endif
- #include <setjmp.h>
- #include "libv4lconvert.h"
- #include "control/libv4lcontrol.h"
-@@ -50,11 +52,13 @@ struct v4lconvert_data {
- 	int64_t supported_src_formats; /* bitfield */
- 	char error_msg[V4LCONVERT_ERROR_MSG_SIZE];
- 	struct jdec_private *tinyjpeg;
-+#ifndef DISABLE_LIBJPEG
- 	struct jpeg_error_mgr jerr;
- 	int jerr_errno;
- 	jmp_buf jerr_jmp_state;
- 	struct jpeg_decompress_struct cinfo;
- 	int cinfo_initialized;
-+#endif
- 	struct v4l2_frmsizeenum framesizes[V4LCONVERT_MAX_FRAMESIZES];
- 	unsigned int no_framesizes;
- 	int bandwidth;
---- a/lib/libv4lconvert/libv4lconvert.c
-+++ b/lib/libv4lconvert/libv4lconvert.c
-@@ -78,7 +78,9 @@ static const struct v4lconvert_pixfmt su
- 	{ V4L2_PIX_FMT_SN9C2028,	 0,	 9,	 9,	1 },
- 	{ V4L2_PIX_FMT_PAC207,		 0,	 9,	 9,	1 },
- 	{ V4L2_PIX_FMT_MR97310A,	 0,	 9,	 9,	1 },
-+#ifndef DISABLE_LIBJPEG
- 	{ V4L2_PIX_FMT_JL2005BCD,	 0,	 9,	 9,	1 },
-+#endif
- 	{ V4L2_PIX_FMT_SQ905C,		 0,	 9,	 9,	1 },
- 	/* special */
- 	{ V4L2_PIX_FMT_SE401,		 0,	 8,	 9,	1 },
-@@ -186,8 +188,10 @@ void v4lconvert_destroy(struct v4lconver
- 		tinyjpeg_set_components(data->tinyjpeg, comps, 3);
- 		tinyjpeg_free(data->tinyjpeg);
- 	}
-+#ifndef DISABLE_LIBJPEG
- 	if (data->cinfo_initialized)
- 		jpeg_destroy_decompress(&data->cinfo);
-+#endif
- 	v4lconvert_helper_cleanup(data);
- 	free(data->convert1_buf);
- 	free(data->convert2_buf);
-@@ -634,10 +638,13 @@ static int v4lconvert_convert_pixfmt(str
- 	/* JPG and variants */
- 	case V4L2_PIX_FMT_MJPEG:
- 	case V4L2_PIX_FMT_JPEG:
-+#ifndef DISABLE_LIBJPEG
- 		if (data->flags & V4LCONVERT_USE_TINYJPEG) {
-+#endif
- 			result = v4lconvert_decode_jpeg_tinyjpeg(data,
- 							src, src_size, dest,
- 							fmt, dest_pix_fmt, 0);
-+#ifndef DISABLE_LIBJPEG
- 		} else {
- 			result = v4lconvert_decode_jpeg_libjpeg(data,
- 							src, src_size, dest,
-@@ -652,6 +659,7 @@ static int v4lconvert_convert_pixfmt(str
- 							fmt, dest_pix_fmt, 0);
- 			}
- 		}
-+#endif
- 		break;
- 	case V4L2_PIX_FMT_PJPG:
- 		result = v4lconvert_decode_jpeg_tinyjpeg(data, src, src_size,
-@@ -777,7 +785,9 @@ static int v4lconvert_convert_pixfmt(str
- 	case V4L2_PIX_FMT_SN9C10X:
- 	case V4L2_PIX_FMT_PAC207:
- 	case V4L2_PIX_FMT_MR97310A:
-+#ifndef DISABLE_LIBJPEG
- 	case V4L2_PIX_FMT_JL2005BCD:
-+#endif
- 	case V4L2_PIX_FMT_SN9C2028:
- 	case V4L2_PIX_FMT_SQ905C:
- 	case V4L2_PIX_FMT_STV0680: { /* Not compressed but needs some shuffling */
-@@ -816,6 +826,7 @@ static int v4lconvert_convert_pixfmt(str
- 			}
- 			tmpfmt.fmt.pix.pixelformat = V4L2_PIX_FMT_SBGGR8;
- 			break;
-+#ifndef DISABLE_LIBJPEG
- 		case V4L2_PIX_FMT_JL2005BCD:
- 			if (v4lconvert_decode_jl2005bcd(data, src, src_size,
- 							tmpbuf,
-@@ -826,6 +837,7 @@ static int v4lconvert_convert_pixfmt(str
- 			}
- 			tmpfmt.fmt.pix.pixelformat = V4L2_PIX_FMT_SRGGB8;
- 			break;
-+#endif
- 		case V4L2_PIX_FMT_SN9C2028:
- 			v4lconvert_decode_sn9c2028(src, tmpbuf, width, height);
- 			tmpfmt.fmt.pix.pixelformat = V4L2_PIX_FMT_SBGGR8;
 

--- a/libs/libv4l/patches/003-add-missing-libs.patch
+++ /dev/null
@@ -1,67 +1,1 @@
---- a/contrib/test/Makefile
-+++ b/contrib/test/Makefile
-@@ -28,7 +28,7 @@ pixfmt-test: pixfmt-test.o
- 	$(CC) $(LDFLAGS) -o $@ $^ -lX11
- 
- v4l2grab: v4l2grab.o ../../lib/libv4l2/libv4l2.so
--	$(CC) $(LDFLAGS) -o $@ $^ -L../../lib/libv4l2 -L../../lib/libv4lconvert -lv4l2 -lv4lconvert
-+	$(CC) $(LDFLAGS) -o $@ $^ -L../../lib/libv4l2 -L../../lib/libv4lconvert -lv4l2 -lv4lconvert -largp
- 
- ioctl-test: ioctl-test.o
- 	$(CC) $(LDFLAGS) -o $@ $^
---- a/utils/decode_tm6000/Makefile
-+++ b/utils/decode_tm6000/Makefile
-@@ -5,7 +5,7 @@ all: $(TARGETS)
- -include *.d
- 
- decode_tm6000: decode_tm6000.o ../libv4l2util/libv4l2util.a
--	$(CC) $(LDFLAGS) -o $@ $^
-+	$(CC) $(LDFLAGS) -o $@ $^ -largp
- 
- install: $(TARGETS)
- 	mkdir -p $(DESTDIR)$(PREFIX)/bin
---- a/utils/keytable/Makefile
-+++ b/utils/keytable/Makefile
-@@ -5,7 +5,7 @@ all: $(TARGETS)
- -include *.d
- 
- ir-keytable: keytable.o
--	$(CC) $(LDFLAGS) -o $@ $^
-+	$(CC) $(LDFLAGS) -o $@ $^ -largp
- 
- keytable.o: keytable.c parse.h
- 
---- a/utils/v4l2-compliance/Makefile
-+++ b/utils/v4l2-compliance/Makefile
-@@ -6,7 +6,7 @@ all: $(TARGETS)
- 
- v4l2-compliance: v4l2-compliance.o v4l2-test-debug.o v4l2-test-input-output.o \
- 	v4l2-test-controls.o v4l2-test-io-config.o v4l2-test-formats.o
--	$(CXX) $(LDFLAGS) -o $@ $^ -lv4l2 -lv4lconvert -lrt
-+	$(CXX) $(LDFLAGS) -o $@ $^ -lv4l2 -lv4lconvert -lrt -lpthread
- 
- install: $(TARGETS)
- 	mkdir -p $(DESTDIR)$(PREFIX)/bin
---- a/utils/v4l2-ctl/Makefile
-+++ b/utils/v4l2-ctl/Makefile
-@@ -13,7 +13,7 @@ ivtv-ctl: ivtv-ctl.o
- 	$(CC) $(LDFLAGS) -o $@ $^ -lm
- 
- v4l2-ctl: v4l2-ctl.o
--	$(CXX) $(LDFLAGS) -o $@ $^ -lv4l2 -lv4lconvert -lrt
-+	$(CXX) $(LDFLAGS) -o $@ $^ -lv4l2 -lv4lconvert -lrt -lpthread
- 
- install: $(TARGETS)
- 	mkdir -p $(DESTDIR)$(PREFIX)/bin
---- a/utils/v4l2-sysfs-path/Makefile
-+++ b/utils/v4l2-sysfs-path/Makefile
-@@ -5,7 +5,7 @@ all: $(TARGETS)
- -include *.d
- 
- v4l2-sysfs-path: v4l2-sysfs-path.o ../libmedia_dev/libmedia_dev.a
--	$(CC) $(LDFLAGS) -o $@ $^
-+	$(CC) $(LDFLAGS) -o $@ $^ -largp
- 
- install: $(TARGETS)
- 	mkdir -p $(DESTDIR)$(PREFIX)/bin
 

--- a/libs/libv4l/patches/004-disable-qv4l2.patch
+++ /dev/null
@@ -1,25 +1,1 @@
---- a/utils/Makefile
-+++ b/utils/Makefile
-@@ -5,21 +5,6 @@ all install: 
- 		$(MAKE) -C $$i $@ || exit 1; \
- 	done
- 
--	# Test whether qmake is installed, and whether it is for qt4.
--	@if which qmake-qt4 >/dev/null 2>&1; then \
--		QMAKE=qmake-qt4; \
--	else \
--		QMAKE=qmake; \
--	fi; \
--	if which $$QMAKE >/dev/null 2>&1; then \
--		if $$QMAKE --version 2>&1 | grep '4\.[0-9][0-9]*\.[0-9][0-9]*' >/dev/null; then \
--			if [ ! -f qv4l2/Makefile ]; then \
--				(cd qv4l2 && $$QMAKE) || exit 1; \
--			fi; \
--			$(MAKE) -C qv4l2 -f Makefile.install $@; \
--		fi \
--	fi
--
- sync-with-kernel:
- 	$(MAKE) -C keytable $@
- 	$(MAKE) -C v4l2-dbg $@
 

file:a/libs/libxslt/Makefile (deleted)
--- a/libs/libxslt/Makefile
+++ /dev/null
@@ -1,147 +1,1 @@
-#
-# 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:=libxslt
-PKG_VERSION:=1.1.28
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://xmlsoft.org/sources/ \
-	ftp://fr.rpmfind.net/pub/libxml/
-PKG_MD5SUM:=9667bf6f9310b957254fdcf6596600b7
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/libxslt
-  SECTION:=libs
-  CATEGORY:=Libraries
-  DEPENDS:=+libxml2
-  TITLE:=Gnome XSLT library
-  URL:=http://xmlsoft.org/XSLT/
-endef
-
-define Package/libxslt/description
-	A library for XML transformation using XSLT.
-endef
-
-define Package/libexslt
-  SECTION:=libs
-  CATEGORY:=Libraries
-  DEPENDS:=+libxslt
-  TITLE:=Gnome XSLT library Extention
-  URL:=http://xmlsoft.org/XSLT/EXSLT/
-endef
-
-define Package/libexslt/description
-	A extention for XSLT.
-endef
-
-define Package/xsltproc
-  SECTION:=utils
-  CATEGORY:=Utilities
-  DEPENDS:=+libxml2 +libxslt +libexslt
-  TITLE:=Gnome XSLT xsltproc Utility
-  URL:=http://xmlsoft.org/XSLT/
-endef
-
-define Package/xsltproc/description
-	XSLT XML transformation utility
-endef
-
-CONFIGURE_ARGS+= \
-	--enable-shared \
-	--enable-static \
-	--without-python \
-	--without-crypto \
-	--without-debug \
-	--without-mem-debug \
-	--without-debugger \
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/InstallDev/Xslt
-	$(INSTALL_DIR) $(1)/usr/bin $(2)/bin $(1)/usr/include/libxslt \
-		$(1)/usr/include/libexslt $(1)/usr/lib \
-		$(1)/usr/lib/pkgconfig $(2)/share/aclocal
-
-	$(INSTALL_BIN) \
-		$(PKG_INSTALL_DIR)/usr/bin/xslt-config \
-		$(2)/bin/
-
-	ln -sf $(STAGING_DIR)/host/bin/xslt-config $(1)/usr/bin/xslt-config
-
-	$(SED) \
-		's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
-		$(2)/bin/xslt-config
-
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/include/libxslt/* \
-		$(1)/usr/include/libxslt/
-
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libxslt.{la,a,so*} \
-		$(1)/usr/lib/
-
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libxslt.pc \
-		$(1)/usr/lib/pkgconfig/
-
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/share/aclocal/* \
-		$(2)/share/aclocal
-endef
-
-define Build/InstallDev/Exslt
-	$(INSTALL_DIR) $(1)/usr/include/libexslt $(1)/usr/lib/pkgconfig
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/include/libexslt/* \
-		$(1)/usr/include/libexslt/
-
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libexslt.{la,a,so*} \
-		$(1)/usr/lib/
-
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libexslt.pc \
-		$(1)/usr/lib/pkgconfig/
-endef
-
-define Build/InstallDev
-	 $(if $(CONFIG_PACKAGE_libxslt),$(call Build/InstallDev/Xslt,$(1),$(2)))
-	 $(if $(CONFIG_PACKAGE_libexslt),$(call Build/InstallDev/Exslt,$(1),$(2)))
-endef
-
-define Package/libxslt/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libxslt.so.* \
-		$(1)/usr/lib/
-endef
-
-define Package/libexslt/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libexslt.so.* \
-		$(1)/usr/lib/
-endef
-
-define Package/xsltproc/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) \
-		$(PKG_INSTALL_DIR)/usr/bin/xsltproc \
-		$(1)/usr/bin/
-endef
-
-$(eval $(call BuildPackage,libxslt))
-$(eval $(call BuildPackage,libexslt))
-$(eval $(call BuildPackage,xsltproc))
-

file:a/libs/tiff/Makefile (deleted)
--- a/libs/tiff/Makefile
+++ /dev/null
@@ -1,106 +1,1 @@
-#
-# Copyright (C) 2006-2012 OpenWrt.org
-#
-# This is free software, licensed under the GNU General Public License v2.
-# See /LICENSE for more information.
-#
-# blogic@openwrt.org
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=tiff
-PKG_VERSION:=4.0.3
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://download.osgeo.org/libtiff
-PKG_MD5SUM:=051c1068e6a0627f461948c365290410
-
-PKG_FIXUP:=autoreconf
-PKG_REMOVE_FILES:=autogen.sh aclocal.m4
-
-PKG_INSTALL:=1
-
-PKG_CONFIG_DEPENDS:=CONFIG_PACKAGE_libtiffxx
-
-include $(INCLUDE_DIR)/uclibc++.mk
-include $(INCLUDE_DIR)/package.mk
-
-define Package/tiff/Default
-  TITLE:=TIFF
-  URL:=http://www.remotesensing.org/libtiff/
-endef
-
-define Package/libtiff
-$(call Package/tiff/Default)
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE+= library
-  DEPENDS:=+zlib +libjpeg
-endef
-
-define Package/libtiffxx
-$(call Package/tiff/Default)
-  SECTION:=libs
-  CATEGORY:=Libraries
-  TITLE+= library(c++ bindings)
-  DEPENDS:=+libtiff $(CXX_DEPENDS)
-endef
-
-define Package/tiff-utils
-$(call Package/tiff/Default)
-  SECTION:=utils
-  CATEGORY:=Utilities
-  TITLE+= utilities
-  DEPENDS:=+libtiff
-endef
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-		$(if $(CONFIG_PACKAGE_libtiffxx), \
-			--enable-cxx, \
-			--disable-cxx \
-		) \
-		--disable-lzma \
-		--enable-ccitt \
-		--enable-packbits \
-		--enable-lzw \
-		--enable-thunder \
-		--enable-next \
-		--enable-logluv \
-		--enable-mdi \
-		--enable-zlib \
-		--enable-jpeg \
-		--disable-old-jpeg \
-		--disable-jbig \
-		--without-x \
-	)
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/{lib,include}
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib* $(1)/usr/lib/
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
-endef
-
-define Package/libtiff/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtiff.so.* $(1)/usr/lib/
-endef
-
-define Package/libtiffxx/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtiffxx.so.* $(1)/usr/lib/
-endef
-
-define Package/tiff-utils/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
-endef
-
-$(eval $(call BuildPackage,libtiff))
-$(eval $(call BuildPackage,libtiffxx))
-$(eval $(call BuildPackage,tiff-utils))
-

--- a/libs/tiff/patches/001-autoconf-compat.patch
+++ /dev/null
@@ -1,32 +1,1 @@
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -25,7 +25,7 @@
- 
- docdir = $(LIBTIFF_DOCDIR)
- 
--AUTOMAKE_OPTIONS = 1.12 dist-zip foreign
-+AUTOMAKE_OPTIONS = dist-zip foreign
- ACLOCAL_AMFLAGS = -I m4
- 
- docfiles = \
-@@ -48,7 +48,7 @@ EXTRA_DIST = \
- 
- dist_doc_DATA = $(docfiles)
- 
--SUBDIRS = port libtiff tools build contrib test man html
-+SUBDIRS = port libtiff tools build contrib
- 
- release:
- 	(rm -f $(top_srcdir)/RELEASE-DATE && echo $(LIBTIFF_RELEASE_DATE) > $(top_srcdir)/RELEASE-DATE)
---- a/test/Makefile.am
-+++ b/test/Makefile.am
-@@ -23,7 +23,7 @@
- 
- # Process this file with automake to produce Makefile.in.
- 
--AUTOMAKE_OPTIONS = 1.12 color-tests parallel-tests foreign
-+AUTOMAKE_OPTIONS = color-tests parallel-tests foreign
- 
- LIBTIFF = $(top_builddir)/libtiff/libtiff.la
- 
 

--- a/multimedia/ffmpeg/Config.in
+++ /dev/null
@@ -1,315 +1,1 @@
-menu "Configuration"
-	depends on PACKAGE_libffmpeg-custom
 
-config FFMPEG_CUSTOM_PATENTED
-	bool "Include patented codecs and technologies"
-	default BUILD_PATENTED
-
-comment "Profiles ---"
-
-config FFMPEG_CUSTOM_FFSERVER_SUPPORT
-	bool "Include support for ffserver (FFmpeg streaming server)"
-	select FFMPEG_CUSTOM_MUXER_ffm
-	select FFMPEG_CUSTOM_DEMUXER_ffm
-	select FFMPEG_CUSTOM_DEMUXER_rtsp
-	select FFMPEG_CUSTOM_PROTOCOL_rtp
-
-config FFMPEG_CUSTOM_LIBDLNA_SUPPORT
-	bool "Include support for libdlna/ushare"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_DECODER_ac3
-	select FFMPEG_CUSTOM_DECODER_atrac3
-	select FFMPEG_CUSTOM_DECODER_h264
-	select FFMPEG_CUSTOM_DECODER_jpegls
-	select FFMPEG_CUSTOM_DECODER_mp3
-	select FFMPEG_CUSTOM_DECODER_mpeg1video
-	select FFMPEG_CUSTOM_DECODER_mpeg2video
-	select FFMPEG_CUSTOM_DECODER_mpeg4
-	select FFMPEG_CUSTOM_DECODER_mpegvideo
-	select FFMPEG_CUSTOM_DECODER_wmav1
-	select FFMPEG_CUSTOM_DECODER_wmav2
-	select FFMPEG_CUSTOM_DECODER_png
-	select FFMPEG_CUSTOM_DEMUXER_ac3
-	select FFMPEG_CUSTOM_DEMUXER_h264
-	select FFMPEG_CUSTOM_DEMUXER_mp3
-	select FFMPEG_CUSTOM_DEMUXER_mpegvideo
-
-config FFMPEG_CUSTOM_MINIDLNA_SUPPORT
-	bool "Include support for minidlna"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_DECODER_aac
-	select FFMPEG_CUSTOM_DECODER_ac3
-	select FFMPEG_CUSTOM_DECODER_flac
-	select FFMPEG_CUSTOM_DECODER_h264
-	select FFMPEG_CUSTOM_DECODER_jpegls
-	select FFMPEG_CUSTOM_DECODER_mp3
-	select FFMPEG_CUSTOM_DECODER_mpeg1video
-	select FFMPEG_CUSTOM_DECODER_mpeg2video
-	select FFMPEG_CUSTOM_DECODER_mpeg4
-	select FFMPEG_CUSTOM_DECODER_mpegvideo
-	select FFMPEG_CUSTOM_DECODER_wmav1
-	select FFMPEG_CUSTOM_DECODER_wmav2
-	select FFMPEG_CUSTOM_DECODER_png
-	select FFMPEG_CUSTOM_DEMUXER_aac
-	select FFMPEG_CUSTOM_DEMUXER_ac3
-	select FFMPEG_CUSTOM_DEMUXER_avi
-	select FFMPEG_CUSTOM_DEMUXER_flac
-	select FFMPEG_CUSTOM_DEMUXER_h264
-	select FFMPEG_CUSTOM_DEMUXER_matroska
-	select FFMPEG_CUSTOM_DEMUXER_mov
-	select FFMPEG_CUSTOM_DEMUXER_mp3
-	select FFMPEG_CUSTOM_DEMUXER_mpegvideo
-	select FFMPEG_CUSTOM_PROTOCOL_file
-
-comment "Encoders ---"
-
-config FFMPEG_CUSTOM_ENCODER_ac3
-	bool "AC3"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_PARSER_ac3
-
-config FFMPEG_CUSTOM_ENCODER_jpegls
-	bool "JPEG-LS"
-
-config FFMPEG_CUSTOM_ENCODER_mpeg1video
-	bool "MPEG-1 Video"
-
-config FFMPEG_CUSTOM_ENCODER_mpeg2video
-	bool "MPEG-2 Video"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_ENCODER_mpeg4
-	bool "MPEG-4"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_ENCODER_pcm_s16be
-	bool "PCM signed 16-bit big-endian"
-
-config FFMPEG_CUSTOM_ENCODER_pcm_s16le
-	bool "PCM signed 16-bit little-endian"
-
-config FFMPEG_CUSTOM_ENCODER_png
-	bool "PNG"
-	select FFMPEG_CUSTOM_ENCODER_zlib
-
-config FFMPEG_CUSTOM_ENCODER_vorbis
-	bool "Vorbis"
-
-config FFMPEG_CUSTOM_ENCODER_zlib
-	bool "Zlib"
-
-comment "Decoders ---"
-
-config FFMPEG_CUSTOM_DECODER_aac
-	bool "AAC (Advanced Audio Coding)"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_PARSER_aac
-
-config FFMPEG_CUSTOM_DECODER_ac3
-	bool "AC3"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_PARSER_ac3
-
-config FFMPEG_CUSTOM_DECODER_atrac3
-	bool "ATRAC3"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_flac
-	bool "FLAC"
-
-config FFMPEG_CUSTOM_DECODER_gif
-	bool "GIF"
-
-config FFMPEG_CUSTOM_DECODER_h264
-	bool "H.264"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_jpegls
-	bool "JPEG-LS"
-
-config FFMPEG_CUSTOM_DECODER_mp2
-	bool "MP2 (MPEG Audio Layer 2)"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_mp3
-	bool "MP3 (MPEG Audio Layer 2)"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_mpegvideo
-	bool "MPEG Video"
-
-config FFMPEG_CUSTOM_DECODER_mpeg1video
-	bool "MPEG-1 Video"
-
-config FFMPEG_CUSTOM_DECODER_mpeg2video
-	bool "MPEG-2 Video"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_mpeg4
-	bool "MPEG-4"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_pcm_s16be
-	bool "PCM signed 16-bit big-endian"
-
-config FFMPEG_CUSTOM_DECODER_pcm_s16le
-	bool "PCM signed 16-bit little-endian"
-
-config FFMPEG_CUSTOM_DECODER_png
-	bool "PNG"
-	select FFMPEG_CUSTOM_DECODER_zlib
-
-config FFMPEG_CUSTOM_DECODER_vorbis
-	bool "Vorbis"
-
-config FFMPEG_CUSTOM_DECODER_wmav1
-	bool "WMAv1"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_wmav2
-	bool "WMAv2"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DECODER_zlib
-	bool "Zlib"
-
-comment "Muxers ---"
-
-config FFMPEG_CUSTOM_MUXER_ac3
-	bool "AC3"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_MUXER_ffm
-	bool "FFM (ffserver live feed)"
-
-config FFMPEG_CUSTOM_MUXER_h264
-	bool "H.264"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_MUXER_mp3
-	bool "MP3 (MPEG Audio Layer 3)"
-
-config FFMPEG_CUSTOM_MUXER_mp4
-	bool "MP4"
-
-config FFMPEG_CUSTOM_MUXER_mpeg1video
-	bool "MPEG-1 Video"
-
-config FFMPEG_CUSTOM_MUXER_mpeg2video
-	bool "MPEG-2 Video"
-
-config FFMPEG_CUSTOM_MUXER_mpegts
-	bool "MPEG-2 (TS)"
-
-config FFMPEG_CUSTOM_MUXER_ogg
-	bool "Ogg"
-
-config FFMPEG_CUSTOM_MUXER_rtp
-	bool "RTP"
-
-comment "Demuxers ---"
-
-config FFMPEG_CUSTOM_DEMUXER_aac
-	bool "AAC"
-
-config FFMPEG_CUSTOM_DEMUXER_avi
-	bool "AVI (Audio Video Interleave)"
-
-config FFMPEG_CUSTOM_DEMUXER_ac3
-	bool "AC3"
-
-config FFMPEG_CUSTOM_DEMUXER_flac
-	bool "FLAC"
-
-config FFMPEG_CUSTOM_DEMUXER_ffm
-	bool "FFM (ffserver live feed)"
-
-config FFMPEG_CUSTOM_DEMUXER_h264
-	bool "H.264"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_DEMUXER_matroska
-	bool "Matroska (MKA,MKV)"
-	select FFMPEG_CUSTOM_DECODER_zlib
-
-config FFMPEG_CUSTOM_DEMUXER_mov
-	bool "MOV/MP4/M4A/3GP/3G2/MJ2"
-	select FFMPEG_CUSTOM_DECODER_zlib
-
-config FFMPEG_CUSTOM_DEMUXER_mp3
-	bool "MP3 (MPEG Audio Layer 3)"
-	select FFMPEG_CUSTOM_PARSER_mpegaudio
-
-config FFMPEG_CUSTOM_DEMUXER_mpegvideo
-	bool "MPEG Video"
-
-config FFMPEG_CUSTOM_DEMUXER_mpegps
-	bool "MPEG-2 (PS)"
-
-config FFMPEG_CUSTOM_DEMUXER_mpegts
-	bool "MPEG-2 (TS)"
-
-config FFMPEG_CUSTOM_DEMUXER_ogg
-	bool "Ogg"
-
-config FFMPEG_CUSTOM_DEMUXER_rm
-	bool "RM"
-	help
-	  RealMedia format demuxer
-
-config FFMPEG_CUSTOM_DEMUXER_rtsp
-	bool "RTSP"
-	select FFMPEG_CUSTOM_DEMUXER_rm
-	select FFMPEG_CUSTOM_DEMUXER_sdp
-
-config FFMPEG_CUSTOM_DEMUXER_sdp
-	bool "SDP"
-	select FFMPEG_CUSTOM_DEMUXER_mpegts
-
-comment "Parsers ---"
-
-config FFMPEG_CUSTOM_PARSER_aac
-	bool "AAC (Advanced Audio Coding)"
-	depends on FFMPEG_CUSTOM_PATENTED
-
-config FFMPEG_CUSTOM_PARSER_ac3
-	bool "AC3"
-
-config FFMPEG_CUSTOM_PARSER_h264
-	bool "H.264"
-	depends on FFMPEG_CUSTOM_PATENTED
-	select FFMPEG_CUSTOM_DECODER_h264
-
-config FFMPEG_CUSTOM_PARSER_mpegaudio
-	bool "MPEG Audio"
-
-config FFMPEG_CUSTOM_PARSER_mpegvideo
-	bool "MPEG Video"
-
-config FFMPEG_CUSTOM_PARSER_mpeg4video
-	bool "MPEG-4 Video"
-
-comment "Protocols ---"
-
-config FFMPEG_CUSTOM_PROTOCOL_file
-	bool "file:"
-
-config FFMPEG_CUSTOM_PROTOCOL_http
-	bool "http:"
-
-config FFMPEG_CUSTOM_PROTOCOL_pipe
-	bool "pipe:"
-
-config FFMPEG_CUSTOM_PROTOCOL_rtp
-	bool "rtp:"
-	select FFMPEG_CUSTOM_PROTOCOL_udp
-
-config FFMPEG_CUSTOM_PROTOCOL_tcp
-	bool "tcp:"
-
-config FFMPEG_CUSTOM_PROTOCOL_udp
-	bool "udp:"
-
-endmenu
-
-

--- a/multimedia/ffmpeg/Makefile
+++ /dev/null
@@ -1,437 +1,1 @@
-#
-# 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:=ffmpeg
-PKG_VERSION:=0.11.5
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=http://ffmpeg.org/releases/
-PKG_MD5SUM:=ea25fc252c132141f12988ed5506bfe8
-
-PKG_LICENSE:=LGPLv2.1+ GPLv2+ LGPLv3
-PKG_LICENSE_FILES:=COPYING.GPLv2 COPYING.GPLv3 COPYING.LGPLv2.1 COPYING.LGPLv3
-
-FFMPEG_CUSTOM_ENCODERS:= \
-	ac3 \
-	jpegls \
-	mpeg1video \
-	mpeg2video \
-	mpeg4 \
-	pcm_s16be \
-	pcm_s16le \
-	png \
-	vorbis \
-	zlib \
-
-FFMPEG_CUSTOM_DECODERS:= \
-	aac \
-	ac3 \
-	atrac3 \
-	flac \
-	gif \
-	h264 \
-	jpegls \
-	mp2 \
-	mp3 \
-	mpeg1video \
-	mpeg2video \
-	mpeg4 \
-	mpegvideo \
-	pcm_s16be \
-	pcm_s16le \
-	png \
-	vorbis \
-	wmav1 \
-	wmav2 \
-	zlib \
-
-FFMPEG_CUSTOM_MUXERS:= \
-	ac3 \
-	ffm \
-	h264 \
-	mp3 \
-	mp4 \
-	mpeg1video \
-	mpeg2video \
-	mpegts \
-	ogg \
-	rtp \
-
-FFMPEG_CUSTOM_DEMUXERS:= \
-	aac \
-	ac3 \
-	avi \
-	flac \
-	ffm \
-	h264 \
-	matroska \
-	mov \
-	mp3 \
-	mpegps \
-	mpegts \
-	mpegvideo \
-	ogg \
-	rm \
-	rtsp \
-	sdp \
-	v4l2 \
-
-FFMPEG_CUSTOM_PARSERS:= \
-	aac \
-	ac3 \
-	h264 \
-	mpegaudio \
-	mpeg4video \
-	mpegvideo \
-
-FFMPEG_CUSTOM_PROTOCOLS:= \
-	file http pipe rtp tcp udp
-
-FFMPEG_MINI_ENCODERS:= \
-
-FFMPEG_MINI_DECODERS:= \
-	aac \
-	ac3 \
-	atrac3 \
-	flac \
-	h263 \
-	h264 \
-	jpegls \
-	mp3 \
-	mpeg1video \
-	mpeg2video \
-	mpeg4 \
-	mpegvideo \
-	png \
-	wmav1 \
-	wmav2 \
-
-FFMPEG_MINI_MUXERS:= \
-	ffm \
-
-FFMPEG_MINI_DEMUXERS := \
-	aac \
-	ac3 \
-	asf \
-	avi \
-	ffm \
-	flac \
-	h264 \
-	matroska \
-	mov \
-	mp3 \
-	mpegts \
-	mpegvideo \
-	rtsp \
-
-FFMPEG_MINI_PARSERS:= \
-	ac3 \
-	flac \
-	h263 \
-	h264 \
-	mpeg4video \
-	mpegaudio \
-
-FFMPEG_MINI_PROTOCOLS := \
-	file http rtp tcp udp \
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
-
-PKG_CONFIG_DEPENDS:= \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_ENCODER_%,$(FFMPEG_CUSTOM_ENCODERS)) \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_DECODER_%,$(FFMPEG_CUSTOM_DECODERS)) \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_MUXER_%,$(FFMPEG_CUSTOM_DEMUXERS)) \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_DEMUXER_%,$(FFMPEG_CUSTOM_DEMUXERS)) \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_PARSER_%,$(FFMPEG_CUSTOM_PARSERS)) \
-	$(patsubst %,CONFIG_FFMPEG_CUSTOM_PROTOCOL_%,$(FFMPEG_CUSTOM_PROTOCOLS))
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/ffmpeg/Default
- TITLE:=FFmpeg
- URL:=http://ffmpeg.mplayerhq.hu/
-endef
-
-define Package/ffmpeg/Default/description
- FFmpeg is a a software package that can record, convert and stream digital
- audio and video in numerous formats.
-endef
-
-
-define Package/ffmpeg
-$(call Package/ffmpeg/Default)
- SECTION:=multimedia
- CATEGORY:=Multimedia
- TITLE+= program
- DEPENDS+= +libpthread +libffmpeg-full
- VARIANT:=full
-endef
-
-define Package/ffmpeg/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains the FFmpeg command line tool.
-endef
-
-
-define Package/ffprobe
-$(call Package/ffmpeg/Default)
- SECTION:=multimedia
- CATEGORY:=Multimedia
- TITLE+= CLI media identifier
- DEPENDS+= +libffmpeg-full
- VARIANT:=full
-endef
-
-define Package/ffprobe/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains the FFprobe command line tool.
-endef
-
-
-define Package/ffserver
-$(call Package/ffserver/Default)
- SECTION:=multimedia
- CATEGORY:=Multimedia
- TITLE+= streaming server
- DEPENDS+= +libpthread +libffmpeg-full
- VARIANT:=full
-endef
-
-define Package/ffserver/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains the FFmpeg streaming server.
-endef
-
-
-define Package/libffmpeg/Default
-$(call Package/ffmpeg/Default)
- SECTION:=libs
- CATEGORY:=Libraries
- TITLE+= libraries
- DEPENDS+= +libpthread +zlib +libbz2
- PROVIDES:= libffmpeg
-endef
-
-
-define Package/libffmpeg-custom
-$(call Package/libffmpeg/Default)
- TITLE+= (mini)
- DEPENDS+= @DEVEL
- VARIANT:=custom
- MENU:=1
-endef
-
-define Package/libffmpeg-custom/config
-source "$(SOURCE)/Config.in"
-endef
-
-define Package/libffmpeg-custom/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains customized FFmpeg shared libraries.
-endef
-
-
-define Package/libffmpeg-full
-$(call Package/libffmpeg/Default)
- TITLE+= (full)
- DEPENDS+= @BUILD_PATENTED +alsa-lib
- VARIANT:=full
-endef
-
-define Package/libffmpeg-full/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains full-featured FFmpeg shared libraries.
-endef
-
-
-define Package/libffmpeg-mini
-$(call Package/libffmpeg/Default)
- TITLE+= (mini)
- DEPENDS+= @BUILD_PATENTED
- VARIANT:=mini
-endef
-
-define Package/libffmpeg-mini/description
-$(call Package/ffmpeg/Default/description)
- .
- This package contains minimal-featured FFmpeg shared libraries.
-endef
-
-
-FFMPEG_CONFIGURE:= \
-	CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) $(FPIC)" \
-	LDFLAGS="$(TARGET_LDFLAGS)" \
-	./configure \
-	--enable-cross-compile \
-	--cross-prefix="$(TARGET_CROSS)" \
-	--arch="$(ARCH)" \
-	--target-os=linux \
-	--prefix="/usr" \
-	--enable-shared \
-	--enable-static \
-	--disable-debug \
-	--pkg-config="pkg-config" \
-	\
-	--enable-gpl \
-	--enable-version3 \
-	\
-	--disable-altivec \
-	--disable-asm \
-	--disable-doc \
-	--disable-dxva2 \
-	--enable-pthreads \
-	--enable-small \
-	--disable-stripping \
-	--enable-zlib \
-	--disable-outdevs
-
-ifeq ($(BUILD_VARIANT),custom)
-
-  FFMPEG_ENABLE= \
-	$(foreach c, $(2), \
-		$(if $($(3)_$(c)),--enable-$(1)="$(c)") \
-	)
-
-  FFMPEG_CONFIGURE+= \
-	--disable-ffmpeg \
-	--disable-ffplay \
-	--disable-ffprobe \
-	--disable-ffserver \
-	--disable-avfilter \
-	--disable-postproc \
-	--disable-swresample \
-	--disable-swscale \
-	--disable-everything \
-	$(call FFMPEG_ENABLE,encoder,$(FFMPEG_CUSTOM_ENCODERS),CONFIG_FFMPEG_CUSTOM_ENCODER) \
-	$(call FFMPEG_ENABLE,decoder,$(FFMPEG_CUSTOM_DECODERS),CONFIG_FFMPEG_CUSTOM_DECODER) \
-	$(call FFMPEG_ENABLE,muxer,$(FFMPEG_CUSTOM_MUXERS),CONFIG_FFMPEG_CUSTOM_MUXER) \
-	$(call FFMPEG_ENABLE,demuxer,$(FFMPEG_CUSTOM_DEMUXERS),CONFIG_FFMPEG_CUSTOM_DEMUXER) \
-	$(call FFMPEG_ENABLE,parser,$(FFMPEG_CUSTOM_PARSERS),CONFIG_FFMPEG_CUSTOM_PARSER) \
-	$(call FFMPEG_ENABLE,protocol,$(FFMPEG_CUSTOM_PROTOCOLS),CONFIG_FFMPEG_CUSTOM_PROTOCOL) \
-
-endif
-
-ifeq ($(BUILD_VARIANT),mini)
-
-  FFMPEG_ENABLE= \
-	$(foreach c, $(2), \
-		--enable-$(1)="$(c)" \
-	)
-
-  FFMPEG_CONFIGURE+= \
-	--disable-ffmpeg \
-	--disable-ffplay \
-	--disable-ffprobe \
-	--disable-ffserver \
-	--disable-avfilter \
-	--disable-postproc \
-	--disable-swresample \
-	--disable-swscale \
-	--disable-everything \
-	$(call FFMPEG_ENABLE,encoder,$(FFMPEG_MINI_ENCODERS)) \
-	$(call FFMPEG_ENABLE,decoder,$(FFMPEG_MINI_DECODERS)) \
-	$(call FFMPEG_ENABLE,muxer,$(FFMPEG_MINI_MUXERS)) \
-	$(call FFMPEG_ENABLE,demuxer,$(FFMPEG_MINI_DEMUXERS)) \
-	$(call FFMPEG_ENABLE,parser,$(FFMPEG_MINI_PARSERS)) \
-	$(call FFMPEG_ENABLE,protocol,$(FFMPEG_MINI_PROTOCOLS)) \
-
-endif
-
-ifneq ($(CONFIG_TARGET_x86),)
-  TARGET_CFLAGS += -fomit-frame-pointer
-endif
-
-define Build/Configure
-	( cd $(PKG_BUILD_DIR); $(FFMPEG_CONFIGURE) )
-endef
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		DESTDIR="$(PKG_INSTALL_DIR)" \
-		all install
-endef
-
-define Build/InstallDev/custom
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/lib{avcodec,avdevice,avformat,avutil} $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{avcodec,avdevice,avformat,avutil}.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/lib{avcodec,avdevice,avformat,avutil}.pc $(1)/usr/lib/pkgconfig/
-endef
-
-define Build/InstallDev/full
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include/lib{avcodec,avdevice,avfilter,avformat,avutil,postproc,swresample,swscale} $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{avcodec,avdevice,avfilter,avformat,avutil,postproc,swresample,swscale}.{a,so*} $(1)/usr/lib/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/lib{avcodec,avdevice,avfilter,avformat,avutil,postproc,swresample,swscale}.pc $(1)/usr/lib/pkgconfig/
-endef
-
-Build/InstallDev/mini = $(Build/InstallDev/custom)
-
-# XXX: attempt at installing "best" dev files available
-ifeq ($(BUILD_VARIANT),custom)
-  # XXX: only install "custom" dev files if -full & -mini are not selected
-  ifeq ($(CONFIG_PACKAGE_libffmpeg-full)$(CONFIG_PACKAGE_libffmpeg-mini),)
-    Build/InstallDev = $(Build/InstallDev/custom)
-  endif
-endif
-ifeq ($(BUILD_VARIANT),full)
-  # XXX: always install "full" dev files if -full is selected
-  Build/InstallDev = $(Build/InstallDev/full)
-endif
-ifeq ($(BUILD_VARIANT),mini)
-  # XXX: only install "mini" dev files if -full is not selected
-  ifeq ($(CONFIG_PACKAGE_libffmpeg-full),)
-    Build/InstallDev = $(Build/InstallDev/mini)
-  endif
-endif
-
-define Package/ffmpeg/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/ffmpeg $(1)/usr/bin/
-endef
-
-define Package/ffprobe/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/ffprobe $(1)/usr/bin/
-endef
-
-define Package/ffserver/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/ffserver $(1)/usr/bin/
-endef
-
-define Package/libffmpeg-custom/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{avcodec,avdevice,avformat,avutil}.so.* $(1)/usr/lib/
-endef
-
-define Package/libffmpeg-full/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{avcodec,avdevice,avfilter,avformat,avutil,postproc,swresample,swscale}.so.* $(1)/usr/lib/
-endef
-
-Package/libffmpeg-mini/install = $(Package/libffmpeg-custom/install)
-
-$(eval $(call BuildPackage,ffmpeg))
-$(eval $(call BuildPackage,ffprobe))
-$(eval $(call BuildPackage,ffserver))
-$(eval $(call BuildPackage,libffmpeg-custom))
-$(eval $(call BuildPackage,libffmpeg-full))
-$(eval $(call BuildPackage,libffmpeg-mini))
-

--- a/multimedia/icecast/Makefile
+++ /dev/null
@@ -1,92 +1,1 @@
-#
-# 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:=icecast
-PKG_VERSION:=2.3.2
-PKG_RELEASE:=4
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://downloads.us.xiph.org/releases/icecast/
-PKG_MD5SUM:=ff516b3ccd2bcc31e68f460cd316093f
-
-PKG_FIXUP:=autoreconf
-
-include $(INCLUDE_DIR)/package.mk
-
-TREMOR_BUILD_DIR=$(PKG_BUILD_DIR)/libvorbisidec-1.2.0-dave
-TREMOR_DIR=$(TREMOR_BUILD_DIR)/ipkg-install/usr
-
-define Package/icecast
-  SECTION:=multimedia
-  CATEGORY:=Multimedia
-  DEPENDS:=+libcurl +libxml2 +libxslt +libogg +libopenssl
-  TITLE:=A streaming media server for Ogg/Vorbis and MP3 audio streams
-  URL:=http://www.icecast.org/
-endef
-
-define Package/icecast/description
-	Icecast is a streaming media server which currently supports Ogg
-	Vorbis and MP3 audio streams. It can be used to create an Internet
-	radio station or a privately running jukebox and many things in
-	between. It is very versatile in that new formats can be added
-	relatively easily and supports open standards for commuincation and
-	interaction.
-endef
-
-define Build/Prepare
-	$(Build/Prepare/Default)
-	$(SUBMAKE) -f libvorbisidec.mk \
-		BUILD_DIR="$(PKG_BUILD_DIR)" \
-		V=99 \
-		prepare
-endef
-
-define Build/Configure
-	$(MAKE) -f libvorbisidec.mk \
-		BUILD_DIR="$(PKG_BUILD_DIR)" \
-		V=99 \
-		compile
-	$(SED) 's,-lvorbis ,$(TREMOR_DIR)/lib/libvorbisidec.a -logg ,g' $(PKG_BUILD_DIR)/configure
-	$(call Build/Configure/Default, \
-		--enable-yp \
-		--with-curl="yes" \
-		--with-curl-config="$(STAGING_DIR)/usr/bin/curl-config" \
-		--with-ogg="$(STAGING_DIR)/usr" \
-		--with-speex="no" \
-		--with-theora="no" \
-		--with-vorbis="$(TREMOR_DIR)" \
-		--with-xslt-config="$(STAGING_DIR)/usr/bin/xslt-config" \
-		, \
-		CPPFLAGS="-I$(TREMOR_DIR)/include -I$(STAGING_DIR)/usr/include/libxml2 $(TARGET_CPPFLAGS)" \
-	)
-endef
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		DESTDIR="$(PKG_INSTALL_DIR)" \
-		INCLUDES="-I$(PKG_BUILD_DIR)/src -I$(TREMOR_DIR)/include" \
-		all install
-endef
-
-define Package/icecast/install
-	$(INSTALL_DIR) $(1)/etc
-	$(CP) $(PKG_INSTALL_DIR)/etc/icecast.xml $(1)/etc/
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/icecast $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/usr/share/icecast
-	$(CP) $(PKG_INSTALL_DIR)/usr/share/icecast/admin $(1)/usr/share/icecast/
-	$(CP) $(PKG_INSTALL_DIR)/usr/share/icecast/web $(1)/usr/share/icecast/
-endef
-
-define Package/icecast/conffiles
-/etc/icecast.xml
-endef
-
-$(eval $(call BuildPackage,icecast))
-

--- a/multimedia/icecast/libvorbisidec.mk
+++ /dev/null
@@ -1,42 +1,1 @@
-# 
-# Copyright (C) 2006 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:=icecast-libvorbisidec
-PKG_VERSION:=1.2.0-dave
-PKG_RELEASE:=1
-
-PKG_SOURCE:=libvorbisidec-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://users.tpg.com.au/davico/openwrt/
-PKG_MD5SUM:=cb8e51aab92ef164f8e0e8853f7164fa
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/libvorbisidec-$(PKG_VERSION)
-PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
-PATCH_DIR=./patches-libvorbisidec
-
-include $(INCLUDE_DIR)/package.mk
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-		--disable-shared \
-		--enable-static \
-	)
-endef
-
-define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		DESTDIR="$(PKG_INSTALL_DIR)" \
-		all install
-endef
-
-define Build/InstallDev
-	true
-endef
-
-$(eval $(call Build/DefaultTargets))
-

--- a/multimedia/icecast/patches/001-icecast-2.3.0-tremor.patch
+++ /dev/null
@@ -1,156 +1,1 @@
---- a/src/format_flac.c
-+++ b/src/format_flac.c
-@@ -18,7 +18,7 @@
- #endif
- 
- #include <stdlib.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include <string.h>
- 
- typedef struct source_tag source_t;
---- a/src/format_midi.c
-+++ b/src/format_midi.c
-@@ -18,7 +18,7 @@
- #endif
- 
- #include <stdlib.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include <string.h>
- 
- typedef struct source_tag source_t;
---- a/src/format_ogg.c
-+++ b/src/format_ogg.c
-@@ -24,7 +24,7 @@
- #include <stdlib.h>
- #include <string.h>
- 
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- 
- #include "refbuf.h"
- #include "source.h"
---- a/src/format_ogg.h
-+++ b/src/format_ogg.h
-@@ -18,7 +18,7 @@
- #ifndef __FORMAT_OGG_H__
- #define __FORMAT_OGG_H__
- 
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include "refbuf.h"
- #include "format.h"
- 
---- a/src/format_speex.c
-+++ b/src/format_speex.c
-@@ -18,7 +18,7 @@
- #endif
- 
- #include <stdlib.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include <speex/speex_header.h>
- 
- typedef struct source_tag source_t;
---- a/src/format_theora.c
-+++ b/src/format_theora.c
-@@ -18,7 +18,7 @@
- #endif
- 
- #include <stdlib.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include <theora/theora.h>
- 
- typedef struct source_tag source_t;
---- a/src/format_vorbis.c
-+++ b/src/format_vorbis.c
-@@ -18,8 +18,8 @@
- #endif
- 
- #include <stdlib.h>
--#include <ogg/ogg.h>
--#include <vorbis/codec.h>
-+#include <tremor/ogg.h>
-+#include <tremor/ivorbiscodec.h>
- #include <memory.h>
- #include <string.h>
- 
---- a/src/source.c
-+++ b/src/source.c
-@@ -19,7 +19,7 @@
- #include <stdlib.h>
- #include <string.h>
- #include <sys/types.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #include <errno.h>
- 
- #ifndef _WIN32
---- a/src/format_kate.c
-+++ b/src/format_kate.c
-@@ -19,7 +19,7 @@
- 
- #include <stdlib.h>
- #include <string.h>
--#include <ogg/ogg.h>
-+#include <tremor/ogg.h>
- #ifdef HAVE_KATE
- #include <kate/oggkate.h>
- #endif
---- a/m4/vorbis.m4
-+++ b/m4/vorbis.m4
-@@ -38,9 +38,9 @@ if test "x$vorbis_prefix" != "x$ogg_pref
-             ])
- fi
- 
--VORBIS_LIBS="-lvorbis"
--VORBISFILE_LIBS="-lvorbisfile"
--VORBISENC_LIBS="-lvorbisenc"
-+VORBIS_LIBS="-lvorbisidec"
-+VORBISFILE_LIBS="-lvorbisidec"
-+VORBISENC_LIBS="-lvorbisidec"
- 
- xt_save_LIBS="$LIBS"
- xt_save_LDFLAGS="$LDFLAGS"
-@@ -58,18 +58,6 @@ AC_TRY_LINK_FUNC(ogg_stream_init, [xt_li
-             )
-         ])
- 
--if test "x$xt_lib_vorbis" = "xok"; then
--#
--# Now check if the installed Vorbis is sufficiently new.
--#
--AC_COMPILE_IFELSE([AC_LANG_PROGRAM([
--#include <vorbis/codec.h>
--#include <vorbis/vorbisenc.h>
--        ], [
--struct ovectl_ratemanage_arg a;
--])],,[xt_lib_vorbis="old version found"])
--AC_MSG_RESULT([$xt_lib_vorbis])
--fi
- CPPFLAGS="$xt_save_CPPFLAGS"
- LIBS="$xt_save_LIBS"
- LDFLAGS="$xt_save_LDFLAGS"
---- a/m4/ogg.m4
-+++ b/m4/ogg.m4
-@@ -29,7 +29,7 @@ XIPH_GCC_WARNING([-I$ogg_prefix/include]
-       ])
- AC_CACHE_CHECK([for libogg], xt_cv_lib_ogg,
- [dnl
--OGG_LIBS="-logg"
-+OGG_LIBS="-lvorbisidec"
- 
- #
- # check if the installed Ogg is sufficiently new.
-@@ -42,7 +42,7 @@ LIBS="$LIBS $OGG_LIBS"
- LDFLAGS="$LDFLAGS $OGG_LDFLAGS"
- AC_TRY_LINK_FUNC(ogg_sync_init,
-     [ xt_cv_lib_ogg=ok ],
--    [ AC_TRY_LINK([#include <ogg/ogg.h>],, 
-+    [ AC_TRY_LINK([#include <tremor/ogg.h>],, 
-         [ xt_cv_lib_ogg="pre v1.0, needs updating" ],
-         [ xt_cv_lib_ogg="not found" ])
-     ])
 

--- a/multimedia/icecast/patches/010-fix_libcurl_test_crap.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- a/m4/xiph_curl.m4
-+++ b/m4/xiph_curl.m4
-@@ -52,7 +52,7 @@ AC_CHECK_HEADERS([curl/curl.h],, curl_ok
- AC_MSG_CHECKING(for libcurl)
- if test "$curl_ok" = "yes"
- then
--    AC_RUN_IFELSE(AC_LANG_SOURCE([
-+    AC_COMPILE_IFELSE(AC_LANG_SOURCE([
- #include <curl/curl.h>
- int main()
- {
 

--- a/multimedia/minidlna/Makefile
+++ /dev/null
@@ -1,92 +1,1 @@
-#
-# Copyright (C) 2010-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:=minidlna
-PKG_VERSION:=1.0.25
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION)_src.tar.gz
-PKG_SOURCE_URL:=@SF/minidlna
-PKG_MD5SUM:=d966256baf2f9b068b9de871ab5dade5
-
-PKG_BUILD_PARALLEL:=0
-PKG_BUILD_DEPENDS:=util-linux
-
-include $(INCLUDE_DIR)/kernel.mk
-include $(INCLUDE_DIR)/package.mk
-include $(INCLUDE_DIR)/nls.mk
-
-define Package/minidlna
-  SECTION:=multimedia
-  CATEGORY:=Multimedia
-  TITLE:=UPnP A/V & DLNA Media Server
-  URL:=http://minidlna.sourceforge.net/
-  DEPENDS:= +libpthread +libexif +libjpeg +libsqlite3 +libffmpeg \
-  	+libid3tag +libflac +libvorbis +libuuid \
-  	$(ICONV_DEPENDS) $(INTL_DEPENDS)
-endef
-
-define Package/minidlna/description
-  MiniDLNA (aka ReadyDLNA) is server software with the aim of
-  being fully compliant with DLNA/UPnP-AV clients.
-endef
-
-define Package/minidlna/conffiles
-/etc/minidlna.conf
-endef
-
-TARGET_CPPFLAGS += \
-	-I$(STAGING_DIR)/usr/include \
-	-I$(STAGING_DIR)/usr/include/FLAC \
-	-I$(STAGING_DIR)/usr/include/libavcodec \
-	-I$(STAGING_DIR)/usr/include/libavformat \
-	-I$(STAGING_DIR)/usr/include/libavutil \
-	-I$(STAGING_DIR)/usr/include/libexif \
-	-I$(STAGING_DIR)/usr/include/uuid \
-	-I$(STAGING_DIR)/usr/include/vorbis \
-	-I$(ICONV_PREFIX)/include \
-	-I$(INTL_PREFIX)/include \
-	-D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 \
-
-TARGET_LDFLAGS += \
-	-L$(ICONV_PREFIX)/lib \
-	-L$(INTL_PREFIX)/lib \
-	-Wl,-rpath-link=$(STAGING_DIR)/usr/lib \
-
-MAKE_FLAGS +=\
-	CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
-	LDFLAGS="$(TARGET_LDFLAGS)" \
-	ICONV_LIBS="-liconv $(if $(INTL_FULL),-lintl)" \
-
-MAKE_VARS +=\
-	PREFIX="$(STAGING_DIR)/usr" \
-	ICONV_PREFIX="$(ICONV_PREFIX)" \
-	INTL_PREFIX="$(INTL_PREFIX)" \
-	OS_NAME="OpenWrt Linux" \
-	OS_VERSION="$(LINUX_VERSION)" \
-	OS_URL="http://openwrt.org/" \
-	DB_PATH="/var/run/minidlna" \
-	LOG_PATH="/var/log" \
-
-
-define Package/minidlna/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/minidlna $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/minidlna.init $(1)/etc/init.d/minidlna
-	$(INSTALL_DIR) $(1)/etc/config
-	$(INSTALL_CONF) ./files/minidlna.config $(1)/etc/config/minidlna
-endef
-
-define Package/minidlna/conffiles
-/etc/config/minidlna
-endef
-
-$(eval $(call BuildPackage,minidlna))
-

--- a/multimedia/minidlna/files/minidlna.config
+++ /dev/null
@@ -1,18 +1,1 @@
-config minidlna config
-	option 'enabled' '0'
-	option port '8200'
-	option interface 'br-lan'
-	option friendly_name 'OpenWrt DLNA Server'
-	option db_dir '/var/run/minidlna'
-	option log_dir '/var/log'
-	option inotify '1'
-	option enable_tivo '0'
-	option strict_dlna '0'
-	option presentation_url ''
-	option notify_interval '900'
-	option serial '12345678'
-	option model_number '1'
-	option root_container '.'
-	list media_dir '/mnt'
-	option album_art_names 'Cover.jpg/cover.jpg/AlbumArtSmall.jpg/albumartsmall.jpg/AlbumArt.jpg/albumart.jpg/Album.jpg/album.jpg/Folder.jpg/folder.jpg/Thumb.jpg/thumb.jpg'
 

--- a/multimedia/minidlna/files/minidlna.init
+++ /dev/null
@@ -1,97 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2010 OpenWrt.org
 
-START=50
-
-SERVICE_USE_PID=1
-
-MINIDLNA_CONFIG_FILE="/tmp/minidlna.conf"
-
-minidlna_cfg_append() {
-	echo "$1" >> "$MINIDLNA_CONFIG_FILE"
-}
-
-minidlna_cfg_addbool() {
-	local cfg="$1"
-	local key="$2"
-	local def="$3"
-	local val
-
-	config_get_bool val "$cfg" "$key" "$def"
-	[ "$val" -gt 0 ] && val="yes" || val="no"
-	minidlna_cfg_append "$key=$val"
-}
-
-minidlna_cfg_addstr() {
-	local cfg="$1"
-	local key="$2"
-	local def="$3"
-	local val
-
-	config_get val "$cfg" "$key" "$def"
-	[ -n "$val" ] && minidlna_cfg_append "$key=$val"
-}
-
-minidlna_cfg_add_media_dir() {
-	local val=$1
-
-	minidlna_cfg_append "media_dir=$val"
-}
-
-minidlna_create_config() {
-	local cfg=$1
-	local port
-	local interface
-
-	config_get port $cfg port
-	config_get interface $cfg interface
-
-	[ -z "$interface" -o -t "$port" ] && return 1
-
-	echo "# this file is generated automatically, don't edit" > "$MINIDLNA_CONFIG_FILE"
-
-	minidlna_cfg_append "port=$port"
-	minidlna_cfg_append "network_interface=$interface"
-
-	minidlna_cfg_addstr $cfg friendly_name
-	minidlna_cfg_addstr $cfg db_dir
-	minidlna_cfg_addstr $cfg log_dir
-	minidlna_cfg_addbool $cfg inotify '1'
-	minidlna_cfg_addbool $cfg enable_tivo '0'
-	minidlna_cfg_addbool $cfg strict_dlna '0'
-	minidlna_cfg_addstr $cfg album_art_names
-	minidlna_cfg_addstr $cfg presentation_url
-	minidlna_cfg_addstr $cfg notify_interval '900'
-	minidlna_cfg_addstr $cfg serial '12345678'
-	minidlna_cfg_addstr $cfg model_number '1'
-	minidlna_cfg_addstr $cfg minissdpsocket
-	minidlna_cfg_addstr $cfg root_container '.'
-	config_list_foreach "$cfg" "media_dir" minidlna_cfg_add_media_dir
-
-	return 0
-}
-
-start() {
-	local enabled
-	local db_dir
-	local log_dir
-
-	config_load 'minidlna'
-	config_get_bool enabled config 'enabled' '0'
-
-	[ "$enabled" -gt 0 ] || return 1
-
-	minidlna_create_config config || return 1
-	
-	config_get db_dir config 'db_dir' '/var/run/minidlna'
-	config_get log_dir config 'log_dir' '/var/log'
-
-	mkdir -m 0755 -p $db_dir
-	mkdir -m 0755 -p $log_dir
-	service_start /usr/bin/minidlna -f "$MINIDLNA_CONFIG_FILE"
-}
-
-stop() {
-	service_stop /usr/bin/minidlna
-}
-

--- a/multimedia/minidlna/patches/010-genconfig-checks.patch
+++ /dev/null
@@ -1,93 +1,1 @@
---- a/genconfig.sh
-+++ b/genconfig.sh
-@@ -23,14 +23,18 @@ RM="rm -f"
- CONFIGFILE="config.h"
- CONFIGMACRO="__CONFIG_H__"
- 
-+PREFIX="${PREFIX:-/usr}"
-+ICONV_PREFIX="${ICONV_PREFIX:-$PREFIX}"
-+INTL_PREFIX="${INTL_PREFIX:-$PREFIX}"
-+
- # Database path
--DB_PATH="/tmp/minidlna"
-+DB_PATH="${DB_PATH:-/tmp/minidlna}"
- # Log path
--LOG_PATH="${DB_PATH}"
-+LOG_PATH="${LOG_PATH:-$DB_PATH}"
- 
- # detecting the OS name and version
--OS_NAME=`uname -s`
--OS_VERSION=`uname -r`
-+OS_NAME="${OS_NAME:-$(uname -s)}"
-+OS_VERSION="${OS_VERSION:-$(uname -r)}"
- TIVO="/*#define TIVO_SUPPORT*/"
- NETGEAR="/*#define NETGEAR*/"
- READYNAS="/*#define READYNAS*/"
-@@ -40,22 +44,22 @@ ${RM} ${CONFIGFILE}
- 
- # Detect if there are missing headers
- # NOTE: This check only works with a normal distro
--[ ! -e "/usr/include/sqlite3.h" ] && MISSING="libsqlite3 $MISSING"
--[ ! -e "/usr/include/jpeglib.h" ] && MISSING="libjpeg $MISSING"
--[ ! -e "/usr/include/libexif/exif-loader.h" ] && MISSING="libexif $MISSING"
--[ ! -e "/usr/include/id3tag.h" ] && MISSING="libid3tag $MISSING"
--[ ! -e "/usr/include/ogg/ogg.h" ] && MISSING="libogg $MISSING"
--[ ! -e "/usr/include/vorbis/codec.h" ] && MISSING="libvorbis $MISSING"
--[ ! -e "/usr/include/FLAC/metadata.h" ] && MISSING="libflac $MISSING"
--[ ! -e "/usr/include/ffmpeg/avutil.h" -a \
--  ! -e "/usr/include/libavutil/avutil.h" -a \
--  ! -e "/usr/include/ffmpeg/libavutil/avutil.h" ] && MISSING="libavutil $MISSING"
--[ ! -e "/usr/include/ffmpeg/avformat.h" -a \
--  ! -e "/usr/include/libavformat/avformat.h" -a \
--  ! -e "/usr/include/ffmpeg/libavformat/avformat.h" ] && MISSING="libavformat $MISSING"
--[ ! -e "/usr/include/ffmpeg/avcodec.h" -a \
--  ! -e "/usr/include/libavcodec/avcodec.h" -a \
--  ! -e "/usr/include/ffmpeg/libavcodec/avcodec.h" ] && MISSING="libavcodec $MISSING"
-+[ ! -e "${PREFIX}/include/sqlite3.h" ] && MISSING="libsqlite3 $MISSING"
-+[ ! -e "${PREFIX}/include/jpeglib.h" ] && MISSING="libjpeg $MISSING"
-+[ ! -e "${PREFIX}/include/libexif/exif-loader.h" ] && MISSING="libexif $MISSING"
-+[ ! -e "${PREFIX}/include/id3tag.h" ] && MISSING="libid3tag $MISSING"
-+[ ! -e "${PREFIX}/include/ogg/ogg.h" ] && MISSING="libogg $MISSING"
-+[ ! -e "${PREFIX}/include/vorbis/codec.h" ] && MISSING="libvorbis $MISSING"
-+[ ! -e "${PREFIX}/include/FLAC/metadata.h" ] && MISSING="libflac $MISSING"
-+[ ! -e "${PREFIX}/include/ffmpeg/avutil.h" -a \
-+  ! -e "${PREFIX}/include/libavutil/avutil.h" -a \
-+  ! -e "${PREFIX}/include/ffmpeg/libavutil/avutil.h" ] && MISSING="libavutil $MISSING"
-+[ ! -e "${PREFIX}/include/ffmpeg/avformat.h" -a \
-+  ! -e "${PREFIX}/include/libavformat/avformat.h" -a \
-+  ! -e "${PREFIX}/include/ffmpeg/libavformat/avformat.h" ] && MISSING="libavformat $MISSING"
-+[ ! -e "${PREFIX}/include/ffmpeg/avcodec.h" -a \
-+  ! -e "${PREFIX}/include/libavcodec/avcodec.h" -a \
-+  ! -e "${PREFIX}/include/ffmpeg/libavcodec/avcodec.h" ] && MISSING="libavcodec $MISSING"
- if [ -n "$MISSING" ]; then
- 	echo -e "\nERROR!  Cannot continue."
- 	echo -e "The following required libraries are either missing, or are missing development headers:\n"
-@@ -151,8 +155,7 @@ case $OS_NAME in
- 		fi
- 		;;
- 	*)
--		echo "Unknown OS : $OS_NAME"
--		exit 1
-+		echo "WARNING: Unknown OS : $OS_NAME" 1>&2
- 		;;
- esac
- 
-@@ -183,7 +186,7 @@ fi
- echo "" >> ${CONFIGFILE}
- 
- echo "/* Enable if the system iconv.h exists.  ID3 tag reading in various character sets will not work properly otherwise. */" >> ${CONFIGFILE}
--if [ -f /usr/include/iconv.h ]; then
-+if [ -f ${ICONV_PREFIX}/include/iconv.h ]; then
- echo "#define HAVE_ICONV_H" >> ${CONFIGFILE}
- else
- echo -e "\nWARNING!!  Iconv support not found.  ID3 tag reading may not work."
-@@ -192,7 +195,7 @@ fi
- echo "" >> ${CONFIGFILE}
- 
- echo "/* Enable if the system libintl.h exists for NLS support. */" >> ${CONFIGFILE}
--if [ -f /usr/include/libintl.h ]; then
-+if [ -f ${INTL_PREFIX}/include/libintl.h ]; then
- echo "#define ENABLE_NLS" >> ${CONFIGFILE}
- else
- echo "/*#define ENABLE_NLS*/" >> ${CONFIGFILE}
 

--- a/multimedia/minidlna/patches/020-makefile-tweaks.patch
+++ /dev/null
@@ -1,49 +1,1 @@
---- a/Makefile
-+++ b/Makefile
-@@ -10,19 +10,23 @@
- # or :
- # $ make install
- #
-+PREFIX ?= /usr
-+ICONV_PREFIX ?= $(PREFIX)
-+INTL_PREFIX ?= $(PREFIX)
- #CFLAGS = -Wall -O -D_GNU_SOURCE -g -DDEBUG
- #CFLAGS = -Wall -g -Os -D_GNU_SOURCE
- CFLAGS = -Wall -g -O3 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 \
--	 -I/usr/include/ffmpeg \
--	 -I/usr/include/libavutil -I/usr/include/libavcodec -I/usr/include/libavformat \
--	 -I/usr/include/ffmpeg/libavutil -I/usr/include/ffmpeg/libavcodec -I/usr/include/ffmpeg/libavformat
-+	 -I$(PREFIX)/include/ffmpeg \
-+	 -I$(PREFIX)/include/libavutil -I$(PREFIX)/include/libavcodec -I$(PREFIX)/include/libavformat \
-+	 -I$(PREFIX)/include/ffmpeg/libavutil -I$(PREFIX)/include/ffmpeg/libavcodec -I$(PREFIX)/include/ffmpeg/libavformat
-+
- #STATIC_LINKING: CFLAGS += -DSTATIC
- #STATIC_LINKING: LDFLAGS = -static
- CC = gcc
- RM = rm -f
- INSTALL = install
- 
--INSTALLPREFIX ?= $(DESTDIR)/usr
-+INSTALLPREFIX ?= $(DESTDIR)$(PREFIX)
- SBININSTALLDIR = $(INSTALLPREFIX)/sbin
- ETCINSTALLDIR = $(DESTDIR)/etc
- 
-@@ -37,7 +41,7 @@ BASEOBJS = minidlna.o upnphttp.o upnpdes
- 
- ALLOBJS = $(BASEOBJS) $(LNXOBJS)
- 
--LIBS = -lpthread -lexif -ljpeg -lsqlite3 -lavformat -lavutil -lavcodec -lid3tag -lFLAC -logg -lvorbis
-+LIBS = -lpthread -lexif -ljpeg -lsqlite3 -lavformat -lavutil -lavcodec -lid3tag -lFLAC -logg -lvorbis -luuid $(ICONV_LIBS)
- #STATIC_LINKING: LIBS = -lvorbis -logg -lm -lsqlite3 -lpthread -lexif -ljpeg -lFLAC -lm -lid3tag -lz -lavformat -lavutil -lavcodec -lm
- 
- TESTUPNPDESCGENOBJS = testupnpdescgen.o upnpdescgen.o
-@@ -64,7 +68,7 @@ install-conf:
- 	$(INSTALL) -d $(ETCINSTALLDIR)
- 	$(INSTALL) --mode=0644 minidlna.conf $(ETCINSTALLDIR)
- 
--minidlna:	$(BASEOBJS) $(LNXOBJS) $(LIBS)
-+minidlna:	$(BASEOBJS) $(LNXOBJS)
- 	@echo Linking $@
- 	@$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(BASEOBJS) $(LNXOBJS) $(LIBS)
- 
 

--- a/multimedia/minidlna/patches/030-missing-include.patch
+++ /dev/null
@@ -1,11 +1,1 @@
---- a/minidlna.c
-+++ b/minidlna.c
-@@ -58,6 +58,7 @@
- #include <fcntl.h>
- #include <sys/file.h>
- #include <sys/time.h>
-+#include <sys/stat.h>
- #include <time.h>
- #include <signal.h>
- #include <sys/param.h>
 

--- a/multimedia/minidlna/patches/040-minidlna-1.0.25-fix-libavformat-api-feature-check.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- a/metadata.c	2012-08-27 23:00:06.997932249 +0100
-+++ b/metadata.c	2012-08-27 23:10:07.716582960 +0100
-@@ -110,7 +110,7 @@ lav_open(AVFormatContext **ctx, const ch
- static inline void
- lav_close(AVFormatContext *ctx)
- {
--#if LIBAVFORMAT_VERSION_INT >= ((53<<16)+(2<<8)+0)
-+#if LIBAVFORMAT_VERSION_INT >= ((53<<16)+(17<<8)+0)
- 	avformat_close_input(&ctx);
- #else
- 	av_close_input_file(ctx);
 

--- a/multimedia/mjpg-streamer/Config.in
+++ /dev/null
@@ -1,24 +1,1 @@
-if PACKAGE_mjpg-streamer
 
-config MJPG_STREAMER_INPUT_FILE
-	bool "Install input file library"
-	default y
-
-config MJPG_STREAMER_INPUT_UVC
-	bool "Install input uvc library"
-	default y
-
-config MJPG_STREAMER_OUTPUT_FILE
-	bool "Install output file library"
-	default y
-
-config MJPG_STREAMER_OUTPUT_HTTP
-	bool "Install output http library"
-	default y
-
-config MJPG_STREAMER_WWW
-	bool "Install WWW files"
-	default y
-
-endif
-

--- a/multimedia/mjpg-streamer/Makefile
+++ /dev/null
@@ -1,75 +1,1 @@
-#
-# 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:=mjpg-streamer
-PKG_REV:=181
-PKG_VERSION:=r$(PKG_REV)
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=https://svn.code.sf.net/p/mjpg-streamer/code/mjpg-streamer
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_SOURCE_VERSION:=$(PKG_REV)
-PKG_SOURCE_PROTO:=svn
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/mjpg-streamer
-  SECTION:=multimedia
-  CATEGORY:=Multimedia
-  TITLE:=MJPG-streamer
-  DEPENDS:=+libpthread +libjpeg
-  URL:=http://mjpg-streamer.wiki.sourceforge.net/
-  MENU:=1
-endef
-
-define Package/mjpg-streamer/description
- Streaming application for Linux-UVC compatible webcams
-endef
-
-define Package/mjpg-streamer/config
-  source "$(SOURCE)/Config.in"
-endef
-
-EXTRA_CFLAGS += $(TARGET_CPPFLAGS) $(TARGET_LDFLAGS)
-
-define Package/mjpg-streamer/conffiles
-/etc/config/mjpg-streamer
-endef
-
-define Package/mjpg-streamer/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/mjpg_streamer $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/etc/config
-	$(CP) ./files/mjpg-streamer.config $(1)/etc/config/mjpg-streamer
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/mjpg-streamer.init $(1)/etc/init.d/mjpg-streamer
-	$(INSTALL_DIR) $(1)/etc/hotplug.d/usb
-	$(INSTALL_DATA) ./files/mjpg-streamer.hotplug $(1)/etc/hotplug.d/usb/20-mjpg-streamer
-	$(INSTALL_DIR) $(1)/usr/lib
-ifeq ($(CONFIG_MJPG_STREAMER_INPUT_FILE),y)
-	$(CP) $(PKG_BUILD_DIR)/input_file.so $(1)/usr/lib
-endif
-ifeq ($(CONFIG_MJPG_STREAMER_INPUT_UVC),y)
-	$(CP) $(PKG_BUILD_DIR)/input_uvc.so $(1)/usr/lib
-endif
-ifeq ($(CONFIG_MJPG_STREAMER_OUTPUT_FILE),y)
-	$(CP) $(PKG_BUILD_DIR)/output_file.so $(1)/usr/lib
-endif
-ifeq ($(CONFIG_MJPG_STREAMER_OUTPUT_HTTP),y)
-	$(CP) $(PKG_BUILD_DIR)/output_http.so $(1)/usr/lib
-endif
-ifeq ($(CONFIG_MJPG_STREAMER_WWW),y)
-	$(INSTALL_DIR) $(1)/www/webcam
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/www/* $(1)/www/webcam
-endif
-endef
-
-$(eval $(call BuildPackage,mjpg-streamer))
-

--- a/multimedia/mjpg-streamer/files/mjpg-streamer.config
+++ /dev/null
@@ -1,11 +1,1 @@
-config mjpg-streamer 'core'
-	option enabled '0'
-	option input 'uvc'
-	option output 'http'
-	option device '/dev/video0'
-	option resolution '640x480'
-	option fps '5'
-	option www '/www/webcam'
-	option port '8080'
 
-

--- a/multimedia/mjpg-streamer/files/mjpg-streamer.hotplug
+++ /dev/null
@@ -1,11 +1,1 @@
-case "$ACTION" in
-	add)
-		# start process
-		/etc/init.d/mjpg-streamer start
-		;;
-	remove)
-		# stop process
-		/etc/init.d/mjpg-streamer stop
-		;;
-esac
 

--- a/multimedia/mjpg-streamer/files/mjpg-streamer.init
+++ /dev/null
@@ -1,84 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2009-2013 OpenWrt.org
 
-START=90
-STOP=10
-
-USE_PROCD=1
-PROG=/usr/bin/mjpg_streamer
-
-error() {
-	echo "${initscript}:" "$@" 1>&2
-}
-
-start_instance() {
-	local s="$1"
-
-	config_get_bool enabled "$1" 'enabled' 0
-	[ $enabled -eq 0 ] && return
-
-	config_get input "$s" 'input'
-	if [ -z "$input" ]; then
-		error "in section '$s' option input is missing"
-		return 1
-	fi
-
-	config_get output "$s" 'output'
-	if [ -z "$output" ]; then
-		error "in section '$s' option output is missing"
-		return 1
-	fi
-
-	local input_arg
-	if [ "x$input" = 'xuvc' ]; then
-		input_arg="input_uvc.so"
-
-		config_get device "$s" 'device'
-		if [ ! -c "$device" ]; then
-			error "device '$device' does not exist"
-			return 1
-		fi
-		input_arg="${input_arg} --device $device"
-
-		config_get fps "$s" 'fps'
-		[ -n "$fps" ] && input_arg="${input_arg} --fps $fps"
-
-		config_get resolution "$s" 'resolution'
-		[ -n "$resolution" ] && input_arg="${input_arg} --resolution $resolution"
-	fi
-
-	if [ -z "$input_arg" ]; then
-		error "unsuported input option '$input' in section '$s'"
-		return 1
-	fi
-
-	local output_arg
-	if [ "x$output" = 'xhttp' ]; then
-		output_arg="output_http.so"
-
-		config_get port "$s" 'port'
-		[ -n "$port" ] && output_arg="${output_arg} --port $port"
-
-		config_get www "$s" 'www'
-		[ -n "$www" ] && output_arg="${output_arg} --www $www"
-	fi
-
-	if [ -z "$output_arg" ]; then
-		error "unsuported output option '$output' in section '$s'"
-		return 1
-	fi
-
-	procd_open_instance
-	procd_set_param command "$PROG" --input "$input_arg" --output "$output_arg"
-	procd_close_instance
-}
-
-start_service() {
-	config_load 'mjpg-streamer'
-	config_foreach start_instance 'mjpg-streamer'
-}
-
-service_triggers() {
-	procd_add_reload_trigger 'mjpg-streamer'
-}
-

--- a/multimedia/motion/Makefile
+++ /dev/null
@@ -1,53 +1,1 @@
-#
-# Copyright (C) 2008-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:=motion
-PKG_VERSION:=20110826-051001
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://www.lavrsen.dk/sources/motion-daily \
-		@SF/motion
-PKG_MD5SUM:=e703fce57ae2215cb05f25e3027f5818
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/motion
-  SECTION:=multimedia
-  CATEGORY:=Multimedia
-  DEPENDS:=+libjpeg +libpthread
-  TITLE:=webcam motion sensing and logging
-  URL:=http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome
-endef
-
-define Package/motion/conffiles
-/etc/motion.conf
-endef
-
-CONFIGURE_ARGS+= \
-	--without-optimizecpu \
-	--without-ffmpeg \
-	--without-jpeg-mmx \
-	--without-sdl \
-	--without-mysql \
-	--without-pgsql \
-	--without-sqlite3 \
-
-define Package/motion/install
-	$(INSTALL_DIR) $(1)/etc
-	$(CP) $(PKG_INSTALL_DIR)/etc/motion-dist.conf $(1)/etc/motion.conf
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/motion $(1)/usr/bin/
-
-endef
-
-$(eval $(call BuildPackage,motion))
-

--- a/multimedia/motion/patches/002-honor_cppflags.patch
+++ /dev/null
@@ -1,20 +1,1 @@
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -31,6 +31,7 @@ examplesdir = $(datadir)/@PACKAGE_NAME@-
- # install.                                                                     #
- ################################################################################
- CFLAGS       = @CFLAGS@ -Wall -DVERSION=\"@PACKAGE_VERSION@\" -Dsysconfdir=\"$(sysconfdir)\" 
-+CPPFLAGS     = @CPPFLAGS@
- LDFLAGS      = @LDFLAGS@
- LIBS         = @LIBS@ 
- VIDEO_OBJ    = @VIDEO@
-@@ -118,7 +119,7 @@ endif
- ################################################################################
- $(DEPEND_FILE): *.h $(SRC)
- 	@echo "Generating dependencies, please wait..."
--	@$(CC) $(CFLAGS) -M $(SRC) > .tmp
-+	@$(CC) $(CFLAGS) $(CPPFLAGS) -M $(SRC) > .tmp
- 	@mv -f .tmp $(DEPEND_FILE)
- 	@echo
- 
 

file:a/net/aria2/Config.in (deleted)
--- a/net/aria2/Config.in
+++ /dev/null
@@ -1,29 +1,1 @@
-menu "Aria2 configuration"
-	depends on PACKAGE_aria2
 
-choice
-	prompt "SSL library"
-	default ARIA2_OPENSSL
-
-config ARIA2_OPENSSL
-	bool "OpenSSL"
-
-config ARIA2_GNUTLS
-	bool "GNUTLS"
-
-config ARIA2_NOSSL
-	bool "No SSL support"
-
-endchoice
-
-config ARIA2_BITTORRENT
-	bool "Enable bittorrent support"
-	depends on ARIA2_OPENSSL
-	default n
-
-config ARIA2_METALINK
-	bool "Enable metalink support"
-	default N
-
-endmenu
-

file:a/net/aria2/Makefile (deleted)
--- a/net/aria2/Makefile
+++ /dev/null
@@ -1,71 +1,1 @@
-#
-# Copyright (C) 2012-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:=aria2
-PKG_VERSION:=1.18.4
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=@SF/aria2
-PKG_MD5SUM:=d10fc5ee6e708760134e4cb963ecc98e
-PKG_INSTALL:=1
-
-PKG_MAINTAINER:=Imre Kaloz <kaloz@openwrt.org>
-PKG_LICENSE:=GPLv2
-PKG_LICENSE_FILES:=COPYING
-
-PKG_CONFIG_DEPENDS := \
-  ARIA2_NOSSL \
-  ARIA2_OPENSSL \
-  ARIA2_GNUTLS \
-  ARIA2_BITTORRENT \
-  ARIA2_METALINK
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/aria2/config
-  source "$(SOURCE)/Config.in"
-endef
-
-define Package/aria2
-  SECTION:=net
-  CATEGORY:=Network
-  SUBMENU:=File Transfer
-  TITLE:=lightweight download utility
-  URL:=http://aria2.sourceforge.net/
-  DEPENDS:=+zlib +ARIA2_METALINK:libxml2 +libstdcpp +ARIA2_OPENSSL:libopenssl +ARIA2_GNUTLS:libgnutls
-endef
-
-define Package/aria2/description
- aria2 is a lightweight multi-protocol & multi-source command-line download
- utility
-endef
-
-CONFIGURE_ARGS += \
-	--disable-nls \
-	$(if $(CONFIG_ARIA2_NOSSL),--disable,--enable)-ssl \
-	$(if $(CONFIG_ARIA2_OPENSSL),--with,--without)-openssl \
-	$(if $(CONFIG_ARIA2_GNUTLS),--with,--without)-gnutls \
-	$(if $(CONFIG_ARIA2_BITTORRENT),--enable,--disable)-bittorrent \
-	$(if $(CONFIG_ARIA2_METALINK),--enable,--disable)-metalink \
-	$(if $(CONFIG_ARIA2_METALINK),--with,--without)-libxml2 \
-	--without-libnettle \
-	--without-libgmp \
-	--without-libgcrypt \
-	--without-libexpat \
-	--without-libcares \
-	--without-sqlite3 \
-	--with-libz
-
-define Package/aria2/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/aria2c $(1)/usr/bin
-endef
-
-$(eval $(call BuildPackage,aria2))
-

file:a/net/iodine/Makefile (deleted)
--- a/net/iodine/Makefile
+++ /dev/null
@@ -1,70 +1,1 @@
-#
-# 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:=iodine
-PKG_VERSION:=0.6.0-rc1
-PKG_RELEASE:=5
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://code.kryo.se/iodine/
-PKG_MD5SUM:=a15bb4faba020d217016fde6e231074a
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/iodine/Default
-  SECTION:=net
-  CATEGORY:=Network
-  SUBMENU:=Firewall Tunnel
-  DEPENDS:= +kmod-tun +zlib
-  TITLE:=IP over DNS tunneling
-  URL:=http://code.kryo.se/iodine/
-endef
-
-define Package/iodine
-  $(call Package/iodine/Default)
-  TITLE+= client version
-endef
-
-define Package/iodine/description
- iodine client version
-endef
-
-define Package/iodined
-  $(call Package/iodine/Default)
-  TITLE+= server version
-endef
-
-define Package/iodined/description
- iodine server version
-endef
-
-define Build/Configure
-endef
-
-define Package/iodine/install
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/iodine $(1)/usr/sbin
-endef
-
-define Package/iodined/install
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/iodined.init $(1)/etc/init.d/iodined
-	$(INSTALL_DIR) $(1)/etc/config
-	$(INSTALL_DATA) ./files/iodined.config $(1)/etc/config/iodined
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/iodined $(1)/usr/sbin
-endef
-
-define Package/iodined/conffiles
-/etc/config/iodined
-endef
-
-$(eval $(call BuildPackage,iodine))
-$(eval $(call BuildPackage,iodined))
-

--- a/net/iodine/files/iodined.config
+++ /dev/null
@@ -1,6 +1,1 @@
-config iodined
-        option address     ''
-        option password    ''
-        option tunnelip    '10.0.0.1'
-        option tld     	   ''
 

--- a/net/iodine/files/iodined.init
+++ /dev/null
@@ -1,24 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2006-2011 OpenWrt.org
 
-START=50
-
-start_instance () {
-	local section="$1"
-	config_get address  "$section" 'address'
-	config_get password "$section" 'password'
-	config_get tunnelip "$section" 'tunnelip'
-	config_get tld      "$section" 'tld'
-	
-	service_start /usr/sbin/iodined -l "$address" -P "$password" "$tunnelip" "$tld"
-}
-
-start() {
-	config_load 'iodined'
-	config_foreach start_instance 'iodined'
-}
-
-stop() {
-	service_stop /usr/sbin/iodined
-}
-

--- a/net/iodine/patches/010-cross-compile.patch
+++ /dev/null
@@ -1,23 +1,1 @@
---- a/src/osflags
-+++ b/src/osflags
-@@ -16,9 +16,6 @@ link)
- 		windows32)
- 			echo '-lws2_32 -liphlpapi';
- 		;;
--		Linux)
--			[ -e /usr/include/selinux/selinux.h ] && echo '-lselinux';
--		;;
- 	esac
- 	;;
- cflags)
-@@ -26,9 +23,6 @@ cflags)
- 		BeOS)
- 			echo '-Dsocklen_t=int';
- 		;;
--		Linux)
--			[ -e /usr/include/selinux/selinux.h ] && echo '-DHAVE_SETCON';
--		;;
- 	esac
- ;;
- *)
 

file:a/net/krb5/Makefile (deleted)
--- a/net/krb5/Makefile
+++ /dev/null
@@ -1,129 +1,1 @@
-include $(TOPDIR)/rules.mk
 
-PKG_NAME:=krb5
-PKG_VERSION:=1.11
-PKG_RELEASE:=1
-
-PKG_SOURCE:=krb5-$(PKG_VERSION)-signed.tar
-PKG_SOURCE_URL:=http://web.mit.edu/kerberos/dist/krb5/$(PKG_VERSION)/
-PKG_MD5SUM:=1a13c53899806c4da99a798a04d25545
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
-
-PKG_BUILD_PARALLEL:=1
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-MAKE_PATH:=src
-
-define Package/krb5/Default
-	SECTION:=net
-	CATEGORY:=Network
-	TITLE:=Kerberos
-	URL:=http://web.mit.edu/kerberos/
-	MAINTAINER:=W. Michael Petullo <mike@flyn.org>
-endef
-
-define Package/krb5-libs
-	SECTION:=net
-	CATEGORY:=Network
-	TITLE:=Kerberos
-	DEPENDS:=+libncurses
-	TITLE:=Kerberos 5 Shared Libraries
-	URL:=http://web.mit.edu/kerberos/
-	MAINTAINER:=W. Michael Petullo <mike@flyn.org>
-endef
-
-define Package/krb5-server
-	$(call Package/krb5/Default)
-	DEPENDS:=+krb5-libs +libpthread
-	TITLE:=Kerberos 5 Server
-endef
-
-define Package/krb5-client
-	$(call Package/krb5/Default)
-	DEPENDS:=+krb5-libs
-	TITLE:=Kerberos 5 Client
-endef
-
-define Package/krb5/description
-	Kerberos
-endef
-
-define Build/Prepare
-	# Krb5 tarball contains signature and a second tarball
-	# containing source code.
-	tar xf "$(DL_DIR)/$(PKG_SOURCE)" -C "$(BUILD_DIR)"
-	tar xzf "$(BUILD_DIR)/krb5-$(PKG_VERSION).tar.gz" -C "$(BUILD_DIR)"
-	patch -p1 -d "$(PKG_BUILD_DIR)" < "$(PATCH_DIR)/001-fix-build-warning.patch"
-endef
-
-CONFIGURE_PATH = ./src
-
-CONFIGURE_VARS += \
-	cross_compiling=yes \
-	krb5_cv_attr_constructor_destructor=yes,yes \
-	ac_cv_func_regcomp=yes \
-	ac_cv_printf_positional=yes \
-	ac_cv_file__etc_environment=no \
-	ac_cv_file__etc_TIMEZONE=no
-
-CONFIGURE_ARGS += \
-	--without-tcl \
-	--without-libedit \
-	--localstatedir=/etc
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_INSTALL_DIR)/usr/include \
-		$(1)/usr/include/krb5
-	$(INSTALL_DIR) $(1)/usr
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib \
-		$(1)/usr
-	rm -f $(1)/usr/lib/libcom_err*
-endef
-
-define Package/krb5-libs/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(INSTALL_DIR) $(1)/usr/lib/krb5
-	$(INSTALL_DIR) $(1)/usr/lib/krb5/plugins
-	$(INSTALL_DIR) $(1)/usr/lib/krb5/plugins/kdb
-	$(INSTALL_DIR) $(1)/usr/lib/krb5/plugins/libkrb5
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/krb5/plugins/kdb/db2.so $(1)/usr/lib/krb5/plugins/kdb
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib
-endef
-
-define Package/krb5-client/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kdestroy $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kinit $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/klist $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kpasswd $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ksu $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kvno $(1)/usr/bin
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/krb5-send-pr $(1)/usr/sbin
-endef
-
-# Removed some server-side software to reduce package size. This should be
-# put in a separate package if needed.
-define Package/krb5-server/install
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/krb5kdc $(1)/etc/init.d/krb5kdc
-#	$(INSTALL_DIR) $(1)/usr/bin
-#	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sclient $(1)/usr/bin
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kadmin.local $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kadmind $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kdb5_util $(1)/usr/sbin
-#	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kprop $(1)/usr/sbin
-#	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kpropd $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/krb5kdc $(1)/usr/sbin
-#	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/sim_server $(1)/usr/sbin
-endef
-
-$(eval $(call BuildPackage,krb5-libs))
-$(eval $(call BuildPackage,krb5-server))
-$(eval $(call BuildPackage,krb5-client))
-

file:a/net/krb5/files/krb5kdc (deleted)
--- a/net/krb5/files/krb5kdc
+++ /dev/null
@@ -1,20 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2009 OpenWrt.org
 
-START=60
-
-start() {
-	mkdir -p /var/tmp
-	mkdir -p /etc/krb5kdc
-	
-	[ -f /etc/krb5kdc/principal ] || ( echo; echo ) | kdb5_util create -s
-	
-	/usr/sbin/krb5kdc
-	/usr/sbin/kadmind
-}
-
-stop() {
-	killall krb5kdc 2> /dev/null
-	killall kadmind 2> /dev/null
-}
-

--- a/net/krb5/patches/001-fix-build-warning.patch
+++ /dev/null
@@ -1,13 +1,1 @@
-diff -ur krb5-1.11-vanilla/src/lib/krb5/krb/preauth2.c krb5-1.11/src/lib/krb5/krb/preauth2.c
---- krb5-1.11-vanilla/src/lib/krb5/krb/preauth2.c	2012-12-18 03:47:05.000000000 +0100
-+++ krb5-1.11/src/lib/krb5/krb/preauth2.c	2013-02-18 03:53:20.580840173 +0100
-@@ -956,7 +956,7 @@
-     size_t i, h;
-     int out_pa_list_size = 0;
-     krb5_pa_data **out_pa_list = NULL;
--    krb5_error_code ret, module_ret;
-+    krb5_error_code ret, module_ret = 0;
-     krb5_responder_fn responder = opte->opt_private->responder;
-     static const int paorder[] = { PA_INFO, PA_REAL };
- 
 

--- /dev/null
+++ b/net/l2tpv3tun/Makefile
@@ -1,1 +1,51 @@
+#
+# Copyright (C) 2009-2010 Thomas Heil <heil@terminal-consulting.de>
+# Copyright (C) 2010-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:=l2tpv3tun
+PKG_VERSION:=0.2
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=ftp://www.openl2tp.org/releases
+PKG_MD5SUM:=d3b4a9af652cca9f34d3eea4a7ff6041
+
+PKG_INSTALL:=1
+
+include $(INCLUDE_DIR)/kernel.mk
+include $(INCLUDE_DIR)/package.mk
+
+define Package/l2tpv3tun
+  SECTION:=net
+  CATEGORY:=Network
+  DEPENDS:=+libnl-tiny +ip +kmod-l2tp +kmod-l2tp-ip +kmod-l2tp-eth
+  TITLE:=Control utility for static L2TP v3 (Pseudowire) tunnels
+  MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>
+  URL:=http://www.openl2tp.org
+endef
+
+define Package/l2tpv3tun/description
+  The l2tpv3tun utility is a command line frontend for configuring static
+  L2TP v3 pseudowire tunnels.
+endef
+
+MAKE_FLAGS += \
+	CC="$(TARGET_CC)" \
+	CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/usr/include/libnl-tiny/" \
+	LD="$(TARGET_CC)" \
+	LDFLAGS="$(TARGET_LDFLAGS) -L$(STAGING_DIR)/usr/lib/ -lnl-tiny"
+
+define Package/l2tpv3tun/install
+	$(INSTALL_DIR) $(1)/usr/bin
+	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/l2tpv3tun $(1)/usr/bin/
+	$(INSTALL_DIR) $(1)/lib/network
+	$(INSTALL_BIN) ./files/l2tp.sh $(1)/lib/network/
+endef
+
+$(eval $(call BuildPackage,l2tpv3tun))
+

--- /dev/null
+++ b/net/l2tpv3tun/files/l2tp.sh
@@ -1,1 +1,214 @@
-
+# l2tp.sh - L2TPv3 tunnel backend
+# Copyright (c) 2010 OpenWrt.org
+
+l2tp_next_tunnel_id() {
+	local max=0
+	local val
+	for val in $(
+		local l
+		l2tpv3tun show tunnel | while read l; do
+			case "$l" in
+				Tunnel*,*encap*) l="${l#Tunnel }"; echo "${l%%,*}";;
+			esac
+		done
+	); do
+		[ "$val" -gt "$max" ] && max="$val"
+	done
+	echo $((max + 1))
+}
+
+l2tp_next_session_id() {
+	local tunnel="$1"
+	local max=0
+	local val
+	for val in $(
+		local l
+		l2tpv3tun show session${tunnel:+ tunnel_id "$tunnel"} | while read l; do
+			case "$l" in
+				Session*in*) l="${l#Session }"; echo "${l%% *}";;
+			esac
+		done
+	); do
+		[ "$val" -gt "$max" ] && max="$val"
+	done
+	echo $((max + 1))
+}
+
+l2tp_tunnel_exists() {
+	test -n "$(l2tpv3tun show tunnel tunnel_id "$1" 2>/dev/null)"
+}
+
+l2tp_session_exists() {
+	test -n "$(l2tpv3tun show session tunnel_id "$1" session_id "$2" 2>/dev/null)"
+}
+
+l2tp_ifname() {
+	l2tpv3tun show session tunnel_id "$1" session_id "$2" 2>/dev/null | \
+		sed -ne 's/^.*interface name: //p'
+}
+
+l2tp_lock() {
+	lock /var/lock/l2tp-setup
+}
+
+l2tp_unlock() {
+	lock -u /var/lock/l2tp-setup
+}
+
+l2tp_log() {
+	logger -t "ifup-l2tp" "$@"
+}
+
+
+# Hook into scan_interfaces() to synthesize a .device option
+# This is needed for /sbin/ifup to properly dispatch control
+# to setup_interface_l2tp() even if no .ifname is set in
+# the configuration.
+scan_l2tp() {
+	local dev
+	config_get dev "$1" device
+	config_set "$1" device "${dev:+$dev }l2tp-$1"
+}
+
+coldplug_interface_l2tp() {
+	setup_interface_l2tp "l2tp-$1" "$1"
+}
+
+setup_interface_l2tp() {
+	local iface="$1"
+	local cfg="$2"
+	local link="l2tp-$cfg"
+
+	l2tp_lock
+
+	# prevent recursion
+	local up="$(uci_get_state network "$cfg" up 0)"
+	[ "$up" = 0 ] || {
+		l2tp_unlock
+		return 0
+	}
+
+	local tunnel_id
+	config_get tunnel_id "$cfg" tunnel_id
+	[ -n "$tunnel_id" ] || {
+		tunnel_id="$(l2tp_next_tunnel_id)"
+		uci_set_state network "$cfg" tunnel_id "$tunnel_id"
+		l2tp_log "No tunnel ID specified, assuming $tunnel_id"
+	}
+
+	local peer_tunnel_id
+	config_get peer_tunnel_id "$cfg" peer_tunnel_id
+	[ -n "$peer_tunnel_id" ] || {
+		peer_tunnel_id="$tunnel_id"
+		uci_set_state network "$cfg" peer_tunnel_id "$peer_tunnel_id"
+		l2tp_log "No peer tunnel ID specified, assuming $peer_tunnel_id"
+	}
+
+	local encap
+	config_get encap "$cfg" encap udp
+
+	local sport dport
+	[ "$encap" = udp ] && {
+		config_get sport "$cfg" sport 1701
+		config_get dport "$cfg" dport 1701
+	}
+
+	local peeraddr
+	config_get peeraddr "$cfg" peeraddr
+	[ -z "$peeraddr" ] && config_get peeraddr "$cfg" peer6addr
+
+	local localaddr
+	case "$peeraddr" in
+		*:*) config_get localaddr "$cfg" local6addr ;;
+		*)   config_get localaddr "$cfg" localaddr  ;;
+	esac
+
+	[ -n "$localaddr" -a -n "$peeraddr" ] || {
+		l2tp_log "Missing local or peer address for tunnel $cfg - skipping"
+		return 1
+	}
+
+	(
+		while ! l2tp_tunnel_exists "$tunnel_id"; do
+			[ -n "$sport" ] && l2tpv3tun show tunnel 2>/dev/null | grep -q "ports: $sport/" && {
+				l2tp_log "There already is a tunnel with src port $sport - skipping"
+				l2tp_unlock
+				return 1
+			}
+
+			l2tpv3tun add tunnel tunnel_id "$tunnel_id" peer_tunnel_id "$peer_tunnel_id" \
+				encap "$encap" local "$localaddr" remote "$peeraddr" \
+				${sport:+udp_sport "$sport"} ${dport:+udp_dport "$dport"}
+
+			# Wait for tunnel
+			sleep 1
+		done
+
+
+		local session_id
+		config_get session_id "$cfg" session_id
+		[ -n "$session_id" ] || {
+			session_id="$(l2tp_next_session_id "$tunnel_id")"
+			uci_set_state network "$cfg" session_id "$session_id"
+			l2tp_log "No session ID specified, assuming $session_id"
+		}
+
+		local peer_session_id
+		config_get peer_session_id "$cfg" peer_session_id
+		[ -n "$peer_session_id" ] || {
+			peer_session_id="$session_id"
+			uci_set_state network "$cfg" peer_session_id "$peer_session_id"
+			l2tp_log "No peer session ID specified, assuming $peer_session_id"
+		}
+
+
+		while ! l2tp_session_exists "$tunnel_id" "$session_id"; do
+			l2tpv3tun add session ifname "$link" tunnel_id "$tunnel_id" \
+				session_id "$session_id" peer_session_id "$peer_session_id"
+
+			# Wait for session
+			sleep 1
+		done
+
+
+		local dev
+		config_get dev "$cfg" device
+
+		local ifn
+		config_get ifn "$cfg" ifname
+
+		uci_set_state network "$cfg" ifname "${ifn:-$dev}"
+		uci_set_state network "$cfg" device "$dev"
+
+		local mtu
+		config_get mtu "$cfg" mtu 1462
+
+		local ttl
+		config_get ttl "$cfg" ttl
+
+		ip link set mtu "$mtu" ${ttl:+ ttl "$ttl"} dev "$link"
+
+		# IP setup inherited from proto static
+		prepare_interface "$link" "$cfg"
+		setup_interface_static "${ifn:-$dev}" "$cfg"
+
+		ip link set up dev "$link"
+
+		uci_set_state network "$cfg" up 1
+		l2tp_unlock
+	) &
+}
+
+stop_interface_l2tp() {
+	local cfg="$1"
+	local link="l2tp-$cfg"
+
+	local tunnel=$(uci_get_state network "$cfg" tunnel_id)
+	local session=$(uci_get_state network "$cfg" session_id)
+
+	[ -n "$tunnel" ] && [ -n "$session" ] && {
+		l2tpv3tun del session tunnel_id "$tunnel" session_id "$session"
+		l2tpv3tun del tunnel tunnel_id "$tunnel"
+	}
+}
+

--- /dev/null
+++ b/net/l2tpv3tun/patches/010-custom_ifname.patch
@@ -1,1 +1,21 @@
+--- a/main.c
++++ b/main.c
+@@ -560,6 +560,7 @@ static void usage(void)
+ 	fprintf(stderr, "          session_id ID peer_session_id ID\n");
+ 	fprintf(stderr, "          [ cookie HEXSTR ] [ peer_cookie HEXSTR ]\n");
+ 	fprintf(stderr, "          [ offset OFFSET ] [ peer_offset OFFSET ]\n");
++	fprintf(stderr, "          [ ifname IFNAME ]\n");
+ 	fprintf(stderr, "       %s del tunnel tunnel_id ID\n", L2TP_CMD_ROOT);
+ 	fprintf(stderr, "       %s del session tunnel_id ID session_id ID\n", L2TP_CMD_ROOT);
+ 	fprintf(stderr, "       %s show tunnel [ tunnel_id ID ]\n", L2TP_CMD_ROOT);
+@@ -671,6 +672,9 @@ static int parse_args(int argc, char **a
+ 			p->peer_cookie_len = slen / 2;
+ 			if (hex2mem(*argv, p->peer_cookie, p->peer_cookie_len) < 0)
+ 				invarg("cookie must be a hex string\n", *argv);
++		} else if (strcmp(*argv, "ifname") == 0) {
++			NEXT_ARG();
++			p->ifname = *argv;
+ 		} else if (strcmp(*argv, "tunnel") == 0) {
+ 			p->tunnel = 1;
+ 		} else if (strcmp(*argv, "session") == 0) {
 

--- /dev/null
+++ b/net/l2tpv3tun/patches/100-nl_handle_alloc.patch
@@ -1,1 +1,24 @@
+--- a/main.c
++++ b/main.c
+@@ -100,7 +100,7 @@ struct l2tp_data {
+ };
+ 
+ /* netlink socket */
+-static struct nl_handle *nl_sock;
++static struct nl_sock *nl_sock;
+ static int nl_family;
+ 
+ /*****************************************************************************
+@@ -788,9 +788,9 @@ static int do_show(int argc, char **argv
+ 
+ int do_ipl2tp(int argc, char **argv)
+ {
+-	nl_sock = nl_handle_alloc();
++	nl_sock = nl_socket_alloc();
+ 	if (!nl_sock) {
+-		perror("nl_handle_alloc");
++		perror("nl_socket_alloc");
+ 		return 1;
+ 	}
+ 
 

file:a/net/lighttpd/Makefile (deleted)
--- a/net/lighttpd/Makefile
+++ /dev/null
@@ -1,181 +1,1 @@
-	#
-# 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:=lighttpd
-PKG_VERSION:=1.4.35
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
-PKG_SOURCE_URL:=http://download.lighttpd.net/lighttpd/releases-1.4.x
-PKG_MD5SUM:=c7ae774eab4cb7ac85e41b712f4ee9ba
-
-PKG_LICENSE:=BSD-3c
-PKG_LICENSE_FILES:=COPYING
-
-PKG_FIXUP:=autoreconf
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/lighttpd/Default
-  SUBMENU:=Web Servers/Proxies
-  SECTION:=net
-  CATEGORY:=Network
-  URL:=http://www.lighttpd.net/
-endef
-
-define Package/lighttpd
-  $(call Package/lighttpd/Default)
-  MENU:=1
-  DEPENDS:=+LIGHTTPD_SSL:libopenssl +libpcre +libpthread
-  TITLE:=A flexible and lightweight web server
-endef
-
-define Package/lighttpd/config
-config LIGHTTPD_SSL
-	bool "SSL support"
-	depends on PACKAGE_lighttpd
-	default y
-	help
-	  Implements SSL support in lighttpd (using libopenssl). This
-	  option is required if you enable the SSL engine in your
-	  lighttpd confguration file.
-endef
-
-CONFIGURE_ARGS+= \
-	--libdir=/usr/lib/lighttpd \
-	--sysconfdir=/etc/lighttpd \
-	--enable-shared \
-	--enable-static \
-	--disable-rpath \
-	--without-attr \
-	--without-bzip2 \
-	--without-fam \
-	--without-gdbm \
-	--without-ldap \
-	--without-lua \
-	--without-memcache \
-	--with-pcre \
-	--without-valgrind \
-	 $(call autoconf_bool,CONFIG_IPV6,ipv6)
-
-CONFIGURE_VARS+= \
-	PCRE_LIB="-lpcre" \
-
-ifneq ($(strip $(CONFIG_LIGHTTPD_SSL)),)
-  CONFIGURE_ARGS+= \
-	--with-openssl="$(STAGING_DIR)/usr"
-else
-  CONFIGURE_ARGS+= \
-	--without-openssl
-endif
-
-ifneq ($(SDK)$(CONFIG_PACKAGE_lighttpd-mod-mysql-vhost),)
-  CONFIGURE_ARGS+= \
-	--with-mysql
-else
-  CONFIGURE_ARGS+= \
-	--without-mysql
-endif
-
-ifneq ($(SDK)$(CONFIG_PACKAGE_lighttpd-mod-webdav),)
-  CONFIGURE_ARGS+= \
-	--with-webdav-locks \
-	--with-webdav-props
-  # XXX: needed by sqlite3 to prevent segfaults in mod_webdav.so
-  CONFIGURE_VARS+= \
-	LIBS="-lpthread"
-else
-  CONFIGURE_ARGS+= \
-	--without-webdav-locks \
-	--without-webdav-props
-endif
-
-define Build/Configure
-$(call Build/Configure/Default)
-	# XXX: override pcre (mis)detection by ./configure when cross-compiling
-	echo "#define HAVE_LIBPCRE 1" >>$(PKG_BUILD_DIR)/config.h
-	echo "#define HAVE_PCRE_H 1" >>$(PKG_BUILD_DIR)/config.h
-endef
-
-define Package/lighttpd/conffiles
-/etc/lighttpd/lighttpd.conf
-endef
-
-define Package/lighttpd/install
-	$(INSTALL_DIR) $(1)/etc/lighttpd
-	$(INSTALL_DATA) ./files/lighttpd.conf $(1)/etc/lighttpd/
-	$(INSTALL_DATA) $(PKG_BUILD_DIR)/doc/config/conf.d/mime.conf $(1)/etc/lighttpd/
-	$(INSTALL_DIR) $(1)/etc/lighttpd/conf.d
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/lighttpd.init $(1)/etc/init.d/lighttpd
-	$(INSTALL_DIR) $(1)/usr/lib/lighttpd
-	for m in dirlisting indexfile staticfile; do \
-		$(CP) $(PKG_INSTALL_DIR)/usr/lib/lighttpd/mod_$$$${m}.so $(1)/usr/lib/lighttpd/ ; \
-	done
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/lighttpd $(1)/usr/sbin/
-endef
-
-define BuildPlugin
-  define Package/lighttpd-mod-$(1)
-    $(call Package/lighttpd/Default)
-    DEPENDS:=lighttpd
-    ifneq ($(3),)
-      DEPENDS+= $(3)
-    endif
-    TITLE:=$(2) module
-  endef
-
-  define Package/lighttpd-mod-$(1)/install
-	$(INSTALL_DIR) $$(1)/usr/lib/lighttpd
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lighttpd/mod_$(1).so $$(1)/usr/lib/lighttpd
-	$(INSTALL_DIR) $$(1)/etc/lighttpd/conf.d
-	if [ -f $(PKG_BUILD_DIR)/doc/config/conf.d/$(1).conf ]; then \
-		$(CP) $(PKG_BUILD_DIR)/doc/config/conf.d/$(1).conf $$(1)/etc/lighttpd/conf.d/$(4)-$(1).conf ; \
-	else \
-		echo 'server.modules += ( "mod_$(1)" )' > $$(1)/etc/lighttpd/conf.d/$(4)-$(1).conf ; \
-	fi
-  endef
-
-  $$(eval $$(call BuildPackage,lighttpd-mod-$(1)))
-endef
-
-$(eval $(call BuildPackage,lighttpd))
-$(eval $(call BuildPlugin,access,Access restrictions,,10))
-$(eval $(call BuildPlugin,accesslog,Access logging,,10))
-$(eval $(call BuildPlugin,alias,Directory alias,,10))
-$(eval $(call BuildPlugin,auth,Authentication,,05))
-$(eval $(call BuildPlugin,cgi,CGI,,10))
-$(eval $(call BuildPlugin,cml,Cache Meta Language,,10))
-$(eval $(call BuildPlugin,compress,Compress output,+PACKAGE_lighttpd-mod-compress:zlib,10))
-$(eval $(call BuildPlugin,evasive,Evasive,,10))
-$(eval $(call BuildPlugin,evhost,Exnhanced Virtual-Hosting,,10))
-$(eval $(call BuildPlugin,expire,Expire,,10))
-$(eval $(call BuildPlugin,extforward,Extract client,,10))
-$(eval $(call BuildPlugin,fastcgi,FastCGI,,10))
-$(eval $(call BuildPlugin,flv_streaming,FLV streaming,,10))
-$(eval $(call BuildPlugin,magnet,Magnet,,10))
-$(eval $(call BuildPlugin,mysql_vhost,Mysql virtual hosting,+PACKAGE_lighttpd-mod-mysql_vhost:libmysqlclient,10))
-$(eval $(call BuildPlugin,proxy,Proxy,,10))
-$(eval $(call BuildPlugin,redirect,URL redirection,+PACKAGE_lighttpd-mod-redirect:libpcre,10))
-$(eval $(call BuildPlugin,rewrite,URL rewriting,+PACKAGE_lighttpd-mod-rewrite:libpcre,10))
-$(eval $(call BuildPlugin,rrdtool,RRDtool,,10))
-$(eval $(call BuildPlugin,scgi,SCGI,,10))
-$(eval $(call BuildPlugin,secdownload,Secure and fast download,,10))
-$(eval $(call BuildPlugin,setenv,Environment variable setting,,10))
-$(eval $(call BuildPlugin,simple_vhost,Simple virtual hosting,,10))
-$(eval $(call BuildPlugin,ssi,SSI,+libpcre,10))
-$(eval $(call BuildPlugin,status,Server status display,,10))
-$(eval $(call BuildPlugin,trigger_b4_dl,Trigger before download,+PACKAGE_lighttpd-mod-trigger_b4_dl:libpcre,10))
-$(eval $(call BuildPlugin,userdir,User directory,,10))
-$(eval $(call BuildPlugin,usertrack,User tracking,,10))
-$(eval $(call BuildPlugin,webdav,WebDAV,+PACKAGE_lighttpd-mod-webdav:libsqlite3 +PACKAGE_lighttpd-mod-webdav:libuuid +PACKAGE_lighttpd-mod-webdav:libxml2,10))
-
-

--- a/net/lighttpd/files/lighttpd.conf
+++ /dev/null
@@ -1,39 +1,1 @@
-# lighttpd configuration file
-# 
-server.modules = (
-)
 
-### only root can use these options
-#server.chroot               = "/"
-
-######### Options that are good to be but not neccesary to be changed #######
-#server.port                 = 81
-#server.bind                 = "localhost"
-server.document-root        = "/www"
-server.upload-dirs          = ( "/tmp" )
-server.errorlog             = "/var/log/lighttpd/error.log"
-server.pid-file             = "/var/run/lighttpd.pid"
-#server.username             = "www-data"
-#server.groupname            = "www-data"
-#server.tag                  = "lighttpd"
-#server.errorlog-use-syslog  = "enable"
-#server.network-backend      = "write"
-
-index-file.names            = ( "index.php", "index.html",
-                                "index.htm", "default.htm",
-                               " index.lighttpd.html" )
-
-static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
-
-## Use ipv6 if available
-#include_shell "/usr/share/lighttpd/use-ipv6.pl"
-
-#dir-listing.encoding        = "utf-8"
-#server.dir-listing          = "enable"
-
-include       "/etc/lighttpd/mime.conf"
-include_shell "cat /etc/lighttpd/conf.d/*.conf"
-
-
-
-

--- a/net/lighttpd/files/lighttpd.init
+++ /dev/null
@@ -1,17 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2006-2011 OpenWrt.org
 
-SERVICE_USE_PID=1
-
-START=50
-
-start() {
-	mkdir -m 0755 -p /var/log/lighttpd
-	service_start /usr/sbin/lighttpd -f /etc/lighttpd/lighttpd.conf
-}
-
-stop() {
-	service_stop /usr/sbin/lighttpd
-}
-
-

file:a/net/prosody/Makefile (deleted)
--- a/net/prosody/Makefile
+++ /dev/null
@@ -1,88 +1,1 @@
-#
-# Copyright (C) 2009-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:=prosody
-PKG_VERSION:=0.6.2
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://prosody.im/downloads/source
-PKG_MD5SUM:=5da59bc906419ad3b4faa21516a6ca18
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/prosody
-  SECTION:=net
-  CATEGORY:=Network
-  SUBMENU:=Instant Messaging
-  DEPENDS:=+luafilesystem +libidn +luaexpat +luasec
-  TITLE:=XMPP server
-  URL:=http://prosody.im/
-endef
-
-define Package/prosody/description
-  Prosody is an exciting new server for Jabber/XMPP
-  written in Lua. It aims to be easy to use, and light
-  on resources
-endef
-
-define Package/prosody/conffiles
-/etc/prosody/prosody.cfg.lua
-endef
-
-TARGET_CFLAGS += $(FPIC)
-
-define Build/Configure
-	# this is *NOT* GNU autoconf stuff
-	(cd $(PKG_BUILD_DIR); ./configure \
-		--prefix=/usr \
-		--with-lua="$(STAGING_DIR)/host/bin" \
-		--with-lua-include="$(STAGING_DIR)/usr/include" \
-		--with-lua-lib="$(STAGING_DIR)/usr/lib" \
-		--cflags="$(TARGET_CFLAGS)" \
-		--datadir="/etc/prosody/data" \
-	)
-endef
-
-MAKE_FLAGS += \
-	CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) -std=gnu99" \
-	LDFLAGS="$(TARGET_LDFLAGS)" \
-	PREFIX="/usr" \
-
-define Package/prosody/install
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/prosody.init $(1)/etc/init.d/prosody
-	$(INSTALL_DIR) $(1)/etc/prosody
-	$(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/prosody/prosody.cfg.lua $(1)/etc/prosody/
-	$(INSTALL_DIR) $(1)/etc/prosody/certs
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/etc/prosody/certs/localhost.{cert,key} $(1)/etc/prosody/certs/
-	$(INSTALL_DIR) $(1)/etc/prosody/data
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/prosody{,ctl} $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/prosody/prosody.version $(1)/usr/lib/prosody/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/core
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/core/*.lua $(1)/usr/lib/prosody/core/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/fallbacks
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/fallbacks/*.lua $(1)/usr/lib/prosody/fallbacks/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/modules
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/modules/*.lua $(1)/usr/lib/prosody/modules/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/modules/muc
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/modules/muc/*.lua $(1)/usr/lib/prosody/modules/muc/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/net
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/net/*.lua $(1)/usr/lib/prosody/net/
-	$(INSTALL_DIR) $(1)/usr/lib/prosody/util
-	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/prosody/util/*.lua $(1)/usr/lib/prosody/util/
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/prosody/util/*.so $(1)/usr/lib/prosody/util/
-endef
-
-$(eval $(call BuildPackage,prosody))
-

--- a/net/prosody/files/prosody.init
+++ /dev/null
@@ -1,42 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2010-2011 OpenWrt.org
 
-START=99
-
-EXTRA_COMMANDS="status"
-EXTRA_HELP="	status	Print the status of the service"
-
-BIN=/usr/bin/prosodyctl
-LOG_D=/var/log/prosody
-RUN_D=/var/run/prosody
-PID_F=$RUN_D/prosody.pid
-RUN_USER=prosody
-RUN_GROUP=prosody
-
-start() {
-	user_exists prosody 54 || user_add prosody 54
-	group_exists prosody 54 || group_add prosody 54
-	[ -d /var/run/prosody ] || {
-		mkdir -m 0755 -p /var/run/prosody
-		chown prosody:prosody /var/run/prosody
-	}
-	[ -d /var/log/prosody ] || {
-		mkdir -m 0755 -p /var/log/prosody
-		chown prosody:prosody /var/log/prosody
-	}
-
-	$BIN start
-}
-
-stop() {
-	$BIN stop
-}
-
-reload() {
-	[ -f $PID_F ] && kill -HUP $(cat $PID_F)
-}
-
-status() {
-	$BIN status
-}
-

--- a/net/prosody/patches/001-conf.patch
+++ /dev/null
@@ -1,38 +1,1 @@
---- a/prosody.cfg.lua.dist
-+++ b/prosody.cfg.lua.dist
-@@ -47,7 +47,7 @@ modules_enabled = {
- 		"register"; -- Allow users to register on this server using a client and change passwords
- 	
- 	-- Other specific functionality
--		--"posix"; -- POSIX functionality, sends server to background, enables syslog, etc.
-+		"posix"; -- POSIX functionality, sends server to background, enables syslog, etc.
- 		--"console"; -- Opens admin telnet interface on localhost port 5582
- 		--"bosh"; -- Enable BOSH clients, aka "Jabber over HTTP"
- 		--"httpserver"; -- Serve static files from a directory over HTTP
-@@ -65,6 +65,9 @@ modules_disabled = {
- -- Disable account creation by default, for security
- -- For more information see http://prosody.im/doc/creating_accounts
- allow_registration = false;
-+
-+-- File to write pid in
-+pidfile = "/var/run/prosody/prosody.pid";
- 	
- -- These are the SSL/TLS-related settings. If you don't want
- -- to use SSL/TLS, you may comment or remove this
-@@ -73,6 +76,15 @@ ssl = {
- 	certificate = "certs/localhost.cert";
- }
- 
-+-- Errors to syslog
-+-- All to /var/log/prosody/
-+log = {
-+	{ levels = { "error" }; to = "syslog";  };
-+	{ levels = { "error" }; to = "file"; filename = "/var/log/prosody/prosody.err";  };
-+	-- Change "info" to "debug" for more verbose logging
-+	{ levels = { min = "info" }; to = "file"; filename = "/var/log/prosody/prosody.log";  };
-+}
-+
- ----------- Virtual hosts -----------
- -- You need to add a VirtualHost entry for each domain you wish Prosody to serve.
- -- Settings under each VirtualHost entry apply *only* to that host.
 

file:a/net/vsftpd/Makefile (deleted)
--- a/net/vsftpd/Makefile
+++ /dev/null
@@ -1,86 +1,1 @@
-#
-# 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:=vsftpd
-PKG_VERSION:=3.0.2
-PKG_RELEASE:=3
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=https://security.appspot.com/downloads/
-PKG_MD5SUM:=8b00c749719089401315bd3c44dddbb2
-
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/vsftpd/Default
-  SUBMENU:=File Transfer
-  SECTION:=net
-  CATEGORY:=Network
-  TITLE:=A fast and secure FTP server
-  URL:=http://vsftpd.beasts.org/
-  MAINTAINER:=Cezary Jackiewicz <cezary@eko.one.pl>
-endef
-
-
-define Package/vsftpd
-$(call Package/vsftpd/Default)
-  VARIANT:=notls
-  TITLE+= (no TLS)
-endef
-
-define Package/vsftpd-tls
-$(call Package/vsftpd/Default)
-  VARIANT:=tls
-  TITLE+= (TLS)
-  DEPENDS+=+libopenssl
-endef
-
-define Package/vsftpd/conffiles
-/etc/vsftpd.conf
-endef
-
-Package/vsftpd-tls/conffiles=$(Package/vsftpd/conffiles)
-
-ifeq ($(BUILD_VARIANT),notls)
- define Build/Compile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		CC="$(TARGET_CC)" \
-		CFLAGS="$(TARGET_CFLAGS)" \
-		LDFLAGS="$(TARGET_LDFLAGS)" \
-		vsftpd
- endef
-endif
-
-ifeq ($(BUILD_VARIANT),tls)
- define Build/Compile
-	$(SED) 's/#undef VSF_BUILD_SSL/#define VSF_BUILD_SSL/' $(PKG_BUILD_DIR)/builddefs.h
-	$(SED) 's/-lcrypt -lnsl/-lcrypt -lnsl -lssl -lcrypto/' $(PKG_BUILD_DIR)/Makefile
-	$(MAKE) -C $(PKG_BUILD_DIR) \
-		CC="$(TARGET_CC)" \
-		CFLAGS="$(TARGET_CFLAGS)" \
-		LDFLAGS="$(TARGET_LDFLAGS)" \
-		vsftpd
- endef
-endif
-
-define Package/vsftpd/install
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_NAME) $(1)/usr/sbin/
-	$(INSTALL_DIR) $(1)/etc
-	$(INSTALL_CONF) ./files/$(PKG_NAME).conf $(1)/etc/$(PKG_NAME).conf
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/$(PKG_NAME).init $(1)/etc/init.d/$(PKG_NAME)
-endef
-
-Package/vsftpd-tls/install=$(Package/vsftpd/install)
-
-$(eval $(call BuildPackage,vsftpd))
-$(eval $(call BuildPackage,vsftpd-tls))
-

--- a/net/vsftpd/files/vsftpd.conf
+++ /dev/null
@@ -1,18 +1,1 @@
-background=YES
-listen=YES
-anonymous_enable=NO
-local_enable=YES
-write_enable=YES
-local_umask=022
-check_shell=NO
-#dirmessage_enable=YES
-#ftpd_banner=Welcome to blah FTP service.
-session_support=NO
-#syslog_enable=YES
-#userlist_enable=YES
-#userlist_deny=NO
-#userlist_file=/etc/vsftpd.users
-#xferlog_enable=YES
-#xferlog_file=/var/log/vsftpd.log
-#xferlog_std_format=YES
 

--- a/net/vsftpd/files/vsftpd.init
+++ /dev/null
@@ -1,14 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2006-2011 OpenWrt.org
 
-START=50
-
-start() {
-	mkdir -m 0755 -p /var/run/vsftpd
-	service_start /usr/sbin/vsftpd
-}
-
-stop() {
-	service_stop /usr/sbin/vsftpd
-}
-

--- a/net/vsftpd/patches/001-destdir.patch
+++ /dev/null
@@ -1,48 +1,1 @@
---- a/Makefile
-+++ b/Makefile
-@@ -22,6 +22,8 @@ OBJS	=	main.o utility.o prelogin.o ftpcm
-     seccompsandbox.o
- 
- 
-+DESTDIR =
-+
- .c.o:
- 	$(CC) -c $*.c $(CFLAGS) $(IFLAGS)
- 
-@@ -29,21 +31,20 @@ vsftpd: $(OBJS) 
- 	$(CC) -o vsftpd $(OBJS) $(LINK) $(LDFLAGS) $(LIBS)
- 
- install:
--	if [ -x /usr/local/sbin ]; then \
--		$(INSTALL) -m 755 vsftpd /usr/local/sbin/vsftpd; \
--	else \
--		$(INSTALL) -m 755 vsftpd /usr/sbin/vsftpd; fi
--	if [ -x /usr/local/man ]; then \
--		$(INSTALL) -m 644 vsftpd.8 /usr/local/man/man8/vsftpd.8; \
--		$(INSTALL) -m 644 vsftpd.conf.5 /usr/local/man/man5/vsftpd.conf.5; \
--	elif [ -x /usr/share/man ]; then \
--		$(INSTALL) -m 644 vsftpd.8 /usr/share/man/man8/vsftpd.8; \
--		$(INSTALL) -m 644 vsftpd.conf.5 /usr/share/man/man5/vsftpd.conf.5; \
--	else \
--		$(INSTALL) -m 644 vsftpd.8 /usr/man/man8/vsftpd.8; \
--		$(INSTALL) -m 644 vsftpd.conf.5 /usr/man/man5/vsftpd.conf.5; fi
--	if [ -x /etc/xinetd.d ]; then \
--		$(INSTALL) -m 644 xinetd.d/vsftpd /etc/xinetd.d/vsftpd; fi
-+	mkdir -p $(DESTDIR)/usr/sbin
-+	$(INSTALL) -m 755 vsftpd $(DESTDIR)/usr/sbin/
-+	mkdir -p $(DESTDIR)/usr/share/man/man8
-+	$(INSTALL) -m 644 vsftpd.8 $(DESTDIR)/usr/share/man/man8/
-+	mkdir -p $(DESTDIR)/usr/share/man/man5
-+	$(INSTALL) -m 644 vsftpd.conf.5 $(DESTDIR)/usr/share/man/man5/
-+	mkdir -p $(DESTDIR)/etc/xinetd.d
-+	$(INSTALL) -m 644 xinetd.d/vsftpd $(DESTDIR)/etc/xinetd.d/
-+
-+uninstall:
-+	rm -f $(DESTDIR)/usr/sbin/vsftpd
-+	rm -f $(DESTDIR)/usr/share/man/man8/vsftpd.8
-+	rm -f $(DESTDIR)/usr/share/man/man5/vsftpd.conf.5
-+	rm -f $(DESTDIR)/etc/xinetd.d/vsftpd
- 
- clean:
- 	rm -f *.o *.swp vsftpd
 

--- a/net/vsftpd/patches/002-find_libs.patch
+++ /dev/null
@@ -1,14 +1,1 @@
---- a/Makefile
-+++ b/Makefile
-@@ -8,8 +8,8 @@ CFLAGS	=	-O2 -fPIE -fstack-protector --p
- 	-D_FORTIFY_SOURCE=2 \
- 	#-pedantic -Wconversion
- 
--LIBS	=	`./vsf_findlibs.sh`
--LINK	=	-Wl,-s
-+LIBS	=	-lcrypt -lnsl
-+LINK	=
- LDFLAGS	=	-fPIE -pie -Wl,-z,relro -Wl,-z,now
- 
- OBJS	=	main.o utility.o prelogin.o ftpcmdio.o postlogin.o privsock.o \
 

--- a/net/vsftpd/patches/003-chroot.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- a/tunables.c
-+++ b/tunables.c
-@@ -254,7 +254,7 @@ tunables_load_defaults()
-   /* -rw------- */
-   tunable_chown_upload_mode = 0600;
- 
--  install_str_setting("/usr/share/empty", &tunable_secure_chroot_dir);
-+  install_str_setting("/var/run/vsftpd", &tunable_secure_chroot_dir);
-   install_str_setting("ftp", &tunable_ftp_username);
-   install_str_setting("root", &tunable_chown_username);
-   install_str_setting("/var/log/xferlog", &tunable_xferlog_file);
 

--- a/net/vsftpd/patches/004-disable-capabilities.patch
+++ /dev/null
@@ -1,13 +1,1 @@
---- a/sysdeputil.c
-+++ b/sysdeputil.c
-@@ -165,6 +165,9 @@
- #endif
- /* END config */
- 
-+#undef VSF_SYSDEP_HAVE_CAPABILITIES
-+#undef VSF_SYSDEP_HAVE_LIBCAP
-+
- /* PAM support - we include our own dummy version if the system lacks this */
- #include <security/pam_appl.h>
- 
 

--- a/net/vsftpd/patches/005-disable-pam.patch
+++ /dev/null
@@ -1,12 +1,1 @@
---- a/builddefs.h
-+++ b/builddefs.h
-@@ -2,7 +2,7 @@
- #define VSF_BUILDDEFS_H
- 
- #undef VSF_BUILD_TCPWRAPPERS
--#define VSF_BUILD_PAM
-+#undef VSF_BUILD_PAM
- #undef VSF_BUILD_SSL
- 
- #endif /* VSF_BUILDDEFS_H */
 

file:a/net/znc/Makefile (deleted)
--- a/net/znc/Makefile
+++ /dev/null
@@ -1,287 +1,1 @@
-#
-# Copyright (C) 2009-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:=znc
-PKG_VERSION:=1.2
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://znc.in/releases \
-		http://znc.in/releases/archive
-PKG_MD5SUM:=ef18e5402a82cc3fcab5c2ac5c2e6f3b
-
-PKG_BUILD_PARALLEL:=1
-
-
-define Package/znc/default
-  SUBMENU:=Instant Messaging
-  SECTION:=net
-  CATEGORY:=Network
-  TITLE:=ZNC
-  URL:=http://en.znc.in/
-  MAINTAINER:=Jonas Gorski <jogo@openwrt.org>
-endef
-
-define Package/znc
-  $(Package/znc/default)
-  DEPENDS:=+libopenssl +libpthread $(CXX_DEPENDS)
-  MENU:=1
-endef
-
-define Package/znc/description
-	ZNC is an IRC bouncer with many advanced features like detaching,
-	multiple users, per channel playback buffer, SSL, IPv6, transparent DCC
-	bouncing, and c++ module support to name a few.
-endef
-
-define Package/znc/conffiles
-/etc/config/znc
-endef
-
-
-define Package/znc/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/znc $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/znc.init $(1)/etc/init.d/znc
-	$(INSTALL_DIR) $(1)/etc/config
-	$(INSTALL_DATA) ./files/znc.conf $(1)/etc/config/znc
-	$(INSTALL_DIR) $(1)/usr/lib/znc/
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/modules/droproot.so $(1)/usr/lib/znc/
-endef
-
-
-ZNC_MODULES :=
-ZNC_MODULE_TARGETS := droproot.so
-
-define module
-  define Package/znc-mod-$(strip $(1))
-    $(Package/znc/default)
-    TITLE+= ($(strip $(1)) plugin)
-    DEPENDS:=znc
-  endef
-
-  define Package/znc-mod-$(strip $(1))/description
-   $(strip $(2))
-  endef
-
-  define Package/znc-mod-$(strip $(1))/install
-	$(INSTALL_DIR) $$(1)/usr/lib/znc/
-	$(INSTALL_BIN) $$(PKG_BUILD_DIR)/modules/$(subst -,_,$(strip $(1))).so $$(1)/usr/lib/znc/
-	# include webadmin page templates if existing
-	if [ -d $$(PKG_BUILD_DIR)/modules/data/$(subst -,_,$(strip $(1))) ]; then \
-		$(INSTALL_DIR) $$(1)/usr/share/znc/modules ;\
-		$(CP) -r $$(PKG_BUILD_DIR)/modules/data/$(subst -,_,$(strip $(1))) $$(1)/usr/share/znc/modules ;\
-	fi
-  endef
-
-  ZNC_MODULES += znc-mod-$(strip $(1))
-  $(if $(CONFIG_PACKAGE_znc-mod-$(strip $(1))),ZNC_MODULE_TARGETS += $(subst -,_,$(strip $(1))).so)
-endef
-
-define webadmin
-  define Package/znc-mod-webadmin
-    $(Package/znc/default)
-    TITLE+= (webadmin plugin)
-    DEPENDS:=znc
-  endef
-
-  define Package/znc-mod-webadmin/description
-   Allows you to add/remove/edit users and settings on the fly via a web browser.
-  endef
-
-  define Package/znc-mod-webadmin/install
-	$(INSTALL_DIR) $$(1)/usr/lib/znc/
-	$(INSTALL_BIN) $$(PKG_BUILD_DIR)/modules/webadmin.so $$(1)/usr/lib/znc/
-	$(INSTALL_DIR) $$(1)/usr/share/znc/modules
-	$(CP) -r $$(PKG_BUILD_DIR)/modules/data/webadmin $$(1)/usr/share/znc/modules
-	$(INSTALL_DIR) $$(1)/usr/share/znc/webskins/
-	$(CP) -r $$(PKG_BUILD_DIR)/webskins/_default_ $$(1)/usr/share/znc/webskins/
-  endef
-
-  ZNC_MODULES += znc-mod-webadmin
-  $(if $(CONFIG_PACKAGE_znc-mod-webadmin),ZNC_MODULE_TARGETS += webadmin.so)
-endef
-
-define webskin
-  define Package/znc-webskin-$(strip $(1))
-    $(Package/znc/default)
-    TITLE+= ($(strip $(1)) webskin)
-    DEPENDS:=znc-mod-webadmin
-  endef
-
-  define Package/znc-webskin-$(strip $(1))/description
-    $(strip $(1)) webskin for webadmin
-  endef
-
-  define Package/znc-webskin-$(strip $(1))/install
-	$(INSTALL_DIR) $$(1)/usr/share/znc/webskins/
-	$(CP) -r $$(PKG_BUILD_DIR)/webskins/$(strip $(1)) $$(1)/usr/share/znc/webskins/
-  endef
-  ZNC_MODULES += znc-webskin-$(strip $(1))
-endef
-
-, := ,
-
-$(eval $(call module,adminlog,Log user connects and disconnects and failed \
-	logins to file or syslog.))
-
-$(eval $(call module,autoattach,Reattaches you to channels on activity.))
-
-$(eval $(call module,autocycle,Cycles a channel when you are the only one in \
-	there and you don't have op.))
-
-$(eval $(call module,autoop,Auto op the good guys.))
-
-$(eval $(call module,autoreply,Gives a automatic reply if someone messages you \
-	if you are away.))
-
-$(eval $(call module,autovoice,Autovoices everyone who joins some channel.))
-
-$(eval $(call module,awaynick,Change your nick while you are away.))
-
-$(eval $(call module,awaystore,Stores messages while away$(,) also auto away.))
-
-$(eval $(call module,block-motd,This module blocks the server's Message of the \
-	Day.))
-
-$(eval $(call module,blockuser,Blocks certain users from using ZNC saying \
-	their account was disabled.))
-
-$(eval $(call module,bouncedcc,Bounces dcc transfers through the znc server \
-	instead of sending them directly to the user.))
-
-$(eval $(call module,buffextras,Add nick changes$(,) joins$(,) parts$(,) topic \
-	changes etc. to your playback buffer.))
-
-$(eval $(call module,cert,Use a SSL certificate for connecting to a server.))
-
-$(eval $(call module,certauth,This module allows users to log in to ZNC via \
-	SSL client keys.))
-
-$(eval $(call module,chansaver,Keeping config up to date when user joins and \
-	parts.))
-
-$(eval $(call module,clearbufferonmsg,This module keeps the buffer until the \
-	next message from the client.))
-
-$(eval $(call module,clientnotify,Notify about new incoming connections to \
-	your user.))
-
-$(eval $(call module,controlpanel,Allows you to add/remove/edit users and \
-	settings on the fly via IRC messages.))
-
-$(eval $(call module,crypt,Encryption for channel/private messages.))
-
-$(eval $(call module,ctcpflood,This module tries to block ctcp floods.))
-
-$(eval $(call module,dcc,Allows you to transfer files to and from ZNC.))
-
-$(eval $(call module,disconkick,This module will kick your client from all \
-	channels where you are$(,) in case if ZNC disconnects from server.))
-
-$(eval $(call module,fail2ban,Block IPs for some time after a failed login.))
-
-$(eval $(call module,flooddetach,This module detaches you from channels which \
-	are flooded.))
-
-$(eval $(call module,identfile,Places the ident of a user to a file when they \
-	 are trying to connect.))
-
-$(eval $(call module,keepnick,Tries to get you your primary nick.))
-
-$(eval $(call module,kickrejoin,Implements auto-rejoin-on-kick.))
-
-$(eval $(call module,lastseen,Logs when a user last logged in to ZNC.))
-
-$(eval $(call module,listsockets,This module displays a list of all open \
-	sockets in ZNC.))
-
-$(eval $(call module,log,Log conversations to file.))
-
-$(eval $(call module,modules_online,This module fakes the online status of \
-	ZNC-*users.))
-
-$(eval $(call module,nickserv,Auths you with NickServ.))
-
-$(eval $(call module,notes,This modules stores and displays short notes using \
-	a key/note pairs and shows them to you on connect.))
-
-$(eval $(call module,notify-connect,Sends a notice to all admins when a user \
-	logs in or out.))
-
-$(eval $(call module,partyline,Allows ZNC users to join internal channels and \
-	query other ZNC users on the same ZNC.))
-
-$(eval $(call module,perform,Performs commands on connect.))
-
-$(eval $(call module,q,Auths you with Q (and a little more).))
-
-$(eval $(call module,raw,View all of the raw traffic.))
-
-$(eval $(call module,route-replies,Routes back answers to the right client \
-	when connected with multiple clients.))
-
-$(eval $(call module,sasl,The SASL module allows you to authenticate to an \
-	IRC network via SASL.))
-
-$(eval $(call module,savebuff,Saves your channel buffers into an encrypted \
-	file so they can survive restarts and reboots.))
-
-$(eval $(call module,schat,SSL (encrypted) DCC chats.))
-
-$(eval $(call module,send-raw,Allows you to send raw traffic to IRC from \
-	other users.))
-
-$(eval $(call module,simple-away,This module will automatically set you away \
-	on IRC while you are disconnected from the bouncer.))
-
-$(eval $(call module,shell,Have your unix shell in a query window right inside \
-	of your IRC client.))
-
-$(eval $(call module,stickychan,Keeps you sticked to specific channels.))
-
-$(eval $(call module,watch,Monitor activity for specific text patterns from \
-	specific users and have the text sent to a special query window.))
-
-$(eval $(call webadmin))
-
-$(eval $(call webskin,dark-clouds))
-$(eval $(call webskin,forest))
-$(eval $(call webskin,ice))
-
-PKG_CONFIG_DEPENDS := $(patsubst %,CONFIG_PACKAGE_%,$(ZNC_MODULES))
-
-include $(INCLUDE_DIR)/uclibc++.mk
-include $(INCLUDE_DIR)/package.mk
-
-CONFIGURE_VARS += \
-	CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -fno-rtti -nostdinc++" \
-	CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
-	LDFLAGS="-nodefaultlibs -lc -L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
-	LIBS="-luClibc++ -lm -lssl -lcrypto $(LIBGCC_S) -lc"
-
-CONFIGURE_ARGS += \
-	--disable-c-ares \
-	--disable-perl
-
-define Build/Configure
-	$(call Build/Configure/Default,)
-	$(call libtool_disable_rpath)
-endef
-
-define Build/Compile
-	$(call Build/Compile/Default,znc)
-	+$(MAKE_VARS) $(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR)/modules \
-		$(MAKE_FLAGS) $(ZNC_MODULE_TARGETS)
-endef
-
-$(eval $(call BuildPackage,znc))
-$(foreach m,$(ZNC_MODULES),$(eval $(call BuildPackage,$(m))))
-

file:a/net/znc/files/znc.conf (deleted)
--- a/net/znc/files/znc.conf
+++ /dev/null
@@ -1,30 +1,1 @@
-config znc
-	# where to listen for connections
-	list listener	'192.168.1.1 1234'
-	# If using SSL sockets, use the following certifcate:
-	# option znc_ssl_cert '/etc/znc.cert'
 
-	# load global modules (You need to install them first):
-	# list module 'fail2ban'
-
-	# remove this to enable the service
-	option disabled 1
-
-config user 'sampleUser'
-	# Use either a plain text password or use the full sha256#... line.
-	# You can generate one with 'znc -s'.
-	option password 'changeme'
-	option nick 	'sampleUser'
-	option altnick 	'userSample'
-	option ident 	'openwrt'
-	option realname 'John Doe'
-
-	# This adds support for channels in znc configuration:
-	# list channel    '#chan optional_password'
-
-	# list of allowed servers:
-	# list server 	'chat.freenode.net 6667'
-
-	# load user modules ('<module> [params...]'):
-	# list module 'simple_away -timer 10 disconnected'
-

file:a/net/znc/files/znc.init (deleted)
--- a/net/znc/files/znc.init
+++ /dev/null
@@ -1,195 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2010 Openwrt.org
 
-START=60
-
-ZNC_CONFIG_PATH=/tmp/etc/znc
-PID_FILE=${ZNC_CONFIG_PATH}/znc.pid
-ZNC_CONFIG=${ZNC_CONFIG_PATH}/configs/znc.conf
-
-EXTERNAL_CONFIG=0
-DISABLED=
-
-RUNAS_USER=
-RUNAS_GROUP=
-
-add_param() {
-	echo "$1 = $2" >> $ZNC_CONFIG
-}
-
-add_chan() {
-	chan=${1% *}
-	pass=${1#* }
-	echo "		<Chan $chan>" >> $ZNC_CONFIG
-	[ "$chan" != "$pass" ] && echo "			Key = $pass" >> $ZNC_CONFIG
-	echo "		</Chan>" >> $ZNC_CONFIG
-}
-
-add_network() {
-	local current_user="$1"
-	local network="$2"
-	local user
-	local name
-
-	config_get user "$network" user
-
-	[ "$user" = "$current_user" ] || return 0
-
-	config_get name "$network" name
-	echo "	<Network $name>" >> $ZNC_CONFIG
-	config_list_foreach "$network" server "add_param \"		Server\""
-	config_list_foreach "$network" channel "add_chan"
-}
-
-znc_global() {
-	local znc="$1"
-	local anoniplimit
-	local maxbuffersize
-	local connectdelay
-	local serverthrottle
-	local znc_config_path
-	local znc_pem_file
-
-	config_get_bool DISABLED "$znc" disabled 0
-
-	[ "$DISABLED" -eq 0 ] || return 0
-
-	config_get znc_config_path "$znc" znc_config_path
-
-	config_get RUNAS_USER "$znc" runas_user
-	config_get RUNAS_GROUP "$znc" runas_group
-
-	if [ "${znc_config_path}" ]
-	then
-		ZNC_CONFIG_PATH=$znc_config_path
-		EXTERNAL_CONFIG=1
-	else
-		mkdir -p $ZNC_CONFIG_PATH/configs/
-		[ ! -f "$ZNC_CONFIG" ] || rm "$ZNC_CONFIG"
-
-		add_param "Version" "1.0"
-
-		config_get anoniplimit "$znc" anoniplimit
-		config_get maxbuffersize "$znc" maxbuffersize
-		config_get connectdelay "$znc" connectdelay
-		config_get serverthrottle "$znc" serverthrottle
-		config_get znc_pem_file "$znc" znc_ssl_cert
-
-		[ -z "$znc_pem_file" ] || ln -sf "$znc_pem_file" $ZNC_CONFIG_PATH/znc.pem
-
-		[ -z $anoniplimit ] || echo "AnonIPLimit = $anoniplimit" >> $ZNC_CONFIG
-		[ -z $maxbuffersize ] || echo "MaxBufferSize = $maxbuffersize" >> $ZNC_CONFIG
-		[ -z $connectdelay ] || echo "ConnectDelay = $connectdelay" >> $ZNC_CONFIG
-		[ -z $serverthrottle ] || echo "ServerThrottle = $anoniplimit" >> $ZNC_CONFIG
-
-		echo "PidFile = $PID_FILE" >> $ZNC_CONFIG
-
-		config_list_foreach "$znc" listener "add_param Listener"
-		config_list_foreach "$znc" module "add_param LoadModule"
-
-		add_param LoadModule "droproot ${RUNAS_USER:-nobody} ${RUNAS_GROUP:-nogroup}"
-	fi
-}
-
-add_user() {
-	local user="$1"
-	local password
-	local nick
-	local altnick
-	local ident
-	local realname
-	local buffer
-	local quitmsg
-	local chanmodes
-	local vhost
-	local server
-
-	config_get password "$user" password
-	config_get nick "$user" nick
-	config_get altnick "$user" altnick
-	config_get ident "$user" ident
-	config_get realname "$user" realname
-	config_get buffer "$user" buffer
-	config_get quitmsg "$user" quitmsg
-	config_get chanmodes "$user" chanmodes
-	config_get vhost "$user" vhost
-	config_get server "$user" server
-
-	echo "<User $user>" >> $ZNC_CONFIG
-
-	case "$password" in
-	"md5#"* | "sha256#"* | "plain#"*)
-		add_param "	Pass" "$password"
-		;;
-	*)
-		add_param "	Pass" "plain#$password"
-		;;
-	esac
-
-	add_param "	Nick" "$nick"
-	add_param "	AltNick" "${altnick:-$nick"_"}"
-	add_param "	Ident" "${ident:-$nick}"
-	add_param "	RealName" "${realname:-$nick}"
-	[ -z "$vhost" ] || add_param "	VHost" "$vhost"
-	add_param "	Buffer" "${buffer:-50}"
-	add_param "	KeepBuffer" "false"
-	add_param "	ChanModes" "${chanmodes:-"+stn"}"
-	[ -z "$quitmsg" ] || add_param "	QuitMsg" "$quitmsg"
-
-	config_list_foreach "$user" module "add_param \"	LoadModule\""
-
-	# add legacy network
-	if [ "$server" ]; then
-		echo "	<Network Default>" >> $ZNC_CONFIG
-		config_list_foreach "$user" server "add_param \"		Server\""
-		config_list_foreach "$user" channel "add_chan"
-		echo "	</Network>" >> $ZNC_CONFIG
-	fi
-
-	config_foreach "add_network \"$user\"" network
-
-	echo "</User>" >> $ZNC_CONFIG
-}
-
-
-start() {
-	config_load znc
-	config_foreach znc_global znc
-
-	if [ "$DISABLED" -eq 1 ]; then
-		return 0
-	fi
-
-	if [ "$EXTERNAL_CONFIG" -eq 0 ]
-	then
-		config_foreach add_listener listener
-		config_foreach add_user user
-
-		chown -hR ${RUNAS_USER:-nobody}:${RUNAS_GROUP:-nogroup} /tmp/etc/znc
-	fi
-
-	if [ "$EXTERNAL_CONFIG" -eq 1 -a "$RUNAS_USER"  ]
-	then
-		local SU=$(which su)
-		if [ "$SU" ]
-		then
-			$SU -c "/usr/bin/znc -d$ZNC_CONFIG_PATH >/dev/null &" $RUNAS_USER
-		else
-			logger -s -t ZNC -p daemon.err "Could not run ZNC as user $RUNAS_USER: su not found."
-			exit 1
-		fi
-	else
-		/usr/bin/znc -d$ZNC_CONFIG_PATH >/dev/null &
-	fi
-}
-
-stop() {
-	if [ -f "$PID_FILE" ]
-	then
-		kill $(cat "$PID_FILE")
-	else
-		killall znc
-	fi
-}
-
-

--- a/net/znc/patches/001-move_rootcheck_after_config.patch
+++ /dev/null
@@ -1,53 +1,1 @@
-From 5f655f9a25a377c01cb15517859eb514628a43d4 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski+openwrt@gmail.com>
-Date: Wed, 6 Apr 2011 04:10:23 +0200
-Subject: [PATCH] Move the root check to after config parsing
 
----
- src/main.cpp |   27 ++++++++++++++-------------
- 1 files changed, 14 insertions(+), 13 deletions(-)
-
---- a/src/main.cpp
-+++ b/src/main.cpp
-@@ -243,19 +243,6 @@ int main(int argc, char** argv) {
- 		CUtils::PrintStatus(true, "");
- 	}
- 
--	if (isRoot()) {
--		CUtils::PrintError("You are running ZNC as root! Don't do that! There are not many valid");
--		CUtils::PrintError("reasons for this and it can, in theory, cause great damage!");
--		if (!bAllowRoot) {
--			delete pZNC;
--			return 1;
--		}
--		CUtils::PrintError("You have been warned.");
--		CUtils::PrintError("Hit CTRL+C now if you don't want to run ZNC as root.");
--		CUtils::PrintError("ZNC will start in 30 seconds.");
--		sleep(30);
--	}
--
- 	if (bMakeConf) {
- 		if (!pZNC->WriteNewConfig(sConfig)) {
- 			delete pZNC;
-@@ -276,6 +263,20 @@ int main(int argc, char** argv) {
- 		return 1;
- 	}
- 
-+	if (isRoot()) {
-+		CUtils::PrintError("You are running ZNC as root! Don't do that! There are not many valid");
-+		CUtils::PrintError("reasons for this and it can, in theory, cause great damage!");
-+		if (!bAllowRoot) {
-+			delete pZNC;
-+			return 1;
-+		}
-+		CUtils::PrintError("You have been warned.");
-+		CUtils::PrintError("Hit CTRL+C now if you don't want to run ZNC as root.");
-+		CUtils::PrintError("ZNC will start in 30 seconds.");
-+		sleep(30);
-+	}
-+
-+
- 	if (bForeground) {
- 		int iPid = getpid();
- 		CUtils::PrintMessage("Staying open for debugging [pid: " + CString(iPid) + "]");
-

--- a/net/znc/patches/002-Uclibcpp_build_fix.patch
+++ /dev/null
@@ -1,29 +1,1 @@
-From fa14938321eda39f16bee6068296e6abc9df7b85 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski+openwrt@gmail.com>
-Date: Wed, 6 Apr 2011 04:11:48 +0200
-Subject: [PATCH] Add a uClibc++ build workaround
 
----
- modules/webadmin.cpp |    4 +++-
- 1 files changed, 3 insertions(+), 1 deletions(-)
-
---- a/modules/webadmin.cpp
-+++ b/modules/webadmin.cpp
-@@ -20,6 +20,7 @@
- #include <znc/IRCNetwork.h>
- #include <znc/IRCSock.h>
- 
-+using std::string;
- using std::stringstream;
- using std::make_pair;
- using std::set;
-@@ -75,7 +76,7 @@ class CWebAdminMod : public CModule {
- public:
- 	MODCONSTRUCTOR(CWebAdminMod) {
- 		VPair vParams;
--		vParams.push_back(make_pair("user", ""));
-+		vParams.push_back(make_pair((string)"user", (string)""));
- 		AddSubPage(new CWebSubPage("settings", "Global Settings", CWebSubPage::F_ADMIN));
- 		AddSubPage(new CWebSubPage("edituser", "Your Settings", vParams));
- 		AddSubPage(new CWebSubPage("traffic", "Traffic Info", CWebSubPage::F_ADMIN));
-

--- a/net/znc/patches/003-Reduce_rebuild_time.patch
+++ /dev/null
@@ -1,39 +1,1 @@
-From 94aff4c3389111fc85054eb06b40bea26a216d0c Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski+openwrt@gmail.com>
-Date: Sat, 16 Apr 2011 05:51:04 +0200
-Subject: [PATCH] Don't rebuild everything when the Makefile's timestamp changed
 
----
- Makefile.in         |    2 +-
- modules/Makefile.in |    2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -104,7 +104,7 @@ clean:
- distclean: clean
- 	rm -rf $(DISTCLEAN)
- 
--src/%.o: src/%.cpp Makefile
-+src/%.o: src/%.cpp
- 	@mkdir -p .depend src
- 	$(E) Building core object $*...
- 	$(Q)$(CXX) $(CXXFLAGS) -c -o $@ $< -MD -MF .depend/$*.dep -MT $@
---- a/modules/Makefile.in
-+++ b/modules/Makefile.in
-@@ -117,12 +117,12 @@ install_datadir:
- clean:
- 	rm -rf $(CLEAN)
- 
--%.o: %.cpp Makefile
-+%.o: %.cpp
- 	@mkdir -p .depend
- 	$(E) Building module $(notdir $(basename $@))...
- 	$(Q)$(CXX) $(MODFLAGS) -c -o $@ $< $($(notdir $(basename $@))CXXFLAGS) -MD -MF .depend/$(notdir $@).dep
- 
--%.so: %.o Makefile
-+%.so: %.o
- 	$(E) "Linking  module" $(notdir $(basename $@))...
- 	$(Q)$(CXX) $(MODFLAGS) $(LDFLAGS) $(MODLINK) -o $@ $< $($(notdir $(basename $@))LDFLAGS) $(LIBS)
- 
-

--- a/net/znc/patches/004-restore_droproot.patch
+++ /dev/null
@@ -1,148 +1,1 @@
---- /dev/null
-+++ b/modules/droproot.cpp
-@@ -0,0 +1,144 @@
-+/*
-+ * droproot.cpp
-+ *
-+ * Copyright (c) 2009 Vadtec (vadtec@vadtec.net)
-+ * This program is free software; you can redistribute it and/or modify it
-+ * under the terms of the GNU General Public License version 2 as published
-+ * by the Free Software Foundation.
-+ *
-+ * Copyright (C) 2004-2012  See the AUTHORS file for details.
-+ *
-+ * This program is free software; you can redistribute it and/or modify it
-+ * under the terms of the GNU General Public License version 2 as published
-+ * by the Free Software Foundation.
-+ */
-+
-+#include <znc/znc.h>
-+#include <znc/User.h>
-+#include <pwd.h>
-+#include <grp.h>
-+
-+class CDroproot : public CModule {
-+
-+public:
-+	MODCONSTRUCTOR(CDroproot) {
-+	}
-+
-+	virtual ~CDroproot() {
-+	}
-+
-+	uid_t GetUser(const CString& sUser, CString& sMessage) {
-+		uid_t ret = sUser.ToUInt();
-+
-+		if (ret != 0)
-+			return ret;
-+
-+		struct passwd *pUser = getpwnam(sUser.c_str());
-+
-+		if (!pUser) {
-+			sMessage = "User [" + sUser + "] not found!";
-+			return 0;
-+		}
-+
-+		return pUser->pw_uid;
-+	}
-+
-+	gid_t GetGroup(const CString& sGroup, CString& sMessage) {
-+		gid_t ret = sGroup.ToUInt();
-+
-+		if (ret != 0)
-+			return ret;
-+
-+		struct group *pGroup = getgrnam(sGroup.c_str());
-+
-+		if (!pGroup) {
-+			sMessage = "Group [" + sGroup + "] not found!";
-+			return 0;
-+		}
-+
-+		return pGroup->gr_gid;
-+	}
-+
-+	virtual bool OnLoad(const CString& sArgs, CString& sMessage) {
-+		CString sUser = sArgs.Token(0);
-+		CString sGroup = sArgs.Token(1, true);
-+
-+		if (sUser.empty() || sGroup.empty()) {
-+			sMessage = "Usage: LoadModule = Droproot <uid> <gid>";
-+			return false;
-+		}
-+
-+		m_user = GetUser(sUser, sMessage);
-+
-+		if (m_user == 0) {
-+			sMessage
-+					= "Error: Cannot run as root, check your config file | Useage: LoadModule = Droproot <uid> <gid>";
-+			return false;
-+		}
-+
-+		m_group = GetGroup(sGroup, sMessage);
-+
-+		if (m_group == 0) {
-+			sMessage
-+					= "Error: Cannot run as root, check your config file | Useage: LoadModule = Droproot <uid> <gid>";
-+			return false;
-+		}
-+
-+		return true;
-+	}
-+
-+	virtual bool OnBoot() {
-+		int u, eu, g, eg, sg;
-+
-+		if ((geteuid() == 0) || (getuid() == 0) || (getegid() == 0) || (getgid()
-+				== 0)) {
-+
-+			CUtils::PrintAction("Dropping root permissions");
-+
-+			// Clear all the supplementary groups
-+			sg = setgroups(0, NULL);
-+
-+			if (sg < 0) {
-+				CUtils::PrintStatus(false,
-+						"Could not remove supplementary groups! ["
-+								+ CString(strerror(errno)) + "]");
-+
-+				return false;
-+			}
-+
-+			// Set the group (if we are root, this sets all three group IDs)
-+			g = setgid(m_group);
-+			eg = setegid(m_group);
-+
-+			if ((g < 0) || (eg < 0)) {
-+				CUtils::PrintStatus(false, "Could not switch group id! ["
-+						+ CString(strerror(errno)) + "]");
-+
-+				return false;
-+			}
-+
-+			// and set the user (if we are root, this sets all three user IDs)
-+			u = setuid(m_user);
-+			eu = seteuid(m_user);
-+
-+			if ((u < 0) || (eu < 0)) {
-+				CUtils::PrintStatus(false, "Could not switch user id! ["
-+						+ CString(strerror(errno)) + "]");
-+
-+				return false;
-+			}
-+
-+			CUtils::PrintStatus(true);
-+
-+			return true;
-+		}
-+
-+		return true;
-+	}
-+
-+protected:
-+	uid_t m_user;
-+	gid_t m_group;
-+};
-+
-+GLOBALMODULEDEFS(CDroproot, "Allows ZNC to drop root privileges and run as an un-privileged user.")
 

file:a/sound/lame/Makefile (deleted)
--- a/sound/lame/Makefile
+++ /dev/null
@@ -1,83 +1,1 @@
-#
-# Copyright (C) 2007-2008 OpenWrt.org
-#
-# This is free software, licensed under the GNU General Public License v2.
-# See /LICENSE for more information.
-#
-# blogic@openwrt.org
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=lame
-PKG_VERSION:=398-2
-PKG_RELEASE:=3
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=@SF/lame
-PKG_MD5SUM:=719dae0ee675d0c16e0e89952930ed35
-PKG_FIXUP:=autoreconf
-
-PKG_LICENSE:=LGPLv2
-PKG_LICENSE_FILES:=COPYING LICENSE
-
-include $(INCLUDE_DIR)/package.mk
-
-PKG_INSTALL=1
-
-define Package/lame/Default
-  SECTION:=sound
-  CATEGORY:=Sound
-  URL:=http://sourceforge.net/projects/lame
-  DEPENDS:=@BUILD_PATENTED
-endef
-
-define Package/lame
-$(call Package/lame/Default)
-  TITLE:=lame
-  MENU:=1
-  DEPENDS += +libncurses
-endef
-
-define Package/lame/description
-lame mp3 encoder
-endef
-
-define Package/lame-lib
-$(call Package/lame/Default)
-  TITLE:=lame-lib
-endef
-
-define Package/lame-lib/description
-lame mp3 encoder libs
-endef
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-	--disable-nasm \
-	)
-endef
-
-
-define Package/lame/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/lame $(1)/usr/bin/
-endef
-
-define Package/lame-lib/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*so* $(1)/usr/lib/
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include/lame
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/include/lame/*.h \
-		$(1)/usr/include/lame/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/*.{la,so*} \
-		$(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,lame-lib))
-$(eval $(call BuildPackage,lame))
-

--- a/sound/lame/patches/001-automake-compat.patch
+++ /dev/null
@@ -1,34 +1,1 @@
---- a/configure.in
-+++ b/configure.in
-@@ -385,7 +385,7 @@ CONFIG_MATH_LIB="${USE_LIBM}"
- 
- dnl configure use of features
- 
--AM_PATH_GTK(1.2.0, HAVE_GTK="yes", HAVE_GTK="no")
-+HAVE_GTK="no"
- 
- dnl ElectricFence malloc debugging
- AC_MSG_CHECKING(use of ElectricFence malloc debugging)
---- a/frontend/Makefile.am
-+++ b/frontend/Makefile.am
-@@ -51,7 +51,7 @@ mp3rtp_SOURCES = mp3rtp.c rtp.c rtp.h $(
- mp3x_SOURCES = mp3x.c gtkanal.c gpkplotting.c $(common_sources)
- endif
- 
--CFLAGS = @CFLAGS@ @GTK_CFLAGS@ @FRONTEND_CFLAGS@ @SNDFILE_CFLAGS@
-+CFLAGS = @CFLAGS@ @FRONTEND_CFLAGS@ @SNDFILE_CFLAGS@
- LDFLAGS = @LDFLAGS@ @FRONTEND_LDFLAGS@ @SNDFILE_LIBS@ -static
- 
- INCLUDES = -I$(top_srcdir)/libmp3lame -I$(top_srcdir)/include -I$(top_builddir)
---- a/frontend/Makefile.in
-+++ b/frontend/Makefile.in
-@@ -113,7 +113,7 @@ AUTOMAKE = @AUTOMAKE@
- AWK = @AWK@
- CC = @CC@
- CCDEPMODE = @CCDEPMODE@
--CFLAGS = @CFLAGS@ @GTK_CFLAGS@ @FRONTEND_CFLAGS@ @SNDFILE_CFLAGS@
-+CFLAGS = @CFLAGS@ @FRONTEND_CFLAGS@ @SNDFILE_CFLAGS@
- CONFIG_DEFS = @CONFIG_DEFS@
- CONFIG_MATH_LIB = @CONFIG_MATH_LIB@
- CPP = @CPP@
 

file:a/sound/sox/Makefile (deleted)
--- a/sound/sox/Makefile
+++ /dev/null
@@ -1,88 +1,1 @@
-#
-# Copyright (C) 2008 David Cooper <dave@kupesoft.com>
-# 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:=sox
-PKG_VERSION:=14.4.1
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_SOURCE_URL:=@SF/sox
-PKG_MD5SUM:=ff9ca6aca972549de0e80e8e30ed379c
-
-PKG_LICENSE:=LGPLv2.1 GPLv2
-PKG_LICENSE_FILES:=COPYING LICENSE.LGPL LICENSE.GPL
-
-PKG_INSTALL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-TARGET_LDFLAGS+= \
-	-Wl,-rpath-link=$(STAGING_DIR)/usr/lib
-
-define Package/sox
-  SECTION:=sound
-  CATEGORY:=Sound
-  DEPENDS:=+BUILD_PATENTED:lame-lib +BUILD_PATENTED:libmad +BUILD_PATENTED:libid3tag +libvorbis +libvorbisidec +libgsm +alsa-lib +libsndfile +libflac +ffmpeg +libmagic +libpng +libao
-  TITLE:=Sox is a general purpose sound converter/player/recorder
-  URL:=http://sox.sourceforge.net/
-  MAINTAINER:=Hamish Guthrie <hcg@openwrt.org>
-endef
-
-define Package/sox/description
-	SoX is a command line utility that can convert various formats
-	of computer audio files in to other formats. It can also apply
-	various effects to these sound files during the conversion.
-	As an added bonus, SoX can play and record audio files on
-	several unix-style platforms.
-endef
-
-define Build/Configure
-	$(call Build/Configure/Default, \
-		--disable-external-gsm \
-		--disable-oss \
-		--enable-alsa \
-		--disable-libao \
-		--without-libltdl \
-		--with-ogg \
-		--with-flac \
-		--with-ffmpeg \
-		--without-amr-wb \
-		--without-amr-nb \
-		--without-samplerate \
-		--without-ladspa \
-		--$(if $(CONFIG_BUILD_PATENTED),with-mad,without-mad) \
-		--$(if $(CONFIG_BUILD_PATENTED),with-lame,without-lame) \
-		--$(if $(CONFIG_BUILD_PATENTED),with-id3tag,without-id3tag) \
-	)
-endef
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/include \
-		$(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
-	$(CP) \
-		$(PKG_INSTALL_DIR)/usr/lib/libsox.{a,so*,la} \
-		$(1)/usr/lib/
-	$(INSTALL_DATA) \
-		$(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
-		$(1)/usr/lib/pkgconfig/
-endef
-
-define Package/sox/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_INSTALL_DIR)/usr/bin/{play,rec,sox} $(1)/usr/bin/
-	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libsox.so* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,sox))
-

--- a/sound/sox/patches/001-cross_compile.patch
+++ /dev/null
@@ -1,23 +1,1 @@
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -144,7 +144,7 @@ EXTRA_DIST = monkey.wav optional-fmts.am
- 	     CMakeLists.txt soxconfig.h.cmake \
- 	     tests.sh testall.sh tests.bat testall.bat test-comments
- 
--all: sox$(EXEEXT) play rec soxi sox_sample_test$(EXEEXT) example0$(EXEEXT) example1$(EXEEXT) example2$(EXEEXT) example3$(EXEEXT) example4$(EXEEXT) example5$(EXEEXT)
-+all: sox$(EXEEXT) play rec
- 
- play rec: sox$(EXEEXT)
- 	if test "$(PLAYRECLINKS)" = "yes"; then	\
---- sox-14.4.1/src/Makefile.in
-+++ sox-14.4.1/src/Makefile.in
-@@ -2904,7 +2904,7 @@
- 	uninstall-libLTLIBRARIES uninstall-pkglibLTLIBRARIES
- 
- 
--all: sox$(EXEEXT) play rec soxi sox_sample_test$(EXEEXT) example0$(EXEEXT) example1$(EXEEXT) example2$(EXEEXT) example3$(EXEEXT) example4$(EXEEXT) example5$(EXEEXT)
-+all: sox$(EXEEXT) play rec
- 
- play rec: sox$(EXEEXT)
- 	if test "$(PLAYRECLINKS)" = "yes"; then	\
 

--- a/sound/sox/patches/010-fix_uclibc_build_issue.patch
+++ /dev/null
@@ -1,20 +1,1 @@
---- sox-14.4.1.orig/src/formats.c
-+++ sox-14.4.1/src/formats.c
-@@ -409,7 +409,7 @@ static void UNUSED rewind_pipe(FILE * fp
- #if defined _FSTDIO || defined _NEWLIB_VERSION || defined __APPLE__
-   fp->_p -= PIPE_AUTO_DETECT_SIZE;
-   fp->_r += PIPE_AUTO_DETECT_SIZE;
--#elif defined __GLIBC__
-+#elif defined __GLIBC__ && ! defined __UCLIBC__
-   fp->_IO_read_ptr = fp->_IO_read_base;
- #elif defined _MSC_VER || defined _WIN32 || defined _WIN64 || defined _ISO_STDIO_ISO_H
-   fp->_ptr = fp->_base;
-@@ -417,7 +417,6 @@ static void UNUSED rewind_pipe(FILE * fp
-   /* To fix this #error, either simply remove the #error line and live without
-    * file-type detection with pipes, or add support for your compiler in the
-    * lines above.  Test with cat monkey.wav | ./sox --info - */
--  #error FIX NEEDED HERE
-   #define NO_REWIND_PIPE
-   (void)fp;
- #endif
 

--- a/sound/sox/patches/020-ffmpeg-0.11.patch
+++ /dev/null
@@ -1,130 +1,1 @@
---- a/configure
-+++ b/configure
-@@ -15825,9 +15825,9 @@
-   cat >>confdefs.h <<_ACEOF
- #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
- _ACEOF
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for av_open_input_file in -lavformat" >&5
--$as_echo_n "checking for av_open_input_file in -lavformat... " >&6; }
--if ${ac_cv_lib_avformat_av_open_input_file+:} false; then :
-+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for avformat_open_input in -lavformat" >&5
-+$as_echo_n "checking for avformat_open_input in -lavformat... " >&6; }
-+if ${ac_cv_lib_avformat_avformat_open_input+:} false; then :
-   $as_echo_n "(cached) " >&6
- else
-   ac_check_lib_save_LIBS=$LIBS
-@@ -15841,27 +15841,27 @@
- #ifdef __cplusplus
- extern "C"
- #endif
--char av_open_input_file ();
-+char avformat_open_input ();
- int
- main ()
- {
--return av_open_input_file ();
-+return avformat_open_input ();
-   ;
-   return 0;
- }
- _ACEOF
- if ac_fn_c_try_link "$LINENO"; then :
--  ac_cv_lib_avformat_av_open_input_file=yes
-+  ac_cv_lib_avformat_avformat_open_input=yes
- else
--  ac_cv_lib_avformat_av_open_input_file=no
-+  ac_cv_lib_avformat_avformat_open_input=no
- fi
- rm -f core conftest.err conftest.$ac_objext \
-     conftest$ac_exeext conftest.$ac_ext
- LIBS=$ac_check_lib_save_LIBS
- fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_avformat_av_open_input_file" >&5
--$as_echo "$ac_cv_lib_avformat_av_open_input_file" >&6; }
--if test "x$ac_cv_lib_avformat_av_open_input_file" = xyes; then :
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_avformat_avformat_open_input" >&5
-+$as_echo "$ac_cv_lib_avformat_avformat_open_input" >&6; }
-+if test "x$ac_cv_lib_avformat_avformat_open_input" = xyes; then :
-   for ac_header in libavcodec/avcodec.h ffmpeg/avcodec.h
- do :
-   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-diff -Naur sox-14.4.0-orig/src/ffmpeg.c sox-14.4.0/src/ffmpeg.c
---- sox-14.4.0-orig/src/ffmpeg.c	2012-06-12 00:35:53.459027469 -0400
-+++ sox-14.4.0/src/ffmpeg.c	2012-06-12 00:36:26.539028545 -0400
-@@ -93,7 +93,7 @@
- #if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
-   enc->error_resilience = 1;
- #else
--  enc->error_recognition = 1;
-+  enc->err_recognition = 1;
- #endif
- 
-   if (!codec || avcodec_open(enc, codec) < 0)
-@@ -157,7 +157,7 @@
- static int startread(sox_format_t * ft)
- {
-   priv_t * ffmpeg = (priv_t *)ft->priv;
--  AVFormatParameters params;
-+  AVDictionary *params;
-   int ret;
-   int i;
- 
-@@ -172,7 +172,7 @@
- 
-   /* Open file and get format */
-   memset(&params, 0, sizeof(params));
--  if ((ret = av_open_input_file(&ffmpeg->ctxt, ft->filename, NULL, 0, &params)) < 0) {
-+  if ((ret = avformat_open_input(&ffmpeg->ctxt, ft->filename, NULL, &params)) < 0) {
-     lsx_fail("ffmpeg cannot open file for reading: %s (code %d)", ft->filename, ret);
-     return SOX_EOF;
-   }
-@@ -231,7 +231,7 @@
-     /* If input buffer empty, read more data */
-     if (ffmpeg->audio_buf_index * 2 >= ffmpeg->audio_buf_size) {
-       if ((ret = av_read_frame(ffmpeg->ctxt, pkt)) < 0 &&
--	  (ret == AVERROR_EOF || url_ferror(ffmpeg->ctxt->pb)))
-+	  (ret == AVERROR_EOF || ffmpeg->ctxt->pb->error))
- 	break;
-       ffmpeg->audio_buf_size = audio_decode_frame(ffmpeg, ffmpeg->audio_buf_aligned, AVCODEC_MAX_AUDIO_FRAME_SIZE);
-       ffmpeg->audio_buf_index = 0;
-@@ -373,13 +373,6 @@
-       return SOX_EOF;
-   }
- 
--  /* set the output parameters (must be done even if no
--     parameters). */
--  if (av_set_parameters(ffmpeg->ctxt, NULL) < 0) {
--    lsx_fail("ffmpeg invalid output format parameters");
--    return SOX_EOF;
--  }
--
-   /* Next line for debugging */
-   /* dump_format(ffmpeg->ctxt, 0, ft->filename, 1); */
- 
-@@ -391,14 +384,14 @@
- 
-   /* open the output file, if needed */
-   if (!(ffmpeg->fmt->flags & AVFMT_NOFILE)) {
--    if (url_fopen(&ffmpeg->ctxt->pb, ft->filename, URL_WRONLY) < 0) {
-+    if (avio_open(&ffmpeg->ctxt->pb, ft->filename, AVIO_FLAG_WRITE) < 0) {
-       lsx_fail("ffmpeg could not open `%s'", ft->filename);
-       return SOX_EOF;
-     }
-   }
- 
-   /* write the stream header, if any */
--  av_write_header(ffmpeg->ctxt);
-+  avformat_write_header(ffmpeg->ctxt, NULL);
- 
-   return SOX_SUCCESS;
- }
-@@ -478,7 +471,7 @@
- #if (LIBAVFORMAT_VERSION_INT < 0x340000)
-     url_fclose(&ffmpeg->ctxt->pb);
- #else
--    url_fclose(ffmpeg->ctxt->pb);
-+    avio_close(ffmpeg->ctxt->pb);
- #endif
-   }
 
-

file:a/utils/ccrypt/Makefile (deleted)
--- a/utils/ccrypt/Makefile
+++ /dev/null
@@ -1,38 +1,1 @@
-#
-# Copyright (C) 2009-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:=ccrypt
-PKG_VERSION:=1.10
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=@SF/ccrypt
-PKG_MD5SUM:=44ddd763465c254df83f5d38851d04d7
-
-PKG_FIXUP:=autoreconf
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/ccrypt
-  SECTION:=utils
-  CATEGORY:=Utilities
-  TITLE:=ccrypt is a utility for encrypting and decrypting files and streams
-  URL:=http://ccrypt.sourceforge.net/
-endef
-
-define Package/ccrypt/install
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/ccrypt $(1)/usr/bin/
-	ln -s ccrypt $(1)/usr/bin/ccencrypt
-	ln -s ccrypt $(1)/usr/bin/ccdecrypt
-	ln -s ccrypt $(1)/usr/bin/ccat
-endef
-
-$(eval $(call BuildPackage,ccrypt))
-

--- a/utils/ccrypt/patches/001-no-intl.patch
+++ /dev/null
@@ -1,90 +1,1 @@
---- a/configure.ac
-+++ b/configure.ac
-@@ -123,17 +123,6 @@ AC_MSG_RESULT($UINT32_TYPE)
- AC_DEFINE_UNQUOTED(UINT32_TYPE,$UINT32_TYPE,unsigned 32 bit integer type)
- 
- dnl ----------------------------------------------------------------------
--dnl Internationalization
--
--GETTEXT_PACKAGE=ccrypt
--AC_SUBST(GETTEXT_PACKAGE)
--AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Package name for gettext])
--
--AM_GNU_GETTEXT
--AM_GNU_GETTEXT_VERSION([0.14.3])
--IT_PO_SUBDIR(po)
--
--dnl ----------------------------------------------------------------------
- dnl Libtool (needed by intl/)
- 
- LT_INIT
-@@ -153,9 +142,7 @@ AC_SUBST(TAR)
- dnl ----------------------------------------------------------------------
- AC_CONFIG_FILES([doc/ccrypt.1
- 	   doc/ccguess.1
--	   po/Makefile.in 
- 	   m4/Makefile 
--	   intl/Makefile 
- 	   Makefile 
- 	   src/Makefile 
- 	   emacs/Makefile
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -4,7 +4,7 @@
- 
- ## Process this file with automake to produce Makefile.in
- 
--SUBDIRS = m4 po intl src emacs doc check
-+SUBDIRS = m4 src emacs doc check
- 
- EXTRA_DIST = m4/ChangeLog config.rpath README-WIN
- 
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -36,7 +36,7 @@ host_triplet = @host@
- subdir = .
- DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
- 	$(srcdir)/Makefile.in $(srcdir)/config.h.in \
--	$(top_srcdir)/configure $(top_srcdir)/intl/Makefile.in \
-+	$(top_srcdir)/configure \
- 	ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL NEWS config.guess \
- 	config.rpath config.sub depcomp elisp-comp install-sh \
- 	ltmain.sh missing mkinstalldirs
-@@ -66,7 +66,7 @@ am__CONFIG_DISTCLEAN_FILES = config.stat
-  configure.lineno config.status.lineno
- mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
- CONFIG_HEADER = config.h
--CONFIG_CLEAN_FILES = intl/Makefile
-+CONFIG_CLEAN_FILES =
- CONFIG_CLEAN_VPATH_FILES =
- SOURCES =
- DIST_SOURCES =
-@@ -277,7 +277,7 @@ target_alias = @target_alias@
- top_build_prefix = @top_build_prefix@
- top_builddir = @top_builddir@
- top_srcdir = @top_srcdir@
--SUBDIRS = m4 po intl src emacs doc check
-+SUBDIRS = m4 src emacs doc check
- EXTRA_DIST = m4/ChangeLog config.rpath README-WIN
- ACLOCAL_AMFLAGS = -I m4
- all: config.h
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -56,4 +56,4 @@ uninstall-local:
- # internationalization stuff
- localedir = $(datadir)/locale
- INCLUDES = -I../intl -I$(top_srcdir)/intl -DLOCALEDIR=\"$(localedir)\"
--LIBS = @LIBINTL@ @LIBS@
-+LIBS = @LIBS@
---- a/src/Makefile.in
-+++ b/src/Makefile.in
-@@ -159,7 +159,7 @@ LDFLAGS = @LDFLAGS@
- LIBICONV = @LIBICONV@
- LIBINTL = @LIBINTL@
- LIBOBJS = @LIBOBJS@
--LIBS = @LIBINTL@ @LIBS@
-+LIBS = @LIBS@
- LIBTOOL = @LIBTOOL@
- LIPO = @LIPO@
- LN_S = @LN_S@
 

file:a/utils/haveged/Makefile (deleted)
--- a/utils/haveged/Makefile
+++ /dev/null
@@ -1,68 +1,1 @@
-#
-# Copyright (C) 2006-2014 OpenWrt.org
-#
-# This is free software, licensed under the GNU General Public License v2.
-# See /LICENSE for more information.
-#
-# $Id: Makefile 1 2012-01-12 03:50:18Z Olipro $
 
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=haveged
-PKG_VERSION:=1.9.1
-PKG_RELEASE:=1
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://www.issihosts.com/$(PKG_NAME)
-PKG_MD5SUM:=015ff58cd10607db0e0de60aeca2f5f8
-
-#ensure this is consistent with the dir in the tarball!!!
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
-
-PKG_BUILD_PARALLEL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/haveged/template
-  SECTION:=utils
-  CATEGORY:=Utilities
-  TITLE:=Feeds the kernel entropy pool by timing CPU loops.
-  URL:=http://www.issihosts.com/haveged/
-endef
-
-define Package/haveged
-  $(call Package/haveged/template)
-  DEPENDS:=+libhavege
-endef
-
-define Package/libhavege
-  $(call Package/haveged/template)
-  TITLE:=Library for haveged
-endef
-
-CONFIGURE_ARGS+= \
-      --enable-daemon=yes
-      --enable-threads=no
-
-define Build/InstallDev
-	$(INSTALL_DIR) $(1)/usr/include
-	$(CP) $(PKG_BUILD_DIR)/src/havege.h $(1)/usr/include/
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_BUILD_DIR)/src/.libs/libhavege.{a,so*} $(1)/usr/lib/
-endef
-
-define Package/haveged/install
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/haveged.init $(1)/etc/init.d/haveged
-	$(INSTALL_DIR) $(1)/usr/sbin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/.libs/haveged $(1)/usr/sbin/
-endef
-
-define Package/libhavege/install
-	$(INSTALL_DIR) $(1)/usr/lib
-	$(CP) $(PKG_BUILD_DIR)/src/.libs/libhavege.so* $(1)/usr/lib/
-endef
-
-$(eval $(call BuildPackage,haveged))
-$(eval $(call BuildPackage,libhavege))
-

--- a/utils/haveged/files/haveged.init
+++ /dev/null
@@ -1,17 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2012 OpenWrt.org
 
-START=98
-
-HAVEGED_THRESHOLD=1024
-HAVEGED_DCACHE=32
-HAVEGED_ICACHE=32
-
-start() {
-	service_start /usr/sbin/haveged -w $HAVEGED_THRESHOLD -d $HAVEGED_DCACHE -i $HAVEGED_ICACHE -v 1
-}
-
-stop() {
-	service_stop /usr/sbin/haveged
-}
-

--- a/utils/rng-tools/Makefile
+++ /dev/null
@@ -1,45 +1,1 @@
-#
-# 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:=rng-tools
-PKG_VERSION:=3
-PKG_RELEASE:=2
-
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://downloads.sourceforge.net/project/gkernel/rng-tools/3/
-PKG_MD5SUM:=fa305916ec101c85c0065aeceb81a38d
-
-PKG_FIXUP:=autoreconf
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/rng-tools
-  SECTION:=utils
-  CATEGORY:=Utilities
-  DEPENDS:=+USE_UCLIBC:argp-standalone
-  TITLE:=Daemon for adding entropy to kernel entropy pool
-  URL:=http://sourceforge.net/projects/gkernel/
-endef
-
-ifdef CONFIG_USE_UCLIBC
-CONFIGURE_VARS += \
-    LIBS="-largp"
-endif
-
-define Package/rng-tools/install
-	$(INSTALL_DIR) $(1)/etc/init.d
-	$(INSTALL_BIN) ./files/rngd.init $(1)/etc/init.d/rngd
-	$(INSTALL_DIR) $(1)/usr/bin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/rngtest $(1)/usr/bin/
-	$(INSTALL_DIR) $(1)/sbin
-	$(INSTALL_BIN) $(PKG_BUILD_DIR)/rngd $(1)/sbin/
-endef
-
-$(eval $(call BuildPackage,rng-tools))
-

--- a/utils/rng-tools/files/rngd.init
+++ /dev/null
@@ -1,17 +1,1 @@
-#!/bin/sh /etc/rc.common
-# Copyright (C) 2011 OpenWrt.org
 
-START=98
-
-RNGD_INTERVAL=30
-RNGD_AMOUNT=4000
-RNGD_DEVICE="/dev/urandom"
-
-start() {
-	service_start /sbin/rngd -r $RNGD_DEVICE -W $RNGD_AMOUNT -t $RNGD_INTERVAL
-}
-
-stop() {
-	service_stop /sbin/rngd
-}
-

comments