diff --git a/README.md b/README.md index dd33d776b..930b6f0dd 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,14 @@ ## Description -This is the OpenWrt "packages"-feed containing community-maintained packages. +This is the OpenWrt "packages"-feed containing community-maintained build scripts, options and patches for applications, modules and libraries used within OpenWrt. + +Installation of pre-built packages is handled directly by the **opkg** utility within your running OpenWrt system or by using the [OpenWrt SDK](http://doc/howto/obtain.firmware.sdk) on a build system. ## Usage +This repository is intended to be layered on-top of an OpenWrt buildroot. If you do not have an OpenWrt buildroot installed, see the documentation at: [OpenWrt Buildroot – Installation](http://wiki.openwrt.org/doc/howto/buildroot.exigence) on the OpenWrt support site. + This feed is enabled by default. To install all its package definitions, run: ``` ./scripts/feeds update packages diff --git a/admin/debootstrap/Makefile b/admin/debootstrap/Makefile index f2e18d5d8..629f221d4 100644 --- a/admin/debootstrap/Makefile +++ b/admin/debootstrap/Makefile @@ -9,13 +9,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=debootstrap -PKG_VERSION:=1.0.66 +PKG_VERSION:=1.0.68 PKG_RELEASE:=1 PKG_MAINTAINER=Daniel Golle PKG_SOURCE:=$(PKG_NAME)-udeb_$(PKG_VERSION)_all.udeb PKG_SOURCE_URL:=http://ftp.debian.org/debian/pool/main/d/debootstrap -PKG_MD5SUM:=bf6370ea0aa80308dfb03a4a35e33ad1 +PKG_MD5SUM:=b7e98013966e595ba50230f60efe7cbe PKG_LICENSE:=Unique PKG_LICENSE_FILES:=debian/copyright diff --git a/admin/monit/Makefile b/admin/monit/Makefile index bb3cfd09a..ba1b64c56 100644 --- a/admin/monit/Makefile +++ b/admin/monit/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=monit -PKG_VERSION:=5.11 +PKG_VERSION:=5.13 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://mmonit.com/monit/dist -PKG_MD5SUM:=ff00f39d248ed7068932ed82211da9e6 +PKG_MD5SUM:=7902ff45eaa1303ac25f6366eff251ef PKG_LICENSE:=AGPL-3.0 PKG_LICENSE_FILES:=COPYING diff --git a/admin/monit/patches/001-fix-default-piddir.patch b/admin/monit/patches/001-fix-default-piddir.patch index 72163ecb3..7af871f0d 100644 --- a/admin/monit/patches/001-fix-default-piddir.patch +++ b/admin/monit/patches/001-fix-default-piddir.patch @@ -1,6 +1,6 @@ --- a/configure +++ b/configure -@@ -13744,14 +13744,7 @@ fi +@@ -13849,14 +13849,7 @@ fi # Find the right directory to put the root-mode PID file in { $as_echo "$as_me:${as_lineno-$LINENO}: checking pid file location" >&5 $as_echo_n "checking pid file location... " >&6; } diff --git a/admin/muninlite/Makefile b/admin/muninlite/Makefile index 1c1793edd..46fc8c4f8 100644 --- a/admin/muninlite/Makefile +++ b/admin/muninlite/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=muninlite PKG_VERSION:=1.0.4 -PKG_RELEASE:=5 +PKG_RELEASE:=6 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/$(PKG_NAME) diff --git a/admin/muninlite/patches/220-modify-ifname-parser.patch b/admin/muninlite/patches/220-modify-ifname-parser.patch new file mode 100644 index 000000000..95655cfbd --- /dev/null +++ b/admin/muninlite/patches/220-modify-ifname-parser.patch @@ -0,0 +1,22 @@ +--- a/plugins/if_ ++++ b/plugins/if_ +@@ -26,7 +26,7 @@ config_if() { + fi + } + fetch_if() { +- IINFO=$(grep "$1:" /proc/net/dev | cut -d: -f2 | sed -e 's/ / /g') ++ IINFO=$(cat /proc/net/dev | sed -e 's/-/_/g' | grep "$1:" | cut -d: -f2 | sed -e 's/ */ /g' -e 's/^[ \t]*//') + echo "down.value" $(echo $IINFO | cut -d\ -f1) + echo "up.value" $(echo $IINFO | cut -d\ -f9) + } +--- a/plugins/if_err_ ++++ b/plugins/if_err_ +@@ -15,7 +15,7 @@ config_if_err() { + echo "trans.warning 1" + } + fetch_if_err() { +- IINFO=$(grep "$1:" /proc/net/dev | cut -d: -f2 | sed -e 's/ / /g') ++ IINFO=$(cat /proc/net/dev | sed -e 's/-/_/g' | grep "$1:" | cut -d: -f2 | sed -e 's/ */ /g' -e 's/^[ \t]*//') + echo "rcvd.value" $(echo $IINFO | cut -d\ -f3) + echo "trans.value" $(echo $IINFO | cut -d\ -f11) + } diff --git a/admin/sudo/Makefile b/admin/sudo/Makefile index 25a0ff348..69ace6060 100644 --- a/admin/sudo/Makefile +++ b/admin/sudo/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sudo -PKG_VERSION:=1.8.12 +PKG_VERSION:=1.8.13 PKG_RELEASE:=1 PKG_LICENSE:=ISC PKG_LICENSE_FILES:=doc/LICENSE PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.sudo.ws/sudo/dist -PKG_MD5SUM:=87558f3a55c62bc9244b19594f103ffa +PKG_MD5SUM:=f61577ec330ad1bd504c0e2eec6ea2d8 PKG_INSTALL:=1 diff --git a/admin/zabbix/Makefile b/admin/zabbix/Makefile index c3c618cd1..e764b7701 100644 --- a/admin/zabbix/Makefile +++ b/admin/zabbix/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=zabbix -PKG_VERSION:=2.4.3 -PKG_RELEASE:=1 +PKG_VERSION:=2.4.5 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/zabbix -PKG_MD5SUM:=e8a0699c4e49999a15c63650a2280600 +PKG_MD5SUM:=a82eb0d55d3ca947e10a4a55238f4388 PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING diff --git a/admin/zabbix/files/wifi b/admin/zabbix/files/wifi index 250d2f913..6315ea995 100644 --- a/admin/zabbix/files/wifi +++ b/admin/zabbix/files/wifi @@ -3,7 +3,7 @@ # wifi interface discovery # exemple: {"data":[{"{#IF}":"wlan0", "{#MODE}":"ap", "{#SSID}":"Openwrt", "{#NET}":"lan", "{#DEV}":"radio0", "{#ENC}":"psk2+ccmp", "{#TYPE}":"mac80211", "{#HWMODE}":"11ng", "{#CHANNEL}":"11", "{#BSSID}":"xx:xx:xx:xx:xx:xx"}]} # ubus call only work as root so you need to run zabbix as root to use wifi.ifdiscovery -UserParameter=wifi.ifdiscovery, lua -l uci -l ubus -l iwinfo -e 'u = ubus.connect();x = uci.cursor();list="{\"data\":[";stat=u:call("network.wireless", "status", {});for dev, dev_table in pairs(stat) do for i, iface in pairs(dev_table["interfaces"]) do s=iface["section"];list=list.."{\"{#IF}\":\""..iface["ifname"].."\", \"{#MODE}\":\""..x:get("wireless", s, "mode").."\", \"{#SSID}\":\""..x:get("wireless", s, "ssid").."\", \"{#NET}\":\""..x:get("wireless", s, "network").."\", \"{#DEV}\":\""..dev.."\", \"{#ENC}\":\""..(x:get("wireless", s, "encryption") or "?").."\", \"{#TYPE}\":\""..x:get("wireless", dev, "type").."\", \"{#HWMODE}\":\""..x:get("wireless", dev, "hwmode").."\", \"{#CHANNEL}\":\""..x:get("wireless", dev, "channel").."\", \"{#BSSID}\":\""..iwinfo[iwinfo.type(iface["ifname"])].bssid(iface["ifname"]).."\"},";end;end;list=string.gsub(list,",$","");print(list.."]}")' +UserParameter=wifi.ifdiscovery, lua -l ubus -l iwinfo -e 'u=ubus.connect();list="{\"data\":[";stat=u:call("network.wireless", "status", {});for dev, dev_table in pairs(stat) do for i, iface in pairs(dev_table["interfaces"]) do c=iface["config"];i=iface["ifname"];t=iwinfo.type(i);iw=iwinfo[t];e = iw.encryption(i);e = e and e.description or "None";n = table.concat(c["network"]," ");list=list.."{\"{#IF}\":\""..i.."\", \"{#MODE}\":\""..iw.mode(i).."\", \"{#SSID}\":\""..c["ssid"].."\", \"{#NET}\":\""..n.."\", \"{#DEV}\":\""..dev.."\", \"{#ENC}\":\""..e.."\", \"{#TYPE}\":\""..t.."\", \"{#HWMODE}\":\"".."?".."\", \"{#CHANNEL}\":\""..iw.channel(i).."\", \"{#BSSID}\":\""..iw.bssid(i).."\"},";end;end;list=string.gsub(list,",$","");print(list.."]}")' #iwinfo info (you need {#IF} as parameter, like 'wlan0') diff --git a/admin/zabbix/patches/100-musl-compat.patch b/admin/zabbix/patches/100-musl-compat.patch new file mode 100644 index 000000000..2b6fee6ce --- /dev/null +++ b/admin/zabbix/patches/100-musl-compat.patch @@ -0,0 +1,23 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -51,7 +51,7 @@ AC_CHECK_HEADERS(stdio.h stdlib.h string + syslog.h time.h errno.h sys/types.h sys/stat.h netinet/in.h \ + math.h sys/socket.h dirent.h ctype.h \ + mtent.h fcntl.h sys/param.h arpa/inet.h \ +- sys/vfs.h sys/pstat.h sys/sysinfo.h sys/statvfs.h sys/statfs.h \ ++ sys/vfs.h sys/pstat.h sys/statvfs.h sys/statfs.h \ + sys/socket.h sys/loadavg.h arpa/inet.h \ + sys/vmmeter.h strings.h vm/vm_param.h \ + sys/time.h kstat.h sys/syscall.h sys/sysmacros.h \ +@@ -63,6 +63,11 @@ AC_CHECK_HEADERS(stdio.h stdlib.h string + sys/timeb.h Winber.h lber.h ws2tcpip.h inttypes.h sys/file.h grp.h \ + execinfo.h libperfstat.h sys/systemcfg.h sys/mnttab.h mntent.h sys/times.h \ + dlfcn.h sys/utsname.h) ++AC_CHECK_HEADERS(sys/sysinfo.h, [], [], [ ++#ifdef HAVE_LINUX_KERNEL_H ++# include ++#endif ++]) + AC_CHECK_HEADERS(resolv.h, [], [], [ + #ifdef HAVE_SYS_TYPES_H + # include diff --git a/devel/diffutils/Makefile b/devel/diffutils/Makefile index 33cdc1216..b313dafa4 100644 --- a/devel/diffutils/Makefile +++ b/devel/diffutils/Makefile @@ -24,7 +24,7 @@ include $(INCLUDE_DIR)/package.mk define Package/diffutils SECTION:=devel CATEGORY:=Development - DEPENDS:=+USE_EGLIBC:librt + DEPENDS:=+USE_GLIBC:librt TITLE:=diffutils URL:=http://www.gnu.org/software/diffutils/ endef diff --git a/devel/lttng-modules/Makefile b/devel/lttng-modules/Makefile index 1fcfa73da..99510a003 100644 --- a/devel/lttng-modules/Makefile +++ b/devel/lttng-modules/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lttng-modules -PKG_VERSION:=2.6.0 +PKG_VERSION:=2.6.1 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://lttng.org/files/$(PKG_NAME)/ -PKG_MD5SUM:=a058ab037daaca293a54934d7b9f9c98 +PKG_MD5SUM:=ccfb50ad922cdaf54a809e2d9de23da4 PKG_LICENSE:=LGPL-2.1 GPL-2.0 MIT PKG_LICENSE_FILES:=LICENSE @@ -26,7 +26,7 @@ define KernelPackage/lttng SUBMENU:=Other modules TITLE:=Linux Trace Toolkit: next generation (kernel modules) URL:=https://lttng.org/ - DEPENDS:= @!TARGET_uml @KERNEL_FTRACE + DEPENDS:= @!TARGET_uml @KERNEL_FTRACE_SYSCALLS FILES:= \ $(PKG_BUILD_DIR)/lttng-*.$(LINUX_KMOD_SUFFIX) \ $(PKG_BUILD_DIR)/lib/lttng-*.$(LINUX_KMOD_SUFFIX) \ diff --git a/devel/lttng-modules/patches/001-mm_page_alloc_extfrag.patch b/devel/lttng-modules/patches/001-mm_page_alloc_extfrag.patch new file mode 100644 index 000000000..d8a0c62fa --- /dev/null +++ b/devel/lttng-modules/patches/001-mm_page_alloc_extfrag.patch @@ -0,0 +1,10 @@ +--- a/instrumentation/events/lttng-module/kmem.h ++++ b/instrumentation/events/lttng-module/kmem.h +@@ -287,6 +287,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE_PRINT(mm + ) + + #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,2) \ ++ || LTTNG_KERNEL_RANGE(3,18,10, 3,19,0) \ + || LTTNG_KERNEL_RANGE(3,14,36, 3,15,0) \ + || LTTNG_DEBIAN_KERNEL_RANGE(3,16,7,9,0,0, 3,17,0,0,0,0)) + diff --git a/devel/lttng-tools/Makefile b/devel/lttng-tools/Makefile index 99269b325..6c902dfce 100644 --- a/devel/lttng-tools/Makefile +++ b/devel/lttng-tools/Makefile @@ -34,6 +34,8 @@ define Package/lttng-tools DEPENDS:= +lttng-ust +libpopt +libxml2 endef +CONFIGURE_ARGS += --disable-kmod + TARGET_LDFLAGS += -lurcu-bp MAKE_FLAGS += V="$(V)" diff --git a/devel/patch/Makefile b/devel/patch/Makefile index b7119a485..d705a30a1 100644 --- a/devel/patch/Makefile +++ b/devel/patch/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=patch -PKG_VERSION:=2.7.4 +PKG_VERSION:=2.7.5 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@GNU/patch -PKG_MD5SUM:=abc59498fcdddd44e0d07764aa105fd2 +PKG_MD5SUM:=e3da7940431633fb65a01b91d3b7a27a PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=COPYING diff --git a/ipv6/aiccu/Makefile b/ipv6/aiccu/Makefile index 50839f359..0034c0b70 100644 --- a/ipv6/aiccu/Makefile +++ b/ipv6/aiccu/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2012 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=aiccu PKG_VERSION:=20070115 -PKG_RELEASE:=12 +PKG_RELEASE:=13 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.sixxs.net/archive/sixxs/aiccu/unix diff --git a/ipv6/aiccu/files/aiccu.sh b/ipv6/aiccu/files/aiccu.sh index 38d8191f5..584574b74 100755 --- a/ipv6/aiccu/files/aiccu.sh +++ b/ipv6/aiccu/files/aiccu.sh @@ -36,7 +36,7 @@ proto_aiccu_setup() { [ -n "$server" ] && echo "server $server" >> "$CFGFILE" [ -n "$protocol" ] && echo "protocol $protocol" >> "$CFGFILE" [ -n "$tunnelid" ] && echo "tunnel_id $tunnelid" >> "$CFGFILE" - [ -n "$requiretls" ] && echo "requiretls $requiretls" >> "$CFGFILE" + [ "$requiretls" == 1 ] && echo "requiretls true" >> "$CFGFILE" [ "$nat" == 1 ] && echo "behindnat true" >> "$CFGFILE" [ "$heartbeat" == 1 ] && echo "makebeats true" >> "$CFGFILE" [ "$verbose" == 1 ] && echo "verbose true" >> "$CFGFILE" diff --git a/ipv6/aiccu/patches/100-cross_compile.patch b/ipv6/aiccu/patches/100-cross_compile.patch index dbdc50aaa..6ef8ad5d6 100644 --- a/ipv6/aiccu/patches/100-cross_compile.patch +++ b/ipv6/aiccu/patches/100-cross_compile.patch @@ -1,6 +1,6 @@ ---- aiccu/unix-console/Makefile.orig 2007-09-02 23:19:39.000000000 +0200 -+++ aiccu/unix-console/Makefile 2007-09-02 23:20:11.000000000 +0200 -@@ -25,7 +25,8 @@ +--- a/unix-console/Makefile ++++ b/unix-console/Makefile +@@ -25,7 +25,8 @@ CWARNS += -W -Wall -Wshadow -Wpointer-ar # CWARNS += -Wpacked #CFLAGS += $(CWARNS) -D_GNU_SOURCE -D_DEBUG -g3 -O0 @@ -10,7 +10,7 @@ CC = @gcc RM = rm -@@ -40,25 +41,25 @@ +@@ -40,25 +41,25 @@ CFLAGS += -D AICCU_CONSOLE # GnuTLS Support ? # Used by TIC to secure that communication # Currently defaultly builds only on Linux, but other platforms might easily also support it @@ -41,7 +41,7 @@ CFLAGS += -D AICCU_TYPE="\"freebsd4\"" SRCS += ../common/aiccu_freebsd4.c OBJS += ../common/aiccu_freebsd4.o -@@ -71,7 +72,7 @@ +@@ -71,7 +72,7 @@ endif endif # DragonFlyBSD @@ -50,7 +50,7 @@ CFLAGS += -D_DFBSD -D NEED_IFHEAD -D AICCU_TYPE="\"dragonfly\"" SRCS += ../common/aiccu_freebsd4.c OBJS += ../common/aiccu_freebsd4.o -@@ -79,7 +80,7 @@ +@@ -79,7 +80,7 @@ CFLAGS += -pthread endif # NetBSD @@ -59,7 +59,7 @@ CFLAGS += -D_NETBSD -D AICCU_TYPE="\"kame\"" # Check if net/if_tun.h has TUNSIFHEAD and enable support for it -@@ -97,10 +98,10 @@ +@@ -97,10 +98,10 @@ CFLAGS += -pthread -D_NETBSD_SOURCE endif # OpenBSD @@ -72,7 +72,7 @@ CFLAGS += -D AICCU_TYPE="\"openbsd2\"" SRCS += ../common/aiccu_openbsd2.c OBJS += ../common/aiccu_openbsd2.o -@@ -114,7 +115,7 @@ +@@ -114,7 +115,7 @@ CFLAGS += -pthread endif # Darwin @@ -81,7 +81,7 @@ CFLAGS += -D_DARWIN -D NEED_IFHEAD -D AICCU_TYPE="\"darwin\"" SRCS += ../common/aiccu_darwin.c OBJS += ../common/aiccu_darwin.o -@@ -122,7 +123,7 @@ +@@ -122,7 +123,7 @@ LDFLAGS += -lresolv endif # SunOS / Solaris @@ -90,7 +90,7 @@ CFLAGS += -D_SUNOS -D AICCU_TYPE="\"sunos\"" SRCS += ../common/aiccu_sunos.c OBJS += ../common/aiccu_sunos.o -@@ -130,7 +131,7 @@ +@@ -130,7 +131,7 @@ LDFLAGS += -lsocket -lnsl -lresolv endif # AIX diff --git a/ipv6/aiccu/patches/200-add_dn_skipname.patch b/ipv6/aiccu/patches/200-add_dn_skipname.patch index ca6afcea1..3ce1e9234 100644 --- a/ipv6/aiccu/patches/200-add_dn_skipname.patch +++ b/ipv6/aiccu/patches/200-add_dn_skipname.patch @@ -1,6 +1,5 @@ -diff -Nru aiccu.old/common/dn_skipname.c aiccu/common/dn_skipname.c ---- aiccu.old/common/dn_skipname.c 1970-01-01 02:00:00.000000000 +0200 -+++ aiccu/common/dn_skipname.c 2006-11-04 00:50:23.000000000 +0200 +--- /dev/null ++++ b/common/dn_skipname.c @@ -0,0 +1,51 @@ +#include +#include @@ -53,11 +52,10 @@ diff -Nru aiccu.old/common/dn_skipname.c aiccu/common/dn_skipname.c + return (ptr - saveptr); +} + -diff -Nru aiccu.old/unix-console/Makefile aiccu/unix-console/Makefile ---- aiccu.old/unix-console/Makefile 2006-11-04 00:51:20.000000000 +0200 -+++ aiccu/unix-console/Makefile 2006-11-04 00:48:51.000000000 +0200 +--- a/unix-console/Makefile ++++ b/unix-console/Makefile @@ -10,9 +10,9 @@ - # $Date: 2006-07-25 09:20:48 $ + # $Date: 2007-01-15 11:04:27 $ # **********************************************************/ -SRCS = main.c ../common/tun.c ../common/aiccu.c ../common/hash_md5.c ../common/hash_sha1.c ../common/common.c ../common/heartbeat.c ../common/tic.c ../common/ayiya.c ../common/aiccu_test.c ../common/resolver.c diff --git a/ipv6/aiccu/patches/300-resolver-uclibc.patch b/ipv6/aiccu/patches/300-resolver-uclibc.patch index fbd6a5093..1a5f11626 100644 --- a/ipv6/aiccu/patches/300-resolver-uclibc.patch +++ b/ipv6/aiccu/patches/300-resolver-uclibc.patch @@ -1,29 +1,40 @@ ---- aiccu/common/resolver.c.orig 2007-09-02 23:10:58.000000000 +0200 -+++ aiccu/common/resolver.c 2007-09-02 23:11:01.000000000 +0200 +--- a/common/resolver.c ++++ b/common/resolver.c @@ -26,7 +26,7 @@ int getrrs(const char *label, int rrtype, void gotrec(unsigned int num, int type, const char *record)) { -#ifdef _LINUX -+#if defined(_LINUX) && !defined(__UCLIBC__) ++#if defined(_LINUX) && defined(__GLIBC__) struct __res_state res; #endif unsigned char answer[8192]; -@@ -38,7 +38,7 @@ +@@ -38,7 +38,7 @@ int getrrs(const char *label, int rrtype uint16_t type = 0, class = 0; uint32_t ttl = 0; -#ifdef _LINUX -+#if defined(_LINUX) && !defined(__UCLIBC__) ++#if defined(_LINUX) && defined(__GLIBC__) memset(&res, 0, sizeof(res)); res.options = RES_DEBUG; res_ninit(&res); -@@ -47,7 +47,7 @@ +@@ -47,7 +47,7 @@ int getrrs(const char *label, int rrtype #endif memset(answer, 0, sizeof(answer)); -#ifdef _LINUX -+#if defined(_LINUX) && !defined(__UCLIBC__) ++#if defined(_LINUX) && defined(__GLIBC__) ret = res_nquery(&res, label, C_IN, rrtype, answer, sizeof(answer)); #else ret = res_query(label, C_IN, rrtype, answer, sizeof(answer)); +--- a/common/dn_skipname.c ++++ b/common/dn_skipname.c +@@ -9,7 +9,7 @@ + * return: + * 0 on success, -1 (with errno set) on failure. + */ +-int ns_name_skip(const u_char **ptrptr, const u_char *eom) ++static int ns_name_skip(const u_char **ptrptr, const u_char *eom) + { + const u_char *cp; + u_int n; diff --git a/ipv6/aiccu/patches/400-musl-compat.patch b/ipv6/aiccu/patches/400-musl-compat.patch new file mode 100644 index 000000000..2e732d8a2 --- /dev/null +++ b/ipv6/aiccu/patches/400-musl-compat.patch @@ -0,0 +1,29 @@ +--- a/common/common.h ++++ b/common/common.h +@@ -50,6 +50,7 @@ + #include + #include + #include ++#include + #include + + #if defined(_SUNOS) || defined(_AIX) || defined(_DARWIN) +@@ -91,7 +92,9 @@ + #include + + #include ++#if defined(__GLIBC__) || defined(__UCLIBC__) + #include ++#endif + #ifdef linux + #include + #include +--- a/common/dn_skipname.c ++++ b/common/dn_skipname.c +@@ -1,5 +1,6 @@ + #include + #include ++#include + + /* Ripped from glibc 2.4 sources. */ + diff --git a/kernel/exfat-nofuse/Makefile b/kernel/exfat-nofuse/Makefile new file mode 100644 index 000000000..232ddeef8 --- /dev/null +++ b/kernel/exfat-nofuse/Makefile @@ -0,0 +1,51 @@ +# +# Copyright (C) 2014 Bruno Randolf +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk +include $(INCLUDE_DIR)/kernel.mk + +PKG_NAME:=exfat-nofuse +PKG_VERSION:=git-20150301 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=https://github.com/dorimanx/exfat-nofuse.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=63964d3fb69cffe9a38822a657bb3b3279eebadf + +PKG_MAINTAINER:=Bruno Randolf +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=LICENSE + +include $(INCLUDE_DIR)/package.mk + +define KernelPackage/fs-exfat + SUBMENU:=Filesystems + TITLE:=ExFAT Kernel driver + FILES:=$(PKG_BUILD_DIR)/exfat.ko + AUTOLOAD:=$(call AutoLoad,30,exfat,1) + DEPENDS:=+kmod-nls-base @BUILD_PATENTED +endef + +define KernelPackage/fs-exfat/description + Kernel module for ExFAT Filesytems +endef + +MAKE_OPTS:= \ + ARCH="$(LINUX_KARCH)" \ + CROSS_COMPILE="$(TARGET_CROSS)" \ + M="$(PKG_BUILD_DIR)" + +define Build/Compile + $(MAKE) -C "$(LINUX_DIR)" \ + $(MAKE_OPTS) \ + CONFIG_EXFAT_FS=m \ + modules +endef + +$(eval $(call KernelPackage,fs-exfat)) diff --git a/lang/dkjson/Makefile b/lang/dkjson/Makefile index 4a6422874..efb0012d0 100644 --- a/lang/dkjson/Makefile +++ b/lang/dkjson/Makefile @@ -9,12 +9,15 @@ include $(TOPDIR)/rules.mk PKG_NAME:=dkjson PKG_VERSION:=2.5 -PKG_RELEASE:=1 +PKG_RELEASE:=3 -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=http://dkolf.de/src/dkjson-lua.fsl/tarball/ -PKG_MD5SUM:=dbe706722dd64308172cf8e37395e762 +PKG_SOURCE_URL:=https://github.com/LuaDist/dkjson.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=e72ba0c9f5d8b8746fc306f6189a819dbb5cd0be PKG_LICENSE:=MIT +PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.bz2 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_SOURCE_VERSION) +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_SOURCE_VERSION) include $(INCLUDE_DIR)/package.mk diff --git a/lang/erlang/Makefile b/lang/erlang/Makefile index dc4c31670..47c8b1198 100644 --- a/lang/erlang/Makefile +++ b/lang/erlang/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=erlang -PKG_VERSION:=17.4 -PKG_RELEASE:=1 +PKG_VERSION:=17.5 +PKG_RELEASE:=2 PKG_SOURCE:=otp_src_$(PKG_VERSION).tar.gz PKG_SOURCE_URL:= http://www.erlang.org/download/ \ http://erlang.mirror.su.se/ -PKG_MD5SUM:=3d33c4c6bd7950240dcd7479edd9c7d8 +PKG_MD5SUM:=346dd0136bf1cc28cebc140e505206bb PKG_LICENSE:=ErlPL-1.1 PKG_LICENSE_FILES:=EPLICENCE @@ -45,7 +45,7 @@ endef define Package/erlang $(call Package/erlang/Default) DEPENDS+= +libncurses +librt +zlib - PROVIDES:= erlang-erts=6.1 erlang-kernel=3.0.1 erlang-sasl=2.4 erlang-stdlib=2.1 + PROVIDES:= erlang-erts=6.4 erlang-kernel=3.2 erlang-sasl=2.4.1 erlang-stdlib=2.4 endef define Package/erlang/description @@ -59,7 +59,7 @@ endef define Package/erlang-asn1 $(call Package/erlang/Default) TITLE:=Abstract Syntax Notation One (ASN.1) support - VERSION:=3.0.1 + VERSION:=3.0.4 DEPENDS+= +erlang +erlang-syntax-tools endef @@ -74,7 +74,7 @@ endef define Package/erlang-compiler $(call Package/erlang/Default) TITLE:=Byte code compiler - VERSION:=5.0.1 + VERSION:=5.0.4 DEPENDS+= +erlang +erlang-hipe endef @@ -89,7 +89,7 @@ endef define Package/erlang-crypto $(call Package/erlang/Default) TITLE:=Cryptography support - VERSION:=3.4 + VERSION:=3.5 DEPENDS+= +erlang +libopenssl endef @@ -104,7 +104,7 @@ endef define Package/erlang-hipe $(call Package/erlang/Default) TITLE:=High Performance Erlang - VERSION:=3.11 + VERSION:=3.11.3 DEPENDS+= +erlang endef @@ -119,7 +119,7 @@ endef define Package/erlang-inets $(call Package/erlang/Default) TITLE:=Internet clients and servers - VERSION:=5.10.2 + VERSION:=5.10.6 DEPENDS+= +erlang endef @@ -135,7 +135,7 @@ endef define Package/erlang-mnesia $(call Package/erlang/Default) TITLE:=Distributed database - VERSION:=4.12.1 + VERSION:=4.12.5 DEPENDS+= +erlang endef @@ -152,7 +152,7 @@ endef define Package/erlang-runtime-tools $(call Package/erlang/Default) TITLE:=Low-profile debugging/tracing tools - VERSION:=1.8.14 + VERSION:=1.8.16 DEPENDS+= +erlang endef @@ -167,7 +167,7 @@ endef define Package/erlang-snmp $(call Package/erlang/Default) TITLE:=Simple Network Management Protocol (SNMP) support - VERSION:=4.25.1 + VERSION:=5.1.1 DEPENDS+= +erlang +erlang-asn1 endef @@ -183,7 +183,7 @@ endef define Package/erlang-ssh $(call Package/erlang/Default) TITLE:=Secure Shell (SSH) support - VERSION:=3.0.3 + VERSION:=3.2 DEPENDS+= +erlang +erlang-crypto endef @@ -198,7 +198,7 @@ endef define Package/erlang-ssl $(call Package/erlang/Default) TITLE:=Secure Sockets Layer (SSL) support - VERSION:=5.3.5 + VERSION:=6.0 DEPENDS+= +erlang +erlang-crypto endef @@ -213,7 +213,7 @@ endef define Package/erlang-syntax-tools $(call Package/erlang/Default) TITLE:=Abstract Erlang syntax trees handling support - VERSION:=1.6.15 + VERSION:=1.6.18 DEPENDS+= +erlang endef @@ -232,6 +232,8 @@ HOST_CONFIGURE_ARGS += \ --disable-smp-support \ --without-javac +HOST_CFLAGS += -D_GNU_SOURCE + define Host/Compile $(MAKE) -C $(HOST_BUILD_DIR) all endef @@ -257,6 +259,7 @@ CONFIGURE_VARS += \ erl_xcomp_getaddrinfo=no \ erl_xcomp_sysroot="$(STAGING_DIR)" +EXTRA_CFLAGS+=-D_GNU_SOURCE EXTRA_LDFLAGS+=-lz define Build/Compile @@ -300,9 +303,9 @@ endef define Build/InstallDev $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/lib/erl_interface/obj/*/*.a $(1)/usr/lib + $(CP) $(PKG_BUILD_DIR)/lib/erl_interface/obj/*/*.a $(1)/usr/lib/ $(INSTALL_DIR) $(1)/usr/include - $(CP) $(PKG_BUILD_DIR)/lib/erl_interface/include/*.h $(1)/usr/include + $(CP) $(PKG_BUILD_DIR)/lib/erl_interface/include/*.h $(1)/usr/include/ endef define BuildModule diff --git a/lang/erlang/patches/102-musl_compat.patch b/lang/erlang/patches/102-musl_compat.patch new file mode 100644 index 000000000..d23900ed2 --- /dev/null +++ b/lang/erlang/patches/102-musl_compat.patch @@ -0,0 +1,11 @@ +--- a/lib/erl_interface/src/connect/ei_resolve.c ++++ b/lib/erl_interface/src/connect/ei_resolve.c +@@ -642,7 +642,7 @@ struct hostent *ei_gethostbyname_r(const + #ifndef HAVE_GETHOSTBYNAME_R + return my_gethostbyname_r(name,hostp,buffer,buflen,h_errnop); + #else +-#if (defined(__GLIBC__) || (__FreeBSD_version >= 602000) || defined(__DragonFly__) || defined(__ANDROID__)) ++#if (defined(_GNU_SOURCE) || (__FreeBSD_version >= 602000) || defined(__DragonFly__) || defined(__ANDROID__)) + struct hostent *result; + + gethostbyname_r(name, hostp, buffer, buflen, &result, h_errnop); diff --git a/lang/json4lua/Makefile b/lang/json4lua/Makefile new file mode 100644 index 000000000..0e0c9c540 --- /dev/null +++ b/lang/json4lua/Makefile @@ -0,0 +1,52 @@ +# +# Copyright (C) 2006-2015 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:=json4lua +PKG_VERSION:=0.9.53 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/amrhassan/json4lua.git +PKG_SOURCE_VERSION:=$(PKG_VERSION) + +PKG_MAINTAINER:=Amr Hassan +PKG_LICENSE=MIT + +LUA_MODULE_PATH:=/usr/lib/lua + +include $(INCLUDE_DIR)/package.mk + +define Package/json4lua + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=json4lua + URL:=https://github.com/amrhassan/json4lua + DEPENDS:=+lua +luasocket +endef + +define Package/json4lua/description + JSON and JSONRPC for Lua +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Package/json4lua/install + $(INSTALL_DIR) $(1)/$(LUA_MODULE_PATH)/json + $(INSTALL_DATA) $(PKG_BUILD_DIR)/json/json.lua $(1)/$(LUA_MODULE_PATH)/json.lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/json/rpc.lua $(1)/$(LUA_MODULE_PATH)/json/rpc.lua +endef + +$(eval $(call BuildPackage,json4lua)) diff --git a/lang/lpeg/Makefile b/lang/lpeg/Makefile new file mode 100644 index 000000000..ee8a4ef1f --- /dev/null +++ b/lang/lpeg/Makefile @@ -0,0 +1,48 @@ +# +# Copyright (C) 2015 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:=lpeg +PKG_VERSION:=0.12.2 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://www.inf.puc-rio.br/~roberto/lpeg/ +PKG_MD5SUM:=fabb614eb46e370d4f6b8fd82d17ca7e + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/lpeg + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=LPeg + URL:=http://www.inf.puc-rio.br/~roberto/lpeg/ + DEPENDS:=+lua +endef + +define Package/lpeg/description + LPeg is a new pattern-matching library for Lua, based on Parsing Expression Grammars (PEGs) +endef + +define Build/Configure +endef + +# add make variable overrides here +MAKE_FLAGS += + +define Package/lpeg/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/lpeg.so $(1)/usr/lib/lua +endef + +$(eval $(call BuildPackage,lpeg)) diff --git a/lang/lua-cjson/Makefile b/lang/lua-cjson/Makefile new file mode 100644 index 000000000..fbdcf17d1 --- /dev/null +++ b/lang/lua-cjson/Makefile @@ -0,0 +1,50 @@ +# +# Copyright (C) 2015 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:=lua-cjson +PKG_VERSION:=2.1.0 +PKG_RELEASE:=2 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=LICENSE + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://www.kyne.com.au/~mark/software/download/ +PKG_MD5SUM:=24f270663e9f6ca8ba2a02cef19f7963 + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/cmake.mk + +define Package/lua-cjson + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua CJSON parser + URL:=https://github.com/mpx/lua-cjson + DEPENDS:= +lua +endef + +define Package/lua-cjson/description + Lua CJSON is a fast JSON encoding/parsing module for Lua. +endef + +CMAKE_OPTIONS += \ + -DUSE_LUA=ON + +define Package/lua-cjson/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/cjson.so $(1)/usr/lib/lua/ + + $(INSTALL_DIR) $(1)/usr/lib/lua/cjson + $(INSTALL_DATA) $(PKG_BUILD_DIR)/lua/cjson/util.lua $(1)/usr/lib/lua/cjson +endef + +$(eval $(call BuildPackage,lua-cjson)) diff --git a/lang/lua-copas/Makefile b/lang/lua-copas/Makefile new file mode 100644 index 000000000..4f073e21f --- /dev/null +++ b/lang/lua-copas/Makefile @@ -0,0 +1,62 @@ +# +# 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:=lua-copas +PKG_VERSION:=2.0.0 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/copas.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=f39a80add9f7c010ac979297652bbaaea0360a27 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-copas + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua-Copas + URL:=https://github.com/keplerproject/copas + DEPENDS:=+lua +endef + +define Package/lua-copas/description + Copas is a dispatcher based on coroutines that can be used by TCP/IP servers. +endef + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + T="$(BUILD_VARIANT)" \ + PREFIX="$(PKG_INSTALL_DIR)/usr" \ + install +endef + +# add make variable overrides here +MAKE_FLAGS += + +define Package/lua-copas/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DIR) $(1)/usr/lib/lua/copas + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas.lua $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/ftp.lua $(1)/usr/lib/lua/copas + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/smtp.lua $(1)/usr/lib/lua/copas + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/http.lua $(1)/usr/lib/lua/copas + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/limit.lua $(1)/usr/lib/lua/copas +endef + +$(eval $(call BuildPackage,lua-copas)) diff --git a/lang/lua-copas/patches/makefile.patch b/lang/lua-copas/patches/makefile.patch new file mode 100644 index 000000000..10e473403 --- /dev/null +++ b/lang/lua-copas/patches/makefile.patch @@ -0,0 +1,15 @@ +--- lua-copas-1.2.1_org/Makefile 2014-06-04 16:39:17.451563827 +0800 ++++ lua-copas-1.2.1/Makefile 2014-06-04 16:39:41.115563309 +0800 +@@ -1,10 +1,10 @@ + # $Id: Makefile,v 1.3 2007/10/29 22:50:16 carregal Exp $ + + # Default prefix +-PREFIX = /usr/local ++PREFIX ?= $(DESTDIR)/usr + + # System's lua directory (where Lua libraries are installed) +-LUA_DIR= $(PREFIX)/share/lua/5.1 ++LUA_DIR= $(PREFIX)/lib/lua + + install: + mkdir -p $(LUA_DIR)/copas diff --git a/lang/lua-coxpcall/Makefile b/lang/lua-coxpcall/Makefile new file mode 100644 index 000000000..6ca3ff848 --- /dev/null +++ b/lang/lua-coxpcall/Makefile @@ -0,0 +1,59 @@ +# +# 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:=lua-coxpcall +PKG_VERSION:=1.15.0 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/coxpcall.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=979257892884816c97391dfd7b0a7b30dcc8f479 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-coxpcall + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua-Coxpcall + URL:=https://github.com/keplerproject/coxpcall + DEPENDS:=+lua +endef + +define Package/lua-coxpcall/description + Coxpcall encapsulates the protected calls with a coroutine based loop, + so errors can be dealed without the usual pcall/xpcall issues with coroutines. +endef + +TARGET_CFLAGS += $(FPIC) +# add make variable overrides here +MAKE_FLAGS += + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + T="$(BUILD_VARIANT)" \ + LUA_DIR="$(PKG_INSTALL_DIR)/usr/lib/lua" \ + install +endef + +define Package/lua-coxpcall/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/coxpcall.lua $(1)/usr/lib/lua +endef + +$(eval $(call BuildPackage,lua-coxpcall)) diff --git a/lang/lua-coxpcall/patches/config.patch b/lang/lua-coxpcall/patches/config.patch new file mode 100644 index 000000000..2a1dbfd99 --- /dev/null +++ b/lang/lua-coxpcall/patches/config.patch @@ -0,0 +1,4 @@ +--- lua-coxpcall-1.15.0_org/config 1970-01-01 08:00:00.000000000 +0800 ++++ lua-coxpcall-1.15.0/config 2014-06-04 16:51:55.487547258 +0800 +@@ -0,0 +1 @@ ++LUA_DIR ?=$(DESTDIR)/usr/lib/lua diff --git a/lang/lua-lzlib/Makefile b/lang/lua-lzlib/Makefile new file mode 100644 index 000000000..e4094f5b3 --- /dev/null +++ b/lang/lua-lzlib/Makefile @@ -0,0 +1,48 @@ +# +# Copyright (C) 2015 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:=lua-lzlib +PKG_VERSION:=0.4.3 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/LuaDist/lzlib.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=79329a07d8f79c19eadd7ea2752b4c4e1574b015 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-lzlib + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua zlib binding + URL:=http://github.com/LuaDist/lzlib + DEPENDS:= +lua +zlib +endef + +define Package/lua-lzlib/description + A library to access zlib library functions and also to read/write gzip files using an interface similar to the base io package. +endef + +MAKE_FLAGS += \ + LUA="$(STAGING_DIR)/usr" \ + OFLAGS="$(TARGET_CFLAGS)" \ + +define Package/lua-lzlib/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/zlib.so $(1)/usr/lib/lua/ + + $(INSTALL_DATA) $(PKG_BUILD_DIR)/gzip.lua $(1)/usr/lib/lua/ +endef + +$(eval $(call BuildPackage,lua-lzlib)) diff --git a/lang/lua-lzlib/patches/001-allow_optim_flags.patch b/lang/lua-lzlib/patches/001-allow_optim_flags.patch new file mode 100644 index 000000000..78f981d23 --- /dev/null +++ b/lang/lua-lzlib/patches/001-allow_optim_flags.patch @@ -0,0 +1,12 @@ +--- a/Makefile ++++ b/Makefile +@@ -14,7 +14,8 @@ LUABIN= $(LUA)/bin + ZLIB=../zlib-1.2.3 + + # no need to change anything below here +-CFLAGS= $(INCS) $(DEFS) $(WARN) -O0 -fPIC ++CFLAGS= $(INCS) $(DEFS) $(WARN) $(OFLAGS) -fPIC ++OFLAGS= -O0 + WARN= -g -Werror -Wall -pedantic #-ansi + INCS= -I$(LUAINC) -I$(ZLIB) + LIBS= -L$(ZLIB) -lz -L$(LUALIB) -L$(LUABIN) #-llua51 diff --git a/lang/lua-md5/Makefile b/lang/lua-md5/Makefile new file mode 100644 index 000000000..36e0d9db9 --- /dev/null +++ b/lang/lua-md5/Makefile @@ -0,0 +1,75 @@ +# +# Copyright (C) 2015 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:=lua-md5 +PKG_VERSION:=1.2 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/md5.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=024b65738b4434860777fc43d7cacaefea29ec60 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-md5 + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua-MD5 + URL:=https://github.com/keplerproject/md5 + DEPENDS:=+lua +endef + +define Package/lua-md5/description + MD5 offers basic cryptographic facilities for Lua +endef + +TARGET_CFLAGS += $(FPIC) + +# add make variable overrides here +MAKE_FLAGS += + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + PREFIX="$(STAGING_DIR)/usr" \ + LUA_LIBDIR="$(STAGING_DIR)/usr/lib/lua" \ + clean + $(MAKE) -C $(PKG_BUILD_DIR) \ + PREFIX="$(STAGING_DIR)/usr" \ + LUA_LIBDIR="$(STAGING_DIR)/usr/lib/lua" \ + LIB_OPTION="-shared" \ + CC="$(TARGET_CROSS)gcc" \ + CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \ + all +endef + +define Build/Install + $(MAKE) -C $(PKG_BUILD_DIR) \ + LUA_LIBDIR="$(PKG_INSTALL_DIR)/usr/lib/lua" \ + LUA_DIR="$(PKG_INSTALL_DIR)/usr/lib/lua" \ + install +endef + +define Package/lua-md5/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/md5.lua $(1)/usr/lib/lua + $(INSTALL_DIR) $(1)/usr/lib/lua/md5 + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/core.so $(1)/usr/lib/lua/md5/core.so +endef + +$(eval $(call BuildPackage,lua-md5)) diff --git a/lang/lua-md5/patches/config.patch b/lang/lua-md5/patches/config.patch new file mode 100644 index 000000000..abea3a88c --- /dev/null +++ b/lang/lua-md5/patches/config.patch @@ -0,0 +1,19 @@ +--- lua-md5-1.2/config 2014-06-04 16:55:50.000000000 +0800 ++++ lua-md5-1.2_new/config 2014-06-04 16:57:54.223539416 +0800 +@@ -1,13 +1,13 @@ + # Installation directories + + # Default prefix +-PREFIX = /usr/local ++PREFIX = /usr + + # System's libraries directory (where binary libraries are installed) +-LUA_LIBDIR= $(PREFIX)/lib/lua/5.1 ++LUA_LIBDIR= $(PREFIX)/lib/lua + + # System's lua directory (where Lua libraries are installed) +-LUA_DIR= $(PREFIX)/share/lua/5.1 ++LUA_DIR= $(PREFIX)/lib/lua + + # Lua includes directory + LUA_INC= $(PREFIX)/include diff --git a/lang/lua-md5/patches/makefile.patch b/lang/lua-md5/patches/makefile.patch new file mode 100644 index 000000000..89a2e33cd --- /dev/null +++ b/lang/lua-md5/patches/makefile.patch @@ -0,0 +1,10 @@ +--- a/Makefile.orig 2014-06-04 17:16:40.083514808 +0800 ++++ b/Makefile 2014-06-04 17:17:27.111513780 +0800 +@@ -1,6 +1,6 @@ + # $Id: Makefile,v 1.7 2007/10/11 00:02:56 carregal Exp $ + +-CONFIG= ./config ++CFLAGS+= -fPIC + + include $(CONFIG) + diff --git a/lang/lua-mobdebug/Makefile b/lang/lua-mobdebug/Makefile new file mode 100644 index 000000000..3d11539d9 --- /dev/null +++ b/lang/lua-mobdebug/Makefile @@ -0,0 +1,56 @@ +# +# Copyright (C) 2015 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:=lua-mobdebug +PKG_VERSION:=0.61 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/pkulchenko/MobDebug.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=9a03aa59696647ba3b7f9ae2f29a9f28532a4feb +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-mobdebug + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua-MobDebug + URL:=https://github.com/pkulchenko/MobDebug + DEPENDS:=+lua +endef + +define Package/lua-mobdebug/description + MobDebug is a remote debugger for Lua (including Lua 5.1, Lua 5.2, Lua 5.3, and LuaJIT 2.x). +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Build/Install +endef + +# add make variable overrides here +MAKE_FLAGS += + +define Package/lua-mobdebug/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/mobdebug.lua $(1)/usr/lib/lua +endef + +$(eval $(call BuildPackage,lua-mobdebug)) diff --git a/lang/lua-mosquitto/Makefile b/lang/lua-mosquitto/Makefile index a8d625f15..680df4b5e 100644 --- a/lang/lua-mosquitto/Makefile +++ b/lang/lua-mosquitto/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2013 OpenWrt.org +# Copyright (C) 2013-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -13,10 +13,11 @@ PKG_RELEASE:=1 PKG_LICENSE:=MIT PKG_LICENSE_FILES:=LICENSE -PKG_SOURCE:=v$(PKG_VERSION).tar.gz +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_URL:=https://github.com/flukso/$(PKG_NAME)/archive/ -PKG_MD5SUM:=fd26fa08fc855ba4a66ce521fe5aae13 +PKG_SOURCE_URL:=https://github.com/flukso/lua-mosquitto.git +PKG_SOURCE_VERSION:=v$(PKG_VERSION) include $(INCLUDE_DIR)/package.mk diff --git a/lang/lua-penlight/Makefile b/lang/lua-penlight/Makefile index e06f4c25b..89192e29a 100644 --- a/lang/lua-penlight/Makefile +++ b/lang/lua-penlight/Makefile @@ -8,11 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lua-penlight -PKG_VERSION:=1.3.1 +PKG_VERSION:=1.3.2 PKG_RELEASE:=1 PKG_BUILD_DIR:=$(BUILD_DIR)/Penlight-$(PKG_VERSION) PKG_SOURCE:=$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/stevedonovan/Penlight/archive/ +PKG_MD5SUM:=0315a39834bb6fab07741ec04ede1bf4 PKG_LICENSE:=MIT PKG_LICENSE_FILE:=LICENSE.md diff --git a/lang/lua-rings/Makefile b/lang/lua-rings/Makefile new file mode 100644 index 000000000..9b39c96be --- /dev/null +++ b/lang/lua-rings/Makefile @@ -0,0 +1,54 @@ +# +# Copyright (C) 2015 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:=lua-rings +PKG_VERSION:=1.3.0 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/rings.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=2b8a900f8b9dbde304859a3ac9d437795c3fdde3 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_FIXUP:=autoreconf + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-rings + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua-Rings + URL:=http://www.inf.puc-rio.br/~roberto/lua-rings/ + DEPENDS:=+lua +endef + +define Package/lua-rings/description + Rings is a library which provides a way to create new Lua states from within Lua. +endef + +TARGET_CFLAGS += $(FPIC) +# add make variable overrides here +MAKE_FLAGS += + +define Build/Configure +endef + +define Package/lua-rings/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/rings.so $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/stable.lua $(1)/usr/lib/lua +endef + +$(eval $(call BuildPackage,lua-rings)) diff --git a/lang/lua-rings/patches/config.patch b/lang/lua-rings/patches/config.patch new file mode 100644 index 000000000..5740faea9 --- /dev/null +++ b/lang/lua-rings/patches/config.patch @@ -0,0 +1,28 @@ +--- lua-rings-1.3.0_org/config 2014-06-04 15:24:24.223662038 +0800 ++++ lua-rings-1.3.0/config 2014-06-04 16:16:15.183594040 +0800 +@@ -1,15 +1,15 @@ + # Installation directories + + # Default prefix +-PREFIX ?= /usr/local ++PREFIX ?= /usr + + DESTDIR ?= / + + # System's libraries directory (where binary libraries are installed) +-LUA_LIBDIR ?= $(PREFIX)/lib/lua/5.1 ++LUA_LIBDIR ?= $(PREFIX)/lib/lua + + # System's lua directory (where Lua libraries are installed) +-LUA_DIR ?= $(PREFIX)/share/lua/5.1 ++LUA_DIR ?= $(PREFIX)/lib/lua + + # Lua includes directory + LUA_INC ?= $(PREFIX)/include +@@ -24,6 +24,5 @@ + WARN ?= -O2 -Wall -fPIC -W -Waggregate-return -Wcast-align -Wmissing-prototypes -Wnested-externs -Wshadow -Wwrite-strings -Wpointer-arith -pedantic + INCS ?= -I$(LUA_INC) + CFLAGS ?= $(WARN) $(INCS) +-CC ?= gcc + + # $Id: config,v 1.7 2007/10/29 22:51:39 carregal Exp $ diff --git a/lang/lua-rings/patches/makefile.patch b/lang/lua-rings/patches/makefile.patch new file mode 100644 index 000000000..8bb055120 --- /dev/null +++ b/lang/lua-rings/patches/makefile.patch @@ -0,0 +1,11 @@ +--- lua-rings-1.3.0_org/Makefile 2014-06-04 15:24:37.583661746 +0800 ++++ lua-rings-1.3.0/Makefile 2014-06-04 15:23:41.611662970 +0800 +@@ -3,6 +3,8 @@ + T= rings + CONFIG= ./config + ++CFLAGS+= -fPIC ++ + include $(CONFIG) + + SRCS= src/rings.c diff --git a/lang/lua-rs232/Makefile b/lang/lua-rs232/Makefile new file mode 100644 index 000000000..7ef5ac7e3 --- /dev/null +++ b/lang/lua-rs232/Makefile @@ -0,0 +1,62 @@ +# +# Copyright (C) 2015 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:=lua-rs232 +PKG_VERSION:=1.0.3 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/srdgame/librs232.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=a9d463181e7f7034fe6a55bc38e845fb04fa93ba +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-rs232 + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua Serial Library + URL:=https://github.com/srdgame/librs232 + DEPENDS:= +lua +endef + +define Package/lua-rs232/description + multiplatform library for serial communications over RS-232 +endef + +CONFIGURE_ARGS += \ + --with-lua-inc=$(STAGING_DIR)/usr/include \ + --with-lua-lib=$(STAGING_DIR)/usr/lib + +#define Build/Configure +# ( cd "$(PKG_BUILD_DIR)"; ./autogen.sh ) +# $(call Build/Configure/Default) +#endef +define Build/Configure +endef + +define Build/Compile + (cd "$(PKG_BUILD_DIR)"; $(TARGET_CC) src/rs232.c src/rs232_posix.c bindings/lua/luars232.c -DLUAROCKS_HACK -std=gnu99 -I./include -I$(STAGING_DIR)/usr/include -L$(STAGING_DIR)/usr/lib -fPIC -shared -o luars232.so) +endef + +define Build/Install +endef + +define Package/lua-rs232/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/luars232.so $(1)/usr/lib/lua/ +endef + +$(eval $(call BuildPackage,lua-rs232)) diff --git a/lang/lua-wsapi/Makefile b/lang/lua-wsapi/Makefile new file mode 100644 index 000000000..b382ad640 --- /dev/null +++ b/lang/lua-wsapi/Makefile @@ -0,0 +1,95 @@ +# +# Copyright (C) 2015 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:=lua-wsapi +PKG_VERSION:=1.6.1 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/wsapi.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=eed8338401196cc155e59280adbe58d78933ead0 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-wsapi/Default + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua WSAPI + URL:=http://www.keplerproject.org/wsapi + DEPENDS:= +lua +endef + +define Package/lua-wsapi/Default/description + WSAPI is an API that abstracts the web server from Lua web applications +endef + + +define Package/lua-wsapi-base +$(call Package/lua-wsapi/Default) + TITLE+= base + DEPENDS+= +luafilesystem + VARIANT:=base +endef + +define Package/lua-wsapi-base/description +$(call Package/lua-wsapi/Default/description) + . + This package contains the basic stuff. +endef + +define Package/lua-wsapi-xavante +$(call Package/lua-wsapi/Default) + TITLE+= xavante + DEPENDS+= +lua-wsapi-base +lua-xavante + VARIANT:=xavante +endef + +define Package/lua-wsapi-xavante/description +$(call Package/lua-wsapi/Default/description) + . + This package contains the Xavante stuff. +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Build/Install +endef + +define Package/lua-wsapi-base/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/wsapi.lua $(1)/usr/lib/lua + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/launcher/wsapi.cgi $(1)/usr/bin + + $(INSTALL_DIR) $(1)/usr/lib/lua/wsapi + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/wsapi/{common,request,response,util,cgi,sapi,ringer,mock}.lua $(1)/usr/lib/lua/wsapi +endef + +define Package/lua-wsapi-xavante/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/launcher/wsapi $(1)/usr/bin + + $(INSTALL_DIR) $(1)/usr/lib/lua/wsapi + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/wsapi/xavante.lua $(1)/usr/lib/lua/wsapi +endef + + +$(eval $(call BuildPackage,lua-wsapi-base)) +$(eval $(call BuildPackage,lua-wsapi-xavante)) diff --git a/lang/lua-xavante/Makefile b/lang/lua-xavante/Makefile new file mode 100644 index 000000000..13b66ee60 --- /dev/null +++ b/lang/lua-xavante/Makefile @@ -0,0 +1,58 @@ +# +# Copyright (C) 2015 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:=lua-xavante +PKG_VERSION:=2.3.0 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/keplerproject/xavante.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=9825b905133e14d37a4c179f2d02367ab93f1ef6 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lua-xavante + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Xavante Web Server + URL:=http://www.keplerproject.org/xavante + DEPENDS:= +lua +endef + +define Package/lua-xavante/description + Xavante is a Lua HTTP 1.1 Web server that uses a modular architecture based on URI mapped handlers. +endef + + +define Build/Configure +endef + +define Build/Compile +endef + +define Build/Install +endef + +define Package/lua-xavante/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/sajax/sajax.lua $(1)/usr/lib/lua + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/xavante/xavante.lua $(1)/usr/lib/lua + + $(INSTALL_DIR) $(1)/usr/lib/lua/xavante + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/xavante/{cgiluahandler,encoding,filehandler,httpd,mime,patternhandler,redirecthandler,vhostshandler,indexhandler,urlhandler,ruleshandler}.lua $(1)/usr/lib/lua/xavante +endef + +$(eval $(call BuildPackage,lua-xavante)) diff --git a/lang/luaexpat/Makefile b/lang/luaexpat/Makefile index 6b73254d6..3c2f23180 100644 --- a/lang/luaexpat/Makefile +++ b/lang/luaexpat/Makefile @@ -41,7 +41,7 @@ define Build/Compile LUA_INC="-I$(STAGING_DIR)/usr/include/" \ LUA_LIBDIR="$(STAGING_DIR)/usr/lib/" \ COMPAT_DIR="$(PKG_BUILD_DIR)/compat-5.1r5" \ - LIB_OPTION="-shared $(TARGET_LDFLAGS)" \ + LDFLAGS="-shared $(TARGET_LDFLAGS)" \ CC="$(TARGET_CC) $(TARGET_CFLAGS) $(FPIC) -std=c99" \ LD="$(TARGET_CROSS)ld -shared" endef diff --git a/lang/luaposix/Makefile b/lang/luaposix/Makefile index dd4a05671..a189e6645 100644 --- a/lang/luaposix/Makefile +++ b/lang/luaposix/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luaposix PKG_VERSION:=v33.2.1 -PKG_RELEASE:=4 +PKG_RELEASE:=5 PKG_SOURCE:=release-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/luaposix/luaposix/archive/ @@ -41,8 +41,11 @@ endef CONFIGURE_VARS += ac_cv_path_LDOC="" TARGET_CFLAGS += -DLUA_USE_LINUX $(FPIC) -std=gnu99 +ifeq ($(CONFIG_USE_MUSL),y) + TARGET_CFLAGS += -D_POSIX_PRIORITY_SCHEDULING +endif -ifneq ($(CONFIG_USE_EGLIBC),) +ifneq ($(CONFIG_USE_GLIBC),) ifeq ($(CONFIG_EGLIBC_OPTION_EGLIBC_UTMP),) TARGET_CFLAGS += -DNO_GETLOGIN endif diff --git a/lang/luarocks/Makefile b/lang/luarocks/Makefile new file mode 100644 index 000000000..e0a0f5711 --- /dev/null +++ b/lang/luarocks/Makefile @@ -0,0 +1,58 @@ +# +# Copyright (C) 2006-2015 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:=luarocks +PKG_VERSION:=2.2.2 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/keplerproject/luarocks.git +PKG_SOURCE_VERSION:=v$(PKG_VERSION) + +PKG_MAINTAINER:=Amr Hassan +PKG_INSTALL=1 +PKG_BUILD_DEPENDS:=lua/host luac/host +PKG_LICENSE=GPL + +include $(INCLUDE_DIR)/package.mk + +define Package/luarocks + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=luarocks + URL:=https://github.com/keplerproject/luarocks + DEPENDS:=+lua +luac +liblua +luasocket +unzip +curl +luasec +endef + +define Package/luarocks/description + LuaRocks is a deployment and management system for Lua modules. +endef + +# My custom args, copied and modified from SDK_ROOT/include/package-defaults.mk +CONFIGURE_ARGS = \ + --prefix=$(CONFIGURE_PREFIX) \ + --sysconfdir=/etc \ + --with-lua=$(STAGING_DIR_HOST) + +define Build/Compile + $(call Build/Compile/Default,build) +endef + +define Package/luarocks/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/luarocks-5.1 $(1)/usr/bin/luarocks + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/luarocks-admin-5.1 $(1)/usr/bin/luarocks-admin + $(CP) $(PKG_INSTALL_DIR)/usr/share $(1)/usr/share + $(CP) $(PKG_INSTALL_DIR)/etc $(1)/etc +endef + +$(eval $(call BuildPackage,luarocks)) diff --git a/lang/luarocks/patches/01_dont_modify_bin_shebang.diff b/lang/luarocks/patches/01_dont_modify_bin_shebang.diff new file mode 100644 index 000000000..a1bad2151 --- /dev/null +++ b/lang/luarocks/patches/01_dont_modify_bin_shebang.diff @@ -0,0 +1,13 @@ +diff -rupN luarocks/Makefile luarocks.new/Makefile +--- luarocks/Makefile 2015-02-19 13:24:07.027310956 +0200 ++++ luarocks.new/Makefile 2015-02-22 13:28:24.497353543 +0200 +@@ -104,7 +104,7 @@ build_bins: cleanup_bins + for f in $(BIN_FILES) ;\ + do \ + sed "1d" src/bin/$$f > src/bin/$$f.bak ;\ +- echo "#!$(LUA_BINDIR)/lua$(LUA_SUFFIX)" > src/bin/$$f ;\ ++ echo "#!/usr/bin/env lua" > src/bin/$$f ;\ + echo "package.path = [[$(LUADIR)/?.lua;]]..package.path" | sed "s,//,/,g" >> src/bin/$$f ;\ + cat src/bin/$$f.bak >> src/bin/$$f ;\ + chmod +x src/bin/$$f ;\ +Binary files luarocks/src/bin/.luarocks.swp and luarocks.new/src/bin/.luarocks.swp differ diff --git a/lang/luasocket/Makefile b/lang/luasocket/Makefile index ceb707729..5e7c98300 100644 --- a/lang/luasocket/Makefile +++ b/lang/luasocket/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luasocket PKG_SOURCE_VERSION:=6d5e40c324c84d9c1453ae88e0ad5bdd0a631448 PKG_VERSION:=3.0-rc1-20130909 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://github.com/diegonehab/luasocket.git @@ -56,6 +56,7 @@ define Package/luasocket/install 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 + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/unix.so $(1)/usr/lib/lua/socket ln -sf ../socket.so.3.0-rc1 $(1)/usr/lib/lua/socket/core.so endef diff --git a/lang/luasql/Makefile b/lang/luasql/Makefile index 6df105dc7..204d6cc1a 100644 --- a/lang/luasql/Makefile +++ b/lang/luasql/Makefile @@ -11,9 +11,11 @@ PKG_NAME:=luasql PKG_VERSION:=2.3.0 PKG_RELEASE:=1 -PKG_SOURCE:=v$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://github.com/keplerproject/luasql/archive/ -PKG_MD5SUM:=af9f0f3a2313a1fcf88c40700092048d +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/keplerproject/luasql.git +PKG_SOURCE_VERSION:=v$(PKG_VERSION) PKG_LICENSE:=MIT PKG_LICENSE_FILES:=docs/us/license.html diff --git a/lang/lzmq/Makefile b/lang/lzmq/Makefile new file mode 100644 index 000000000..b17b945d3 --- /dev/null +++ b/lang/lzmq/Makefile @@ -0,0 +1,48 @@ +# +# Copyright (C) 2015 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:=lzmq +PKG_VERSION:=0.4.3 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=MIT + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://codeload.github.com/zeromq/lzmq/tar.gz/v$(PKG_VERSION)? +PKG_MD5SUM:=c4e51a60a5a26987bdce59e45d674a9e + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/cmake.mk + +define Package/lzmq + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=Lua ZeroMQ binding + URL:=https://github.com/moteus/lzmq/ + DEPENDS:= +lua +libzmq +endef + +define Package/lzmq/description + LZMQ is a Lua binding to ZeroMQ. +endef + +CMAKE_OPTIONS += \ + -DUSE_LUA=ON + +define Package/lzmq/install + $(INSTALL_DIR) $(1)/usr/lib/lua + $(INSTALL_BIN) $(PKG_BUILD_DIR)/lzmq.so $(1)/usr/lib/lua/ + + $(INSTALL_DIR) $(1)/usr/lib/lua/lzmq + $(INSTALL_BIN) $(PKG_BUILD_DIR)/lzmq/timer.so $(1)/usr/lib/lua/lzmq + $(CP) -R $(PKG_BUILD_DIR)/src/lua/lzmq/* $(1)/usr/lib/lua/lzmq +endef + +$(eval $(call BuildPackage,lzmq)) diff --git a/lang/micropython-lib/Makefile b/lang/micropython-lib/Makefile index b74ad0e08..c8162dc54 100644 --- a/lang/micropython-lib/Makefile +++ b/lang/micropython-lib/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=micropython-lib -PKG_VERSION=0.1-20141028-$(PKG_SOURCE_VERSION) +PKG_VERSION=0.1-20150601-$(PKG_SOURCE_VERSION) PKG_RELEASE:=1 PKG_MAINTAINER:=Roger D @@ -17,7 +17,7 @@ PKG_LICENSE_FILES:=LICENSE PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/micropython/micropython-lib.git -PKG_SOURCE_VERSION:=610aa65ceff9f4b0a60514423f543aa807f49f76 +PKG_SOURCE_VERSION:=b8092c1838f4942a0fab62c1eb6d08b542cc9e9b PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION) PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz diff --git a/lang/micropython/Makefile b/lang/micropython/Makefile index c1904567c..d5c66ada6 100644 --- a/lang/micropython/Makefile +++ b/lang/micropython/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=micropython -PKG_VERSION=1.3.7-20141209-$(PKG_SOURCE_VERSION) +PKG_VERSION=1.4.3-20150601-$(PKG_SOURCE_VERSION) PKG_RELEASE:=1 PKG_MAINTAINER:=Roger D @@ -17,7 +17,7 @@ PKG_LICENSE_FILES:=LICENSE PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/micropython/micropython.git -PKG_SOURCE_VERSION:=e6e8ad8ab238cd596a3eedf8f4dd635e2e84f46e +PKG_SOURCE_VERSION:=3ac2d06bd13f1cedb8242eaacc6c608ac08c3520 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz diff --git a/lang/perl-compress-bzip2/Makefile b/lang/perl-compress-bzip2/Makefile index 0671cd971..fbb388f18 100644 --- a/lang/perl-compress-bzip2/Makefile +++ b/lang/perl-compress-bzip2/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-compress-bzip2 PKG_VERSION:=2.22 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/R/RU/RURBAN/ PKG_SOURCE:=Compress-Bzip2-$(PKG_VERSION).tar.gz diff --git a/lang/perl-dbi/Makefile b/lang/perl-dbi/Makefile index 263359128..c752e9602 100644 --- a/lang/perl-dbi/Makefile +++ b/lang/perl-dbi/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-dbi PKG_VERSION:=1.633 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/T/TI/TIMB/ PKG_SOURCE:=DBI-$(PKG_VERSION).tar.gz diff --git a/lang/perl-device-serialport/Makefile b/lang/perl-device-serialport/Makefile new file mode 100644 index 000000000..22297ae9b --- /dev/null +++ b/lang/perl-device-serialport/Makefile @@ -0,0 +1,53 @@ +# +# Copyright (C) 2014, 2015 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-device-serialport +PKG_VERSION:=1.04 +PKG_RELEASE:=2 + +PKG_SOURCE_URL:=http://www.cpan.org/authors/id/C/CO/COOK/ +PKG_SOURCE:=Device-SerialPort-$(PKG_VERSION).tar.gz +PKG_MD5SUM:=82c698151f934eb28c65d1838cee7d9e + +PKG_LICENSE:=GPL-1.0+ Artistic-1.0-Perl +PKG_MAINTAINER:=Paul Oranje + +PKG_BUILD_DIR:=$(BUILD_DIR)/perl/Device-SerialPort-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk +include ../perl/perlmod.mk + +define Package/perl-device-serialport + SUBMENU:=Perl + SECTION:=lang + CATEGORY:=Languages + TITLE:=A POSIX-based version of the Win32::SerialPort module + URL:=http://search.cpan.org/dist/Device-SerialPort/ + DEPENDS:=perl +perlbase-essential +endef + +define Package/perl-device-serialport/description + A POSIX-based version of the Win32::SerialPort module + that provides modem support to Perl applications +endef + +define Build/Configure + $(call perlmod/Configure,,) +endef + +define Build/Compile + $(call perlmod/Compile,,) +endef + +define Package/perl-device-serialport/install + $(call perlmod/Install,$(1),Device auto/Device) +endef + + +$(eval $(call BuildPackage,perl-device-serialport)) diff --git a/lang/perl-html-parser/Makefile b/lang/perl-html-parser/Makefile index 6baa88d82..d1c86af61 100644 --- a/lang/perl-html-parser/Makefile +++ b/lang/perl-html-parser/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-html-parser PKG_VERSION:=3.71 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/G/GA/GAAS/ PKG_SOURCE:=HTML-Parser-$(PKG_VERSION).tar.gz diff --git a/lang/perl-html-tagset/Makefile b/lang/perl-html-tagset/Makefile index fbec409cf..d7b0b0c83 100644 --- a/lang/perl-html-tagset/Makefile +++ b/lang/perl-html-tagset/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-html-tagset PKG_VERSION:=3.20 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/P/PE/PETDANCE/ PKG_SOURCE:=HTML-Tagset-$(PKG_VERSION).tar.gz diff --git a/lang/perl-html-tree/Makefile b/lang/perl-html-tree/Makefile index 614aff7fb..942e3bf22 100644 --- a/lang/perl-html-tree/Makefile +++ b/lang/perl-html-tree/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-html-tree PKG_VERSION:=3.23 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_MD5SUM:=6352f50be402301f79b580dd235d7762 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/P/PE/PETEK/ diff --git a/lang/perl-lockfile-simple/Makefile b/lang/perl-lockfile-simple/Makefile index e65d4a570..97e3c568a 100644 --- a/lang/perl-lockfile-simple/Makefile +++ b/lang/perl-lockfile-simple/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-lockfile-simple PKG_VERSION:=0.208 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/S/SC/SCHWIGON/lockfile-simple/ PKG_SOURCE:=LockFile-Simple-$(PKG_VERSION).tar.gz diff --git a/lang/perl-net-telnet/Makefile b/lang/perl-net-telnet/Makefile index d229cd814..f1823fc92 100644 --- a/lang/perl-net-telnet/Makefile +++ b/lang/perl-net-telnet/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-net-telnet PKG_VERSION:=3.04 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/J/JR/JROGERS/ PKG_SOURCE:=Net-Telnet-$(PKG_VERSION).tar.gz diff --git a/lang/perl-test-harness/Makefile b/lang/perl-test-harness/Makefile index 9a0f0a532..aa08dec94 100644 --- a/lang/perl-test-harness/Makefile +++ b/lang/perl-test-harness/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-test-harness PKG_VERSION:=3.35 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/L/LE/LEONT/ PKG_SOURCE:=Test-Harness-$(PKG_VERSION).tar.gz diff --git a/lang/perl-uri/Makefile b/lang/perl-uri/Makefile index 64cc10f17..df46d5292 100644 --- a/lang/perl-uri/Makefile +++ b/lang/perl-uri/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2015 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:=perl-uri -PKG_VERSION:=1.65 -PKG_RELEASE:=1 +PKG_VERSION:=1.67 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/E/ET/ETHER/ PKG_SOURCE:=URI-$(PKG_VERSION).tar.gz -PKG_MD5SUM:=12c5d612a20ddd42041a5aa426f66269 +PKG_MD5SUM:=d0ef53b6c63bcc02ba55f405c30741e3 PKG_LICENSE:=GPL-1.0+ Artistic-1.0-Perl PKG_MAINTAINER:=Marcel Denia diff --git a/lang/perl-www-curl/Makefile b/lang/perl-www-curl/Makefile index 8bc3bfda5..3eaa3d01c 100644 --- a/lang/perl-www-curl/Makefile +++ b/lang/perl-www-curl/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-www-curl PKG_VERSION:=4.17 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/S/SZ/SZBALINT/ PKG_SOURCE:=WWW-Curl-$(PKG_VERSION).tar.gz diff --git a/lang/perl-www-mechanize/Makefile b/lang/perl-www-mechanize/Makefile index 576424cd2..9fb1fcb22 100644 --- a/lang/perl-www-mechanize/Makefile +++ b/lang/perl-www-mechanize/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-www-mechanize PKG_VERSION:=1.74 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=WWW-Mechanize-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.cpan.org/authors/id/E/ET/ETHER/ diff --git a/lang/perl-www/Makefile b/lang/perl-www/Makefile index fadc1c023..acd9e9b9f 100644 --- a/lang/perl-www/Makefile +++ b/lang/perl-www/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl-www PKG_VERSION:=5.837 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://www.cpan.org/authors/id/G/GA/GAAS/ PKG_SOURCE:=libwww-perl-$(PKG_VERSION).tar.gz @@ -33,7 +33,7 @@ define Package/perl-www endef define Build/Configure - $(call perlmod/Configure,-n,) + $(call perlmod/Configure,,) endef define Build/Compile diff --git a/lang/perl/Config.in b/lang/perl/Config.in index 11cb5eb11..14aedc285 100644 --- a/lang/perl/Config.in +++ b/lang/perl/Config.in @@ -3,7 +3,7 @@ menu "Configuration" config PERL_THREADS bool "Enable threading support" - default y if (mips || mipsel || i386 || i686 || x86_64 || armeb || arm) && (USE_UCLIBC || USE_EGLIBC) + default y if (mips || mipsel || i386 || i686 || x86_64 || armeb || arm) default n config PERL_TESTS diff --git a/lang/perl/Makefile b/lang/perl/Makefile index c3fe981f9..3259861b4 100644 --- a/lang/perl/Makefile +++ b/lang/perl/Makefile @@ -8,11 +8,11 @@ include $(TOPDIR)/rules.mk PKG_NAME:=perl -PKG_VERSION:=5.20.2 -PKG_RELEASE:=1 +PKG_VERSION:=5.22.0 +PKG_RELEASE:=0 PKG_SOURCE_URL:=ftp://ftp.cpan.org/pub/CPAN/src/5.0 \ - http://www.cpan.org/src/5.0/perl-5.20.0.tar.gz \ + http://www.cpan.org/src/5.0 \ ftp://ftp.mpi-sb.mpg.de/pub/perl/CPAN/src/5.0 \ http://ftp.mpi-sb.mpg.de/pub/perl/CPAN/src/5.0 \ ftp://ftp.gmd.de/mirrors/CPAN/src/5.0 \ @@ -20,7 +20,7 @@ PKG_SOURCE_URL:=ftp://ftp.cpan.org/pub/CPAN/src/5.0 \ ftp://ftp.funet.fi/pub/languages/perl/CPAN/src/5.0 \ http://ftp.funet.fi/pub/languages/perl/CPAN/src/5.0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_MD5SUM:=81b17b9a4e5ee18e54efe906c9bf544d +PKG_MD5SUM:=e32cb6a8dda0084f2a43dac76318d68d PKG_LICENSE:=GPL-1.0+ Artistic-1.0-Perl PKG_LICENSE_FILES:=Copying Artistic README @@ -36,7 +36,7 @@ HOST_BUILD_PARALLEL:=1 # Variables used during configuration/build HOST_PERL_PREFIX:=$(STAGING_DIR_HOST)/usr -ifneq ($(CONFIG_USE_EGLIBC),) +ifneq ($(CONFIG_USE_GLIBC),) EXTRA_LIBS:=bsd EXTRA_LIBDIRS:=$(STAGING_DIR)/lib endif @@ -50,7 +50,7 @@ ifdef CONFIG_PERL_THREADS PERL_CONFIG_SUFFIX:=-mt # uclibc doesn't provide crypt_r(). Enable crypt() usage for glibc builds only - ifdef CONFIG_USE_EGLIBC + ifdef CONFIG_USE_GLIBC CRYPT_R_PROTO:=REENTRANT_PROTO_B_CCS CRYPT:=define else @@ -79,7 +79,7 @@ define Package/perl CATEGORY:=Languages TITLE:=The Perl intepreter URL:=http://www.perl.com/ - DEPENDS:=+USE_EGLIBC:libbsd +PERL_THREADS:libpthread + DEPENDS:=+USE_GLIBC:libbsd +PERL_THREADS:libpthread endef define Package/perl/description @@ -94,7 +94,7 @@ endef # Static host perl define Host/Configure - ( cd $(HOST_BUILD_DIR); ./Configure -der -Uusedl -Duserelocatableinc -Dprefix=$(HOST_PERL_PREFIX) ) + ( cd $(HOST_BUILD_DIR); ./Configure -der -Uusedl -Duserelocatableinc -Dprefix=$(HOST_PERL_PREFIX) $(if $(CONFIG_PERL_THREADS),-Dusethreads,)) endef define Host/Install @@ -128,6 +128,27 @@ define Build/Configure -e 's!%%HOSTGENERATE%%!$(HOST_PERL_PREFIX)/bin/generate_uudmap!g' \ files/config.sh-$(patsubst i386,i486,$(ARCH))$(PERL_CONFIG_SUFFIX).in \ > $(PKG_BUILD_DIR)/config.sh + ifeq ($(CONFIG_USE_MUSL),y) + sed -i \ + -e "s,\(d_stdio_ptr_lval=\)'define',\1'undef',g" \ + -e "s,\(d_stdio_ptr_lval_sets_cnt=\)'define',\1'undef',g" \ + -e "s,\(d_stdiobase=\)'define',\1'undef',g" \ + -e "s,\(d_stdstdio=\)'define',\1'undef',g" \ + -e "s,\(d_getnetbyname_r=\)'define',\1'undef',g" \ + -e "s,\(getprotobyname_r=\)'define',\1'undef',g" \ + -e "s,\(getpwent_r=\)'define',\1'undef',g" \ + -e "s,\(getservent_r=\)'define',\1'undef',g" \ + -e "s,\(gethostent_r=\)'define',\1'undef',g" \ + -e "s,\(getnetent_r=\)'define',\1'undef',g" \ + -e "s,\(getnetbyaddr_r=\)'define',\1'undef',g" \ + -e "s,\(getprotoent_r=\)'define',\1'undef',g" \ + -e "s,\(getprotobynumber_r=\)'define',\1'undef',g" \ + -e "s,\(getgrent_r=\)'define',\1'undef',g" \ + -e "s,\(i_fcntl=\)'undef',\1'define',g" \ + -e "s,\(h_fcntl=\)'false',\1'true',g" \ + -e "s,\(d_strerror_r=\)'define',\1'undef',g" \ + $(PKG_BUILD_DIR)/config.sh + endif (cd $(PKG_BUILD_DIR) && ./Configure -S) install -m 0644 $(PKG_BUILD_DIR)/config.h $(PKG_BUILD_DIR)/xconfig.h endef @@ -137,8 +158,8 @@ define Build/Compile endef define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/lib/perl5/5.20 - $(CP) $(PKG_INSTALL_DIR)/usr/lib/perl5/5.20 $(1)/usr/lib/perl5/ + $(INSTALL_DIR) $(1)/usr/lib/perl5/$(PERL_VERSION) + $(CP) $(PKG_INSTALL_DIR)/usr/lib/perl5/$(PERL_VERSION) $(1)/usr/lib/perl5/ endef define Package/perl/install @@ -146,8 +167,8 @@ define Package/perl/install $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/perl$(PKG_VERSION) $(1)/usr/bin ln -nsf perl$(PKG_VERSION) $(1)/usr/bin/perl - $(INSTALL_DIR) $(1)/usr/lib/perl5/5.20/CORE - $(CP) $(PKG_INSTALL_DIR)/usr/lib/perl5/5.20/CORE/libperl.so $(1)/usr/lib/perl5/5.20/CORE/ + $(INSTALL_DIR) $(1)/usr/lib/perl5/$(PERL_VERSION)/CORE + $(CP) $(PKG_INSTALL_DIR)/usr/lib/perl5/$(PERL_VERSION)/CORE/libperl.so $(1)/usr/lib/perl5/$(PERL_VERSION)/CORE/ endef @@ -171,9 +192,9 @@ define Package/perl-tests-common/install $(INSTALL_DIR) $(1)/$(PERL_TESTSDIR) $(INSTALL_DIR) $(1)/$(PERL_TESTSDIR)/Porting $(INSTALL_DIR) $(1)/$(PERL_TESTSDIR)/regen - $(INSTALL_DIR) $(1)/usr/lib/perl5/5.20/XS - $(INSTALL_DIR) $(1)/usr/lib/perl5/5.20/auto/XS - $(INSTALL_DIR) $(1)/usr/lib/perl5/5.20/unicore + $(INSTALL_DIR) $(1)/usr/lib/perl5/$(PERL_VERSION)/XS + $(INSTALL_DIR) $(1)/usr/lib/perl5/$(PERL_VERSION)/auto/XS + $(INSTALL_DIR) $(1)/usr/lib/perl5/$(PERL_VERSION)/unicore $(CP) $(PKG_BUILD_DIR)/t $(1)/$(PERL_TESTSDIR) $(CP) $(PKG_BUILD_DIR)/Porting $(1)/$(PERL_TESTSDIR) @@ -182,12 +203,15 @@ define Package/perl-tests-common/install $(CP) $(PKG_BUILD_DIR)/TestInit.pm $(1)/$(PERL_TESTSDIR) $(CP) $(PKG_BUILD_DIR)/vutil.c $(1)/$(PERL_TESTSDIR) $(CP) $(PKG_BUILD_DIR)/vxs.inc $(1)/$(PERL_TESTSDIR) - $(CP) $(PKG_BUILD_DIR)/lib/XS $(1)/usr/lib/perl5/5.20/ - $(CP) $(PKG_BUILD_DIR)/lib/auto/XS $(1)/usr/lib/perl5/5.20/auto - $(CP) $(PKG_BUILD_DIR)/lib/vmsish.pm $(1)/usr/lib/perl5/5.20/ - $(CP) $(PKG_BUILD_DIR)/lib/unicore/TestProp.pl $(1)/usr/lib/perl5/5.20/unicore + $(CP) $(PKG_BUILD_DIR)/lib/XS $(1)/usr/lib/perl5/$(PERL_VERSION)/ + $(CP) $(PKG_BUILD_DIR)/lib/auto/XS $(1)/usr/lib/perl5/$(PERL_VERSION)/auto + $(CP) $(PKG_BUILD_DIR)/lib/vmsish.pm $(1)/usr/lib/perl5/$(PERL_VERSION)/ + $(CP) $(PKG_BUILD_DIR)/lib/unicore/TestProp.pl $(1)/usr/lib/perl5/$(PERL_VERSION)/unicore $(CP) files/perl-run_tests.sh $(1)/$(PERL_TESTSDIR)/run_tests.sh - sed -e 's!%%PERL_DISABLEDTESTS%%!$(PERL_DISABLEDTESTS)!' -i $(1)/$(PERL_TESTSDIR)/run_tests.sh + sed \ + -e 's!%%PERL_DISABLEDTESTS%%!$(PERL_DISABLEDTESTS)!' \ + -e 's!%%PERL_VERSION%%!$(PERL_VERSION)!' \ + -i $(1)/$(PERL_TESTSDIR)/run_tests.sh $(CP) $(PKG_BUILD_DIR)/config_h.SH $(1)/$(PERL_TESTSDIR) $(CP) $(PKG_BUILD_DIR)/perl.h $(1)/$(PERL_TESTSDIR) endef diff --git a/lang/perl/files/config.sh-arm-mt.in b/lang/perl/files/config.sh-arm-mt.in index 635b05e9e..2a7a3db3d 100644 --- a/lang/perl/files/config.sh-arm-mt.in +++ b/lang/perl/files/config.sh-arm-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5tel unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__ARM_ARCH_3__=1' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1064,7 +1126,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1099,6 +1160,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1136,27 +1198,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-arm.in b/lang/perl/files/config.sh-arm.in index 9382b6536..0403c7cb3 100644 --- a/lang/perl/files/config.sh-arm.in +++ b/lang/perl/files/config.sh-arm.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5tel unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__ARM_ARCH_3__=1' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1063,7 +1125,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1098,6 +1159,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1135,27 +1197,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-armeb-mt.in b/lang/perl/files/config.sh-armeb-mt.in index 6dad0eb1d..33b3c0907 100644 --- a/lang/perl/files/config.sh-armeb-mt.in +++ b/lang/perl/files/config.sh-armeb-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5teb unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -52,7 +51,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__ARM_ARCH_3__=1' @@ -100,10 +99,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -113,6 +115,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -124,6 +127,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -133,6 +137,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -148,6 +153,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -169,7 +175,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -178,19 +188,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -263,27 +281,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -322,6 +363,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -344,6 +389,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -355,19 +401,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -437,6 +491,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -478,12 +533,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -509,7 +567,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -523,6 +583,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -541,7 +602,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -614,7 +674,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -640,6 +702,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -647,6 +710,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -727,7 +791,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -754,6 +817,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -762,10 +826,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -948,7 +1008,6 @@ stdio_stream_array='' strerror_r_proto='REENTRANT_PROTO_B_IBW' #strings='/usr/include/string.h' submit='' -subversion='0' sysman='/usr/share/man/man1' tail='' tar='' @@ -983,6 +1042,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1057,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1064,7 +1125,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1099,6 +1159,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1136,27 +1197,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-armeb.in b/lang/perl/files/config.sh-armeb.in index b6e828b6a..4b3b3418b 100644 --- a/lang/perl/files/config.sh-armeb.in +++ b/lang/perl/files/config.sh-armeb.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5teb unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -52,7 +51,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__ARM_ARCH_3__=1' @@ -100,10 +99,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -113,6 +115,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -124,6 +127,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -133,6 +137,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -148,6 +153,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -169,7 +175,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -178,19 +188,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -263,27 +281,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -322,6 +363,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -344,6 +389,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -355,19 +401,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -437,6 +491,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -478,12 +533,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -509,7 +567,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -523,6 +583,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -541,7 +602,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -614,7 +674,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -640,6 +702,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -647,6 +710,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -727,7 +791,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -754,6 +817,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -762,10 +826,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -948,7 +1008,6 @@ stdio_stream_array='' strerror_r_proto='0' #strings='/usr/include/string.h' submit='' -subversion='0' sysman='/usr/share/man/man1' tail='' tar='' @@ -983,6 +1042,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1057,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1063,7 +1124,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1098,6 +1158,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1135,27 +1196,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-avr32-mt.in b/lang/perl/files/config.sh-avr32-mt.in index 7336b666d..fd420a2c9 100644 --- a/lang/perl/files/config.sh-avr32-mt.in +++ b/lang/perl/files/config.sh-avr32-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5teb unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -103,10 +102,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -116,6 +118,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -127,6 +130,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -136,6 +140,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -151,6 +156,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -172,7 +178,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -181,19 +191,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -266,27 +284,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -325,6 +366,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -347,6 +392,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -358,19 +404,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -440,6 +494,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -481,12 +536,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -512,7 +570,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -526,6 +586,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -544,7 +605,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -617,7 +677,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -643,6 +705,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -650,6 +713,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -730,7 +794,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -757,6 +820,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -765,10 +829,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -985,6 +1045,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='undef' usedl='define' usefaststdio='undef' @@ -999,6 +1060,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1066,7 +1128,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1101,6 +1162,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1138,27 +1200,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-avr32.in b/lang/perl/files/config.sh-avr32.in index 2ec7588e3..ee4e5ce67 100644 --- a/lang/perl/files/config.sh-avr32.in +++ b/lang/perl/files/config.sh-avr32.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 armv5teb unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -103,10 +102,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -116,6 +118,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -127,6 +130,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -136,6 +140,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -151,6 +156,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -172,7 +178,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -181,19 +191,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -266,27 +284,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -325,6 +366,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -347,6 +392,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -358,19 +404,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -440,6 +494,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -481,12 +536,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -512,7 +570,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -526,6 +586,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -544,7 +605,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -617,7 +677,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -643,6 +705,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -650,6 +713,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -730,7 +794,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -757,6 +820,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -765,10 +829,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -985,6 +1045,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='undef' usedl='define' usefaststdio='undef' @@ -999,6 +1060,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1065,7 +1127,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1100,6 +1161,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1137,27 +1199,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-i486-mt.in b/lang/perl/files/config.sh-i486-mt.in index 89583b65b..06c8c5e12 100644 --- a/lang/perl/files/config.sh-i486-mt.in +++ b/lang/perl/files/config.sh-i486-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.25 #2 sat apr 19 09:46:49 cest 2008 i686 unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='3' longdblsize='12' longlongsize='8' longsize='4' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1050,7 +1112,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1085,6 +1146,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1122,27 +1184,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-i486.in b/lang/perl/files/config.sh-i486.in index 9d91dff70..a4230378e 100644 --- a/lang/perl/files/config.sh-i486.in +++ b/lang/perl/files/config.sh-i486.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.25 #2 sat apr 19 09:46:49 cest 2008 i686 unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='3' longdblsize='12' longlongsize='8' longsize='4' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1049,7 +1111,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1084,6 +1145,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1121,27 +1183,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mips-mt.in b/lang/perl/files/config.sh-mips-mt.in index 8564c2338..c7774016a 100644 --- a/lang/perl/files/config.sh-mips-mt.in +++ b/lang/perl/files/config.sh-mips-mt.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1064,7 +1126,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1099,6 +1160,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1136,27 +1198,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mips.in b/lang/perl/files/config.sh-mips.in index 1a752e74b..585cf62d8 100644 --- a/lang/perl/files/config.sh-mips.in +++ b/lang/perl/files/config.sh-mips.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1063,7 +1125,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1098,6 +1159,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1135,27 +1197,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mips64-mt.in b/lang/perl/files/config.sh-mips64-mt.in index 26d908a7e..884260a8d 100644 --- a/lang/perl/files/config.sh-mips64-mt.in +++ b/lang/perl/files/config.sh-mips64-mt.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='undef' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='define' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='8' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='6' longdblsize='16' longlongsize='8' longsize='8' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long' use5005threads='undef' use64bitall='define' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1064,7 +1126,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1099,6 +1160,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1136,27 +1198,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mips64.in b/lang/perl/files/config.sh-mips64.in index baab56fdb..be3b334ee 100644 --- a/lang/perl/files/config.sh-mips64.in +++ b/lang/perl/files/config.sh-mips64.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='undef' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='define' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='8' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='6' longdblsize='16' longlongsize='8' longsize='8' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long' use5005threads='undef' use64bitall='define' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1063,7 +1125,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1098,6 +1159,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1135,27 +1197,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mipsel-mt.in b/lang/perl/files/config.sh-mipsel-mt.in index d09586a88..26c6d4ed9 100644 --- a/lang/perl/files/config.sh-mipsel-mt.in +++ b/lang/perl/files/config.sh-mipsel-mt.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1050,7 +1112,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1085,6 +1146,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1122,27 +1184,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-mipsel.in b/lang/perl/files/config.sh-mipsel.in index 43c61a69c..0c424f1cf 100644 --- a/lang/perl/files/config.sh-mipsel.in +++ b/lang/perl/files/config.sh-mipsel.in @@ -13,14 +13,13 @@ # Target system : linux merope 2.4.30 #1 di 23. jan 15:23:42 cet 2007 mips unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='define' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='define' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='define' +d_j0l='define' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='define' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1049,7 +1111,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1084,6 +1145,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1121,27 +1183,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-powerpc-mt.in b/lang/perl/files/config.sh-powerpc-mt.in index 564f27bc7..c24eb9b40 100644 --- a/lang/perl/files/config.sh-powerpc-mt.in +++ b/lang/perl/files/config.sh-powerpc-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 ppc unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__gnu_linux__=1 __linux=1 __linux__=1 __unix=1 __unix__=1 system=linux system=posix system=unix' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1064,7 +1126,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1099,6 +1160,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1136,27 +1198,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-powerpc.in b/lang/perl/files/config.sh-powerpc.in index 8906ad68b..cbeb2185a 100644 --- a/lang/perl/files/config.sh-powerpc.in +++ b/lang/perl/files/config.sh-powerpc.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.22 #1 wed jul 11 12:24:09 cest 2007 ppc unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -53,7 +52,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='__gnu_linux__=1 __linux=1 __linux__=1 __unix=1 __unix__=1 system=linux system=posix system=unix' @@ -101,10 +100,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -114,6 +116,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -125,6 +128,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -134,6 +138,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -149,6 +154,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -170,7 +176,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -179,19 +189,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -264,27 +282,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -323,6 +364,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='define' @@ -345,6 +390,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -356,19 +402,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -438,6 +492,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -479,12 +534,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='undef' @@ -510,7 +568,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -524,6 +584,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='4' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -542,7 +603,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -615,7 +675,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -641,6 +703,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -648,6 +711,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -728,7 +792,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='4' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -755,6 +818,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='0' longdblsize='8' longlongsize='8' longsize='4' @@ -763,10 +827,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -983,6 +1043,7 @@ uquadtype='unsigned long long' use5005threads='undef' use64bitall='undef' use64bitint='undef' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -997,6 +1058,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1063,7 +1125,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1098,6 +1159,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1135,27 +1197,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-x86_64-mt.in b/lang/perl/files/config.sh-x86_64-mt.in index 3c6ab7b15..9ea9b0efe 100644 --- a/lang/perl/files/config.sh-x86_64-mt.in +++ b/lang/perl/files/config.sh-x86_64-mt.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.25 #2 sat apr 19 09:46:49 cest 2008 i686 unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='-D_REENTRANT -D_GNU_SOURCE %%CFLAGS%%' +ccflags='-D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='define' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='%%CRYPT%%' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='define' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='define' d_localtime_r_needs_tzset='define' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='undef' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='define' d_pthread_attr_setscope='define' d_pthread_yield='define' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='define' +d_re_comp='undef' d_readdir64_r='define' d_readdir='define' d_readdir_r='define' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='define' d_srandom_r='define' d_sresgproto='define' d_sresuproto='define' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='define' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='define' d_tzname='define' d_u32align='define' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='REENTRANT_PROTO_I_ST' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='8' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='REENTRANT_PROTO_S_TS' locincpth=' ' loclibpth=' ' +longdblkind='3' longdblsize='16' longlongsize='8' longsize='8' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long' use5005threads='undef' use64bitall='define' use64bitint='define' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1050,7 +1112,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1085,6 +1146,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1122,27 +1184,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/config.sh-x86_64.in b/lang/perl/files/config.sh-x86_64.in index f528c5412..7d12b27a0 100644 --- a/lang/perl/files/config.sh-x86_64.in +++ b/lang/perl/files/config.sh-x86_64.in @@ -13,14 +13,13 @@ # Target system : linux maia 2.6.25 #2 sat apr 19 09:46:49 cest 2008 i686 unknown unknown gnulinux Author='' -Date='$Date' +Date='' Header='' -Id='$Id' +Id='' Locker='' -Log='$Log' -Mcc='Mcc' -RCSfile='$RCSfile' -Revision='$Revision' +Log='' +RCSfile='' +Revision='' Source='' State='' _a='.a' @@ -51,7 +50,7 @@ castflags='0' cat='cat' cc='%%CC%%' cccdlflags='-fPIC' -ccflags='%%CFLAGS%%' +ccflags='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 %%CFLAGS%%' ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' ccname='gcc' ccsymbols='' @@ -99,10 +98,13 @@ d_SCNfldbl='define' d__fwalk='undef' d_access='define' d_accessx='undef' +d_acosh='define' d_aintl='undef' d_alarm='define' d_archlib='undef' d_asctime_r='undef' +d_asinh='define' +d_atanh='define' d_atolf='undef' d_atoll='define' d_attribute_format='define' @@ -112,6 +114,7 @@ d_attribute_noreturn='define' d_attribute_pure='define' d_attribute_unused='define' d_attribute_warn_unused_result='define' +d_backtrace='define' d_bcmp='define' d_bcopy='define' d_bsd='undef' @@ -123,6 +126,7 @@ d_bzero='define' d_c99_variadic_macros='define' d_casti32='undef' d_castneg='define' +d_cbrt='define' d_charvspr='undef' d_chown='define' d_chroot='define' @@ -132,6 +136,7 @@ d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' d_const='define' +d_copysign='define' d_copysignl='undef' d_cplusplus='undef' d_crypt='define' @@ -147,6 +152,7 @@ d_difftime='define' d_dir_dd_fd='undef' d_dirfd='define' d_dirnamlen='undef' +d_dladdr='define' d_dlerror='define' d_dlopen='define' d_dlsymun='undef' @@ -168,7 +174,11 @@ d_endpwent_r='undef' d_endsent='define' d_endservent_r='undef' d_eofnblk='define' +d_erf='define' +d_erfc='define' d_eunice='undef' +d_exp2='define' +d_expm1='define' d_faststdio='undef' d_fchdir='define' d_fchmod='define' @@ -177,19 +187,27 @@ d_fcntl='define' d_fcntl_can_lock='define' d_fd_macros='define' d_fd_set='define' +d_fdim='define' d_fds_bits='undef' +d_fegetround='undef' d_fgetpos='define' d_finite='define' d_finitel='undef' d_flexfnam='define' d_flock='define' d_flockproto='define' +d_fma='define' +d_fmax='define' +d_fmin='define' d_fork='define' d_fp_class='undef' +d_fp_classify='undef' +d_fp_classl='undef' d_fpathconf='define' d_fpclass='undef' -d_fpclassify='undef' +d_fpclassify='define' d_fpclassl='undef' +d_fpgetround='undef' d_fpos64_t='undef' d_frexpl='undef' d_fs_data_s='undef' @@ -262,27 +280,50 @@ d_gnulibc='undef' d_grpasswd='define' d_hasmntopt='define' d_htonl='define' +d_hypot='define' +d_ilogb='define' d_ilogbl='undef' d_inc_version_list='undef' d_index='undef' d_inetaton='define' d_int64_t='define' d_isascii='define' -d_isfinite='undef' +d_isfinite='define' +d_isfinitel='undef' d_isinf='define' +d_isinfl='define' +d_isless='undef' d_isnan='define' d_isnanl='undef' +d_isnormal='define' +d_j0='undef' +d_j0l='undef' d_killpg='define' +d_lc_monetary_2008='define' d_lchown='define' d_ldbl_dig='define' +d_ldexpl='define' +d_lgamma='define' +d_lgamma_r='define' d_libm_lib_version='define' d_link='define' +d_llrint='define' +d_llrintl='define' +d_llround='define' +d_llroundl='define' d_localtime_r='undef' d_localtime_r_needs_tzset='undef' d_locconv='define' d_lockf='define' +d_log1p='define' +d_log2='define' +d_logb='define' d_longdbl='define' d_longlong='define' +d_lrint='define' +d_lrintl='define' +d_lround='define' +d_lroundl='define' d_lseekproto='define' d_lstat='define' d_madvise='define' @@ -321,6 +362,10 @@ d_msgsnd='define' d_msync='define' d_munmap='define' d_mymalloc='undef' +d_nan='define' +d_nearbyint='define' +d_nextafter='define' +d_nexttoward='undef' d_nice='define' d_nl_langinfo='define' d_nv_preserves_uv='undef' @@ -343,6 +388,7 @@ d_pseudofork='undef' d_pthread_atfork='undef' d_pthread_attr_setscope='define' d_pthread_yield='undef' +d_ptrdiff_t='define' d_pwage='undef' d_pwchange='undef' d_pwclass='undef' @@ -354,19 +400,27 @@ d_pwquota='undef' d_qgcvt='undef' d_quad='define' d_random_r='undef' +d_re_comp='undef' d_readdir64_r='undef' d_readdir='define' d_readdir_r='undef' d_readlink='define' d_readv='define' d_recvmsg='define' +d_regcmp='undef' +d_regcomp='define' +d_remainder='define' +d_remquo='define' d_rename='define' d_rewinddir='define' +d_rint='define' d_rmdir='define' +d_round='define' d_safebcpy='undef' d_safemcpy='undef' d_sanemcmp='define' d_sbrkproto='define' +d_scalbn='define' d_scalbnl='undef' d_sched_yield='define' d_scm_rights='define' @@ -436,6 +490,7 @@ d_srand48_r='undef' d_srandom_r='undef' d_sresgproto='undef' d_sresuproto='undef' +d_stat='define' d_statblks='define' d_statfs_f_flags='undef' d_statfs_s='define' @@ -477,12 +532,15 @@ d_tcgetpgrp='define' d_tcsetpgrp='define' d_telldir='define' d_telldirproto='define' +d_tgamma='define' d_time='define' d_times='define' d_tm_tm_gmtoff='define' d_tm_tm_zone='define' d_tmpnam_r='undef' +d_trunc='define' d_truncate='define' +d_truncl='define' d_ttyname_r='undef' d_tzname='define' d_u32align='define' @@ -508,7 +566,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp='define' d_wcstombs='define' +d_wcsxfrm='define' d_wctomb='define' d_writev='define' d_xenix='undef' @@ -522,6 +582,7 @@ defvoidused='15' direntrytype='struct dirent' dlext='so' dlsrc='dl_dlopen.xs' +doublekind='3' doublesize='8' drand01='drand48()' drand48_r_proto='0' @@ -539,7 +600,6 @@ endservent_r_proto='0' eunicefix=':' exe_ext='' expr='expr' -extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib' extras='' fflushNULL='define' fflushall='undef' @@ -612,7 +672,9 @@ i_dbm='undef' i_dirent='define' i_dld='undef' i_dlfcn='define' +i_execinfo='define' i_fcntl='undef' +i_fenv='undef' i_float='define' i_fp='undef' i_fp_class='undef' @@ -638,6 +700,7 @@ i_poll='define' i_prot='undef' i_pthread='define' i_pwd='define' +i_quadmath='define' i_rpcsvcdbm='undef' i_sfio='undef' i_sgtty='undef' @@ -645,6 +708,7 @@ i_shadow='define' i_socks='undef' i_stdarg='define' i_stddef='define' +i_stdint='define' i_stdlib='define' i_string='define' i_sunmath='undef' @@ -721,7 +785,6 @@ issymlink='test -h' ivdformat='"ld"' ivsize='8' ivtype='long' -known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' ksh='' ld='%%LD%%' lddlflags='-shared %%LDFLAGS%%' @@ -748,6 +811,7 @@ lns='/bin/ln -s' localtime_r_proto='0' locincpth=' ' loclibpth=' ' +longdblkind='3' longdblsize='16' longlongsize='8' longsize='8' @@ -756,10 +820,6 @@ lpr='' ls='ls' lseeksize='8' lseektype='off_t' -mad='undef' -madlyh='' -madlyobj='' -madlysrc='' mail='' mailx='' make='make' @@ -972,6 +1032,7 @@ uquadtype='unsigned long' use5005threads='undef' use64bitall='define' use64bitint='define' +usecbacktrace='undef' usecrosscompile='define' usedl='define' usefaststdio='undef' @@ -986,6 +1047,7 @@ usenm='true' useopcode='true' useperlio='define' useposix='true' +usequadmath='undef' usereentrant='undef' userelocatableinc='undef' usesfio='false' @@ -1049,7 +1111,6 @@ d_clock='define' # New symbols for perl 5.20.0 bin_ELF='define' -bootstrap_charset='undef' charbits='8' charsize='1' d_asctime64='undef' @@ -1084,6 +1145,7 @@ dtrace='' extern_C='extern' hostosname='' i_assert='define' +i_bfd='undef' i_gdbm_ndbm='undef' i_gdbmndbm='undef' i_mallocmalloc='undef' @@ -1121,27 +1183,29 @@ libdb_needs_pthread='N' # These symbols changed from perl 5.10.0 to 5.20.0 and probably will # change again for new versions, so they're included here for # future reference -api_version='20' +api_version='22' # Always set this to the base version, not the patched one! -api_versionstring='5.20.0' -dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' -installarchlib='/usr/lib/perl5/5.20' -installprivlib='/usr/lib/perl5/5.20' -installsitearch='/usr/lib/perl5/5.20' -installsitelib='/usr/lib/perl5/5.20' -nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CGI CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/Build Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Package/Constants Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' -privlib='/usr/lib/perl5/5.20' -privlibexp='/usr/lib/perl5/5.20' -archlib='/usr/lib/perl5/5.20' -archlibexp='/usr/lib/perl5/5.20' -version='5.20.2' -version_patchlevel_string='version 20 subversion 2' -PERL_VERSION=20 -PERL_API_VERSION=20 -PERL_SUBVERSION=2 -patchlevel='20' -ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.20/CORE' -subversion='2' +api_versionstring='5.22.0' +dynamic_ext='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate XS/APItest XS/Typemap arybase attributes mro re threads threads/shared' +installarchlib='/usr/lib/perl5/5.22' +installprivlib='/usr/lib/perl5/5.22' +installsitearch='/usr/lib/perl5/5.22' +installsitelib='/usr/lib/perl5/5.22' +nonxs_ext='Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Command ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Parse/CPAN/Meta Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators Unicode/Normalize version' +privlib='/usr/lib/perl5/5.22' +privlibexp='/usr/lib/perl5/5.22' +archlib='/usr/lib/perl5/5.22' +archlibexp='/usr/lib/perl5/5.22' +version='5.22.0' +version_patchlevel_string='version 22 subversion 0' +PERL_VERSION=22 +PERL_API_VERSION=22 +PERL_SUBVERSION=0 +patchlevel='22' +ccdlflags='-fPIC -Wl,-rpath,/usr/lib/perl5/5.22/CORE' +subversion='0' +extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash Compress/Zlib Errno IO_Compress_Base IO_Compress_Zlib Unicode/Normalize' +known_extensions='B Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/DProf Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/Glob Filter/Util/Call GDBM_File Hash/Util I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File ODBM_File Opcode POSIX PerlIO/encoding PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Text/Soundex Time/HiRes Time/Piece Unicode/Normalize Win32 Win32API/File Win32CORE XS/APItest XS/Typemap attrs re threads threads/shared Hash/Util/FieldHash' # Make perl use these tools instead of the target binaries during build hostgenerate='%%HOSTGENERATE%%' diff --git a/lang/perl/files/perl-run_tests.sh b/lang/perl/files/perl-run_tests.sh index af6a39c94..288191b43 100755 --- a/lang/perl/files/perl-run_tests.sh +++ b/lang/perl/files/perl-run_tests.sh @@ -1,7 +1,7 @@ #!/bin/sh PERL_TESTSDIR="/usr/share/perl/perl-tests" -PERL_LIBDIR="/usr/lib/perl5/5.20/" +PERL_LIBDIR="/usr/lib/perl5/%%PERL_VERSION%%/" PERL_DISABLEDTESTS="%%PERL_DISABLEDTESTS%%" if [ ! -f "$PERL_TESTSDIR/__prepared" ]; then diff --git a/lang/perl/patches/100-musl-compat.patch b/lang/perl/patches/100-musl-compat.patch new file mode 100644 index 000000000..8dbad78f4 --- /dev/null +++ b/lang/perl/patches/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/pp.c ++++ b/pp.c +@@ -43,7 +43,7 @@ extern Pid_t getpid (void); + * Some BSDs and Cygwin default to POSIX math instead of IEEE. + * This switches them over to IEEE. + */ +-#if defined(LIBM_LIB_VERSION) ++#if defined(LIBM_LIB_VERSION) && (defined(__GLIBC__) || defined(__UCLIBC__)) + _LIB_VERSION_TYPE _LIB_VERSION = _IEEE_; + #endif + diff --git a/lang/perl/perlbase.mk b/lang/perl/perlbase.mk index e5dd88a84..68cd7bb7b 100644 --- a/lang/perl/perlbase.mk +++ b/lang/perl/perlbase.mk @@ -49,6 +49,7 @@ $(eval $(call BuildPackage,perlbase-archive)) define Package/perlbase-arybase $(call Package/perlbase-template) TITLE:=arybase perl module +DEPENDS+=+perlbase-xsloader endef define Package/perlbase-arybase/install @@ -76,7 +77,7 @@ $(eval $(call BuildPackage,perlbase-attribute)) define Package/perlbase-attributes $(call Package/perlbase-template) TITLE:=attributes perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-attributes/install @@ -89,7 +90,7 @@ $(eval $(call BuildPackage,perlbase-attributes)) define Package/perlbase-autodie $(call Package/perlbase-template) TITLE:=autodie perl module -DEPENDS+=+perlbase-base +perlbase-essential +perlbase-fatal +perlbase-if +DEPENDS+=+perlbase-essential endef define Package/perlbase-autodie/install @@ -143,7 +144,7 @@ $(eval $(call BuildPackage,perlbase-autouse)) define Package/perlbase-b $(call Package/perlbase-template) TITLE:=B perl module -DEPENDS+=+perlbase-config +perlbase-essential +DEPENDS+=+perlbase-config +perlbase-essential +perlbase-feature endef define Package/perlbase-b/install @@ -233,24 +234,10 @@ endef $(eval $(call BuildPackage,perlbase-bytes)) -define Package/perlbase-cgi -$(call Package/perlbase-template) -TITLE:=CGI perl module -DEPENDS+=+perlbase-base +perlbase-essential +perlbase-file +perlbase-if -endef - -define Package/perlbase-cgi/install -$(call perlmod/Install,$(1),CGI CGI.pm,) -$(call perlmod/InstallBaseTests,$(1),cpan/CGI/t) -endef - -$(eval $(call BuildPackage,perlbase-cgi)) - - define Package/perlbase-charnames $(call Package/perlbase-template) TITLE:=charnames perl module -DEPENDS+=+perlbase-bytes +perlbase-essential +perlbase-file +perlbase-re +perlbase-unicore +DEPENDS+=+perlbase-bytes +perlbase-essential +perlbase-re +perlbase-unicore endef define Package/perlbase-charnames/install @@ -304,7 +291,7 @@ $(eval $(call BuildPackage,perlbase-config)) define Package/perlbase-cpan $(call Package/perlbase-template) TITLE:=CPAN perl module -DEPENDS+=+perlbase-b +perlbase-config +perlbase-cwd +perlbase-dirhandle +perlbase-essential +perlbase-extutils +perlbase-fcntl +perlbase-file +perlbase-filehandle +perlbase-http-tiny +perlbase-list +perlbase-net +perlbase-safe +perlbase-scalar +perlbase-sys +perlbase-text +perlbase-version +DEPENDS+=+perlbase-b +perlbase-config +perlbase-cwd +perlbase-dirhandle +perlbase-essential +perlbase-extutils +perlbase-fcntl +perlbase-file +perlbase-filehandle +perlbase-http-tiny +perlbase-net +perlbase-safe +perlbase-scalar +perlbase-sys +perlbase-text endef define Package/perlbase-cpan/install @@ -359,7 +346,7 @@ $(eval $(call BuildPackage,perlbase-db)) define Package/perlbase-db-file $(call Package/perlbase-template) TITLE:=DB_File perl module -DEPENDS+=+libdb47 +perlbase-essential +DEPENDS+=+libdb47 +perlbase-essential +perlbase-tie endef define Package/perlbase-db-file/install @@ -386,7 +373,7 @@ $(eval $(call BuildPackage,perlbase-dbm-filter)) define Package/perlbase-devel $(call Package/perlbase-template) TITLE:=Devel perl module -DEPENDS+=+perlbase-essential +perlbase-file +DEPENDS+=+perlbase-essential +perlbase-file +perlbase-selfloader +perlbase-xsloader endef define Package/perlbase-devel/install @@ -414,7 +401,7 @@ $(eval $(call BuildPackage,perlbase-diagnostics)) define Package/perlbase-digest $(call Package/perlbase-template) TITLE:=Digest perl module -DEPENDS+=+perlbase-essential +perlbase-fcntl +perlbase-integer +DEPENDS+=+perlbase-dynaloader +perlbase-essential +perlbase-fcntl +perlbase-integer endef define Package/perlbase-digest/install @@ -510,6 +497,7 @@ $(eval $(call BuildPackage,perlbase-encoding)) define Package/perlbase-english $(call Package/perlbase-template) TITLE:=English perl module +DEPENDS+=+perlbase-essential endef define Package/perlbase-english/install @@ -563,7 +551,7 @@ $(eval $(call BuildPackage,perlbase-essential)) define Package/perlbase-experimental $(call Package/perlbase-template) TITLE:=experimental perl module -DEPENDS+=+perlbase-essential +perlbase-feature +DEPENDS+=+perlbase-essential +perlbase-feature +perlbase-version endef define Package/perlbase-experimental/install @@ -577,13 +565,13 @@ $(eval $(call BuildPackage,perlbase-experimental)) define Package/perlbase-extutils $(call Package/perlbase-template) TITLE:=ExtUtils perl module -DEPENDS+=+perlbase-autosplit +perlbase-config +perlbase-cwd +perlbase-dirhandle +perlbase-essential +perlbase-file +perlbase-io +perlbase-ipc +perlbase-ostype +perlbase-symbol +perlbase-text +DEPENDS+=+perlbase-autosplit +perlbase-base +perlbase-config +perlbase-cwd +perlbase-dirhandle +perlbase-encode +perlbase-essential +perlbase-file +perlbase-io +perlbase-ipc +perlbase-ostype +perlbase-symbol +perlbase-text endef define Package/perlbase-extutils/install $(call perlmod/Install,$(1),ExtUtils,ExtUtils/MakeMaker/FAQ.pod ExtUtils/MakeMaker/Tutorial.pod ExtUtils/ParseXS.pm ExtUtils/ParseXS/Utilities.pm) $(call perlmod/Install/NoStrip,$(1),ExtUtils/ParseXS.pm ExtUtils/ParseXS/Utilities.pm,) -$(call perlmod/InstallBaseTests,$(1),cpan/ExtUtils-Constant/t cpan/ExtUtils-MakeMaker/t dist/ExtUtils-CBuilder/t dist/ExtUtils-Command/t dist/ExtUtils-Install/t dist/ExtUtils-Manifest/t dist/ExtUtils-ParseXS/t) +$(call perlmod/InstallBaseTests,$(1),cpan/ExtUtils-Command/t cpan/ExtUtils-Constant/t cpan/ExtUtils-Install/t cpan/ExtUtils-MakeMaker/t cpan/ExtUtils-Manifest/t dist/ExtUtils-CBuilder/t dist/ExtUtils-ParseXS/t) endef $(eval $(call BuildPackage,perlbase-extutils)) @@ -592,7 +580,7 @@ $(eval $(call BuildPackage,perlbase-extutils)) define Package/perlbase-fatal $(call Package/perlbase-template) TITLE:=Fatal perl module -DEPENDS+=+perlbase-config +perlbase-essential +perlbase-scalar +perlbase-tie +DEPENDS+=+perlbase-autodie +perlbase-config +perlbase-essential +perlbase-scalar +perlbase-tie endef define Package/perlbase-fatal/install @@ -605,7 +593,7 @@ $(eval $(call BuildPackage,perlbase-fatal)) define Package/perlbase-fcntl $(call Package/perlbase-template) TITLE:=Fcntl perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-fcntl/install @@ -644,7 +632,7 @@ $(eval $(call BuildPackage,perlbase-fields)) define Package/perlbase-file $(call Package/perlbase-template) TITLE:=File perl module -DEPENDS+=+perlbase-class +perlbase-config +perlbase-cwd +perlbase-errno +perlbase-essential +perlbase-fcntl +perlbase-filehandle +perlbase-io +perlbase-locale +perlbase-params +perlbase-scalar +DEPENDS+=+perlbase-class +perlbase-config +perlbase-cwd +perlbase-errno +perlbase-essential +perlbase-fcntl +perlbase-filehandle +perlbase-io +perlbase-locale +perlbase-params +perlbase-scalar +perlbase-symbol +perlbase-xsloader endef define Package/perlbase-file/install @@ -673,7 +661,7 @@ $(eval $(call BuildPackage,perlbase-filecache)) define Package/perlbase-filehandle $(call Package/perlbase-template) TITLE:=FileHandle perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-io endef define Package/perlbase-filehandle/install @@ -698,7 +686,7 @@ $(eval $(call BuildPackage,perlbase-filetest)) define Package/perlbase-filter $(call Package/perlbase-template) TITLE:=Filter perl module -DEPENDS+=+perlbase-essential +perlbase-text +DEPENDS+=+perlbase-dynaloader +perlbase-essential +perlbase-text endef define Package/perlbase-filter/install @@ -725,7 +713,7 @@ $(eval $(call BuildPackage,perlbase-findbin)) define Package/perlbase-gdbm-file $(call Package/perlbase-template) TITLE:=GDBM_File perl module -DEPENDS+=+libgdbm +perlbase-essential +DEPENDS+=+libgdbm +perlbase-essential +perlbase-tie +perlbase-xsloader endef define Package/perlbase-gdbm-file/install @@ -753,7 +741,7 @@ $(eval $(call BuildPackage,perlbase-getopt)) define Package/perlbase-hash $(call Package/perlbase-template) TITLE:=Hash perl module -DEPENDS+=+perlbase-essential +perlbase-scalar +DEPENDS+=+perlbase-essential +perlbase-scalar +perlbase-xsloader endef define Package/perlbase-hash/install @@ -781,7 +769,7 @@ $(eval $(call BuildPackage,perlbase-http-tiny)) define Package/perlbase-i18n $(call Package/perlbase-template) TITLE:=I18N perl module -DEPENDS+=+perlbase-essential +perlbase-posix +DEPENDS+=+perlbase-essential +perlbase-posix +perlbase-xsloader endef define Package/perlbase-i18n/install @@ -876,7 +864,7 @@ $(eval $(call BuildPackage,perlbase-less)) define Package/perlbase-list $(call Package/perlbase-template) TITLE:=List perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-list/install @@ -903,7 +891,7 @@ $(eval $(call BuildPackage,perlbase-locale)) define Package/perlbase-math $(call Package/perlbase-template) TITLE:=Math perl module -DEPENDS+=+perlbase-config +perlbase-essential +perlbase-scalar +DEPENDS+=+perlbase-config +perlbase-essential +perlbase-scalar +perlbase-xsloader endef define Package/perlbase-math/install @@ -931,7 +919,7 @@ $(eval $(call BuildPackage,perlbase-memoize)) define Package/perlbase-mime $(call Package/perlbase-template) TITLE:=MIME perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-mime/install @@ -945,13 +933,12 @@ $(eval $(call BuildPackage,perlbase-mime)) define Package/perlbase-module $(call Package/perlbase-template) TITLE:=Module perl module -DEPENDS+=+perlbase-config +perlbase-cwd +perlbase-data +perlbase-essential +perlbase-extutils +perlbase-file +perlbase-filehandle +perlbase-if +perlbase-io +perlbase-locale +perlbase-ostype +perlbase-params +perlbase-text +perlbase-version +DEPENDS+=+perlbase-essential +perlbase-file +perlbase-filehandle +perlbase-locale +perlbase-params +perlbase-version endef define Package/perlbase-module/install -$(call perlmod/Install,$(1),Module,Module/Build Module/Build.pm Module/Build/API.pod Module/Build/Authoring.pod) -$(call perlmod/Install/NoStrip,$(1),Module/Build Module/Build.pm,Module/Build/API.pod Module/Build/Authoring.pod) -$(call perlmod/InstallBaseTests,$(1),cpan/Module-Build/lib cpan/Module-Build/t cpan/Module-Load-Conditional/t cpan/Module-Load/t cpan/Module-Loaded/t cpan/Module-Metadata/lib cpan/Module-Metadata/t dist/Module-CoreList/t) +$(call perlmod/Install,$(1),Module,) +$(call perlmod/InstallBaseTests,$(1),cpan/Module-Load-Conditional/t cpan/Module-Load/t cpan/Module-Loaded/t cpan/Module-Metadata/lib cpan/Module-Metadata/t dist/Module-CoreList/t) endef $(eval $(call BuildPackage,perlbase-module)) @@ -960,7 +947,7 @@ $(eval $(call BuildPackage,perlbase-module)) define Package/perlbase-mro $(call Package/perlbase-template) TITLE:=mro perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-mro/install @@ -1066,20 +1053,6 @@ endef $(eval $(call BuildPackage,perlbase-ostype)) -define Package/perlbase-package -$(call Package/perlbase-template) -TITLE:=Package perl module -DEPENDS+=+perlbase-essential +perlbase-if -endef - -define Package/perlbase-package/install -$(call perlmod/Install,$(1),Package,) -$(call perlmod/InstallBaseTests,$(1),cpan/Package-Constants/t) -endef - -$(eval $(call BuildPackage,perlbase-package)) - - define Package/perlbase-params $(call Package/perlbase-template) TITLE:=Params perl module @@ -1097,7 +1070,7 @@ $(eval $(call BuildPackage,perlbase-params)) define Package/perlbase-perl5db $(call Package/perlbase-template) TITLE:=perl5db perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-cwd +perlbase-essential endef define Package/perlbase-perl5db/install @@ -1142,7 +1115,7 @@ $(eval $(call BuildPackage,perlbase-pod)) define Package/perlbase-posix $(call Package/perlbase-template) TITLE:=POSIX perl module -DEPENDS+=+perlbase-essential +perlbase-fcntl +DEPENDS+=+perlbase-essential +perlbase-fcntl +perlbase-tie +perlbase-xsloader endef define Package/perlbase-posix/install @@ -1170,7 +1143,7 @@ $(eval $(call BuildPackage,perlbase-re)) define Package/perlbase-safe $(call Package/perlbase-template) TITLE:=Safe perl module -DEPENDS+=+perlbase-b +perlbase-essential +perlbase-opcode +perlbase-scalar +DEPENDS+=+perlbase-b +perlbase-essential +perlbase-opcode +perlbase-scalar +perlbase-utf8 endef define Package/perlbase-safe/install @@ -1184,7 +1157,7 @@ $(eval $(call BuildPackage,perlbase-safe)) define Package/perlbase-scalar $(call Package/perlbase-template) TITLE:=Scalar perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-list endef define Package/perlbase-scalar/install @@ -1199,7 +1172,7 @@ $(eval $(call BuildPackage,perlbase-scalar)) define Package/perlbase-sdbm-file $(call Package/perlbase-template) TITLE:=SDBM_File perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-tie +perlbase-xsloader endef define Package/perlbase-sdbm-file/install @@ -1267,7 +1240,7 @@ $(eval $(call BuildPackage,perlbase-sigtrap)) define Package/perlbase-socket $(call Package/perlbase-template) TITLE:=Socket perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-socket/install @@ -1294,7 +1267,7 @@ $(eval $(call BuildPackage,perlbase-sort)) define Package/perlbase-storable $(call Package/perlbase-template) TITLE:=Storable perl module -DEPENDS+=+perlbase-essential +DEPENDS+=+perlbase-essential +perlbase-xsloader endef define Package/perlbase-storable/install @@ -1308,6 +1281,7 @@ $(eval $(call BuildPackage,perlbase-storable)) define Package/perlbase-symbol $(call Package/perlbase-template) TITLE:=Symbol perl module +DEPENDS+=+perlbase-essential endef define Package/perlbase-symbol/install @@ -1361,7 +1335,7 @@ $(eval $(call BuildPackage,perlbase-term)) define Package/perlbase-test $(call Package/perlbase-template) TITLE:=Test perl module -DEPENDS+=+perlbase-base +perlbase-config +perlbase-essential +perlbase-symbol +perlbase-tap +perlbase-text +DEPENDS+=+perlbase-base +perlbase-config +perlbase-essential +perlbase-io +perlbase-symbol +perlbase-tap +perlbase-text endef define Package/perlbase-test/install @@ -1406,7 +1380,7 @@ $(eval $(call BuildPackage,perlbase-thread)) define Package/perlbase-threads $(call Package/perlbase-template) TITLE:=threads perl module -DEPENDS+=+perlbase-essential +perlbase-scalar +DEPENDS+=+perlbase-config +perlbase-essential +perlbase-scalar +perlbase-xsloader endef define Package/perlbase-threads/install @@ -1420,7 +1394,7 @@ $(eval $(call BuildPackage,perlbase-threads)) define Package/perlbase-tie $(call Package/perlbase-template) TITLE:=Tie perl module -DEPENDS+=+perlbase-essential +perlbase-fcntl +perlbase-posix +DEPENDS+=+perlbase-essential +perlbase-fcntl +perlbase-xsloader endef define Package/perlbase-tie/install @@ -1434,7 +1408,7 @@ $(eval $(call BuildPackage,perlbase-tie)) define Package/perlbase-time $(call Package/perlbase-template) TITLE:=Time perl module -DEPENDS+=+perlbase-class +perlbase-config +perlbase-essential +DEPENDS+=+perlbase-class +perlbase-config +perlbase-dynaloader +perlbase-essential endef define Package/perlbase-time/install @@ -1448,7 +1422,7 @@ $(eval $(call BuildPackage,perlbase-time)) define Package/perlbase-unicode $(call Package/perlbase-template) TITLE:=Unicode perl module -DEPENDS+=+perlbase-base +perlbase-charnames +perlbase-essential +perlbase-file +DEPENDS+=+perlbase-base +perlbase-charnames +perlbase-dynaloader +perlbase-essential +perlbase-file endef define Package/perlbase-unicode/install @@ -1536,4 +1510,4 @@ endef $(eval $(call BuildPackage,perlbase-xsloader)) -# Generated Mon Oct 13 10:06:15 2014 +# Generated Mon Jun 15 15:00:59 2015 diff --git a/lang/perl/perlmod.mk b/lang/perl/perlmod.mk index 4a4181d28..df5de2a72 100644 --- a/lang/perl/perlmod.mk +++ b/lang/perl/perlmod.mk @@ -1,21 +1,23 @@ # This makefile simplifies perl module builds. # +PERL_VERSION:=5.22 + # Build environment HOST_PERL_PREFIX:=$(STAGING_DIR_HOST)/usr -ifneq ($(CONFIG_USE_EGLIBC),) +ifneq ($(CONFIG_USE_GLIBC),) EXTRA_LIBS:=bsd EXTRA_LIBDIRS:=$(STAGING_DIR)/lib endif -PERL_CMD:=$(STAGING_DIR_HOST)/usr/bin/perl5.20.0 +PERL_CMD:=$(STAGING_DIR_HOST)/usr/bin/perl$(PERL_VERSION).0 -MOD_CFLAGS_PERL:=$(TARGET_CFLAGS) $(TARGET_CPPFLAGS) +MOD_CFLAGS_PERL:=-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) ifdef CONFIG_PERL_THREADS MOD_CFLAGS_PERL+= -D_REENTRANT -D_GNU_SOURCE endif # Module install prefix -PERL_SITELIB:=/usr/lib/perl5/5.20 +PERL_SITELIB:=/usr/lib/perl5/$(PERL_VERSION) PERL_TESTSDIR:=/usr/share/perl/perl-tests PERLBASE_TESTSDIR:=/usr/share/perl/perlbase-tests PERLMOD_TESTSDIR:=/usr/share/perl/perlmod-tests @@ -52,10 +54,10 @@ define perlmod/host/Install endef define perlmod/Configure - (cd $(PKG_BUILD_DIR); \ + (cd $(if $(3),$(3),$(PKG_BUILD_DIR)); \ PERL_MM_USE_DEFAULT=1 \ $(2) \ - $(PERL_CMD) Makefile.PL \ + $(PERL_CMD) -MConfig -e '$$$${tied %Config::Config}{cpprun}="$(GNU_TARGET_NAME)-cpp -E"; do "Makefile.PL"' \ $(1) \ AR=ar \ CC=$(GNU_TARGET_NAME)-gcc \ @@ -67,7 +69,7 @@ define perlmod/Configure EXE_EXT=" " \ FULL_AR=$(GNU_TARGET_NAME)-ar \ LD=$(GNU_TARGET_NAME)-gcc \ - LDDLFLAGS="-shared $(TARGET_LDFLAGS)" \ + LDDLFLAGS="-shared -rdynamic $(TARGET_LDFLAGS)" \ LDFLAGS="$(EXTRA_LIBDIRS:%=-L%) $(EXTRA_LIBS:%=-l%) " \ LIBC=" " \ LIB_EXT=.a \ @@ -102,13 +104,13 @@ define perlmod/Configure LINKTYPE=dynamic \ DESTDIR=$(PKG_INSTALL_DIR) \ ); - sed 's!^PERL_INC = .*!PERL_INC = $(STAGING_DIR)/usr/lib/perl5/5.20/CORE/!' -i $(PKG_BUILD_DIR)/Makefile + sed 's!^PERL_INC = .*!PERL_INC = $(STAGING_DIR)/usr/lib/perl5/$(PERL_VERSION)/CORE/!' -i $(PKG_BUILD_DIR)/Makefile endef define perlmod/Compile PERL5LIB=$(PERL_LIB) \ $(2) \ - $(MAKE) -C $(PKG_BUILD_DIR) \ + $(MAKE) -C $(if $(3),$(3),$(PKG_BUILD_DIR)) \ $(1) \ install endef diff --git a/lang/php5-pecl-dio/Makefile b/lang/php5-pecl-dio/Makefile new file mode 100644 index 000000000..9f7367bc1 --- /dev/null +++ b/lang/php5-pecl-dio/Makefile @@ -0,0 +1,36 @@ +# +# Copyright (C) 2012-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PECL_NAME:=dio +PECL_LONGNAME:=Direct I/O functions + +PKG_VERSION:=0.0.7 +PKG_RELEASE:=1 +PKG_MD5SUM:=a1a4df428a17dbe1ab4277b492dfa052 + +PKG_NAME:=php5-pecl-$(PECL_NAME) +PKG_SOURCE:=$(PECL_NAME)-$(PKG_VERSION).tgz +PKG_SOURCE_URL:=http://pecl.php.net/get/ + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PECL_NAME)-$(PKG_VERSION) +PKG_BUILD_PARALLEL:=1 + +PKG_MAINTAINER:=Michael Heimpold + +PKG_LICENSE:=PHPv3.01 +PKG_LICENSE_FILES:= + +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk +include ../php5/pecl.mk + +$(eval $(call PECLPackage,$(PECL_NAME),$(PECL_LONGNAME))) +$(eval $(call BuildPackage,$(PKG_NAME))) diff --git a/lang/php5-pecl-dio/patches/010-additional-baudrates.patch b/lang/php5-pecl-dio/patches/010-additional-baudrates.patch new file mode 100644 index 000000000..5032e6e14 --- /dev/null +++ b/lang/php5-pecl-dio/patches/010-additional-baudrates.patch @@ -0,0 +1,29 @@ +--- a/dio.c ++++ b/dio.c +@@ -442,6 +442,26 @@ PHP_FUNCTION(dio_tcsetattr) + + /* assign to correct values... */ + switch (Baud_Rate) { ++#ifdef B460800 ++ case 460800: ++ BAUD = B460800; ++ break; ++#endif ++#ifdef B230400 ++ case 230400: ++ BAUD = B230400; ++ break; ++#endif ++#ifdef B115200 ++ case 115200: ++ BAUD = B115200; ++ break; ++#endif ++#ifdef B57600 ++ case 57600: ++ BAUD = B57600; ++ break; ++#endif + case 38400: + BAUD = B38400; + break; diff --git a/lang/php5-pecl-libevent/Makefile b/lang/php5-pecl-libevent/Makefile new file mode 100644 index 000000000..feca20df3 --- /dev/null +++ b/lang/php5-pecl-libevent/Makefile @@ -0,0 +1,38 @@ +# +# Copyright (C) 2012-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PECL_NAME:=libevent +PECL_LONGNAME:=Libevent - event notification + +PKG_VERSION:=0.1.0 +PKG_RELEASE:=2 +PKG_MD5SUM:=e091371a9e714098a4c04a6e3daeb56a + +PKG_NAME:=php5-pecl-$(PECL_NAME) +PKG_SOURCE:=$(PECL_NAME)-$(PKG_VERSION).tgz +PKG_SOURCE_URL:=http://pecl.php.net/get/ + +PKG_MAINTAINER:=Michael Heimpold + +PKG_LICENSE:=PHPv3.01 +PKG_LICENSE_FILES:= + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PECL_NAME)-$(PKG_VERSION) +PKG_BUILD_PARALLEL:=1 + +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk +include ../php5/pecl.mk + +CONFIGURE_ARGS+= --with-libevent=shared,"$(STAGING_DIR)/usr" + +$(eval $(call PECLPackage,$(PECL_NAME),$(PECL_LONGNAME),+libevent2 +php5-mod-sockets)) +$(eval $(call BuildPackage,$(PKG_NAME))) diff --git a/lang/php5-pecl-libevent/patches/010-libevent2.patch b/lang/php5-pecl-libevent/patches/010-libevent2.patch new file mode 100644 index 000000000..961fb3608 --- /dev/null +++ b/lang/php5-pecl-libevent/patches/010-libevent2.patch @@ -0,0 +1,16 @@ +--- a/libevent.c ++++ b/libevent.c +@@ -42,10 +42,12 @@ + (rsrc = (rsrc_type) zend_fetch_resource(passed_id TSRMLS_CC, default_id, resource_type_name, NULL, 1, resource_type)) + #endif + +-#ifdef PHP_WIN32 ++//#ifdef PHP_WIN32 + /* XXX compiling with 2.x on Windows. Luckily the ext code works thanks to the + compat exports from the libevent. However it might need to be adapted to the + never version, so this ifdefs would go away. */ ++#if 1 ++/* force use of libevent2 on OpenWrt and by-pass compat event.h */ + # include + # include + # include diff --git a/lang/php5-pecl-propro/Makefile b/lang/php5-pecl-propro/Makefile new file mode 100644 index 000000000..14f39fdc6 --- /dev/null +++ b/lang/php5-pecl-propro/Makefile @@ -0,0 +1,39 @@ +# +# Copyright (C) 2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PECL_NAME:=propro +PECL_LONGNAME:=Property proxy + +PKG_VERSION:=1.0.0 +PKG_RELEASE:=1 +PKG_MD5SUM:=9c775035fd17c65f0162b7eb1b4f8564 + +PKG_NAME:=php5-pecl-propro +PKG_SOURCE:=$(PECL_NAME)-$(PKG_VERSION).tgz +PKG_SOURCE_URL:=http://pecl.php.net/get/ + +PKG_MAINTAINER:=Michael Heimpold + +PKG_LICENSE:=BSD-3-Clause +PKG_LICENSE_FILES:=LICENSE + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PECL_NAME)-$(PKG_VERSION) +PKG_BUILD_PARALLEL:=1 + +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk +include ../php5/pecl.mk + +CONFIGURE_ARGS+= \ + --enable-propro + +$(eval $(call PECLPackage,$(PECL_NAME),$(PECL_LONGNAME))) +$(eval $(call BuildPackage,$(PKG_NAME))) diff --git a/lang/php5-pecl-raphf/Makefile b/lang/php5-pecl-raphf/Makefile new file mode 100644 index 000000000..fdd23871e --- /dev/null +++ b/lang/php5-pecl-raphf/Makefile @@ -0,0 +1,39 @@ +# +# Copyright (C) 2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PECL_NAME:=raphf +PECL_LONGNAME:=Resource and persistent handles factory + +PKG_VERSION:=1.0.4 +PKG_RELEASE:=1 +PKG_MD5SUM:=e5e7e5c3954a5fd31c034c347f22c4a5 + +PKG_NAME:=php5-pecl-raphf +PKG_SOURCE:=$(PECL_NAME)-$(PKG_VERSION).tgz +PKG_SOURCE_URL:=http://pecl.php.net/get/ + +PKG_MAINTAINER:=Michael Heimpold + +PKG_LICENSE:=BSD-3-Clause +PKG_LICENSE_FILES:=LICENSE + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PECL_NAME)-$(PKG_VERSION) +PKG_BUILD_PARALLEL:=1 + +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk +include ../php5/pecl.mk + +CONFIGURE_ARGS+= \ + --enable-raphf + +$(eval $(call PECLPackage,$(PECL_NAME),$(PECL_LONGNAME))) +$(eval $(call BuildPackage,$(PKG_NAME))) diff --git a/lang/php5/Makefile b/lang/php5/Makefile index 8cbdd08ef..8772e9c1f 100644 --- a/lang/php5/Makefile +++ b/lang/php5/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=php -PKG_VERSION:=5.4.38 +PKG_VERSION:=5.6.10 PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo @@ -18,9 +18,9 @@ PKG_LICENSE_FILES:=LICENSE PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.php.net/distributions/ -PKG_MD5SUM:=2bf5007ba4bd012f9895c1b441dd4f50 +PKG_MD5SUM:=83b17e0cdc72a3a486f5e6342e76c45e -PKG_FIXUP:=libtool no-autoreconf +PKG_FIXUP:=libtool autoreconf PKG_BUILD_PARALLEL:=1 PKG_USE_MIPS16:=0 @@ -36,7 +36,7 @@ PHP5_MODULES = \ json \ ldap \ mbstring mcrypt mysql mysqli \ - openssl \ + opcache openssl \ pcntl pdo pdo-mysql pdo-pgsql pdo-sqlite pgsql \ session shmop simplexml soap sockets sqlite3 sysvmsg sysvsem sysvshm \ tokenizer \ @@ -276,6 +276,12 @@ else CONFIGURE_ARGS+= --without-mysqli endif +ifneq ($(SDK)$(CONFIG_PACKAGE_php5-mod-opcache),) + CONFIGURE_ARGS+= --enable-opcache=shared +else + CONFIGURE_ARGS+= --disable-opcache +endif + ifneq ($(SDK)$(CONFIG_PACKAGE_php5-mod-openssl),) CONFIGURE_ARGS+= \ --with-openssl=shared,"$(STAGING_DIR)/usr" \ @@ -508,7 +514,11 @@ define BuildModule $(INSTALL_DIR) $$(1)/usr/lib/php $(INSTALL_BIN) $(PKG_BUILD_DIR)/modules/$(subst -,_,$(1)).so $$(1)/usr/lib/php/ $(INSTALL_DIR) $$(1)/etc/php5 + ifeq ($(4),zend) + echo "zend_extension=/usr/lib/php/$(subst -,_,$(1)).so" > $$(1)/etc/php5/$(subst -,_,$(1)).ini + else echo "extension=$(subst -,_,$(1)).so" > $$(1)/etc/php5/$(subst -,_,$(1)).ini + endif endef $$(eval $$(call BuildPackage,php5-mod-$(1))) @@ -540,6 +550,7 @@ $(eval $(call BuildModule,mbstring,MBString)) $(eval $(call BuildModule,mcrypt,Mcrypt,+PACKAGE_php5-mod-mcrypt:libmcrypt +PACKAGE_php5-mod-mcrypt:libltdl)) $(eval $(call BuildModule,mysql,MySQL,+PACKAGE_php5-mod-mysql:libmysqlclient)) $(eval $(call BuildModule,mysqli,MySQL Improved Extension,+PACKAGE_php5-mod-mysqli:libmysqlclient)) +$(eval $(call BuildModule,opcache,OPcache,,zend)) $(eval $(call BuildModule,openssl,OpenSSL,+PACKAGE_php5-mod-openssl:libopenssl)) $(eval $(call BuildModule,pcntl,PCNTL)) $(eval $(call BuildModule,pdo,PHP Data Objects)) diff --git a/lang/php5/files/php.ini b/lang/php5/files/php.ini index 6fe2a3108..23a8bb988 100644 --- a/lang/php5/files/php.ini +++ b/lang/php5/files/php.ini @@ -309,3 +309,13 @@ ldap.max_links = -1 [mcrypt] ;mcrypt.algorithms_dir= ;mcrypt.modes_dir= + +[opcache] +;opcache.memory_consumption=8 ; 8M is the allowed minimum +;opcache.interned_strings_buffer=1 +opcache.max_accelerated_files=200 ; 200 is the allowed minimum +;opcache.revalidate_freq=60 +;opcache.fast_shutdown=1 +opcache.enable_cli=1 +opcache.enable=1 +;opcache.log_verbosity_level=4 diff --git a/lang/php5/patches/102-debian_patches_use_embedded_timezonedb.patch b/lang/php5/patches/102-debian_patches_use_embedded_timezonedb.patch index 438274aa1..4b5ff5b62 100644 --- a/lang/php5/patches/102-debian_patches_use_embedded_timezonedb.patch +++ b/lang/php5/patches/102-debian_patches_use_embedded_timezonedb.patch @@ -1,12 +1,13 @@ - Add support for use of the system timezone database, rather than embedding a copy. Discussed upstream but was not desired. History: -r9: fix another compile error without --with-system-tzdata configured +r11: adopted to php 5.6.9 +r10: make timezone case insensitive +r9: fix another compile error without --with-system-tzdata configured (Michael Heimpold) r8: fix compile error without --with-system-tzdata configured r7: improve check for valid timezone id to exclude directories -r6: fix fd leak in r5, fix country code/BC flag use in +r6: fix fd leak in r5, fix country code/BC flag use in. timezone_identifiers_list() using system db, fix use of PECL timezonedb to override system db, r5: reverts addition of "System/Localtime" fake tzname. @@ -17,10 +18,17 @@ r3: fix a crash if /usr/share/zoneinfo doesn't exist (Raphael Geissert) r2: add filesystem trawl to set up name alias index r1: initial revision ---- a/ext/date/lib/parse_tz.c -+++ b/ext/date/lib/parse_tz.c -@@ -20,6 +20,16 @@ +diff -Naur php-5.6.9.orig/ext/date/lib/parse_tz.c php-5.6.9/ext/date/lib/parse_tz.c +--- php-5.6.9.orig/ext/date/lib/parse_tz.c 2015-05-14 01:13:33.000000000 +0200 ++++ php-5.6.9/ext/date/lib/parse_tz.c 2015-05-18 22:40:55.000000000 +0200 +@@ -18,8 +18,22 @@ + + /* $Id$ */ ++#ifndef PATH_MAX ++#define PATH_MAX 4096 ++#endif ++ #include "timelib.h" +#ifdef HAVE_SYSTEM_TZDATA @@ -36,7 +44,7 @@ r1: initial revision #include #ifdef HAVE_LOCALE_H -@@ -31,7 +41,12 @@ +@@ -31,7 +45,12 @@ #else #include #endif @@ -49,25 +57,19 @@ r1: initial revision #if (defined(__APPLE__) || defined(__APPLE_CC__)) && (defined(__BIG_ENDIAN__) || defined(__LITTLE_ENDIAN__)) # if defined(__LITTLE_ENDIAN__) -@@ -51,9 +66,14 @@ - - static void read_preamble(const unsigned char **tzf, timelib_tzinfo *tz) +@@ -53,6 +72,11 @@ { -- /* skip ID */ -- *tzf += 4; -- -+ if (memcmp(tzf, "TZif", 4) == 0) { -+ *tzf += 20; -+ return; -+ } -+ -+ /* skip ID */ -+ *tzf += 4; -+ - /* read BC flag */ - tz->bc = (**tzf == '\1'); - *tzf += 1; -@@ -256,7 +276,397 @@ void timelib_dump_tzinfo(timelib_tzinfo + uint32_t version; + ++ if (memcmp(tzf, "TZif", 4) == 0) { ++ *tzf += 20; ++ return -1; ++ } ++ + /* read ID */ + version = (*tzf)[3] - '0'; + *tzf += 4; +@@ -296,7 +320,406 @@ } } @@ -81,7 +83,7 @@ r1: initial revision +#endif + +/* System timezone database pointer. */ -+static const timelib_tzdb *timezonedb_system = NULL; ++static const timelib_tzdb *timezonedb_system; + +/* Hash table entry for the cache of the zone.tab mapping table. */ +struct location_info { @@ -99,13 +101,14 @@ r1: initial revision + * prevent too many collisions. */ +#define LOCINFO_HASH_SIZE (1021) + ++/* Compute a case insensitive hash of str */ +static uint32_t tz_hash(const char *str) +{ + const unsigned char *p = (const unsigned char *)str; + uint32_t hash = 5381; + int c; + -+ while ((c = *p++) != '\0') { ++ while ((c = tolower(*p++)) != '\0') { + hash = (hash << 5) ^ hash ^ c; + } + @@ -201,10 +204,10 @@ r1: initial revision + + if (*p == '#' || *p == '\0' || *p == '\n') + continue; -+ ++ + if (!isalpha(p[0]) || !isalpha(p[1]) || p[2] != '\t') + continue; -+ ++ + /* code => AA */ + code = p; + p[2] = 0; @@ -238,7 +241,7 @@ r1: initial revision + + if (*p == '\n' || *p == '\t') + *p = '\0'; -+ ++ + hash = tz_hash(name); + i = malloc(sizeof *i); + memcpy(i->code, code, 2); @@ -274,7 +277,7 @@ r1: initial revision + } + + return NULL; -+} ++} + +/* Filter out some non-tzdata files and the posix/right databases, if + * present. */ @@ -443,6 +446,14 @@ r1: initial revision + return NULL; + } + ++ if (system_location_table) { ++ const struct location_info *li; ++ if ((li = find_zone_info(system_location_table, timezone)) != NULL) { ++ /* Use the stored name to avoid case issue */ ++ timezone = li->name; ++ } ++ } ++ + snprintf(fname, sizeof fname, ZONEINFO_PREFIX "/%s", timezone); + + fd = open(fname, O_RDONLY); @@ -466,11 +477,11 @@ r1: initial revision { int left = 0, right = tzdb->index_size - 1; #ifdef HAVE_SETLOCALE -@@ -295,36 +705,128 @@ static int seek_to_tz_position(const uns +@@ -335,21 +758,90 @@ return 0; } -+static int seek_to_tz_position(const unsigned char **tzf, char *timezone, ++static int seek_to_tz_position(const unsigned char **tzf, char *timezone, + char **map, size_t *maplen, + const timelib_tzdb *tzdb) +{ @@ -483,14 +494,14 @@ r1: initial revision + return 0; + } + -+ (*tzf) = (unsigned char *)orig ; ++ (*tzf) = (unsigned char *)orig; + *map = orig; -+ -+ return 1; ++ ++ return 1; + } -+ else ++ else +#endif -+ { ++ { + return inmem_seek_to_tz_position(tzf, timezone, tzdb); + } +} @@ -505,7 +516,7 @@ r1: initial revision + tmp->data = NULL; + create_zone_index(tmp); + system_location_table = create_location_table(); -+ fake_data_segment(tmp, system_location_table); ++ fake_data_segment(tmp, system_location_table); + timezonedb_system = tmp; + } + @@ -533,38 +544,49 @@ r1: initial revision - return (seek_to_tz_position(&tzf, timezone, tzdb)); + +#ifdef HAVE_SYSTEM_TZDATA -+ if (tzdb == timezonedb_system) { -+ char fname[PATH_MAX]; -+ struct stat st; -+ -+ if (timezone[0] == '\0' || strstr(timezone, "..") != NULL) { -+ return 0; -+ } -+ -+ snprintf(fname, sizeof fname, ZONEINFO_PREFIX "/%s", timezone); -+ -+ return stat(fname, &st) == 0 && is_valid_tzfile(&st); -+ } ++ if (tzdb == timezonedb_system) { ++ char fname[PATH_MAX]; ++ struct stat st; ++ ++ if (timezone[0] == '\0' || strstr(timezone, "..") != NULL) { ++ return 0; ++ } ++ ++ if (system_location_table) { ++ if (find_zone_info(system_location_table, timezone) != NULL) { ++ /* found in cache */ ++ return 1; ++ } ++ } ++ ++ snprintf(fname, sizeof fname, ZONEINFO_PREFIX "/%s", timezone); ++ ++ return stat(fname, &st) == 0 && is_valid_tzfile(&st); ++ } +#endif + + return (inmem_seek_to_tz_position(&tzf, timezone, tzdb)); } + static void skip_64bit_preamble(const unsigned char **tzf, timelib_tzinfo *tz) +@@ -374,10 +866,12 @@ timelib_tzinfo *timelib_parse_tzfile(char *timezone, const timelib_tzdb *tzdb) { const unsigned char *tzf; + char *memmap = NULL; + size_t maplen; timelib_tzinfo *tmp; + int version; - if (seek_to_tz_position(&tzf, timezone, tzdb)) { + if (seek_to_tz_position(&tzf, timezone, &memmap, &maplen, tzdb)) { tmp = timelib_tzinfo_ctor(timezone); - read_preamble(&tzf, tmp); - read_header(&tzf, tmp); - read_transistions(&tzf, tmp); - read_types(&tzf, tmp); + version = read_preamble(&tzf, tmp); +@@ -391,7 +885,34 @@ + skip_64bit_types(&tzf, tmp); + skip_posix_string(&tzf, tmp); + } - read_location(&tzf, tmp); + +#ifdef HAVE_SYSTEM_TZDATA @@ -576,12 +598,11 @@ r1: initial revision + + if ((li = find_zone_info(system_location_table, timezone)) != NULL) { + tmp->location.comments = strdup(li->comment); -+ strncpy(tmp->location.country_code, li->code, 2); ++ strncpy(tmp->location.country_code, li->code, 2); + tmp->location.longitude = li->longitude; + tmp->location.latitude = li->latitude; + tmp->bc = 1; -+ } -+ else { ++ } else { + strcpy(tmp->location.country_code, "??"); + tmp->bc = 0; + tmp->location.comments = strdup(""); @@ -598,9 +619,10 @@ r1: initial revision } else { tmp = NULL; } ---- a/ext/date/lib/timelib.m4 -+++ b/ext/date/lib/timelib.m4 -@@ -78,3 +78,17 @@ stdlib.h +diff -Naur php-5.6.9.orig/ext/date/lib/timelib.m4 php-5.6.9/ext/date/lib/timelib.m4 +--- php-5.6.9.orig/ext/date/lib/timelib.m4 2015-05-14 01:13:33.000000000 +0200 ++++ php-5.6.9/ext/date/lib/timelib.m4 2015-05-18 22:31:36.000000000 +0200 +@@ -78,3 +78,17 @@ dnl Check for strtoll, atoll AC_CHECK_FUNCS(strtoll atoll strftime) diff --git a/lang/php5/patches/200-ext-opcache-fix-detection-of-shm-mmap.patch b/lang/php5/patches/200-ext-opcache-fix-detection-of-shm-mmap.patch new file mode 100644 index 000000000..d2a1e91af --- /dev/null +++ b/lang/php5/patches/200-ext-opcache-fix-detection-of-shm-mmap.patch @@ -0,0 +1,159 @@ +From dc8bb6a53bfdfe42d9ae81d4e78c6155ad4bfd6e Mon Sep 17 00:00:00 2001 +From: Michael Heimpold +Date: Sun, 17 May 2015 16:50:50 +0200 +Subject: [PATCH] ext/opcache: fix detection of shm/mmap + +The detection of sysvipc and mmap doesn't work well when cross-compiling, +so I decided to only check for the availability of the functions involved. +This is not a clean solution, but works for now(tm) :-) + +It should be discussed with upstream to find a better solution. + +This solves the issue reported at +https://github.com/openwrt/packages/issues/1010 +and makes opcache usable on OpenWrt. + +Signed-off-by: Michael Heimpold +--- + ext/opcache/config.m4 | 122 ++----------------------------------------------- + 1 file changed, 4 insertions(+), 118 deletions(-) + +diff --git a/ext/opcache/config.m4 b/ext/opcache/config.m4 +index b7e4835..7b6c0aa 100644 +--- a/ext/opcache/config.m4 ++++ b/ext/opcache/config.m4 +@@ -11,127 +11,13 @@ if test "$PHP_OPCACHE" != "no"; then + AC_DEFINE(HAVE_MPROTECT, 1, [Define if you have mprotect() function]) + ]) + +- AC_MSG_CHECKING(for sysvipc shared memory support) +- AC_TRY_RUN([ +-#include +-#include +-#include +-#include +-#include +-#include +- +-int main() { +- pid_t pid; +- int status; +- int ipc_id; +- char *shm; +- struct shmid_ds shmbuf; +- +- ipc_id = shmget(IPC_PRIVATE, 4096, (IPC_CREAT | SHM_R | SHM_W)); +- if (ipc_id == -1) { +- return 1; +- } +- +- shm = shmat(ipc_id, NULL, 0); +- if (shm == (void *)-1) { +- shmctl(ipc_id, IPC_RMID, NULL); +- return 2; +- } +- +- if (shmctl(ipc_id, IPC_STAT, &shmbuf) != 0) { +- shmdt(shm); +- shmctl(ipc_id, IPC_RMID, NULL); +- return 3; +- } +- +- shmbuf.shm_perm.uid = getuid(); +- shmbuf.shm_perm.gid = getgid(); +- shmbuf.shm_perm.mode = 0600; +- +- if (shmctl(ipc_id, IPC_SET, &shmbuf) != 0) { +- shmdt(shm); +- shmctl(ipc_id, IPC_RMID, NULL); +- return 4; +- } +- +- shmctl(ipc_id, IPC_RMID, NULL); +- +- strcpy(shm, "hello"); +- +- pid = fork(); +- if (pid < 0) { +- return 5; +- } else if (pid == 0) { +- strcpy(shm, "bye"); +- return 6; +- } +- if (wait(&status) != pid) { +- return 7; +- } +- if (!WIFEXITED(status) || WEXITSTATUS(status) != 6) { +- return 8; +- } +- if (strcmp(shm, "bye") != 0) { +- return 9; +- } +- return 0; +-} +-],dnl ++ AC_CHECK_FUNC(shmget,[ + AC_DEFINE(HAVE_SHM_IPC, 1, [Define if you have SysV IPC SHM support]) +- msg=yes,msg=no,msg=no) +- AC_MSG_RESULT([$msg]) +- +- AC_MSG_CHECKING(for mmap() using MAP_ANON shared memory support) +- AC_TRY_RUN([ +-#include +-#include +-#include +-#include +-#include +- +-#ifndef MAP_ANON +-# ifdef MAP_ANONYMOUS +-# define MAP_ANON MAP_ANONYMOUS +-# endif +-#endif +-#ifndef MAP_FAILED +-# define MAP_FAILED ((void*)-1) +-#endif +- +-int main() { +- pid_t pid; +- int status; +- char *shm; +- +- shm = mmap(NULL, 4096, PROT_READ | PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0); +- if (shm == MAP_FAILED) { +- return 1; +- } +- +- strcpy(shm, "hello"); ++ ]) + +- pid = fork(); +- if (pid < 0) { +- return 5; +- } else if (pid == 0) { +- strcpy(shm, "bye"); +- return 6; +- } +- if (wait(&status) != pid) { +- return 7; +- } +- if (!WIFEXITED(status) || WEXITSTATUS(status) != 6) { +- return 8; +- } +- if (strcmp(shm, "bye") != 0) { +- return 9; +- } +- return 0; +-} +-],dnl ++ AC_CHECK_FUNC(mmap,[ + AC_DEFINE(HAVE_SHM_MMAP_ANON, 1, [Define if you have mmap(MAP_ANON) SHM support]) +- msg=yes,msg=no,msg=no) +- AC_MSG_RESULT([$msg]) ++ ]) + + AC_MSG_CHECKING(for mmap() using /dev/zero shared memory support) + AC_TRY_RUN([ +-- +1.7.10.4 + diff --git a/lang/php5/patches/950-Fix-dl-cross-compiling-issue.patch b/lang/php5/patches/950-Fix-dl-cross-compiling-issue.patch index 216a5180a..22122ec82 100644 --- a/lang/php5/patches/950-Fix-dl-cross-compiling-issue.patch +++ b/lang/php5/patches/950-Fix-dl-cross-compiling-issue.patch @@ -12,3 +12,48 @@ if test "$ac_cv_func_dlopen" = "yes"; then AC_DEFINE(HAVE_LIBDL, 1, [ ]) fi +--- a/ext/fileinfo/config.m4 ++++ b/ext/fileinfo/config.m4 +@@ -46,6 +46,10 @@ int main(void) + AC_MSG_RESULT(no) + AC_MSG_NOTICE(using libmagic strcasestr implementation) + libmagic_sources="$libmagic_sources libmagic/strcasestr.c" ++ ],[ ++ dnl cross-compiling; assume not present ++ AC_MSG_NOTICE(using libmagic strcasestr implementation) ++ libmagic_sources="$libmagic_sources libmagic/strcasestr.c" + ]) + + PHP_NEW_EXTENSION(fileinfo, fileinfo.c $libmagic_sources, $ext_shared,,-I@ext_srcdir@/libmagic) +--- a/ext/opcache/config.m4 ++++ b/ext/opcache/config.m4 +@@ -227,7 +227,14 @@ AC_TRY_RUN([ + flock_type=linux + AC_DEFINE([HAVE_FLOCK_LINUX], [], [Struct flock is Linux-type]) + AC_MSG_RESULT("yes") +-], AC_MSG_RESULT("no") ) ++], [ ++ AC_MSG_RESULT("no") ++], [ ++ dnl cross-compiling; assume Linux ++ flock_type=linux ++ AC_DEFINE([HAVE_FLOCK_LINUX], [], [Struct flock is Linux-type]) ++ AC_MSG_RESULT("yes") ++]) + + AC_MSG_CHECKING("whether flock struct is BSD ordered") + AC_TRY_RUN([ +@@ -243,7 +250,12 @@ AC_TRY_RUN([ + flock_type=bsd + AC_DEFINE([HAVE_FLOCK_BSD], [], [Struct flock is BSD-type]) + AC_MSG_RESULT("yes") +-], AC_MSG_RESULT("no") ) ++], [ ++ AC_MSG_RESULT("no") ++], [ ++ dnl cross-compiling; assume Linux ++ AC_MSG_RESULT("no") ++]) + + if test "$flock_type" == "unknown"; then + AC_MSG_ERROR([Don't know how to define struct flock on this system[,] set --enable-opcache=no]) diff --git a/lang/php5/pecl.mk b/lang/php5/pecl.mk index e1b981963..ee2a5ce77 100644 --- a/lang/php5/pecl.mk +++ b/lang/php5/pecl.mk @@ -1,5 +1,5 @@ # -# Copyright (C) 2011-2014 OpenWrt.org +# Copyright (C) 2011-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -10,13 +10,12 @@ define Package/php5-pecl/Default SECTION:=lang CATEGORY:=Languages URL:=http://pecl.php.net/ - MAINTAINER:=Michael Heimpold DEPENDS:=php5 endef -define Build/Configure +define Build/Prepare + $(Build/Prepare/Default) ( cd $(PKG_BUILD_DIR); $(STAGING_DIR_HOST)/usr/bin/phpize ) - $(Build/Configure/Default) endef CONFIGURE_ARGS+= \ diff --git a/lang/python-crcmod/Makefile b/lang/python-crcmod/Makefile new file mode 100644 index 000000000..03b9d6af6 --- /dev/null +++ b/lang/python-crcmod/Makefile @@ -0,0 +1,50 @@ +# +# Copyright (C) 2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=python-crcmod +PKG_VERSION:=1.7 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Micke Prag +PKG_LICENSE:=MIT + +PKG_SOURCE:=crcmod-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://pypi.python.org/packages/source/c/crcmod/ +PKG_MD5SUM:=2d5b92117d958dcead94f9e17f54cd32 + +PKG_BUILD_DIR:=$(BUILD_DIR)/crcmod-$(PKG_VERSION) +PKG_BUILD_DEPENDS:=python + +include $(INCLUDE_DIR)/package.mk +$(call include_mk, python-package.mk) + +define Package/python-crcmod + SUBMENU:=Python + SECTION:=lang + CATEGORY:=Languages + TITLE:=python-crcmod + URL:=http://crcmod.sourceforge.net/ + DEPENDS:=+python-light +endef + +define Package/python-crcmod/description + The software in this package is a Python module for generating objects that compute the Cyclic Redundancy Check (CRC). There is no attempt in this package to explain how the CRC works. There are a number of resources on the web that give a good explanation of the algorithms. Just do a Google search for "crc calculation" and browse till you find what you need. Another resource can be found in chapter 20 of the book "Numerical Recipes in C" by Press et. al. +endef + +define Build/Compile + $(call Build/Compile/PyMod,,install --prefix="$(PKG_INSTALL_DIR)/usr") +endef + +define Package/python-crcmod/install + $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR) + $(CP) \ + $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \ + $(1)$(PYTHON_PKG_DIR) +endef + +$(eval $(call BuildPackage,python-crcmod)) diff --git a/lang/python-yaml/Makefile b/lang/python-yaml/Makefile new file mode 100644 index 000000000..3af2f0eeb --- /dev/null +++ b/lang/python-yaml/Makefile @@ -0,0 +1,43 @@ +# +# Copyright (C) 2008-2015 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:=PyYAML +PKG_VERSION:=3.11 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://pyyaml.org/download/pyyaml/ +PKG_MD5SUM:=f50e08ef0fe55178479d3a618efe21db + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Nicolas Thill + +PKG_BUILD_DEPENDS:=python + +include $(INCLUDE_DIR)/package.mk +$(call include_mk, python-package.mk) + +define Package/python-yaml + SUBMENU:=Python + SECTION:=lang + CATEGORY:=Languages + TITLE:=YAML parser and emitter for Python + URL:=http://pyyaml.org/wiki/PyYAML + DEPENDS:=+python +libyaml +endef + +define Build/Compile + $(call Build/Compile/PyMod,,\ + --with-libyaml install --prefix="$(PKG_INSTALL_DIR)/usr" \ + ) +endef + +$(eval $(call PyPackage,python-yaml)) +$(eval $(call BuildPackage,python-yaml)) diff --git a/lang/python/Makefile b/lang/python/Makefile index bb4252292..133bab0d9 100644 --- a/lang/python/Makefile +++ b/lang/python/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -12,11 +12,11 @@ include ./files/python-package.mk PKG_NAME:=python PKG_VERSION:=$(PYTHON_VERSION).$(PYTHON_VERSION_MICRO) -PKG_RELEASE:=4 +PKG_RELEASE:=5 PKG_SOURCE:=Python-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://www.python.org/ftp/python/$(PKG_VERSION) -PKG_MD5SUM:=38d530f7efc373d64a8fb1637e3baaa7 +PKG_MD5SUM:=c685ef0b8e9f27b5e3db5db12b268ac6 PKG_LICENSE:=PSF PKG_LICENSE_FILES:=LICENSE Modules/_ctypes/libffi_msvc/LICENSE Modules/_ctypes/darwin/LICENSE Modules/_ctypes/libffi/LICENSE Modules/_ctypes/libffi_osx/LICENSE Tools/pybench/LICENSE @@ -54,7 +54,7 @@ endef define Package/python-base $(call Package/python/Default) TITLE:=Python $(PYTHON_VERSION) interpreter - DEPENDS:=+libpthread +zlib +libffi +libopenssl + DEPENDS:=+libpthread +zlib endef define Package/python-base/description @@ -62,13 +62,44 @@ define Package/python-base/description for the interpreter to start. endef +define Package/python-light +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) light installation + DEPENDS:=+python-base +libffi +libbz2 +endef + +define Package/python-light/description + This package is essentially the python-base package plus + a few of the rarely used (and big) libraries stripped out + into separate packages. +endef + +# Define newline here, since it's not defined in OpenWRT +define newline + + +endef + +PYTHON_LIB_FILES_DEL:= +PYTHON_PACKAGES:= +define PyBasePackage + PYTHON_PACKAGES+=$(1) + PYTHON_LIB_FILES_DEL+=$(2) + define PyPackage/$(1)/filespec + $(subst $(space),$(newline),$(foreach lib_file,$(2),+|$(lib_file))) + endef +endef + +include ./files/python-package-*.mk + define Package/python $(call Package/python/Default) - DEPENDS:=+python-base +libncursesw +libbz2 +libgdbm +libsqlite3 +libexpat +libdb47 + DEPENDS:=+python-light $(foreach package,$(PYTHON_PACKAGES),+$(package)) endef define Package/python/description This package contains the (almost) full Python install. + It's python-light + all other packages. endef MAKE_FLAGS+=\ @@ -124,31 +155,36 @@ define Build/InstallDev $(1)/usr/lib/python$(PYTHON_VERSION)/ endef +PYTHON_BASE_LIB_FILES:= \ + /usr/lib/python$(PYTHON_VERSION)/_abcoll.py \ + /usr/lib/python$(PYTHON_VERSION)/_sysconfigdata.py \ + /usr/lib/python$(PYTHON_VERSION)/_weakrefset.py \ + /usr/lib/python$(PYTHON_VERSION)/abc.py \ + /usr/lib/python$(PYTHON_VERSION)/copy_reg.py \ + /usr/lib/python$(PYTHON_VERSION)/genericpath.py \ + /usr/lib/python$(PYTHON_VERSION)/linecache.py \ + /usr/lib/python$(PYTHON_VERSION)/posixpath.py \ + /usr/lib/python$(PYTHON_VERSION)/os.py \ + /usr/lib/python$(PYTHON_VERSION)/re.py \ + /usr/lib/python$(PYTHON_VERSION)/site.py \ + /usr/lib/python$(PYTHON_VERSION)/sre_compile.py \ + /usr/lib/python$(PYTHON_VERSION)/sre_constants.py \ + /usr/lib/python$(PYTHON_VERSION)/sre_parse.py \ + /usr/lib/python$(PYTHON_VERSION)/sysconfig.py \ + /usr/lib/python$(PYTHON_VERSION)/stat.py \ + /usr/lib/python$(PYTHON_VERSION)/traceback.py \ + /usr/lib/python$(PYTHON_VERSION)/types.py \ + /usr/lib/python$(PYTHON_VERSION)/UserDict.py \ + /usr/lib/python$(PYTHON_VERSION)/warnings.py + +PYTHON_LIB_FILES_DEL+=$(PYTHON_BASE_LIB_FILES) + define PyPackage/python-base/filespec +|/usr/bin/python$(PYTHON_VERSION) -+|/usr/lib/python$(PYTHON_VERSION)/_abcoll.py -+|/usr/lib/python$(PYTHON_VERSION)/_sysconfigdata.py -+|/usr/lib/python$(PYTHON_VERSION)/_weakrefset.py -+|/usr/lib/python$(PYTHON_VERSION)/abc.py -+|/usr/lib/python$(PYTHON_VERSION)/copy_reg.py -+|/usr/lib/python$(PYTHON_VERSION)/genericpath.py -+|/usr/lib/python$(PYTHON_VERSION)/linecache.py -+|/usr/lib/python$(PYTHON_VERSION)/posixpath.py -+|/usr/lib/python$(PYTHON_VERSION)/os.py -+|/usr/lib/python$(PYTHON_VERSION)/re.py -+|/usr/lib/python$(PYTHON_VERSION)/site.py -+|/usr/lib/python$(PYTHON_VERSION)/sre_compile.py -+|/usr/lib/python$(PYTHON_VERSION)/sre_constants.py -+|/usr/lib/python$(PYTHON_VERSION)/sre_parse.py -+|/usr/lib/python$(PYTHON_VERSION)/sysconfig.py -+|/usr/lib/python$(PYTHON_VERSION)/stat.py -+|/usr/lib/python$(PYTHON_VERSION)/traceback.py -+|/usr/lib/python$(PYTHON_VERSION)/types.py -+|/usr/lib/python$(PYTHON_VERSION)/UserDict.py -+|/usr/lib/python$(PYTHON_VERSION)/warnings.py +$(subst $(space),$(newline),$(foreach lib_file,$(PYTHON_BASE_LIB_FILES),+|$(lib_file))) endef -define PyPackage/python/filespec +define PyPackage/python-light/filespec +|/usr/lib/python$(PYTHON_VERSION) -|/usr/lib/python$(PYTHON_VERSION)/config -|/usr/lib/python$(PYTHON_VERSION)/distutils/cygwinccompiler.py @@ -164,26 +200,7 @@ define PyPackage/python/filespec -|/usr/lib/python$(PYTHON_VERSION)/*/test -|/usr/lib/python$(PYTHON_VERSION)/*/tests -|/usr/lib/python$(PYTHON_VERSION)/lib-dynload/readline.so --|/usr/lib/python$(PYTHON_VERSION)/_abcoll.py --|/usr/lib/python$(PYTHON_VERSION)/_sysconfigdata.py --|/usr/lib/python$(PYTHON_VERSION)/_weakrefset.py --|/usr/lib/python$(PYTHON_VERSION)/abc.py --|/usr/lib/python$(PYTHON_VERSION)/copy_reg.py --|/usr/lib/python$(PYTHON_VERSION)/genericpath.py --|/usr/lib/python$(PYTHON_VERSION)/linecache.py --|/usr/lib/python$(PYTHON_VERSION)/posixpath.py --|/usr/lib/python$(PYTHON_VERSION)/os.py --|/usr/lib/python$(PYTHON_VERSION)/re.py --|/usr/lib/python$(PYTHON_VERSION)/site.py --|/usr/lib/python$(PYTHON_VERSION)/sre_compile.py --|/usr/lib/python$(PYTHON_VERSION)/sre_constants.py --|/usr/lib/python$(PYTHON_VERSION)/sre_parse.py --|/usr/lib/python$(PYTHON_VERSION)/sysconfig.py --|/usr/lib/python$(PYTHON_VERSION)/stat.py --|/usr/lib/python$(PYTHON_VERSION)/traceback.py --|/usr/lib/python$(PYTHON_VERSION)/types.py --|/usr/lib/python$(PYTHON_VERSION)/UserDict.py --|/usr/lib/python$(PYTHON_VERSION)/warnings.py +$(subst $(space),$(newline),$(foreach lib_file,$(PYTHON_LIB_FILES_DEL),-|$(lib_file))) endef define PyPackage/python-base/install @@ -192,6 +209,10 @@ define PyPackage/python-base/install $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpython$(PYTHON_VERSION).so* $(1)/usr/lib/ endef +define PyPackage/python/filespec +-|$(PYTHON_PKG_DIR) +endef + HOST_CFLAGS+= \ -I/usr/include/ncursesw \ -I/usr/include/ncurses @@ -213,8 +234,15 @@ endef $(eval $(call HostBuild)) +$(foreach package, $(PYTHON_PACKAGES), \ + $(eval $(call PyPackage,$(package))) \ + $(eval $(call BuildPackage,$(package))) \ +) + $(eval $(call PyPackage,python-base)) +$(eval $(call PyPackage,python-light)) $(eval $(call PyPackage,python)) $(eval $(call BuildPackage,python-base)) +$(eval $(call BuildPackage,python-light)) $(eval $(call BuildPackage,python)) diff --git a/lang/python/files/python-package-codecs.mk b/lang/python/files/python-package-codecs.mk new file mode 100644 index 000000000..d6e183500 --- /dev/null +++ b/lang/python/files/python-package-codecs.mk @@ -0,0 +1,23 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-codecs +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) codecs + unicode support + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-codecs, \ + /usr/lib/python$(PYTHON_VERSION)/encodings \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_cn.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_hk.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_iso2022.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_jp.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_kr.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_codecs_tw.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/unicodedata.so \ +)) diff --git a/lang/python/files/python-package-compiler.mk b/lang/python/files/python-package-compiler.mk new file mode 100644 index 000000000..fbe8bf2e6 --- /dev/null +++ b/lang/python/files/python-package-compiler.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-compiler +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) compiler module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-compiler, \ + /usr/lib/python$(PYTHON_VERSION)/compiler \ +)) diff --git a/lang/python/files/python-package-ctypes.mk b/lang/python/files/python-package-ctypes.mk new file mode 100644 index 000000000..66b303310 --- /dev/null +++ b/lang/python/files/python-package-ctypes.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-ctypes +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) ctypes module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-ctypes, \ + /usr/lib/python$(PYTHON_VERSION)/ctypes \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_ctypes.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_ctypes_test.so \ +)) diff --git a/lang/python/files/python-package-db.mk b/lang/python/files/python-package-db.mk new file mode 100644 index 000000000..26f35d882 --- /dev/null +++ b/lang/python/files/python-package-db.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-db +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) db module + DEPENDS:=+python-light +libdb47 +endef + +$(eval $(call PyBasePackage,python-db, \ + /usr/lib/python$(PYTHON_VERSION)/bsddb \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_bsddb.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/dbm.so \ +)) diff --git a/lang/python/files/python-package-decimal.mk b/lang/python/files/python-package-decimal.mk new file mode 100644 index 000000000..33e3a21d2 --- /dev/null +++ b/lang/python/files/python-package-decimal.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-decimal +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) decimal module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-decimal, \ + /usr/lib/python$(PYTHON_VERSION)/decimal.py \ +)) diff --git a/lang/python/files/python-package-distutils.mk b/lang/python/files/python-package-distutils.mk new file mode 100644 index 000000000..f5119fac3 --- /dev/null +++ b/lang/python/files/python-package-distutils.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-distutils +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) distutils + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-distutils, \ + /usr/lib/python$(PYTHON_VERSION)/distutils \ +)) diff --git a/lang/python/files/python-package-email.mk b/lang/python/files/python-package-email.mk new file mode 100644 index 000000000..51fa8d12a --- /dev/null +++ b/lang/python/files/python-package-email.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-email +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) email module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-email, \ + /usr/lib/python$(PYTHON_VERSION)/email \ +)) diff --git a/lang/python/files/python-package-gdbm.mk b/lang/python/files/python-package-gdbm.mk new file mode 100644 index 000000000..8e0b16f9c --- /dev/null +++ b/lang/python/files/python-package-gdbm.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-gdbm +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) gdbm module + DEPENDS:=+python-light +libgdbm +endef + +$(eval $(call PyBasePackage,python-gdbm, \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/gdbm.so \ +)) diff --git a/lang/python/files/python-package-logging.mk b/lang/python/files/python-package-logging.mk new file mode 100644 index 000000000..f45de35dc --- /dev/null +++ b/lang/python/files/python-package-logging.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-logging +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) logging module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-logging, \ + /usr/lib/python$(PYTHON_VERSION)/logging \ +)) diff --git a/lang/python/files/python-package-multiprocessing.mk b/lang/python/files/python-package-multiprocessing.mk new file mode 100644 index 000000000..2a9f5b185 --- /dev/null +++ b/lang/python/files/python-package-multiprocessing.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-multiprocessing +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) multiprocessing + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-multiprocessing, \ + /usr/lib/python$(PYTHON_VERSION)/multiprocessing \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_multiprocessing.so \ +)) diff --git a/lang/python/files/python-package-ncurses.mk b/lang/python/files/python-package-ncurses.mk new file mode 100644 index 000000000..bab941559 --- /dev/null +++ b/lang/python/files/python-package-ncurses.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-ncurses +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) ncurses module + DEPENDS:=+python-light +libncurses +endef + +$(eval $(call PyBasePackage,python-ncurses, \ + /usr/lib/python$(PYTHON_VERSION)/curses \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_curses.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_curses_panel.so \ +)) diff --git a/lang/python/files/python-package-openssl.mk b/lang/python/files/python-package-openssl.mk new file mode 100644 index 000000000..4d897eb81 --- /dev/null +++ b/lang/python/files/python-package-openssl.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-openssl +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) SSL module + DEPENDS:=+python-light +libopenssl +endef + +$(eval $(call PyBasePackage,python-openssl, \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_hashlib.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_ssl.so \ +)) diff --git a/lang/python/files/python-package-pydoc.mk b/lang/python/files/python-package-pydoc.mk new file mode 100644 index 000000000..ca27f9b36 --- /dev/null +++ b/lang/python/files/python-package-pydoc.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-pydoc +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) pydoc module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-pydoc, \ + /usr/lib/python$(PYTHON_VERSION)/doctest.py \ + /usr/lib/python$(PYTHON_VERSION)/pydoc.py \ + /usr/lib/python$(PYTHON_VERSION)/pydoc_data \ +)) diff --git a/lang/python/files/python-package-sqlite3.mk b/lang/python/files/python-package-sqlite3.mk new file mode 100644 index 000000000..c5abb122e --- /dev/null +++ b/lang/python/files/python-package-sqlite3.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-sqlite3 +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) sqlite3 module + DEPENDS:=+python-light +libsqlite3 +endef + +$(eval $(call PyBasePackage,python-sqlite3, \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_sqlite3.so \ + /usr/lib/python$(PYTHON_VERSION)/sqlite3 \ +)) diff --git a/lang/python/files/python-package-unittest.mk b/lang/python/files/python-package-unittest.mk new file mode 100644 index 000000000..6e1ab552d --- /dev/null +++ b/lang/python/files/python-package-unittest.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-unittest +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) unittest module + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-unittest, \ + /usr/lib/python$(PYTHON_VERSION)/unittest \ +)) diff --git a/lang/python/files/python-package-xml.mk b/lang/python/files/python-package-xml.mk new file mode 100644 index 000000000..69074ccb4 --- /dev/null +++ b/lang/python/files/python-package-xml.mk @@ -0,0 +1,20 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python-xml +$(call Package/python/Default) + TITLE:=Python $(PYTHON_VERSION) xml libs + DEPENDS:=+python-light +endef + +$(eval $(call PyBasePackage,python-xml, \ + /usr/lib/python$(PYTHON_VERSION)/xml \ + /usr/lib/python$(PYTHON_VERSION)/xmllib.py \ + /usr/lib/python$(PYTHON_VERSION)/xmlrpclib.py \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/_elementtree.so \ + /usr/lib/python$(PYTHON_VERSION)/lib-dynload/pyexpat.so \ +)) diff --git a/lang/python/files/python-package.mk b/lang/python/files/python-package.mk index c8cbcda57..5ab35195d 100644 --- a/lang/python/files/python-package.mk +++ b/lang/python/files/python-package.mk @@ -1,12 +1,12 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. # PYTHON_VERSION:=2.7 -PYTHON_VERSION_MICRO:=9 +PYTHON_VERSION_MICRO:=10 PYTHON_DIR:=$(STAGING_DIR)/usr PYTHON_BIN_DIR:=$(PYTHON_DIR)/bin @@ -25,11 +25,21 @@ define HostPython ( export PYTHONPATH="$(PYTHONPATH)"; \ export PYTHONOPTIMIZE=""; \ export PYTHONDONTWRITEBYTECODE=1; \ + export _python_sysroot="$(STAGING_DIR)"; \ + export _python_prefix="/usr"; \ + export _python_exec_prefix="/usr"; \ $(1) \ $(HOST_PYTHON_BIN) $(2); \ ) endef +# These configure args are needed in detection of path to Python header files +# using autotools. +CONFIGURE_ARGS += \ + _python_sysroot="$(STAGING_DIR)" \ + _python_prefix="/usr" \ + _python_exec_prefix="/usr" + PKG_USE_MIPS16:=0 # This is required in addition to PKG_USE_MIPS16:=0 because otherwise MIPS16 # flags are inherited from the Python base package (via sysconfig module) diff --git a/lang/python/patches/110-enable-zlib.patch b/lang/python/patches/001-enable-zlib.patch similarity index 100% rename from lang/python/patches/110-enable-zlib.patch rename to lang/python/patches/001-enable-zlib.patch diff --git a/lang/python/patches/120-do-not-add-include-dirs-when-cross-compiling.patch b/lang/python/patches/002-do-not-add-include-dirs-when-cross-compiling.patch similarity index 100% rename from lang/python/patches/120-do-not-add-include-dirs-when-cross-compiling.patch rename to lang/python/patches/002-do-not-add-include-dirs-when-cross-compiling.patch diff --git a/lang/python/patches/003-do-not-compile-tests-at-build.patch b/lang/python/patches/003-do-not-compile-tests-at-build.patch new file mode 100644 index 000000000..a6774e174 --- /dev/null +++ b/lang/python/patches/003-do-not-compile-tests-at-build.patch @@ -0,0 +1,20 @@ +diff --git a/Makefile.pre.in b/Makefile.pre.in +index 7f4ec2f..e270bf2 100644 +--- a/Makefile.pre.in ++++ b/Makefile.pre.in +@@ -1038,6 +1038,7 @@ libinstall: build_all $(srcdir)/Lib/$(PLATDIR) $(srcdir)/Modules/xxmodule.c + done; \ + done + $(INSTALL_DATA) $(srcdir)/LICENSE $(DESTDIR)$(LIBDEST)/LICENSE.txt ++ifeq (@COMPILE_ALL_TESTS@,yes) + if test -d $(DESTDIR)$(LIBDEST)/distutils/tests; then \ + $(INSTALL_DATA) $(srcdir)/Modules/xxmodule.c \ + $(DESTDIR)$(LIBDEST)/distutils/tests ; \ +@@ -1064,6 +1065,7 @@ libinstall: build_all $(srcdir)/Lib/$(PLATDIR) $(srcdir)/Modules/xxmodule.c + $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt + -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ + $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/PatternGrammar.txt ++endif + + # Create the PLATDIR source directory, if one wasn't distributed.. + $(srcdir)/Lib/$(PLATDIR): diff --git a/lang/python/patches/140-do-not-write-bytes-codes.patch b/lang/python/patches/004-do-not-write-bytes-codes.patch similarity index 100% rename from lang/python/patches/140-do-not-write-bytes-codes.patch rename to lang/python/patches/004-do-not-write-bytes-codes.patch diff --git a/lang/python/patches/150-fix-libffi-x86-64-configure.patch b/lang/python/patches/005-fix-libffi-x86-64-configure.patch similarity index 100% rename from lang/python/patches/150-fix-libffi-x86-64-configure.patch rename to lang/python/patches/005-fix-libffi-x86-64-configure.patch diff --git a/lang/python/patches/160-remove-debian-multiarch-support.patch b/lang/python/patches/006-remove-debian-multiarch-support.patch similarity index 100% rename from lang/python/patches/160-remove-debian-multiarch-support.patch rename to lang/python/patches/006-remove-debian-multiarch-support.patch diff --git a/lang/python/patches/007-distutils-do-not-adjust-path.patch b/lang/python/patches/007-distutils-do-not-adjust-path.patch new file mode 100644 index 000000000..49fe92629 --- /dev/null +++ b/lang/python/patches/007-distutils-do-not-adjust-path.patch @@ -0,0 +1,10 @@ +--- a/Lib/distutils/command/build_scripts.py ++++ b/Lib/distutils/command/build_scripts.py +@@ -89,6 +89,7 @@ class build_scripts (Command): + adjust = 1 + post_interp = match.group(1) or '' + ++ adjust = 0 + if adjust: + log.info("copying and adjusting %s -> %s", script, + self.build_dir) diff --git a/lang/python/patches/008-distutils-use-python-sysroot.patch b/lang/python/patches/008-distutils-use-python-sysroot.patch new file mode 100644 index 000000000..7cd748761 --- /dev/null +++ b/lang/python/patches/008-distutils-use-python-sysroot.patch @@ -0,0 +1,54 @@ +Adjust library/header paths for cross-compilation + +When cross-compiling third-party extensions, the get_python_inc() or +get_python_lib() can be called, to return the path to headers or +libraries. However, they use the sys.prefix of the host Python, which +returns incorrect paths when cross-compiling (paths pointing to host +headers and libraries). + +In order to fix this, we introduce the _python_sysroot, _python_prefix +and _python_exec_prefix variables, that allow to override these +values, and get correct header/library paths when cross-compiling +third-party Python modules. + +The _python_sysroot variable is also used to prefix the LIBDIR value +taken from the sysconfigdata module. + +Signed-off-by: Thomas Petazzoni + +Index: b/Lib/distutils/sysconfig.py +=================================================================== +--- a/Lib/distutils/sysconfig.py ++++ b/Lib/distutils/sysconfig.py +@@ -19,8 +19,13 @@ + from distutils.errors import DistutilsPlatformError + + # These are needed in a couple of spots, so just compute them once. +-PREFIX = os.path.normpath(sys.prefix) +-EXEC_PREFIX = os.path.normpath(sys.exec_prefix) ++if "_python_sysroot" in os.environ: ++ _sysroot=os.environ.get('_python_sysroot') ++ PREFIX = os.path.normpath(_sysroot + os.environ.get('_python_prefix')) ++ EXEC_PREFIX = os.path.normpath(_sysroot + os.environ.get('_python_exec_prefix')) ++else: ++ PREFIX = os.path.normpath(sys.prefix) ++ EXEC_PREFIX = os.path.normpath(sys.exec_prefix) + + # Path to the base directory of the project. On Windows the binary may + # live in project/PCBuild9. If we're dealing with an x64 Windows build, +Index: b/Lib/distutils/command/build_ext.py +=================================================================== +--- a/Lib/distutils/command/build_ext.py ++++ b/Lib/distutils/command/build_ext.py +@@ -237,7 +237,10 @@ + if (sysconfig.get_config_var('Py_ENABLE_SHARED')): + if not sysconfig.python_build: + # building third party extensions +- self.library_dirs.append(sysconfig.get_config_var('LIBDIR')) ++ libdir = sysconfig.get_config_var('LIBDIR') ++ if "_python_sysroot" in os.environ: ++ libdir = os.environ.get("_python_sysroot") + libdir ++ self.library_dirs.append(libdir) + else: + # building python standard extensions + self.library_dirs.append('.') diff --git a/lang/python/patches/009-do-not-use-dblib_dir-when-cross-compiling.patch b/lang/python/patches/009-do-not-use-dblib_dir-when-cross-compiling.patch new file mode 100644 index 000000000..b59809754 --- /dev/null +++ b/lang/python/patches/009-do-not-use-dblib_dir-when-cross-compiling.patch @@ -0,0 +1,34 @@ +diff --git a/setup.py b/setup.py +index 7868b7b..10ec68f 100644 +--- a/setup.py ++++ b/setup.py +@@ -1067,6 +1067,7 @@ class PyBuildExt(build_ext): + if db_setup_debug: print "db lib: ", dblib, "not found" + + except db_found: ++ rt_dblib_dir = None if cross_compiling else dblib_dir + if db_setup_debug: + print "bsddb using BerkeleyDB lib:", db_ver, dblib + print "bsddb lib dir:", dblib_dir, " inc dir:", db_incdir +@@ -1081,7 +1082,7 @@ class PyBuildExt(build_ext): + exts.append(Extension('_bsddb', ['_bsddb.c'], + depends = ['bsddb.h'], + library_dirs=dblib_dir, +- runtime_library_dirs=dblib_dir, ++ runtime_library_dirs=rt_dblib_dir, + include_dirs=db_incs, + libraries=dblibs)) + else: +@@ -1292,10 +1293,11 @@ class PyBuildExt(build_ext): + break + elif cand == "bdb": + if db_incs is not None: ++ rt_dblib_dir = None if cross_compiling else dblib_dir + print "building dbm using bdb" + dbmext = Extension('dbm', ['dbmmodule.c'], + library_dirs=dblib_dir, +- runtime_library_dirs=dblib_dir, ++ runtime_library_dirs=rt_dblib_dir, + include_dirs=db_incs, + define_macros=[ + ('HAVE_BERKDB_H', None), diff --git a/lang/python/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch b/lang/python/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch new file mode 100644 index 000000000..5a106d4e8 --- /dev/null +++ b/lang/python/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch @@ -0,0 +1,15 @@ +diff --git a/setup.py b/setup.py +index 7868b7b..544fa7e 100644 +--- a/setup.py ++++ b/setup.py +@@ -452,8 +452,9 @@ class PyBuildExt(build_ext): + # directly since an inconsistently reproducible issue comes up where + # the environment variable is not set even though the value were passed + # into configure and stored in the Makefile (issue found on OS X 10.3). ++ rt_lib_dirs = [] if cross_compiling else self.compiler.runtime_library_dirs + for env_var, arg_name, dir_list in ( +- ('LDFLAGS', '-R', self.compiler.runtime_library_dirs), ++ ('LDFLAGS', '-R', rt_lib_dirs), + ('LDFLAGS', '-L', self.compiler.library_dirs), + ('CPPFLAGS', '-I', self.compiler.include_dirs)): + env_val = sysconfig.get_config_var(env_var) diff --git a/lang/python/patches/011-do-not-prefer-ncursesw.patch b/lang/python/patches/011-do-not-prefer-ncursesw.patch new file mode 100644 index 000000000..c5f323c43 --- /dev/null +++ b/lang/python/patches/011-do-not-prefer-ncursesw.patch @@ -0,0 +1,15 @@ +diff --git a/setup.py b/setup.py +index 7868b7b..86b0119 100644 +--- a/setup.py ++++ b/setup.py +@@ -725,8 +725,8 @@ class PyBuildExt(build_ext): + # use the same library for the readline and curses modules. + if 'curses' in readline_termcap_library: + curses_library = readline_termcap_library +- elif self.compiler.find_library_file(lib_dirs, 'ncursesw'): +- curses_library = 'ncursesw' ++ #elif self.compiler.find_library_file(lib_dirs, 'ncursesw'): ++ # curses_library = 'ncursesw' + elif self.compiler.find_library_file(lib_dirs, 'ncurses'): + curses_library = 'ncurses' + elif self.compiler.find_library_file(lib_dirs, 'curses'): diff --git a/lang/python/patches/130-do-not-run-distutils-tests.patch b/lang/python/patches/130-do-not-run-distutils-tests.patch deleted file mode 100644 index 4fdd2bb4b..000000000 --- a/lang/python/patches/130-do-not-run-distutils-tests.patch +++ /dev/null @@ -1,37 +0,0 @@ -diff --git a/Makefile.pre.in b/Makefile.pre.in -index bcd83bf..c4dcc6d 100644 ---- a/Makefile.pre.in -+++ b/Makefile.pre.in -@@ -1005,32 +1005,6 @@ libinstall: build_all $(srcdir)/Lib/$(PLATDIR) $(srcdir)/Modules/xxmodule.c - done; \ - done - $(INSTALL_DATA) $(srcdir)/LICENSE $(DESTDIR)$(LIBDEST)/LICENSE.txt -- if test -d $(DESTDIR)$(LIBDEST)/distutils/tests; then \ -- $(INSTALL_DATA) $(srcdir)/Modules/xxmodule.c \ -- $(DESTDIR)$(LIBDEST)/distutils/tests ; \ -- fi -- PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \ -- -d $(LIBDEST) -f \ -- -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ -- $(DESTDIR)$(LIBDEST) -- PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \ -- -d $(LIBDEST) -f \ -- -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ -- $(DESTDIR)$(LIBDEST) -- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \ -- -d $(LIBDEST)/site-packages -f \ -- -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages -- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \ -- -d $(LIBDEST)/site-packages -f \ -- -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages -- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt -- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ -- $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/PatternGrammar.txt - - # Create the PLATDIR source directory, if one wasn't distributed.. - $(srcdir)/Lib/$(PLATDIR): diff --git a/lang/python3/Makefile b/lang/python3/Makefile index d13a9f4da..b9d29aab2 100644 --- a/lang/python3/Makefile +++ b/lang/python3/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -14,12 +14,12 @@ PYTHON_VERSION:=$(PYTHON3_VERSION) PYTHON_VERSION_MICRO:=$(PYTHON3_VERSION_MICRO) PKG_NAME:=python3 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_VERSION:=$(PYTHON_VERSION).$(PYTHON_VERSION_MICRO) PKG_SOURCE:=Python-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://www.python.org/ftp/python/$(PKG_VERSION) -PKG_MD5SUM:=36fc7327c02c6f12fa24fc9ba78039e3 +PKG_MD5SUM:=7d092d1bba6e17f0d9bd21b49e441dd5 PKG_LICENSE:=PSF PKG_LICENSE_FILES:=LICENSE Modules/_ctypes/libffi_msvc/LICENSE Modules/_ctypes/darwin/LICENSE Modules/_ctypes/libffi/LICENSE Modules/_ctypes/libffi_osx/LICENSE Tools/pybench/LICENSE @@ -57,7 +57,7 @@ endef define Package/python3-base $(call Package/python3/Default) TITLE:=Python $(PYTHON_VERSION) interpreter - DEPENDS:=+libpthread +zlib +libffi +libopenssl + DEPENDS:=+libpthread +zlib endef define Package/python3-base/description @@ -65,13 +65,45 @@ define Package/python3-base/description for the interpreter to start. endef +define Package/python3-light +$(call Package/python3/Default) + TITLE:=Python $(PYTHON_VERSION) light installation + DEPENDS:=+python3-base +libffi +libbz2 +endef + +define Package/python3-light/description + This package is essentially the python3-base package plus + a few of the rarely used (and big) libraries stripped out + into separate packages. +endef + +# Define newline here, since it's not defined in OpenWRT +define newline + + +endef + +PYTHON3_LIB_FILES_DEL:= +PYTHON3_PACKAGES:= +PYTHON3_SO_SUFFIX:=cpython-34.so +define Py3BasePackage + PYTHON3_PACKAGES+=$(1) + PYTHON3_LIB_FILES_DEL+=$(2) + define Py3Package/$(1)/filespec + $(subst $(space),$(newline),$(foreach lib_file,$(2),+|$(lib_file))) + endef +endef + +include ./files/python3-package-*.mk + define Package/python3 $(call Package/python3/Default) - DEPENDS:=+python3-base +libncursesw +libbz2 +libgdbm +libsqlite3 +libdb47 + DEPENDS:=+python3-light $(foreach package,$(PYTHON3_PACKAGES),+$(package)) endef define Package/python3/description This package contains the (almost) full Python install. + It's python3-light + all other packages. endef MAKE_FLAGS+=\ @@ -79,6 +111,10 @@ MAKE_FLAGS+=\ LD="$(TARGET_CC)" \ PGEN=pgen3 +ifeq ($(ARCH),i386) +MAKE_FLAGS+=PYTHON_DECIMAL_WITH_MACHINE=ansi32 +endif + EXTRA_CFLAGS+= \ -DNDEBUG -fno-inline EXTRA_LDFLAGS+= \ @@ -123,29 +159,35 @@ define Build/InstallDev $(1)/usr/lib/python$(PYTHON_VERSION)/ endef +PYTHON3_BASE_LIB_FILES:= \ + /usr/lib/python$(PYTHON_VERSION)/encodings \ + /usr/lib/python$(PYTHON_VERSION)/_collections_abc.py \ + /usr/lib/python$(PYTHON_VERSION)/_sitebuiltins.py \ + /usr/lib/python$(PYTHON_VERSION)/_sysconfigdata.py \ + /usr/lib/python$(PYTHON_VERSION)/_weakrefset.py \ + /usr/lib/python$(PYTHON_VERSION)/abc.py \ + /usr/lib/python$(PYTHON_VERSION)/codecs.py \ + /usr/lib/python$(PYTHON_VERSION)/genericpath.py \ + /usr/lib/python$(PYTHON_VERSION)/io.py \ + /usr/lib/python$(PYTHON_VERSION)/os.py \ + /usr/lib/python$(PYTHON_VERSION)/posixpath.py \ + /usr/lib/python$(PYTHON_VERSION)/site.py \ + /usr/lib/python$(PYTHON_VERSION)/sysconfig.py \ + /usr/lib/python$(PYTHON_VERSION)/stat.py + +PYTHON3_LIB_FILES_DEL+=$(PYTHON3_BASE_LIB_FILES) + define Py3Package/python3-base/filespec +|/usr/bin/python$(PYTHON_VERSION) -+|/usr/lib/python$(PYTHON_VERSION)/encodings -+|/usr/lib/python$(PYTHON_VERSION)/_collections_abc.py -+|/usr/lib/python$(PYTHON_VERSION)/_sitebuiltins.py -+|/usr/lib/python$(PYTHON_VERSION)/_sysconfigdata.py -+|/usr/lib/python$(PYTHON_VERSION)/_weakrefset.py -+|/usr/lib/python$(PYTHON_VERSION)/abc.py -+|/usr/lib/python$(PYTHON_VERSION)/codecs.py -+|/usr/lib/python$(PYTHON_VERSION)/genericpath.py -+|/usr/lib/python$(PYTHON_VERSION)/io.py -+|/usr/lib/python$(PYTHON_VERSION)/os.py -+|/usr/lib/python$(PYTHON_VERSION)/posixpath.py -+|/usr/lib/python$(PYTHON_VERSION)/site.py -+|/usr/lib/python$(PYTHON_VERSION)/sysconfig.py -+|/usr/lib/python$(PYTHON_VERSION)/stat.py +$(subst $(space),$(newline),$(foreach lib_file,$(PYTHON3_BASE_LIB_FILES),+|$(lib_file))) endef -define Py3Package/python3/filespec +define Py3Package/python3-light/filespec +|/usr/lib/python$(PYTHON_VERSION) -|/usr/lib/python$(PYTHON_VERSION)/config-$(PYTHON_VERSION) -|/usr/lib/python$(PYTHON_VERSION)/distutils/cygwinccompiler.py -|/usr/lib/python$(PYTHON_VERSION)/distutils/command/wininst* +-|/usr/lib/python$(PYTHON_VERSION)/ensurepip -|/usr/lib/python$(PYTHON_VERSION)/idlelib -|/usr/lib/python$(PYTHON_VERSION)/lib2to3 -|/usr/lib/python$(PYTHON_VERSION)/tkinter @@ -157,6 +199,8 @@ define Py3Package/python3/filespec -|/usr/lib/python$(PYTHON_VERSION)/webbrowser.py -|/usr/lib/python$(PYTHON_VERSION)/*/test -|/usr/lib/python$(PYTHON_VERSION)/*/tests +-|/usr/lib/python$(PYTHON_VERSION)/_osx_support.py +$(subst $(space),$(newline),$(foreach lib_file,$(PYTHON3_LIB_FILES_DEL),-|$(lib_file))) endef define Py3Package/python3-base/install @@ -167,6 +211,14 @@ define Py3Package/python3-base/install $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpython$(PYTHON_VERSION).so* $(1)/usr/lib/ endef +define Py3Package/python3/filespec +-|$(PYTHON3_PKG_DIR) +endef + +HOST_CFLAGS+= \ + -I/usr/include/ncursesw \ + -I/usr/include/ncurses + HOST_CONFIGURE_ARGS+= \ --without-cxx-main \ --without-pymalloc \ @@ -174,7 +226,7 @@ HOST_CONFIGURE_ARGS+= \ --prefix=$(STAGING_DIR_HOST) \ --with-ensurepip=upgrade \ CONFIG_SITE= \ - OPT="$(HOST_CFLAGS)" + CFLAGS="$(HOST_CFLAGS)" define Host/Compile +$(MAKE) $(HOST_JOBS) -C $(HOST_BUILD_DIR) python Parser/pgen @@ -189,8 +241,15 @@ endef $(eval $(call HostBuild)) +$(foreach package, $(PYTHON3_PACKAGES), \ + $(eval $(call Py3Package,$(package))) \ + $(eval $(call BuildPackage,$(package))) \ +) + $(eval $(call Py3Package,python3-base)) +$(eval $(call Py3Package,python3-light)) $(eval $(call Py3Package,python3)) $(eval $(call BuildPackage,python3-base)) +$(eval $(call BuildPackage,python3-light)) $(eval $(call BuildPackage,python3)) diff --git a/lang/python3/files/python3-package-asyncio.mk b/lang/python3/files/python3-package-asyncio.mk new file mode 100644 index 000000000..1d2faab3f --- /dev/null +++ b/lang/python3/files/python3-package-asyncio.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-asyncio +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) asyncio module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-asyncio, \ + /usr/lib/python$(PYTHON3_VERSION)/asyncio \ +)) diff --git a/lang/python3/files/python3-package-codecs.mk b/lang/python3/files/python3-package-codecs.mk new file mode 100644 index 000000000..66101e1fb --- /dev/null +++ b/lang/python3/files/python3-package-codecs.mk @@ -0,0 +1,22 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-codecs +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) codecs + unicode support + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-codecs, \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_cn.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_hk.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_iso2022.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_jp.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_kr.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_codecs_tw.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/unicodedata.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-ctypes.mk b/lang/python3/files/python3-package-ctypes.mk new file mode 100644 index 000000000..97c2c768a --- /dev/null +++ b/lang/python3/files/python3-package-ctypes.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-ctypes +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) ctypes module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-ctypes, \ + /usr/lib/python$(PYTHON3_VERSION)/ctypes \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_ctypes.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_ctypes_test.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-dbm.mk b/lang/python3/files/python3-package-dbm.mk new file mode 100644 index 000000000..ed343d81a --- /dev/null +++ b/lang/python3/files/python3-package-dbm.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-dbm +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) dbm module + DEPENDS:=+python3-light +libdb47 +endef + +$(eval $(call Py3BasePackage,python3-dbm, \ + /usr/lib/python$(PYTHON3_VERSION)/dbm \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_dbm.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-decimal.mk b/lang/python3/files/python3-package-decimal.mk new file mode 100644 index 000000000..81ecbb0d4 --- /dev/null +++ b/lang/python3/files/python3-package-decimal.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-decimal +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) decimal module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-decimal, \ + /usr/lib/python$(PYTHON3_VERSION)/decimal.py \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_decimal.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-distutils.mk b/lang/python3/files/python3-package-distutils.mk new file mode 100644 index 000000000..65f4b5aa6 --- /dev/null +++ b/lang/python3/files/python3-package-distutils.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-distutils +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) distutils module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-distutils, \ + /usr/lib/python$(PYTHON3_VERSION)/distutils \ +)) diff --git a/lang/python3/files/python3-package-email.mk b/lang/python3/files/python3-package-email.mk new file mode 100644 index 000000000..dae351979 --- /dev/null +++ b/lang/python3/files/python3-package-email.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-email +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) email module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-email, \ + /usr/lib/python$(PYTHON3_VERSION)/email \ +)) diff --git a/lang/python3/files/python3-package-gdbm.mk b/lang/python3/files/python3-package-gdbm.mk new file mode 100644 index 000000000..cc929132c --- /dev/null +++ b/lang/python3/files/python3-package-gdbm.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-gdbm +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) gdbm module + DEPENDS:=+python3-light +libgdbm +endef + +$(eval $(call Py3BasePackage,python3-gdbm, \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_gdbm.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-logging.mk b/lang/python3/files/python3-package-logging.mk new file mode 100644 index 000000000..4cd6ea979 --- /dev/null +++ b/lang/python3/files/python3-package-logging.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-logging +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) logging module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-logging, \ + /usr/lib/python$(PYTHON3_VERSION)/logging \ +)) diff --git a/lang/python3/files/python3-package-lzma.mk b/lang/python3/files/python3-package-lzma.mk new file mode 100644 index 000000000..b04f072f9 --- /dev/null +++ b/lang/python3/files/python3-package-lzma.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-lzma +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) lzma module + DEPENDS:=+python3-light +liblzma +endef + +$(eval $(call Py3BasePackage,python3-lzma, \ + /usr/lib/python$(PYTHON3_VERSION)/lzma.py \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_lzma.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-multiprocessing.mk b/lang/python3/files/python3-package-multiprocessing.mk new file mode 100644 index 000000000..784aabb8b --- /dev/null +++ b/lang/python3/files/python3-package-multiprocessing.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-multiprocessing +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) multiprocessing + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-multiprocessing, \ + /usr/lib/python$(PYTHON3_VERSION)/multiprocessing \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_multiprocessing.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-ncurses.mk b/lang/python3/files/python3-package-ncurses.mk new file mode 100644 index 000000000..7e703b3dd --- /dev/null +++ b/lang/python3/files/python3-package-ncurses.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-ncurses +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) ncurses module + DEPENDS:=+python3-light +libncurses +endef + +$(eval $(call Py3BasePackage,python3-ncurses, \ + /usr/lib/python$(PYTHON3_VERSION)/curses \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_curses.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_curses_panel.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-openssl.mk b/lang/python3/files/python3-package-openssl.mk new file mode 100644 index 000000000..255d58099 --- /dev/null +++ b/lang/python3/files/python3-package-openssl.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-openssl +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) SSL module + DEPENDS:=+python3-light +libopenssl +endef + +$(eval $(call Py3BasePackage,python3-openssl, \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_hashlib.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_ssl.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package-pydoc.mk b/lang/python3/files/python3-package-pydoc.mk new file mode 100644 index 000000000..7ed8c2110 --- /dev/null +++ b/lang/python3/files/python3-package-pydoc.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-pydoc +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) pydoc module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-pydoc, \ + /usr/lib/python$(PYTHON3_VERSION)/doctest.py \ + /usr/lib/python$(PYTHON3_VERSION)/pydoc.py \ + /usr/lib/python$(PYTHON3_VERSION)/pydoc_data \ +)) diff --git a/lang/python3/files/python3-package-sqlite3.mk b/lang/python3/files/python3-package-sqlite3.mk new file mode 100644 index 000000000..4b097a36b --- /dev/null +++ b/lang/python3/files/python3-package-sqlite3.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-sqlite3 +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) sqlite3 module + DEPENDS:=+python3-light +libsqlite3 +endef + +$(eval $(call Py3BasePackage,python3-sqlite3, \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_sqlite3.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/sqlite3 \ +)) diff --git a/lang/python3/files/python3-package-unittest.mk b/lang/python3/files/python3-package-unittest.mk new file mode 100644 index 000000000..6d3643a71 --- /dev/null +++ b/lang/python3/files/python3-package-unittest.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-unittest +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) unittest module + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-unittest, \ + /usr/lib/python$(PYTHON3_VERSION)/unittest \ +)) diff --git a/lang/python3/files/python3-package-xml.mk b/lang/python3/files/python3-package-xml.mk new file mode 100644 index 000000000..e734f0c72 --- /dev/null +++ b/lang/python3/files/python3-package-xml.mk @@ -0,0 +1,19 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-xml +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) xml libs + DEPENDS:=+python3-light +endef + +$(eval $(call Py3BasePackage,python3-xml, \ + /usr/lib/python$(PYTHON3_VERSION)/xml \ + /usr/lib/python$(PYTHON3_VERSION)/xmlrpc \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/_elementtree.$(PYTHON3_SO_SUFFIX) \ + /usr/lib/python$(PYTHON3_VERSION)/lib-dynload/pyexpat.$(PYTHON3_SO_SUFFIX) \ +)) diff --git a/lang/python3/files/python3-package.mk b/lang/python3/files/python3-package.mk index b28ec5833..e76dc0bc8 100644 --- a/lang/python3/files/python3-package.mk +++ b/lang/python3/files/python3-package.mk @@ -6,7 +6,7 @@ # PYTHON3_VERSION:=3.4 -PYTHON3_VERSION_MICRO:=2 +PYTHON3_VERSION_MICRO:=3 PYTHON3_DIR:=$(STAGING_DIR)/usr PYTHON3_BIN_DIR:=$(PYTHON3_DIR)/bin diff --git a/lang/python3/patches/110-enable-zlib.patch b/lang/python3/patches/001-enable-zlib.patch similarity index 100% rename from lang/python3/patches/110-enable-zlib.patch rename to lang/python3/patches/001-enable-zlib.patch diff --git a/lang/python3/patches/120-do-not-add-include-dirs-when-cross-compiling.patch b/lang/python3/patches/002-do-not-add-include-dirs-when-cross-compiling.patch similarity index 100% rename from lang/python3/patches/120-do-not-add-include-dirs-when-cross-compiling.patch rename to lang/python3/patches/002-do-not-add-include-dirs-when-cross-compiling.patch diff --git a/lang/python3/patches/130-do-not-run-distutils-tests.patch b/lang/python3/patches/003-do-not-run-distutils-tests.patch similarity index 100% rename from lang/python3/patches/130-do-not-run-distutils-tests.patch rename to lang/python3/patches/003-do-not-run-distutils-tests.patch diff --git a/lang/python3/patches/140-do-not-write-bytes-codes.patch b/lang/python3/patches/004-do-not-write-bytes-codes.patch similarity index 100% rename from lang/python3/patches/140-do-not-write-bytes-codes.patch rename to lang/python3/patches/004-do-not-write-bytes-codes.patch diff --git a/lang/python3/patches/005-fix-libffi-x86-64-configure.patch b/lang/python3/patches/005-fix-libffi-x86-64-configure.patch new file mode 100644 index 000000000..ea062a350 --- /dev/null +++ b/lang/python3/patches/005-fix-libffi-x86-64-configure.patch @@ -0,0 +1,31 @@ +diff --git a/Modules/_ctypes/libffi/configure b/Modules/_ctypes/libffi/configure +index 75f62a7..4d6c9f2 100755 +--- a/Modules/_ctypes/libffi/configure ++++ b/Modules/_ctypes/libffi/configure +@@ -17257,20 +17257,12 @@ case "$host" in + fi + ;; + +- i?86-*-* | x86_64-*-*) +- TARGETDIR=x86 +- if test $ac_cv_sizeof_size_t = 4; then +- case "$host" in +- *-gnux32) +- TARGET=X86_64 +- ;; +- *) +- TARGET=X86 +- ;; +- esac +- else +- TARGET=X86_64; +- fi ++ i?86-*-*) ++ TARGET=X86; TARGETDIR=x86 ++ ;; ++ ++ x86_64-*-*) ++ TARGET=X86_64; TARGETDIR=x86 + ;; + + ia64*-*-*) diff --git a/lang/python3/patches/006-remove-debian-multiarch-support.patch b/lang/python3/patches/006-remove-debian-multiarch-support.patch new file mode 100644 index 000000000..52d52b94e --- /dev/null +++ b/lang/python3/patches/006-remove-debian-multiarch-support.patch @@ -0,0 +1,12 @@ +diff --git a/setup.py b/setup.py +index 7868b7b..9ae0ef2 100644 +--- a/setup.py ++++ b/setup.py +@@ -444,7 +444,6 @@ class PyBuildExt(build_ext): + add_dir_to_list(self.compiler.include_dirs, '/usr/local/include') + if cross_compiling: + self.add_gcc_paths() +- self.add_multiarch_paths() + + # Add paths specified in the environment variables LDFLAGS and + # CPPFLAGS for header and library files. diff --git a/lang/python3/patches/007-distutils-do-not-adjust-path.patch b/lang/python3/patches/007-distutils-do-not-adjust-path.patch new file mode 100644 index 000000000..49fe92629 --- /dev/null +++ b/lang/python3/patches/007-distutils-do-not-adjust-path.patch @@ -0,0 +1,10 @@ +--- a/Lib/distutils/command/build_scripts.py ++++ b/Lib/distutils/command/build_scripts.py +@@ -89,6 +89,7 @@ class build_scripts (Command): + adjust = 1 + post_interp = match.group(1) or '' + ++ adjust = 0 + if adjust: + log.info("copying and adjusting %s -> %s", script, + self.build_dir) diff --git a/lang/python3/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch b/lang/python3/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch new file mode 100644 index 000000000..5a106d4e8 --- /dev/null +++ b/lang/python3/patches/010-do-not-add-rt-lib-dirs-when-cross-compiling.patch @@ -0,0 +1,15 @@ +diff --git a/setup.py b/setup.py +index 7868b7b..544fa7e 100644 +--- a/setup.py ++++ b/setup.py +@@ -452,8 +452,9 @@ class PyBuildExt(build_ext): + # directly since an inconsistently reproducible issue comes up where + # the environment variable is not set even though the value were passed + # into configure and stored in the Makefile (issue found on OS X 10.3). ++ rt_lib_dirs = [] if cross_compiling else self.compiler.runtime_library_dirs + for env_var, arg_name, dir_list in ( +- ('LDFLAGS', '-R', self.compiler.runtime_library_dirs), ++ ('LDFLAGS', '-R', rt_lib_dirs), + ('LDFLAGS', '-L', self.compiler.library_dirs), + ('CPPFLAGS', '-I', self.compiler.include_dirs)): + env_val = sysconfig.get_config_var(env_var) diff --git a/lang/python3/patches/011-do-not-prefer-ncursesw.patch b/lang/python3/patches/011-do-not-prefer-ncursesw.patch new file mode 100644 index 000000000..c02322534 --- /dev/null +++ b/lang/python3/patches/011-do-not-prefer-ncursesw.patch @@ -0,0 +1,15 @@ +diff --git a/setup.py b/setup.py +index 2779658..b6d3d61 100644 +--- a/setup.py ++++ b/setup.py +@@ -693,8 +693,8 @@ class PyBuildExt(build_ext): + # use the same library for the readline and curses modules. + if 'curses' in readline_termcap_library: + curses_library = readline_termcap_library +- elif self.compiler.find_library_file(lib_dirs, 'ncursesw'): +- curses_library = 'ncursesw' ++ #elif self.compiler.find_library_file(lib_dirs, 'ncursesw'): ++ # curses_library = 'ncursesw' + elif self.compiler.find_library_file(lib_dirs, 'ncurses'): + curses_library = 'ncurses' + elif self.compiler.find_library_file(lib_dirs, 'curses'): diff --git a/lang/ruby/Makefile b/lang/ruby/Makefile index 1d419b6b7..54aaadc29 100644 --- a/lang/ruby/Makefile +++ b/lang/ruby/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -10,14 +10,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ruby -PKG_VERSION:=2.2.0 -PKG_RELEASE:=1 +PKG_VERSION:=2.2.2 +PKG_RELEASE:=3 PKG_LIBVER:=2.2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://cache.ruby-lang.org/pub/ruby/$(PKG_LIBVER)/ -PKG_MD5SUM:=d03cd4690fec1fff81d096d1c1255fde +PKG_MD5SUM:=af6eb4fa7247f1f7b2e19c8e6f3e3145 PKG_MAINTAINER:=Luiz Angelo Daros de Luca PKG_LICENSE:=BSD-2-Clause PKG_LICENSE_FILES:=COPYING @@ -575,7 +575,7 @@ endef define Package/ruby-psych $(call Package/ruby/Default) TITLE+=YAML parser and emitter - DEPENDS:=ruby +ruby-bigdecimal +ruby-datetime +ruby-misc +ruby-enc + DEPENDS:=ruby +ruby-bigdecimal +ruby-datetime +ruby-misc +ruby-enc +libyaml endef define Package/ruby-psych/description @@ -803,16 +803,24 @@ HOST_CONFIGURE_ARGS += \ --disable-install-rdoc \ --disable-install-capi \ --with-static-linked-ext \ + --with-out-ext=tk,tk/tkutil,win32,win32ole,dbm,gdbm,readline \ + +# even not used, host build with restricted exts results in gems not being +# compiling for target (probably some cross compiling problem like checking +# host for selecting target features) +# --with-out-ext \ +# --with-ext=thread,stringio \ CONFIGURE_ARGS += \ --enable-shared \ --enable-static \ --disable-rpath \ - --enable-ipv6 \ + $(call autoconf_bool,CONFIG_IPV6,ipv6) \ --disable-install-doc \ --disable-install-capi \ --with-ruby-version=minor \ --with-iconv-dir=$(ICONV_PREFIX) \ + --with-out-ext=tk,tk/tkutil,win32,win32ole ifndef CONFIG_RUBY_DIGEST_USE_OPENSSL CONFIGURE_ARGS += \ @@ -874,7 +882,6 @@ define Package/ruby-datetime/install ( cd $(PKG_INSTALL_DIR); $(TAR) -cf - \ usr/lib/ruby/$(PKG_LIBVER)/time.rb \ usr/lib/ruby/$(PKG_LIBVER)/date.rb \ - usr/lib/ruby/$(PKG_LIBVER)/date/ \ usr/lib/ruby/$(PKG_LIBVER)/*/date_core.so \ ) | ( cd $(1); $(TAR) -xf - ) endef @@ -1252,7 +1259,6 @@ endef define Package/ruby-socket/install ( cd $(PKG_INSTALL_DIR); $(TAR) -cf - \ - usr/lib/ruby/$(PKG_LIBVER)/gserver.rb \ usr/lib/ruby/$(PKG_LIBVER)/ipaddr.rb \ usr/lib/ruby/$(PKG_LIBVER)/resolv-replace.rb \ usr/lib/ruby/$(PKG_LIBVER)/resolv.rb \ diff --git a/lang/uuid/Makefile b/lang/uuid/Makefile new file mode 100644 index 000000000..a093e666c --- /dev/null +++ b/lang/uuid/Makefile @@ -0,0 +1,51 @@ +# +# Copyright (C) 2006-2015 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:=uuid +PKG_VERSION:=0.2.0 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/Tieske/uuid.git +PKG_SOURCE_VERSION:=version_$(PKG_VERSION) + +PKG_MAINTAINER:=Amr Hassan +PKG_LICENSE=Apache-2.0 + +LUA_MODULE_PATH:=/usr/lib/lua + +include $(INCLUDE_DIR)/package.mk + +define Package/uuid + SUBMENU:=Lua + SECTION:=lang + CATEGORY:=Languages + TITLE:=uuid + URL:=https://github.com/Tieske/uuid + DEPENDS:=+lua +luasocket +endef + +define Package/uuid/description + A pure Lua uuid generator +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Package/uuid/install + $(INSTALL_DIR) $(1)/$(LUA_MODULE_PATH) + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/uuid.lua $(1)/$(LUA_MODULE_PATH)/uuid.lua +endef + +$(eval $(call BuildPackage,uuid)) diff --git a/lang/vala/Makefile b/lang/vala/Makefile index d3dbc82ff..c8b9c1b58 100644 --- a/lang/vala/Makefile +++ b/lang/vala/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,15 +8,15 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vala -PKG_VERSION:=0.26.1 +PKG_VERSION:=0.28.0 PKG_RELEASE:=1 PKG_LICENSE:=LGPL-2.1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=@GNOME/vala/0.26/ -PKG_MD5SUM:=723a03b822d4cc47abc4019685970a3e +PKG_SOURCE_URL:=@GNOME/vala/0.28/ +PKG_MD5SUM:=8d4ceac3451a0d5497e7be38e5e4c2ad -PKG_BUILD_DEPENDS:=glib2/host vala/host +PKG_BUILD_DEPENDS:=glib2 glib2/host vala/host HOST_BUILD_DEPENDS:=glib2/host include $(INCLUDE_DIR)/host-build.mk @@ -47,21 +47,21 @@ endef define Build/InstallDev $(INSTALL_DIR) \ - $(1)/usr/share/vala-0.26/vapi \ + $(1)/usr/share/vala-0.28/vapi \ $(1)/usr/lib \ $(1)/usr/share/pkgconfig \ $(1)/usr/bin $(INSTALL_DATA) \ - $(PKG_INSTALL_DIR)/usr/share/vala-0.26/vapi/* \ - $(1)/usr/share/vala-0.26/vapi + $(PKG_INSTALL_DIR)/usr/share/vala-0.28/vapi/* \ + $(1)/usr/share/vala-0.28/vapi $(INSTALL_DATA) \ - $(PKG_INSTALL_DIR)/usr/lib/libvala-0.26.{so*,la} \ + $(PKG_INSTALL_DIR)/usr/lib/libvala-0.28.{so*,la} \ $(1)/usr/lib $(INSTALL_BIN) \ - $(PKG_INSTALL_DIR)/usr/bin/{vala,vala-0.26,valac,valac-0.26,vapicheck,vapicheck-0.26,vapigen,vapigen-0.26,vala-gen-introspect,vala-gen-introspect-0.26} \ + $(PKG_INSTALL_DIR)/usr/bin/{vala,vala-0.28,valac,valac-0.28,vapicheck,vapicheck-0.28,vapigen,vapigen-0.28,vala-gen-introspect,vala-gen-introspect-0.28} \ $(1)/usr/bin $(INSTALL_DATA) \ diff --git a/libs/apr/Makefile b/libs/apr/Makefile index 69f5b5fd9..d61d31f9e 100644 --- a/libs/apr/Makefile +++ b/libs/apr/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=apr -PKG_VERSION:=1.5.1 -PKG_RELEASE:=1 +PKG_VERSION:=1.5.2 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://mirrors.ibiblio.org/apache/apr/ -PKG_MD5SUM:=5486180ec5a23efb5cae6d4292b300ab +PKG_MD5SUM:=4e9769f3349fe11fc0a5e1b224c236aa PKG_MAINTAINER:=Thomas Heil PKG_LICENSE:=Apache License @@ -38,7 +38,7 @@ TARGET_CPPFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE CONFIGURE_ARGS += \ --with-devrandom=/dev/urandom \ --disable-dso \ - --enable-ipv6 + $(call autoconf_bool,CONFIG_IPV6,ipv6) # XXX: ac_cv_sizeof_struct_iovec=1 is just to trick configure CONFIGURE_VARS += \ diff --git a/libs/apr/patches/001-autoconf-compat.patch b/libs/apr/patches/001-autoconf-compat.patch index 8170572bc..acc94fc3f 100644 --- a/libs/apr/patches/001-autoconf-compat.patch +++ b/libs/apr/patches/001-autoconf-compat.patch @@ -1,5 +1,7 @@ ---- a/Makefile.in -+++ b/Makefile.in +Index: apr-1.5.2/Makefile.in +=================================================================== +--- apr-1.5.2.orig/Makefile.in ++++ apr-1.5.2/Makefile.in @@ -3,6 +3,7 @@ srcdir=@srcdir@ VPATH=@srcdir@ top_srcdir=@apr_srcdir@ @@ -8,9 +10,11 @@ # # APR (Apache Portable Runtime) library Makefile. ---- a/configure.in -+++ b/configure.in -@@ -246,9 +246,6 @@ case $host in +Index: apr-1.5.2/configure.in +=================================================================== +--- apr-1.5.2.orig/configure.in ++++ apr-1.5.2/configure.in +@@ -245,9 +245,6 @@ case $host in gcc $CFLAGS $CPPFLAGS -o $LIBTOOL.exe $LIBTOOL.c ;; *) diff --git a/libs/apr/patches/201-upgrade-and-fix-1.5.1.patch b/libs/apr/patches/201-upgrade-and-fix-1.5.1.patch index 42f4c0f03..87cd546d1 100644 --- a/libs/apr/patches/201-upgrade-and-fix-1.5.1.patch +++ b/libs/apr/patches/201-upgrade-and-fix-1.5.1.patch @@ -15,10 +15,10 @@ Signed-off-by: Hongxu Jia Makefile.in | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) -Index: apr-1.5.1/Makefile.in +Index: apr-1.5.2/Makefile.in =================================================================== ---- apr-1.5.1.orig/Makefile.in -+++ apr-1.5.1/Makefile.in +--- apr-1.5.2.orig/Makefile.in ++++ apr-1.5.2/Makefile.in @@ -20,7 +20,7 @@ INCDIR=./include OSDIR=$(top_srcdir)/include/arch/@OSDIR@ DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@ @@ -36,19 +36,16 @@ Index: apr-1.5.1/Makefile.in include/private/apr_escape_test_char.h DISTCLEAN_TARGETS = config.cache config.log config.status \ include/apr.h include/arch/unix/apr_private.h \ -@@ -130,13 +129,8 @@ check: $(TARGET_LIB) - etags: - etags `find . -name '*.[ch]'` +@@ -135,9 +134,9 @@ tools/gen_test_char.lo: tools/gen_test_c + $(APR_MKDIR) tools + $(LT_COMPILE) --make_tools_dir: -- $(APR_MKDIR) tools -- --OBJECTS_gen_test_char = tools/gen_test_char.lo $(LOCAL_LIBS) --tools/gen_test_char.lo: make_tools_dir -tools/gen_test_char@EXEEXT@: $(OBJECTS_gen_test_char) - $(LINK_PROG) $(OBJECTS_gen_test_char) $(ALL_LIBS) +- +tools/gen_test_char@EXEEXT@: tools/gen_test_char.c + $(BUILDCC) $(CFLAGS_FOR_BUILD) $< -o $@ - ++ include/private/apr_escape_test_char.h: tools/gen_test_char@EXEEXT@ $(APR_MKDIR) include/private + tools/gen_test_char@EXEEXT@ > $@ diff --git a/libs/argp-standalone/Makefile b/libs/argp-standalone/Makefile deleted file mode 100644 index 8cf23fec5..000000000 --- a/libs/argp-standalone/Makefile +++ /dev/null @@ -1,48 +0,0 @@ -# -# Copyright (C) 2007-2014 OpenWrt.org -# -# This is free software, licensed under the GNU General Public License v2. -# See /LICENSE for more information. -# - -include $(TOPDIR)/rules.mk - -PKG_NAME:=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 -PKG_MAINTAINER:=Ted Hess - -PKG_LICENSE:=LGPL-2.1 -PKG_LICENSE:=Makefile.am - -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)) diff --git a/libs/argp-standalone/patches/001-throw-in-funcdef.patch b/libs/argp-standalone/patches/001-throw-in-funcdef.patch deleted file mode 100644 index 4a90751e1..000000000 --- a/libs/argp-standalone/patches/001-throw-in-funcdef.patch +++ /dev/null @@ -1,79 +0,0 @@ -# --- 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; - } diff --git a/libs/avahi/Makefile b/libs/avahi/Makefile index 5f7ac1374..2d1a64b31 100644 --- a/libs/avahi/Makefile +++ b/libs/avahi/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=avahi PKG_VERSION:=0.6.31 -PKG_RELEASE:=11 +PKG_RELEASE:=12 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://avahi.org/download/ @@ -56,7 +56,7 @@ define Package/libavahi/Default SECTION:=libs CATEGORY:=Libraries PROVIDES:=libavahi - DEPENDS:=+libpthread +SSP_SUPPORT:libssp + DEPENDS:=+libpthread endef define Package/libavahi/description @@ -100,6 +100,7 @@ define Package/avahi-nodbus-daemon SUBMENU:=IP Addresses and Names DEPENDS:=+libavahi-nodbus-support +libexpat +librt +libdaemon TITLE+= (daemon) + USERID:=avahi=105:avahi=105 endef define Package/avahi-daemon/description @@ -155,7 +156,7 @@ endef define Package/avahi-dnsconfd $(call Package/avahi/Default) SUBMENU:=IP Addresses and Names - DEPENDS:=+libavahi +libdaemon +libpthread +SSP_SUPPORT:libssp + DEPENDS:=+libavahi +libdaemon +libpthread TITLE:=A Unicast DNS server using avahi-daemon endef diff --git a/libs/avahi/files/avahi-daemon.conf b/libs/avahi/files/avahi-daemon.conf index 4ef64df2a..3ef0788eb 100644 --- a/libs/avahi/files/avahi-daemon.conf +++ b/libs/avahi/files/avahi-daemon.conf @@ -2,7 +2,7 @@ #host-name=foo #domain-name=local use-ipv4=yes -use-ipv6=no +use-ipv6=yes check-response-ttl=no use-iff-running=no diff --git a/libs/boost/Makefile b/libs/boost/Makefile index aae7fd2b4..b54ea1e84 100644 --- a/libs/boost/Makefile +++ b/libs/boost/Makefile @@ -16,212 +16,157 @@ include $(INCLUDE_DIR)/nls.mk include $(INCLUDE_DIR)/target.mk PKG_NAME:=boost -PKG_VERSION:=1_57_0 -PKG_RELEASE:=2 +PKG_VERSION:=1_58_0 +PKG_RELEASE:=5 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/boost PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)_$(PKG_VERSION) HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/$(PKG_NAME)_$(PKG_VERSION) -PKG_MD5SUM:=25f9a8ac28beeb5ab84aa98510305299 +PKG_MD5SUM:=5a5d5614d9a07672e1ab2a250b5defc5 PKG_LICENSE:=Boost Software License -PKG_MAINTAINER:=Carlos M. Ferreira (Modified from Mirko Vogt Boost 1.51 Original Makefile and patches) - +PKG_MAINTAINER:=Carlos M. Ferreira PKG_BUILD_DEPENDS += boost/host PKG_BUILD_PARALLEL:=0 PKG_USE_MIPS16:=0 -PKG_CONFIG_DEPENDS := \ - CONFIG_PACKAGE_boost-date_time \ - CONFIG_PACKAGE_boost-filesystem \ - CONFIG_PACKAGE_boost-graph \ - CONFIG_PACKAGE_boost-iostreams \ - CONFIG_PACKAGE_boost-math \ - CONFIG_PACKAGE_boost-program_options \ - CONFIG_PACKAGE_boost-python \ - CONFIG_PACKAGE_boost-regex \ - CONFIG_PACKAGE_boost-serialization \ - CONFIG_PACKAGE_boost-signals \ - CONFIG_PACKAGE_boost-system \ - CONFIG_PACKAGE_boost-test \ - CONFIG_PACKAGE_boost-thread \ - CONFIG_PACKAGE_boost-wave \ - CONFIG_PACKAGE_boost-atomic \ - CONFIG_PACKAGE_boost-context \ - CONFIG_PACKAGE_boost-container \ - CONFIG_PACKAGE_boost-coroutine \ - CONFIG_PACKAGE_boost-log \ - - - include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/host-build.mk + define Package/boost/Default SECTION:=libs CATEGORY:=Libraries - TITLE:=Boost C++ source libraries + TITLE:=Boost C++ source library URL:=http://www.boost.org DEPENDS:=+libstdcpp +libpthread +librt endef -define Package/boost/Default/description +define Package/boost/description/Default Boost provides free peer-reviewed portable C++ source libraries endef -define Package/boost-atomic - $(call Package/boost/Default) - TITLE+= (atomic) - DEPENDS+= +boost-system -endef +BOOST_LIBS = -define Package/boost-chrono - $(call Package/boost/Default) - TITLE+= (chrono) - DEPENDS+= +boost-system +define Package/boost-libs +$(call Package/boost/Default) + TITLE+= (all libs) + DEPENDS+= $(BOOST_DEPENDS) + HIDDEN:=1 endef -define Package/boost-date_time - $(call Package/boost/Default) - TITLE+= (date_time) +define Package/boost-libs/description +$(call Package/boost/description/Default) + . + This meta package contains only dependencies to the other libraries from + the boost libraries collection. endef -define Package/boost-exception - $(call Package/boost/Default) - TITLE+= (exception) +# Create a meta-package of dependent libraries (for ALL) +define Package/boost-libs/install + true endef -define Package/boost-filesystem - $(call Package/boost/Default) - TITLE+= (filesystem) - DEPENDS+= +boost-system +define Package/boost/install + true endef -define Package/boost-graph +define Package/boost $(call Package/boost/Default) - TITLE+= (graph) - DEPENDS+= +boost-regex + TITLE+= packages + DEPENDS:=+ALL:boost-libs +ALL:boost-test endef -define Package/boost-graph_parallel - $(call Package/boost/Default) - TITLE+= (graph_parallel) -endef +define Package/boost/config + menu "Select Boost libraries" + depends on PACKAGE_boost -define Package/boost-iostreams - $(call Package/boost/Default) - TITLE+= (iostreams) - DEPENDS+= +zlib -endef + config boost-libs-all + bool "Include all Boost libraries" + select PACKAGE_boost-libs -define Package/boost-locale - $(call Package/boost/Default) - TITLE+= (locale) - DEPENDS+= $(ICONV_DEPENDS) -endef + config boost-test-pkg + bool "Boost test package" + select PACKAGE_boost-test -define Package/boost-math - $(call Package/boost/Default) - TITLE+= (math) -endef + comment "Libraries" -define Package/boost-mpi - $(call Package/boost/Default) - TITLE+= (mpi) -endef + $(foreach lib,$(BOOST_LIBS), \ + config PACKAGE_boost-$(lib) + prompt "Boost $(lib) library" -define Package/boost-program_options - $(call Package/boost/Default) - TITLE+= (program_options) -endef + ) -define Package/boost-python - $(call Package/boost/Default) - TITLE+= (python) - DEPENDS+= +PACKAGE_boost-python:python -endef + endmenu -define Package/boost-random - $(call Package/boost/Default) - TITLE+= (random) - DEPENDS+= +boost-system endef -define Package/boost-regex - $(call Package/boost/Default) - TITLE+= (regex) -endef - -define Package/boost-serialization - $(call Package/boost/Default) - TITLE+= (serialization) -endef - -define Package/boost-signals - $(call Package/boost/Default) - TITLE+= (signals) -endef - -define Package/boost-system - $(call Package/boost/Default) - TITLE+= (system) -endef +PKG_CONFIG_DEPENDS:= CONFIG_PACKAGE_boost-test define Package/boost-test $(call Package/boost/Default) TITLE+= (test) -endef - -define Package/boost-thread - $(call Package/boost/Default) - TITLE+= (thread) - DEPENDS+= +boost-system +boost-chrono +boost-atomic -endef - -define Package/boost-timer - $(call Package/boost/Default) - TITLE+= (timer) - DEPENDS+= boost-chrono -endef - -define Package/boost-wave - $(call Package/boost/Default) - TITLE+= (wave) - DEPENDS+= +boost-date_time +boost-thread +boost-filesystem -endef - -define Package/boost-context - $(call Package/boost/Default) - TITLE+= (context) -endef - -define Package/boost-container - $(call Package/boost/Default) - TITLE+= (container) -endef - -define Package/boost-coroutine - $(call Package/boost/Default) - TITLE+= (coroutine) - DEPENDS+= +boost-system +boost-chrono +boost-context +boost-thread -endef - -define Package/boost-log - $(call Package/boost/Default) - TITLE+= (log) - DEPENDS+= +boost-system +boost-chrono +boost-date_time +boost-thread +boost-filesystem +boost-regex -endef - -define Package/boost - $(call Package/boost/Default) - TITLE+= (header-only) - BUILDONLY:=1 + HIDDEN:=1 endef define Build/Configure endef +# 1: short name +# 2: dependencies on other boost libraries (short name) +# 3: dependencies on other packages +define DefineBoostLibrary + + BOOST_DEPENDS+= +boost-$(1) + BOOST_LIBS+= $(1) + + PKG_CONFIG_DEPENDS+= CONFIG_PACKAGE_boost-$(1) + + define Package/boost-$(1) + $(call Package/boost/Default) + TITLE+= ($(1)) + DEPENDS+= $$(foreach lib,$(2),+boost-$$(lib)) $(3) + HIDDEN:=1 + endef + + define Package/boost-$(1)/description + $(call Package/boost/description/Default) + . + This package contains the Boost $(1) library. + endef +endef + +$(eval $(call DefineBoostLibrary,atomic,system,)) +$(eval $(call DefineBoostLibrary,chrono,system,)) +$(eval $(call DefineBoostLibrary,container,,)) +$(eval $(call DefineBoostLibrary,context,chrono system thread,)) +$(eval $(call DefineBoostLibrary,coroutine,system chrono context thread,)) +$(eval $(call DefineBoostLibrary,date_time,,)) +#$(eval $(call DefineBoostLibrary,exception,,)) +$(eval $(call DefineBoostLibrary,filesystem,system,)) +$(eval $(call DefineBoostLibrary,graph,regex,)) +#$(eval $(call DefineBoostLibrary,graph_parallel,,)) +$(eval $(call DefineBoostLibrary,iostreams,,+zlib)) +$(eval $(call DefineBoostLibrary,locale,system,$(ICONV_DEPENDS))) +$(eval $(call DefineBoostLibrary,log,system chrono date_time thread filesystem regex,)) +$(eval $(call DefineBoostLibrary,math,,)) +#$(eval $(call DefineBoostLibrary,mpi,,)) +$(eval $(call DefineBoostLibrary,program_options,,)) +$(eval $(call DefineBoostLibrary,random,system,)) + +# We need a beter way to provide this package, information regarding the Python packages +# such as Python version and directories locations. +# Python 2.7 version is for now hard-coded. Python 3 is (until this date) broken in the trunk tree. +$(eval $(call DefineBoostLibrary,python,,+PACKAGE_boost-python:python)) +$(eval $(call DefineBoostLibrary,regex,,)) +$(eval $(call DefineBoostLibrary,serialization,,)) +$(eval $(call DefineBoostLibrary,signals,,)) +$(eval $(call DefineBoostLibrary,system,,)) +$(eval $(call DefineBoostLibrary,thread,system chrono atomic,)) +$(eval $(call DefineBoostLibrary,timer,chrono)) +$(eval $(call DefineBoostLibrary,wave,date_time thread filesystem,)) + define Host/Compile # bjam does not provide a configure-script nor a Makefile ( cd $(HOST_BUILD_DIR)/tools/build/src/engine ; ./build.sh gcc ) @@ -231,26 +176,22 @@ CONFIGURE_PREFIX:=$(PKG_INSTALL_DIR) TARGET_LDFLAGS += -pthread -lrt - - ifneq ($(findstring mips,$(ARCH)),) - ifeq ($(ARCH),mips64) - BOOST_ABI = 64 - else ifeq ($(ARCH),octeon) - BOOST_ABI = 64 - else - BOOST_ABI = o32 + BOOST_ABI = o32 + ifneq ($(findstring 64,$(ARCH)),) + BOOST_ABI = o64 endif -else ifeq ($(ARCH),arm) - BOOST_ABI = aapcs +else ifneq ($(findstring arm,$(ARCH)),) + BOOST_ABI = aapcs +else ifeq ($(ARCH),aarch64) + BOOST_ABI = aapcs else - BOOST_ABI = sysv + BOOST_ABI = sysv endif - define Build/Compile - echo "Selected Boost API $(BOOST_ABI) for architecture $(ARCH) and cpu $(CPU_TYPE) $(CPU_SUBTYPE)"; + $(info Selected Boost API $(BOOST_ABI) for architecture $(ARCH) and cpu $(CPU_TYPE) $(CPU_SUBTYPE)) ( cd $(PKG_BUILD_DIR) ; \ echo "using gcc : $(ARCH) : $(GNU_TARGET_NAME)-gcc : \"$(TARGET_CFLAGS)\" \"$(TARGET_CXXFLAGS)\" \"$(TARGET_LDFLAGS)\" ;" > tools/build/src/user-config.jam ; \ $(if $(CONFIG_PACKAGE_boost-python), \ @@ -262,33 +203,13 @@ define Build/Compile --toolset=gcc-$(ARCH) --build-type=minimal --layout=system abi=$(BOOST_ABI) \ --disable-long-double \ $(CONFIGURE_ARGS) \ - $(if $(CONFIG_PACKAGE_boost-atomic),,--without-atomic) \ - $(if $(CONFIG_PACKAGE_boost-chrono),,--without-chrono) \ - $(if $(CONFIG_PACKAGE_boost-date_time),,--without-date_time) \ - $(if $(CONFIG_PACKAGE_boost-exception),,--without-exception) \ - $(if $(CONFIG_PACKAGE_boost-filesystem),,--without-filesystem) \ - $(if $(CONFIG_PACKAGE_boost-graph),,--without-graph) \ - $(if $(CONFIG_PACKAGE_boost-graph_parallel),,--without-graph_parallel) \ - $(if $(CONFIG_PACKAGE_boost-iostreams),,--without-iostreams) \ - $(if $(CONFIG_PACKAGE_boost-locale),boost.locale.iconv=on -sICONV_PATH=$(ICONV_PREFIX) boost.locale.posix=$(if $(USE_UCLIBC),on,off), \ - --without-locale boost.locale.iconv=off) \ - $(if $(CONFIG_PACKAGE_boost-math),,--without-math) \ - $(if $(CONFIG_PACKAGE_boost-mpi),,--without-mpi) \ - $(if $(CONFIG_PACKAGE_boost-program_options),,--without-program_options) \ - $(if $(CONFIG_PACKAGE_boost-python),,--without-python) \ - $(if $(CONFIG_PACKAGE_boost-random),,--without-random) \ - $(if $(CONFIG_PACKAGE_boost-regex),,--without-regex) \ - $(if $(CONFIG_PACKAGE_boost-serialization),,--without-serialization) \ - $(if $(CONFIG_PACKAGE_boost-signals),,--without-signals) \ - $(if $(CONFIG_PACKAGE_boost-system),,--without-system) \ + --without-mpi \ $(if $(CONFIG_PACKAGE_boost-test),,--without-test) \ - $(if $(CONFIG_PACKAGE_boost-thread),,--without-thread) \ - $(if $(CONFIG_PACKAGE_boost-timer),,--without-timer) \ - $(if $(CONFIG_PACKAGE_boost-wave),,--without-wave) \ - $(if $(CONFIG_PACKAGE_boost-context),,--without-context) \ - $(if $(CONFIG_PACKAGE_boost-container),,--without-container) \ - $(if $(CONFIG_PACKAGE_boost-coroutine),,--without-coroutine) \ - $(if $(CONFIG_PACKAGE_boost-log),,--without-log) \ + $(foreach lib,$(BOOST_LIBS), \ + $(if $(CONFIG_PACKAGE_boost-$(lib)),,--without-$(lib)) \ + ) \ + $(if $(CONFIG_PACKAGE_boost-locale),boost.locale.iconv=on -sICONV_PATH=$(ICONV_PREFIX) boost.locale.posix=$(if $(USE_UCLIBC),on,off), \ + boost.locale.iconv=off) \ \ $(if $(CONFIG_PACKAGE_boost-iostreams),-sNO_BZIP2=1 -sZLIB_INCLUDE=$(STAGING_DIR)/usr/include \ -sZLIB_LIBPATH=$(STAGING_DIR)/usr/lib) \ @@ -335,74 +256,6 @@ define Package/boost/Default/install $(1)/usr/lib/ endef -define Package/boost-atomic/install - $(call Package/boost/Default/install,$(1),atomic) -endef - -define Package/boost-chrono/install - $(call Package/boost/Default/install,$(1),chrono) -endef - -define Package/boost-date_time/install - $(call Package/boost/Default/install,$(1),date_time) -endef - -define Package/boost-exception/install - $(call Package/boost/Default/install,$(1),exception) -endef - -define Package/boost-filesystem/install - $(call Package/boost/Default/install,$(1),filesystem) -endef - -define Package/boost-graph/install - $(call Package/boost/Default/install,$(1),graph) -endef - -define Package/boost-graph_parallel/install - $(call Package/boost/Default/install,$(1),graph_parallel) -endef - -define Package/boost-iostreams/install - $(call Package/boost/Default/install,$(1),iostreams) -endef - -define Package/boost-math/install - $(call Package/boost/Default/install,$(1),math) -endef - -define Package/boost-mpi/install - $(call Package/boost/Default/install,$(1),mpi) -endef - -define Package/boost-program_options/install - $(call Package/boost/Default/install,$(1),program_options) -endef - -define Package/boost-python/install - $(call Package/boost/Default/install,$(1),python) -endef - -define Package/boost-random/install - $(call Package/boost/Default/install,$(1),random) -endef - -define Package/boost-regex/install - $(call Package/boost/Default/install,$(1),regex) -endef - -define Package/boost-serialization/install - $(call Package/boost/Default/install,$(1),serialization) -endef - -define Package/boost-signals/install - $(call Package/boost/Default/install,$(1),signals) -endef - -define Package/boost-system/install - $(call Package/boost/Default/install,$(1),system) -endef - define Package/boost-test/install $(INSTALL_DIR) \ $(1)/usr/lib @@ -416,61 +269,18 @@ define Package/boost-test/install $(1)/usr/lib/ endef -define Package/boost-thread/install - $(call Package/boost/Default/install,$(1),thread) -endef +define BuildBoostLibrary + define Package/boost-$(1)/install + $(call Package/boost/Default/install,$$(1),$(1)) + endef -define Package/boost-timer/install - $(call Package/boost/Default/install,$(1),timer) -endef - -define Package/boost-wave/install - $(call Package/boost/Default/install,$(1),wave) -endef - -define Package/boost-context/install - $(call Package/boost/Default/install,$(1),context) -endef - -define Package/boost-container/install - $(call Package/boost/Default/install,$(1),container) -endef - -define Package/boost-coroutine/install - $(call Package/boost/Default/install,$(1),coroutine) -endef - -define Package/boost-log/install - $(call Package/boost/Default/install,$(1),log) + $$(eval $$(call BuildPackage,boost-$(1))) endef +$(eval $(call HostBuild)) +$(foreach lib,$(BOOST_LIBS),$(eval $(call BuildBoostLibrary,$(lib)))) +$(eval $(call BuildPackage,boost-test)) -$(eval $(call HostBuild)) +$(eval $(call BuildPackage,boost-libs)) $(eval $(call BuildPackage,boost)) -$(eval $(call BuildPackage,boost-atomic)) -$(eval $(call BuildPackage,boost-chrono)) -$(eval $(call BuildPackage,boost-date_time)) -#$(eval $(call BuildPackage,boost-exception)) -$(eval $(call BuildPackage,boost-filesystem)) -$(eval $(call BuildPackage,boost-graph)) -#$(eval $(call BuildPackage,boost-graph_parallel)) -$(eval $(call BuildPackage,boost-iostreams)) -$(eval $(call BuildPackage,boost-locale)) -$(eval $(call BuildPackage,boost-math)) -#$(eval $(call BuildPackage,boost-mpi)) -$(eval $(call BuildPackage,boost-program_options)) -$(eval $(call BuildPackage,boost-random)) -$(eval $(call BuildPackage,boost-python)) -$(eval $(call BuildPackage,boost-regex)) -$(eval $(call BuildPackage,boost-serialization)) -$(eval $(call BuildPackage,boost-signals)) -$(eval $(call BuildPackage,boost-system)) -$(eval $(call BuildPackage,boost-test)) -$(eval $(call BuildPackage,boost-thread)) -$(eval $(call BuildPackage,boost-timer)) -$(eval $(call BuildPackage,boost-wave)) -$(eval $(call BuildPackage,boost-context)) -$(eval $(call BuildPackage,boost-container)) -$(eval $(call BuildPackage,boost-coroutine)) -$(eval $(call BuildPackage,boost-log)) diff --git a/libs/boost/patches/001-mips-options-fix.patch b/libs/boost/patches/001-mips-options-fix.patch new file mode 100644 index 000000000..d9b30e6e9 --- /dev/null +++ b/libs/boost/patches/001-mips-options-fix.patch @@ -0,0 +1,11 @@ +--- boost_1_58_0/tools/build/src/tools/gcc.jam 2015-04-23 12:01:37.723438995 +0200 ++++ boost_1_58_0/tools/build/src/tools/gcc.jam 2015-04-23 12:00:21.427441384 +0200 +@@ -451,7 +451,7 @@ + else + { + local arch = [ feature.get-values architecture : $(properties) ] ; +- if $(arch) != arm ++ if $(arch) = power || $(arch) = sparc || $(arch) = x86 + { + if $(model) = 32 + { diff --git a/libs/boost/patches/100-do-not-use-librt.patch b/libs/boost/patches/100-do-not-use-librt.patch deleted file mode 100644 index a7560c6f3..000000000 --- a/libs/boost/patches/100-do-not-use-librt.patch +++ /dev/null @@ -1,28 +0,0 @@ -Index: boost_1_57_0/tools/build/src/tools/gcc.jam -=================================================================== ---- boost_1_57_0.orig/tools/build/src/tools/gcc.jam -+++ boost_1_57_0/tools/build/src/tools/gcc.jam -@@ -1037,7 +1037,7 @@ rule setup-threading ( targets * : sourc - case *bsd : option = -pthread ; # There is no -lrt on BSD. - case sgi : # gcc on IRIX does not support multi-threading. - case darwin : # No threading options. -- case * : option = -pthread ; libs = rt ; -+ case * : # pass appropriate options via OpenWrt - } - - if $(option) -Index: boost_1_57_0/tools/build/src/tools/gcc.py -=================================================================== ---- boost_1_57_0.orig/tools/build/src/tools/gcc.py -+++ boost_1_57_0/tools/build/src/tools/gcc.py -@@ -700,8 +700,8 @@ elif bjam.variable('UNIX'): - # Darwin has no threading options, don't set anything here. - pass - else: -- flags('gcc', 'OPTIONS', ['multi'], ['-pthread']) -- flags('gcc', 'FINDLIBS-SA', [], ['rt']) -+ # pass appropriate options via OpenWrt -+ pass - - def cpu_flags(toolset, variable, architecture, instruction_set, values, default=None): - #FIXME: for some reason this fails. Probably out of date feature code diff --git a/libs/c-ares/Makefile b/libs/c-ares/Makefile index 815a379a3..c5b226997 100644 --- a/libs/c-ares/Makefile +++ b/libs/c-ares/Makefile @@ -22,6 +22,9 @@ PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk +TARGET_CPPFLAGS += $(filter -D%,$(TARGET_CFLAGS)) +TARGET_CFLAGS := $(filter-out -D%,$(TARGET_CFLAGS)) + define Package/libcares SECTION:=libs CATEGORY:=Libraries diff --git a/libs/db47/Makefile b/libs/db47/Makefile index 563d47c88..bf0f0b733 100644 --- a/libs/db47/Makefile +++ b/libs/db47/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2014 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -12,7 +12,7 @@ BASE_VERSION:=4.7.25 PKG_NAME:=db47 PKG_VERSION:=$(BASE_VERSION).4.NC -PKG_RELEASE:=3 +PKG_RELEASE:=5 PKG_BUILD_DIR:=$(BUILD_DIR)/db-$(BASE_VERSION).NC PKG_SOURCE:=db-$(BASE_VERSION).NC.tar.gz @@ -62,7 +62,7 @@ CONFIGURE_ARGS += \ --enable-shared \ --enable-static \ --disable-java \ - --with-mutex=UNIX/fcntl \ + --with-mutex=POSIX/pthreads/library \ --disable-tcl \ --disable-rpc \ --enable-compat185 \ diff --git a/libs/db47/patches/100-repmgr-format-security.patch b/libs/db47/patches/100-repmgr-format-security.patch new file mode 100644 index 000000000..58cfafdd0 --- /dev/null +++ b/libs/db47/patches/100-repmgr-format-security.patch @@ -0,0 +1,11 @@ +--- a/repmgr/repmgr_net.c ++++ b/repmgr/repmgr_net.c +@@ -1136,7 +1136,7 @@ __repmgr_listen(env) + } + + ret = net_errno; +- __db_err(env, ret, why); ++ __db_err(env, ret, "%s", why); + clean: if (s != INVALID_SOCKET) + (void)closesocket(s); + return (ret); diff --git a/libs/elfutils/Makefile b/libs/elfutils/Makefile deleted file mode 100644 index d3e1552c6..000000000 --- a/libs/elfutils/Makefile +++ /dev/null @@ -1,97 +0,0 @@ -# -# Copyright (C) 2010-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:=elfutils -PKG_VERSION:=0.161 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=http://fedorahosted.org/releases/e/l/$(PKG_NAME)/$(PKG_VERSION) -PKG_MD5SUM:=e1b9847c9a6a1ad340de8d47a863ec52 -PKG_MAINTAINER:=Luiz Angelo Daros de Luca -PKG_LICENSE:=GPL-3.0+ -PKG_LICENSE_FILES:=COPYING COPYING-GPLV2 COPYING-LGPLV3 - -PKG_INSTALL:=1 -PKG_USE_MIPS16:=0 - -PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone USE_MUSL:argp-standalone - -include $(INCLUDE_DIR)/package.mk -include $(INCLUDE_DIR)/nls.mk - -define Package/elfutils/Default - SECTION:=libs - CATEGORY:=Libraries - DEPENDS:=$(INTL_DEPENDS) - TITLE:=ELF manipulation libraries - URL:=https://fedorahosted.org/elfutils/ -endef - -define Package/libasm - $(call Package/elfutils/Default) - TITLE+= (libasm) - DEPENDS:=libelf1 -endef - -define Package/libdw - $(call Package/elfutils/Default) - DEPENDS:=libelf1 +zlib +libbz2 - TITLE+= (libdw) -endef - -define Package/libelf1 - $(call Package/elfutils/Default) - TITLE+= (libelf) -endef - -ifeq ($(CONFIG_BUILD_NLS),y) -TARGET_LDFLAGS += "-lintl" -endif - -ifdef CONFIG_USE_UCLIBC -CONFIGURE_VARS += \ - LIBS="-largp" -endif - -ifdef CONFIG_USE_MUSL -CONFIGURE_VARS += \ - LIBS="-largp" -endif - -CONFIGURE_ARGS += \ - --disable-werror \ - --without-lzma - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/include - $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/libasm/libasm.{a,so*} $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/libdw/libdw.{a,so*} $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/libelf/libelf.{a,so*} $(1)/usr/lib/ -endef - -define Package/libasm/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/libasm/libasm.so* $(1)/usr/lib/ -endef - -define Package/libdw/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/libdw/libdw.so* $(1)/usr/lib/ -endef - -define Package/libelf1/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/libelf/libelf.so* $(1)/usr/lib/ -endef - -$(eval $(call BuildPackage,libasm)) -$(eval $(call BuildPackage,libdw)) -$(eval $(call BuildPackage,libelf1)) diff --git a/libs/elfutils/patches/001-elfutils-portability.patch b/libs/elfutils/patches/001-elfutils-portability.patch deleted file mode 100644 index 7539f8bb6..000000000 --- a/libs/elfutils/patches/001-elfutils-portability.patch +++ /dev/null @@ -1,1871 +0,0 @@ ---- elfutils/backends/ChangeLog -+++ elfutils/backends/ChangeLog -@@ -433,6 +433,10 @@ - * ppc_attrs.c (ppc_check_object_attribute): Handle tag - GNU_Power_ABI_Struct_Return. - -+2009-01-23 Roland McGrath -+ -+ * Makefile.am (libebl_%.so): Use $(LD_AS_NEEDED). -+ - 2008-10-04 Ulrich Drepper - - * i386_reloc.def: Fix entries for TLS_GOTDESC, TLS_DESC_CALL, and -@@ -760,6 +764,11 @@ - * sparc_init.c: Likewise. - * x86_64_init.c: Likewise. - -+2005-11-22 Roland McGrath -+ -+ * Makefile.am (LD_AS_NEEDED): New variable, substituted by configure. -+ (libebl_%.so rule): Use it in place of -Wl,--as-needed. -+ - 2005-11-19 Roland McGrath - - * ppc64_reloc.def: REL30 -> ADDR30. -@@ -782,6 +791,9 @@ - * Makefile.am (uninstall): Don't try to remove $(pkgincludedir). - (CLEANFILES): Add libebl_$(m).so. - -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - * ppc_reloc.def: Update bits per Alan Modra . - * ppc64_reloc.def: Likewise. - ---- elfutils/backends/Makefile.am -+++ elfutils/backends/Makefile.am -@@ -119,7 +119,7 @@ libebl_%.so libebl_%.map: libebl_%_pic.a - $(LINK) -shared -o $(@:.map=.so) \ - -Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \ - -Wl,--version-script,$(@:.so=.map) \ -- -Wl,-z,defs -Wl,--as-needed $(libelf) $(libdw) -+ -Wl,-z,defs $(LD_AS_NEEDED) $(libelf) $(libdw) - @$(textrel_check) - - libebl_i386.so: $(cpu_i386) ---- elfutils/backends/Makefile.in -+++ elfutils/backends/Makefile.in -@@ -83,6 +83,7 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - subdir = backends - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -285,6 +286,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -316,6 +318,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -378,11 +381,11 @@ zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(top_srcdir)/libebl -I$(top_srcdir)/libasm \ - -I$(top_srcdir)/libelf -I$(top_srcdir)/libdw --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(foreach m,$(modules), libebl_$(m).map \ - libebl_$(m).so $(am_libebl_$(m)_pic_a_OBJECTS)) -@@ -888,7 +891,7 @@ libebl_%.so libebl_%.map: libebl_%_pic.a - $(LINK) -shared -o $(@:.map=.so) \ - -Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \ - -Wl,--version-script,$(@:.so=.map) \ -- -Wl,-z,defs -Wl,--as-needed $(libelf) $(libdw) -+ -Wl,-z,defs $(LD_AS_NEEDED) $(libelf) $(libdw) - @$(textrel_check) - - libebl_i386.so: $(cpu_i386) ---- elfutils/ChangeLog -+++ elfutils/ChangeLog -@@ -187,6 +187,8 @@ - - 2012-01-24 Mark Wielaard - -+ * configure.ac: Wrap AC_COMPILE_IFELSE sources in AC_LANG_SOURCE. -+ - * COPYING: Fix address. Updated version from gnulib. - - 2012-01-23 Mark Wielaard -@@ -205,6 +207,9 @@ - - 2011-10-08 Mike Frysinger - -+ * configure.ac (--disable-werror): Handle it, controlling BUILD_WERROR -+ automake option. -+ - * configure.ac: Fix use of AC_ARG_ENABLE to handle $enableval correctly. - - 2011-10-02 Ulrich Drepper -@@ -226,6 +231,10 @@ - - * configure.ac (LOCALEDIR, DATADIRNAME): Removed. - -+2009-11-22 Roland McGrath -+ -+ * configure.ac: Use sed and expr instead of modern bash extensions. -+ - 2009-09-21 Ulrich Drepper - - * configure.ac: Update for more modern autoconf. -@@ -234,6 +243,10 @@ - - * configure.ac (zip_LIBS): Check for liblzma too. - -+2009-08-17 Roland McGrath -+ -+ * configure.ac: Check for -fgnu89-inline; add it to WEXTRA if it works. -+ - 2009-04-19 Roland McGrath - - * configure.ac (eu_version): Round down here, not in version.h macros. -@@ -245,6 +258,8 @@ - - 2009-01-23 Roland McGrath - -+ * configure.ac: Check for __builtin_popcount. -+ - * configure.ac (zlib check): Check for gzdirect, need zlib >= 1.2.2.3. - - * configure.ac (__thread check): Use AC_LINK_IFELSE, in case of -@@ -325,6 +340,10 @@ - * configure.ac: Add dummy automake conditional to get dependencies - for non-generic linker right. See src/Makefile.am. - -+2005-11-22 Roland McGrath -+ -+ * configure.ac: Check for --as-needed linker option. -+ - 2005-11-18 Roland McGrath - - * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): New variable. -@@ -372,6 +391,17 @@ - * Makefile.am (all_SUBDIRS): Add libdwfl. - * configure.ac: Write libdwfl/Makefile. - -+2005-05-31 Roland McGrath -+ -+ * configure.ac (WEXTRA): Check for -Wextra and set this substitution. -+ -+ * configure.ac: Check for struct stat st_?tim members. -+ * src/strip.c (process_file): Use st_?time if st_?tim are not there. -+ -+ * configure.ac: Check for futimes function. -+ * src/strip.c (handle_elf) [! HAVE_FUTIMES]: Use utimes instead. -+ (handle_ar) [! HAVE_FUTIMES]: Likewise. -+ - 2005-05-19 Roland McGrath - - * configure.ac [AH_BOTTOM] (INTDECL, _INTDECL): New macros. ---- elfutils/config/ChangeLog -+++ elfutils/config/ChangeLog -@@ -71,6 +71,10 @@ - - * known-dwarf.awk: Use gawk. - -+2011-10-08 Mike Frysinger -+ -+ * eu.am [BUILD_WERROR]: Conditionalize -Werror use on this. -+ - 2010-07-02 Ulrich Drepper - - * elfutils.spec.in: Add more BuildRequires. ---- elfutils/config/eu.am -+++ elfutils/config/eu.am -@@ -1,6 +1,6 @@ - ## Common automake fragments for elfutils subdirectory makefiles. - ## --## Copyright (C) 2010, 2014 Red Hat, Inc. -+## Copyright (C) 2010-2011, 2014 Red Hat, Inc. - ## - ## This file is part of elfutils. - ## -@@ -29,13 +29,21 @@ - ## not, see . - ## - -+WEXTRA = @WEXTRA@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ -+ - DEFS = -D_GNU_SOURCE -DHAVE_CONFIG_H -DLOCALEDIR='"${localedir}"' - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow \ - $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -+ $(if $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) \ -+ $(if $($(*F)_no_Wformat),-Wno-format,-Wformat=2) \ - $($(*F)_CFLAGS) - -+if BUILD_WERROR -+AM_CFLAGS += $(if $($(*F)_no_Werror),,-Werror) -+endif -+ - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - - %.os: %.c %.o ---- elfutils/config/Makefile.in -+++ elfutils/config/Makefile.in -@@ -147,6 +147,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -178,6 +179,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ ---- elfutils/config.h.in -+++ elfutils/config.h.in -@@ -3,6 +3,9 @@ - /* Should ar and ranlib use -D behavior by default? */ - #undef DEFAULT_AR_DETERMINISTIC - -+/* Have __builtin_popcount. */ -+#undef HAVE_BUILTIN_POPCOUNT -+ - /* Define to 1 if you have the header file. */ - #undef HAVE_INTTYPES_H - -@@ -102,4 +105,7 @@ - /* Define for large files, on AIX-style hosts. */ - #undef _LARGE_FILES - -+/* Stubbed out if missing compiler support. */ -+#undef __thread -+ - #include ---- elfutils/configure -+++ elfutils/configure -@@ -663,6 +663,8 @@ ZLIB_TRUE - LIBEBL_SUBDIR - TESTS_RPATH_FALSE - TESTS_RPATH_TRUE -+BUILD_WERROR_FALSE -+BUILD_WERROR_TRUE - BUILD_STATIC_FALSE - BUILD_STATIC_TRUE - USE_VALGRIND_FALSE -@@ -678,6 +680,8 @@ NEVER_TRUE - base_cpu - NATIVE_LD_FALSE - NATIVE_LD_TRUE -+LD_AS_NEEDED -+WEXTRA - NM - READELF - ac_ct_AR -@@ -798,6 +802,7 @@ enable_debugpred - enable_gprof - enable_gcov - enable_valgrind -+enable_werror - enable_tests_rpath - enable_libebl_subdir - with_zlib -@@ -1455,6 +1460,7 @@ Optional Features: - --enable-gprof build binaries with gprof support - --enable-gcov build binaries with gcov support - --enable-valgrind run all tests under valgrind -+ --disable-werror do not build with -Werror - --enable-tests-rpath build $ORIGIN-using rpath into tests - --enable-libebl-subdir=DIR - install libebl_CPU modules in $(libdir)/DIR -@@ -4843,6 +4849,130 @@ if test "x$ac_cv_c99" != xyes; then : - as_fn_error $? "gcc with C99 support required" "$LINENO" 5 - fi - -+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wextra option to $CC" >&5 -+$as_echo_n "checking for -Wextra option to $CC... " >&6; } -+if ${ac_cv_cc_wextra+:} false; then : -+ $as_echo_n "(cached) " >&6 -+else -+ old_CFLAGS="$CFLAGS" -+CFLAGS="$CFLAGS -Wextra" -+cat confdefs.h - <<_ACEOF >conftest.$ac_ext -+/* end confdefs.h. */ -+void foo (void) { } -+_ACEOF -+if ac_fn_c_try_compile "$LINENO"; then : -+ ac_cv_cc_wextra=yes -+else -+ ac_cv_cc_wextra=no -+fi -+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -+CFLAGS="$old_CFLAGS" -+fi -+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_wextra" >&5 -+$as_echo "$ac_cv_cc_wextra" >&6; } -+ -+if test "x$ac_cv_cc_wextra" = xyes; then : -+ WEXTRA=-Wextra -+else -+ WEXTRA=-W -+fi -+ -+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fgnu89-inline option to $CC" >&5 -+$as_echo_n "checking for -fgnu89-inline option to $CC... " >&6; } -+if ${ac_cv_cc_gnu89_inline+:} false; then : -+ $as_echo_n "(cached) " >&6 -+else -+ old_CFLAGS="$CFLAGS" -+CFLAGS="$CFLAGS -fgnu89-inline -Werror" -+cat confdefs.h - <<_ACEOF >conftest.$ac_ext -+/* end confdefs.h. */ -+ -+void foo (void) -+{ -+ inline void bar (void) {} -+ bar (); -+} -+extern inline void baz (void) {} -+ -+_ACEOF -+if ac_fn_c_try_compile "$LINENO"; then : -+ ac_cv_cc_gnu89_inline=yes -+else -+ ac_cv_cc_gnu89_inline=no -+fi -+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -+CFLAGS="$old_CFLAGS" -+fi -+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_gnu89_inline" >&5 -+$as_echo "$ac_cv_cc_gnu89_inline" >&6; } -+if test "x$ac_cv_cc_gnu89_inline" = xyes; then : -+ WEXTRA="${WEXTRA:+$WEXTRA }-fgnu89-inline" -+fi -+ -+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --as-needed linker option" >&5 -+$as_echo_n "checking for --as-needed linker option... " >&6; } -+if ${ac_cv_as_needed+:} false; then : -+ $as_echo_n "(cached) " >&6 -+else -+ cat > conftest.c <&5 -+ (eval $ac_try) 2>&5 -+ ac_status=$? -+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 -+ test $ac_status = 0; }; } -+then -+ ac_cv_as_needed=yes -+else -+ ac_cv_as_needed=no -+fi -+rm -f conftest* -+fi -+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_as_needed" >&5 -+$as_echo "$ac_cv_as_needed" >&6; } -+if test "x$ac_cv_as_needed" = xyes; then : -+ LD_AS_NEEDED=-Wl,--as-needed -+else -+ LD_AS_NEEDED= -+fi -+ -+ -+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_popcount" >&5 -+$as_echo_n "checking for __builtin_popcount... " >&6; } -+if ${ac_cv_popcount+:} false; then : -+ $as_echo_n "(cached) " >&6 -+else -+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext -+/* end confdefs.h. */ -+ -+int -+main () -+{ -+exit (__builtin_popcount (127)); -+ ; -+ return 0; -+} -+_ACEOF -+if ac_fn_c_try_link "$LINENO"; then : -+ ac_cv_popcount=yes -+else -+ ac_cv_popcount=no -+fi -+rm -f core conftest.err conftest.$ac_objext \ -+ conftest$ac_exeext conftest.$ac_ext -+fi -+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_popcount" >&5 -+$as_echo "$ac_cv_popcount" >&6; } -+if test "x$ac_cv_popcount" = xyes; then : -+ -+$as_echo "#define HAVE_BUILTIN_POPCOUNT 1" >>confdefs.h -+ -+fi -+ - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread support" >&5 - $as_echo_n "checking for __thread support... " >&6; } - if ${ac_cv_tls+:} false; then : -@@ -4879,7 +5009,13 @@ fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5 - $as_echo "$ac_cv_tls" >&6; } - if test "x$ac_cv_tls" != xyes; then : -- as_fn_error $? "__thread support required" "$LINENO" 5 -+ if test "$use_locks" = yes; then : -+ as_fn_error $? "--enable-thread-safety requires __thread support" "$LINENO" 5 -+else -+ -+$as_echo "#define __thread /* empty: no multi-thread support */" >>confdefs.h -+ -+fi - fi - - # Check whether --enable-largefile was given. -@@ -5246,6 +5382,22 @@ else - fi - - -+# Check whether --enable-werror was given. -+if test "${enable_werror+set}" = set; then : -+ enableval=$enable_werror; enable_werror=$enableval -+else -+ enable_werror=yes -+fi -+ -+ if test "$enable_werror" = yes; then -+ BUILD_WERROR_TRUE= -+ BUILD_WERROR_FALSE='#' -+else -+ BUILD_WERROR_TRUE='#' -+ BUILD_WERROR_FALSE= -+fi -+ -+ - # Check whether --enable-tests-rpath was given. - if test "${enable_tests_rpath+set}" = set; then : - enableval=$enable_tests_rpath; tests_use_rpath=$enableval -@@ -5983,7 +6135,7 @@ case "$eu_version" in - esac - - # Round up to the next release API (x.y) version. --eu_version=$(( (eu_version + 999) / 1000 )) -+eu_version=`expr \( $eu_version + 999 \) / 1000` - - ac_ext=c - ac_cpp='$CPP $CPPFLAGS' -@@ -6729,6 +6881,10 @@ if test -z "${BUILD_STATIC_TRUE}" && tes - as_fn_error $? "conditional \"BUILD_STATIC\" was never defined. - Usually this means the macro was only invoked conditionally." "$LINENO" 5 - fi -+if test -z "${BUILD_WERROR_TRUE}" && test -z "${BUILD_WERROR_FALSE}"; then -+ as_fn_error $? "conditional \"BUILD_WERROR\" was never defined. -+Usually this means the macro was only invoked conditionally." "$LINENO" 5 -+fi - if test -z "${TESTS_RPATH_TRUE}" && test -z "${TESTS_RPATH_FALSE}"; then - as_fn_error $? "conditional \"TESTS_RPATH\" was never defined. - Usually this means the macro was only invoked conditionally." "$LINENO" 5 ---- elfutils/configure.ac -+++ elfutils/configure.ac -@@ -89,6 +89,54 @@ CFLAGS="$old_CFLAGS"]) - AS_IF([test "x$ac_cv_c99" != xyes], - AC_MSG_ERROR([gcc with C99 support required])) - -+AC_CACHE_CHECK([for -Wextra option to $CC], ac_cv_cc_wextra, [dnl -+old_CFLAGS="$CFLAGS" -+CFLAGS="$CFLAGS -Wextra" -+AC_COMPILE_IFELSE([AC_LANG_SOURCE([void foo (void) { }])], -+ ac_cv_cc_wextra=yes, ac_cv_cc_wextra=no) -+CFLAGS="$old_CFLAGS"]) -+AC_SUBST(WEXTRA) -+AS_IF([test "x$ac_cv_cc_wextra" = xyes], [WEXTRA=-Wextra], [WEXTRA=-W]) -+ -+AC_CACHE_CHECK([for -fgnu89-inline option to $CC], ac_cv_cc_gnu89_inline, [dnl -+old_CFLAGS="$CFLAGS" -+CFLAGS="$CFLAGS -fgnu89-inline -Werror" -+AC_COMPILE_IFELSE([AC_LANG_SOURCE([ -+void foo (void) -+{ -+ inline void bar (void) {} -+ bar (); -+} -+extern inline void baz (void) {} -+])], ac_cv_cc_gnu89_inline=yes, ac_cv_cc_gnu89_inline=no) -+CFLAGS="$old_CFLAGS"]) -+AS_IF([test "x$ac_cv_cc_gnu89_inline" = xyes], -+ [WEXTRA="${WEXTRA:+$WEXTRA }-fgnu89-inline"]) -+ -+AC_CACHE_CHECK([for --as-needed linker option], -+ ac_cv_as_needed, [dnl -+cat > conftest.c <&AS_MESSAGE_LOG_FD]) -+then -+ ac_cv_as_needed=yes -+else -+ ac_cv_as_needed=no -+fi -+rm -f conftest*]) -+AS_IF([test "x$ac_cv_as_needed" = xyes], -+ [LD_AS_NEEDED=-Wl,--as-needed], [LD_AS_NEEDED=]) -+AC_SUBST(LD_AS_NEEDED) -+ -+AC_CACHE_CHECK([for __builtin_popcount], ac_cv_popcount, [dnl -+AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[exit (__builtin_popcount (127));]])], -+ ac_cv_popcount=yes, ac_cv_popcount=no)]) -+AS_IF([test "x$ac_cv_popcount" = xyes], -+ [AC_DEFINE([HAVE_BUILTIN_POPCOUNT], [1], [Have __builtin_popcount.])]) -+ - AC_CACHE_CHECK([for __thread support], ac_cv_tls, [dnl - # Use the same flags that we use for our DSOs, so the test is representative. - # Some old compiler/linker/libc combinations fail some ways and not others. -@@ -104,7 +152,10 @@ static __thread int a; int foo (int b) { - CFLAGS="$save_CFLAGS" - LDFLAGS="$save_LDFLAGS"]) - AS_IF([test "x$ac_cv_tls" != xyes], -- AC_MSG_ERROR([__thread support required])) -+ [AS_IF([test "$use_locks" = yes], -+ [AC_MSG_ERROR([--enable-thread-safety requires __thread support])], -+ [AC_DEFINE([__thread], [/* empty: no multi-thread support */], -+ [Stubbed out if missing compiler support.])])]) - - dnl This test must come as early as possible after the compiler configuration - dnl tests, because the choice of the file model can (in principle) affect -@@ -183,6 +234,11 @@ AM_CONDITIONAL(USE_VALGRIND, test "$use_ - AM_CONDITIONAL(BUILD_STATIC, [dnl - test "$use_gprof" = yes -o "$use_gcov" = yes]) - -+AC_ARG_ENABLE([werror], -+AS_HELP_STRING([--disable-werror],[do not build with -Werror]), -+ [enable_werror=$enableval], [enable_werror=yes]) -+AM_CONDITIONAL(BUILD_WERROR, test "$enable_werror" = yes) -+ - AC_ARG_ENABLE([tests-rpath], - AS_HELP_STRING([--enable-tests-rpath],[build $ORIGIN-using rpath into tests]), - [tests_use_rpath=$enableval], [tests_use_rpath=no]) -@@ -302,7 +358,7 @@ case "$eu_version" in - esac - - # Round up to the next release API (x.y) version. --eu_version=$(( (eu_version + 999) / 1000 )) -+eu_version=`expr \( $eu_version + 999 \) / 1000` - - AC_CHECK_SIZEOF(long) - ---- elfutils/lib/ChangeLog -+++ elfutils/lib/ChangeLog -@@ -65,6 +65,9 @@ - - 2009-01-23 Roland McGrath - -+ * eu-config.h [! HAVE_BUILTIN_POPCOUNT] -+ (__builtin_popcount): New inline function. -+ - * eu-config.h: Add multiple inclusion protection. - - 2009-01-17 Ulrich Drepper -@@ -121,6 +124,11 @@ - * Makefile.am (libeu_a_SOURCES): Add it. - * system.h: Declare crc32_file. - -+2005-02-07 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-04-30 Ulrich Drepper - - * Makefile.am: Use -ffunction-sections for xmalloc.c. ---- elfutils/lib/eu-config.h -+++ elfutils/lib/eu-config.h -@@ -162,6 +162,17 @@ asm (".section predict_data, \"aw\"; .pr - /* This macro is used by the tests conditionalize for standalone building. */ - #define ELFUTILS_HEADER(name) - -+#ifndef HAVE_BUILTIN_POPCOUNT -+# define __builtin_popcount hakmem_popcount -+static inline unsigned int __attribute__ ((unused)) -+hakmem_popcount (unsigned int x) -+{ -+ /* HAKMEM 169 */ -+ unsigned int n = x - ((x >> 1) & 033333333333) - ((x >> 2) & 011111111111); -+ return ((n + (n >> 3)) & 030707070707) % 63; -+} -+#endif /* HAVE_BUILTIN_POPCOUNT */ -+ - - #ifdef SHARED - # define OLD_VERSION(name, version) \ ---- elfutils/lib/Makefile.in -+++ elfutils/lib/Makefile.in -@@ -82,6 +82,7 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - subdir = lib - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -197,6 +198,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -228,6 +230,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -289,9 +292,11 @@ top_srcdir = @top_srcdir@ - zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(srcdir)/../libelf --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 $(if \ -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ - $($(*F)_no_Werror),,-Werror) $(if \ -- $($(*F)_no_Wunused),,-Wunused -Wextra) $($(*F)_CFLAGS) -fpic -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) -fpic - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda - textrel_msg = echo "WARNING: TEXTREL found in '$@'" ---- elfutils/libasm/ChangeLog -+++ elfutils/libasm/ChangeLog -@@ -87,6 +87,11 @@ - * asm_error.c: Add new error ASM_E_IOERROR. - * libasmP.h: Add ASM_E_IOERROR definition. - -+2005-05-31 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-02-15 Ulrich Drepper - - * Makefile.am (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2. ---- elfutils/libasm/Makefile.in -+++ elfutils/libasm/Makefile.in -@@ -83,8 +83,9 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) $(pkginclude_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - noinst_PROGRAMS = $(am__EXEEXT_1) --@USE_LOCKS_TRUE@am__append_1 = -lpthread -+@USE_LOCKS_TRUE@am__append_2 = -lpthread - subdir = libasm - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -248,6 +249,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -279,6 +281,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -341,11 +344,11 @@ zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(top_srcdir)/libelf -I$(top_srcdir)/libebl \ - -I$(top_srcdir)/libdw --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(am_libasm_pic_a_OBJECTS) \ - libasm.so.$(VERSION) -@@ -373,7 +376,7 @@ libasm_a_SOURCES = asm_begin.c asm_abort - - libasm_pic_a_SOURCES = - am_libasm_pic_a_OBJECTS = $(libasm_a_SOURCES:.c=.os) --libasm_so_LDLIBS = $(am__append_1) -+libasm_so_LDLIBS = $(am__append_2) - libasm_so_SOURCES = - noinst_HEADERS = libasmP.h symbolhash.h - EXTRA_DIST = libasm.map ---- elfutils/libcpu/ChangeLog -+++ elfutils/libcpu/ChangeLog -@@ -51,6 +51,9 @@ - - 2009-01-23 Roland McGrath - -+ * i386_disasm.c (i386_disasm): Add abort after assert-constant for old -+ compilers that don't realize it's noreturn. -+ - * Makefile.am (i386_parse_CFLAGS): Use quotes around command - substitution that can produce leading whitespace. - -@@ -380,6 +383,11 @@ - * defs/i386.doc: New file. - * defs/x86_64: New file. - -+2005-04-04 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it instead of -Wextra. -+ - 2005-02-15 Ulrich Drepper - - * Makefile (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2. ---- elfutils/libcpu/i386_disasm.c -+++ elfutils/libcpu/i386_disasm.c -@@ -822,6 +822,7 @@ i386_disasm (const uint8_t **startp, con - - default: - assert (! "INVALID not handled"); -+ abort (); - } - } - else ---- elfutils/libcpu/Makefile.in -+++ elfutils/libcpu/Makefile.in -@@ -84,6 +84,7 @@ DIST_COMMON = $(top_srcdir)/config/eu.am - $(srcdir)/Makefile.am i386_lex.c i386_parse.c \ - $(top_srcdir)/config/depcomp $(top_srcdir)/config/ylwrap \ - $(am__noinst_HEADERS_DIST) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - @MAINTAINER_MODE_TRUE@noinst_PROGRAMS = i386_gendis$(EXEEXT) - subdir = libcpu - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -@@ -223,6 +224,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = lex.$( -+ -+ * dwarf_begin_elf.c: Add fallback for be64toh if not defined. -+ - 2011-07-14 Mark Wielaard - - * libdw.h (dwarf_offdie): Fix documentation to mention .debug_info. -@@ -1076,6 +1080,10 @@ - - * dwarf_hasattr_integrate.c: Integrate DW_AT_specification too. - -+2009-08-17 Roland McGrath -+ -+ * libdw.h: Disable extern inlines for GCC 4.2. -+ - 2009-08-10 Roland McGrath - - * dwarf_getscopevar.c: Use dwarf_diename. -@@ -1844,6 +1852,11 @@ - - 2005-05-31 Roland McGrath - -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ -+2005-05-31 Roland McGrath -+ - * dwarf_formref_die.c (dwarf_formref_die): Add CU header offset to - formref offset. - ---- elfutils/libdw/dwarf_begin_elf.c -+++ elfutils/libdw/dwarf_begin_elf.c -@@ -47,6 +47,14 @@ - #if USE_ZLIB - # include - # define crc32 loser_crc32 -+# ifndef be64toh -+# include -+# if __BYTE_ORDER == __LITTLE_ENDIAN -+# define be64toh(x) bswap_64 (x) -+# else -+# define be64toh(x) (x) -+# endif -+# endif - # include - # undef crc32 - #endif ---- elfutils/libdw/libdw.h -+++ elfutils/libdw/libdw.h -@@ -1003,7 +1003,7 @@ extern Dwarf_OOM dwarf_new_oom_handler ( - - - /* Inline optimizations. */ --#ifdef __OPTIMIZE__ -+#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2) - /* Return attribute code of given attribute. */ - __libdw_extern_inline unsigned int - dwarf_whatattr (Dwarf_Attribute *attr) ---- elfutils/libdw/Makefile.in -+++ elfutils/libdw/Makefile.in -@@ -84,7 +84,8 @@ DIST_COMMON = $(top_srcdir)/config/eu.am - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(include_HEADERS) $(noinst_HEADERS) $(pkginclude_HEADERS) \ - ChangeLog --@BUILD_STATIC_TRUE@am__append_1 = -fpic -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) -+@BUILD_STATIC_TRUE@am__append_2 = -fpic - noinst_PROGRAMS = $(am__EXEEXT_1) - subdir = libdw - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -@@ -298,6 +299,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -329,6 +331,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -390,10 +393,11 @@ top_srcdir = @top_srcdir@ - zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(srcdir)/../libelf --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 $(if \ -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ - $($(*F)_no_Werror),,-Werror) $(if \ -- $($(*F)_no_Wunused),,-Wunused -Wextra) $($(*F)_CFLAGS) \ -- $(am__append_1) -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) $(am__append_2) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda - textrel_msg = echo "WARNING: TEXTREL found in '$@'" ---- elfutils/libdwelf/Makefile.in -+++ elfutils/libdwelf/Makefile.in -@@ -82,6 +82,7 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) $(pkginclude_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - subdir = libdwelf - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -227,6 +228,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -258,6 +260,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -320,11 +323,11 @@ zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(srcdir)/../libelf -I$(srcdir)/../libdw \ - -I$(srcdir)/../libdwfl -I$(srcdir)/../libebl --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(am_libdwelf_pic_a_OBJECTS) - textrel_msg = echo "WARNING: TEXTREL found in '$@'" ---- elfutils/libdwfl/ChangeLog -+++ elfutils/libdwfl/ChangeLog -@@ -571,6 +571,21 @@ - (dwfl_module_addrsym) (i_to_symfile): New function. - (dwfl_module_addrsym) (search_table): Use it. - -+2013-11-09 Jan Kratochvil -+ -+ Older OS compatibility bits. -+ * linux-core-attach.c (be64toh, le64toh, be32toh, le32toh): Provide -+ fallbacks if not defined by system. -+ -+2013-11-09 Jan Kratochvil -+ -+ Handle T-stopped detach for old kernels. -+ * linux-pid-attach.c (struct pid_arg): New field stopped. -+ (ptrace_attach): New parameter stoppedp. Set it appropriately. -+ (pid_set_initial_registers): Pass the new field. -+ (pid_thread_detach): Handle the case of STOPPED for old kernels. -+ (__libdwfl_attach_state_for_pid): Initialize STOPPED. -+ - 2013-11-07 Jan Kratochvil - Mark Wielaard - -@@ -2336,6 +2351,11 @@ - - 2005-07-21 Roland McGrath - -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ -+2005-07-21 Roland McGrath -+ - * Makefile.am (noinst_HEADERS): Add loc2c.c. - - * test2.c (main): Check sscanf result to quiet warning. ---- elfutils/libdwfl/linux-core-attach.c -+++ elfutils/libdwfl/linux-core-attach.c -@@ -29,6 +29,35 @@ - #include "libdwflP.h" - #include - #include "system.h" -+#include -+#include -+#if __BYTE_ORDER == __LITTLE_ENDIAN -+# ifndef be64toh -+# define be64toh(x) bswap_64 (x) -+# endif -+# ifndef le64toh -+# define le64toh(x) (x) -+# endif -+# ifndef be32toh -+# define be32toh(x) bswap_32 (x) -+# endif -+# ifndef le32toh -+# define le32toh(x) (x) -+# endif -+#else -+# ifndef be64toh -+# define be64toh(x) (x) -+# endif -+# ifndef le64toh -+# define le64toh(x) bswap_64 (x) -+# endif -+# ifndef be32toh -+# define be32toh(x) (x) -+# endif -+# ifndef le32toh -+# define le32toh(x) bswap_32 (x) -+# endif -+#endif - - #include "../libdw/memory-access.h" - ---- elfutils/libdwfl/linux-pid-attach.c -+++ elfutils/libdwfl/linux-pid-attach.c -@@ -255,6 +255,11 @@ void - internal_function - __libdwfl_ptrace_detach (pid_t tid, bool tid_was_stopped) - { -+ // Older kernels (tested kernel-2.6.18-348.12.1.el5.x86_64) need special -+ // handling of the detachment to keep the process State: T (stopped). -+ if (tid_was_stopped) -+ syscall (__NR_tkill, tid, SIGSTOP); -+ - /* This handling is needed only on older Linux kernels such as - 2.6.32-358.23.2.el6.ppc64. Later kernels such as - 3.11.7-200.fc19.x86_64 remember the T (stopped) state -@@ -262,6 +267,15 @@ __libdwfl_ptrace_detach (pid_t tid, bool - PTRACE_DETACH. */ - ptrace (PTRACE_DETACH, tid, NULL, - (void *) (intptr_t) (tid_was_stopped ? SIGSTOP : 0)); -+ -+ if (tid_was_stopped) -+ { -+ // Wait till the SIGSTOP settles down. -+ int i; -+ for (i = 0; i < 100000; i++) -+ if (linux_proc_pid_is_stopped (tid)) -+ break; -+ } - } - - static void ---- elfutils/libdwfl/Makefile.in -+++ elfutils/libdwfl/Makefile.in -@@ -82,9 +82,10 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) $(pkginclude_HEADERS) ChangeLog --@ZLIB_TRUE@am__append_1 = gzip.c --@BZLIB_TRUE@am__append_2 = bzip2.c --@LZMA_TRUE@am__append_3 = lzma.c -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) -+@ZLIB_TRUE@am__append_2 = gzip.c -+@BZLIB_TRUE@am__append_3 = bzip2.c -+@LZMA_TRUE@am__append_4 = lzma.c - subdir = libdwfl - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -286,6 +287,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -317,6 +319,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -379,11 +382,11 @@ zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. -I$(srcdir) \ - -I$(srcdir)/../libelf -I$(srcdir)/../libebl \ - -I$(srcdir)/../libdw -I$(srcdir)/../libdwelf --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(am_libdwfl_pic_a_OBJECTS) - textrel_msg = echo "WARNING: TEXTREL found in '$@'" -@@ -413,8 +416,8 @@ libdwfl_a_SOURCES = dwfl_begin.c dwfl_en - dwfl_module_register_names.c dwfl_segment_report_module.c \ - link_map.c core-file.c open.c image-header.c dwfl_frame.c \ - frame_unwind.c dwfl_frame_pc.c linux-pid-attach.c \ -- linux-core-attach.c dwfl_frame_regs.c $(am__append_1) \ -- $(am__append_2) $(am__append_3) -+ linux-core-attach.c dwfl_frame_regs.c $(am__append_2) \ -+ $(am__append_3) $(am__append_4) - libdwfl = $(libdw) - libdw = ../libdw/libdw.so - libelf = ../libelf/libelf.so ---- elfutils/libebl/ChangeLog -+++ elfutils/libebl/ChangeLog -@@ -765,6 +765,11 @@ - * Makefile.am (libebl_*_so_SOURCES): Set to $(*_SRCS) so dependency - tracking works right. - -+2005-05-31 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-05-21 Ulrich Drepper - - * libebl_x86_64.map: Add x86_64_core_note. ---- elfutils/libebl/Makefile.in -+++ elfutils/libebl/Makefile.in -@@ -82,6 +82,7 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(noinst_HEADERS) $(pkginclude_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - subdir = libebl - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -249,6 +250,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -280,6 +282,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -342,9 +345,11 @@ zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. \ - -I$(srcdir)/../libelf -I$(srcdir)/../libdw \ - -I$(srcdir)/../libasm --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 $(if \ -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ - $($(*F)_no_Werror),,-Werror) $(if \ -- $($(*F)_no_Wunused),,-Wunused -Wextra) $($(*F)_CFLAGS) -fpic -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) -fpic - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(am_libebl_pic_a_OBJECTS) - textrel_msg = echo "WARNING: TEXTREL found in '$@'" ---- elfutils/libelf/ChangeLog -+++ elfutils/libelf/ChangeLog -@@ -244,6 +244,11 @@ - - * elf-knowledge.h (SECTION_STRIP_P): Remove < SHT_NUM check. - -+2011-03-10 Roland McGrath -+ -+ * gnuhash_xlate.h (elf_cvt_gnuhash): Avoid post-increment in bswap_32 -+ argument, since some implementations are buggy macros. -+ - 2011-02-26 Mark Wielaard - - * elf_end.c (elf_end): Call rwlock_unlock before rwlock_fini. -@@ -921,6 +926,11 @@ - - * elf.h: Update from glibc. - -+2005-05-31 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-05-08 Roland McGrath - - * elf_begin.c (read_file) [_MUDFLAP]: Don't use mmap for now. ---- elfutils/libelf/common.h -+++ elfutils/libelf/common.h -@@ -139,7 +139,7 @@ libelf_release_all (Elf *elf) - (Var) = (sizeof (Var) == 1 \ - ? (unsigned char) (Var) \ - : (sizeof (Var) == 2 \ -- ? bswap_16 (Var) \ -+ ? (unsigned short int) bswap_16 (Var) \ - : (sizeof (Var) == 4 \ - ? bswap_32 (Var) \ - : bswap_64 (Var)))) -@@ -148,7 +148,7 @@ libelf_release_all (Elf *elf) - (Dst) = (sizeof (Var) == 1 \ - ? (unsigned char) (Var) \ - : (sizeof (Var) == 2 \ -- ? bswap_16 (Var) \ -+ ? (unsigned short int) bswap_16 (Var) \ - : (sizeof (Var) == 4 \ - ? bswap_32 (Var) \ - : bswap_64 (Var)))) ---- elfutils/libelf/gnuhash_xlate.h -+++ elfutils/libelf/gnuhash_xlate.h -@@ -1,5 +1,5 @@ - /* Conversion functions for versioning information. -- Copyright (C) 2006, 2007 Red Hat, Inc. -+ Copyright (C) 2006-2011 Red Hat, Inc. - This file is part of elfutils. - Written by Ulrich Drepper , 2006. - -@@ -68,7 +68,9 @@ elf_cvt_gnuhash (void *dest, const void - dest32 = (Elf32_Word *) &dest64[bitmask_words]; - while (len >= 4) - { -- *dest32++ = bswap_32 (*src32++); -+ *dest32 = bswap_32 (*src32); -+ ++dest32; -+ ++src32; - len -= 4; - } - } ---- elfutils/libelf/Makefile.in -+++ elfutils/libelf/Makefile.in -@@ -84,9 +84,10 @@ DIST_COMMON = $(top_srcdir)/config/eu.am - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(include_HEADERS) $(noinst_HEADERS) $(pkginclude_HEADERS) \ - ChangeLog --@BUILD_STATIC_TRUE@am__append_1 = -fpic -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) -+@BUILD_STATIC_TRUE@am__append_2 = -fpic - noinst_PROGRAMS = $(am__EXEEXT_1) --@USE_LOCKS_TRUE@am__append_2 = -lpthread -+@USE_LOCKS_TRUE@am__append_3 = -lpthread - subdir = libelf - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -291,6 +292,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -322,6 +324,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = 1 -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -382,10 +385,11 @@ top_builddir = @top_builddir@ - top_srcdir = @top_srcdir@ - zip_LIBS = @zip_LIBS@ - AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 $(if \ -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ - $($(*F)_no_Werror),,-Werror) $(if \ -- $($(*F)_no_Wunused),,-Wunused -Wextra) $($(*F)_CFLAGS) \ -- $(am__append_1) -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) $(am__append_2) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda $(am_libelf_pic_a_OBJECTS) \ - libelf.so.$(VERSION) -@@ -449,7 +453,7 @@ libelf_a_SOURCES = elf_version.c elf_has - - libelf_pic_a_SOURCES = - am_libelf_pic_a_OBJECTS = $(libelf_a_SOURCES:.c=.os) --libelf_so_LDLIBS = $(am__append_2) -+libelf_so_LDLIBS = $(am__append_3) - libelf_so_SOURCES = - noinst_HEADERS = elf.h abstract.h common.h exttypes.h gelf_xlate.h libelfP.h \ - version_xlate.h gnuhash_xlate.h note_xlate.h dl-hash.h ---- elfutils/m4/Makefile.in -+++ elfutils/m4/Makefile.in -@@ -145,6 +145,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -176,6 +177,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ ---- elfutils/Makefile.in -+++ elfutils/Makefile.in -@@ -263,6 +263,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -294,6 +295,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ ---- elfutils/src/addr2line.c -+++ elfutils/src/addr2line.c -@@ -540,10 +540,10 @@ handle_address (const char *string, Dwfl - bool parsed = false; - int i, j; - char *name = NULL; -- if (sscanf (string, "(%m[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2 -+ if (sscanf (string, "(%a[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2 - && string[i] == '\0') - parsed = adjust_to_section (name, &addr, dwfl); -- switch (sscanf (string, "%m[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j)) -+ switch (sscanf (string, "%a[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j)) - { - default: - break; ---- elfutils/src/ChangeLog -+++ elfutils/src/ChangeLog -@@ -1371,8 +1371,16 @@ - * readelf.c (attr_callback): Use print_block only when we don't use - print_ops. - -+2009-08-17 Roland McGrath -+ -+ * ld.h: Disable extern inlines for GCC 4.2. -+ - 2009-08-14 Roland McGrath - -+ * strings.c (read_block): Conditionalize posix_fadvise use -+ on [POSIX_FADV_SEQUENTIAL]. -+ From Petr Salinger . -+ - * ar.c (do_oper_extract): Use pathconf instead of statfs. - - 2009-08-01 Ulrich Drepper -@@ -1536,6 +1544,8 @@ - * readelf.c (print_debug_frame_section): Use t instead of j formats - for ptrdiff_t OFFSET. - -+ * addr2line.c (handle_address): Use %a instead of %m for compatibility. -+ - 2009-01-21 Ulrich Drepper - - * elflint.c (check_program_header): Fix typo in .eh_frame_hdr section -@@ -1719,6 +1729,11 @@ - that matches its PT_LOAD's p_flags &~ PF_W. On sparc, PF_X really - is valid in RELRO. - -+2008-03-01 Roland McGrath -+ -+ * readelf.c (dump_archive_index): Tweak portability hack -+ to match [__GNUC__ < 4] too. -+ - 2008-02-29 Roland McGrath - - * readelf.c (print_attributes): Add a cast. -@@ -1970,6 +1985,8 @@ - - * readelf.c (hex_dump): Fix rounding error in whitespace calculation. - -+ * Makefile.am (readelf_no_Werror): New variable. -+ - 2007-10-15 Roland McGrath - - * make-debug-archive.in: New file. -@@ -2409,6 +2426,10 @@ - * elflint.c (valid_e_machine): Add EM_ALPHA. - Reported by Christian Aichinger . - -+ * strings.c (map_file): Define POSIX_MADV_SEQUENTIAL to -+ MADV_SEQUENTIAL if undefined. Don't call posix_madvise -+ if neither is defined. -+ - 2006-08-08 Ulrich Drepper - - * elflint.c (check_dynamic): Don't require DT_HASH for DT_SYMTAB. -@@ -2485,6 +2506,10 @@ - * Makefile.am: Add hacks to create dependency files for non-generic - linker. - -+2006-04-05 Roland McGrath -+ -+ * strings.c (MAP_POPULATE): Define to 0 if undefined. -+ - 2006-06-12 Ulrich Drepper - - * ldgeneric.c (ld_generic_generate_sections): Don't create .interp -@@ -2833,6 +2858,11 @@ - * readelf.c (print_debug_loc_section): Fix indentation for larger - address size. - -+2005-05-31 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-05-30 Roland McGrath - - * readelf.c (print_debug_line_section): Print section offset of each ---- elfutils/src/findtextrel.c -+++ elfutils/src/findtextrel.c -@@ -502,7 +502,11 @@ ptrcompare (const void *p1, const void * - - - static void --check_rel (size_t nsegments, struct segments segments[nsegments], -+check_rel (size_t nsegments, struct segments segments[ -+#if __GNUC__ >= 4 -+ nsegments -+#endif -+ ], - GElf_Addr addr, Elf *elf, Elf_Scn *symscn, Dwarf *dw, - const char *fname, bool more_than_one, void **knownsrcs) - { ---- elfutils/src/ld.h -+++ elfutils/src/ld.h -@@ -1114,6 +1114,7 @@ extern bool dynamically_linked_p (void); - - /* Checked whether the symbol is undefined and referenced from a DSO. */ - extern bool linked_from_dso_p (struct scninfo *scninfo, size_t symidx); -+#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2) - #ifdef __GNUC_STDC_INLINE__ - __attribute__ ((__gnu_inline__)) - #endif -@@ -1131,5 +1132,6 @@ linked_from_dso_p (struct scninfo *scnin - - return sym->defined && sym->in_dso; - } -+#endif /* Optimizing and not GCC 4.2. */ - - #endif /* ld.h */ ---- elfutils/src/Makefile.am -+++ elfutils/src/Makefile.am -@@ -89,6 +89,11 @@ endif - # XXX While the file is not finished, don't warn about this - ldgeneric_no_Wunused = yes - -+# Buggy old compilers or libc headers. -+readelf_no_Werror = yes -+strings_no_Werror = yes -+addr2line_no_Wformat = yes -+ - readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) -ldl - nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) -ldl \ - $(demanglelib) ---- elfutils/src/Makefile.in -+++ elfutils/src/Makefile.in -@@ -85,6 +85,7 @@ DIST_COMMON = $(top_srcdir)/config/eu.am - $(srcdir)/Makefile.am ldlex.c ldscript.c \ - $(top_srcdir)/config/depcomp $(top_srcdir)/config/ylwrap \ - $(noinst_HEADERS) ChangeLog -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) - bin_PROGRAMS = readelf$(EXEEXT) nm$(EXEEXT) size$(EXEEXT) \ - strip$(EXEEXT) ld$(EXEEXT) elflint$(EXEEXT) \ - findtextrel$(EXEEXT) addr2line$(EXEEXT) elfcmp$(EXEEXT) \ -@@ -93,9 +94,9 @@ bin_PROGRAMS = readelf$(EXEEXT) nm$(EXEE - @NATIVE_LD_FALSE@noinst_PROGRAMS = $(am__EXEEXT_1) - # We never build this library but we need to get the dependency files - # of all the linker backends that might be used in a non-generic linker. --@NEVER_TRUE@am__append_1 = libdummy.a -+@NEVER_TRUE@am__append_2 = libdummy.a - # -ldl is always needed for libebl. --@NATIVE_LD_TRUE@am__append_2 = libld_elf.a -+@NATIVE_LD_TRUE@am__append_3 = libld_elf.a - @NATIVE_LD_TRUE@am_libld_elf_i386_pic_a_OBJECTS = - subdir = src - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -@@ -159,7 +160,7 @@ am_ld_OBJECTS = ld.$(OBJEXT) ldgeneric.$ - ldscript.$(OBJEXT) symbolhash.$(OBJEXT) sectionhash.$(OBJEXT) \ - versionhash.$(OBJEXT) - ld_OBJECTS = $(am_ld_OBJECTS) --ld_DEPENDENCIES = $(libebl) $(libelf) $(libeu) $(am__append_2) -+ld_DEPENDENCIES = $(libebl) $(libelf) $(libeu) $(am__append_3) - ld_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ld_LDFLAGS) $(LDFLAGS) -o \ - $@ - am_libld_elf_i386_so_OBJECTS = -@@ -340,6 +341,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -371,6 +373,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -434,11 +437,11 @@ AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_sr - -I$(srcdir)/../libelf -I$(srcdir)/../libebl \ - -I$(srcdir)/../libdw -I$(srcdir)/../libdwelf \ - -I$(srcdir)/../libdwfl -I$(srcdir)/../libasm --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda make-debug-archive none_ld.os \ - $(ld_modules:.c=.os) *.gconv -@@ -452,8 +455,8 @@ AM_LFLAGS = -Pld -olex.yy.c - native_ld = @native_ld@ - ld_dsos = libld_elf_i386_pic.a - @NATIVE_LD_FALSE@noinst_LIBRARIES = libld_elf.a libar.a $(ld_dsos) \ --@NATIVE_LD_FALSE@ $(am__append_1) --@NATIVE_LD_TRUE@noinst_LIBRARIES = libld_elf.a libar.a $(am__append_1) -+@NATIVE_LD_FALSE@ $(am__append_2) -+@NATIVE_LD_TRUE@noinst_LIBRARIES = libld_elf.a libar.a $(am__append_2) - @NATIVE_LD_TRUE@native_ld_cflags = -DBASE_ELF_NAME=elf_$(base_cpu) - @NEVER_TRUE@libdummy_a_SOURCES = i386_ld.c - ld_SOURCES = ld.c ldgeneric.c ldlex.l ldscript.y symbolhash.c sectionhash.c \ -@@ -479,13 +482,18 @@ libeu = ../lib/libeu.a - - # XXX While the file is not finished, don't warn about this - ldgeneric_no_Wunused = yes -+ -+# Buggy old compilers or libc headers. -+readelf_no_Werror = yes -+strings_no_Werror = yes -+addr2line_no_Wformat = yes - readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) -ldl - nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) -ldl \ - $(demanglelib) - - size_LDADD = $(libelf) $(libeu) - strip_LDADD = $(libebl) $(libelf) $(libeu) -ldl --ld_LDADD = $(libebl) $(libelf) $(libeu) -ldl $(am__append_2) -+ld_LDADD = $(libebl) $(libelf) $(libeu) -ldl $(am__append_3) - ld_LDFLAGS = -rdynamic - elflint_LDADD = $(libebl) $(libelf) $(libeu) -ldl - findtextrel_LDADD = $(libdw) $(libelf) ---- elfutils/src/readelf.c -+++ elfutils/src/readelf.c -@@ -4368,10 +4368,12 @@ listptr_base (struct listptr *p) - return base; - } - -+static const char *listptr_name; -+ - static int --compare_listptr (const void *a, const void *b, void *arg) -+compare_listptr (const void *a, const void *b) - { -- const char *name = arg; -+ const char *const name = listptr_name; - struct listptr *p1 = (void *) a; - struct listptr *p2 = (void *) b; - -@@ -4467,8 +4469,11 @@ static void - sort_listptr (struct listptr_table *table, const char *name) - { - if (table->n > 0) -- qsort_r (table->table, table->n, sizeof table->table[0], -- &compare_listptr, (void *) name); -+ { -+ listptr_name = name; -+ qsort (table->table, table->n, sizeof table->table[0], -+ &compare_listptr); -+ } - } - - static bool -@@ -9539,7 +9544,7 @@ dump_archive_index (Elf *elf, const char - if (unlikely (elf_rand (elf, as_off) == 0) - || unlikely ((subelf = elf_begin (-1, ELF_C_READ_MMAP, elf)) - == NULL)) --#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7) -+#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7) || __GNUC__ < 4 - while (1) - #endif - error (EXIT_FAILURE, 0, ---- elfutils/src/strings.c -+++ elfutils/src/strings.c -@@ -43,6 +43,10 @@ - - #include - -+#ifndef MAP_POPULATE -+# define MAP_POPULATE 0 -+#endif -+ - - /* Prototypes of local functions. */ - static int read_fd (int fd, const char *fname, off64_t fdlen); -@@ -489,8 +493,13 @@ map_file (int fd, off64_t start_off, off - fd, start_off); - if (mem != MAP_FAILED) - { -+#if !defined POSIX_MADV_SEQUENTIAL && defined MADV_SEQUENTIAL -+# define POSIX_MADV_SEQUENTIAL MADV_SEQUENTIAL -+#endif -+#ifdef POSIX_MADV_SEQUENTIAL - /* We will go through the mapping sequentially. */ - (void) posix_madvise (mem, map_size, POSIX_MADV_SEQUENTIAL); -+#endif - break; - } - if (errno != EINVAL && errno != ENOMEM) -@@ -581,9 +590,11 @@ read_block (int fd, const char *fname, o - elfmap_off = from & ~(ps - 1); - elfmap_base = elfmap = map_file (fd, elfmap_off, fdlen, &elfmap_size); - -+#ifdef POSIX_FADV_SEQUENTIAL - if (unlikely (elfmap == MAP_FAILED)) - /* Let the kernel know we are going to read everything in sequence. */ - (void) posix_fadvise (fd, 0, 0, POSIX_FADV_SEQUENTIAL); -+#endif - } - - if (unlikely (elfmap == MAP_FAILED)) ---- elfutils/src/strip.c -+++ elfutils/src/strip.c -@@ -45,6 +45,12 @@ - #include - #include - -+#ifdef HAVE_FUTIMES -+# define FUTIMES(fd, fname, tvp) futimes (fd, tvp) -+#else -+# define FUTIMES(fd, fname, tvp) utimes (fname, tvp) -+#endif -+ - typedef uint8_t GElf_Byte; - - /* Name and version of program. */ -@@ -318,8 +324,18 @@ process_file (const char *fname) - - /* If we have to preserve the timestamp, we need it in the - format utimes() understands. */ -+#ifdef HAVE_STRUCT_STAT_ST_ATIM - TIMESPEC_TO_TIMEVAL (&tv[0], &pre_st.st_atim); -+#else -+ tv[0].tv_sec = pre_st.st_atime; -+ tv[0].tv_usec = 0; -+#endif -+#ifdef HAVE_STRUCT_STAT_ST_MTIM - TIMESPEC_TO_TIMEVAL (&tv[1], &pre_st.st_mtim); -+#else -+ tv[1].tv_sec = pre_st.st_atime; -+ tv[1].tv_usec = 0; -+#endif - } - - /* Open the file. */ -@@ -2091,7 +2107,7 @@ while computing checksum for debug infor - /* If requested, preserve the timestamp. */ - if (tvp != NULL) - { -- if (futimes (fd, tvp) != 0) -+ if (FUTIMES (fd, output_fname, tvp) != 0) - { - error (0, errno, gettext ("\ - cannot set access and modification date of '%s'"), -@@ -2148,7 +2164,7 @@ handle_ar (int fd, Elf *elf, const char - - if (tvp != NULL) - { -- if (unlikely (futimes (fd, tvp) != 0)) -+ if (unlikely (FUTIMES (fd, fname, tvp) != 0)) - { - error (0, errno, gettext ("\ - cannot set access and modification date of '%s'"), fname); ---- elfutils/tests/backtrace.c -+++ elfutils/tests/backtrace.c -@@ -36,6 +36,7 @@ - #include - #include - #include -+#include - #include ELFUTILS_HEADER(dwfl) - - #ifndef __linux__ ---- elfutils/tests/ChangeLog -+++ elfutils/tests/ChangeLog -@@ -421,6 +421,13 @@ - - 2013-12-02 Jan Kratochvil - -+ Handle T-stopped detach for old kernels. -+ * backtrace.c: Include sys/syscall.h. -+ (linux_proc_pid_is_stopped): New function. -+ (ptrace_detach_stopped): Handle old kernels. -+ -+2013-12-02 Jan Kratochvil -+ - * Makefile.am (check_PROGRAMS): Add backtrace, backtrace-child, - backtrace-data and backtrace-dwarf. - (BUILT_SOURCES, clean-local, backtrace-child-biarch): New. -@@ -1285,6 +1292,8 @@ - - 2008-01-21 Roland McGrath - -+ * line2addr.c (main): Revert last change. -+ - * testfile45.S.bz2: Add tests for cltq, cqto. - * testfile45.expect.bz2: Adjust. - -@@ -1993,6 +2002,11 @@ - * Makefile.am (TESTS): Add run-elflint-test.sh. - (EXTRA_DIST): Add run-elflint-test.sh and testfile18.bz2. - -+2005-05-31 Roland McGrath -+ -+ * Makefile.am (WEXTRA): New variable, substituted by configure. -+ (AM_CFLAGS): Use it in place of -Wextra. -+ - 2005-05-24 Ulrich Drepper - - * get-files.c (main): Use correct format specifier. ---- elfutils/tests/line2addr.c -+++ elfutils/tests/line2addr.c -@@ -124,7 +124,7 @@ main (int argc, char *argv[]) - { - struct args a = { .arg = argv[cnt] }; - -- switch (sscanf (a.arg, "%m[^:]:%d", &a.file, &a.line)) -+ switch (sscanf (a.arg, "%a[^:]:%d", &a.file, &a.line)) - { - default: - case 0: ---- elfutils/tests/Makefile.am -+++ elfutils/tests/Makefile.am -@@ -365,6 +365,7 @@ get_lines_LDADD = $(libdw) $(libelf) - get_files_LDADD = $(libdw) $(libelf) - get_aranges_LDADD = $(libdw) $(libelf) - allfcts_LDADD = $(libdw) $(libelf) -+line2addr_no_Wformat = yes - line2addr_LDADD = $(libdw) - addrscopes_LDADD = $(libdw) - funcscopes_LDADD = $(libdw) ---- elfutils/tests/Makefile.in -+++ elfutils/tests/Makefile.in -@@ -80,13 +80,14 @@ host_triplet = @host@ - DIST_COMMON = $(top_srcdir)/config/eu.am $(srcdir)/Makefile.in \ - $(srcdir)/Makefile.am $(top_srcdir)/config/depcomp \ - $(top_srcdir)/config/test-driver ChangeLog --@STANDALONE_FALSE@am__append_1 = -I$(top_srcdir)/libasm -I$(top_srcdir)/libdw \ -+@BUILD_WERROR_TRUE@am__append_1 = $(if $($(*F)_no_Werror),,-Werror) -+@STANDALONE_FALSE@am__append_2 = -I$(top_srcdir)/libasm -I$(top_srcdir)/libdw \ - @STANDALONE_FALSE@ -I$(top_srcdir)/libdwfl -I$(top_srcdir)/libdwelf \ - @STANDALONE_FALSE@ -I$(top_srcdir)/libebl -I$(top_srcdir)/libelf \ - @STANDALONE_FALSE@ -I$(top_srcdir)/lib -I.. - --@STANDALONE_FALSE@am__append_2 = -Wl,-rpath-link,../libasm:../libdw:../libelf --@TESTS_RPATH_TRUE@am__append_3 = -Wl,-rpath,$(BUILD_RPATH) -+@STANDALONE_FALSE@am__append_3 = -Wl,-rpath-link,../libasm:../libdw:../libelf -+@TESTS_RPATH_TRUE@am__append_4 = -Wl,-rpath,$(BUILD_RPATH) - check_PROGRAMS = arextract$(EXEEXT) arsymtest$(EXEEXT) \ - newfile$(EXEEXT) saridx$(EXEEXT) scnnames$(EXEEXT) \ - sectiondump$(EXEEXT) showptable$(EXEEXT) update1$(EXEEXT) \ -@@ -113,7 +114,7 @@ check_PROGRAMS = arextract$(EXEEXT) arsy - deleted$(EXEEXT) deleted-lib.so$(EXEEXT) \ - aggregate_size$(EXEEXT) vdsosyms$(EXEEXT) $(am__EXEEXT_1) \ - $(am__EXEEXT_2) $(am__EXEEXT_4) --@BIARCH_TRUE@am__append_4 = backtrace-child-biarch -+@BIARCH_TRUE@am__append_5 = backtrace-child-biarch - TESTS = run-arextract.sh run-arsymtest.sh newfile$(EXEEXT) \ - test-nlist$(EXEEXT) update1$(EXEEXT) update2$(EXEEXT) \ - update3$(EXEEXT) update4$(EXEEXT) run-show-die-info.sh \ -@@ -159,14 +160,14 @@ TESTS = run-arextract.sh run-arsymtest.s - run-stack-i-test.sh run-readelf-dwz-multi.sh \ - run-allfcts-multi.sh run-deleted.sh run-linkmap-cut.sh \ - run-aggregate-size.sh vdsosyms$(EXEEXT) run-readelf-A.sh \ -- $(am__EXEEXT_2) $(am__append_7) $(am__append_8) \ -+ $(am__EXEEXT_2) $(am__append_8) $(am__append_9) \ - $(am__EXEEXT_4) --@STANDALONE_FALSE@am__append_5 = msg_tst md5-sha1-test - @STANDALONE_FALSE@am__append_6 = msg_tst md5-sha1-test --@LZMA_TRUE@am__append_7 = run-readelf-s.sh run-dwflsyms.sh --@ZLIB_TRUE@am__append_8 = run-readelf-zdebug.sh --@HAVE_LIBASM_TRUE@am__append_9 = $(asm_TESTS) -+@STANDALONE_FALSE@am__append_7 = msg_tst md5-sha1-test -+@LZMA_TRUE@am__append_8 = run-readelf-s.sh run-dwflsyms.sh -+@ZLIB_TRUE@am__append_9 = run-readelf-zdebug.sh - @HAVE_LIBASM_TRUE@am__append_10 = $(asm_TESTS) -+@HAVE_LIBASM_TRUE@am__append_11 = $(asm_TESTS) - subdir = tests - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 - am__aclocal_m4_deps = $(top_srcdir)/m4/biarch.m4 \ -@@ -787,6 +788,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_SCRIPT = @INSTALL_SCRIPT@ - INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ - LDFLAGS = @LDFLAGS@ -+LD_AS_NEEDED = @LD_AS_NEEDED@ - LEX = @LEX@ - LEXLIB = @LEXLIB@ - LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -@@ -818,6 +820,7 @@ SHELL = @SHELL@ - STRIP = @STRIP@ - USE_NLS = @USE_NLS@ - VERSION = @VERSION@ -+WEXTRA = @WEXTRA@ - XGETTEXT = @XGETTEXT@ - XGETTEXT_015 = @XGETTEXT_015@ - XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -@@ -877,12 +880,12 @@ top_build_prefix = @top_build_prefix@ - top_builddir = @top_builddir@ - top_srcdir = @top_srcdir@ - zip_LIBS = @zip_LIBS@ --AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. $(am__append_1) --AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ -- $(if $($(*F)_no_Werror),,-Werror) \ -- $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ -- $($(*F)_CFLAGS) -- -+AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. $(am__append_2) -+AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \ -+ $($(*F)_no_Werror),,-Werror) $(if \ -+ $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \ -+ $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \ -+ $(am__append_1) - COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE)) - CLEANFILES = *.gcno *.gcda - textrel_msg = echo "WARNING: TEXTREL found in '$@'" -@@ -890,7 +893,7 @@ textrel_msg = echo "WARNING: TEXTREL fou - @FATAL_TEXTREL_TRUE@textrel_found = $(textrel_msg); exit 1 - textrel_check = if $(READELF) -d $@ | fgrep -q TEXTREL; then $(textrel_found); fi - BUILD_RPATH = \$$ORIGIN/../libasm:\$$ORIGIN/../libdw:\$$ORIGIN/../backends:\$$ORIGIN/../libelf --AM_LDFLAGS = $(am__append_2) $(am__append_3) -+AM_LDFLAGS = $(am__append_3) $(am__append_4) - @TESTS_RPATH_FALSE@tests_rpath = no - @TESTS_RPATH_TRUE@tests_rpath = yes - asm_TESTS = asm-tst1 asm-tst2 asm-tst3 asm-tst4 asm-tst5 \ -@@ -1106,6 +1109,7 @@ get_lines_LDADD = $(libdw) $(libelf) - get_files_LDADD = $(libdw) $(libelf) - get_aranges_LDADD = $(libdw) $(libelf) - allfcts_LDADD = $(libdw) $(libelf) -+line2addr_no_Wformat = yes - line2addr_LDADD = $(libdw) - addrscopes_LDADD = $(libdw) - funcscopes_LDADD = $(libdw) diff --git a/libs/elfutils/patches/002-argp_standalone.patch b/libs/elfutils/patches/002-argp_standalone.patch deleted file mode 100644 index d1511a909..000000000 --- a/libs/elfutils/patches/002-argp_standalone.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- elfutils-0.160/lib/color.c.old 2014-11-06 03:46:43.584116134 -0200 -+++ elfutils-0.160/lib/color.c 2014-11-06 03:47:25.840116128 -0200 -@@ -131,8 +131,10 @@ - - 'never', 'no', 'none'\n\ - - 'auto', 'tty', 'if-tty'\n"), - program_invocation_short_name, arg); -+ char program_invocation_short_name_nonconst[sizeof(program_invocation_short_name)]; -+ strcpy(program_invocation_short_name_nonconst, program_invocation_short_name); - argp_help (&color_argp, stderr, ARGP_HELP_SEE, -- program_invocation_short_name); -+ program_invocation_short_name_nonconst); - exit (EXIT_FAILURE); - } - } diff --git a/libs/elfutils/patches/003-libint-stub.patch b/libs/elfutils/patches/003-libint-stub.patch deleted file mode 100644 index c9ceb37ca..000000000 --- a/libs/elfutils/patches/003-libint-stub.patch +++ /dev/null @@ -1,49 +0,0 @@ ---- elfutils-0.160/libelf/libelfP.h.old 2014-11-06 01:47:55.420116984 -0200 -+++ elfutils-0.160/libelf/libelfP.h 2014-11-06 01:48:33.368116980 -0200 -@@ -43,6 +43,9 @@ - #include - -+#ifdef _ /* fix libintl-stub */ -+#undef _ -+#endif - /* gettext helper macros. */ - #define _(Str) dgettext ("elfutils", Str) - - ---- elfutils-0.160/libdw/libdwP.h.old 2014-11-06 02:27:12.628116703 -0200 -+++ elfutils-0.160/libdw/libdwP.h 2014-11-06 02:27:39.816116700 -0200 -@@ -36,7 +36,9 @@ - #include - #include - -- -+#ifdef _ /* fix libintl-stub */ -+#undef _ -+#endif - /* gettext helper macros. */ - #define _(Str) dgettext ("elfutils", Str) - ---- elfutils-0.160/libdwfl/libdwflP.h.old 2014-11-06 02:31:20.112116673 -0200 -+++ elfutils-0.160/libdwfl/libdwflP.h 2014-11-06 02:33:00.548116661 -0200 -@@ -46,6 +46,9 @@ - - typedef struct Dwfl_Process Dwfl_Process; - -+#ifdef _ /* fix libintl-stub */ -+#undef _ -+#endif - /* gettext helper macros. */ - #define _(Str) dgettext ("elfutils", Str) - ---- elfutils-0.160/libasm/libasmP.h.old 2014-11-06 02:31:32.064116672 -0200 -+++ elfutils-0.160/libasm/libasmP.h 2014-11-06 02:33:08.656116660 -0200 -@@ -33,6 +33,9 @@ - - #include - -+#ifdef _ /* fix libintl-stub */ -+#undef _ -+#endif - /* gettext helper macros. */ - #define _(Str) dgettext ("elfutils", Str) - diff --git a/libs/elfutils/patches/004-maybe-uninitialized.patch b/libs/elfutils/patches/004-maybe-uninitialized.patch deleted file mode 100644 index 7d54d71fc..000000000 --- a/libs/elfutils/patches/004-maybe-uninitialized.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- elfutils-0.160/libelf/elf_getarsym.c.org 2014-11-06 01:56:58.664116919 -0200 -+++ elfutils-0.160/libelf/elf_getarsym.c 2014-11-06 01:57:09.396116918 -0200 -@@ -166,7 +166,7 @@ - - /* We have an archive. The first word in there is the number of - entries in the table. */ -- uint64_t n; -+ uint64_t n = 0; - size_t off = elf->start_offset + SARMAG + sizeof (struct ar_hdr); - if (read_number_entries (&n, elf, &off, index64_p) < 0) - { diff --git a/libs/elfutils/patches/004-memcpy_def.patch b/libs/elfutils/patches/004-memcpy_def.patch deleted file mode 100644 index 62e4d0ca9..000000000 --- a/libs/elfutils/patches/004-memcpy_def.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- a/libelf/libelf.h -+++ b/libelf/libelf.h -@@ -34,6 +34,11 @@ - /* Get the ELF types. */ - #include - -+#ifndef _LIBC -+#ifndef __mempcpy -+#define __mempcpy mempcpy -+#endif -+#endif - - /* Known translation types. */ - typedef enum diff --git a/libs/elfutils/patches/005-build_only_libs.patch b/libs/elfutils/patches/005-build_only_libs.patch deleted file mode 100644 index b8b459459..000000000 --- a/libs/elfutils/patches/005-build_only_libs.patch +++ /dev/null @@ -1,24 +0,0 @@ ---- elfutils-0.160/Makefile.in.old 2014-11-06 03:56:04.828116067 -0200 -+++ elfutils-0.160/Makefile.in 2014-11-06 03:57:03.380116060 -0200 -@@ -359,8 +359,7 @@ - pkginclude_HEADERS = version.h - - # Add doc back when we have some real content. --SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libcpu libasm \ -- backends src po tests -+SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libasm - - EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \ - COPYING COPYING-GPLV2 COPYING-LGPLV3 ---- elfutils-0.160/Makefile.am.old 2014-11-06 03:58:13.012116051 -0200 -+++ elfutils-0.160/Makefile.am 2014-11-06 03:58:25.948116050 -0200 -@@ -23,8 +23,7 @@ - pkginclude_HEADERS = version.h - - # Add doc back when we have some real content. --SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libcpu libasm \ -- backends src po tests -+SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libasm - - EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \ - COPYING COPYING-GPLV2 COPYING-LGPLV3 diff --git a/libs/elfutils/patches/006-libdw_LIBS.patch b/libs/elfutils/patches/006-libdw_LIBS.patch deleted file mode 100644 index aaa35f943..000000000 --- a/libs/elfutils/patches/006-libdw_LIBS.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- elfutils-0.161/libdw/Makefile.in.orig 2015-01-16 03:50:15.311237461 -0200 -+++ elfutils-0.161/libdw/Makefile.in 2015-01-16 03:55:35.082090075 -0200 -@@ -969,7 +969,7 @@ - -Wl,--enable-new-dtags,-rpath,$(pkglibdir) \ - -Wl,--version-script,$<,--no-undefined \ - -Wl,--whole-archive $(filter-out $<,$^) -Wl,--no-whole-archive\ -- -ldl $(zip_LIBS) -+ -ldl $(zip_LIBS) $(LIBS) - @$(textrel_check) - ln -fs $@ $@.$(VERSION) - diff --git a/libs/elfutils/patches/100-musl-compat.patch b/libs/elfutils/patches/100-musl-compat.patch deleted file mode 100644 index 076b9cf83..000000000 --- a/libs/elfutils/patches/100-musl-compat.patch +++ /dev/null @@ -1,788 +0,0 @@ ---- a/lib/system.h -+++ b/lib/system.h -@@ -68,6 +68,16 @@ extern int crc32_file (int fd, uint32_t - - #define gettext_noop(Str) Str - -+#ifndef TEMP_FAILURE_RETRY -+#define TEMP_FAILURE_RETRY(expression) \ -+ (__extension__ \ -+ ({ long int __result; \ -+ do __result = (long int) (expression); \ -+ while (__result == -1L && errno == EINTR); \ -+ __result; })) -+#endif -+ -+#define error(status, errno, ...) err(status, __VA_ARGS__) - - static inline ssize_t __attribute__ ((unused)) - pwrite_retry (int fd, const void *buf, size_t len, off_t off) ---- a/lib/color.c -+++ b/lib/color.c -@@ -32,7 +32,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/lib/xmalloc.c -+++ b/lib/xmalloc.c -@@ -30,7 +30,7 @@ - # include - #endif - --#include -+#include - #include - #include - #include ---- a/src/addr2line.c -+++ b/src/addr2line.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/ar.c -+++ b/src/ar.c -@@ -22,7 +22,7 @@ - - #include - #include --#include -+#include - #include - #include - #include ---- a/src/arlib2.c -+++ b/src/arlib2.c -@@ -20,7 +20,7 @@ - # include - #endif - --#include -+#include - #include - #include - #include ---- a/src/arlib.c -+++ b/src/arlib.c -@@ -21,7 +21,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/src/elfcmp.c -+++ b/src/elfcmp.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/elflint.c -+++ b/src/elflint.c -@@ -24,7 +24,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/findtextrel.c -+++ b/src/findtextrel.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/i386_ld.c -+++ b/src/i386_ld.c -@@ -20,7 +20,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/src/ld.c -+++ b/src/ld.c -@@ -21,7 +21,7 @@ - - #include - #include --#include -+#include - #include - #include - #include ---- a/src/ldgeneric.c -+++ b/src/ldgeneric.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/ldlex.c -+++ b/src/ldlex.c -@@ -1099,7 +1099,7 @@ char *ldtext; - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/ldscript.c -+++ b/src/ldscript.c -@@ -95,7 +95,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include -@@ -106,7 +106,7 @@ - #include - #include - --/* The error handler. */ -+/* The err.handler. */ - static void yyerror (const char *s); - - /* Some helper functions we need to construct the data structures ---- a/src/nm.c -+++ b/src/nm.c -@@ -26,7 +26,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/objdump.c -+++ b/src/objdump.c -@@ -21,7 +21,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/src/ranlib.c -+++ b/src/ranlib.c -@@ -24,7 +24,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/readelf.c -+++ b/src/readelf.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/size.c -+++ b/src/size.c -@@ -21,7 +21,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/src/stack.c -+++ b/src/stack.c -@@ -18,7 +18,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/strings.c -+++ b/src/strings.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/strip.c -+++ b/src/strip.c -@@ -24,7 +24,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/src/unstrip.c -+++ b/src/unstrip.c -@@ -31,7 +31,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/addrscopes.c -+++ b/tests/addrscopes.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - - ---- a/tests/allregs.c -+++ b/tests/allregs.c -@@ -21,7 +21,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/backtrace.c -+++ b/tests/backtrace.c -@@ -24,7 +24,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/backtrace-data.c -+++ b/tests/backtrace-data.c -@@ -27,7 +27,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/buildid.c -+++ b/tests/buildid.c -@@ -23,7 +23,7 @@ - #include ELFUTILS_HEADER(elf) - #include ELFUTILS_HEADER(dwelf) - #include --#include -+#include - #include - #include - #include ---- a/tests/debugaltlink.c -+++ b/tests/debugaltlink.c -@@ -23,7 +23,7 @@ - #include ELFUTILS_HEADER(dw) - #include ELFUTILS_HEADER(dwelf) - #include --#include -+#include - #include - #include - #include ---- a/tests/debuglink.c -+++ b/tests/debuglink.c -@@ -21,7 +21,7 @@ - #include - #include ELFUTILS_HEADER(dwelf) - #include --#include -+#include - #include - #include - #include ---- a/tests/dwfl-addr-sect.c -+++ b/tests/dwfl-addr-sect.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ELFUTILS_HEADER(dwfl) ---- a/tests/dwfl-bug-addr-overflow.c -+++ b/tests/dwfl-bug-addr-overflow.c -@@ -20,7 +20,7 @@ - #include - #include - #include --#include -+#include - #include - #include ELFUTILS_HEADER(dwfl) - ---- a/tests/dwfl-bug-fd-leak.c -+++ b/tests/dwfl-bug-fd-leak.c -@@ -24,7 +24,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/dwfl-bug-getmodules.c -+++ b/tests/dwfl-bug-getmodules.c -@@ -18,7 +18,7 @@ - #include - #include ELFUTILS_HEADER(dwfl) - --#include -+#include - - static const Dwfl_Callbacks callbacks = - { ---- a/tests/dwfllines.c -+++ b/tests/dwfllines.c -@@ -27,7 +27,7 @@ - #include - #include - #include --#include -+#include - - int - main (int argc, char *argv[]) ---- a/tests/dwflmodtest.c -+++ b/tests/dwflmodtest.c -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ELFUTILS_HEADER(dwfl) ---- a/tests/dwfl-report-elf-align.c -+++ b/tests/dwfl-report-elf-align.c -@@ -20,7 +20,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/tests/dwflsyms.c -+++ b/tests/dwflsyms.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - - static const char * ---- a/tests/early-offscn.c -+++ b/tests/early-offscn.c -@@ -19,7 +19,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/tests/ecp.c -+++ b/tests/ecp.c -@@ -16,7 +16,7 @@ - along with this program. If not, see . */ - - #include --#include -+#include - #include - #include - #include ---- a/tests/find-prologues.c -+++ b/tests/find-prologues.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - ---- a/tests/funcretval.c -+++ b/tests/funcretval.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - ---- a/tests/funcscopes.c -+++ b/tests/funcscopes.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - ---- a/tests/line2addr.c -+++ b/tests/line2addr.c -@@ -26,7 +26,7 @@ - #include - #include - #include --#include -+#include - - - static void ---- a/tests/low_high_pc.c -+++ b/tests/low_high_pc.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - ---- a/tests/md5-sha1-test.c -+++ b/tests/md5-sha1-test.c -@@ -19,7 +19,7 @@ - #endif - - #include --#include -+#include - - #include "md5.h" - #include "sha1.h" ---- a/tests/rdwrmmap.c -+++ b/tests/rdwrmmap.c -@@ -15,7 +15,7 @@ - along with this program. If not, see . */ - - #include --#include -+#include - #include - #include - #include ---- a/tests/saridx.c -+++ b/tests/saridx.c -@@ -17,7 +17,7 @@ - - #include - --#include -+#include - #include - #include - #include ---- a/tests/sectiondump.c -+++ b/tests/sectiondump.c -@@ -18,7 +18,7 @@ - #include - - #include --#include -+#include - #include - #include - #include ---- a/tests/varlocs.c -+++ b/tests/varlocs.c -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/libelf/libelf.h -+++ b/libelf/libelf.h -@@ -29,6 +29,7 @@ - #ifndef _LIBELF_H - #define _LIBELF_H 1 - -+#include - #include - - /* Get the ELF types. */ ---- a/libasm/asm_end.c -+++ b/libasm/asm_end.c -@@ -32,7 +32,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/libasm/asm_newscn.c -+++ b/libasm/asm_newscn.c -@@ -32,7 +32,7 @@ - #endif - - #include --#include -+#include - #include - #include - #include ---- a/libcpu/i386_gendis.c -+++ b/libcpu/i386_gendis.c -@@ -31,7 +31,7 @@ - # include - #endif - --#include -+#include - #include - #include - #include ---- a/libcpu/i386_lex.c -+++ b/libcpu/i386_lex.c -@@ -571,7 +571,7 @@ char *i386_text; - #endif - - #include --#include -+#include - #include - - #include ---- a/libcpu/i386_lex.l -+++ b/libcpu/i386_lex.l -@@ -31,7 +31,7 @@ - #endif - - #include --#include -+#include - #include - - #include ---- a/libcpu/i386_parse.c -+++ b/libcpu/i386_parse.c -@@ -107,7 +107,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/libdw/libdw_alloc.c -+++ b/libdw/libdw_alloc.c -@@ -31,7 +31,7 @@ - # include - #endif - --#include -+#include - #include - #include - #include -@@ -74,5 +74,5 @@ __attribute ((noreturn, visibility ("hid - __libdw_oom (void) - { - while (1) -- error (EXIT_FAILURE, ENOMEM, "libdw"); -+ err (EXIT_FAILURE, "libdw: out of memory"); - } ---- a/libebl/eblopenbackend.c -+++ b/libebl/eblopenbackend.c -@@ -32,7 +32,7 @@ - - #include - #include --#include -+#include - #include - #include - #include ---- a/src/ldlex.l -+++ b/src/ldlex.l -@@ -23,7 +23,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include ---- a/libebl/eblwstrtab.c -+++ b/libebl/eblwstrtab.c -@@ -305,7 +305,7 @@ copystrings (struct Ebl_WStrent *nodep, - - /* Process the current node. */ - nodep->offset = *offsetp; -- *freep = wmempcpy (*freep, nodep->string, nodep->len); -+ *freep = wmemcpy (*freep, nodep->string, nodep->len) + nodep->len; - *offsetp += nodep->len * sizeof (wchar_t); - - for (subs = nodep->next; subs != NULL; subs = subs->next) ---- a/libdwfl/dwfl_error.c -+++ b/libdwfl/dwfl_error.c -@@ -128,6 +128,7 @@ const char * - dwfl_errmsg (error) - int error; - { -+ static __thread char s[64] = ""; - if (error == 0 || error == -1) - { - int last_error = global_error; -@@ -142,7 +143,8 @@ dwfl_errmsg (error) - switch (error &~ 0xffff) - { - case OTHER_ERROR (ERRNO): -- return strerror_r (error & 0xffff, "bad", 0); -+ strerror_r (error & 0xffff, s, sizeof(s)); -+ return s; - case OTHER_ERROR (LIBELF): - return elf_errmsg (error & 0xffff); - case OTHER_ERROR (LIBDW): ---- a/libdwfl/libdwfl.h -+++ b/libdwfl/libdwfl.h -@@ -31,6 +31,27 @@ - - #include "libdw.h" - #include -+#include -+#include -+#include -+ -+#ifndef TEMP_FAILURE_RETRY -+#define TEMP_FAILURE_RETRY(expression) \ -+ (__extension__ \ -+ ({ long int __result; \ -+ do __result = (long int) (expression); \ -+ while (__result == -1L && errno == EINTR); \ -+ __result; })) -+#endif -+ -+#ifndef strndupa -+#define strndupa(s, n) \ -+ (__extension__ ({const char *__in = (s); \ -+ size_t __len = strnlen (__in, (n)) + 1; \ -+ char *__out = (char *) alloca (__len); \ -+ __out[__len-1] = '\0'; \ -+ (char *) memcpy (__out, __in, __len-1);})) -+#endif - - /* Handle for a session using the library. */ - typedef struct Dwfl Dwfl; ---- a/libdwfl/find-debuginfo.c -+++ b/libdwfl/find-debuginfo.c -@@ -338,7 +338,7 @@ dwfl_standard_find_debuginfo (Dwfl_Modul - /* If FILE_NAME is a symlink, the debug file might be associated - with the symlink target name instead. */ - -- char *canon = canonicalize_file_name (file_name); -+ char *canon = realpath (file_name, NULL); - if (canon != NULL && strcmp (file_name, canon)) - fd = find_debuginfo_in_path (mod, canon, - debuglink_file, debuglink_crc, ---- a/libdwfl/dwfl_build_id_find_elf.c -+++ b/libdwfl/dwfl_build_id_find_elf.c -@@ -80,7 +80,7 @@ __libdwfl_open_by_build_id (Dwfl_Module - { - if (*file_name != NULL) - free (*file_name); -- *file_name = canonicalize_file_name (name); -+ *file_name = realpath (name, NULL); - if (*file_name == NULL) - { - *file_name = name; ---- a/libelf/elf_getarsym.c -+++ b/libelf/elf_getarsym.c -@@ -284,7 +284,7 @@ elf_getarsym (elf, ptr) - arsym[cnt].as_off = file_data->u32[cnt]; - - arsym[cnt].as_hash = _dl_elf_hash (str_data); -- str_data = rawmemchr (str_data, '\0') + 1; -+ str_data = memchr (str_data, '\0', SIZE_MAX) + 1; - } - - /* At the end a special entry. */ diff --git a/libs/elfutils/patches/101-no-fts.patch b/libs/elfutils/patches/101-no-fts.patch deleted file mode 100644 index 9dd7ee249..000000000 --- a/libs/elfutils/patches/101-no-fts.patch +++ /dev/null @@ -1,109 +0,0 @@ ---- a/libdwfl/argp-std.c -+++ b/libdwfl/argp-std.c -@@ -52,9 +52,6 @@ static const struct argp_option options[ - { "linux-process-map", 'M', "FILE", 0, - N_("Find addresses in files mapped as read from FILE" - " in Linux /proc/PID/maps format"), 0 }, -- { "kernel", 'k', NULL, 0, N_("Find addresses in the running kernel"), 0 }, -- { "offline-kernel", 'K', "RELEASE", OPTION_ARG_OPTIONAL, -- N_("Kernel with all modules"), 0 }, - { "debuginfo-path", OPT_DEBUGINFO, "PATH", 0, - N_("Search path for separate debuginfo files"), 0 }, - { NULL, 0, NULL, 0, NULL, 0 } -@@ -81,15 +78,6 @@ static const Dwfl_Callbacks proc_callbac - .find_elf = INTUSE(dwfl_linux_proc_find_elf), - }; - --static const Dwfl_Callbacks kernel_callbacks = -- { -- .find_debuginfo = INTUSE(dwfl_standard_find_debuginfo), -- .debuginfo_path = &debuginfo_path, -- -- .find_elf = INTUSE(dwfl_linux_kernel_find_elf), -- .section_address = INTUSE(dwfl_linux_kernel_module_section_address), -- }; -- - /* Structure held at state->HOOK. */ - struct parse_opt - { -@@ -219,43 +207,6 @@ parse_opt (int key, char *arg, struct ar - } - break; - -- case 'k': -- { -- struct parse_opt *opt = state->hook; -- if (opt->dwfl == NULL) -- { -- Dwfl *dwfl = INTUSE(dwfl_begin) (&kernel_callbacks); -- int result = INTUSE(dwfl_linux_kernel_report_kernel) (dwfl); -- if (result != 0) -- return fail (dwfl, result, _("cannot load kernel symbols")); -- result = INTUSE(dwfl_linux_kernel_report_modules) (dwfl); -- if (result != 0) -- /* Non-fatal to have no modules since we do have the kernel. */ -- failure (dwfl, result, _("cannot find kernel modules")); -- opt->dwfl = dwfl; -- } -- else -- goto toomany; -- } -- break; -- -- case 'K': -- { -- struct parse_opt *opt = state->hook; -- if (opt->dwfl == NULL) -- { -- Dwfl *dwfl = INTUSE(dwfl_begin) (&offline_callbacks); -- int result = INTUSE(dwfl_linux_kernel_report_offline) (dwfl, arg, -- NULL); -- if (result != 0) -- return fail (dwfl, result, _("cannot find kernel or modules")); -- opt->dwfl = dwfl; -- } -- else -- goto toomany; -- } -- break; -- - case ARGP_KEY_SUCCESS: - { - struct parse_opt *opt = state->hook; ---- a/libdwfl/Makefile.in -+++ b/libdwfl/Makefile.in -@@ -113,7 +113,7 @@ am__libdwfl_a_SOURCES_DIST = dwfl_begin. - dwfl_getmodules.c dwfl_getdwarf.c dwfl_module_getdwarf.c \ - dwfl_module_getelf.c dwfl_validate_address.c argp-std.c \ - find-debuginfo.c dwfl_build_id_find_elf.c \ -- dwfl_build_id_find_debuginfo.c linux-kernel-modules.c \ -+ dwfl_build_id_find_debuginfo.c \ - linux-proc-maps.c dwfl_addrmodule.c dwfl_addrdwarf.c cu.c \ - dwfl_module_nextcu.c dwfl_nextcu.c dwfl_cumodule.c \ - dwfl_module_addrdie.c dwfl_addrdie.c lines.c dwfl_lineinfo.c \ -@@ -142,7 +142,7 @@ am_libdwfl_a_OBJECTS = dwfl_begin.$(OBJE - dwfl_validate_address.$(OBJEXT) argp-std.$(OBJEXT) \ - find-debuginfo.$(OBJEXT) dwfl_build_id_find_elf.$(OBJEXT) \ - dwfl_build_id_find_debuginfo.$(OBJEXT) \ -- linux-kernel-modules.$(OBJEXT) linux-proc-maps.$(OBJEXT) \ -+ linux-proc-maps.$(OBJEXT) \ - dwfl_addrmodule.$(OBJEXT) dwfl_addrdwarf.$(OBJEXT) \ - cu.$(OBJEXT) dwfl_module_nextcu.$(OBJEXT) \ - dwfl_nextcu.$(OBJEXT) dwfl_cumodule.$(OBJEXT) \ -@@ -402,7 +402,7 @@ libdwfl_a_SOURCES = dwfl_begin.c dwfl_en - dwfl_getmodules.c dwfl_getdwarf.c dwfl_module_getdwarf.c \ - dwfl_module_getelf.c dwfl_validate_address.c argp-std.c \ - find-debuginfo.c dwfl_build_id_find_elf.c \ -- dwfl_build_id_find_debuginfo.c linux-kernel-modules.c \ -+ dwfl_build_id_find_debuginfo.c \ - linux-proc-maps.c dwfl_addrmodule.c dwfl_addrdwarf.c cu.c \ - dwfl_module_nextcu.c dwfl_nextcu.c dwfl_cumodule.c \ - dwfl_module_addrdie.c dwfl_addrdie.c lines.c dwfl_lineinfo.c \ -@@ -540,7 +540,6 @@ distclean-compile: - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lines.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/link_map.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linux-core-attach.Po@am__quote@ --@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linux-kernel-modules.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linux-pid-attach.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linux-proc-maps.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lzma.Po@am__quote@ diff --git a/libs/engine_pkcs11/Makefile b/libs/engine_pkcs11/Makefile index dbdafdab6..c7449ed47 100644 --- a/libs/engine_pkcs11/Makefile +++ b/libs/engine_pkcs11/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=engine_pkcs11 -PKG_VERSION:=20131021 +PKG_VERSION:=20150429 PKG_RELEASE:=1 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=LGPL-2.1+ @@ -18,7 +18,7 @@ PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/OpenSC/engine_pkcs11.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=5abdc7e0d6d519d2514e3eccc116b335bc427254 +PKG_SOURCE_VERSION:=0cc9d88eb291f5c545e5bc91d56866a2e0e95d48 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_FIXUP:=libtool diff --git a/libs/fftw3/Makefile b/libs/fftw3/Makefile new file mode 100644 index 000000000..7d31b7381 --- /dev/null +++ b/libs/fftw3/Makefile @@ -0,0 +1,119 @@ +# +# Copyright (C) 2007-2015 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:=fftw3 +PKG_VERSION:=3.3.4 +PKG_RELEASE:=1 +PKG_LICENSE:=GPL-2.0+ + +PKG_SOURCE:=fftw-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://www.fftw.org +PKG_MD5SUM:=2edab8c06b24feeb3b82bbb3ebf3e7b3 + +PKG_BUILD_DIR=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/fftw-$(PKG_VERSION) +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk + +define Package/fftw3 + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=@!avr32 +libpthread + VARIANT:=double + TITLE:=Fast Fourier transform library + URL:=http://www.fftw.org/ + MAINTAINER:=Vladimir Ulrich +endef + +define Package/fftw3f + $(call Package/fftw3) + VARIANT:=single + TITLE+= (single precision) +endef + +define Package/fftw3l + $(call Package/fftw3) + DEPENDS:=@BROKEN + VARIANT:=long-double + TITLE+= (long-double precision) +endef + +define Package/fftw3/description + FFTW is a collection of fast C routines for computing the + Discrete Fourier Transform in one or more dimensions. It + includes complex, real, and parallel transforms, and can + handle arbitrary array sizes efficiently. +endef + +define Package/fftw3f/description + $(call Package/fftw3/description) + + This package contains the single precision library. +endef + +define Package/fftw3l/description + $(call Package/fftw3/description) + + This package contains the long-double precision library. +endef + +TARGET_CFLAGS += $(FPIC) + +CONFIGURE_ARGS += \ + --prefix=/usr \ + --without-libiconv-prefix \ + --without-libintl-prefix \ + --enable-shared \ + --enable-threads \ + --enable-type-prefix \ + --disable-debug \ + --disable-fortran + +ifeq ($(BUILD_VARIANT), single) +CONFIGURE_ARGS += \ + --enable-single +endif + +ifeq ($(BUILD_VARIANT), long-double) +CONFIGURE_ARGS += \ + --enable-long-double +endif + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) DESTDIR="$(PKG_INSTALL_DIR)" install +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/fftw3.h $(1)/usr/include + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfftw3*.{a,la} $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfftw3*.so* $(1)/usr/lib + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/ +endef + +define Package/fftw3/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfftw3.so* $(1)/usr/lib/ +endef + +define Package/fftw3f/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfftw3f.so* $(1)/usr/lib/ +endef + +define Package/fftw3l/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfftw3l.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,fftw3)) +$(eval $(call BuildPackage,fftw3f)) +$(eval $(call BuildPackage,fftw3l)) diff --git a/libs/fftw3/patches/001-makefile.patch b/libs/fftw3/patches/001-makefile.patch new file mode 100644 index 000000000..c5dd8571f --- /dev/null +++ b/libs/fftw3/patches/001-makefile.patch @@ -0,0 +1,20 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -232,7 +232,7 @@ + CTAGS = ctags + CSCOPE = cscope + DIST_SUBDIRS = support genfft kernel simd-support dft rdft reodft api \ +- libbench2 . threads tests mpi doc tools m4 ++ libbench2 . threads mpi doc tools m4 + DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) + distdir = $(PACKAGE)-$(VERSION) + top_distdir = $(distdir) +@@ -444,7 +444,7 @@ + # + @COMBINED_THREADS_TRUE@CHICKEN_EGG = threads . + SUBDIRS = support $(GENFFT) kernel simd-support dft rdft reodft api \ +-libbench2 $(CHICKEN_EGG) tests mpi doc tools m4 ++libbench2 $(CHICKEN_EGG) mpi m4 + + EXTRA_DIST = COPYRIGHT bootstrap.sh CONVENTIONS fftw.pc.in + SIMD_LIBS = \ diff --git a/libs/gdbm/Makefile b/libs/gdbm/Makefile index d2c4939bc..21ecfb2dd 100644 --- a/libs/gdbm/Makefile +++ b/libs/gdbm/Makefile @@ -19,7 +19,7 @@ PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=COPYING PKG_MAINTAINER:=Marcel Denia -PKG_FIXUP:=autoreconf +PKG_FIXUP:=autoreconf gettext-version PKG_REMOVE_FILES:=Makefile compat/Makefile doc/Makefile export/Makefile src/Makefile tests/Makefile PKG_BUILD_PARALLEL:=0 diff --git a/libs/giflib/Makefile b/libs/giflib/Makefile new file mode 100644 index 000000000..efeabee68 --- /dev/null +++ b/libs/giflib/Makefile @@ -0,0 +1,61 @@ +# +# Copyright (C) 2006-2015 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:=giflib +PKG_VERSION:=5.1.1 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=@SF/giflib +PKG_MD5SUM:=1c39333192712788c6568c78a949f13e + +PKG_MAINTAINER:=Ted Hess + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING + +PKG_FIXUP:=autoreconf +PKG_REMOVE_FILES:=autogen.sh aclocal.m4 + +include $(INCLUDE_DIR)/package.mk + +define Package/giflib + SECTION:=libs + CATEGORY:=Libraries + TITLE:=GIF libraries + URL:=http://sourceforge.net/projects/giflib +endef + +define Package/giflib/description + giflib is a library for reading and writing gif images. + It is API and ABI compatible with libungif which was in wide use while + the LZW compression algorithm was patented. +endef + +TARGET_CFLAGS += $(FPIC) +CONFIGURE_ARGS += --enable-x11=no + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/{lib,include} + $(CP) $(PKG_BUILD_DIR)/lib/.libs/lib*so* $(1)/usr/lib + $(CP) $(PKG_BUILD_DIR)/lib/.libs/libgif.a $(1)/usr/lib + $(CP) $(PKG_BUILD_DIR)/lib/libgif.la $(1)/usr/lib + $(CP) $(PKG_BUILD_DIR)/lib/*.h $(1)/usr/include/ +endef + +define Package/giflib/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_BUILD_DIR)/lib/.libs/lib*so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,giflib)) diff --git a/libs/glib2/Makefile b/libs/glib2/Makefile index 5b516a2cc..80b9768bb 100644 --- a/libs/glib2/Makefile +++ b/libs/glib2/Makefile @@ -16,6 +16,8 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/glib-$(PKG_VERSION) PKG_SOURCE_URL:=@GNOME/glib/2.43 PKG_MD5SUM:=2f28879252c660a65aa3139ec499776b +PKG_BUILD_PARALLEL:=1 +HOST_BUILD_PARALLEL:=1 PKG_BUILD_DEPENDS:=glib2/host libpthread zlib libintl libffi HOST_BUILD_DEPENDS:=libintl/host libiconv/host libffi/host PKG_INSTALL:=1 diff --git a/libs/glpk/Makefile b/libs/glpk/Makefile new file mode 100644 index 000000000..e8ef53944 --- /dev/null +++ b/libs/glpk/Makefile @@ -0,0 +1,66 @@ +# +# Copyright (C) 2010-2015 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:=glpk +PKG_VERSION:=4.55 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=@GNU/$(PKG_NAME) +PKG_MD5SUM:=c632a7a631b8aed02e28eafcd99477f + +PKG_LICENSE:=GPL-3.0 +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libglpk + SECTION:=libs + CATEGORY:=Libraries + TITLE:=The GNU Linear Programming Kit + URL:=http://www.gnu.org/software/glpk/ +endef + +define Package/libglpk/description + The GLPK (GNU Linear Programming Kit) package is intended for solving + large-scale linear programming (LP), mixed integer programming (MIP), + and other related problems. It is a set of routines written in ANSI C + and organized in the form of a callable library. +endef + +define Package/glpsol + SECTION:=libs + CATEGORY:=Libraries + TITLE:=The GNU Linear Programming Kit (glpsol) + URL:=http://www.gnu.org/software/glpk/ + DEPENDS:=libglpk +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/ + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{so*,a,la} $(1)/usr/lib/ +endef + +define Package/libglpk/install + $(INSTALL_DIR) $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ +endef + +define Package/glpsol/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/glpsol $(1)/usr/bin +endef + +$(eval $(call BuildPackage,libglpk)) +$(eval $(call BuildPackage,glpsol)) diff --git a/libs/gnutls/Makefile b/libs/gnutls/Makefile index a7aedf9df..8d716af9f 100644 --- a/libs/gnutls/Makefile +++ b/libs/gnutls/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2005-2010 OpenWrt.org +# Copyright (C) 2005-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,14 +8,16 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gnutls -PKG_VERSION:=3.3.12 +PKG_VERSION:=3.4.2 PKG_RELEASE:=1 PKG_USE_MIPS16:=0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=ftp://ftp.gnutls.org/gcrypt/gnutls/v3.3 -PKG_MD5SUM:=a37b20b4352a5f542367ded904729c90 +PKG_SOURCE_URL:=ftp://ftp.gnutls.org/gcrypt/gnutls/v3.4 +PKG_MD5SUM:=4fb4a6253e09aa070e6c467cbb51ba33 +#PKG_FIXUP:=autoreconf gettext-version PKG_MAINTAINER:=Nikos Mavrogiannopoulos +PKG_LICENSE:=LGPLv2.1+ PKG_INSTALL:=1 PKG_LIBTOOL_PATHS:=. lib @@ -114,6 +116,7 @@ endef CONFIGURE_ARGS+= \ --enable-shared \ --enable-static \ + --disable-rpath \ --disable-libdane \ --disable-guile \ --disable-nls \ @@ -121,9 +124,10 @@ CONFIGURE_ARGS+= \ --enable-local-libopts \ --disable-doc \ --disable-tests \ - --disable-rsa-export \ + --enable-openssl-compatibility \ --with-default-trust-store-dir=/etc/ssl/certs/ \ - --disable-crywrap + --disable-crywrap \ + --with-librt-prefix="$(LIBRT_ROOT_DIR)/" ifneq ($(CONFIG_GNUTLS_EXT_LIBTASN1),y) CONFIGURE_ARGS += --with-included-libtasn1 @@ -174,27 +178,21 @@ CONFIGURE_ARGS += --enable-cryptodev endif TARGET_CFLAGS += $(FPIC) -TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib - -define Build/Configure - $(SED) 's,-I$$$${includedir},,g' $(PKG_BUILD_DIR)/configure - $(SED) 's,-L$$$${libdir},,g' $(PKG_BUILD_DIR)/configure - $(call Build/Configure/Default) -endef define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib/pkgconfig + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libgnutls.so* \ + $(1)/usr/lib/ $(CP) \ $(PKG_INSTALL_DIR)/usr/include/gnutls \ $(1)/usr/include/ - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/libgnutls{,-openssl}.{a,so*} \ - $(1)/usr/lib/ $(CP) \ $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/gnutls.pc \ $(1)/usr/lib/pkgconfig/ endef + define Package/certtool/conffiles /etc/gnutls/certtool.cfg endef diff --git a/libs/gnutls/patches/001-ai-idn-remove.patch b/libs/gnutls/patches/001-ai-idn-remove.patch deleted file mode 100644 index 9acf756af..000000000 --- a/libs/gnutls/patches/001-ai-idn-remove.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/src/socket.c b/src/socket.c -index 82c6252..e2feda9 100644 ---- a/src/socket.c -+++ b/src/socket.c -@@ -241,10 +241,6 @@ socket_open(socket_st * hd, const char *hostname, const char *service, - /* get server name */ - memset(&hints, 0, sizeof(hints)); - --#ifdef AI_IDN -- hints.ai_flags = AI_IDN|AI_IDN_ALLOW_UNASSIGNED; --#endif -- - hints.ai_socktype = udp ? SOCK_DGRAM : SOCK_STREAM; - if ((err = getaddrinfo(hostname, service, &hints, &res))) { - fprintf(stderr, "Cannot resolve %s:%s: %s\n", hostname, diff --git a/libs/hiredis/Makefile b/libs/hiredis/Makefile new file mode 100644 index 000000000..31971b907 --- /dev/null +++ b/libs/hiredis/Makefile @@ -0,0 +1,55 @@ +# +# Copyright (C) 2010-2015 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:=hiredis +PKG_VERSION:=0.13.1 +PKG_RELEASE:=1 + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/redis/hiredis.git +PKG_SOURCE_VERSION:=f58dd249d6ed47a7e835463c3b04722972281dbb +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz + +PKG_LICENSE:=BSD-3-Clause +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libhiredis + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Minimalistic C client for Redis + URL:=https://github.com/redis/hiredis +endef + +define Package/libhiredis/description + Hiredis is a minimalistic C client library for the Redis database. +endef + +MAKE_FLAGS += ARCH="" DEBUG="" PREFIX="/usr" + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/hiredis/adapters + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/hiredis/adapters/* $(1)/usr/include/hiredis/adapters + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/hiredis/*.h $(1)/usr/include/hiredis/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libhiredis.{so*,a} $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/hiredis.pc $(1)/usr/lib/pkgconfig +endef + +define Package/libhiredis/install + $(INSTALL_DIR) $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libhiredis.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libhiredis)) diff --git a/libs/ldns/Makefile b/libs/ldns/Makefile new file mode 100644 index 000000000..9a0b4e1f6 --- /dev/null +++ b/libs/ldns/Makefile @@ -0,0 +1,84 @@ +# +# Copyright (C) 2011-2015 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:=ldns +PKG_VERSION:=1.6.17 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://www.nlnetlabs.nl/downloads/ldns +PKG_MD5SUM:=a79423bcc4129e6d59b616b1cae11e5e + +PKG_LICENSE:=BSD-3-Clause +PKG_LICENSE_FILES:=LICENSE +PKG_MAINTAINER:=Nicolas Thill + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libldns/Default + URL:=http://www.nlnetlabs.nl/projects/ldns/ + DEPENDS:=+libopenssl +endef + +define Package/libldns + $(call Package/libldns/Default) + SECTION:=libs + CATEGORY:=Libraries + TITLE:=A library to simplify DNS programming +endef + +define Package/libldns/description + The goal of ldns is to simplify DNS programming, it supports recent RFCs like + the DNSSEC documents, and allows developers to easily create software + conforming to current RFCs, and experimental software for current Internet + Drafts. +endef + +define Package/drill + $(call Package/libldns/Default) + SECTION:=net + CATEGORY:=Network + SUBMENU:=IP Addresses and Names + TITLE:=DNS(SEC) information tool + DEPENDS+= +libldns +endef + +define Package/drill/description + drill is a tool to designed to get all sorts of information out of the DNS. It + is specificly designed to be used with DNSSEC. +endef + +CONFIGURE_ARGS += \ + --disable-ecdsa \ + --disable-gost \ + --with-drill \ + --with-ssl="$(STAGING_DIR)/usr" + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/ldns $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libldns.{a,so*} $(1)/usr/lib/ +endef + +define Package/libldns/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libldns.so.* $(1)/usr/lib/ +endef + +define Package/drill/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/drill $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,libldns)) +$(eval $(call BuildPackage,drill)) diff --git a/libs/libarchive/Makefile b/libs/libarchive/Makefile index 91bbe5462..9c42aad14 100644 --- a/libs/libarchive/Makefile +++ b/libs/libarchive/Makefile @@ -22,12 +22,23 @@ PKG_FIXUP:=autoreconf include $(INCLUDE_DIR)/package.mk -define Package/libarchive - SECTION:=libs - CATEGORY:=Libraries - DEPENDS:=+libopenssl +zlib - TITLE:=Multi-format archive and compression library - URL:=http://www.libarchive.org/ +define Package/$(PKG_NAME)/Default + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=+zlib + TITLE:=Multi-format archive and compression library + URL:=http://www.libarchive.org/ +endef + +define Package/$(PKG_NAME) + $(call Package/$(PKG_NAME)/Default) + DEPENDS += +libopenssl +endef + +define Package/$(PKG_NAME)-noopenssl + $(call Package/$(PKG_NAME)/Default) + TITLE += (without OpenSSL dependency) + VARIANT:=noopenssl endef CONFIGURE_ARGS += \ @@ -43,6 +54,12 @@ CONFIGURE_ARGS += \ --without-expat \ --without-xml2 +ifeq ($(BUILD_VARIANT),noopenssl) + CONFIGURE_ARGS += --without-openssl +else + CONFIGURE_ARGS += --with-openssl +endif + define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ @@ -54,5 +71,7 @@ define Package/libarchive/install $(INSTALL_DIR) $(1)/usr/lib $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so.* $(1)/usr/lib/ endef +Package/$(PKG_NAME)-noopenssl/install = $(Package/$(PKG_NAME)/install) $(eval $(call BuildPackage,libarchive)) +$(eval $(call BuildPackage,libarchive-noopenssl)) diff --git a/libs/libdaq/Makefile b/libs/libdaq/Makefile index fb3585bd7..3b269f137 100644 --- a/libs/libdaq/Makefile +++ b/libs/libdaq/Makefile @@ -9,9 +9,10 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libdaq PKG_VERSION:=2.0.4 -PKG_RELEASE:=1 +PKG_RELEASE:=2 -PKG_SOURCE_URL:=https://www.snort.org/downloads/snort/ +PKG_SOURCE_URL:=https://www.snort.org/downloads/snort/ \ + @SF/snort PKG_SOURCE:=daq-$(PKG_VERSION).tar.gz PKG_MD5SUM:=65e51d72e9d5d8b397e192e4e5857eff PKG_BUILD_DIR:=$(BUILD_DIR)/daq-$(PKG_VERSION) diff --git a/libs/libdaq/patches/001-compile.patch b/libs/libdaq/patches/001-compile.patch index 6eadb9ee6..b8dd94241 100644 --- a/libs/libdaq/patches/001-compile.patch +++ b/libs/libdaq/patches/001-compile.patch @@ -1,8 +1,8 @@ ---- daq-1.1.1/configure 2012-07-10 21:32:51.000000000 +0200 -+++ daq-new/configure 2012-08-03 15:47:07.654945651 +0200 -@@ -12717,10 +12717,11 @@ - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libpcap version >= \"1.0.0\"" >&5 - $as_echo_n "checking for libpcap version >= \"1.0.0\"... " >&6; } +--- a/configure ++++ b/configure +@@ -12967,10 +12967,11 @@ if ${daq_cv_libpcap_version_1x+:} false; + else + if test "$cross_compiling" = yes; then : - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} diff --git a/libs/libdaq/patches/100-musl-compat.patch b/libs/libdaq/patches/100-musl-compat.patch new file mode 100644 index 000000000..c510564c4 --- /dev/null +++ b/libs/libdaq/patches/100-musl-compat.patch @@ -0,0 +1,42 @@ +--- a/os-daq-modules/daq_ipfw.c ++++ b/os-daq-modules/daq_ipfw.c +@@ -23,10 +23,10 @@ + #include + #include + #include ++#include + + #include + #include +-#include + + #include + #include +--- a/os-daq-modules/daq_ipq.c ++++ b/os-daq-modules/daq_ipq.c +@@ -24,10 +24,10 @@ + #include + #include + #include ++#include + + #include + #include +-#include + + #include + +--- a/os-daq-modules/daq_nfq.c ++++ b/os-daq-modules/daq_nfq.c +@@ -24,10 +24,10 @@ + #include + #include + #include ++#include + + #include + #include +-#include + + #include + diff --git a/libs/libesmtp/Makefile b/libs/libesmtp/Makefile index cd6269623..fa402c660 100644 --- a/libs/libesmtp/Makefile +++ b/libs/libesmtp/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libesmtp PKG_VERSION:=1.0.6 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_MD5SUM:=c4fedc999b6c3820296b0eb92cc2e252 PKG_MAINTAINER:=Othmar Truniger @@ -19,6 +19,9 @@ PKG_LICENSE_FILES:=COPYING PKG_SOURCE_URL:=http://www.stafford.uklinux.net/libesmtp PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_BUILD_PARALLEL:=1 +PKG_INSTALL:=1 + include $(INCLUDE_DIR)/package.mk define Package/libesmtp @@ -29,38 +32,24 @@ define Package/libesmtp DEPENDS:=+libpthread endef -define Build/Configure - $(call Build/Configure/Default,--without-openssl) -endef - -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - DESTDIR="$(PKG_INSTALL_DIR)" \ - all install -endef +CONFIGURE_ARGS += \ + --without-openssl define Build/InstallDev - mkdir -p $(STAGING_DIR)/usr/include - $(CP) $(PKG_INSTALL_DIR)/usr/include/libesmtp.h $(STAGING_DIR)/usr/include/ - $(CP) $(PKG_INSTALL_DIR)/usr/include/auth-client.h $(STAGING_DIR)/usr/include/ - $(CP) $(PKG_INSTALL_DIR)/usr/include/auth-plugin.h $(STAGING_DIR)/usr/include/ - mkdir -p $(STAGING_DIR)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.{a,so*} $(STAGING_DIR)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libesmtp-config $(1)/usr/bin/ + $(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(1)/usr/bin/libesmtp-config + + $(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/libesmtp.{a,so*} $(1)/usr/lib/ $(INSTALL_DIR) $(2)/bin - $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libesmtp-config $(2)/bin/ - $(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(2)/bin/libesmtp-config -endef - -define Build/UninstallDev - rm -rf \ - $(STAGING_DIR)/usr/include/libesmtp.h \ - $(STAGING_DIR)/usr/include/auth-client.h \ - $(STAGING_DIR)/usr/include/auth-plugin.h \ - $(STAGING_DIR)/usr/lib/libesmtp.{a,so*} + $(LN) ../../usr/bin/libesmtp-config $(2)/bin/ endef define Package/libesmtp/install - mkdir -p $(1)/usr/lib + $(INSTALL_DIR) $(1)/usr/lib $(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.so.* $(1)/usr/lib/ endef diff --git a/libs/libev/Makefile b/libs/libev/Makefile new file mode 100644 index 000000000..9f0dc5c89 --- /dev/null +++ b/libs/libev/Makefile @@ -0,0 +1,57 @@ +# +# Copyright (C) 2014-2015 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:=libev +PKG_VERSION:=4.20 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://dist.schmorp.de/libev/Attic/ +PKG_MD5SUM:=1cac539cfc560f381a490c9fba940de9 +PKG_LICENSE:=BSD-2-Clause +PKG_MAINTAINER:=Karl Palsson + +PKG_BUILD_PARALLEL:=1 +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 +PKG_USE_MIPS16:=0 + +include $(INCLUDE_DIR)/package.mk + +define Package/libev + SECTION:=libs + CATEGORY:=Libraries + TITLE:=High-performance event loop + URL:=http://software.schmorp.de/pkg/libev.html +endef + +define Package/libev/description + A full-featured and high-performance event loop that is loosely modelled after + libevent, but without its limitations and bugs. +endef + +TARGET_CFLAGS += $(FPIC) + +CONFIGURE_ARGS += \ + --enable-shared \ + --enable-static \ + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libev.{a,so*} $(1)/usr/lib/ +endef + +define Package/libev/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libev.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libev)) diff --git a/libs/libevdev/Makefile b/libs/libevdev/Makefile new file mode 100644 index 000000000..2fe243331 --- /dev/null +++ b/libs/libevdev/Makefile @@ -0,0 +1,57 @@ +# +# Copyright (C) 2007-2015 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:=libevdev +PKG_VERSION:=1.4.2 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=http://www.freedesktop.org/software/libevdev/ +PKG_MD5SUM:=debfcd5153558eba25a8e71eb2534ae8 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libevdev + SECTION:=libs + CATEGORY:=Libraries + TITLE:=a wrapper library for evdev devices + URL:=http://www.freedesktop.org/wiki/Software/libevdev/ +endef + +define Package/libevdev/description + libevdev is a wrapper library for evdev devices. it moves the common + tasks when dealing with evdev devices into a library and provides a + library interface to the callers, thus avoiding erroneous ioctls, etc. + + The eventual goal is that libevdev wraps all ioctls available to + evdev devices, thus making direct access unnecessary. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{a,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/ +endef + +define Package/libevdev/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libevdev)) diff --git a/libs/libevdev/patches/010-no-clock-monotonic-raw-in-uclibc.patch b/libs/libevdev/patches/010-no-clock-monotonic-raw-in-uclibc.patch new file mode 100644 index 000000000..a11ac1e46 --- /dev/null +++ b/libs/libevdev/patches/010-no-clock-monotonic-raw-in-uclibc.patch @@ -0,0 +1,14 @@ +--- a/test/test-libevdev-init.c ++++ b/test/test-libevdev-init.c +@@ -32,6 +32,11 @@ + #include + #include "test-common.h" + ++/* work-around CLOCK_MONOTONIC_RAW definition missing in uClibc */ ++#ifndef CLOCK_MONOTONIC_RAW ++#define CLOCK_MONOTONIC_RAW 4 ++#endif ++ + START_TEST(test_new_device) + { + struct libevdev *dev; diff --git a/libs/libevhtp-1.1/Makefile b/libs/libevhtp-1.1/Makefile new file mode 100644 index 000000000..9d3cdbc26 --- /dev/null +++ b/libs/libevhtp-1.1/Makefile @@ -0,0 +1,47 @@ +# +# Copyright (C) 2007-2015 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:=libevhtp-1.1 +PKG_VERSION:=1.1.7 +PKG_RELEASE:=1 +PKG_LICENSE:=BSD-3-Clause + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/ellzey/libevhtp.git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=f70c920d4d8d4146ff662867f47c4b5854045b3c +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz + +include $(INCLUDE_DIR)/package.mk + +define Package/libevhtp-1.1 + SECTION:=libs + CATEGORY:=Libraries + TITLE:=A more flexible replacement for libevent's httpd API - compatibility package + MAINTAINER:=Gergely Kiss + URL:=https://github.com/ellzey/libevhtp + DEPENDS:=+libevent2 +libevent2-pthreads +libpthread +endef + +define Package/libevhtp-1.1/description + Libevhtp was created as a replacement API for Libevent's current HTTP API. + + NOTE: This is an older version required for compatibility reasons. The latest version has its own package named "libevhtp". +endef + +include $(INCLUDE_DIR)/cmake.mk + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/libevhtp-1.1/ + $(INSTALL_DIR) $(1)/usr/lib/libevhtp-1.1/ + $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libevhtp-1.1)) diff --git a/libs/libevhtp-1.1/patches/010-CMakeLists-fixes.patch b/libs/libevhtp-1.1/patches/010-CMakeLists-fixes.patch new file mode 100644 index 000000000..970bb76a0 --- /dev/null +++ b/libs/libevhtp-1.1/patches/010-CMakeLists-fixes.patch @@ -0,0 +1,29 @@ +diff -rupN libevhtp-1.1-1.1.7-orig/CMakeLists.txt libevhtp-1.1-1.1.7/CMakeLists.txt +--- libevhtp-1.1-1.1.7-orig/CMakeLists.txt 2015-06-14 00:15:28.000000000 +0200 ++++ libevhtp-1.1-1.1.7/CMakeLists.txt 2015-06-14 00:21:17.441299942 +0200 +@@ -54,7 +54,7 @@ if (NOT HAVE_SYS_UN) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DNO_SYS_UN") + endif(NOT HAVE_SYS_UN) + +-OPTION(EVHTP_DISABLE_SSL "Disable ssl support" OFF) ++OPTION(EVHTP_DISABLE_SSL "Disable ssl support" ON) + OPTION(EVHTP_DISABLE_EVTHR "Disable evthread support" OFF) + OPTION(EVHTP_DIABLE_REGEX "Disable regex support" OFF) + +@@ -182,11 +182,11 @@ endif() + add_library(libevhtp STATIC ${LIBEVHTP_SOURCES} ${ONIG_SOURCES}) + set_target_properties(libevhtp PROPERTIES OUTPUT_NAME "evhtp") + +-install (TARGETS libevhtp DESTINATION lib) +-install (FILES evhtp.h DESTINATION include) +-install (FILES htparse/htparse.h DESTINATION include) +-install (FILES evthr/evthr.h DESTINATION include) +-install (FILES oniguruma/onigposix.h DESTINATION include) ++install (TARGETS libevhtp DESTINATION lib/libevhtp-1.1) ++install (FILES evhtp.h DESTINATION include/libevhtp-1.1) ++install (FILES htparse/htparse.h DESTINATION include/libevhtp-1.1) ++install (FILES evthr/evthr.h DESTINATION include/libevhtp-1.1) ++install (FILES oniguruma/onigposix.h DESTINATION include/libevhtp-1.1) + + find_library (LIB_DL dl) + set (SYS_LIBS ${LIB_DL}) diff --git a/libs/libevhtp/Makefile b/libs/libevhtp/Makefile index f6f61def5..8be811e67 100644 --- a/libs/libevhtp/Makefile +++ b/libs/libevhtp/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libevhtp -PKG_VERSION:=1.2.9 +PKG_VERSION:=1.2.10 PKG_RELEASE:=1 PKG_LICENSE:=BSD-3-Clause PKG_SOURCE:=$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/ellzey/libevhtp/archive/ -PKG_MD5SUM:=428a8d179fcc0cadedd914ed6456e08f +PKG_MD5SUM:=e7261c7e34654f78047431d169b88806 PKG_INSTALL:=1 diff --git a/libs/libevhtp/patches/020-strcmp-endianness-fix.patch b/libs/libevhtp/patches/020-strcmp-endianness-fix.patch deleted file mode 100644 index 072b76b0a..000000000 --- a/libs/libevhtp/patches/020-strcmp-endianness-fix.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff -rupN libevhtp-1.2.9.orig/htparse/htparse.c libevhtp-1.2.9/htparse/htparse.c ---- libevhtp-1.2.9.orig/htparse/htparse.c 2014-03-23 12:50:50.000000000 +0100 -+++ libevhtp-1.2.9/htparse/htparse.c 2014-12-09 01:12:22.242001241 +0100 -@@ -197,6 +197,7 @@ static const char * method_strmap[] = { - - #define _MIN_READ(a, b) ((a) < (b) ? (a) : (b)) - -+#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ - #define _str3_cmp(m, c0, c1, c2, c3) \ - *(uint32_t *)m == ((c3 << 24) | (c2 << 16) | (c1 << 8) | c0) - -@@ -226,6 +227,37 @@ static const char * method_strmap[] = { - *(uint32_t *)m == ((c3 << 24) | (c2 << 16) | (c1 << 8) | c0) \ - && ((uint32_t *)m)[1] == ((c7 << 24) | (c6 << 16) | (c5 << 8) | c4) \ - && m[8] == c8 -+#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ -+#define _str3_cmp(m, c0, c1, c2, c3) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) -+ -+#define _str3Ocmp(m, c0, c1, c2, c3) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) -+ -+#define _str4cmp(m, c0, c1, c2, c3) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) -+ -+#define _str5cmp(m, c0, c1, c2, c3, c4) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) \ -+ && m[4] == c4 -+ -+#define _str6cmp(m, c0, c1, c2, c3, c4, c5) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) \ -+ && (((uint32_t *)m)[1] & 0xffff0000) == ((c4 << 24) | c5 << 16) -+ -+#define _str7_cmp(m, c0, c1, c2, c3, c4, c5, c6, c7) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) \ -+ && ((uint32_t *)m)[1] == ((c4 << 24) | (c5 << 16) | (c6 << 8) | c7) -+ -+#define _str8cmp(m, c0, c1, c2, c3, c4, c5, c6, c7) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) \ -+ && ((uint32_t *)m)[1] == ((c4 << 24) | (c5 << 16) | (c6 << 8) | c7) -+ -+#define _str9cmp(m, c0, c1, c2, c3, c4, c5, c6, c7, c8) \ -+ *(uint32_t *)m == ((c0 << 24) | (c1 << 16) | (c2 << 8) | c3) \ -+ && ((uint32_t *)m)[1] == ((c4 << 24) | (c5 << 16) | (c6 << 8) | c7) \ -+ && m[8] == c8 -+#endif - - #define __HTPARSE_GENHOOK(__n) \ - static inline int hook_ ## __n ## _run(htparser * p, htparse_hooks * hooks) { \ diff --git a/libs/libextractor/Makefile b/libs/libextractor/Makefile new file mode 100644 index 000000000..d68f997a7 --- /dev/null +++ b/libs/libextractor/Makefile @@ -0,0 +1,138 @@ +# +# Copyright (C) 2015 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:=libextractor +PKG_VERSION:=1.3 +PKG_RELEASE:=3 + +# ToDo: +# - package missing optional dependencies: libexiv2, gsf, librpm, smf, tidy + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=@GNU/$(PKG_NAME) +PKG_MD5SUM:=35b8913dbebafe583a2781bf71509c48 + +PKG_LICENSE:=GPL-3.0 +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_INSTALL:=1 + +PLUGINS:= \ + archive:+libarchive-noopenssl \ + deb \ + dvi \ + flac:+libflac \ + gif:+giflib \ + gstreamer:+libgstreamer1:+libgst1app:+libgst1pbutils:+libgst1tag \ + it \ + jpeg:+libjpeg \ + man \ + mime:+libmagic \ + mpeg:+libmpeg2 \ + nsf \ + nsfe \ + odf \ + ogg:+libvorbis \ + png \ + ps \ + riff \ + s3m \ + sid \ + thumbnailffmpeg:+libffmpeg-full:+libmagic \ + tiff:+libtiff \ + wav \ + xm \ + zip + + +include $(INCLUDE_DIR)/package.mk + +CONFIGURE_ARGS += \ + --enable-ffmpeg \ + --with-gstreamer \ + --disable-gsf \ + --disable-rpath + +define Package/libextractor + SECTION:=libs + CATEGORY:=Libraries + TITLE:=GNU Libextractor + URL:=https://www.gnu.org/software/libextractor/ + DEPENDS:=+libbz2 +libltdl +librt +zlib + MENU:=1 +endef + +define Package/libextractor/description + GNU Libextractor is a library used to extract meta data from files. + The goal is to provide developers of file-sharing networks, browsers or + WWW-indexing bots with a universal library to obtain simple keywords and meta + data to match against queries and to show to users instead of only relying on + filenames. +endef + +define PluginGen +define Package/libextractor-plugin-$(subst _,-,$(firstword $(subst :, ,$(1)))) + SECTION:=libs + CATEGORY:=Libraries + TITLE:=GNU Libextractor ($(firstword $(subst :, ,$(1))) plugin) + URL:=https://www.gnu.org/software/libextractor/ + DEPENDS:=libextractor $(wordlist 2,$(words $(subst :, ,$(1))),$(subst :, ,$(1))) +endef +endef + +$(foreach file,$(PLUGINS),$(eval $(call PluginGen,$(file)))) + +define Package/extract + SECTION:=utils + CATEGORY:=Utilities + TITLE:=extract util from GNU Libextractor + URL:=https://www.gnu.org/software/libextractor/ + DEPENDS:=+libextractor +endef + +define Package/extract/description + libextractor contains the shell command extract that, similar to the + well-known file command, can extract meta data from a file an print the results + to stdout. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/ + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(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/libextractor/install + $(INSTALL_DIR) $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ +endef + +define PluginInstall +define Package/libextractor-plugin-$(subst _,-,$(firstword $(subst :, ,$(1))))/install + $(INSTALL_DIR) $$(1)/usr/lib/libextractor + $(INSTALL_BIN) \ + $(PKG_INSTALL_DIR)/usr/lib/libextractor/libextractor_$(firstword $(subst :, ,$(1))).so \ + $$(1)/usr/lib/libextractor +endef +endef + +define Package/extract/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/ +endef + +$(foreach file,$(PLUGINS),$(eval $(call PluginInstall,$(file)))) + +$(eval $(call BuildPackage,libextractor)) +$(foreach file,$(PLUGINS),$(eval $(call BuildPackage,libextractor-plugin-$(subst _,-,$(firstword $(subst :, ,$(file))))))) +$(eval $(call BuildPackage,extract)) diff --git a/libs/libextractor/patches/001-backport-support-for-giflib-5-1.patch b/libs/libextractor/patches/001-backport-support-for-giflib-5-1.patch new file mode 100644 index 000000000..7b7a2df4a --- /dev/null +++ b/libs/libextractor/patches/001-backport-support-for-giflib-5-1.patch @@ -0,0 +1,26 @@ +--- a/src/plugins/gif_extractor.c ++++ b/src/plugins/gif_extractor.c +@@ -78,7 +78,11 @@ EXTRACTOR_gif_extract_method (struct EXT + if (gif_file == NULL || gif_error != 0) + { + if (gif_file != NULL) ++#if GIFLIB_MAJOR < 5 || GIFLIB_MINOR < 1 + EGifCloseFile (gif_file); ++#else ++ EGifCloseFile (gif_file, NULL); ++#endif + return; /* not a GIF */ + } + #endif +@@ -133,7 +137,11 @@ EXTRACTOR_gif_extract_method (struct EXT + DGifGetExtensionNext(gif_file, &ext)) && + (NULL != ext) ) ; /* keep going */ + } ++#if defined (GIF_LIB_VERSION) || GIFLIB_MAJOR < 5 || GIFLIB_MINOR < 1 + DGifCloseFile (gif_file); ++#else ++ DGifCloseFile (gif_file, NULL); ++#endif + } + + /* end of gif_extractor.c */ diff --git a/libs/libidn/Makefile b/libs/libidn/Makefile index 811ebe442..b92e39240 100644 --- a/libs/libidn/Makefile +++ b/libs/libidn/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libidn -PKG_VERSION:=1.29 -PKG_RELEASE:=2 +PKG_VERSION:=1.30 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@GNU/libidn -PKG_MD5SUM:=2b67bb507207af379f9461e1307dc84b +PKG_MD5SUM:=b17edc8551cd31cc5f14c82a9dabf58e PKG_LICENSE:=GPL-2.0+ GPL-3.0+ LGPL-2.1+ LGPL-3.0+ Apache-2.0 PKG_LICENSE_FILES:=COPYING COPYINGv2 COPYINGv3 COPYING.LESSERv2 COPYING.LESSERv3 java/LICENSE-2.0.txt diff --git a/libs/libidn/patches/002-disable-po-docs-examples.patch b/libs/libidn/patches/002-disable-po-docs-examples.patch index 27a6f947e..e99f2a11f 100644 --- a/libs/libidn/patches/002-disable-po-docs-examples.patch +++ b/libs/libidn/patches/002-disable-po-docs-examples.patch @@ -11,12 +11,12 @@ EXTRA_DIST = cfg.mk maint.mk .clcopying --- a/configure.ac +++ b/configure.ac -@@ -51,8 +51,6 @@ AC_PROG_LIBTOOL +@@ -48,8 +48,6 @@ AC_PROG_LIBTOOL # Checks for programs. AM_MISSING_PROG(PERL, perl, $missing_dir) AM_MISSING_PROG(HELP2MAN, help2man, $missing_dir) -AM_GNU_GETTEXT(external) --AM_GNU_GETTEXT_VERSION(0.18.3) +-AM_GNU_GETTEXT_VERSION(0.19.3) AM_ICONV AM_PATH_LISPDIR diff --git a/libs/libimobiledevice/Makefile b/libs/libimobiledevice/Makefile index 7cb06224c..304cf275f 100644 --- a/libs/libimobiledevice/Makefile +++ b/libs/libimobiledevice/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libimobiledevice PKG_VERSION:=1.2.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_MAINTAINER:=Lukasz Baj PKG_LICENSE:=LGPL-2.1+ @@ -42,7 +42,7 @@ define Package/libimobiledevice $(call Package/libimobiledevice/Default) SECTION:=libs CATEGORY:=Libraries - DEPENDS:=$(ICONV_DEPENDS) +libplist +libusbmuxd +libopenssl +libcrypto + DEPENDS:=$(ICONV_DEPENDS) +libplist +libusbmuxd +libopenssl endef define Package/libimobiledevice/description diff --git a/libs/libinput/Makefile b/libs/libinput/Makefile new file mode 100644 index 000000000..f03e1dbec --- /dev/null +++ b/libs/libinput/Makefile @@ -0,0 +1,60 @@ +# +# Copyright (C) 2007-2015 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:=libinput +PKG_VERSION:=0.17.0 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=http://www.freedesktop.org/software/libinput/ +# PKG_MD5SUM:=debfcd5153558eba25a8e71eb2534ae8 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +TARGET_CFLAGS+= -std=gnu99 + +define Package/libinput + SECTION:=libs + CATEGORY:=Libraries + TITLE:=a library to handle input devices + URL:=http://freedesktop.org/wiki/Software/libinput/ + DEPENDS:=+libevdev +mtdev +udev +endef + +define Package/libinput/description + libinput is a library to handle input devices in Wayland compositors + and to provide a generic X.Org input driver. It provides device + detection, device handling, input device event processing and + abstraction so minimize the amount of custom input code compositors + need to provide the common set of functionality that users expect. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{la,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/ +endef + +define Package/libinput/install + $(INSTALL_DIR) $(1)/usr/lib/udev + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/udev/* $(1)/usr/lib/udev +endef + +$(eval $(call BuildPackage,libinput)) diff --git a/libs/libinput/patches/001-no-locale.patch b/libs/libinput/patches/001-no-locale.patch new file mode 100644 index 000000000..adb4aa8be --- /dev/null +++ b/libs/libinput/patches/001-no-locale.patch @@ -0,0 +1,22 @@ +--- a/src/libinput-util.c ++++ b/src/libinput-util.c +@@ -215,18 +215,10 @@ parse_mouse_wheel_click_angle_property(c + double + parse_trackpoint_accel_property(const char *prop) + { +- locale_t c_locale; + double accel; + char *endp; + +- /* Create a "C" locale to force strtod to use '.' as separator */ +- c_locale = newlocale(LC_NUMERIC_MASK, "C", (locale_t)0); +- if (c_locale == (locale_t)0) +- return 0.0; +- +- accel = strtod_l(prop, &endp, c_locale); +- +- freelocale(c_locale); ++ accel = strtod(prop, &endp); + + if (*endp != '\0') + return 0.0; diff --git a/libs/liblz4/Makefile b/libs/liblz4/Makefile new file mode 100644 index 000000000..c24d50971 --- /dev/null +++ b/libs/liblz4/Makefile @@ -0,0 +1,58 @@ +# +# Copyright (C) 2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +# Although liblz4 exports a major.minor.patch version, it isn't always +# incremented for new releases, so use the release tag instead. +PKG_NAME:=liblz4 +PKG_VERSION:=r129 +PKG_RELEASE:=1 + +PKG_LICENSE:=BSD-2-Clause +PKG_MAINTAINER:=Darik Horn + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/Cyan4973/lz4.git +PKG_SOURCE_VERSION:=$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/liblz4 + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Extremely fast compression + URL:=http://www.lz4.org/ +endef + +define Package/liblz4/description + LZ4 is a compression codec that features a very fast encoder and an + even faster decoder. This package provides the liblz4 shared library. +endef + +TARGET_CFLAGS += $(FPIC) + +define Build/Compile + $(MAKE) -C "$(PKG_BUILD_DIR)/lib" $(MAKE_INSTALL_FLAGS) \ + CC="$(TARGET_CC)" \ + CFLAGS="$(TARGET_CFLAGS)" \ + PREFIX="$(CONFIGURE_PREFIX)" \ + install +endef + +define Build/InstallDev + $(CP) $(PKG_INSTALL_DIR)/* $(1)/ +endef + +define Package/liblz4/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/liblz4.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,liblz4)) diff --git a/libs/libmicrohttpd/Makefile b/libs/libmicrohttpd/Makefile index 3f1608ee9..9c9dcbae5 100644 --- a/libs/libmicrohttpd/Makefile +++ b/libs/libmicrohttpd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libmicrohttpd -PKG_VERSION:=0.9.38 -PKG_RELEASE:=1.1 +PKG_VERSION:=0.9.42 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@GNU/libmicrohttpd -PKG_MD5SUM:=b72efbfe7f290846015d460aea7091fe +PKG_MD5SUM:=3b9cf0b67fc8ebc9e69f53c6bc84a88d PKG_MAINTAINER:=Martijn Zilverschoon @@ -29,7 +29,7 @@ define Package/libmicrohttpd CATEGORY:=Libraries TITLE:=GNU libmicrohttpd is a library that runs an HTTP server. URL:=http://www.gnu.org/software/libmicrohttpd/ - DEPENDS:=+libpthread +libgcrypt +libgnutls +libgpg-error +libcrypto +libopenssl + DEPENDS:=+libpthread +libgcrypt +libgnutls +libgpg-error endef define Package/libmicrohttpd/description @@ -37,6 +37,13 @@ define Package/libmicrohttpd/description to run an HTTP server as part of another application. endef +CONFIGURE_ARGS += \ + --enable-https \ + --with-gnutls \ + --disable-curl \ + --disable-spdy \ + --without-openssl + define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include/ $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ diff --git a/libs/libmicrohttpd/patches/001-bump-to-r35864.patch b/libs/libmicrohttpd/patches/001-bump-to-r35864.patch new file mode 100644 index 000000000..6558a96db --- /dev/null +++ b/libs/libmicrohttpd/patches/001-bump-to-r35864.patch @@ -0,0 +1,754 @@ +--- a/ChangeLog ++++ b/ChangeLog +@@ -1,3 +1,14 @@ ++Thu Jun 4 13:37:05 CEST 2015 ++ Fixing memory leak in digest authentication. -AW ++ ++Wed Jun 03 21:23:47 CEST 2015 ++ Add deprecation compiler messages for deprecated functions ++ and macros. -EG ++ ++Fri May 29 12:23:01 CEST 2015 ++ Fixing digest authentication when used in combination ++ with escaped characters in URLs. -CG/AW ++ + Wed May 13 11:49:09 CEST 2015 + Releasing libmicrohttpd 0.9.42. -CG + +--- a/src/microhttpd/response.c ++++ b/src/microhttpd/response.c +@@ -24,6 +24,8 @@ + * @author Christian Grothoff + */ + ++#define MHD_NO_DEPRECATION 1 ++ + #include "internal.h" + #include "response.h" + +--- a/src/microhttpd/digestauth.c ++++ b/src/microhttpd/digestauth.c +@@ -1,6 +1,6 @@ + /* + This file is part of libmicrohttpd +- Copyright (C) 2010, 2011, 2012 Daniel Pittman and Christian Grothoff ++ Copyright (C) 2010, 2011, 2012, 2015 Daniel Pittman and Christian Grothoff + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public +@@ -472,8 +472,8 @@ test_header (struct MHD_Connection *conn + * + * @param connection connections with headers to compare against + * @param args argument URI string (after "?" in URI) +- * @return MHD_YES if the arguments match, +- * MHD_NO if not ++ * @return #MHD_YES if the arguments match, ++ * #MHD_NO if not + */ + static int + check_argument_match (struct MHD_Connection *connection, +@@ -508,7 +508,10 @@ check_argument_match (struct MHD_Connect + connection, + argp); + if (MHD_YES != test_header (connection, argp, NULL)) +- return MHD_NO; ++ { ++ free(argb); ++ return MHD_NO; ++ } + num_headers++; + break; + } +@@ -527,10 +530,16 @@ check_argument_match (struct MHD_Connect + connection, + equals); + if (! test_header (connection, argp, equals)) +- return MHD_NO; ++ { ++ free(argb); ++ return MHD_NO; ++ } ++ + num_headers++; + argp = amper; + } ++ ++ free(argb); + + /* also check that the number of headers matches */ + for (pos = connection->headers_received; NULL != pos; pos = pos->next) +@@ -632,10 +641,83 @@ MHD_digest_auth_check (struct MHD_Connec + header value. */ + return MHD_NO; + } ++ /* 8 = 4 hexadecimal numbers for the timestamp */ ++ nonce_time = strtoul (nonce + len - 8, (char **)NULL, 16); ++ t = (uint32_t) MHD_monotonic_time(); ++ /* ++ * First level vetting for the nonce validity: if the timestamp ++ * attached to the nonce exceeds `nonce_timeout', then the nonce is ++ * invalid. ++ */ ++ if ( (t > nonce_time + nonce_timeout) || ++ (nonce_time + nonce_timeout < nonce_time) ) ++ { ++ /* too old */ ++ return MHD_INVALID_NONCE; ++ } ++ ++ calculate_nonce (nonce_time, ++ connection->method, ++ connection->daemon->digest_auth_random, ++ connection->daemon->digest_auth_rand_size, ++ connection->url, ++ realm, ++ noncehashexp); ++ /* ++ * Second level vetting for the nonce validity ++ * if the timestamp attached to the nonce is valid ++ * and possibly fabricated (in case of an attack) ++ * the attacker must also know the random seed to be ++ * able to generate a "sane" nonce, which if he does ++ * not, the nonce fabrication process going to be ++ * very hard to achieve. ++ */ ++ ++ if (0 != strcmp (nonce, noncehashexp)) ++ { ++ return MHD_INVALID_NONCE; ++ } ++ if ( (0 == lookup_sub_value (cnonce, ++ sizeof (cnonce), ++ header, "cnonce")) || ++ (0 == lookup_sub_value (qop, sizeof (qop), header, "qop")) || ++ ( (0 != strcmp (qop, "auth")) && ++ (0 != strcmp (qop, "")) ) || ++ (0 == lookup_sub_value (nc, sizeof (nc), header, "nc")) || ++ (0 == lookup_sub_value (response, sizeof (response), header, "response")) ) ++ { ++#if HAVE_MESSAGES ++ MHD_DLOG (connection->daemon, ++ "Authentication failed, invalid format.\n"); ++#endif ++ return MHD_NO; ++ } ++ nci = strtoul (nc, &end, 16); ++ if ( ('\0' != *end) || ++ ( (LONG_MAX == nci) && ++ (ERANGE == errno) ) ) ++ { ++#if HAVE_MESSAGES ++ MHD_DLOG (connection->daemon, ++ "Authentication failed, invalid format.\n"); ++#endif ++ return MHD_NO; /* invalid nonce format */ ++ } ++ /* ++ * Checking if that combination of nonce and nc is sound ++ * and not a replay attack attempt. Also adds the nonce ++ * to the nonce-nc map if it does not exist there. ++ */ ++ ++ if (MHD_YES != check_nonce_nc (connection, nonce, nci)) ++ { ++ return MHD_NO; ++ } ++ + { + char *uri; +- +- uri = malloc(left + 1); ++ ++ uri = malloc (left + 1); + if (NULL == uri) + { + #if HAVE_MESSAGES +@@ -648,24 +730,31 @@ MHD_digest_auth_check (struct MHD_Connec + left + 1, + header, "uri")) + { +- free(uri); ++ free (uri); + return MHD_NO; + } + +- /* 8 = 4 hexadecimal numbers for the timestamp */ +- nonce_time = strtoul (nonce + len - 8, (char **)NULL, 16); +- t = (uint32_t) MHD_monotonic_time(); +- /* +- * First level vetting for the nonce validity: if the timestamp +- * attached to the nonce exceeds `nonce_timeout', then the nonce is +- * invalid. +- */ +- if ( (t > nonce_time + nonce_timeout) || +- (nonce_time + nonce_timeout < nonce_time) ) +- { +- free(uri); +- return MHD_INVALID_NONCE; +- } ++ digest_calc_ha1("md5", ++ username, ++ realm, ++ password, ++ nonce, ++ cnonce, ++ ha1); ++ digest_calc_response (ha1, ++ nonce, ++ nc, ++ cnonce, ++ qop, ++ connection->method, ++ uri, ++ hentity, ++ respexp); ++ ++ /* Need to unescape URI before comparing with connection->url */ ++ connection->daemon->unescape_callback (connection->daemon->unescape_callback_cls, ++ connection, ++ uri); + if (0 != strncmp (uri, + connection->url, + strlen (connection->url))) +@@ -674,9 +763,10 @@ MHD_digest_auth_check (struct MHD_Connec + MHD_DLOG (connection->daemon, + "Authentication failed, URI does not match.\n"); + #endif +- free(uri); ++ free (uri); + return MHD_NO; + } ++ + { + const char *args = strchr (uri, '?'); + +@@ -692,89 +782,11 @@ MHD_digest_auth_check (struct MHD_Connec + MHD_DLOG (connection->daemon, + "Authentication failed, arguments do not match.\n"); + #endif +- free(uri); ++ free (uri); + return MHD_NO; + } + } +- calculate_nonce (nonce_time, +- connection->method, +- connection->daemon->digest_auth_random, +- connection->daemon->digest_auth_rand_size, +- connection->url, +- realm, +- noncehashexp); +- /* +- * Second level vetting for the nonce validity +- * if the timestamp attached to the nonce is valid +- * and possibly fabricated (in case of an attack) +- * the attacker must also know the random seed to be +- * able to generate a "sane" nonce, which if he does +- * not, the nonce fabrication process going to be +- * very hard to achieve. +- */ +- +- if (0 != strcmp (nonce, noncehashexp)) +- { +- free(uri); +- return MHD_INVALID_NONCE; +- } +- if ( (0 == lookup_sub_value (cnonce, +- sizeof (cnonce), +- header, "cnonce")) || +- (0 == lookup_sub_value (qop, sizeof (qop), header, "qop")) || +- ( (0 != strcmp (qop, "auth")) && +- (0 != strcmp (qop, "")) ) || +- (0 == lookup_sub_value (nc, sizeof (nc), header, "nc")) || +- (0 == lookup_sub_value (response, sizeof (response), header, "response")) ) +- { +-#if HAVE_MESSAGES +- MHD_DLOG (connection->daemon, +- "Authentication failed, invalid format.\n"); +-#endif +- free(uri); +- return MHD_NO; +- } +- nci = strtoul (nc, &end, 16); +- if ( ('\0' != *end) || +- ( (LONG_MAX == nci) && +- (ERANGE == errno) ) ) +- { +-#if HAVE_MESSAGES +- MHD_DLOG (connection->daemon, +- "Authentication failed, invalid format.\n"); +-#endif +- free(uri); +- return MHD_NO; /* invalid nonce format */ +- } +- /* +- * Checking if that combination of nonce and nc is sound +- * and not a replay attack attempt. Also adds the nonce +- * to the nonce-nc map if it does not exist there. +- */ +- +- if (MHD_YES != check_nonce_nc (connection, nonce, nci)) +- { +- free(uri); +- return MHD_NO; +- } +- +- digest_calc_ha1("md5", +- username, +- realm, +- password, +- nonce, +- cnonce, +- ha1); +- digest_calc_response (ha1, +- nonce, +- nc, +- cnonce, +- qop, +- connection->method, +- uri, +- hentity, +- respexp); +- free(uri); ++ free (uri); + return (0 == strcmp(response, respexp)) + ? MHD_YES + : MHD_NO; +@@ -835,7 +847,7 @@ MHD_queue_auth_fail_response (struct MHD + : ""); + { + char *header; +- ++ + header = malloc(hlen + 1); + if (NULL == header) + { +--- a/src/microhttpd/daemon.c ++++ b/src/microhttpd/daemon.c +@@ -73,7 +73,7 @@ + /** + * Default connection limit. + */ +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + #define MHD_MAX_CONNECTIONS_DEFAULT FD_SETSIZE - 4 + #else + #define MHD_MAX_CONNECTIONS_DEFAULT FD_SETSIZE +@@ -1271,7 +1271,7 @@ internal_add_connection (struct MHD_Daem + return MHD_NO; + } + +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + if ( (client_socket >= FD_SETSIZE) && + (0 == (daemon->options & (MHD_USE_POLL | MHD_USE_EPOLL_LINUX_ONLY))) ) + { +@@ -1418,7 +1418,7 @@ internal_add_connection (struct MHD_Daem + #endif + { + /* make socket non-blocking */ +-#if !defined(WINDOWS) || defined(CYGWIN) ++#if !defined(MHD_WINSOCK_SOCKETS) + int flags = fcntl (connection->socket_fd, F_GETFL); + if ( (-1 == flags) || + (0 != fcntl (connection->socket_fd, F_SETFL, flags | O_NONBLOCK)) ) +@@ -1797,7 +1797,7 @@ static void + make_nonblocking_noninheritable (struct MHD_Daemon *daemon, + MHD_socket sock) + { +-#ifdef WINDOWS ++#ifdef MHD_WINSOCK_SOCKETS + DWORD dwFlags; + unsigned long flags = 1; + +@@ -3611,7 +3611,7 @@ MHD_start_daemon_va (unsigned int flags, + daemon->socket_fd = MHD_INVALID_SOCKET; + daemon->listening_address_reuse = 0; + daemon->options = flags; +-#if WINDOWS ++#if defined(MHD_WINSOCK_SOCKETS) || defined(CYGWIN) + /* Winsock is broken with respect to 'shutdown'; + this disables us calling 'shutdown' on W32. */ + daemon->options |= MHD_USE_EPOLL_TURBO; +@@ -3650,7 +3650,7 @@ MHD_start_daemon_va (unsigned int flags, + free (daemon); + return NULL; + } +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + if ( (0 == (flags & (MHD_USE_POLL | MHD_USE_EPOLL_LINUX_ONLY))) && + (1 == use_pipe) && + (daemon->wpipe[0] >= FD_SETSIZE) ) +@@ -3934,7 +3934,7 @@ MHD_start_daemon_va (unsigned int flags, + (http://msdn.microsoft.com/en-us/library/ms738574%28v=VS.85%29.aspx); + and may also be missing on older POSIX systems; good luck if you have any of those, + your IPv6 socket may then also bind against IPv4 anyway... */ +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + const int + #else + const char +@@ -4016,7 +4016,7 @@ MHD_start_daemon_va (unsigned int flags, + { + socket_fd = daemon->socket_fd; + } +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + if ( (socket_fd >= FD_SETSIZE) && + (0 == (flags & (MHD_USE_POLL | MHD_USE_EPOLL_LINUX_ONLY)) ) ) + { +@@ -4121,7 +4121,7 @@ MHD_start_daemon_va (unsigned int flags, + if ( (daemon->worker_pool_size > 0) && + (0 == (daemon->options & MHD_USE_NO_LISTEN_SOCKET)) ) + { +-#if !defined(WINDOWS) || defined(CYGWIN) ++#if !defined(MHD_WINSOCK_SOCKETS) + int sk_flags; + #else + unsigned long sk_flags; +@@ -4140,7 +4140,7 @@ MHD_start_daemon_va (unsigned int flags, + /* Accept must be non-blocking. Multiple children may wake up + * to handle a new connection, but only one will win the race. + * The others must immediately return. */ +-#if !defined(WINDOWS) || defined(CYGWIN) ++#if !defined(MHD_WINSOCK_SOCKETS) + sk_flags = fcntl (socket_fd, F_GETFL); + if (sk_flags < 0) + goto thread_failed; +@@ -4150,7 +4150,7 @@ MHD_start_daemon_va (unsigned int flags, + sk_flags = 1; + if (SOCKET_ERROR == ioctlsocket (socket_fd, FIONBIO, &sk_flags)) + goto thread_failed; +-#endif /* WINDOWS && !CYGWIN */ ++#endif /* MHD_WINSOCK_SOCKETS */ + + /* Allocate memory for pooled objects */ + daemon->worker_pool = malloc (sizeof (struct MHD_Daemon) +@@ -4182,7 +4182,7 @@ MHD_start_daemon_va (unsigned int flags, + #endif + goto thread_failed; + } +-#ifndef WINDOWS ++#ifndef MHD_WINSOCK_SOCKETS + if ( (0 == (flags & (MHD_USE_POLL | MHD_USE_EPOLL_LINUX_ONLY))) && + (MHD_USE_SUSPEND_RESUME == (flags & MHD_USE_SUSPEND_RESUME)) && + (d->wpipe[0] >= FD_SETSIZE) ) +@@ -4343,7 +4343,7 @@ close_all_connections (struct MHD_Daemon + { + shutdown (pos->socket_fd, + (pos->read_closed == MHD_YES) ? SHUT_WR : SHUT_RDWR); +-#if WINDOWS ++#if MHD_WINSOCK_SOCKETS + if ( (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) && + (MHD_INVALID_PIPE_ != daemon->wpipe[1]) && + (1 != MHD_pipe_write_ (daemon->wpipe[1], "e", 1)) ) +--- a/src/include/microhttpd.h ++++ b/src/include/microhttpd.h +@@ -130,7 +130,7 @@ typedef intptr_t ssize_t; + * Current version of the library. + * 0x01093001 = 1.9.30-1. + */ +-#define MHD_VERSION 0x00094200 ++#define MHD_VERSION 0x00094202 + + /** + * MHD-internal return code for "YES". +@@ -194,6 +194,53 @@ typedef SOCKET MHD_socket; + #endif /* MHD_SOCKET_DEFINED */ + + /** ++ * Define MHD_NO_DEPRECATION before including "microhttpd.h" to disable deprecation messages ++ */ ++#ifdef MHD_NO_DEPRECATION ++#define _MHD_DEPR_MACRO(msg) ++#define _MHD_DEPR_FUNC(msg) ++#endif /* MHD_NO_DEPRECATION */ ++ ++#ifndef _MHD_DEPR_MACRO ++#if defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1500 ++/* Stringify macros */ ++#define _MHD_INSTRMACRO(a) #a ++#define _MHD_STRMACRO(a) _MHD_INSTRMACRO(a) ++#define _MHD_DEPR_MACRO(msg) __pragma(message(__FILE__ "(" _MHD_STRMACRO(__LINE__)"): warning: " msg)) ++#elif defined(__clang__) || defined (__GNUC_PATCHLEVEL__) ++#define _MHD_GCC_PRAG(x) _Pragma (#x) ++#if __clang_major__+0 >= 5 || \ ++ (!defined(__apple_build_version__) && (__clang_major__+0 > 3 || (__clang_major__+0 == 3 && __clang_minor__ >= 3))) || \ ++ __GNUC__+0 > 4 || (__GNUC__+0 == 4 && __GNUC_MINOR__+0 >= 8) ++#define _MHD_DEPR_MACRO(msg) _MHD_GCC_PRAG(GCC warning msg) ++#else /* older clang or GCC */ ++#define _MHD_DEPR_MACRO(msg) _MHD_GCC_PRAG(message msg) ++#endif ++/* #elif defined(SOMEMACRO) */ /* add compiler-specific macros here if required */ ++#else /* other compilers */ ++#define _MHD_DEPR_MACRO(msg) ++#endif ++#endif /* _MHD_DEPR_MACRO */ ++ ++#ifndef _MHD_DEPR_FUNC ++#if defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1400 ++#define _MHD_DEPR_FUNC(msg) __declspec(deprecated(msg)) ++#elif defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1310 ++/* VS .NET 2003 deprecation do not support custom messages */ ++#define _MHD_DEPR_FUNC(msg) __declspec(deprecated) ++#elif defined (__clang__) && \ ++ (__clang_major__+0 >= 4 || (!defined(__apple_build_version__) && __clang_major__+0 >= 3)) ++#define _MHD_DEPR_FUNC(msg) __attribute__((deprecated(msg))) ++#elif defined (__clang__) || __GNUC__+0 > 3 || (__GNUC__+0 == 3 && __GNUC_MINOR__+0 >= 1) ++/* GCC-style deprecation do not support custom messages */ ++#define _MHD_DEPR_FUNC(msg) __attribute__((__deprecated__)) ++/* #elif defined(SOMEMACRO) */ /* add compiler-specific macros here if required */ ++#else /* other compilers */ ++#define _MHD_DEPR_FUNC(msg) ++#endif ++#endif /* _MHD_DEPR_FUNC */ ++ ++/** + * Not all architectures and `printf()`'s support the `long long` type. + * This gives the ability to replace `long long` with just a `long`, + * standard `int` or a `short`. +@@ -204,6 +251,8 @@ typedef SOCKET MHD_socket; + */ + #define MHD_LONG_LONG long long + #define MHD_UNSIGNED_LONG_LONG unsigned long long ++#else /* MHD_LONG_LONG */ ++_MHD_DEPR_MACRO("Macro MHD_LONG_LONG is deprecated, use MHD_UNSIGNED_LONG_LONG") + #endif + /** + * Format string for printing a variable of type #MHD_LONG_LONG. +@@ -215,6 +264,8 @@ typedef SOCKET MHD_socket; + */ + #define MHD_LONG_LONG_PRINTF "ll" + #define MHD_UNSIGNED_LONG_LONG_PRINTF "%llu" ++#else /* MHD_LONG_LONG_PRINTF */ ++_MHD_DEPR_MACRO("Macro MHD_LONG_LONG_PRINTF is deprecated, use MHD_UNSIGNED_LONG_LONG_PRINTF") + #endif + + +@@ -253,7 +304,8 @@ typedef SOCKET MHD_socket; + #define MHD_HTTP_METHOD_NOT_ALLOWED 405 + #define MHD_HTTP_NOT_ACCEPTABLE 406 + /** @deprecated */ +-#define MHD_HTTP_METHOD_NOT_ACCEPTABLE 406 ++#define MHD_HTTP_METHOD_NOT_ACCEPTABLE \ ++ _MHD_DEPR_MACRO("Value MHD_HTTP_METHOD_NOT_ACCEPTABLE is deprecated, use MHD_HTTP_NOT_ACCEPTABLE") 406 + #define MHD_HTTP_PROXY_AUTHENTICATION_REQUIRED 407 + #define MHD_HTTP_REQUEST_TIMEOUT 408 + #define MHD_HTTP_CONFLICT 409 +@@ -1953,6 +2005,7 @@ MHD_create_response_from_callback (uint6 + * @deprecated use #MHD_create_response_from_buffer instead + * @ingroup response + */ ++_MHD_DEPR_FUNC("MHD_create_response_from_data() is deprecated, use MHD_create_response_from_buffer()") \ + _MHD_EXTERN struct MHD_Response * + MHD_create_response_from_data (size_t size, + void *data, +@@ -2023,6 +2076,8 @@ MHD_create_response_from_buffer (size_t + * @return NULL on error (i.e. invalid arguments, out of memory) + * @ingroup response + */ ++/* NOTE: this should be 'uint64_t' instead of 'size_t', but changing ++ this would break API compatibility. */ + _MHD_EXTERN struct MHD_Response * + MHD_create_response_from_fd (size_t size, + int fd); +@@ -2044,6 +2099,8 @@ MHD_create_response_from_fd (size_t size + * @return NULL on error (i.e. invalid arguments, out of memory) + * @ingroup response + */ ++/* NOTE: this should be 'uint64_t' instead of 'size_t', but changing ++ this would break API compatibility. */ + _MHD_EXTERN struct MHD_Response * + MHD_create_response_from_fd_at_offset (size_t size, + int fd, +--- a/src/include/platform_interface.h ++++ b/src/include/platform_interface.h +@@ -82,14 +82,14 @@ + + + /* MHD_socket_close_(fd) close any FDs (non-W32) / close only socket FDs (W32) */ +-#if !defined(_WIN32) || defined(__CYGWIN__) ++#if !defined(MHD_WINSOCK_SOCKETS) + #define MHD_socket_close_(fd) close((fd)) + #else + #define MHD_socket_close_(fd) closesocket((fd)) + #endif + + /* MHD_socket_errno_ is errno of last function (non-W32) / errno of last socket function (W32) */ +-#if !defined(_WIN32) || defined(__CYGWIN__) ++#if !defined(MHD_WINSOCK_SOCKETS) + #define MHD_socket_errno_ errno + #else + #define MHD_socket_errno_ MHD_W32_errno_from_winsock_() +@@ -97,21 +97,21 @@ + + /* MHD_socket_last_strerr_ is description string of last errno (non-W32) / + * description string of last socket error (W32) */ +-#if !defined(_WIN32) || defined(__CYGWIN__) ++#if !defined(MHD_WINSOCK_SOCKETS) + #define MHD_socket_last_strerr_() strerror(errno) + #else + #define MHD_socket_last_strerr_() MHD_W32_strerror_last_winsock_() + #endif + + /* MHD_strerror_ is strerror (both non-W32/W32) */ +-#if !defined(_WIN32) || defined(__CYGWIN__) ++#if !defined(MHD_WINSOCK_SOCKETS) + #define MHD_strerror_(errnum) strerror((errnum)) + #else + #define MHD_strerror_(errnum) MHD_W32_strerror_((errnum)) + #endif + + /* MHD_set_socket_errno_ set errno to errnum (non-W32) / set socket last error to errnum (W32) */ +-#if !defined(_WIN32) || defined(__CYGWIN__) ++#if !defined(MHD_WINSOCK_SOCKETS) + #define MHD_set_socket_errno_(errnum) errno=(errnum) + #else + #define MHD_set_socket_errno_(errnum) MHD_W32_set_last_winsock_error_((errnum)) +--- a/src/testcurl/test_digestauth.c ++++ b/src/testcurl/test_digestauth.c +@@ -73,7 +73,8 @@ ahc_echo (void *cls, + const char *url, + const char *method, + const char *version, +- const char *upload_data, size_t *upload_data_size, ++ const char *upload_data, ++ size_t *upload_data_size, + void **unused) + { + struct MHD_Response *response; +@@ -82,44 +83,47 @@ ahc_echo (void *cls, + const char *realm = "test@example.com"; + int ret; + +- username = MHD_digest_auth_get_username(connection); ++ username = MHD_digest_auth_get_username (connection); + if ( (username == NULL) || + (0 != strcmp (username, "testuser")) ) + { +- response = MHD_create_response_from_buffer(strlen (DENIED), +- DENIED, +- MHD_RESPMEM_PERSISTENT); ++ response = MHD_create_response_from_buffer (strlen (DENIED), ++ DENIED, ++ MHD_RESPMEM_PERSISTENT); + ret = MHD_queue_auth_fail_response(connection, realm, + MY_OPAQUE, + response, +- MHD_NO); +- MHD_destroy_response(response); ++ MHD_NO); ++ MHD_destroy_response(response); + return ret; + } + ret = MHD_digest_auth_check(connection, realm, +- username, +- password, ++ username, ++ password, + 300); + free(username); + if ( (ret == MHD_INVALID_NONCE) || + (ret == MHD_NO) ) + { +- response = MHD_create_response_from_buffer(strlen (DENIED), ++ response = MHD_create_response_from_buffer(strlen (DENIED), + DENIED, +- MHD_RESPMEM_PERSISTENT); +- if (NULL == response) ++ MHD_RESPMEM_PERSISTENT); ++ if (NULL == response) + return MHD_NO; + ret = MHD_queue_auth_fail_response(connection, realm, + MY_OPAQUE, + response, +- (ret == MHD_INVALID_NONCE) ? MHD_YES : MHD_NO); +- MHD_destroy_response(response); ++ (ret == MHD_INVALID_NONCE) ? MHD_YES : MHD_NO); ++ MHD_destroy_response(response); + return ret; + } +- response = MHD_create_response_from_buffer(strlen(PAGE), PAGE, +- MHD_RESPMEM_PERSISTENT); +- ret = MHD_queue_response(connection, MHD_HTTP_OK, response); +- MHD_destroy_response(response); ++ response = MHD_create_response_from_buffer (strlen(PAGE), ++ PAGE, ++ MHD_RESPMEM_PERSISTENT); ++ ret = MHD_queue_response (connection, ++ MHD_HTTP_OK, ++ response); ++ MHD_destroy_response (response); + return ret; + } + +@@ -144,24 +148,24 @@ testDigestAuth () + fd = open("/dev/urandom", O_RDONLY); + if (-1 == fd) + { +- fprintf(stderr, "Failed to open `%s': %s\n", +- "/dev/urandom", +- strerror(errno)); +- return 1; +- } ++ fprintf(stderr, "Failed to open `%s': %s\n", ++ "/dev/urandom", ++ strerror(errno)); ++ return 1; ++ } + while (off < 8) +- { +- len = read(fd, rnd, 8); +- if (len == -1) +- { +- fprintf(stderr, "Failed to read `%s': %s\n", +- "/dev/urandom", +- strerror(errno)); +- (void) close(fd); +- return 1; +- } +- off += len; +- } ++ { ++ len = read(fd, rnd, 8); ++ if (len == -1) ++ { ++ fprintf(stderr, "Failed to read `%s': %s\n", ++ "/dev/urandom", ++ strerror(errno)); ++ (void) close(fd); ++ return 1; ++ } ++ off += len; ++ } + (void) close(fd); + #else + { +@@ -193,7 +197,7 @@ testDigestAuth () + if (d == NULL) + return 1; + c = curl_easy_init (); +- curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1:1337/"); ++ curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1:1337/bar%20 foo?a=bü%20"); + curl_easy_setopt (c, CURLOPT_WRITEFUNCTION, ©Buffer); + curl_easy_setopt (c, CURLOPT_WRITEDATA, &cbc); + curl_easy_setopt (c, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST); +@@ -225,7 +229,6 @@ testDigestAuth () + } + + +- + int + main (int argc, char *const *argv) + { +--- a/src/testcurl/https/test_https_time_out.c ++++ b/src/testcurl/https/test_https_time_out.c +@@ -64,7 +64,7 @@ test_tls_session_time_out (gnutls_sessio + + gnutls_transport_set_ptr (session, (gnutls_transport_ptr_t) (intptr_t) sd); + +- ret = connect (sd, &sa, sizeof (struct sockaddr_in)); ++ ret = connect (sd, (struct sockaddr *) &sa, sizeof (struct sockaddr_in)); + + if (ret < 0) + { diff --git a/libs/libmodbus/Makefile b/libs/libmodbus/Makefile index 5610a0946..65fb00e03 100644 --- a/libs/libmodbus/Makefile +++ b/libs/libmodbus/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=libmodbus -PKG_VERSION:=3.0.6 +PKG_VERSION:=3.1.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://libmodbus.org/releases -PKG_MD5SUM:=c80f88b6ca19cabc4ceffc195ca07771 +PKG_MD5SUM:=dd4262f87ed835c4d1e560f8321a222c PKG_MAINTAINER:=Michael Heimpold @@ -36,6 +36,7 @@ define Package/libmodbus/description A Modbus library for Linux, Mac OS X, FreeBSD, QNX and Win32. endef +CONFIGURE_ARGS += --without-documentation TARGET_CFLAGS += $(FPIC) define Build/InstallDev diff --git a/libs/libmpdclient/Makefile b/libs/libmpdclient/Makefile index dbf5fe02c..06661145f 100644 --- a/libs/libmpdclient/Makefile +++ b/libs/libmpdclient/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libmpdclient -PKG_VERSION:=2.9 -PKG_RELEASE:=3 +PKG_VERSION:=2.10 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://www.musicpd.org/download/libmpdclient/2/ -PGK_MD5SUM:=4b101a36e5c0cf967dc063391260ddbf +PGK_MD5SUM:=00606c630b905aa6196330373b366c29 PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=BSD-3-Clause diff --git a/libs/libmpdclient/patches/001-WIP_musl_compatibility.patch b/libs/libmpdclient/patches/001-WIP_musl_compatibility.patch deleted file mode 100644 index 02ea65220..000000000 --- a/libs/libmpdclient/patches/001-WIP_musl_compatibility.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/src/socket.c -+++ b/src/socket.c -@@ -43,6 +43,7 @@ - #else - # include - # include -+# include - # include - # include - # include ---- a/src/sync.c -+++ b/src/sync.c -@@ -33,6 +33,9 @@ - #include - #include - #include -+#ifndef WIN32 -+#include -+#endif - #include - #include - diff --git a/libs/libnet-1.2.x/Makefile b/libs/libnet-1.2.x/Makefile new file mode 100644 index 000000000..a9d7e7508 --- /dev/null +++ b/libs/libnet-1.2.x/Makefile @@ -0,0 +1,71 @@ +# +# Copyright (C) 2015 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:=libnet +PKG_VERSION:=1.2-rc3 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://sourceforge.net/projects/libnet-dev/files/ +PKG_MD5SUM:=f051e6e5bdecddb90f77c701c2ca1804 +PKG_MAINTAINER:=Mislav Novakovic +PKG_LICENSE:=GPL-2.0 + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +TARGET_CFLAGS += $(FPIC) + +define Package/libnet-1.2.x + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=+libpcap + TITLE:=Low-level packet creation library +endef + + +CONFIGURE_ARGS += \ + --enable-shared \ + --enable-static + +CONFIGURE_VARS += \ + ac_cv_libnet_endianess=$(ENDIANESS) \ + ac_libnet_have_pf_packet=yes \ + LL_INT_TYPE=libnet_link_linux + +define Build/Configure + (cd $(PKG_BUILD_DIR); touch \ + configure.in \ + include.m4 \ + aclocal.m4 \ + Makefile.in \ + ); + $(call Build/Configure/Default) +endef + + +define Build/InstallDev + $(INSTALL_DIR) $(STAGING_DIR)/usr/lib/libnet-1.2.x/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/libnet.h $(STAGING_DIR)/usr/lib/libnet-1.2.x/include + + $(INSTALL_DIR) $(STAGING_DIR)/usr/lib/libnet-1.2.x/include/libnet + $(CP) $(PKG_INSTALL_DIR)/usr/include/libnet/libnet-*.h $(STAGING_DIR)/usr/lib/libnet-1.2.x/include/libnet + + $(INSTALL_DIR) $(STAGING_DIR)/usr/lib/libnet-1.2.x/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnet.{a,la,so*} $(STAGING_DIR)/usr/lib/libnet-1.2.x/lib +endef + +define Package/libnet-1.2.x/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnet.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libnet-1.2.x)) diff --git a/libs/libnet-1.2.x/patches/100-musl-compat.patch b/libs/libnet-1.2.x/patches/100-musl-compat.patch new file mode 100644 index 000000000..fcb4188a0 --- /dev/null +++ b/libs/libnet-1.2.x/patches/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/src/libnet_link_linux.c ++++ b/src/libnet_link_linux.c +@@ -30,7 +30,7 @@ + #include + + #include +-#if (__GLIBC__) ++#if (!__UCLIBC__) + #include + #include + #else diff --git a/libs/libnetfilter-cthelper/Makefile b/libs/libnetfilter-cthelper/Makefile deleted file mode 100644 index f96fd0c92..000000000 --- a/libs/libnetfilter-cthelper/Makefile +++ /dev/null @@ -1,72 +0,0 @@ -# -# Copyright (C) 2015 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:=libnetfilter_cthelper -PKG_VERSION:=1.0.0 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:= \ - http://www.netfilter.org/projects/libnetfilter_cthelper/files/ \ - ftp://ftp.netfilter.org/pub/libnetfilter_cthelper/ \ - http://mirrors.evolva.ro/netfilter.org/libnetfilter_cthelper/ -PKG_MD5SUM:=b2efab1a3a198a5add448960ba011acd - -PKG_LICENSE:=GPL-2.0+ -PKG_LICENSE_FILES:=COPYING -PKG_MAINTAINER:=Nicolas Thill - -PKG_FIXUP:=autoreconf -PKG_INSTALL:=1 - -include $(INCLUDE_DIR)/package.mk - -define Package/libnetfilter-cthelper - CATEGORY:=Libraries - SECTION:=libs - TITLE:=API to connection tracking helper infrastructure - URL:=http://www.netfilter.org/projects/libnetfilter_cthelper/ - DEPENDS:=+libmnl -endef - -define Package/libnetfilter-cthelper/description - libnetfilter_cthelper is the userspace library that provides the programming - interface to the user-space helper infrastructure available since Linux kernel - 3.6. - With this library, you register, configure, enable and disable user-space - helpers. -endef - -TARGET_CFLAGS += $(FPIC) - -CONFIGURE_ARGS += \ - --enable-static \ - --enable-shared \ - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/include - $(CP) \ - $(PKG_INSTALL_DIR)/usr/include/libnetfilter_cthelper \ - $(1)/usr/include/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_cthelper*.{a,la,so*} \ - $(1)/usr/lib/ - $(INSTALL_DIR) $(1)/usr/lib/pkgconfig - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnetfilter_cthelper.pc \ - $(1)/usr/lib/pkgconfig/ -endef - -define Package/libnetfilter-cthelper/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_cthelper*.so.* $(1)/usr/lib/ -endef - -$(eval $(call BuildPackage,libnetfilter-cthelper)) diff --git a/libs/libnetfilter-cttimeout/Makefile b/libs/libnetfilter-cttimeout/Makefile deleted file mode 100644 index 01c2cd030..000000000 --- a/libs/libnetfilter-cttimeout/Makefile +++ /dev/null @@ -1,71 +0,0 @@ -# -# Copyright (C) 2015 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:=libnetfilter_cttimeout -PKG_VERSION:=1.0.0 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:= \ - http://www.netfilter.org/projects/libnetfilter_cttimeout/files/ \ - ftp://ftp.netfilter.org/pub/libnetfilter_cttimeout/ \ - http://mirrors.evolva.ro/netfilter.org/libnetfilter_cttimeout/ -PKG_MD5SUM:=7697437fc9ebb6f6b83df56a633db7f9 - -PKG_LICENSE:=GPL-2.0+ -PKG_LICENSE_FILES:=COPYING -PKG_MAINTAINER:=Nicolas Thill - -PKG_FIXUP:=autoreconf -PKG_INSTALL:=1 - -include $(INCLUDE_DIR)/package.mk - -define Package/libnetfilter-cttimeout - SECTION:=libs - CATEGORY:=Libraries - TITLE:=API to connection tracking timeout infrastructure - URL:=http://www.netfilter.org/projects/libnetfilter_cttimeout/ - DEPENDS:=+libmnl -endef - -define Package/libnetfilter-queue/description - libnetfilter_cttimeout is the userspace library that provides the programming - interface to the fine-grain connection tracking timeout infrastructure. - With this library, you can create, update and delete timeout policies that can - be attached to traffic flows. -endef - -TARGET_CFLAGS += $(FPIC) - -CONFIGURE_ARGS += \ - --enable-static \ - --enable-shared \ - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/include - $(CP) \ - $(PKG_INSTALL_DIR)/usr/include/libnetfilter_cttimeout \ - $(1)/usr/include/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_cttimeout*.{so*,a,la} \ - $(1)/usr/lib/ - $(INSTALL_DIR) $(1)/usr/lib/pkgconfig - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnetfilter_cttimeout.pc \ - $(1)/usr/lib/pkgconfig/ -endef - -define Package/libnetfilter-cttimeout/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_cttimeout*.so.* $(1)/usr/lib/ -endef - -$(eval $(call BuildPackage,libnetfilter-cttimeout)) diff --git a/libs/libnetfilter-queue/Makefile b/libs/libnetfilter-queue/Makefile deleted file mode 100644 index e9793404b..000000000 --- a/libs/libnetfilter-queue/Makefile +++ /dev/null @@ -1,70 +0,0 @@ -# -# Copyright (C) 2007-2015 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:=libnetfilter_queue -PKG_VERSION:=1.0.2 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:= \ - http://www.netfilter.org/projects/libnetfilter_queue/files/ \ - ftp://ftp.netfilter.org/pub/libnetfilter_queue/ \ - http://mirrors.evolva.ro/netfilter.org/libnetfilter_queue/ -PKG_MD5SUM:=df09befac35cb215865b39a36c96a3fa - -PKG_LICENSE:=GPL-2.0+ -PKG_LICENSE_FILES:=COPYING -PKG_MAINTAINER:=Nicolas Thill - -PKG_FIXUP:=autoreconf -PKG_INSTALL:=1 - -include $(INCLUDE_DIR)/package.mk - -define Package/libnetfilter-queue - SECTION:=libs - CATEGORY:=Libraries - TITLE:=API to packets queued by the kernel packet filter - URL:=http://www.netfilter.org/projects/libnetfilter_queue/ - DEPENDS:=+libmnl +libnfnetlink +kmod-nfnetlink-queue -endef - -define Package/libnetfilter-queue/description - libnetfilter_queue is a userspace library providing an API to packets - that have been queued by the kernel packet filter. -endef - -TARGET_CFLAGS += $(FPIC) - -CONFIGURE_ARGS += \ - --enable-static \ - --enable-shared \ - - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/include - $(CP) \ - $(PKG_INSTALL_DIR)/usr/include/libnetfilter_queue \ - $(1)/usr/include/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_queue*.{so*,a,la} \ - $(1)/usr/lib/ - $(INSTALL_DIR) $(1)/usr/lib/pkgconfig - $(CP) \ - $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnetfilter_queue.pc \ - $(1)/usr/lib/pkgconfig/ -endef - -define Package/libnetfilter-queue/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libnetfilter_queue*.so.* $(1)/usr/lib/ -endef - -$(eval $(call BuildPackage,libnetfilter-queue)) diff --git a/libs/libowfat/Makefile b/libs/libowfat/Makefile index 173e5dca1..01bd25a1f 100644 --- a/libs/libowfat/Makefile +++ b/libs/libowfat/Makefile @@ -7,15 +7,15 @@ include $(TOPDIR)/rules.mk -LOWFAT_VERSION=0.29 +LOWFAT_VERSION=0.30 PKG_NAME:=libowfat PKG_VERSION:=$(LOWFAT_VERSION) -PKG_RELEASE:=2 +PKG_RELEASE:=1 -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=http://dl.fefe.de -PKG_MD5SUM:=1187c6acf11429e7adb9ebe180f644bb +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=http://www.fefe.de/libowfat +PKG_MD5SUM:=f0119532ea834ce9e80afe49d7d85512 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING diff --git a/libs/libp11/Makefile b/libs/libp11/Makefile index 4258604e5..c64f79cfe 100644 --- a/libs/libp11/Makefile +++ b/libs/libp11/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libp11 -PKG_VERSION:=20131021 +PKG_VERSION:=20141217 PKG_RELEASE:=1 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=LGPL-2.1+ @@ -19,7 +19,7 @@ PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/OpenSC/libp11.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=ab6306ee7ede9b2fb9c1fa2c3694c6e7ff044a9e +PKG_SOURCE_VERSION:=9f433022a039bbdf31f6c334f442ac3494ac4a07 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_FIXUP:=libtool diff --git a/libs/libpam/Makefile b/libs/libpam/Makefile index e9c4a3c70..ee9ecc659 100644 --- a/libs/libpam/Makefile +++ b/libs/libpam/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libpam -PKG_VERSION:=1.1.8 -PKG_RELEASE:=4 +PKG_VERSION:=1.2.0 +PKG_RELEASE:=2 PKG_SOURCE:=Linux-PAM-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.linux-pam.org/library/ -PKG_MD5SUM:=35b6091af95981b1b2cd60d813b5e4ee +PKG_MD5SUM:=ee4a480d77b341c99e8b1375f8f180c0 PKG_INSTALL:=1 PKG_FIXUP:=autoreconf PKG_MAINTAINER:=Nikos Mavrogiannopoulos @@ -45,6 +45,8 @@ define Build/Configure --disable-selinux \ --disable-nls \ --disable-rpath \ + --disable-nis \ + --disable-regenerate-docu \ --enable-db=no \ ) endef diff --git a/libs/libpam/patches/000-OE-libpam-xtests.patch b/libs/libpam/patches/000-OE-libpam-xtests.patch deleted file mode 100644 index 19fbaa29b..000000000 --- a/libs/libpam/patches/000-OE-libpam-xtests.patch +++ /dev/null @@ -1,35 +0,0 @@ -This patch is used to create a new sub package libpam-xtests to do more checks. - -Upstream-Status: Pending - -Signed-off-by: Kang Kai ---- a/xtests/Makefile.am -+++ b/xtests/Makefile.am -@@ -7,7 +7,7 @@ AM_CFLAGS = -DLIBPAM_COMPILE -I$(top_src - LDADD = $(top_builddir)/libpam/libpam.la \ - $(top_builddir)/libpam_misc/libpam_misc.la - --CLEANFILES = *~ $(XTESTS) -+CLEANFILES = *~ - - EXTRA_DIST = run-xtests.sh tst-pam_dispatch1.pamd tst-pam_dispatch2.pamd \ - tst-pam_dispatch3.pamd tst-pam_dispatch4.pamd \ -@@ -51,3 +51,18 @@ EXTRA_PROGRAMS = $(XTESTS) - - xtests: $(XTESTS) run-xtests.sh - "$(srcdir)"/run-xtests.sh "$(srcdir)" ${XTESTS} ${NOSRCTESTS} -+ -+all: $(XTESTS) -+ -+install: install_xtests -+ -+install_xtests: -+ $(INSTALL) -d $(DESTDIR)$(pkgdatadir)/xtests -+ for file in $(EXTRA_DIST) ; do \ -+ $(INSTALL) $$file $(DESTDIR)$(pkgdatadir)/xtests ; \ -+ done -+ for file in $(XTESTS); do \ -+ $(INSTALL) .libs/$$file $(DESTDIR)$(pkgdatadir)/xtests ; \ -+ done -+ -+.PHONY: all install_xtests diff --git a/libs/libpam/patches/0001-build-always-use-lib-instead-of-lib64.patch b/libs/libpam/patches/0001-build-always-use-lib-instead-of-lib64.patch new file mode 100644 index 000000000..25d9a4ab7 --- /dev/null +++ b/libs/libpam/patches/0001-build-always-use-lib-instead-of-lib64.patch @@ -0,0 +1,36 @@ +From 1948dd03d69c1a50e92d7e8868b7d6eabd4873c1 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 16:11:31 +0800 +Subject: [PATCH 1/7] build: always use /lib instead of /lib64. + +* configure.ac: OpenWrt does not use /lib64. + +Signed-off-by: Yousong Zhou +--- + configure.ac | 10 +--------- + 1 file changed, 1 insertion(+), 9 deletions(-) + +diff --git a/configure.ac b/configure.ac +index fd0e310..306b6e2 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -25,15 +25,7 @@ dnl If we use /usr as prefix, use /etc for config files + then + sysconfdir="/etc" + fi +- if test ${libdir} = '${exec_prefix}/lib' +- then +- case "`uname -m`" in +- x86_64|ppc64|s390x|sparc64) +- libdir="/lib64" ;; +- *) +- libdir="/lib" ;; +- esac +- fi ++ libdir="/lib" + if test ${sbindir} = '${exec_prefix}/sbin' + then + sbindir="/sbin" +-- +1.7.10.4 + diff --git a/libs/libpam/patches/0002-build-ignore-pam_rhosts-if-neither-ruserok-nor-ruser.patch b/libs/libpam/patches/0002-build-ignore-pam_rhosts-if-neither-ruserok-nor-ruser.patch new file mode 100644 index 000000000..abafcbb24 --- /dev/null +++ b/libs/libpam/patches/0002-build-ignore-pam_rhosts-if-neither-ruserok-nor-ruser.patch @@ -0,0 +1,77 @@ +From 1a2e6c979118dce5e79604e88c008c7879d1e4e6 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 18:19:23 +0800 +Subject: [PATCH 2/7] build: ignore pam_rhosts if neither ruserok nor + ruserok_af is available. + +* configure.ac: check for ruserok and ruserok_af +* modules/Makefile.am: ignore pam_rhosts/ if it's disabled +* modules/pam_rhosts/pam_rhosts.c: include stdlib.h for malloc and free + +Signed-off-by: Yousong Zhou +--- + configure.ac | 5 ++++- + modules/Makefile.am | 11 ++++++++--- + modules/pam_rhosts/pam_rhosts.c | 1 + + 3 files changed, 13 insertions(+), 4 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 306b6e2..084071a 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -534,7 +534,10 @@ AC_CHECK_FUNCS(fseeko getdomainname gethostname gettimeofday lckpwdf mkdir selec + AC_CHECK_FUNCS(strcspn strdup strspn strstr strtol uname) + AC_CHECK_FUNCS(getutent_r getpwnam_r getpwuid_r getgrnam_r getgrgid_r getspnam_r) + AC_CHECK_FUNCS(getgrouplist getline getdelim) +-AC_CHECK_FUNCS(inet_ntop inet_pton innetgr ruserok_af) ++AC_CHECK_FUNCS(inet_ntop inet_pton innetgr) ++AC_CHECK_FUNCS([ruserok_af ruserok], [break]) ++ ++AM_CONDITIONAL([COND_BUILD_PAM_RHOSTS], [test "$ac_cv_func_ruserok_af" = yes -o "$ac_cv_func_ruserok" = yes]) + + AC_CHECK_FUNCS(unshare, [UNSHARE=yes], [UNSHARE=no]) + AM_CONDITIONAL([HAVE_UNSHARE], [test "$UNSHARE" = yes]) +diff --git a/modules/Makefile.am b/modules/Makefile.am +index 0c80cea..9ad26a9 100644 +--- a/modules/Makefile.am ++++ b/modules/Makefile.am +@@ -2,16 +2,21 @@ + # Copyright (c) 2005, 2006, 2008 Thorsten Kukuk + # + +-SUBDIRS = pam_access pam_cracklib pam_debug pam_deny pam_echo \ ++if COND_BUILD_PAM_RHOSTS ++ MAYBE_PAM_RHOSTS = pam_rhosts ++endif ++ ++SUBDIRS := pam_access pam_cracklib pam_debug pam_deny pam_echo \ + pam_env pam_exec pam_faildelay pam_filter pam_ftp \ + pam_group pam_issue pam_keyinit pam_lastlog pam_limits \ + pam_listfile pam_localuser pam_loginuid pam_mail \ + pam_mkhomedir pam_motd pam_namespace pam_nologin \ +- pam_permit pam_pwhistory pam_rhosts pam_rootok pam_securetty \ ++ pam_permit pam_pwhistory pam_rootok pam_securetty \ + pam_selinux pam_sepermit pam_shells pam_stress \ + pam_succeed_if pam_tally pam_tally2 pam_time pam_timestamp \ + pam_tty_audit pam_umask \ +- pam_unix pam_userdb pam_warn pam_wheel pam_xauth ++ pam_unix pam_userdb pam_warn pam_wheel pam_xauth \ ++ $(MAYBE_PAM_RHOSTS) + + CLEANFILES = *~ + +diff --git a/modules/pam_rhosts/pam_rhosts.c b/modules/pam_rhosts/pam_rhosts.c +index bc9e76f..51ef13e 100644 +--- a/modules/pam_rhosts/pam_rhosts.c ++++ b/modules/pam_rhosts/pam_rhosts.c +@@ -35,6 +35,7 @@ + #include + #include + #include ++#include + #include + + #define PAM_SM_AUTH /* only defines this management group */ +-- +1.7.10.4 + diff --git a/libs/libpam/patches/0003-build-ignore-pam_lastlog-when-logwtmp-is-not-availab.patch b/libs/libpam/patches/0003-build-ignore-pam_lastlog-when-logwtmp-is-not-availab.patch new file mode 100644 index 000000000..2f3f19cb3 --- /dev/null +++ b/libs/libpam/patches/0003-build-ignore-pam_lastlog-when-logwtmp-is-not-availab.patch @@ -0,0 +1,60 @@ +From bac1ee3033cf22e31730fe3e77ca82bd5ebba692 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 21:18:05 +0800 +Subject: [PATCH 3/7] build: ignore pam_lastlog when logwtmp is not available. + +* configure.ac: check logwtmp and set COND_BUILD_PAM_LASTLOG +* modules/pam_lastlog/Makefile.am: check COND_BUILD_PAM_LASTLOG + +Signed-off-by: Yousong Zhou +--- + configure.ac | 2 ++ + modules/Makefile.am | 8 ++++++-- + 2 files changed, 8 insertions(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 084071a..ca4bf5b 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -536,8 +536,10 @@ AC_CHECK_FUNCS(getutent_r getpwnam_r getpwuid_r getgrnam_r getgrgid_r getspnam_r + AC_CHECK_FUNCS(getgrouplist getline getdelim) + AC_CHECK_FUNCS(inet_ntop inet_pton innetgr) + AC_CHECK_FUNCS([ruserok_af ruserok], [break]) ++AC_CHECK_FUNCS([logwtmp]) + + AM_CONDITIONAL([COND_BUILD_PAM_RHOSTS], [test "$ac_cv_func_ruserok_af" = yes -o "$ac_cv_func_ruserok" = yes]) ++AM_CONDITIONAL([COND_BUILD_PAM_LASTLOG], [test "$ac_cv_func_logwtmp" = yes]) + + AC_CHECK_FUNCS(unshare, [UNSHARE=yes], [UNSHARE=no]) + AM_CONDITIONAL([HAVE_UNSHARE], [test "$UNSHARE" = yes]) +diff --git a/modules/Makefile.am b/modules/Makefile.am +index 9ad26a9..b98dc5c 100644 +--- a/modules/Makefile.am ++++ b/modules/Makefile.am +@@ -6,9 +6,13 @@ if COND_BUILD_PAM_RHOSTS + MAYBE_PAM_RHOSTS = pam_rhosts + endif + ++if COND_BUILD_PAM_LASTLOG ++ MAYBE_PAM_LASTLOG = pam_lastlog ++endif ++ + SUBDIRS := pam_access pam_cracklib pam_debug pam_deny pam_echo \ + pam_env pam_exec pam_faildelay pam_filter pam_ftp \ +- pam_group pam_issue pam_keyinit pam_lastlog pam_limits \ ++ pam_group pam_issue pam_keyinit pam_limits \ + pam_listfile pam_localuser pam_loginuid pam_mail \ + pam_mkhomedir pam_motd pam_namespace pam_nologin \ + pam_permit pam_pwhistory pam_rootok pam_securetty \ +@@ -16,7 +20,7 @@ SUBDIRS := pam_access pam_cracklib pam_debug pam_deny pam_echo \ + pam_succeed_if pam_tally pam_tally2 pam_time pam_timestamp \ + pam_tty_audit pam_umask \ + pam_unix pam_userdb pam_warn pam_wheel pam_xauth \ +- $(MAYBE_PAM_RHOSTS) ++ $(MAYBE_PAM_RHOSTS) $(MAYBE_PAM_LASTLOG) + + CLEANFILES = *~ + +-- +1.7.10.4 + diff --git a/libs/libpam/patches/0004-build-fix-build-when-crypt-is-not-part-of-crypt_libs.patch b/libs/libpam/patches/0004-build-fix-build-when-crypt-is-not-part-of-crypt_libs.patch new file mode 100644 index 000000000..04e617326 --- /dev/null +++ b/libs/libpam/patches/0004-build-fix-build-when-crypt-is-not-part-of-crypt_libs.patch @@ -0,0 +1,28 @@ +From a35daea1b8be768d1b0be6eae157fbf3e5380f92 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 18:22:31 +0800 +Subject: [PATCH 4/7] build: fix build when crypt() is not part of crypt_libs. + +* configure.ac: ditto. + +Signed-off-by: Yousong Zhou +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index ca4bf5b..6553c78 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -408,7 +408,7 @@ AS_IF([test "x$ac_cv_header_xcrypt_h" = "xyes"], + [crypt_libs="crypt"]) + + BACKUP_LIBS=$LIBS +-AC_SEARCH_LIBS([crypt],[$crypt_libs], LIBCRYPT="-l$ac_lib", LIBCRYPT="") ++AC_SEARCH_LIBS([crypt],[$crypt_libs], LIBCRYPT="${ac_lib:+-l$ac_lib}", LIBCRYPT="") + AC_CHECK_FUNCS(crypt_r crypt_gensalt_r) + LIBS=$BACKUP_LIBS + AC_SUBST(LIBCRYPT) +-- +1.7.10.4 + diff --git a/libs/libpam/patches/0005-build-fix-doc-build.patch b/libs/libpam/patches/0005-build-fix-doc-build.patch new file mode 100644 index 000000000..cd9b0a802 --- /dev/null +++ b/libs/libpam/patches/0005-build-fix-doc-build.patch @@ -0,0 +1,133 @@ +From 1563e57ea8ab9d123f765129a6840929ef58ff7a Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 20:38:41 +0800 +Subject: [PATCH 5/7] build: fix doc build. + +* Makefile.am: ignore doc/ directory if not ENABLE_REGENERATE_MAN +* doc/adg/Makefile.am: remove check on ENABLE_REGENERATE_MAN +* doc/man/Makefile.am: ditto +* doc/mwg/Makefile.am: ditto +* doc/sag/Makefile.am: ditto +* doc/specs/Makefile.am: ignore CC from command line + +Signed-off-by: Yousong Zhou +--- + Makefile.am | 5 ++++- + doc/adg/Makefile.am | 3 --- + doc/man/Makefile.am | 2 -- + doc/mwg/Makefile.am | 3 --- + doc/sag/Makefile.am | 2 -- + doc/specs/Makefile.am | 2 +- + 6 files changed, 5 insertions(+), 12 deletions(-) + +diff --git a/Makefile.am b/Makefile.am +index 3db4e37..5e6592a 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -4,7 +4,10 @@ + + AUTOMAKE_OPTIONS = 1.9 gnu dist-bzip2 check-news + +-SUBDIRS = libpam tests libpamc libpam_misc modules po conf doc examples xtests ++if ENABLE_REGENERATE_MAN ++ MAYBE_DOC = doc ++endif ++SUBDIRS = libpam tests libpamc libpam_misc modules po conf examples xtests $(MAYBE_DOC) + + CLEANFILES = *~ + +diff --git a/doc/adg/Makefile.am b/doc/adg/Makefile.am +index 77bd7a9..bec5edc 100644 +--- a/doc/adg/Makefile.am ++++ b/doc/adg/Makefile.am +@@ -9,7 +9,6 @@ EXTRA_DIST = $(XMLS) + XMLS = Linux-PAM_ADG.xml $(shell ls $(srcdir)/pam_*.xml) + DEP_XMLS = $(shell ls $(top_srcdir)/doc/man/pam_*.xml) + +-if ENABLE_REGENERATE_MAN + MAINTAINERCLEANFILES = Linux-PAM_ADG.txt Linux-PAM_ADG.pdf html/*.html + + all: Linux-PAM_ADG.txt html/Linux-PAM_ADG.html Linux-PAM_ADG.pdf +@@ -51,8 +50,6 @@ html/Linux-PAM_ADG.html: $(XMLS) $(DEP_XMLS) + distclean-local: + -rm -rf html Linux-PAM_ADG.txt Linux-PAM_ADG.pdf + +-endif +- + install-data-local: + $(mkinstalldirs) $(DESTDIR)$(docdir) + $(mkinstalldirs) $(DESTDIR)$(pdfdir) +diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am +index 78c891d..b1dc421 100644 +--- a/doc/man/Makefile.am ++++ b/doc/man/Makefile.am +@@ -45,7 +45,6 @@ XMLS = pam.3.xml pam.8.xml \ + misc_conv.3.xml pam_misc_paste_env.3.xml pam_misc_drop_env.3.xml \ + pam_misc_setenv.3.xml + +-if ENABLE_REGENERATE_MAN + PAM.8: pam.8 + pam_get_authtok_noverify.3: pam_get_authtok.3 + pam_get_authtok_verify.3: pam_get_authtok.3 +@@ -60,4 +59,3 @@ pam_get_item.3: pam_item_types_std.inc.xml pam_item_types_ext.inc.xml + pam_set_data.3: pam_item_types_std.inc.xml pam_item_types_ext.inc.xml + pam.conf.5: pam.conf-desc.xml pam.conf-dir.xml pam.conf-syntax.xml + -include $(top_srcdir)/Make.xml.rules +-endif +diff --git a/doc/mwg/Makefile.am b/doc/mwg/Makefile.am +index 2bbb2d0..f57e297 100644 +--- a/doc/mwg/Makefile.am ++++ b/doc/mwg/Makefile.am +@@ -9,7 +9,6 @@ EXTRA_DIST = $(XMLS) + XMLS = Linux-PAM_MWG.xml $(shell ls $(srcdir)/pam_*.xml) + DEP_XMLS = $(shell ls $(top_srcdir)/doc/man/pam_*.xml) + +-if ENABLE_REGENERATE_MAN + MAINTAINERCLEANFILES = Linux-PAM_MWG.txt Linux-PAM_MWG.pdf html/*.html + + all: Linux-PAM_MWG.txt html/Linux-PAM_MWG.html Linux-PAM_MWG.pdf +@@ -51,8 +50,6 @@ html/Linux-PAM_MWG.html: $(XMLS) $(DEP_XMLS) + distclean-local: + -rm -rf html Linux-PAM_MWG.txt Linux-PAM_MWG.pdf + +-endif +- + install-data-local: + $(mkinstalldirs) $(DESTDIR)$(docdir) + $(mkinstalldirs) $(DESTDIR)$(pdfdir) +diff --git a/doc/sag/Makefile.am b/doc/sag/Makefile.am +index 31816aa..a8b655f 100644 +--- a/doc/sag/Makefile.am ++++ b/doc/sag/Makefile.am +@@ -10,7 +10,6 @@ XMLS = Linux-PAM_SAG.xml $(shell ls $(srcdir)/pam_*.xml) + + DEP_XMLS = $(shell ls $(top_srcdir)/modules/pam_*/pam_*.xml) + +-if ENABLE_REGENERATE_MAN + MAINTAINERCLEANFILES = Linux-PAM_SAG.txt Linux-PAM_SAG.pdf html/*.html + + all: Linux-PAM_SAG.txt html/Linux-PAM_SAG.html Linux-PAM_SAG.pdf +@@ -51,7 +50,6 @@ html/Linux-PAM_SAG.html: $(XMLS) $(DEP_XMLS) + + distclean-local: + -rm -rf html Linux-PAM_SAG.txt Linux-PAM_SAG.pdf +-endif + + install-data-local: + $(mkinstalldirs) $(DESTDIR)$(docdir) +diff --git a/doc/specs/Makefile.am b/doc/specs/Makefile.am +index 99ecc70..39c850f 100644 +--- a/doc/specs/Makefile.am ++++ b/doc/specs/Makefile.am +@@ -11,7 +11,7 @@ draft-morgan-pam-current.txt: padout draft-morgan-pam.raw + + AM_YFLAGS = -d + +-CC = @CC_FOR_BUILD@ ++override CC = @CC_FOR_BUILD@ + CPPFLAGS = @BUILD_CPPFLAGS@ + CFLAGS = @BUILD_CFLAGS@ + LDFLAGS = @BUILD_LDFLAGS@ +-- +1.7.10.4 + diff --git a/libs/libpam/patches/0006-pam_unix-fix-compilation-in-case-rpc-rpc.h-is-missin.patch b/libs/libpam/patches/0006-pam_unix-fix-compilation-in-case-rpc-rpc.h-is-missin.patch new file mode 100644 index 000000000..014684f29 --- /dev/null +++ b/libs/libpam/patches/0006-pam_unix-fix-compilation-in-case-rpc-rpc.h-is-missin.patch @@ -0,0 +1,29 @@ +From 2e3ed4c6fb09f84fede589047d37d11783202d34 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 18:16:18 +0800 +Subject: [PATCH 6/7] pam_unix: fix compilation in case rpc/rpc.h is missing. + +* modules/pam_unix/pam_unix_passwd.c: conditional compile on the + availability of rpc/rpc.h + +Signed-off-by: Yousong Zhou +--- + modules/pam_unix/pam_unix_passwd.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/modules/pam_unix/pam_unix_passwd.c b/modules/pam_unix/pam_unix_passwd.c +index 2d330e5..970724a 100644 +--- a/modules/pam_unix/pam_unix_passwd.c ++++ b/modules/pam_unix/pam_unix_passwd.c +@@ -336,7 +336,7 @@ static int _do_setpass(pam_handle_t* pamh, const char *forwho, + } + + if (on(UNIX_NIS, ctrl) && _unix_comesfromsource(pamh, forwho, 0, 1)) { +-#ifdef HAVE_NIS ++#if defined(HAVE_NIS) && defined(HAVE_RPC_RPC_H) + if ((master=getNISserver(pamh, ctrl)) != NULL) { + struct timeval timeout; + struct yppasswd yppwd; +-- +1.7.10.4 + diff --git a/libs/libpam/patches/000-OE-pam-no-innetgr.patch b/libs/libpam/patches/0007-Check-if-innetgr-is-available-at-compile-time.patch similarity index 59% rename from libs/libpam/patches/000-OE-pam-no-innetgr.patch rename to libs/libpam/patches/0007-Check-if-innetgr-is-available-at-compile-time.patch index f7f5b4897..f79b01aeb 100644 --- a/libs/libpam/patches/000-OE-pam-no-innetgr.patch +++ b/libs/libpam/patches/0007-Check-if-innetgr-is-available-at-compile-time.patch @@ -1,42 +1,44 @@ +From c681bd104627139eac2f40fe303e1f67676233e8 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 17 Jun 2015 15:33:43 +0800 +Subject: [PATCH 7/7] Check if innetgr is available at compile time. + innetgr may not be there so make sure that when innetgr is not present then we inform about it and not use it. --Khem +* modules/pam_group/pam_group.c: ditto +* modules/pam_succeed_if/pam_succeed_if.c: ditto +* modules/pam_time/pam_time.c: ditto + +Signed-off-by: Khem Raj +Signed-off-by: Yousong Zhou +--- + modules/pam_group/pam_group.c | 4 ++++ + modules/pam_succeed_if/pam_succeed_if.c | 17 +++++++++++++---- + modules/pam_time/pam_time.c | 4 ++++ + 3 files changed, 21 insertions(+), 4 deletions(-) + +diff --git a/modules/pam_group/pam_group.c b/modules/pam_group/pam_group.c +index be5f20f..6a065ca 100644 --- a/modules/pam_group/pam_group.c +++ b/modules/pam_group/pam_group.c -@@ -656,7 +656,11 @@ static int check_account(pam_handle_t *p +@@ -656,7 +656,11 @@ static int check_account(pam_handle_t *pamh, const char *service, } /* If buffer starts with @, we are using netgroups */ if (buffer[0] == '@') +#ifdef HAVE_INNETGR good &= innetgr (&buffer[1], NULL, user, NULL); +#else -+ pam_syslog (pamh, LOG_ERR, "pam_group does not have netgroup support"); ++ pam_syslog (pamh, LOG_ERR, "pam_group does not have netgroup support"); +#endif /* otherwise, if the buffer starts with %, it's a UNIX group */ else if (buffer[0] == '%') good &= pam_modutil_user_in_group_nam_nam(pamh, user, &buffer[1]); ---- a/modules/pam_time/pam_time.c -+++ b/modules/pam_time/pam_time.c -@@ -555,9 +555,13 @@ check_account(pam_handle_t *pamh, const - } - /* If buffer starts with @, we are using netgroups */ - if (buffer[0] == '@') -- good &= innetgr (&buffer[1], NULL, user, NULL); -+#ifdef HAVE_INNETGR -+ good &= innetgr (&buffer[1], NULL, user, NULL); -+#else -+ pam_syslog (pamh, LOG_ERR, "pam_time does not have netgroup support"); -+#endif - else -- good &= logic_field(pamh, user, buffer, count, is_same); -+ good &= logic_field(pamh, user, buffer, count, is_same); - D(("with user: %s", good ? "passes":"fails" )); - - /* here we get the time field */ +diff --git a/modules/pam_succeed_if/pam_succeed_if.c b/modules/pam_succeed_if/pam_succeed_if.c +index aa828fc..c0c68a0 100644 --- a/modules/pam_succeed_if/pam_succeed_if.c +++ b/modules/pam_succeed_if/pam_succeed_if.c -@@ -231,18 +231,27 @@ evaluate_notingroup(pam_handle_t *pamh, +@@ -231,18 +231,27 @@ evaluate_notingroup(pam_handle_t *pamh, const char *user, const char *group) } /* Return PAM_SUCCESS if the (host,user) is in the netgroup. */ static int @@ -47,7 +49,7 @@ then we inform about it and not use it. if (innetgr(group, host, user, NULL) == 1) return PAM_SUCCESS; +#else -+ pam_syslog (pamh, LOG_ERR, "pam_succeed_if does not have netgroup support"); ++ pam_syslog (pamh, LOG_ERR, "pam_succeed_if does not have netgroup support"); +#endif + return PAM_AUTH_ERR; @@ -83,3 +85,22 @@ then we inform about it and not use it. } /* Fail closed. */ return PAM_SERVICE_ERR; +diff --git a/modules/pam_time/pam_time.c b/modules/pam_time/pam_time.c +index c94737c..0b34a14 100644 +--- a/modules/pam_time/pam_time.c ++++ b/modules/pam_time/pam_time.c +@@ -555,7 +555,11 @@ check_account(pam_handle_t *pamh, const char *service, + } + /* If buffer starts with @, we are using netgroups */ + if (buffer[0] == '@') ++#ifdef HAVE_INNETGR + good &= innetgr (&buffer[1], NULL, user, NULL); ++#else ++ pam_syslog (pamh, LOG_ERR, "pam_time does not have netgroup support"); ++#endif + else + good &= logic_field(pamh, user, buffer, count, is_same); + D(("with user: %s", good ? "passes":"fails" )); +-- +1.7.10.4 + diff --git a/libs/libpam/patches/001-no_nis.patch b/libs/libpam/patches/001-no_nis.patch deleted file mode 100644 index c9988c7fb..000000000 --- a/libs/libpam/patches/001-no_nis.patch +++ /dev/null @@ -1,68 +0,0 @@ ---- a/modules/pam_access/pam_access.c -+++ b/modules/pam_access/pam_access.c -@@ -44,7 +44,7 @@ - #include - #include - #include --#ifdef HAVE_RPCSVC_YPCLNT_H -+#ifdef HAVE_RPCSVC_YPCLNT_H && USE_NIS - #include - #endif - #ifdef HAVE_LIBAUDIT ---- a/modules/pam_unix/pam_unix_passwd.c -+++ b/modules/pam_unix/pam_unix_passwd.c -@@ -79,18 +79,18 @@ - #include "passverify.h" - #include "bigcrypt.h" - --#if (HAVE_YP_GET_DEFAULT_DOMAIN || HAVE_GETDOMAINNAME) && HAVE_YP_MASTER -+#if (HAVE_YP_GET_DEFAULT_DOMAIN || HAVE_GETDOMAINNAME) && HAVE_YP_MASTER && USE_NIS - # define HAVE_NIS - #endif - - #ifdef HAVE_NIS - # include - --# if HAVE_RPCSVC_YP_PROT_H -+# if HAVE_RPCSVC_YP_PROT_H && USE_NIS - # include - # endif - --# if HAVE_RPCSVC_YPCLNT_H -+# if HAVE_RPCSVC_YPCLNT_H && USE_NIS - # include - # endif - ---- a/modules/pam_unix/support.c -+++ b/modules/pam_unix/support.c -@@ -19,7 +19,7 @@ - #include - #include - #include --#ifdef HAVE_RPCSVC_YPCLNT_H -+#ifdef HAVE_RPCSVC_YPCLNT_H && USE_NIS - #include - #endif - -@@ -402,7 +402,7 @@ int _unix_getpwnam(pam_handle_t *pamh, c - } - } - --#if defined(HAVE_YP_GET_DEFAULT_DOMAIN) && defined (HAVE_YP_BIND) && defined (HAVE_YP_MATCH) && defined (HAVE_YP_UNBIND) -+#if defined(HAVE_YP_GET_DEFAULT_DOMAIN) && defined (HAVE_YP_BIND) && defined (HAVE_YP_MATCH) && defined (HAVE_YP_UNBIND) && (USE_NIS) - if (!matched && nis) { - char *userinfo = NULL, *domain = NULL; - int len = 0, i; ---- a/modules/pam_unix/yppasswd_xdr.c -+++ b/modules/pam_unix/yppasswd_xdr.c -@@ -15,6 +15,10 @@ - #ifdef HAVE_RPC_RPC_H - - #include -+#ifdef USE_NIS -+#include -+#include -+#endif - #include "yppasswd.h" - - bool_t diff --git a/libs/libpam/patches/002-no_yywrap.patch b/libs/libpam/patches/002-no_yywrap.patch deleted file mode 100644 index 0d73e4be0..000000000 --- a/libs/libpam/patches/002-no_yywrap.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/conf/pam_conv1/pam_conv_l.c -+++ b/conf/pam_conv1/pam_conv_l.c -@@ -534,7 +534,9 @@ void yyset_lineno (int line_number ); - #ifdef __cplusplus - extern "C" int yywrap (void ); - #else --extern int yywrap (void ); -+int yywrap (void ) { -+ return 1; -+} - #endif - #endif - ---- a/doc/specs/parse_l.c -+++ b/doc/specs/parse_l.c -@@ -520,7 +520,9 @@ void yyset_lineno (int line_number ); - #ifdef __cplusplus - extern "C" int yywrap (void ); - #else --extern int yywrap (void ); -+int yywrap (void ) { -+ return 1; -+} - #endif - #endif - diff --git a/libs/libpam/patches/003-no_doc.patch b/libs/libpam/patches/003-no_doc.patch deleted file mode 100644 index d36621514..000000000 --- a/libs/libpam/patches/003-no_doc.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/Makefile.am -+++ b/Makefile.am -@@ -4,7 +4,7 @@ - - AUTOMAKE_OPTIONS = 1.9 gnu dist-bzip2 check-news - --SUBDIRS = libpam tests libpamc libpam_misc modules po conf doc examples xtests -+SUBDIRS = libpam tests libpamc libpam_misc modules po conf examples xtests - - CLEANFILES = *~ - ---- a/Makefile.in -+++ b/Makefile.in -@@ -288,7 +288,7 @@ top_build_prefix = @top_build_prefix@ - top_builddir = @top_builddir@ - top_srcdir = @top_srcdir@ - AUTOMAKE_OPTIONS = 1.9 gnu dist-bzip2 check-news --SUBDIRS = libpam tests libpamc libpam_misc modules po conf doc examples xtests -+SUBDIRS = libpam tests libpamc libpam_misc modules po conf examples xtests - CLEANFILES = *~ - EXTRA_DIST = pgp.keys.asc CHANGELOG ChangeLog-CVS Copyright Make.xml.rules - ACLOCAL_AMFLAGS = -I m4 diff --git a/libs/libpam/patches/004-fix_lib64.patch b/libs/libpam/patches/004-fix_lib64.patch deleted file mode 100644 index 5605d8298..000000000 --- a/libs/libpam/patches/004-fix_lib64.patch +++ /dev/null @@ -1,16 +0,0 @@ ---- a/configure.in -+++ b/configure.in -@@ -28,12 +28,7 @@ dnl If we use /usr as prefix, use /etc f - fi - if test ${libdir} = '${exec_prefix}/lib' - then -- case "`uname -m`" in -- x86_64|ppc64|s390x|sparc64) -- libdir="/lib64" ;; -- *) -- libdir="/lib" ;; -- esac -+ libdir="/lib" - fi - if test ${sbindir} = '${exec_prefix}/sbin' - then diff --git a/libs/libpam/patches/005-fix_ruserok.patch b/libs/libpam/patches/005-fix_ruserok.patch deleted file mode 100644 index 1f0f46337..000000000 --- a/libs/libpam/patches/005-fix_ruserok.patch +++ /dev/null @@ -1,364 +0,0 @@ ---- a/modules/pam_rhosts/pam_rhosts.c -+++ b/modules/pam_rhosts/pam_rhosts.c -@@ -43,6 +43,361 @@ - #include - #include - -+#ifdef __UCLIBC__ -+ -+#include -+#include -+ -+ -+int __check_rhosts_file = 1; -+ -+/* Extremely paranoid file open function. */ -+static FILE * -+iruserfopen (const char *file, uid_t okuser) -+{ -+ struct stat st; -+ char *cp = NULL; -+ FILE *res = NULL; -+ -+ /* If not a regular file, if owned by someone other than user or -+ root, if writeable by anyone but the owner, or if hardlinked -+ anywhere, quit. */ -+ if (lstat (file, &st)) -+ cp = "lstat failed"; -+ else if (!S_ISREG (st.st_mode)) -+ cp = "not regular file"; -+ else -+ { -+ res = fopen (file, "r"); -+ if (!res) -+ cp = "cannot open"; -+ else if (fstat (fileno (res), &st) < 0) -+ cp = "fstat failed"; -+ else if (st.st_uid && st.st_uid != okuser) -+ cp = "bad owner"; -+ else if (st.st_mode & (S_IWGRP|S_IWOTH)) -+ cp = "writeable by other than owner"; -+ else if (st.st_nlink > 1) -+ cp = "hard linked somewhere"; -+ } -+ -+ /* If there were any problems, quit. */ -+ if (cp != NULL) -+ { -+ if (res) -+ fclose (res); -+ return NULL; -+ } -+ -+ return res; -+} -+ -+/* -+ * Returns 1 for blank lines (or only comment lines) and 0 otherwise -+ */ -+static int -+__isempty(char *p) -+{ -+ while (*p && isspace (*p)) { -+ ++p; -+ } -+ -+ return (*p == '\0' || *p == '#') ? 1 : 0 ; -+} -+ -+/* Returns 1 on positive match, 0 on no match, -1 on negative match. */ -+static int -+__icheckhost (u_int32_t raddr, char *lhost, const char *rhost) -+{ -+ struct hostent *hp; -+ u_int32_t laddr; -+ int negate=1; /* Multiply return with this to get -1 instead of 1 */ -+ char **pp; -+ -+#ifdef __UCLIBC_HAS_REENTRANT_RPC__ -+ int save_errno; -+ size_t buflen; -+ char *buffer; -+ struct hostent hostbuf; -+ int herr; -+#endif -+ -+#ifdef HAVE_NETGROUP -+ /* Check nis netgroup. */ -+ if (strncmp ("+@", lhost, 2) == 0) -+ return innetgr (&lhost[2], rhost, NULL, NULL); -+ -+ if (strncmp ("-@", lhost, 2) == 0) -+ return -innetgr (&lhost[2], rhost, NULL, NULL); -+#endif /* HAVE_NETGROUP */ -+ -+ /* -host */ -+ if (strncmp ("-", lhost,1) == 0) { -+ negate = -1; -+ lhost++; -+ } else if (strcmp ("+",lhost) == 0) { -+ return 1; /* asking for trouble, but ok.. */ -+ } -+ -+ /* Try for raw ip address first. */ -+ if (isdigit (*lhost) && (laddr = inet_addr (lhost)) != INADDR_NONE) -+ return negate * (! (raddr ^ laddr)); -+ -+ /* Better be a hostname. */ -+#ifdef __UCLIBC_HAS_REENTRANT_RPC__ -+ buflen = 1024; -+ buffer = malloc(buflen); -+ save_errno = errno; -+ -+ while (gethostbyname_r (lhost, &hostbuf, buffer, buflen, &hp, &herr) -+ != 0) { -+ free(buffer); -+ return (0); -+ } -+ free(buffer); -+ __set_errno (save_errno); -+#else -+ hp = gethostbyname(lhost); -+#endif /* __UCLIBC_HAS_REENTRANT_RPC__ */ -+ -+ if (hp == NULL) -+ return 0; -+ -+ /* Spin through ip addresses. */ -+ for (pp = hp->h_addr_list; *pp; ++pp) -+ if (!memcmp (&raddr, *pp, sizeof (u_int32_t))) -+ return negate; -+ -+ /* No match. */ -+ return (0); -+} -+ -+/* Returns 1 on positive match, 0 on no match, -1 on negative match. */ -+static int -+__icheckuser (const char *luser, const char *ruser) -+{ -+ -+ /* -+ luser is user entry from .rhosts/hosts.equiv file -+ ruser is user id on remote host -+ */ -+ -+#ifdef HAVE_NETGROUP -+ /* [-+]@netgroup */ -+ if (strncmp ("+@", luser, 2) == 0) -+ return innetgr (&luser[2], NULL, ruser, NULL); -+ -+ if (strncmp ("-@", luser,2) == 0) -+ return -innetgr (&luser[2], NULL, ruser, NULL); -+#endif /* HAVE_NETGROUP */ -+ -+ /* -user */ -+ if (strncmp ("-", luser, 1) == 0) -+ return -(strcmp (&luser[1], ruser) == 0); -+ -+ /* + */ -+ if (strcmp ("+", luser) == 0) -+ return 1; -+ -+ /* simple string match */ -+ return strcmp (ruser, luser) == 0; -+} -+ -+/* -+ * Returns 0 if positive match, -1 if _not_ ok. -+ */ -+static int -+__ivaliduser2(FILE *hostf, u_int32_t raddr, const char *luser, -+ const char *ruser, const char *rhost) -+{ -+ register const char *user; -+ register char *p; -+ int hcheck, ucheck; -+ char *buf = NULL; -+ size_t bufsize = 0; -+ int retval = -1; -+ -+ while (getline (&buf, &bufsize, hostf) > 0) { -+ buf[bufsize - 1] = '\0'; /* Make sure it's terminated. */ -+ p = buf; -+ -+ /* Skip empty or comment lines */ -+ if (__isempty (p)) { -+ continue; -+ } -+ -+ /* Skip lines that are too long. */ -+ if (strchr (p, '\n') == NULL) { -+ int ch = getc_unlocked (hostf); -+ -+ while (ch != '\n' && ch != EOF) -+ ch = getc_unlocked (hostf); -+ continue; -+ } -+ -+ for (;*p && !isspace(*p); ++p) { -+ *p = tolower (*p); -+ } -+ -+ /* Next we want to find the permitted name for the remote user. */ -+ if (*p == ' ' || *p == '\t') { -+ /* terminate hostname and skip spaces */ -+ for (*p++='\0'; *p && isspace (*p); ++p); -+ -+ user = p; /* this is the user's name */ -+ while (*p && !isspace (*p)) -+ ++p; /* find end of user's name */ -+ } else -+ user = p; -+ -+ *p = '\0'; /* terminate username (+host?) */ -+ -+ /* buf -> host(?) ; user -> username(?) */ -+ -+ /* First check host part */ -+ hcheck = __icheckhost (raddr, buf, rhost); -+ -+ if (hcheck < 0) -+ break; -+ -+ if (hcheck) { -+ /* Then check user part */ -+ if (! (*user)) -+ user = luser; -+ -+ ucheck = __icheckuser (user, ruser); -+ -+ /* Positive 'host user' match? */ -+ if (ucheck > 0) { -+ retval = 0; -+ break; -+ } -+ -+ /* Negative 'host -user' match? */ -+ if (ucheck < 0) -+ break; -+ -+ /* Neither, go on looking for match */ -+ } -+ } -+ -+ free (buf); -+ -+ return retval; -+} -+ -+static int -+iruserok2 (u_int32_t raddr, int superuser, const char *ruser, const char *luser, -+ const char *rhost) -+{ -+ FILE *hostf = NULL; -+ int isbad = -1; -+ -+ if (!superuser) -+ hostf = iruserfopen (_PATH_HEQUIV, 0); -+ -+ if (hostf) { -+ isbad = __ivaliduser2 (hostf, raddr, luser, ruser, rhost); -+ fclose (hostf); -+ -+ if (!isbad) -+ return 0; -+ } -+ -+ if (__check_rhosts_file || superuser) { -+ char *pbuf; -+ struct passwd *pwd; -+ size_t dirlen; -+ uid_t uid; -+ -+#ifdef __UCLIBC_HAS_REENTRANT_RPC__ -+ size_t buflen = sysconf (_SC_GETPW_R_SIZE_MAX); -+ struct passwd pwdbuf; -+ char *buffer = stack_heap_alloc(buflen); -+ -+ if (getpwnam_r (luser, &pwdbuf, buffer, -+ buflen, &pwd) != 0 || pwd == NULL) -+ { -+ stack_heap_free(buffer); -+ return -1; -+ } -+ stack_heap_free(buffer); -+#else -+ if ((pwd = getpwnam(luser)) == NULL) -+ return -1; -+#endif -+ -+ dirlen = strlen (pwd->pw_dir); -+ pbuf = malloc (dirlen + sizeof "/.rhosts"); -+ strcpy (pbuf, pwd->pw_dir); -+ strcat (pbuf, "/.rhosts"); -+ -+ /* Change effective uid while reading .rhosts. If root and -+ reading an NFS mounted file system, can't read files that -+ are protected read/write owner only. */ -+ uid = geteuid (); -+ seteuid (pwd->pw_uid); -+ hostf = iruserfopen (pbuf, pwd->pw_uid); -+ free(pbuf); -+ -+ if (hostf != NULL) { -+ isbad = __ivaliduser2 (hostf, raddr, luser, ruser, rhost); -+ fclose (hostf); -+ } -+ -+ seteuid (uid); -+ return isbad; -+ } -+ return -1; -+} -+ -+int ruserok(const char *rhost, int superuser, const char *ruser, -+ const char *luser) -+{ -+ struct hostent *hp; -+ u_int32_t addr; -+ char **ap; -+#ifdef __UCLIBC_HAS_REENTRANT_RPC__ -+ size_t buflen; -+ char *buffer; -+ int herr; -+ struct hostent hostbuf; -+#endif -+ -+#ifdef __UCLIBC_HAS_REENTRANT_RPC__ -+ buflen = 1024; -+ buffer = stack_heap_alloc(buflen); -+ -+ while (gethostbyname_r (rhost, &hostbuf, buffer, -+ buflen, &hp, &herr) != 0 || hp == NULL) -+ { -+ if (herr != NETDB_INTERNAL || errno != ERANGE) { -+ stack_heap_free(buffer); -+ return -1; -+ } else -+ { -+ /* Enlarge the buffer. */ -+ buflen *= 2; -+ stack_heap_free(buffer); -+ buffer = stack_heap_alloc(buflen); -+ } -+ } -+ stack_heap_free(buffer); -+#else -+ if ((hp = gethostbyname(rhost)) == NULL) { -+ return -1; -+ } -+#endif -+ for (ap = hp->h_addr_list; *ap; ++ap) { -+ memmove(&addr, *ap, sizeof(addr)); -+ if (iruserok2(addr, superuser, ruser, luser, rhost) == 0) -+ return 0; -+ } -+ return -1; -+} -+ -+#endif /* __UCLIBC__ */ -+ - PAM_EXTERN - int pam_sm_authenticate (pam_handle_t *pamh, int flags, int argc, - const char **argv) diff --git a/libs/libpam/patches/006-fix_xdr.patch b/libs/libpam/patches/006-fix_xdr.patch deleted file mode 100644 index 976950608..000000000 --- a/libs/libpam/patches/006-fix_xdr.patch +++ /dev/null @@ -1,271 +0,0 @@ ---- a/modules/pam_unix/yppasswd_xdr.c -+++ b/modules/pam_unix/yppasswd_xdr.c -@@ -21,6 +21,268 @@ - #endif - #include "yppasswd.h" - -+#ifdef __UCLIBC__ -+ -+static const char xdr_zero[BYTES_PER_XDR_UNIT] = {0, 0, 0, 0}; -+ -+/* -+ * XDR integers -+ */ -+bool_t -+xdr_int (XDR *xdrs, int *ip) -+{ -+ -+#if INT_MAX < LONG_MAX -+ long l; -+ -+ switch (xdrs->x_op) -+ { -+ case XDR_ENCODE: -+ l = (long) *ip; -+ return XDR_PUTLONG (xdrs, &l); -+ -+ case XDR_DECODE: -+ if (!XDR_GETLONG (xdrs, &l)) -+ { -+ return FALSE; -+ } -+ *ip = (int) l; -+ case XDR_FREE: -+ return TRUE; -+ } -+ return FALSE; -+#elif INT_MAX == LONG_MAX -+ return xdr_long (xdrs, (long *) ip); -+#elif INT_MAX == SHRT_MAX -+ return xdr_short (xdrs, (short *) ip); -+#else -+#error unexpected integer sizes in xdr_int() -+#endif -+} -+ -+/* -+ * XDR null terminated ASCII strings -+ * xdr_string deals with "C strings" - arrays of bytes that are -+ * terminated by a NULL character. The parameter cpp references a -+ * pointer to storage; If the pointer is null, then the necessary -+ * storage is allocated. The last parameter is the max allowed length -+ * of the string as specified by a protocol. -+ */ -+bool_t -+xdr_string (XDR *xdrs, char **cpp, u_int maxsize) -+{ -+ char *sp = *cpp; /* sp is the actual string pointer */ -+ u_int size; -+ u_int nodesize; -+ -+ /* -+ * first deal with the length since xdr strings are counted-strings -+ */ -+ switch (xdrs->x_op) -+ { -+ case XDR_FREE: -+ if (sp == NULL) -+ { -+ return TRUE; /* already free */ -+ } -+ /* fall through... */ -+ case XDR_ENCODE: -+ if (sp == NULL) -+ return FALSE; -+ size = strlen (sp); -+ break; -+ case XDR_DECODE: -+ break; -+ } -+ if (!xdr_u_int (xdrs, &size)) -+ { -+ return FALSE; -+ } -+ if (size > maxsize) -+ { -+ return FALSE; -+ } -+ nodesize = size + 1; -+ -+ /* -+ * now deal with the actual bytes -+ */ -+ switch (xdrs->x_op) -+ { -+ case XDR_DECODE: -+ if (nodesize == 0) -+ { -+ return TRUE; -+ } -+ if (sp == NULL) -+ *cpp = sp = (char *) mem_alloc (nodesize); -+ if (sp == NULL) -+ { -+#ifdef USE_IN_LIBIO -+ if (_IO_fwide (stderr, 0) > 0) -+ (void) fwprintf (stderr, L"%s", -+ _("xdr_string: out of memory\n")); -+ else -+#endif -+ (void) fputs (_("xdr_string: out of memory\n"), stderr); -+ return FALSE; -+ } -+ sp[size] = 0; -+ /* fall into ... */ -+ -+ case XDR_ENCODE: -+ return xdr_opaque (xdrs, sp, size); -+ -+ case XDR_FREE: -+ mem_free (sp, nodesize); -+ *cpp = NULL; -+ return TRUE; -+ } -+ return FALSE; -+} -+ -+/* -+ * XDR long integers -+ * The definition of xdr_long() is kept for backward -+ * compatibility. Instead xdr_int() should be used. -+ */ -+bool_t -+xdr_long (XDR *xdrs, long *lp) -+{ -+ if (xdrs->x_op == XDR_ENCODE -+ && (sizeof (int32_t) == sizeof (long) -+ || (int32_t) *lp == *lp)) -+ return XDR_PUTLONG (xdrs, lp); -+ -+ if (xdrs->x_op == XDR_DECODE) -+ return XDR_GETLONG (xdrs, lp); -+ -+ if (xdrs->x_op == XDR_FREE) -+ return TRUE; -+ -+ return FALSE; -+} -+ -+/* -+ * XDR unsigned integers -+ */ -+bool_t -+xdr_u_int (XDR *xdrs, u_int *up) -+{ -+#if UINT_MAX < ULONG_MAX -+ u_long l; -+ -+ switch (xdrs->x_op) -+ { -+ case XDR_ENCODE: -+ l = (u_long) * up; -+ return XDR_PUTLONG (xdrs, (long *) &l); -+ -+ case XDR_DECODE: -+ if (!XDR_GETLONG (xdrs, (long *) &l)) -+ { -+ return FALSE; -+ } -+ *up = (u_int) l; -+ case XDR_FREE: -+ return TRUE; -+ } -+ return FALSE; -+#elif UINT_MAX == ULONG_MAX -+ return xdr_u_long (xdrs, (u_long *) up); -+#elif UINT_MAX == USHRT_MAX -+ return xdr_short (xdrs, (short *) up); -+#else -+#error unexpected integer sizes in xdr_u_int() -+#endif -+} -+ -+/* -+ * XDR opaque data -+ * Allows the specification of a fixed size sequence of opaque bytes. -+ * cp points to the opaque object and cnt gives the byte length. -+ */ -+bool_t -+xdr_opaque (XDR *xdrs, caddr_t cp, u_int cnt) -+{ -+ u_int rndup; -+ static char crud[BYTES_PER_XDR_UNIT]; -+ -+ /* -+ * if no data we are done -+ */ -+ if (cnt == 0) -+ return TRUE; -+ -+ /* -+ * round byte count to full xdr units -+ */ -+ rndup = cnt % BYTES_PER_XDR_UNIT; -+ if (rndup > 0) -+ rndup = BYTES_PER_XDR_UNIT - rndup; -+ -+ switch (xdrs->x_op) -+ { -+ case XDR_DECODE: -+ if (!XDR_GETBYTES (xdrs, cp, cnt)) -+ { -+ return FALSE; -+ } -+ if (rndup == 0) -+ return TRUE; -+ return XDR_GETBYTES (xdrs, (caddr_t)crud, rndup); -+ -+ case XDR_ENCODE: -+ if (!XDR_PUTBYTES (xdrs, cp, cnt)) -+ { -+ return FALSE; -+ } -+ if (rndup == 0) -+ return TRUE; -+ return XDR_PUTBYTES (xdrs, xdr_zero, rndup); -+ -+ case XDR_FREE: -+ return TRUE; -+ } -+ return FALSE; -+} -+ -+/* -+ * XDR unsigned long integers -+ * The definition of xdr_u_long() is kept for backward -+ * compatibility. Instead xdr_u_int() should be used. -+ */ -+bool_t -+xdr_u_long (XDR *xdrs, u_long *ulp) -+{ -+ switch (xdrs->x_op) -+ { -+ case XDR_DECODE: -+ { -+ long int tmp; -+ -+ if (XDR_GETLONG (xdrs, &tmp) == FALSE) -+ return FALSE; -+ -+ *ulp = (uint32_t) tmp; -+ return TRUE; -+ } -+ -+ case XDR_ENCODE: -+ if (sizeof (uint32_t) != sizeof (u_long) -+ && (uint32_t) *ulp != *ulp) -+ return FALSE; -+ -+ return XDR_PUTLONG (xdrs, (long *) ulp); -+ -+ case XDR_FREE: -+ return TRUE; -+ } -+ return FALSE; -+} -+ -+#endif /* UCLIBC */ -+ - bool_t - xdr_xpasswd(XDR * xdrs, xpasswd * objp) - { diff --git a/libs/libpam/patches/007-cve-2014-2583.patch b/libs/libpam/patches/007-cve-2014-2583.patch deleted file mode 100644 index 8d24bead6..000000000 --- a/libs/libpam/patches/007-cve-2014-2583.patch +++ /dev/null @@ -1,52 +0,0 @@ -From 9dcead87e6d7f66d34e7a56d11a30daca367dffb Mon Sep 17 00:00:00 2001 -From: "Dmitry V. Levin" -Date: Wed, 26 Mar 2014 22:17:23 +0000 -Subject: pam_timestamp: fix potential directory traversal issue (ticket #27) - -pam_timestamp uses values of PAM_RUSER and PAM_TTY as components of -the timestamp pathname it creates, so extra care should be taken to -avoid potential directory traversal issues. - -* modules/pam_timestamp/pam_timestamp.c (check_tty): Treat -"." and ".." tty values as invalid. -(get_ruser): Treat "." and ".." ruser values, as well as any ruser -value containing '/', as invalid. - -Fixes CVE-2014-2583. - -Reported-by: Sebastian Krahmer - -diff --git a/modules/pam_timestamp/pam_timestamp.c b/modules/pam_timestamp/pam_timestamp.c -index 5193733..b3f08b1 100644 ---- a/modules/pam_timestamp/pam_timestamp.c -+++ b/modules/pam_timestamp/pam_timestamp.c -@@ -158,7 +158,7 @@ check_tty(const char *tty) - tty = strrchr(tty, '/') + 1; - } - /* Make sure the tty wasn't actually a directory (no basename). */ -- if (strlen(tty) == 0) { -+ if (!strlen(tty) || !strcmp(tty, ".") || !strcmp(tty, "..")) { - return NULL; - } - return tty; -@@ -243,6 +243,17 @@ get_ruser(pam_handle_t *pamh, char *ruserbuf, size_t ruserbuflen) - if (pwd != NULL) { - ruser = pwd->pw_name; - } -+ } else { -+ /* -+ * This ruser is used by format_timestamp_name as a component -+ * of constructed timestamp pathname, so ".", "..", and '/' -+ * are disallowed to avoid potential path traversal issues. -+ */ -+ if (!strcmp(ruser, ".") || -+ !strcmp(ruser, "..") || -+ strchr(ruser, '/')) { -+ ruser = NULL; -+ } - } - if (ruser == NULL || strlen(ruser) >= ruserbuflen) { - *ruserbuf = '\0'; --- -cgit v0.10.2 - diff --git a/libs/libradcli/Config.in b/libs/libradcli/Config.in new file mode 100644 index 000000000..35c3a223b --- /dev/null +++ b/libs/libradcli/Config.in @@ -0,0 +1,10 @@ +# radcli avanced configuration + +menu "Configuration" + depends on PACKAGE_libradcli + +config RADCLI_TLS + bool "enable TLS support" + default y + +endmenu diff --git a/libs/libradcli/Makefile b/libs/libradcli/Makefile new file mode 100644 index 000000000..00af18f99 --- /dev/null +++ b/libs/libradcli/Makefile @@ -0,0 +1,75 @@ +# +# Copyright (C) 2015 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:=libradcli +PKG_VERSION:=1.2.1 +PKG_RELEASE:=1 + +PKG_SOURCE:=radcli-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://github.com/radcli/radcli/releases/download/radcli_1_2_1/ +PKG_MD5SUM:=48f917ed3822ed2d91a5e90309a80812 +PKG_BUILD_DIR:=$(BUILD_DIR)/radcli-$(PKG_VERSION) + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libradcli + SECTION:=libs + CATEGORY:=Libraries + TITLE:=A library for radius clients + URL:=http://radcli.github.io/radcli/ + MAINTAINER:=Nikos Mavrogiannopoulos + DEPENDS:= +RADCLI_TLS:libgnutls +libnettle +endef + +define Package/libradcli/decription + The radcli library is a library for writing RADIUS Clients. The library's + approach is to allow writing RADIUS-aware application in less than 50 lines + of C code. It was based originally on freeradius-client and is source + compatible with it. +endef + +CONFIGURE_ARGS+= \ + --enable-legacy-compat + +ifneq ($(CONFIG_RADCLI_TLS),y) +CONFIGURE_ARGS += --without-tls +endif + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/radcli + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/radcli/radcli.h \ + $(PKG_INSTALL_DIR)/usr/include/radcli/version.h \ + $(1)/usr/include/radcli + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/freeradius-client.h \ + $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libradcli.so* \ + $(PKG_INSTALL_DIR)/usr/lib/libfreeradius-client.so \ + $(1)/usr/lib/ +endef + +define Package/libradcli/conffiles +/etc/radcli/radiusclient.conf +endef + +define Package/libradcli/install + $(INSTALL_DIR) $(1)/etc/radcli + $(INSTALL_CONF) $(PKG_BUILD_DIR)/etc/radiusclient.conf $(1)/etc/radcli/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libradcli.so.* \ + $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libradcli)) diff --git a/libs/libseccomp/Makefile b/libs/libseccomp/Makefile index e3ff8b44e..1ad5d2bff 100644 --- a/libs/libseccomp/Makefile +++ b/libs/libseccomp/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2005-2010 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,19 +8,22 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libseccomp -PKG_VERSION:=2.2.0 +PKG_VERSION:=2.2.1 PKG_RELEASE:=1 PKG_USE_MIPS16:=0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/seccomp/libseccomp/releases/download/v$(PKG_VERSION)/ -PKG_MD5SUM:=e9509301a1fc024cd10127ac1f31792a +PKG_MD5SUM:=068af8e1bc36fcd4b326ee83875ab4fd PKG_MAINTAINER:=Nikos Mavrogiannopoulos PKG_INSTALL:=1 PKG_LIBTOOL_PATHS:=. lib PKG_CHECK_FORMAT_SECURITY:=0 +PKG_CONFIG_DEPENDS:= \ + CONFIG_KERNEL_SECCOMP + include $(INCLUDE_DIR)/package.mk @@ -50,12 +53,6 @@ define Package/libseccomp/description This package contains the seccomp library. endef -define Build/Configure - $(SED) 's,-I$$$${includedir},,g' $(PKG_BUILD_DIR)/configure - $(SED) 's,-L$$$${libdir},,g' $(PKG_BUILD_DIR)/configure - $(call Build/Configure/Default) -endef - define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib/pkgconfig $(CP) \ diff --git a/libs/libseccomp/patches/100-dont-use-linux-prctl.h-with-musl.patch b/libs/libseccomp/patches/100-dont-use-linux-prctl.h-with-musl.patch new file mode 100644 index 000000000..4093ca353 --- /dev/null +++ b/libs/libseccomp/patches/100-dont-use-linux-prctl.h-with-musl.patch @@ -0,0 +1,14 @@ +Index: libseccomp-2.2.1/src/system.h +=================================================================== +--- libseccomp-2.2.1.orig/src/system.h ++++ libseccomp-2.2.1/src/system.h +@@ -23,7 +23,9 @@ + #define _SYSTEM_H + + #include ++#ifdef __GLIBC__ + #include ++#endif + + #include "configure.h" + diff --git a/libs/libsigc++/Makefile b/libs/libsigc++/Makefile index 66fffb08a..fbb0a5610 100644 --- a/libs/libsigc++/Makefile +++ b/libs/libsigc++/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=libsigc++ -PKG_VERSION:=2.4.0 +PKG_VERSION:=2.4.1 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@GNOME/libsigc++/2.4 -PKG_MD5SUM:=c6cd2259f5ef973e4c8178d0abbdbfa7 +PKG_MD5SUM:=55945ba6e1652f89999e910f6b52047c PKG_MAINTAINER:=Steven Barth PKG_LICENSE:=LGPL-2.1 diff --git a/libs/libsodium/Makefile b/libs/libsodium/Makefile index bd4cb9f39..448109472 100644 --- a/libs/libsodium/Makefile +++ b/libs/libsodium/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libsodium -PKG_VERSION:=1.0.2 +PKG_VERSION:=1.0.3 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://download.libsodium.org/libsodium/releases -PKG_MD5SUM:=dc40eb23e293448c6fc908757738003f +PKG_MD5SUM:=b3bcc98e34d3250f55ae196822307fab PKG_FIXUP:=libtool autoreconf PKG_USE_MIPS16:=0 diff --git a/libs/libtasn1/Makefile b/libs/libtasn1/Makefile index dd106bd1d..2b5a2d4b8 100644 --- a/libs/libtasn1/Makefile +++ b/libs/libtasn1/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libtasn1 -PKG_VERSION:=4.2 +PKG_VERSION:=4.4 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=ftp://ftp.gnu.org/gnu/libtasn1 -PKG_MD5SUM:=414df906df421dee0a5cf7548788d153 +PKG_MD5SUM:=c26d76d1309dd339365c563076599912 #PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/libs/libtorrent/Makefile b/libs/libtorrent/Makefile index f6673acaa..2001235a9 100644 --- a/libs/libtorrent/Makefile +++ b/libs/libtorrent/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libtorrent -PKG_VERSION:=0.13.4-git-0 +PKG_VERSION:=0.13.4-git-1 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git @@ -49,7 +49,8 @@ CONFIGURE_ARGS+= \ --disable-debug \ --enable-openssl \ --disable-instrumentation \ - --with-zlib=$(STAGING_DIR)/usr + --with-zlib=$(STAGING_DIR)/usr \ + $(call autoconf_bool,CONFIG_IPV6,ipv6) define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include diff --git a/libs/libugpio/Makefile b/libs/libugpio/Makefile new file mode 100644 index 000000000..66168c1e5 --- /dev/null +++ b/libs/libugpio/Makefile @@ -0,0 +1,72 @@ +# +# Copyright (C) 2012-2015 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:=libugpio +PKG_VERSION:=0.0.6 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=https://github.com/mhei/libugpio/releases/download/v$(PKG_VERSION) +PKG_MD5SUM:=09c35abbc25f7ebff125bc43ff21ac35 + +PKG_LICENSE:=LGPL-2.1+ +PKG_LICENSE_FILES:=COPYING.LESSER + +PKG_MAINTAINER:=Michael Heimpold + +PKG_INSTALL:=1 +PKG_BUILD_PARALLEL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libugpio + SECTION:=libs + CATEGORY:=Libraries + URL:=https://github.com/mhei/libugpio + TITLE:=Library for using sysfs gpio interface from C programs + DEPENDS:=@GPIO_SUPPORT +endef + +define Package/libugpio/description + libugpio is a library to ease the use of linux kernel's sysfs + gpio interface from C programs and/or other libraries. +endef + +define Package/gpioctl-sysfs + SECTION:=utils + CATEGORY:=Utilities + TITLE:=Tool for controlling gpio pins + DEPENDS:=+libugpio +endef + +define Package/gpioctl-sysfs/description + Tool for controlling gpio pins using the sysfs api provided by the kernel. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/ugpio $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libugpio.{so*,a} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libugpio.pc $(1)/usr/lib/pkgconfig/ +endef + +define Package/libugpio/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libugpio.so* $(1)/usr/lib/ +endef + +define Package/gpioctl-sysfs/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpioctl $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,libugpio)) +$(eval $(call BuildPackage,gpioctl-sysfs)) diff --git a/libs/libupnpp/Makefile b/libs/libupnpp/Makefile index 8c9071db5..923187465 100644 --- a/libs/libupnpp/Makefile +++ b/libs/libupnpp/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libupnpp -PKG_VERSION:=0.9.0 +PKG_VERSION:=0.11.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.lesbonscomptes.com/upmpdcli/downloads -PKG_MD5SUM:=ff218bbe2df6cf70b73843d951ef838e +PKG_MD5SUM:=faefaef9e7dbfe57d9224cf49aab6e2e PKG_MAINTAINER:=Petko Bordjukov PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING @@ -39,14 +39,13 @@ define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(CP) $(PKG_INSTALL_DIR)/usr/include/libupnpp $(1)/usr/include/ $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp-$(PKG_VERSION).so* $(1)/usr/lib/ - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp.{so,la} $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp.so* $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp.la $(1)/usr/lib/ endef define Package/libupnpp/install $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp-$(PKG_VERSION).so.* $(1)/usr/lib/ - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp.so $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libupnpp.so.* $(1)/usr/lib/ endef $(eval $(call BuildPackage,libupnpp)) diff --git a/libs/libuv/Makefile b/libs/libuv/Makefile new file mode 100644 index 000000000..da1ac326d --- /dev/null +++ b/libs/libuv/Makefile @@ -0,0 +1,73 @@ +# +# Copyright (C) 2015 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:=libuv +PKG_VERSION:=1.6.1 +PKG_RELEASE:=1 + +PKG_LICENSE_FILES:=LICENSE + +PKG_MAINTAINER:=Luka Perkov + +PKG_SOURCE:=$(PKG_NAME)-v$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://libuv.org/dist/v$(PKG_VERSION)/ +PKG_MD5SUM:=51cfa3d8adc05852982e3c742ec3c039 + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-v$(PKG_VERSION) +PKG_BUILD_PARALLEL:=1 + +PKG_INSTALL:=1 +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk + +define Package/libuv + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Cross-platform asychronous I/O library + URL:=https://github.com/libuv/libuv + DEPENDS:=+libpthread +librt +endef + +define Package/libuv/description + libuv is a multi-platform support library with a focus on asynchronous I/O. It + was primarily developed for use by Node.js, but it's also used by Luvit, Julia, + pyuv, and others. +endef + +define Build/Configure + ( cd $(PKG_BUILD_DIR); ./autogen.sh ) + $(call Build/Configure/Default) +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/ + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/* \ + $(1)/usr/include/ + + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libuv.so* \ + $(1)/usr/lib/ + + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libuv.pc \ + $(1)/usr/lib/pkgconfig/ +endef + +define Package/libuv/install + $(INSTALL_DIR) $(1)/usr/lib/ + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libuv.so* \ + $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libuv)) diff --git a/libs/libv4l/Makefile b/libs/libv4l/Makefile index 4fb41ed1b..841ffa50e 100644 --- a/libs/libv4l/Makefile +++ b/libs/libv4l/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2014 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # Copyright (C) 2009 David Cooper # # This is free software, licensed under the GNU General Public License v2. @@ -9,19 +9,22 @@ include $(TOPDIR)/rules.mk PKG_NAME:=v4l-utils -PKG_VERSION:=1.2.1 -PKG_RELEASE:=2 -PKG_USE_MIPS16:=0 +PKG_VERSION:=1.6.3 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.linuxtv.org/downloads/v4l-utils -PKG_MD5SUM:=4cc0fb4ded302ea9e89e5e1b56a7252b +PKG_MD5SUM:=307858616be6374f63bf946307f15a7f PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=GPL-2.0 LGPL-2.1 PKG_LICENSE_FILES:=COPYING COPYING.libv4l +PKG_USE_MIPS16:=0 +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + PKG_BUILD_DEPENDS:=argp-standalone include $(INCLUDE_DIR)/uclibc++.mk @@ -73,24 +76,15 @@ define Package/v4l-utils/description This package contains the video4linux utilities. endef -TARGET_CFLAGS += $(FPIC) +TARGET_CFLAGS += $(FPIC) -std=gnu99 TARGET_LDFLAGS += -largp CONFIGURE_ARGS+= \ + --disable-doxygen-doc \ --disable-libdvbv5 \ --disable-qv4l2 \ --without-jpeg \ -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - DESTDIR="$(PKG_INSTALL_DIR)" \ - all install - $(MAKE) -C $(PKG_BUILD_DIR) \ - DESTDIR="$(PKG_INSTALL_DIR)" \ - LINKTYPE="static" \ - all install -endef - define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/ diff --git a/libs/libv4l/patches/005-test_for_posix_ioctl.patch b/libs/libv4l/patches/005-test_for_posix_ioctl.patch new file mode 100644 index 000000000..e945bbf87 --- /dev/null +++ b/libs/libv4l/patches/005-test_for_posix_ioctl.patch @@ -0,0 +1,23 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -80,6 +80,20 @@ gl_VISIBILITY + AC_CHECK_HEADERS([sys/klog.h]) + AC_CHECK_FUNCS([klogctl]) + ++AC_CACHE_CHECK([for ioctl with POSIX signature], ++ [gl_cv_func_ioctl_posix_signature], ++ [AC_COMPILE_IFELSE( ++ [AC_LANG_PROGRAM( ++ [[#include ]], ++ [[int ioctl (int, int, ...);]]) ++ ], ++ [gl_cv_func_ioctl_posix_signature=yes], ++ [gl_cv_func_ioctl_posix_signature=no]) ++ ]) ++if test "x$gl_cv_func_ioctl_posix_signature" = xyes; then ++ AC_DEFINE([HAVE_POSIX_IOCTL], [1], [Have ioctl with POSIX signature]) ++fi ++ + # Check host os + case "$host_os" in + linux*) diff --git a/libs/libv4l/patches/020-add-missing-includes.patch b/libs/libv4l/patches/020-add-missing-includes.patch index 70107d397..34e0511ab 100644 --- a/libs/libv4l/patches/020-add-missing-includes.patch +++ b/libs/libv4l/patches/020-add-missing-includes.patch @@ -8,3 +8,21 @@ #include #include #include +@@ -36,6 +37,7 @@ + #include + #include + #include ++#include + + #include + #include +--- a/utils/v4l2-ctl/v4l2-ctl-streaming.cpp ++++ b/utils/v4l2-ctl/v4l2-ctl-streaming.cpp +@@ -14,6 +14,7 @@ + #include + #include + #include ++#include + + #include "v4l2-ctl.h" + diff --git a/libs/libv4l/patches/030-musl_compatibility.patch b/libs/libv4l/patches/030-musl_compatibility.patch new file mode 100644 index 000000000..758be2b52 --- /dev/null +++ b/libs/libv4l/patches/030-musl_compatibility.patch @@ -0,0 +1,96 @@ +--- a/lib/libv4lconvert/libv4lsyscall-priv.h ++++ b/lib/libv4lconvert/libv4lsyscall-priv.h +@@ -35,18 +35,23 @@ + which is broken on some systems and doesn't include them itself :( */ + + #ifdef linux ++#define __NEED_off_t + #include + #include + #include + #include + /* On 32 bits archs we always use mmap2, on 64 bits archs there is no mmap2 */ + #ifdef __NR_mmap2 ++#undef SYS_mmap2 + #define SYS_mmap2 __NR_mmap2 + #define MMAP2_PAGE_SHIFT 12 + #else + #define SYS_mmap2 SYS_mmap + #define MMAP2_PAGE_SHIFT 0 + #endif ++#if !(defined(__UCLIBC__) || defined(__GLIBC__)) ++typedef off_t __off_t; ++#endif + #endif + + #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) +--- a/lib/libv4l1/v4l1compat.c ++++ b/lib/libv4l1/v4l1compat.c +@@ -62,7 +62,7 @@ LIBV4L_PUBLIC int open(const char *file, + return fd; + } + +-#ifdef linux ++#if defined(linux) && (defined(__GLIBC__) || defined(__UCLIBC__)) + LIBV4L_PUBLIC int open64(const char *file, int oflag, ...) + { + int fd; +@@ -94,7 +94,11 @@ LIBV4L_PUBLIC int dup(int fd) + return v4l1_dup(fd); + } + ++#ifdef HAVE_POSIX_IOCTL ++LIBV4L_PUBLIC int ioctl(int fd, int request, ...) ++#else + LIBV4L_PUBLIC int ioctl(int fd, unsigned long int request, ...) ++#endif + { + void *arg; + va_list ap; +@@ -112,12 +116,12 @@ LIBV4L_PUBLIC ssize_t read(int fd, void + } + + LIBV4L_PUBLIC void *mmap(void *start, size_t length, int prot, int flags, int fd, +- __off_t offset) ++ off_t offset) + { + return v4l1_mmap(start, length, prot, flags, fd, offset); + } + +-#ifdef linux ++#if defined(linux) && (defined(__GLIBC__) || defined(__UCLIBC__)) + LIBV4L_PUBLIC void *mmap64(void *start, size_t length, int prot, int flags, int fd, + __off64_t offset) + { +--- a/lib/libv4l2/v4l2convert.c ++++ b/lib/libv4l2/v4l2convert.c +@@ -86,7 +86,7 @@ LIBV4L_PUBLIC int open(const char *file, + return fd; + } + +-#ifdef linux ++#if defined(linux) && (defined(__GLIBC__) || defined(__UCLIBC__)) + LIBV4L_PUBLIC int open64(const char *file, int oflag, ...) + { + int fd; +@@ -121,7 +121,11 @@ LIBV4L_PUBLIC int dup(int fd) + return v4l2_dup(fd); + } + ++#ifdef HAVE_POSIX_IOCTL ++LIBV4L_PUBLIC int ioctl(int fd, int request, ...) ++#else + LIBV4L_PUBLIC int ioctl(int fd, unsigned long int request, ...) ++#endif + { + void *arg; + va_list ap; +@@ -144,7 +148,7 @@ LIBV4L_PUBLIC void *mmap(void *start, si + return v4l2_mmap(start, length, prot, flags, fd, offset); + } + +-#ifdef linux ++#if defined(linux) && (defined(__GLIBC__) || defined(__UCLIBC__)) + LIBV4L_PUBLIC void *mmap64(void *start, size_t length, int prot, int flags, int fd, + __off64_t offset) + { diff --git a/libs/libvorbis/Makefile b/libs/libvorbis/Makefile index 6ce3734fe..aa1c9295a 100644 --- a/libs/libvorbis/Makefile +++ b/libs/libvorbis/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 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:=libvorbis -PKG_VERSION:=1.3.4 -PKG_RELEASE:=2 +PKG_VERSION:=1.3.5 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://downloads.xiph.org/releases/vorbis/ -PKG_MD5SUM:=55f2288055e44754275a17c9a2497391 +PKG_MD5SUM:=28cb28097c07a735d6af56e598e1c90f PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=BSD-3-Clause diff --git a/libs/libvpx/Makefile b/libs/libvpx/Makefile index 4d8bb46b6..ae25bddf9 100644 --- a/libs/libvpx/Makefile +++ b/libs/libvpx/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libvpx -PKG_VERSION:=1.3.0 +PKG_VERSION:=1.4.0 PKG_RELEASE:=1 PKG_REV:=v$(PKG_VERSION) diff --git a/libs/libwebsockets/Makefile b/libs/libwebsockets/Makefile index e82e0720a..d9952e6fb 100644 --- a/libs/libwebsockets/Makefile +++ b/libs/libwebsockets/Makefile @@ -1,19 +1,24 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 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:=libwebsockets - -PKG_VERSION:=1.3-chrome37-firefox30 +PKG_VERSION:=1.4-chrome43-firefox-36 PKG_RELEASE:=1 -PKG_SOURCE:=v$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://github.com/warmcat/$(PKG_NAME)/archive/ + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/warmcat/libwebsockets.git +PKG_SOURCE_VERSION:=v$(PKG_VERSION) + PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_SOURCE_SUBDIR) + PKG_LICENSE:=LGPL-2.1+exception PKG_LICENSE_FILES:=LICENSE @@ -38,6 +43,8 @@ define Package/$(PKG_NAME)/Default CATEGORY:=Libraries TITLE:=libwebsockets DEPENDS:=+zlib + URL:=https://libwebsockets.org + MAINTAINER:=Karl Palsson endef define Package/libwebsockets-openssl diff --git a/libs/libwebsockets/patches/0001-cyassl-correct-include-path-for-3.1.x.patch b/libs/libwebsockets/patches/0001-cyassl-correct-include-path-for-3.1.x.patch deleted file mode 100644 index 4413ac929..000000000 --- a/libs/libwebsockets/patches/0001-cyassl-correct-include-path-for-3.1.x.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 4fb4a2353db521667d1ec61480bf8179bf585d5f Mon Sep 17 00:00:00 2001 -From: Karl Palsson -Date: Thu, 14 Aug 2014 16:30:48 +0000 -Subject: [PATCH] cyassl: correct include path for 3.1.x - ---- - lib/private-libwebsockets.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/lib/private-libwebsockets.h b/lib/private-libwebsockets.h -index 4194498..fbd22b5 100755 ---- a/lib/private-libwebsockets.h -+++ b/lib/private-libwebsockets.h -@@ -155,7 +155,7 @@ - #ifdef LWS_OPENSSL_SUPPORT - #ifdef USE_CYASSL - #include --#include -+#include - unsigned char * - SHA1(const unsigned char *d, size_t n, unsigned char *md); - #else --- -1.8.3.1 - diff --git a/libs/libxerces-c/Makefile b/libs/libxerces-c/Makefile index c2dd09727..e892084ea 100644 --- a/libs/libxerces-c/Makefile +++ b/libs/libxerces-c/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libxerces-c -PKG_VERSION:=3.1.1 +PKG_VERSION:=3.1.2 PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=git://git.apache.org/xerces-c.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=Xerces-C_3_1_1 +PKG_SOURCE_VERSION:=Xerces-C_3_1_2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_MAINTAINER:=Álvaro Fernández Rojas @@ -22,10 +22,11 @@ PKG_LICENSE:=Apache-2.0 PKG_LICENSE_FILES:=LICENSE PKG_BUILD_PARALLEL:=1 -PKG_FIXUP:=libtool +PKG_FIXUP:=autoreconf PKG_INSTALL:=1 include $(INCLUDE_DIR)/uclibc++.mk +include $(INCLUDE_DIR)/nls.mk include $(INCLUDE_DIR)/package.mk CONFIGURE_ARGS += \ @@ -34,14 +35,7 @@ CONFIGURE_ARGS += \ --enable-netaccessor-socket \ --enable-msgloader-inmemory -TARGET_CFLAGS += \ - -I$(STAGING_DIR)/usr/lib/libiconv-full/include - -TARGET_CPPFLAGS += \ - -I$(STAGING_DIR)/usr/lib/libiconv-full/include - TARGET_LDFLAGS += \ - -L$(STAGING_DIR)/usr/lib/libiconv-full/lib \ -lm define Package/libxerces-c @@ -49,7 +43,7 @@ define Package/libxerces-c CATEGORY:=Libraries TITLE:=Validating XML parser library for C++ URL:=http://xerces.apache.org/ - DEPENDS:=$(CXX_DEPENDS) +libc +libiconv +libpthread + DEPENDS:=$(CXX_DEPENDS) $(ICONV_DEPENDS) +libc +libpthread endef define Package/libxerces-c-samples @@ -60,12 +54,6 @@ define Package/libxerces-c-samples DEPENDS:=+libxerces-c endef -define Build/Configure - (cd $(PKG_BUILD_DIR)/$(CONFIGURE_PATH); \ - ./reconf;) - $(call Build/Configure/Default) -endef - define Package/libxerces-c/description Xerces-C++ is a validating XML parser written in a portable subset of C++. Xerces-C++ makes it easy to give your application the ability diff --git a/libs/lttng-ust/Makefile b/libs/lttng-ust/Makefile index dc9c8920e..872c5be14 100644 --- a/libs/lttng-ust/Makefile +++ b/libs/lttng-ust/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lttng-ust -PKG_VERSION:=2.6.0 +PKG_VERSION:=2.6.1 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://lttng.org/files/$(PKG_NAME)/ -PKG_MD5SUM:=74ad4826eac76c9dbf50fd3e46523191 +PKG_MD5SUM:=5c7de27a9968e01ac0b08c7c9cf554d0 PKG_LICENSE:=LGPL-2.1 GPL-2.0 PKG_LICENSE_FILES:=COPYING diff --git a/libs/mtdev/Makefile b/libs/mtdev/Makefile new file mode 100644 index 000000000..6f1e0b79c --- /dev/null +++ b/libs/mtdev/Makefile @@ -0,0 +1,56 @@ +# +# Copyright (C) 2007-2015 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:=mtdev +PKG_VERSION:=1.1.5 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=http://bitmath.org/code/mtdev/ +PKG_MD5SUM:=52c9610b6002f71d1642dc1a1cca5ec1 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/mtdev + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Multitouch Protocol Translation Library + URL:=http://bitmath.org/code/mtdev/ +endef + +define Package/mtdev/description + The mtdev is a stand-alone library which transforms all variants of + kernel MT events to the slotted type B protocol. The events put into + mtdev may be from any MT device, specifically type A without contact + tracking, type A with contact tracking, or type B with contact + tracking. See the kernel documentation for further details. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{a,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/ +endef + +define Package/mtdev/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,mtdev)) diff --git a/libs/nspr/Makefile b/libs/nspr/Makefile deleted file mode 100644 index d14d08607..000000000 --- a/libs/nspr/Makefile +++ /dev/null @@ -1,60 +0,0 @@ -# -# Copyright (C) 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:=nspr -PKG_VERSION:=3.16.6 -PKG_RELEASE:=1 - -PKG_BUILD_DIR:=$(BUILD_DIR)/nss-$(PKG_VERSION) -PKG_SOURCE:=nss-$(PKG_VERSION)-with-nspr-4.10.6.tar.gz -PKG_SOURCE_URL:=ftp://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/NSS_3_16_6_RTM/src/ -PKG_MD5SUM:=4722706ea101948712b5ad003629679f -PKG_INSTALL:=1 - -include $(INCLUDE_DIR)/package.mk - -CONFIGURE_PATH=nspr -MAKE_PATH=nspr - -define Package/nspr - SECTION:=libs - CATEGORY:=Libraries - TITLE:=Netscape Portable Runtime (NSPR) - URL:=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSPR - DEPENDS:=+libpthread +librt - MAINTAINER:=Luka Perkov -endef - -define Package/nspr/description - Netscape Portable Runtime (NSPR) provides a platform-neutral API for system - level and libc-like functions. The API is used in the Mozilla clients, many of - Red Hat's and Sun's server applications, and other software offerings. -endef - -CONFIGURE_ARGS += \ - --with-arch=toolchain-default \ - --with-fpu=toolchain-default \ - --with-float-abi=toolchain-default \ - --with-soft-float=toolchain-default - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/ - $(CP) $(PKG_INSTALL_DIR)/usr/include/ $(1)/usr/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/*{a,so} $(1)/usr/lib/ - $(INSTALL_DIR) $(1)/usr/lib/pkgconfig - $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/nspr.pc $(1)/usr/lib/pkgconfig/ -endef - -define Package/nspr/install - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/*so $(1)/usr/lib -endef - -$(eval $(call BuildPackage,nspr)) diff --git a/libs/nspr/patches/001-compile.patch b/libs/nspr/patches/001-compile.patch deleted file mode 100644 index 63b697e7a..000000000 --- a/libs/nspr/patches/001-compile.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/nspr/config/Makefile.in -+++ b/nspr/config/Makefile.in -@@ -30,7 +30,6 @@ CSRCS = now.c - - # This version hasn't been ported for us; the one in mozilla/config has - ifneq ($(OS_ARCH),OS2) --CSRCS += nsinstall.c - - PLSRCS = nfspwd.pl - endif -@@ -84,7 +83,6 @@ else - ifeq (,$(filter-out SYMBIAN WINCE,$(OS_ARCH))) - TARGETS = $(PROGS) - else --PROGS += $(OBJDIR)/nsinstall$(PROG_SUFFIX) - TARGETS = $(PROGS) $(PLSRCS:.pl=) - endif - endif -@@ -114,6 +112,7 @@ endif - $(OBJDIR)/%$(PROG_SUFFIX): $(OBJDIR)/%.$(OBJ_SUFFIX) - @$(MAKE_OBJDIR) - $(CC) $(XCFLAGS) $< $(LDFLAGS) $(XLDOPTS) $(OUTOPTION)$@ -+ gcc nsinstall.c -o nsinstall - - install:: nspr.m4 - $(NSINSTALL) -D $(DESTDIR)$(datadir)/aclocal diff --git a/libs/opencv/Makefile b/libs/opencv/Makefile index 9abc8ad5a..bf80fbe9b 100644 --- a/libs/opencv/Makefile +++ b/libs/opencv/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=opencv -PKG_VERSION:=2.4.10 -PKG_RELEASE:=2 +PKG_VERSION:=2.4.11 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).zip -PKG_SOURCE_URL:=http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/2.4.10/ -PKG_MD5SUM:=ec63952d3a3dff965d5fdde765926821 +PKG_SOURCE_URL:=http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/$(PKG_VERSION)/ +PKG_MD5SUM:=32f498451bff1817a60e1aabc2939575 PKG_LICENSE:=BSD-3-Clause PKG_LICENSE_FILES:=LICENSE @@ -35,7 +35,7 @@ endef define Package/opencv SECTION:=libs CATEGORY:=Libraries - TITLE:=opencv-2.4.10 + TITLE:=opencv-2.4.11 URL:=http://opencv.org/ MAINTAINER:=WRTnode Team DEPENDS:=+libpthread +librt +libstdcpp +zlib +libjpeg @@ -45,8 +45,8 @@ endef PKG_INSTALL:=1 CMAKE_OPTIONS += -DBUILD_opencv_gpu:BOOL=OFF \ - -DWITH_1394:BOOL=OFF -DBUILD_opencv_stitching:BOOL=OFF \ - -DBUILD_opencv_superres:BOOL=OFF -DBUILD_opencv_ts:BOOL=OFF \ + -DWITH_1394:BOOL=OFF -DBUILD_opencv_stitching:BOOL=OFF \ + -DBUILD_opencv_superres:BOOL=OFF -DBUILD_opencv_ts:BOOL=OFF \ -DBUILD_opencv_highgui:BOOL=OFF \ -DBUILD_opencv_videostab:BOOL=OFF \ -DWITH_FFMPEG:BOOL=OFF \ diff --git a/libs/opus/Makefile b/libs/opus/Makefile index dbcb4dd95..ed64c3ed5 100644 --- a/libs/opus/Makefile +++ b/libs/opus/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=opus PKG_VERSION:=1.1 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://downloads.xiph.org/releases/opus/ @@ -31,11 +31,15 @@ define Package/libopus endef define Package/libopus/description - Opus is a totally open, royalty-free, highly versatile audio codec. Opus is - unmatched for interactive speech and music transmission over the Internet, but + Opus is a totally open, royalty-free, highly versatile audio codec. Opus is + unmatched for interactive speech and music transmission over the Internet, but is also intended for storage and streaming applications. endef +CONFIGURE_ARGS+= \ + --disable-doc \ + --disable-extra-programs + define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(CP) $(PKG_INSTALL_DIR)/usr/include/opus $(1)/usr/include/ diff --git a/libs/pcre/Makefile b/libs/pcre/Makefile index 2c708ec86..6a9c4144c 100644 --- a/libs/pcre/Makefile +++ b/libs/pcre/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=pcre -PKG_VERSION:=8.36 -PKG_RELEASE:=1 +PKG_VERSION:=8.37 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=@SF/pcre -PKG_MD5SUM:=b767bc9af0c20bc9c1fe403b0d41ad97 +PKG_MD5SUM:=ed91be292cb01d21bc7e526816c26981 PKG_MAINTAINER:=Thomas Heil PKG_LICENSE:=BSD-3-Clause @@ -36,6 +36,11 @@ define Package/libpcre TITLE:=A Perl Compatible Regular Expression library endef +define Package/libpcre16 + $(call Package/libpcre/default) + TITLE:=A Perl Compatible Regular Expression library (16bit support) +endef + define Package/libpcrecpp $(call Package/libpcre/default) TITLE:=C++ wrapper for Perl Compatible Regular Expression library @@ -47,6 +52,7 @@ TARGET_CFLAGS += $(FPIC) CONFIGURE_ARGS += \ --enable-utf8 \ --enable-unicode-properties \ + --enable-pcre16 \ ifneq ($(CONFIG_PACKAGE_libpcrecpp),) CONFIGURE_ARGS+= --enable-cpp @@ -68,7 +74,7 @@ define Build/InstallDev $(CP) $(PKG_INSTALL_DIR)/usr/include/pcre*.h $(1)/usr/include/ $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre*.{a,so*} $(1)/usr/lib// + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre*.{a,so*} $(1)/usr/lib/ $(INSTALL_DIR) $(1)/usr/lib/pkgconfig $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libpcre*.pc $(1)/usr/lib/pkgconfig/ @@ -77,6 +83,12 @@ endef define Package/libpcre/install $(INSTALL_DIR) $(1)/usr/lib $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre{,posix}.so.* $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre.so $(1)/usr/lib/ +endef + +define Package/libpcre16/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre16.so* $(1)/usr/lib/ endef define Package/libpcrecpp/install @@ -85,4 +97,5 @@ define Package/libpcrecpp/install endef $(eval $(call BuildPackage,libpcre)) +$(eval $(call BuildPackage,libpcre16)) $(eval $(call BuildPackage,libpcrecpp)) diff --git a/libs/pcre/patches/100-pcre-cve-2015-3210.patch b/libs/pcre/patches/100-pcre-cve-2015-3210.patch new file mode 100644 index 000000000..276d09e9a --- /dev/null +++ b/libs/pcre/patches/100-pcre-cve-2015-3210.patch @@ -0,0 +1,32 @@ +Index: pcre-8.37/pcre_compile.c +=================================================================== +--- a/pcre_compile.c ++++ b/pcre_compile.c +@@ -7177,14 +7177,26 @@ + number. If the name is not found, set the value to 0 for a forward + reference. */ + ++ recno = 0; + ng = cd->named_groups; + for (i = 0; i < cd->names_found; i++, ng++) + { + if (namelen == ng->length && + STRNCMP_UC_UC(name, ng->name, namelen) == 0) +- break; ++ { ++ open_capitem *oc; ++ recno = ng->number; ++ if (is_recurse) break; ++ for (oc = cd->open_caps; oc != NULL; oc = oc->next) ++ { ++ if (oc->number == recno) ++ { ++ oc->flag = TRUE; ++ break; ++ } ++ } ++ } + } +- recno = (i < cd->names_found)? ng->number : 0; + + /* Count named back references. */ diff --git a/libs/protobuf/Makefile b/libs/protobuf/Makefile index e1d99f67a..4f45183e2 100644 --- a/libs/protobuf/Makefile +++ b/libs/protobuf/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,15 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=protobuf -PKG_VERSION:=2.5.0 +PKG_VERSION:=2.6.1 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=http://protobuf.googlecode.com/files -PKG_MD5SUM:=a72001a9067a4c2c4e0e836d0f92ece4 +PKG_SOURCE_URL:=https://github.com/google/protobuf/releases/download/v$(PKG_VERSION) +PKG_MD5SUM:=11aaac2d704eef8efd1867a807865d85 + +PKG_LICENSE:=BSD-3-Clause +PKG_LICENSE_FILES:=LICENSE PKG_BUILD_DEPENDS:=protobuf/host -PKG_USE_MIPS16:=0 +PKG_USE_MIPS16:=0# MIPS16 prevents protobuf's usage of the 'sync' asm-opcode PKG_INSTALL:=1 @@ -38,15 +41,7 @@ define Package/protobuf/description of its internal RPC protocols and file formats. endef -define Host/Compile - $(MAKE) -C $(HOST_BUILD_DIR) -endef - -define Host/Install - $(MAKE) -C $(HOST_BUILD_DIR) install -endef - -CONFIGURE_ARGS += --with-protoc=$(HOST_BUILD_DIR)/src/protoc +CONFIGURE_ARGS += --with-protoc=$(STAGING_DIR_HOST)/bin/protoc define Build/InstallDev $(INSTALL_DIR) \ diff --git a/libs/protobuf/patches/001-mipseb-compile.patch b/libs/protobuf/patches/001-mipseb-compile.patch index 6eb059000..f57683396 100644 --- a/libs/protobuf/patches/001-mipseb-compile.patch +++ b/libs/protobuf/patches/001-mipseb-compile.patch @@ -1,11 +1,11 @@ ---- a/src/google/protobuf/stubs/platform_macros.h -+++ b/src/google/protobuf/stubs/platform_macros.h -@@ -49,7 +49,7 @@ - #elif defined(__ARMEL__) - #define GOOGLE_PROTOBUF_ARCH_ARM 1 - #define GOOGLE_PROTOBUF_ARCH_32_BIT 1 +--- - 2015-05-19 16:27:29.770936016 +0200 ++++ protobuf-2.6.1/src/google/protobuf/stubs/platform_macros.h 2015-05-19 13:49:52.115444643 +0200 +@@ -55,7 +55,7 @@ + #elif defined(__aarch64__) + #define GOOGLE_PROTOBUF_ARCH_AARCH64 1 + #define GOOGLE_PROTOBUF_ARCH_64_BIT 1 -#elif defined(__MIPSEL__) +#elif defined(__MIPSEL__) || defined(__MIPSEB__) - #define GOOGLE_PROTOBUF_ARCH_MIPS 1 - #define GOOGLE_PROTOBUF_ARCH_32_BIT 1 - #elif defined(__pnacl__) + #if defined(__LP64__) + #define GOOGLE_PROTOBUF_ARCH_MIPS64 1 + #define GOOGLE_PROTOBUF_ARCH_64_BIT 1 diff --git a/libs/protobuf/patches/003-mips2andHigher-compile.patch b/libs/protobuf/patches/003-mips2andHigher-compile.patch new file mode 100644 index 000000000..df9792894 --- /dev/null +++ b/libs/protobuf/patches/003-mips2andHigher-compile.patch @@ -0,0 +1,11 @@ +--- - 2015-05-19 16:29:09.614344473 +0200 ++++ protobuf-2.6.1/src/google/protobuf/stubs/atomicops_internals_mips_gcc.h 2015-05-19 13:49:52.127442746 +0200 +@@ -150,7 +150,7 @@ + } + + inline void MemoryBarrier() { +- __asm__ __volatile__("sync" : : : "memory"); ++ __asm__ __volatile__(".set mips2; sync; .set mips0" : : : "memory"); + } + + inline void Acquire_Store(volatile Atomic32* ptr, Atomic32 value) { diff --git a/libs/pthsem/Makefile b/libs/pthsem/Makefile index 43fd7aec0..54d7737e1 100644 --- a/libs/pthsem/Makefile +++ b/libs/pthsem/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=pthsem PKG_VERSION:=2.0.8 -PKG_RELEASE:=2 +PKG_RELEASE:=4 PKG_MAINTAINER:=Othmar Truniger PKG_LICENSE:=LGPL-2.1+ @@ -21,6 +21,7 @@ PKG_MD5SUM:=9144b26dcc27e67498d63dd5456f934c PKG_FIXUP:=autoreconf PKG_BUILD_PARALLEL:=1 +PKG_FORTIFY_SOURCE:=0 PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk @@ -37,26 +38,26 @@ define Package/pthsem/description pthsem is an extend version, with support for semaphores added. It can be installed parallel to a normal pth. endef -MAKE_FLAGS += \ - OPTIM="$(TARGET_CFLAGS)" \ - CFLAGS="$(TARGET_CFLAGS)" \ - DESTDIR="$(PKG_INSTALL_DIR)" +# The musl libc provides a proper implementation of sigaltstack() so +# prevent configure from wrongly assuming a broken Linux platform +ifeq ($(CONFIG_USE_MUSL),y) + CONFIGURE_VARS += \ + ac_cv_check_sjlj=ssjlj +endif define Build/InstallDev - $(INSTALL_DIR) $(2)/bin - $(INSTALL_BIN) \ - $(PKG_INSTALL_DIR)/usr/bin/pthsem-config \ - $(2)/bin/ - $(SED) \ - 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \ - $(2)/bin/pthsem-config + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/pthsem-config $(1)/usr/bin/ + $(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(1)/usr/bin/pthsem-config $(INSTALL_DIR) $(1)/usr/include - $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h \ - $(1)/usr/include/ + $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/ $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpthsem.{a,la,so*} \ - $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpthsem.{a,la,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/pthsem.pc $(1)/usr/lib/pkgconfig/ + $(INSTALL_DIR) $(2)/bin + $(LN) ../../usr/bin/pthsem-config $(2)/bin/ endef define Package/pthsem/install diff --git a/libs/qrencode/Makefile b/libs/qrencode/Makefile new file mode 100644 index 000000000..37d39aac1 --- /dev/null +++ b/libs/qrencode/Makefile @@ -0,0 +1,90 @@ +# +# 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:=qrencode +PKG_VERSION:=3.4.4 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://fukuchi.org/works/qrencode/ +PKG_MD5SUM:=be545f3ce36ea8fbb58612d72c4222de +PKG_MAINTAINER:=Jonathan Bennett +PKG_LICENSE:=LGPL-2.1+ +PKG_INSTALL:=1 +PKG_FIXUP:=autoreconf + +include $(INCLUDE_DIR)/package.mk + +define Package/libqrencode + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Library for encoding data in a QR Code symbol + URL:=http://fukuchi.org/works/qrencode/ +endef + +define Package/libqrencode/description +Libqrencode is a C library for encoding data in a QR Code symbol, +a kind of 2D symbology that can be scanned by handy terminals such +as a mobile phone with CCD. The capacity of QR Code is up to 7000 +digits or 4000 characters, and is highly robust. +endef + +define Package/qrencode + SECTION:=utils + CATEGORY:=Utilities + TITLE:=qrencode binary for producing qr codes + URL:=http://fukuchi.org/works/qrencode/ + DEPENDS:=+libqrencode +endef + +define Package/qrencode/description +Qrencode is a C program for encoding data in a QR Code symbol, +a kind of 2D symbology that can be scanned by handy terminals such +as a mobile phone with CCD. The capacity of QR Code is up to 7000 +digits or 4000 characters, and is highly robust. +endef + + +CONFIGURE_ARGS+= \ + --enable-shared \ + --enable-static \ + --disable-rpath \ + --disable-sdltest \ + --without-tests + +TARGET_LDFLAGS+= -s + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + $(TARGET_CONFIGURE_OPTS) \ + CFLAGS="$(TARGET_CFLAGS)" \ + LDFLAGS="$(TARGET_LDFLAGS)" \ + DESTDIR="$(PKG_INSTALL_DIR)" \ + all install +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/include/qrencode.h $(1)/usr/include/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libqrencode.{a,so*} $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/libqrencode.pc $(1)/usr/lib/pkgconfig/ +endef + +define Package/libqrencode/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libqrencode.so* $(1)/usr/lib/ +endef + +define Package/qrencode/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/qrencode $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,libqrencode)) +$(eval $(call BuildPackage,qrencode)) diff --git a/libs/qrencode/patches/001-disable-png.patch b/libs/qrencode/patches/001-disable-png.patch new file mode 100644 index 000000000..345bb6008 --- /dev/null +++ b/libs/qrencode/patches/001-disable-png.patch @@ -0,0 +1,306 @@ +--- a/qrenc.c ++++ b/qrenc.c +@@ -25,7 +25,6 @@ + #include + #include + #include +-#include + #include + + #include "qrencode.h" +@@ -49,7 +48,6 @@ + static int verbose = 0; + + enum imageType { +- PNG_TYPE, + EPS_TYPE, + SVG_TYPE, + ANSI_TYPE, +@@ -60,7 +58,7 @@ + ANSIUTF8_TYPE + }; + +-static enum imageType image_type = PNG_TYPE; ++static enum imageType image_type = SVG_TYPE; + + static const struct option options[] = { + {"help" , no_argument , NULL, 'h'}, +@@ -96,13 +94,13 @@ + if(longopt) { + fprintf(stderr, + "Usage: qrencode [OPTION]... [STRING]\n" +-"Encode input data in a QR Code and save as a PNG or EPS image.\n\n" ++"Encode input data in a QR Code and save as a SVG or EPS image.\n\n" + " -h, --help display the help message. -h displays only the help of short\n" + " options.\n\n" + " -o FILENAME, --output=FILENAME\n" + " write image to FILENAME. If '-' is specified, the result\n" + " will be output to standard output. If -S is given, structured\n" +-" symbols are written to FILENAME-01.png, FILENAME-02.png, ...\n" ++" symbols are written to FILENAME-01.svg, FILENAME-02.svg, ...\n" + " (suffix is removed from FILENAME, if specified)\n" + " -s NUMBER, --size=NUMBER\n" + " specify module size in dots (pixels). (default=3)\n\n" +@@ -116,9 +114,9 @@ + " specify the width of the margins. (default=4 (2 for Micro QR)))\n\n" + " -d NUMBER, --dpi=NUMBER\n" + " specify the DPI of the generated PNG. (default=72)\n\n" +-" -t {PNG,EPS,SVG,ANSI,ANSI256,ASCII,ASCIIi,UTF8,ANSIUTF8}, --type={PNG,EPS,\n" ++" -t {EPS,SVG,ANSI,ANSI256,ASCII,ASCIIi,UTF8,ANSIUTF8}, --type={EPS,\n" + " SVG,ANSI,ANSI256,ASCII,ASCIIi,UTF8,ANSIUTF8}\n" +-" specify the type of the generated image. (default=PNG)\n\n" ++" specify the type of the generated image. (default=SVG)\n\n" + " -S, --structured\n" + " make structured symbols. Version must be specified.\n\n" + " -k, --kanji assume that the input text contains kanji (shift-jis).\n\n" +@@ -133,7 +131,7 @@ + " --background=RRGGBB[AA]\n" + " specify foreground/background color in hexadecimal notation.\n" + " 6-digit (RGB) or 8-digit (RGBA) form are supported.\n" +-" Color output support available only in PNG and SVG.\n" ++" Color output support available only in SVG.\n" + " -V, --version\n" + " display the version number and copyrights of the qrencode.\n\n" + " --verbose\n" +@@ -153,12 +151,12 @@ + } else { + fprintf(stderr, + "Usage: qrencode [OPTION]... [STRING]\n" +-"Encode input data in a QR Code and save as a PNG or EPS image.\n\n" ++"Encode input data in a QR Code and save as a SVG or EPS image.\n\n" + " -h display this message.\n" + " --help display the usage of long options.\n" + " -o FILENAME write image to FILENAME. If '-' is specified, the result\n" + " will be output to standard output. If -S is given, structured\n" +-" symbols are written to FILENAME-01.png, FILENAME-02.png, ...\n" ++" symbols are written to FILENAME-01.svg, FILENAME-02.svg, ...\n" + " (suffix is removed from FILENAME, if specified)\n" + " -s NUMBER specify module size in dots (pixels). (default=3)\n" + " -l {LMQH} specify error correction level from L (lowest) to H (highest).\n" +@@ -166,8 +164,8 @@ + " -v NUMBER specify the version of the symbol. (default=auto)\n" + " -m NUMBER specify the width of the margins. (default=4 (2 for Micro))\n" + " -d NUMBER specify the DPI of the generated PNG. (default=72)\n" +-" -t {PNG,EPS,SVG,ANSI,ANSI256,ASCII,ASCIIi,UTF8,ANSIUTF8}\n" +-" specify the type of the generated image. (default=PNG)\n" ++" -t {EPS,SVG,ANSI,ANSI256,ASCII,ASCIIi,UTF8,ANSIUTF8}\n" ++" specify the type of the generated image. (default=SVG)\n" + " -S make structured symbols. Version must be specified.\n" + " -k assume that the input text contains kanji (shift-jis).\n" + " -c encode lower-case alphabet characters in 8-bit mode. (default)\n" +@@ -178,7 +176,7 @@ + " --background=RRGGBB[AA]\n" + " specify foreground/background color in hexadecimal notation.\n" + " 6-digit (RGB) or 8-digit (RGBA) form are supported.\n" +-" Color output support available only in PNG and SVG.\n" ++" Color output support available only in SVG.\n" + " -V display the version number and copyrights of the qrencode.\n" + " [STRING] input data. If it is not specified, data will be taken from\n" + " standard input.\n" +@@ -253,128 +251,6 @@ + return fp; + } + +-static int writePNG(QRcode *qrcode, const char *outfile) +-{ +- static FILE *fp; // avoid clobbering by setjmp. +- png_structp png_ptr; +- png_infop info_ptr; +- png_colorp palette; +- png_byte alpha_values[2]; +- unsigned char *row, *p, *q; +- int x, y, xx, yy, bit; +- int realwidth; +- +- realwidth = (qrcode->width + margin * 2) * size; +- row = (unsigned char *)malloc((realwidth + 7) / 8); +- if(row == NULL) { +- fprintf(stderr, "Failed to allocate memory.\n"); +- exit(EXIT_FAILURE); +- } +- +- if(outfile[0] == '-' && outfile[1] == '\0') { +- fp = stdout; +- } else { +- fp = fopen(outfile, "wb"); +- if(fp == NULL) { +- fprintf(stderr, "Failed to create file: %s\n", outfile); +- perror(NULL); +- exit(EXIT_FAILURE); +- } +- } +- +- png_ptr = png_create_write_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL); +- if(png_ptr == NULL) { +- fprintf(stderr, "Failed to initialize PNG writer.\n"); +- exit(EXIT_FAILURE); +- } +- +- info_ptr = png_create_info_struct(png_ptr); +- if(info_ptr == NULL) { +- fprintf(stderr, "Failed to initialize PNG write.\n"); +- exit(EXIT_FAILURE); +- } +- +- if(setjmp(png_jmpbuf(png_ptr))) { +- png_destroy_write_struct(&png_ptr, &info_ptr); +- fprintf(stderr, "Failed to write PNG image.\n"); +- exit(EXIT_FAILURE); +- } +- +- palette = (png_colorp) malloc(sizeof(png_color) * 2); +- if(palette == NULL) { +- fprintf(stderr, "Failed to allocate memory.\n"); +- exit(EXIT_FAILURE); +- } +- palette[0].red = fg_color[0]; +- palette[0].green = fg_color[1]; +- palette[0].blue = fg_color[2]; +- palette[1].red = bg_color[0]; +- palette[1].green = bg_color[1]; +- palette[1].blue = bg_color[2]; +- alpha_values[0] = fg_color[3]; +- alpha_values[1] = bg_color[3]; +- png_set_PLTE(png_ptr, info_ptr, palette, 2); +- png_set_tRNS(png_ptr, info_ptr, alpha_values, 2, NULL); +- +- png_init_io(png_ptr, fp); +- png_set_IHDR(png_ptr, info_ptr, +- realwidth, realwidth, +- 1, +- PNG_COLOR_TYPE_PALETTE, +- PNG_INTERLACE_NONE, +- PNG_COMPRESSION_TYPE_DEFAULT, +- PNG_FILTER_TYPE_DEFAULT); +- png_set_pHYs(png_ptr, info_ptr, +- dpi * INCHES_PER_METER, +- dpi * INCHES_PER_METER, +- PNG_RESOLUTION_METER); +- png_write_info(png_ptr, info_ptr); +- +- /* top margin */ +- memset(row, 0xff, (realwidth + 7) / 8); +- for(y=0; ydata; +- for(y=0; ywidth; y++) { +- bit = 7; +- memset(row, 0xff, (realwidth + 7) / 8); +- q = row; +- q += margin * size / 8; +- bit = 7 - (margin * size % 8); +- for(x=0; xwidth; x++) { +- for(xx=0; xxcode, filename); +- break; + case EPS_TYPE: + writeEPS(p->code, filename); + break; +@@ -1062,9 +929,7 @@ + } + break; + case 't': +- if(strcasecmp(optarg, "png") == 0) { +- image_type = PNG_TYPE; +- } else if(strcasecmp(optarg, "eps") == 0) { ++ if(strcasecmp(optarg, "eps") == 0) { + image_type = EPS_TYPE; + } else if(strcasecmp(optarg, "svg") == 0) { + image_type = SVG_TYPE; +@@ -1133,11 +998,6 @@ + exit(EXIT_SUCCESS); + } + +- if(outfile == NULL && image_type == PNG_TYPE) { +- fprintf(stderr, "No output filename is given.\n"); +- exit(EXIT_FAILURE); +- } +- + if(optind < argc) { + intext = (unsigned char *)argv[optind]; + length = strlen((char *)intext); +--- a/configure.ac ++++ b/configure.ac +@@ -58,9 +58,6 @@ + [build_tools=$withval], [build_tools=yes]) + + AM_CONDITIONAL(BUILD_TOOLS, [test "x$build_tools" = "xyes" ]) +-if test x$build_tools = xyes ; then +- PKG_CHECK_MODULES(png, "libpng") +-fi + + dnl --with-tests + AC_ARG_WITH([tests], [AS_HELP_STRING([--with-tests], [build tests [default=no]])], +@@ -80,12 +77,6 @@ + echo "/* #undef WITH_TESTS */" >>confdefs.h + fi + +-if test x$build_tests = xyes ; then +- SDL_REQUIRED_VERSION=1.2.0 +- AM_PATH_SDL($SDL_REQUIRED_VERSION,,AC_MSG_WARN([*** SDL $SDL_REQUIRED_VERSION or better is required.])) +- AC_MSG_NOTICE([SDL check done.]) +- AM_ICONV_LINK +-fi + AM_CONDITIONAL(HAVE_SDL, [test "x$SDL_CFLAGS" != "x" ]) + + diff --git a/libs/sbc/Makefile b/libs/sbc/Makefile new file mode 100644 index 000000000..cca54729d --- /dev/null +++ b/libs/sbc/Makefile @@ -0,0 +1,57 @@ +# +# Copyright (C) 2015 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:=sbc +PKG_VERSION:=1.3 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=https://www.kernel.org/pub/linux/bluetooth/ +PKG_MD5SUM:=2d8b7841f2c11ab287718d562f2b981c + +PKG_LICENSE:=LGPL-2.1+ +PKG_LICENSE_FILES:=COPYING.LIB +PKG_MAINTAINER:=Dirk Neukirchen + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/sbc + SECTION:=libs + CATEGORY:=Libraries + TITLE:=sbc encoding library + DEPENDS:=+libsndfile + URL:=http://www.bluez.org +endef + +define Package/sbc/description + Low Complexity Subband Coding for bluetooth audio profiles encoding and decoding. + Needed for A2DP support. +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/sbc + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/sbc/sbc.h $(1)/usr/include/sbc/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsbc* $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/sbc.pc $(1)/usr/lib/pkgconfig/ +endef + +define Package/sbc/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sbc* $(1)/usr/bin/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsbc.so* $(1)/usr/lib/ +endef + + +$(eval $(call BuildPackage,sbc)) diff --git a/libs/sqlite3/Makefile b/libs/sqlite3/Makefile index 37a4cc760..7f5d58a7c 100644 --- a/libs/sqlite3/Makefile +++ b/libs/sqlite3/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sqlite -PKG_VERSION:=3080801 +PKG_VERSION:=3081002 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-autoconf-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.sqlite.org/2015/ -PKG_MD5SUM:=a6381941ffe8817ba19669ec0c0ede6f +PKG_MD5SUM:=a18bfc015cd49a1e7a961b7b77bc3b37 PKG_LICENSE:=PUBLICDOMAIN PKG_LICENSE_FILES:= diff --git a/libs/tcp_wrappers/Makefile b/libs/tcp_wrappers/Makefile index 1ea637f29..d453031ec 100644 --- a/libs/tcp_wrappers/Makefile +++ b/libs/tcp_wrappers/Makefile @@ -32,11 +32,15 @@ endef TARGET_CFLAGS += $(FPIC) +ifeq ($(CONFIG_USE_MUSL),) +TARGET_EXTRA_LIBS:=LIBS=-lnsl +endif + define Build/Compile $(MAKE) -C $(PKG_BUILD_DIR) \ $(TARGET_CONFIGURE_OPTS) \ OPT_CFLAGS="$(TARGET_CFLAGS)" \ - LIBS=-lnsl \ + $(TARGET_EXTRA_LIBS) \ NETGROUP= \ VSYSLOG= \ BUGS= \ diff --git a/libs/tcp_wrappers/patches/005-no--lnsl-on-musl.patch b/libs/tcp_wrappers/patches/005-no--lnsl-on-musl.patch new file mode 100644 index 000000000..5e7b968dd --- /dev/null +++ b/libs/tcp_wrappers/patches/005-no--lnsl-on-musl.patch @@ -0,0 +1,22 @@ +Index: tcp_wrappers_7.6/Makefile +=================================================================== +--- tcp_wrappers_7.6.orig/Makefile ++++ tcp_wrappers_7.6/Makefile +@@ -1,4 +1,4 @@ +-GLIBC=$(shell grep -s -c __GLIBC__ /usr/include/features.h) ++GLIBC=$(shell grep -s -c __GLIBC__ ${STAGING_DIR}/usr/include/features.h) + + # @(#) Makefile 1.23 97/03/21 19:27:20 + +@@ -146,9 +146,11 @@ freebsd: + LIBS= RANLIB=ranlib ARFLAGS=rv AUX_OBJ= NETGROUP= TLI= \ + EXTRA_CFLAGS=-DSYS_ERRLIST_DEFINED VSYSLOG= all + ++ifneq ($(GLIBC),) + ifneq ($(GLIBC),0) + MYLIB=-lnsl + endif ++endif + + linux: + @make REAL_DAEMON_DIR=$(REAL_DAEMON_DIR) STYLE=$(STYLE) \ diff --git a/libs/toxcore/Makefile b/libs/toxcore/Makefile new file mode 100644 index 000000000..07f0c7651 --- /dev/null +++ b/libs/toxcore/Makefile @@ -0,0 +1,170 @@ +# +# Copyright (C) 2009-2015 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:=toxcore +PKG_VERSION:=0.0.0 +PKG_RELEASE:=1 + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/irungentoo/toxcore.git +PKG_SOURCE_VERSION:=6d883f488ff59b2394982b62895d50b1d1d55bf4 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_SOURCE_VERSION) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_SOURCE_VERSION) + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +PKG_MAINTAINER:=Daniel Golle +PKG_LICENSE:=GPL + +include $(INCLUDE_DIR)/package.mk + +define Package/toxcore/Default + SECTION:=libs + CATEGORY:=Libraries + SUBMENU:=Networking + TITLE:=Tox + URL:=https://tox.im +endef + +define Package/toxcore/description/Default + Tox, a FOSS initiative, aims to be an easy to use, all-in-one + communication platform that ensures their users full privacy and + secure message delivery. +endef + +define Package/libtoxcore + $(call Package/toxcore/Default) + DEPENDS:=+libsodium +librt +libpthread + TITLE+= core library +endef + +define Package/libtoxcore/description + $(call Package/toxcore/description/Default) + + core library +endef + +define Package/libtoxav + $(call Package/toxcore/Default) + DEPENDS:=+libtoxcore +libopus +libvpx + TITLE+= A/V library +endef + +define Package/libtoxav/description + $(call Package/toxcore/description/Default) + + A/V library providing audio/video codec bindings +endef + +define Package/libtoxdns + $(call Package/toxcore/Default) + DEPENDS:=+libtoxcore + TITLE+= dns library +endef + +define Package/libtoxdns/description + $(call Package/toxcore/description/Default) + + DNS library +endef + +define Package/libtoxencryptsave + $(call Package/toxcore/Default) + DEPENDS:=+libtoxcore + TITLE+= encryptsave library +endef + +define Package/libtoxencryptsave/description + $(call Package/toxcore/description/Default) + + encryptsave library +endef + +define Package/ntox + SECTION:=net + CATEGORY:=Network + SUBMENU:=Instant Messaging + DEPENDS:=+libtoxcore +libncurses + TITLE:=ntox Tox command-line client +endef + +define Package/ntox/description + $(call Package/toxcore/description/Default) + + nTox is an ncurses-based command-line client for Tox. +endef + +define Package/tox-bootstrapd + SECTION:=net + CATEGORY:=Network + SUBMENU:=Instant Messaging + DEPENDS:=+libtoxcore +libconfig + TITLE:=Tox DHT bootstrap +endef + +define Package/tox-dht-bootstrap/description + $(call Package/toxcore/description/Default) + + This package provide the Tox DHT bootstrap service. +endef + +CONFIGURE_ARGS+= \ + --enable-daemon \ + --enable-ntox \ + --enable-av \ + --disable-testing \ + --disable-tests + +define Package/libtoxav/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtoxav.*so* $(1)/usr/lib +endef + +define Package/libtoxcore/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtoxcore.*so* $(1)/usr/lib +endef + +define Package/libtoxdns/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtoxdns.*so* $(1)/usr/lib +endef + +define Package/libtoxencryptsave/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtoxencryptsave.*so* $(1)/usr/lib +endef + +define Package/tox-bootstrapd/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/tox-bootstrapd $(1)/usr/bin +endef + +define Package/ntox/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/nTox $(1)/usr/bin +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/tox + $(CP) $(PKG_INSTALL_DIR)/usr/include/tox/*.h $(1)/usr/include/tox + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtox* $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libtoxcore.pc $(1)/usr/lib/pkgconfig/ +endef + +$(eval $(call BuildPackage,libtoxav)) +$(eval $(call BuildPackage,libtoxcore)) +$(eval $(call BuildPackage,libtoxdns)) +$(eval $(call BuildPackage,libtoxencryptsave)) +$(eval $(call BuildPackage,ntox)) +$(eval $(call BuildPackage,tox-bootstrapd)) diff --git a/libs/yaml/Makefile b/libs/yaml/Makefile new file mode 100644 index 000000000..c2b818aa2 --- /dev/null +++ b/libs/yaml/Makefile @@ -0,0 +1,51 @@ +# +# Copyright (C) 2008-2015 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:=yaml +PKG_VERSION:=0.1.6 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://pyyaml.org/download/libyaml/ +PKG_MD5SUM:=5fe00cda18ca5daeb43762b80c38e06e + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Nicolas Thill + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/libyaml + SUBMENU:=Languages + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Fast YAML 1.1 parser and emitter library + URL:=http://pyyaml.org/wiki/LibYAML +endef + +TARGET_CFLAGS += $(FPIC) + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/yaml.h $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libyaml*.{a,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/yaml*.pc $(1)/usr/lib/pkgconfig/ +endef + +define Package/libyaml/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libyaml*.so* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libyaml)) diff --git a/libs/zmq/Makefile b/libs/zmq/Makefile new file mode 100644 index 000000000..dd845815a --- /dev/null +++ b/libs/zmq/Makefile @@ -0,0 +1,85 @@ +# +# Copyright (C) 2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# +# This Makefile for ZeroMQ +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=zeromq +PKG_VERSION:=4.1.1 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Dirk Chang +PKG_LICENSE:=GPL-3.0+ +PKG_LICENSE_FILES:=LICENCE.txt + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:= http://download.zeromq.org +PKG_MD5SUM:=73c39f5eb01b9d7eaf74a5d899f1d03d + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) +PKG_BUILD_DEPENDS:=libuuid + +PKG_FIXUP:=autoreconf + +PKG_INSTALL:=1 + + +include $(INCLUDE_DIR)/uclibc++.mk +include $(INCLUDE_DIR)/package.mk + +define Package/libzmq + TITLE:=ZeroMQ - Message Queue engine + URL:=http://www.zeromq.org/ + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=+libuuid +libpthread +librt +PACKAGE_libsodium:libsodium $(CXX_DEPENDS) + MENU:=1 +endef + +define Package/libzmq/config + config LIBZMQ_CURVEZMQ + bool "Include support for CurveZMQ security" + depends on PACKAGE_libzmq + default y + select PACKAGE_libsodium +endef + +define Package/libzmq/description + This package contains the ZeroMQ messaging engine shared library. + CurveZMQ security protocols are optional using libsodium. +endef + +# add extra configure flags here +CONFIGURE_ARGS += \ + --enable-static \ + --enable-shared + +ifneq ($(CONFIG_PACKAGE_libsodium),) + CONFIGURE_ARGS+= --with-libsodium +else + CONFIGURE_ARGS+= --without-libsodium +endif + +# add make variable overrides here +MAKE_FLAGS += + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/zmq.h $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/zmq_utils.h $(1)/usr/include + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libzmq.{a,so*} $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libzmq.pc $(1)/usr/lib/pkgconfig/ +endef + +define Package/libzmq/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libzmq.so.* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libzmq)) diff --git a/libs/zmq/patches/disable_pedantic_on_linux_with_ulibc++.patch b/libs/zmq/patches/disable_pedantic_on_linux_with_ulibc++.patch new file mode 100644 index 000000000..74e0091e9 --- /dev/null +++ b/libs/zmq/patches/disable_pedantic_on_linux_with_ulibc++.patch @@ -0,0 +1,14 @@ +--- a/configure.ac 2014-06-04 10:19:35.140061796 +0800 ++++ b/configure.ac 2014-06-04 11:08:17.231997926 +0800 +@@ -127,8 +127,10 @@ + *linux*) + # Define on Linux to enable all library features. Define if using a gnu compiler + if test "x$GXX" = "xyes"; then +- CPPFLAGS="-D_GNU_SOURCE $CPPFLAGS" ++ CPPFLAGS="-D_GNU_SOURCE $CPPFLAGS -Wno-long-long" + fi ++ libzmq_pedantic="no" ++ libzmq_werror="no" + AC_DEFINE(ZMQ_HAVE_LINUX, 1, [Have Linux OS]) + libzmq_on_linux="yes" + diff --git a/libs/zmq/patches/map_with_const_string_with_ublic++.patch b/libs/zmq/patches/map_with_const_string_with_ublic++.patch new file mode 100644 index 000000000..c1a14fcb7 --- /dev/null +++ b/libs/zmq/patches/map_with_const_string_with_ublic++.patch @@ -0,0 +1,41 @@ +--- a/src/metadata.hpp 2015-06-17 21:39:33.629934688 +0800 ++++ b/src/metadata.hpp 2014-10-14 22:07:36.000000000 +0800 +@@ -31,7 +31,7 @@ + { + public: + +- typedef std::map dict_t; ++ typedef std::map dict_t; + + metadata_t (const dict_t &dict); + virtual ~metadata_t (); +--- a/src/socket_base.cpp 2015-06-17 21:42:26.289413233 +0800 ++++ b/src/socket_base.cpp 2015-06-02 18:31:00.000000000 +0800 +@@ -20,6 +20,7 @@ + #include + #include + #include ++#include + + #include "platform.hpp" + +--- a/src/stream_engine.cpp 2015-06-17 21:57:29.599443517 +0800 ++++ b/src/stream_engine.cpp 2015-06-02 18:31:00.000000000 +0800 +@@ -198,7 +198,7 @@ + // Compile metadata. + typedef metadata_t::dict_t properties_t; + properties_t properties; +- properties.insert(std::make_pair("Peer-Address", peer_address)); ++ properties.insert(std::make_pair("Peer-Address", peer_address)); + zmq_assert (metadata == NULL); + metadata = new (std::nothrow) metadata_t (properties); + } +@@ -805,7 +805,7 @@ + + // If we have a peer_address, add it to metadata + if (!peer_address.empty()) { +- properties.insert(std::make_pair("Peer-Address", peer_address)); ++ properties.insert(std::make_pair("Peer-Address", peer_address)); + } + + // Add ZAP properties. diff --git a/libs/zmq/patches/streamoff_missing_with_ulibc++.patch b/libs/zmq/patches/streamoff_missing_with_ulibc++.patch new file mode 100644 index 000000000..0d1127bdb --- /dev/null +++ b/libs/zmq/patches/streamoff_missing_with_ulibc++.patch @@ -0,0 +1,10 @@ +--- a/src/blob.hpp 2014-06-04 10:19:12.680062287 +0800 ++++ b/src/blob.hpp 2014-06-04 10:30:31.168047457 +0800 +@@ -21,6 +21,7 @@ + #define __ZMQ_BLOB_HPP_INCLUDED__ + + #include ++#include + #include + + // Borrowed from id3lib_strings.h: diff --git a/mail/alpine/Makefile b/mail/alpine/Makefile index 322e954b6..cd32a628d 100644 --- a/mail/alpine/Makefile +++ b/mail/alpine/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=alpine PKG_VERSION:=2.20 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=http://patches.freeiz.com/alpine/release/src/ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz @@ -44,7 +44,7 @@ endef define Package/alpine $(call Package/alpine/Default) TITLE+= (with OpenSSL support) - DEPENDS+= +libcrypto +libopenssl + DEPENDS+= +libopenssl VARIANT:=ssl endef diff --git a/mail/bogofilter/Makefile b/mail/bogofilter/Makefile index de3646b01..d31dfa8c1 100644 --- a/mail/bogofilter/Makefile +++ b/mail/bogofilter/Makefile @@ -35,7 +35,10 @@ define Package/bogofilter/description Bogofilter is a fast Bayesian spam filter endef -CONFIGURE_ARGS += --disable-unicode +CONFIGURE_ARGS += \ + --disable-unicode \ + --with-libdb-prefix=$(STAGING_DIR) \ + --with-included-gsl define Package/bogofilter/install $(INSTALL_DIR) $(1)/etc/ \ diff --git a/mail/mailman/Makefile b/mail/mailman/Makefile index 9e848a8ad..eee50f85d 100644 --- a/mail/mailman/Makefile +++ b/mail/mailman/Makefile @@ -10,8 +10,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mailman PKG_RELEASE:=1 PKG_SOURCE_URL:=ftp://ftp.gnu.org/gnu/mailman/ http://ftp.gnu.org/gnu/mailman/ -PKG_VERSION:=2.1.18-1 -PKG_MD5SUM:=dc861ed9698a98499a951eaef7d4db9f +PKG_VERSION:=2.1.20 +PKG_MD5SUM:=96819640406f90a12bc28edd3dc09d4a PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz PKG_MAINTAINER:=Denis Shulyaka PKG_LICENSE:=GPL-2.0+ @@ -24,7 +24,7 @@ define Package/mailman CATEGORY:=Mail TITLE:=The GNU Mailing List Manager URL:=http://www.gnu.org/software/mailman/ - DEPENDS:=+postfix +python-mini +uhttpd +python-dns #+python-dev + DEPENDS:=+postfix +python +uhttpd +python-dns endef define Package/mailman/description diff --git a/mail/mailman/patches/100-postfix.patch b/mail/mailman/patches/100-postfix.patch index 857b99b73..22fec1eae 100644 --- a/mail/mailman/patches/100-postfix.patch +++ b/mail/mailman/patches/100-postfix.patch @@ -1,7 +1,7 @@ diff -rupN mailman-2.1.14-1/Mailman/Defaults.py.in mailman-2.1.14-1_patched/Mailman/Defaults.py.in --- mailman-2.1.14-1/Mailman/Defaults.py.in 2011-03-01 23:35:57.000000000 +0300 +++ mailman-2.1.14-1_patched/Mailman/Defaults.py.in 2011-03-09 12:26:10.000000000 +0300 -@@ -439,7 +439,7 @@ DELIVERY_MODULE = 'SMTPDirect' +@@ -461,7 +461,7 @@ DELIVERY_MODULE = 'SMTPDirect' # standard out (or send an email to the site list owner) for manual twiddling # of an /etc/aliases style file. Use 'Postfix' if you are using the Postfix # MTA -- but then also see POSTFIX_STYLE_VIRTUAL_DOMAINS. diff --git a/mail/mailsend/Makefile b/mail/mailsend/Makefile index 5b63bae8c..f9480f152 100644 --- a/mail/mailsend/Makefile +++ b/mail/mailsend/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mailsend PKG_VERSION:=1.17b15 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/muquit/mailsend/archive/$(PKG_VERSION) @@ -20,32 +20,42 @@ PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=BSD-3-Clause PKG_LICENSE_FILES:=COPYRIGHT +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) + include $(INCLUDE_DIR)/package.mk -define Package/mailsend +define Package/mailsend/default SECTION:=mail CATEGORY:=Mail TITLE:=A command-line mail sender - DEPENDS:=+MAILSEND_SSL:libopenssl URL:=https://github.com/muquit/mailsend endef -define Package/mailsend/config -config MAILSEND_SSL - bool "SSL support" - depends on PACKAGE_mailsend - default n - help - Implements SSL support in mailsend (using libopenssl). +define Package/mailsend-nossl + $(call Package/mailsend/default) + TITLE+= (without SSL) + VARIANT:=nossl +endef + +define Package/mailsend + $(call Package/mailsend/default) + TITLE+= (with SSL) + DEPENDS:=+libopenssl + VARIANT:=ssl endef -ifeq ($(CONFIG_MAILSEND_SSL),y) +ifeq ($(BUILD_VARIANT),ssl) CONFIGURE_ARGS+= --with-openssl=$(STAGING_DIR)/usr endif define Package/mailsend/description + $(call Package/mailsend-nossl/description) + . + SSL supported is provided by OpenSSL. +endef + +define Package/mailsend-nossl/description Mailsend is a simple command line program to send mail via SMTP protocol. - SSL is supported via OpenSSL (optional). endef define Build/Compile @@ -57,4 +67,7 @@ define Package/mailsend/install $(INSTALL_BIN) $(PKG_BUILD_DIR)/mailsend $(1)/usr/bin/ endef +Package/mailsend-nossl/install=$(Package/mailsend/install) + $(eval $(call BuildPackage,mailsend)) +$(eval $(call BuildPackage,mailsend-nossl)) diff --git a/mail/msmtp/Makefile b/mail/msmtp/Makefile index 1a7e21480..9a29f5ce0 100644 --- a/mail/msmtp/Makefile +++ b/mail/msmtp/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=msmtp -PKG_VERSION:=1.6.1 -PKG_RELEASE:=2 +PKG_VERSION:=1.6.2 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@SF/msmtp -PKG_MD5SUM:=6ebba4809bbc665b8a665a018d1a5ee1 +PKG_MD5SUM:=3baca93c7e5f1aa9d36a2e5b38739ab9 PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=COPYING @@ -85,19 +85,23 @@ CONFIGURE_ARGS += \ --without-libintl-prefix \ --without-libgsasl \ --without-libidn \ - --without-gnome-keyring \ + --without-libsecret \ --without-macosx-keyring \ +ifneq ($(CONFIG_USE_UCLIBC),) + CONFIGURE_ARGS += --disable-gai-idn +endif + MAKE_FLAGS := ifeq ($(BUILD_VARIANT),ssl) CONFIGURE_ARGS += \ - --with-ssl=openssl + --with-tls=openssl endif ifeq ($(BUILD_VARIANT),nossl) CONFIGURE_ARGS += \ - --with-ssl=no + --with-tls=no endif define Package/msmtp/install diff --git a/mail/postfix/Makefile b/mail/postfix/Makefile index 36c0f76f5..bcbb07a18 100644 --- a/mail/postfix/Makefile +++ b/mail/postfix/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,10 +8,10 @@ include $(TOPDIR)/rules.mk PKG_NAME:=postfix -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_URL:=ftp://ftp.porcupine.org/mirrors/postfix-release/official/ -PKG_VERSION:=3.0.0 -PKG_MD5SUM:=a4a83f8d729f31c803bf9c2277701d56 +PKG_VERSION:=3.0.1 +PKG_MD5SUM:=3ec1416e7d4fba9566297c8fcf7a348c PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_MAINTAINER:=Denis Shulyaka PKG_LICENSE:=IPL-1.0 diff --git a/mail/postfix/patches/500-crosscompile.patch b/mail/postfix/patches/500-crosscompile.patch index e4123ef00..0366612bb 100644 --- a/mail/postfix/patches/500-crosscompile.patch +++ b/mail/postfix/patches/500-crosscompile.patch @@ -1,6 +1,6 @@ ---- postfix-2.10.2/makedefs 2013-02-04 05:33:13.000000000 +0400 -+++ postfix-2.10.2_patched/makedefs 2013-11-19 22:48:50.528560454 +0400 -@@ -190,9 +190,9 @@ +--- a/makedefs ++++ b/makedefs +@@ -190,9 +190,9 @@ error() { case $# in # Officially supported usage. @@ -13,7 +13,7 @@ case "$VERSION" in dcosx*) SYSTEM=$VERSION;; esac;; -@@ -522,9 +522,9 @@ +@@ -522,9 +522,9 @@ EOF esac for name in nsl resolv do @@ -21,7 +21,7 @@ + for lib in /usr/lib64 /usr/lib64/* /usr/lib /usr/lib/* /lib /lib/* do - test -e $lib/lib$name.a -o -e $lib/lib$name.so && { -+ test -e $PKG_BUILD_DIR/$lib/lib$name.a -o -e $PKG_BUILD_DIR/$lib/lib$name.so && { ++ test -e $STAGING_DIR/$lib/lib$name.a -o -e $STAGING_DIR/$lib/lib$name.so && { SYSLIBS="$SYSLIBS -l$name" break } diff --git a/multimedia/ffmpeg/Config.in b/multimedia/ffmpeg/Config.in index c01498778..760dad6bf 100644 --- a/multimedia/ffmpeg/Config.in +++ b/multimedia/ffmpeg/Config.in @@ -60,11 +60,11 @@ config FFMPEG_CUSTOM_AUDIO_DEC_SUPPORT select FFMPEG_CUSTOM_DECODER_ape select FFMPEG_CUSTOM_DECODER_atrac3 select FFMPEG_CUSTOM_DECODER_flac - select FFMPEG_CUSTOM_SELECT_libopus select FFMPEG_CUSTOM_DECODER_mp2 select FFMPEG_CUSTOM_DECODER_mp3 select FFMPEG_CUSTOM_DECODER_mpc7 select FFMPEG_CUSTOM_DECODER_mpc8 + select FFMPEG_CUSTOM_DECODER_opus select FFMPEG_CUSTOM_DECODER_pcm_s16be select FFMPEG_CUSTOM_DECODER_pcm_s16le select FFMPEG_CUSTOM_SELECT_speex @@ -98,9 +98,10 @@ config FFMPEG_CUSTOM_AUDIO_DEC_SUPPORT select FFMPEG_CUSTOM_DEMUXER_wv select FFMPEG_CUSTOM_PARSER_aac select FFMPEG_CUSTOM_PARSER_aac_latm - select FFMPEG_CUSTOM_PARSER_flac select FFMPEG_CUSTOM_PARSER_ac3 + select FFMPEG_CUSTOM_PARSER_flac select FFMPEG_CUSTOM_PARSER_mpegaudio + select FFMPEG_CUSTOM_PARSER_opus select FFMPEG_CUSTOM_PROTOCOL_file select FFMPEG_CUSTOM_PROTOCOL_http select FFMPEG_CUSTOM_PROTOCOL_rtp @@ -229,6 +230,9 @@ config FFMPEG_CUSTOM_DECODER_mpc8 bool "Musepack 8" select FFMPEG_CUSTOM_DEMUXER_mpc8 +config FFMPEG_CUSTOM_DECODER_opus + bool "Opus" + config FFMPEG_CUSTOM_DECODER_pcm_s16be bool "PCM signed 16-bit big-endian" @@ -398,6 +402,9 @@ config FFMPEG_CUSTOM_PARSER_mpegvideo config FFMPEG_CUSTOM_PARSER_mpeg4video bool "MPEG-4 Video" +config FFMPEG_CUSTOM_PARSER_opus + bool "Opus" + comment "Protocols ---" config FFMPEG_CUSTOM_PROTOCOL_file @@ -406,6 +413,10 @@ config FFMPEG_CUSTOM_PROTOCOL_file config FFMPEG_CUSTOM_PROTOCOL_http bool "http:" +config FFMPEG_CUSTOM_PROTOCOL_icecast + bool "icecast:" + select FFMPEG_CUSTOM_PROTOCOL_http + config FFMPEG_CUSTOM_PROTOCOL_pipe bool "pipe:" diff --git a/multimedia/ffmpeg/Makefile b/multimedia/ffmpeg/Makefile index 9b46edb30..9aac9a80e 100644 --- a/multimedia/ffmpeg/Makefile +++ b/multimedia/ffmpeg/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ffmpeg -PKG_VERSION:=2.5.3 -PKG_RELEASE:=1 +PKG_VERSION:=2.6.3 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://ffmpeg.org/releases/ -PKG_MD5SUM:=efba7c5cfbea9ce58ff693cd08f90ffa +PKG_MD5SUM:=e2cc3c209f91393d35ab58598e41cf22 PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=LGPL-2.1+ GPL-2+ LGPL-3 @@ -108,7 +108,7 @@ FFMPEG_CUSTOM_PARSERS:= \ mpegvideo \ FFMPEG_CUSTOM_PROTOCOLS:= \ - file http pipe rtp tcp udp + file http icecast pipe rtp tcp udp FFMPEG_MINI_DECODERS:= \ aac \ @@ -125,7 +125,7 @@ FFMPEG_MINI_DECODERS:= \ wmav1 \ wmav2 \ -FFMPEG_MINI_DEMUXERS := \ +FFMPEG_MINI_DEMUXERS:= \ aac \ ac3 \ avi \ @@ -144,7 +144,7 @@ FFMPEG_MINI_PARSERS:= \ mpeg4video \ mpegaudio \ -FFMPEG_MINI_PROTOCOLS := \ +FFMPEG_MINI_PROTOCOLS:= \ file \ FFMPEG_AUDIO_DECODERS:= \ @@ -162,6 +162,7 @@ FFMPEG_AUDIO_DECODERS:= \ mp3* \ mpc7 \ mpc8 \ + opus \ pcm_* \ vorbis \ wavpack \ @@ -197,12 +198,13 @@ FFMPEG_AUDIO_DEMUXERS:= \ FFMPEG_AUDIO_PARSERS:= \ aac \ aac_latm \ - flac \ ac3 \ + flac \ mpegaudio \ + opus \ FFMPEG_AUDIO_PROTOCOLS:= \ - file http rtp tcp udp + file http icecast rtp tcp udp PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) @@ -308,7 +310,7 @@ endef define Package/libffmpeg-audio-dec $(call Package/libffmpeg/Default) TITLE+= (audio) - DEPENDS+= @DEVEL +libopus +libspeex + DEPENDS+= @BUILD_PATENTED +libspeex VARIANT:=audio-dec endef @@ -395,6 +397,7 @@ FFMPEG_CONFIGURE:= \ --disable-mipsfpu \ \ --disable-dxva2 \ + --disable-lzma \ --disable-vaapi \ --disable-vda \ --disable-vdpau \ @@ -461,7 +464,6 @@ ifeq ($(BUILD_VARIANT),audio-dec) $(call FFMPEG_ENABLE,demuxer,$(FFMPEG_AUDIO_DEMUXERS)) \ $(call FFMPEG_ENABLE,parser,$(FFMPEG_AUDIO_PARSERS)) \ $(call FFMPEG_ENABLE,protocol,$(FFMPEG_AUDIO_PROTOCOLS)) \ - --enable-libopus --enable-decoder=libopus \ --enable-libspeex --enable-decoder=libspeex \ --disable-decoder=pcm_bluray,pcm_dvd \ diff --git a/multimedia/gst1-libav/Makefile b/multimedia/gst1-libav/Makefile index 81ce237b3..36a25293a 100644 --- a/multimedia/gst1-libav/Makefile +++ b/multimedia/gst1-libav/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gst1-libav -PKG_VERSION:=1.4.4 +PKG_VERSION:=1.4.5 PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo PKG_SOURCE:=gst-libav-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gst-libav -PKG_MD5SUM:=64a3e2cda2687132cadca4efdc63f3b4 +PKG_MD5SUM:=f4922a46adbcbe7bd01331ff5dc7979d PKG_LICENSE:=GPL-2.0 LGPL-2.0 PKG_LICENSE_FILES:=COPYING COPYING.LIB @@ -185,7 +185,7 @@ CONFIGURE_ARGS += \ --disable-yasm" # XXX: trick to force use of embedded Libav headers -TARGET_CFLAGS += $(TARGET_CPPFLAGS) +TARGET_CFLAGS += $(TARGET_CPPFLAGS) -D_GNU_SOURCE TARGET_CPPFLAGS := TARGET_LDFLAGS += $(FPIC) diff --git a/multimedia/gst1-plugins-bad/Makefile b/multimedia/gst1-plugins-bad/Makefile index 105f127e9..bfeb1c593 100644 --- a/multimedia/gst1-plugins-bad/Makefile +++ b/multimedia/gst1-plugins-bad/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2011-2014 OpenWrt.org +# Copyright (C) 2011-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gst1-plugins-bad -PKG_VERSION:=1.4.4 -PKG_RELEASE:=4 +PKG_VERSION:=1.4.5 +PKG_RELEASE:=2 PKG_MAINTAINER:=W. Michael Petullo @@ -19,9 +19,9 @@ PKG_LICENSE_FILES:=COPYING.LIB COPYING PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-bad-$(PKG_VERSION) PKG_SOURCE:=gst-plugins-bad-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gst-plugins-bad/ -PKG_MD5SUM:=972c6e22dd2e44fcf0b04b9d810a56be +PKG_MD5SUM:=e0bb39412cf4a48fe0397bcf3a7cd451 -PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base liboil +PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base PKG_FIXUP:=autoreconf PKG_INSTALL:=1 @@ -106,28 +106,18 @@ CONFIGURE_ARGS += \ --disable-osx_video \ --disable-quicktime \ --disable-vcd \ - --disable-alsa \ --disable-assrender \ - --disable-amrwb \ --disable-apexsink \ --disable-bz2 \ - --disable-cdaudio \ - --disable-celt \ - --disable-cog \ --disable-dc1394 \ --disable-directfb \ - --disable-dirac \ --disable-dts \ - --disable-divx \ --disable-resindvd \ - --disable-metadata \ --disable-faac \ --disable-faad \ --disable-fbdev \ --disable-flite \ --disable-gsm \ - --disable-jack \ - --disable-jp2k \ --disable-kate \ --disable-ladspa \ --disable-lv2 \ @@ -137,7 +127,6 @@ CONFIGURE_ARGS += \ --disable-mpeg2enc \ --disable-mplex \ --disable-musepack \ - --disable-musicbrainz \ --disable-mythtv \ --disable-nas \ --disable-neon \ @@ -151,8 +140,6 @@ CONFIGURE_ARGS += \ --disable-soundtouch \ --disable-spc \ --disable-gme \ - --disable-swfdec \ - --disable-theoradec \ --disable-xvid \ --disable-dvb \ --disable-wininet \ @@ -160,11 +147,12 @@ CONFIGURE_ARGS += \ --disable-vdpau \ --disable-schro \ --disable-zbar \ - --disable-vp8 \ --disable-srtp \ + --disable-hls \ \ --without-libiconv-prefix \ --without-libintl-prefix \ + --with-libgcrypt-prefix="$(STAGING_DIR)/usr" \ --without-x \ TARGET_CFLAGS+= -std=gnu99 @@ -269,12 +257,14 @@ $(eval $(call GstBuildPlugin,mpegpsmux,mpegpsmux support,,,)) #$(eval $(call GstBuildPlugin,mpegtsdemux,mpegtsdemux support,mpegts pbutils tag,,)) #$(eval $(call GstBuildPlugin,mpegtsmux,mpegtsmux support,video,,)) $(eval $(call GstBuildPlugin,mxf,mxf support,audio video,,)) +$(eval $(call GstBuildPlugin,opus,OPUS plugin library,audio tag rtp,,+libopus)) $(eval $(call GstBuildPlugin,pcapparse,pcapparse support,,,)) $(eval $(call GstBuildPlugin,pnm,pnm support,video,,)) $(eval $(call GstBuildPlugin,rawparse,rawparse support,audio video,,)) $(eval $(call GstBuildPlugin,rfbsrc,librfb support,video,,)) $(eval $(call GstBuildPlugin,sdpelem,sdp support,rtp sdp,,)) $(eval $(call GstBuildPlugin,segmentclip,segmentclip support,audio,,)) +$(eval $(call GstBuildPlugin,shm,POSIX shared memory source and sink,,,+librt)) $(eval $(call GstBuildPlugin,siren,siren support,audio rtp,,)) $(eval $(call GstBuildPlugin,speed,speed support,audio,,)) $(eval $(call GstBuildPlugin,subenc,subenc support,controller,,)) diff --git a/multimedia/gst1-plugins-bad/patches/000-gettext.patch b/multimedia/gst1-plugins-bad/patches/000-gettext.patch index 12b433383..1c0d88e1e 100644 --- a/multimedia/gst1-plugins-bad/patches/000-gettext.patch +++ b/multimedia/gst1-plugins-bad/patches/000-gettext.patch @@ -1,18 +1,16 @@ -diff -u --recursive gst-plugins-bad-1.0.7-vanilla/configure.ac gst-plugins-bad-1.0.7/configure.ac ---- gst-plugins-bad-1.0.7-vanilla/configure.ac 2013-06-01 19:44:32.199308073 -0500 -+++ gst-plugins-bad-1.0.7/configure.ac 2013-06-01 19:45:27.754119344 -0500 -@@ -2373,7 +2373,6 @@ - ext/timidity/Makefile +--- a/configure.ac ++++ b/configure.ac +@@ -3334,7 +3334,6 @@ ext/timidity/Makefile + ext/webp/Makefile ext/xvid/Makefile ext/zbar/Makefile -po/Makefile.in docs/Makefile docs/plugins/Makefile docs/libs/Makefile -diff -u --recursive gst-plugins-bad-1.0.7-vanilla/Makefile.am gst-plugins-bad-1.0.7/Makefile.am ---- gst-plugins-bad-1.0.7-vanilla/Makefile.am 2013-06-01 19:44:32.165309412 -0500 -+++ gst-plugins-bad-1.0.7/Makefile.am 2013-06-01 19:45:39.016675625 -0500 -@@ -2,11 +2,11 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -2,11 +2,11 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-d SUBDIRS = \ gst-libs gst sys ext pkgconfig \ @@ -26,10 +24,9 @@ diff -u --recursive gst-plugins-bad-1.0.7-vanilla/Makefile.am gst-plugins-bad-1. # include before EXTRA_DIST for win32 assignment include $(top_srcdir)/common/win32.mak -diff -u --recursive gst-plugins-bad-1.0.7-vanilla/Makefile.in gst-plugins-bad-1.0.7/Makefile.in ---- gst-plugins-bad-1.0.7-vanilla/Makefile.in 2013-06-01 19:44:32.217307364 -0500 -+++ gst-plugins-bad-1.0.7/Makefile.in 2013-06-01 19:45:44.624454691 -0500 -@@ -636,11 +636,11 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -739,11 +739,11 @@ wayland_scanner = @wayland_scanner@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc SUBDIRS = \ gst-libs gst sys ext pkgconfig \ diff --git a/multimedia/gst1-plugins-base/Makefile b/multimedia/gst1-plugins-base/Makefile index 73b2ce16a..6f7cda5d8 100644 --- a/multimedia/gst1-plugins-base/Makefile +++ b/multimedia/gst1-plugins-base/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gst1-plugins-base -PKG_VERSION:=1.4.4 -PKG_RELEASE:=3 +PKG_VERSION:=1.4.5 +PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo @@ -19,9 +19,9 @@ PKG_LICENSE_FILES:=COPYING.LIB COPYING PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-base-$(PKG_VERSION) PKG_SOURCE:=gst-plugins-base-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gst-plugins-base/ -PKG_MD5SUM:=0c42eca8f9e4efd56d2ce8e9249ce4a1 +PKG_MD5SUM:=357165af625c0ca353ab47c5d843920e -PKG_BUILD_DEPENDS:= libgstreamer1 liboil +PKG_BUILD_DEPENDS:= libgstreamer1 PKG_CONFIG_DEPENDS:= \ CONFIG_PACKAGE_gst1-mod-alsa \ CONFIG_PACKAGE_gst1-mod-app \ @@ -133,8 +133,8 @@ CONFIGURE_ARGS += \ --disable-subparse \ $(call GST_COND_SELECT,tcp) \ $(call GST_COND_SELECT,theora) \ - --disable-videorate \ - --disable-videoscale \ + $(call GST_COND_SELECT,videorate) \ + $(call GST_COND_SELECT,videoscale) \ $(call GST_COND_SELECT,videoconvert) \ $(call GST_COND_SELECT,videotestsrc) \ $(call GST_COND_SELECT,volume) \ @@ -279,6 +279,8 @@ $(eval $(call GstBuildPlugin,tcp,TCP,,,)) $(eval $(call GstBuildPlugin,theora,Theora,tag video,,+libogg +libtheora)) $(eval $(call GstBuildPlugin,typefindfunctions,'typefind' functions,audio pbutils tag video,,)) $(eval $(call GstBuildPlugin,videoconvert,video format conversion,video,,)) +$(eval $(call GstBuildPlugin,videorate,Adjusts video frames,video,,)) +$(eval $(call GstBuildPlugin,videoscale,Resizes video,video,,)) $(eval $(call GstBuildPlugin,videotestsrc,video test,video,,+liboil)) $(eval $(call GstBuildPlugin,volume,volume,audio controller,,+liboil)) $(eval $(call GstBuildPlugin,vorbis,Vorbis,audio tag,ogg,+libvorbis)) diff --git a/multimedia/gst1-plugins-base/patches/001-no_docs.patch b/multimedia/gst1-plugins-base/patches/001-no_docs.patch index 87343b29a..0044ceca8 100644 --- a/multimedia/gst1-plugins-base/patches/001-no_docs.patch +++ b/multimedia/gst1-plugins-base/patches/001-no_docs.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base-1.0.7/Makefile.am ---- gst-plugins-base-1.0.7-vanilla/Makefile.am 2013-06-01 22:38:30.495678685 -0500 -+++ gst-plugins-base-1.0.7/Makefile.am 2013-06-01 22:39:04.374335121 -0500 -@@ -12,14 +12,12 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -12,14 +12,12 @@ SUBDIRS = \ gst sys $(SUBDIRS_EXT) \ tools \ tests \ @@ -16,10 +15,9 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base- gst-libs \ gst sys ext \ tools \ -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.in gst-plugins-base-1.0.7/Makefile.in ---- gst-plugins-base-1.0.7-vanilla/Makefile.in 2013-06-01 22:38:30.527677416 -0500 -+++ gst-plugins-base-1.0.7/Makefile.in 2013-06-01 22:38:59.110543873 -0500 -@@ -493,14 +493,12 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -539,14 +539,12 @@ SUBDIRS = \ gst sys $(SUBDIRS_EXT) \ tools \ tests \ diff --git a/multimedia/gst1-plugins-base/patches/002-no_tests.patch b/multimedia/gst1-plugins-base/patches/002-no_tests.patch index 9b4a513cc..3e8c93d41 100644 --- a/multimedia/gst1-plugins-base/patches/002-no_tests.patch +++ b/multimedia/gst1-plugins-base/patches/002-no_tests.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base-1.0.7/Makefile.am ---- gst-plugins-base-1.0.7-vanilla/Makefile.am 2013-06-01 19:49:37.986260708 -0500 -+++ gst-plugins-base-1.0.7/Makefile.am 2013-06-01 19:49:54.998590479 -0500 -@@ -11,7 +11,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -11,7 +11,6 @@ SUBDIRS = \ gst-libs \ gst sys $(SUBDIRS_EXT) \ tools \ @@ -9,7 +8,7 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base- po \ common \ m4 -@@ -21,7 +20,6 @@ +@@ -21,7 +20,6 @@ DIST_SUBDIRS = \ gst-libs \ gst sys ext \ tools \ @@ -17,10 +16,9 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base- po \ common \ m4 -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.in gst-plugins-base-1.0.7/Makefile.in ---- gst-plugins-base-1.0.7-vanilla/Makefile.in 2013-06-01 19:49:37.987260668 -0500 -+++ gst-plugins-base-1.0.7/Makefile.in 2013-06-01 19:49:58.374457466 -0500 -@@ -492,7 +492,6 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -538,7 +538,6 @@ SUBDIRS = \ gst-libs \ gst sys $(SUBDIRS_EXT) \ tools \ @@ -28,7 +26,7 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.in gst-plugins-base- po \ common \ m4 -@@ -502,7 +501,6 @@ +@@ -548,7 +547,6 @@ DIST_SUBDIRS = \ gst-libs \ gst sys ext \ tools \ diff --git a/multimedia/gst1-plugins-base/patches/003-no_translations.patch b/multimedia/gst1-plugins-base/patches/003-no_translations.patch index 581cef508..894c8da9b 100644 --- a/multimedia/gst1-plugins-base/patches/003-no_translations.patch +++ b/multimedia/gst1-plugins-base/patches/003-no_translations.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-base-1.0.7-vanilla/configure.ac gst-plugins-base-1.0.7/configure.ac ---- gst-plugins-base-1.0.7-vanilla/configure.ac 2013-06-01 19:48:21.931257133 -0500 -+++ gst-plugins-base-1.0.7/configure.ac 2013-06-01 19:51:30.371829534 -0500 -@@ -923,7 +923,6 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -918,7 +918,6 @@ docs/design/Makefile docs/libs/Makefile docs/plugins/Makefile docs/version.entities @@ -9,10 +8,9 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/configure.ac gst-plugins-base common/Makefile common/m4/Makefile m4/Makefile -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base-1.0.7/Makefile.am ---- gst-plugins-base-1.0.7-vanilla/Makefile.am 2013-06-01 19:50:30.232202309 -0500 -+++ gst-plugins-base-1.0.7/Makefile.am 2013-06-01 19:50:58.973069965 -0500 -@@ -11,7 +11,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -11,7 +11,6 @@ SUBDIRS = \ gst-libs \ gst sys $(SUBDIRS_EXT) \ tools \ @@ -20,7 +18,7 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base- common \ m4 -@@ -20,7 +19,6 @@ +@@ -20,7 +19,6 @@ DIST_SUBDIRS = \ gst-libs \ gst sys ext \ tools \ @@ -28,10 +26,9 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.am gst-plugins-base- common \ m4 -diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.in gst-plugins-base-1.0.7/Makefile.in ---- gst-plugins-base-1.0.7-vanilla/Makefile.in 2013-06-01 19:50:30.233202273 -0500 -+++ gst-plugins-base-1.0.7/Makefile.in 2013-06-01 19:51:22.796130711 -0500 -@@ -492,7 +492,6 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -538,7 +538,6 @@ SUBDIRS = \ gst-libs \ gst sys $(SUBDIRS_EXT) \ tools \ @@ -39,7 +36,7 @@ diff -u --recursive gst-plugins-base-1.0.7-vanilla/Makefile.in gst-plugins-base- common \ m4 -@@ -501,7 +500,6 @@ +@@ -547,7 +546,6 @@ DIST_SUBDIRS = \ gst-libs \ gst sys ext \ tools \ diff --git a/multimedia/gst1-plugins-good/Makefile b/multimedia/gst1-plugins-good/Makefile index bffabb314..f52d82fc3 100644 --- a/multimedia/gst1-plugins-good/Makefile +++ b/multimedia/gst1-plugins-good/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gst1-plugins-good -PKG_VERSION:=1.4.4 +PKG_VERSION:=1.4.5 PKG_RELEASE:=2 PKG_MAINTAINER:=W. Michael Petullo @@ -19,9 +19,9 @@ PKG_LICENSE_FILES:=COPYING PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-good-$(PKG_VERSION) PKG_SOURCE:=gst-plugins-good-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gst-plugins-good/ -PKG_MD5SUM:=673cf9276952bd3937dafd817c9ead2b +PKG_MD5SUM:=eaf1a6daf73749bc423feac301d60038 -PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base liboil +PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/multimedia/gst1-plugins-good/patches/001-no_docs.patch b/multimedia/gst1-plugins-good/patches/001-no_docs.patch index 9257931b8..21c10c3b9 100644 --- a/multimedia/gst1-plugins-good/patches/001-no_docs.patch +++ b/multimedia/gst1-plugins-good/patches/001-no_docs.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good-1.0.7/Makefile.am ---- gst-plugins-good-1.0.7-vanilla/Makefile.am 2013-06-01 19:54:57.652601127 -0500 -+++ gst-plugins-good-1.0.7/Makefile.am 2013-06-01 19:55:15.281902215 -0500 -@@ -3,7 +3,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -3,7 +3,6 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-d ALWAYS_SUBDIRS = \ gst sys ext \ tests \ @@ -9,10 +8,9 @@ diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good- po \ common \ m4 \ -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.in gst-plugins-good-1.0.7/Makefile.in ---- gst-plugins-good-1.0.7-vanilla/Makefile.in 2013-06-01 19:54:57.692599541 -0500 -+++ gst-plugins-good-1.0.7/Makefile.in 2013-06-01 19:55:23.025595255 -0500 -@@ -523,7 +523,6 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -571,7 +571,6 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk ALWAYS_SUBDIRS = \ gst sys ext \ tests \ diff --git a/multimedia/gst1-plugins-good/patches/002-no_tests.patch b/multimedia/gst1-plugins-good/patches/002-no_tests.patch index 7b862d670..ed922c531 100644 --- a/multimedia/gst1-plugins-good/patches/002-no_tests.patch +++ b/multimedia/gst1-plugins-good/patches/002-no_tests.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good-1.0.7/Makefile.am ---- gst-plugins-good-1.0.7-vanilla/Makefile.am 2013-06-01 19:56:00.995090476 -0500 -+++ gst-plugins-good-1.0.7/Makefile.am 2013-06-01 19:56:12.911618318 -0500 -@@ -2,7 +2,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -2,7 +2,6 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-d ALWAYS_SUBDIRS = \ gst sys ext \ @@ -9,10 +8,9 @@ diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good- po \ common \ m4 \ -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.in gst-plugins-good-1.0.7/Makefile.in ---- gst-plugins-good-1.0.7-vanilla/Makefile.in 2013-06-01 19:56:00.995090476 -0500 -+++ gst-plugins-good-1.0.7/Makefile.in 2013-06-01 19:56:16.655469989 -0500 -@@ -522,7 +522,6 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -570,7 +570,6 @@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc ALWAYS_SUBDIRS = \ gst sys ext \ diff --git a/multimedia/gst1-plugins-good/patches/003-no_translations.patch b/multimedia/gst1-plugins-good/patches/003-no_translations.patch index 84e311408..16d1b7e07 100644 --- a/multimedia/gst1-plugins-good/patches/003-no_translations.patch +++ b/multimedia/gst1-plugins-good/patches/003-no_translations.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-good-1.0.7-vanilla/configure.ac gst-plugins-good-1.0.7/configure.ac ---- gst-plugins-good-1.0.7-vanilla/configure.ac 2013-06-01 19:56:23.004218467 -0500 -+++ gst-plugins-good-1.0.7/configure.ac 2013-06-01 19:56:52.919033496 -0500 -@@ -1157,7 +1157,6 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -1083,7 +1083,6 @@ sys/sunaudio/Makefile sys/v4l2/Makefile sys/waveform/Makefile sys/ximage/Makefile @@ -9,10 +8,9 @@ diff -u --recursive gst-plugins-good-1.0.7-vanilla/configure.ac gst-plugins-good tests/Makefile tests/check/Makefile tests/examples/Makefile -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good-1.0.7/Makefile.am ---- gst-plugins-good-1.0.7-vanilla/Makefile.am 2013-06-01 19:56:23.043216922 -0500 -+++ gst-plugins-good-1.0.7/Makefile.am 2013-06-01 19:56:43.671399777 -0500 -@@ -2,7 +2,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -2,7 +2,6 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-d ALWAYS_SUBDIRS = \ gst sys ext \ @@ -20,10 +18,9 @@ diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.am gst-plugins-good- common \ m4 \ pkgconfig -diff -u --recursive gst-plugins-good-1.0.7-vanilla/Makefile.in gst-plugins-good-1.0.7/Makefile.in ---- gst-plugins-good-1.0.7-vanilla/Makefile.in 2013-06-01 19:56:23.043216922 -0500 -+++ gst-plugins-good-1.0.7/Makefile.in 2013-06-01 19:56:47.703240080 -0500 -@@ -522,7 +522,6 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -570,7 +570,6 @@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc ALWAYS_SUBDIRS = \ gst sys ext \ diff --git a/multimedia/gst1-plugins-ugly/Makefile b/multimedia/gst1-plugins-ugly/Makefile index b8ed67080..26c7995aa 100644 --- a/multimedia/gst1-plugins-ugly/Makefile +++ b/multimedia/gst1-plugins-ugly/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2014 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gst1-plugins-ugly -PKG_VERSION:=1.4.4 +PKG_VERSION:=1.4.5 PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo @@ -19,9 +19,9 @@ PKG_LICENSE_FILES:=COPYING PKG_BUILD_DIR:=$(BUILD_DIR)/gst-plugins-ugly-$(PKG_VERSION) PKG_SOURCE:=gst-plugins-ugly-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gst-plugins-ugly/ -PKG_MD5SUM:=abd832c5cab1a37fb1d9d15fb08e6e59 +PKG_MD5SUM:=6954beed7bb9a93e426dee543ff46393 -PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base liboil +PKG_BUILD_DEPENDS:= libgstreamer1 gstreamer1-plugins-base PKG_CONFIG_DEPENDS:= \ CONFIG_PACKAGE_gst1-mod-asf \ CONFIG_PACKAGE_gst1-mod-lame \ diff --git a/multimedia/gst1-plugins-ugly/patches/001-no_docs.patch b/multimedia/gst1-plugins-ugly/patches/001-no_docs.patch index 5d99fd496..72c880a90 100644 --- a/multimedia/gst1-plugins-ugly/patches/001-no_docs.patch +++ b/multimedia/gst1-plugins-ugly/patches/001-no_docs.patch @@ -1,6 +1,5 @@ -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly-1.0.7/Makefile.am ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.am 2013-06-01 19:58:12.400886469 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.am 2013-06-01 19:58:33.306059047 -0500 +--- a/Makefile.am ++++ b/Makefile.am @@ -1,7 +1,7 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc @@ -10,10 +9,9 @@ diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly- # include before EXTRA_DIST for win32 assignment include $(top_srcdir)/common/win32.mak -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.in gst-plugins-ugly-1.0.7/Makefile.in ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.in 2013-06-01 19:58:12.412885994 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.in 2013-06-01 19:58:39.810801615 -0500 -@@ -453,7 +453,7 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -502,7 +502,7 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc SUBDIRS = \ diff --git a/multimedia/gst1-plugins-ugly/patches/002-no_tests.patch b/multimedia/gst1-plugins-ugly/patches/002-no_tests.patch index 1f23bf96c..1611671f0 100644 --- a/multimedia/gst1-plugins-ugly/patches/002-no_tests.patch +++ b/multimedia/gst1-plugins-ugly/patches/002-no_tests.patch @@ -1,6 +1,5 @@ -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly-1.0.7/Makefile.am ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.am 2013-06-01 19:59:16.988330482 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.am 2013-06-01 19:59:28.455876771 -0500 +--- a/Makefile.am ++++ b/Makefile.am @@ -1,7 +1,7 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc @@ -10,10 +9,9 @@ diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly- # include before EXTRA_DIST for win32 assignment include $(top_srcdir)/common/win32.mak -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.in gst-plugins-ugly-1.0.7/Makefile.in ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.in 2013-06-01 19:59:16.988330482 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.in 2013-06-01 19:59:39.840426385 -0500 -@@ -453,7 +453,7 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -502,7 +502,7 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc SUBDIRS = \ diff --git a/multimedia/gst1-plugins-ugly/patches/003-no_translations.patch b/multimedia/gst1-plugins-ugly/patches/003-no_translations.patch index 3adfea835..bd617713d 100644 --- a/multimedia/gst1-plugins-ugly/patches/003-no_translations.patch +++ b/multimedia/gst1-plugins-ugly/patches/003-no_translations.patch @@ -1,7 +1,6 @@ -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/configure.ac gst-plugins-ugly-1.0.7/configure.ac ---- gst-plugins-ugly-1.0.7-vanilla/configure.ac 2013-06-01 19:59:46.199174835 -0500 -+++ gst-plugins-ugly-1.0.7/configure.ac 2013-06-01 20:00:29.709453831 -0500 -@@ -479,7 +479,6 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -475,7 +475,6 @@ docs/version.entities tests/Makefile tests/check/Makefile m4/Makefile @@ -9,9 +8,8 @@ diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/configure.ac gst-plugins-ugly pkgconfig/Makefile pkgconfig/gstreamer-plugins-ugly-uninstalled.pc gst-plugins-ugly.spec -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly-1.0.7/Makefile.am ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.am 2013-06-01 19:59:46.210174399 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.am 2013-06-01 20:00:11.351179921 -0500 +--- a/Makefile.am ++++ b/Makefile.am @@ -1,7 +1,7 @@ DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc @@ -21,10 +19,9 @@ diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.am gst-plugins-ugly- # include before EXTRA_DIST for win32 assignment include $(top_srcdir)/common/win32.mak -diff -u --recursive gst-plugins-ugly-1.0.7-vanilla/Makefile.in gst-plugins-ugly-1.0.7/Makefile.in ---- gst-plugins-ugly-1.0.7-vanilla/Makefile.in 2013-06-01 19:59:46.210174399 -0500 -+++ gst-plugins-ugly-1.0.7/Makefile.in 2013-06-01 20:00:20.222829049 -0500 -@@ -453,7 +453,7 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -502,7 +502,7 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc SUBDIRS = \ diff --git a/multimedia/gstreamer1/Makefile b/multimedia/gstreamer1/Makefile index a73cc1d85..0ab4629fb 100644 --- a/multimedia/gstreamer1/Makefile +++ b/multimedia/gstreamer1/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gstreamer1 -PKG_VERSION:=1.4.4 -PKG_RELEASE:=2 +PKG_VERSION:=1.4.5 +PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo @@ -19,7 +19,7 @@ PKG_LICENSE_FILES:=COPYING PKG_BUILD_DIR:=$(BUILD_DIR)/gstreamer-$(PKG_VERSION) PKG_SOURCE:=gstreamer-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://gstreamer.freedesktop.org/src/gstreamer/ -PKG_MD5SUM:=98f4a6d45a28dd195144baef0244ba38 +PKG_MD5SUM:=88a9289c64a4950ebb4f544980234289 PKG_FIXUP:=autoreconf PKG_REMOVE_FILES:=autogen.sh aclocal.m4 diff --git a/multimedia/gstreamer1/patches/001-no_docs.patch b/multimedia/gstreamer1/patches/001-no_docs.patch index 744f1c6ac..fb0e034f1 100644 --- a/multimedia/gstreamer1/patches/001-no_docs.patch +++ b/multimedia/gstreamer1/patches/001-no_docs.patch @@ -1,7 +1,6 @@ -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile.am ---- gstreamer-1.0.7-vanilla/Makefile.am 2013-06-01 18:47:44.498057069 -0500 -+++ gstreamer-1.0.7/Makefile.am 2013-06-01 19:01:41.634143861 -0500 -@@ -8,7 +8,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -8,7 +8,6 @@ aclocal_DATA = gst-element-check-@GST_AP SUBDIRS = pkgconfig \ gst libs plugins tests \ @@ -9,7 +8,7 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile po \ m4 \ common -@@ -20,7 +19,6 @@ +@@ -20,7 +19,6 @@ endif # These are all the possible subdirs DIST_SUBDIRS = pkgconfig \ gst libs plugins tools tests \ @@ -17,10 +16,9 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile po \ m4 \ common -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.in gstreamer-1.0.7/Makefile.in ---- gstreamer-1.0.7-vanilla/Makefile.in 2013-06-01 18:47:44.533056863 -0500 -+++ gstreamer-1.0.7/Makefile.in 2013-06-01 19:02:04.529246907 -0500 -@@ -508,13 +508,12 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -554,13 +554,12 @@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-docbook aclocaldir = $(datadir)/aclocal aclocal_DATA = gst-element-check-@GST_API_VERSION@.m4 diff --git a/multimedia/gstreamer1/patches/002-no_tests.patch b/multimedia/gstreamer1/patches/002-no_tests.patch index e002becfb..384dd0add 100644 --- a/multimedia/gstreamer1/patches/002-no_tests.patch +++ b/multimedia/gstreamer1/patches/002-no_tests.patch @@ -1,7 +1,6 @@ -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile.am ---- gstreamer-1.0.7-vanilla/Makefile.am 2013-06-01 19:22:31.546496381 -0500 -+++ gstreamer-1.0.7/Makefile.am 2013-06-01 19:20:38.141070908 -0500 -@@ -7,7 +7,7 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -7,7 +7,7 @@ aclocaldir = $(datadir)/aclocal aclocal_DATA = gst-element-check-@GST_API_VERSION@.m4 SUBDIRS = pkgconfig \ @@ -10,7 +9,7 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile po \ m4 \ common -@@ -18,7 +18,7 @@ +@@ -18,7 +18,7 @@ endif # These are all the possible subdirs DIST_SUBDIRS = pkgconfig \ @@ -19,10 +18,9 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile po \ m4 \ common -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.in gstreamer-1.0.7/Makefile.in ---- gstreamer-1.0.7-vanilla/Makefile.in 2013-06-01 19:22:31.547496342 -0500 -+++ gstreamer-1.0.7/Makefile.in 2013-06-01 19:20:48.948632307 -0500 -@@ -508,12 +508,12 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -554,12 +554,12 @@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-docbook aclocaldir = $(datadir)/aclocal aclocal_DATA = gst-element-check-@GST_API_VERSION@.m4 diff --git a/multimedia/gstreamer1/patches/003-no_translations.patch b/multimedia/gstreamer1/patches/003-no_translations.patch index e2561993f..7e918dd7e 100644 --- a/multimedia/gstreamer1/patches/003-no_translations.patch +++ b/multimedia/gstreamer1/patches/003-no_translations.patch @@ -1,7 +1,6 @@ -diff -u --recursive gstreamer-1.0.7-vanilla/configure.ac gstreamer-1.0.7/configure.ac ---- gstreamer-1.0.7-vanilla/configure.ac 2013-06-01 18:47:44.506057110 -0500 -+++ gstreamer-1.0.7/configure.ac 2013-06-01 19:24:05.035756124 -0500 -@@ -769,7 +769,6 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -780,7 +780,6 @@ libs/gst/helpers/Makefile libs/gst/net/Makefile plugins/Makefile plugins/elements/Makefile @@ -9,10 +8,9 @@ diff -u --recursive gstreamer-1.0.7-vanilla/configure.ac gstreamer-1.0.7/configu tests/Makefile tests/benchmarks/Makefile tests/check/Makefile -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile.am ---- gstreamer-1.0.7-vanilla/Makefile.am 2013-06-01 19:23:08.361020919 -0500 -+++ gstreamer-1.0.7/Makefile.am 2013-06-01 19:24:15.036357308 -0500 -@@ -8,7 +8,6 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -8,7 +8,6 @@ aclocal_DATA = gst-element-check-@GST_AP SUBDIRS = pkgconfig \ gst libs plugins \ @@ -20,7 +18,7 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile m4 \ common -@@ -19,7 +18,6 @@ +@@ -19,7 +18,6 @@ endif # These are all the possible subdirs DIST_SUBDIRS = pkgconfig \ gst libs plugins tools \ @@ -28,10 +26,9 @@ diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.am gstreamer-1.0.7/Makefile m4 \ common -diff -u --recursive gstreamer-1.0.7-vanilla/Makefile.in gstreamer-1.0.7/Makefile.in ---- gstreamer-1.0.7-vanilla/Makefile.in 2013-06-01 19:23:08.362020867 -0500 -+++ gstreamer-1.0.7/Makefile.in 2013-06-01 19:24:27.907844191 -0500 -@@ -508,13 +508,12 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -554,13 +554,12 @@ top_srcdir = @top_srcdir@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-docbook aclocaldir = $(datadir)/aclocal aclocal_DATA = gst-element-check-@GST_API_VERSION@.m4 diff --git a/multimedia/icecast/Makefile b/multimedia/icecast/Makefile index 796e9bb95..1b0766e7e 100644 --- a/multimedia/icecast/Makefile +++ b/multimedia/icecast/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=icecast -PKG_VERSION:=2.4.1 +PKG_VERSION:=2.4.2 PKG_RELEASE:=1 PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=André Gaul PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://downloads.xiph.org/releases/icecast/ -PKG_MD5SUM:=b1402712a79734d4720c8fe15fd9fb10 +PKG_MD5SUM:=55947c83d31dfcbbede58c9521c676f4 PKG_FIXUP:=autoreconf diff --git a/multimedia/mjpg-streamer/Makefile b/multimedia/mjpg-streamer/Makefile index 24e569df8..e1e0e200e 100644 --- a/multimedia/mjpg-streamer/Makefile +++ b/multimedia/mjpg-streamer/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mjpg-streamer PKG_REV:=182 PKG_VERSION:=r$(PKG_REV) -PKG_RELEASE:=4 +PKG_RELEASE:=7 PKG_MAINTAINER:=Roger D PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).1.tar.bz2 @@ -49,12 +49,12 @@ define Package/mjpg-streamer/conffiles /etc/config/mjpg-streamer endef -CAMBOZOLA:=cambozola-latest.tar.gz +CAMBOZOLA:=cambozola-0.936.tar.gz define Download/cambozola URL:=http://www.andywilcock.com/code/cambozola FILE:=$(CAMBOZOLA) - MD5SUM:=6c48fd994685d4d72668850eeb613e24 + MD5SUM:=35c45188aa9635aef2b745c35c311396 endef # Fetch latest cambozola that works with latest Java(s) diff --git a/multimedia/mjpg-streamer/files/mjpg-streamer.config b/multimedia/mjpg-streamer/files/mjpg-streamer.config index 7d6bfa454..a40d7873c 100644 --- a/multimedia/mjpg-streamer/files/mjpg-streamer.config +++ b/multimedia/mjpg-streamer/files/mjpg-streamer.config @@ -5,6 +5,8 @@ config mjpg-streamer 'core' option output 'http' option device '/dev/video0' option resolution '640x480' + option yuv '0' + option quality '80' option fps '5' option led 'auto' option www '/www/webcam' diff --git a/multimedia/mjpg-streamer/files/mjpg-streamer.init b/multimedia/mjpg-streamer/files/mjpg-streamer.init index 1ce5ce1db..06630d423 100644 --- a/multimedia/mjpg-streamer/files/mjpg-streamer.init +++ b/multimedia/mjpg-streamer/files/mjpg-streamer.init @@ -43,6 +43,13 @@ start_instance() { config_get fps "$s" 'fps' [ -n "$fps" ] && input_arg="${input_arg} --fps $fps" + config_get_bool yuv "$s" 'yuv' 0 + if [ $yuv -ne 0 ]; then + input_arg="${input_arg} --yuv" + config_get quality "$s" 'quality' + [ -n "$quality" ] && input_arg="${input_arg} --quality $quality" + fi + config_get resolution "$s" 'resolution' [ -n "$resolution" ] && input_arg="${input_arg} --resolution $resolution" diff --git a/multimedia/mjpg-streamer/patches/005-musl_compatibility.patch b/multimedia/mjpg-streamer/patches/005-musl_compatibility.patch new file mode 100644 index 000000000..c758eb953 --- /dev/null +++ b/multimedia/mjpg-streamer/patches/005-musl_compatibility.patch @@ -0,0 +1,13 @@ +--- a/mjpg_streamer.h ++++ b/mjpg_streamer.h +@@ -29,6 +29,10 @@ + #define MAX_OUTPUT_PLUGINS 10 + #define MAX_PLUGIN_ARGUMENTS 32 + ++#define __NEED_pthread_t ++#define __NEED_pthread_mutex_t ++#define __NEED_pthread_cond_t ++ + #include /* for videodev2.h */ + #include + diff --git a/multimedia/mjpg-streamer/patches/040-Buffer-the-bytesused-variable-from-struct-v4l2_buffe.patch b/multimedia/mjpg-streamer/patches/040-Buffer-the-bytesused-variable-from-struct-v4l2_buffe.patch new file mode 100644 index 000000000..a228f420c --- /dev/null +++ b/multimedia/mjpg-streamer/patches/040-Buffer-the-bytesused-variable-from-struct-v4l2_buffe.patch @@ -0,0 +1,87 @@ +From 19202b54698b343a0207d7e213448e32b8e58fc3 Mon Sep 17 00:00:00 2001 +From: Olliver Schinagl +Date: Wed, 29 Oct 2014 09:34:41 +0100 +Subject: [PATCH 1/7] Buffer the bytesused variable from struct v4l2_buffer + +Starting with kernel versions 3.16, (DE)Queing of buffers has been fixed +after it was leaking data for ages. in the struct v4l2_buffer is the +bytesused element which indicates the size of the buffer. This however +gets cleared whenever the buffer gets requeued and is thus no longer +valid. + +This patch copies the bytesused variable so it is available until the +next frame captured again. + +Signed-off-by: Olliver Schinagl +--- + plugins/input_uvc/input_uvc.c | 6 +++--- + plugins/input_uvc/v4l2uvc.c | 2 ++ + plugins/input_uvc/v4l2uvc.h | 1 + + 3 files changed, 6 insertions(+), 3 deletions(-) + +diff --git a/plugins/input_uvc/input_uvc.c b/plugins/input_uvc/input_uvc.c +index e6c74fd..64f66cb 100644 +--- a/plugins/input_uvc/input_uvc.c ++++ b/plugins/input_uvc/input_uvc.c +@@ -482,7 +482,7 @@ void *cam_thread(void *arg) + exit(EXIT_FAILURE); + } + +- //DBG("received frame of size: %d from plugin: %d\n", pcontext->videoIn->buf.bytesused, pcontext->id); ++ //DBG("received frame of size: %d from plugin: %d\n", pcontext->videoIn->tmpbytesused, pcontext->id); + + /* + * Workaround for broken, corrupted frames: +@@ -491,7 +491,7 @@ void *cam_thread(void *arg) + * For example a VGA (640x480) webcam picture is normally >= 8kByte large, + * corrupted frames are smaller. + */ +- if(pcontext->videoIn->buf.bytesused < minimum_size) { ++ if(pcontext->videoIn->tmpbytesused < minimum_size) { + DBG("dropping too small frame, assuming it as broken\n"); + continue; + } +@@ -529,7 +529,7 @@ void *cam_thread(void *arg) + } else { + #endif + //DBG("copying frame from input: %d\n", (int)pcontext->id); +- pglobal->in[pcontext->id].size = memcpy_picture(pglobal->in[pcontext->id].buf, pcontext->videoIn->tmpbuffer, pcontext->videoIn->buf.bytesused); ++ pglobal->in[pcontext->id].size = memcpy_picture(pglobal->in[pcontext->id].buf, pcontext->videoIn->tmpbuffer, pcontext->videoIn->tmpbytesused); + #ifndef NO_LIBJPEG + } + #endif +diff --git a/plugins/input_uvc/v4l2uvc.c b/plugins/input_uvc/v4l2uvc.c +index c5a5aa4..d11510c 100644 +--- a/plugins/input_uvc/v4l2uvc.c ++++ b/plugins/input_uvc/v4l2uvc.c +@@ -532,6 +532,7 @@ int uvcGrab(struct vdIn *vd) + */ + + memcpy(vd->tmpbuffer, vd->mem[vd->buf.index], vd->buf.bytesused); ++ vd->tmpbytesused = vd->buf.bytesused; + + if(debug) + fprintf(stderr, "bytes in used %d \n", vd->buf.bytesused); +@@ -570,6 +571,7 @@ int close_v4l2(struct vdIn *vd) + if(vd->tmpbuffer) + free(vd->tmpbuffer); + vd->tmpbuffer = NULL; ++ vd->tmpbytesused = 0; + free(vd->framebuffer); + vd->framebuffer = NULL; + free(vd->videodevice); +diff --git a/plugins/input_uvc/v4l2uvc.h b/plugins/input_uvc/v4l2uvc.h +index 022c57e..2c7c8ba 100644 +--- a/plugins/input_uvc/v4l2uvc.h ++++ b/plugins/input_uvc/v4l2uvc.h +@@ -83,6 +83,7 @@ struct vdIn { + struct v4l2_requestbuffers rb; + void *mem[NB_BUFFER]; + unsigned char *tmpbuffer; ++ int tmpbytesused; + unsigned char *framebuffer; + streaming_state streamingState; + int grabmethod; +-- +1.9.1 + diff --git a/multimedia/mjpg-streamer/patches/041-Stop-leaking-data-via-struct-v4l2_buffer.patch b/multimedia/mjpg-streamer/patches/041-Stop-leaking-data-via-struct-v4l2_buffer.patch new file mode 100644 index 000000000..4f45da5d6 --- /dev/null +++ b/multimedia/mjpg-streamer/patches/041-Stop-leaking-data-via-struct-v4l2_buffer.patch @@ -0,0 +1,242 @@ +From 11b28b36a8711b53658e8bbc50435595522f91ba Mon Sep 17 00:00:00 2001 +From: Olliver Schinagl +Date: Wed, 29 Oct 2014 11:21:16 +0100 +Subject: [PATCH 2/7] Stop leaking data via struct v4l2_buffer + +Before the 3.16 kernel, the v4l2_buffer was leaking data and violating +its own spec. Since 3.16 this has been corrected and after calling the +QBUF ioctl, the struct gets cleaned up. + +Right now, input_uvc assumes the buffer is valid at all times. This no +longer being true, this patch removes the v4l2_buffer from the vdIn +struct. Certain values are still needed outside of this buffer however, +the length buffer in the buffer array 'mem' and the timestamp. These are +now stored in the vdIn struct. + +All of this is still somewhat hackish, as a) the processing of the image +should really be done inside the uvcGrab function between the queuing +and dequeing of the buffers (or separate that into 3 functions, deq, q +and process and call them from input_uvc). b) we are still copying the +image using memcpy, which is something we don't really want and defeats +the purpose of using a mmap in the first place. Changing this however +requires some heavier re-architecting and in the end, may still not be avoided. + +More information about this bug and change can be found on the +linux-media mailing list[0] with the title uvcvideo fails on 3.16 and +3.17 kernels. + +[0] http://www.spinics.net/lists/linux-media/msg81515.html + +Signed-off-by: Olliver Schinagl +--- + plugins/input_uvc/input_uvc.c | 6 ++-- + plugins/input_uvc/v4l2uvc.c | 64 +++++++++++++++++++++++-------------------- + plugins/input_uvc/v4l2uvc.h | 4 ++- + 3 files changed, 41 insertions(+), 33 deletions(-) + +diff --git a/plugins/input_uvc/input_uvc.c b/plugins/input_uvc/input_uvc.c +index 64f66cb..64ef56c 100644 +--- a/plugins/input_uvc/input_uvc.c ++++ b/plugins/input_uvc/input_uvc.c +@@ -500,8 +500,8 @@ void *cam_thread(void *arg) + if (pcontext->videoIn->soft_framedrop == 1) { + unsigned long last = pglobal->in[pcontext->id].timestamp.tv_sec * 1000 + + (pglobal->in[pcontext->id].timestamp.tv_usec/1000); // convert to ms +- unsigned long current = pcontext->videoIn->buf.timestamp.tv_sec * 1000 + +- pcontext->videoIn->buf.timestamp.tv_usec/1000; // convert to ms ++ unsigned long current = pcontext->videoIn->tmptimestamp.tv_sec * 1000 + ++ pcontext->videoIn->tmptimestamp.tv_usec/1000; // convert to ms + + // if the requested time did not esplashed skip the frame + if ((current - last) < pcontext->videoIn->frame_period_time) { +@@ -543,7 +543,7 @@ void *cam_thread(void *arg) + #endif + + /* copy this frame's timestamp to user space */ +- pglobal->in[pcontext->id].timestamp = pcontext->videoIn->buf.timestamp; ++ pglobal->in[pcontext->id].timestamp = pcontext->videoIn->tmptimestamp; + + /* signal fresh_frame */ + pthread_cond_broadcast(&pglobal->in[pcontext->id].db_update); +diff --git a/plugins/input_uvc/v4l2uvc.c b/plugins/input_uvc/v4l2uvc.c +index d11510c..7ec5eec 100644 +--- a/plugins/input_uvc/v4l2uvc.c ++++ b/plugins/input_uvc/v4l2uvc.c +@@ -217,6 +217,9 @@ static int init_v4l2(struct vdIn *vd) + { + int i; + int ret = 0; ++ struct v4l2_buffer buf; ++ ++ + if((vd->fd = OPEN_VIDEO(vd->videodevice, O_RDWR)) == -1) { + perror("ERROR opening V4L interface"); + DBG("errno: %d", errno); +@@ -375,26 +378,27 @@ static int init_v4l2(struct vdIn *vd) + * map the buffers + */ + for(i = 0; i < NB_BUFFER; i++) { +- memset(&vd->buf, 0, sizeof(struct v4l2_buffer)); +- vd->buf.index = i; +- vd->buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; +- vd->buf.memory = V4L2_MEMORY_MMAP; +- ret = xioctl(vd->fd, VIDIOC_QUERYBUF, &vd->buf); ++ memset(&buf, 0, sizeof(struct v4l2_buffer)); ++ buf.index = i; ++ buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ buf.memory = V4L2_MEMORY_MMAP; ++ ret = xioctl(vd->fd, VIDIOC_QUERYBUF, &buf); + if(ret < 0) { + perror("Unable to query buffer"); + goto fatal; + } + + if(debug) +- fprintf(stderr, "length: %u offset: %u\n", vd->buf.length, vd->buf.m.offset); ++ fprintf(stderr, "length: %u offset: %u\n", buf.length, buf.m.offset); + + vd->mem[i] = mmap(0 /* start anywhere */ , +- vd->buf.length, PROT_READ | PROT_WRITE, MAP_SHARED, vd->fd, +- vd->buf.m.offset); ++ buf.length, PROT_READ | PROT_WRITE, MAP_SHARED, vd->fd, ++ buf.m.offset); + if(vd->mem[i] == MAP_FAILED) { + perror("Unable to map buffer"); + goto fatal; + } ++ vd->memlength[i] = buf.length; + if(debug) + fprintf(stderr, "Buffer mapped at address %p.\n", vd->mem[i]); + } +@@ -403,11 +407,11 @@ static int init_v4l2(struct vdIn *vd) + * Queue the buffers. + */ + for(i = 0; i < NB_BUFFER; ++i) { +- memset(&vd->buf, 0, sizeof(struct v4l2_buffer)); +- vd->buf.index = i; +- vd->buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; +- vd->buf.memory = V4L2_MEMORY_MMAP; +- ret = xioctl(vd->fd, VIDIOC_QBUF, &vd->buf); ++ memset(&buf, 0, sizeof(struct v4l2_buffer)); ++ buf.index = i; ++ buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ buf.memory = V4L2_MEMORY_MMAP; ++ ret = xioctl(vd->fd, VIDIOC_QBUF, &buf); + if(ret < 0) { + perror("Unable to queue buffer"); + goto fatal;; +@@ -499,17 +503,18 @@ int memcpy_picture(unsigned char *out, unsigned char *buf, int size) + int uvcGrab(struct vdIn *vd) + { + #define HEADERFRAME1 0xaf ++ struct v4l2_buffer buf; + int ret; + + if(vd->streamingState == STREAMING_OFF) { + if(video_enable(vd)) + goto err; + } +- memset(&vd->buf, 0, sizeof(struct v4l2_buffer)); +- vd->buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; +- vd->buf.memory = V4L2_MEMORY_MMAP; ++ memset(&buf, 0, sizeof(struct v4l2_buffer)); ++ buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ buf.memory = V4L2_MEMORY_MMAP; + +- ret = xioctl(vd->fd, VIDIOC_DQBUF, &vd->buf); ++ ret = xioctl(vd->fd, VIDIOC_DQBUF, &buf); + if(ret < 0) { + perror("Unable to dequeue buffer"); + goto err; +@@ -517,33 +522,34 @@ int uvcGrab(struct vdIn *vd) + + switch(vd->formatIn) { + case V4L2_PIX_FMT_MJPEG: +- if(vd->buf.bytesused <= HEADERFRAME1) { ++ if(buf.bytesused <= HEADERFRAME1) { + /* Prevent crash + * on empty image */ + fprintf(stderr, "Ignoring empty buffer ...\n"); + return 0; + } + +- /* memcpy(vd->tmpbuffer, vd->mem[vd->buf.index], vd->buf.bytesused); ++ /* memcpy(vd->tmpbuffer, vd->mem[buf.index], buf.bytesused); + +- memcpy (vd->tmpbuffer, vd->mem[vd->buf.index], HEADERFRAME1); ++ memcpy (vd->tmpbuffer, vd->mem[buf.index], HEADERFRAME1); + memcpy (vd->tmpbuffer + HEADERFRAME1, dht_data, sizeof(dht_data)); +- memcpy (vd->tmpbuffer + HEADERFRAME1 + sizeof(dht_data), vd->mem[vd->buf.index] + HEADERFRAME1, (vd->buf.bytesused - HEADERFRAME1)); ++ memcpy (vd->tmpbuffer + HEADERFRAME1 + sizeof(dht_data), vd->mem[buf.index] + HEADERFRAME1, (buf.bytesused - HEADERFRAME1)); + */ + +- memcpy(vd->tmpbuffer, vd->mem[vd->buf.index], vd->buf.bytesused); +- vd->tmpbytesused = vd->buf.bytesused; ++ memcpy(vd->tmpbuffer, vd->mem[buf.index], buf.bytesused); ++ vd->tmpbytesused = buf.bytesused; ++ vd->tmptimestamp = buf.timestamp; + + if(debug) +- fprintf(stderr, "bytes in used %d \n", vd->buf.bytesused); ++ fprintf(stderr, "bytes in used %d \n", buf.bytesused); + break; + case V4L2_PIX_FMT_RGB565: + case V4L2_PIX_FMT_YUYV: + case V4L2_PIX_FMT_RGB24: +- if(vd->buf.bytesused > vd->framesizeIn) +- memcpy(vd->framebuffer, vd->mem[vd->buf.index], (size_t) vd->framesizeIn); ++ if(buf.bytesused > vd->framesizeIn) ++ memcpy(vd->framebuffer, vd->mem[buf.index], (size_t) vd->framesizeIn); + else +- memcpy(vd->framebuffer, vd->mem[vd->buf.index], (size_t) vd->buf.bytesused); ++ memcpy(vd->framebuffer, vd->mem[buf.index], (size_t) buf.bytesused); + break; + + default: +@@ -551,7 +557,7 @@ int uvcGrab(struct vdIn *vd) + break; + } + +- ret = xioctl(vd->fd, VIDIOC_QBUF, &vd->buf); ++ ret = xioctl(vd->fd, VIDIOC_QBUF, &buf); + if(ret < 0) { + perror("Unable to requeue buffer"); + goto err; +@@ -947,7 +953,7 @@ int setResolution(struct vdIn *vd, int width, int height) + DBG("Unmap buffers\n"); + int i; + for(i = 0; i < NB_BUFFER; i++) +- munmap(vd->mem[i], vd->buf.length); ++ munmap(vd->mem[i], vd->memlength[i]); + + if(CLOSE_VIDEO(vd->fd) == 0) { + DBG("Device closed successfully\n"); +diff --git a/plugins/input_uvc/v4l2uvc.h b/plugins/input_uvc/v4l2uvc.h +index 2c7c8ba..e625957 100644 +--- a/plugins/input_uvc/v4l2uvc.h ++++ b/plugins/input_uvc/v4l2uvc.h +@@ -35,6 +35,7 @@ + #include + #include + #include ++#include + + #include /* for videodev2.h */ + #include +@@ -79,11 +80,12 @@ struct vdIn { + char *pictName; + struct v4l2_capability cap; + struct v4l2_format fmt; +- struct v4l2_buffer buf; + struct v4l2_requestbuffers rb; + void *mem[NB_BUFFER]; ++ int memlength[NB_BUFFER]; + unsigned char *tmpbuffer; + int tmpbytesused; ++ struct timeval tmptimestamp; + unsigned char *framebuffer; + streaming_state streamingState; + int grabmethod; +-- +1.9.1 + diff --git a/multimedia/mjpg-streamer/patches/050-fix-yuv-capture.patch b/multimedia/mjpg-streamer/patches/050-fix-yuv-capture.patch new file mode 100644 index 000000000..0c4d27a60 --- /dev/null +++ b/multimedia/mjpg-streamer/patches/050-fix-yuv-capture.patch @@ -0,0 +1,58 @@ +Binary files a/ipkg-ar71xx/mjpg-streamer/usr/lib/input_uvc.so and b/ipkg-ar71xx/mjpg-streamer/usr/lib/input_uvc.so differ +diff -ur a/plugins/input_uvc/input_uvc.c b/plugins/input_uvc/input_uvc.c +--- a/plugins/input_uvc/input_uvc.c 2015-03-02 09:14:05.000000000 +0200 ++++ b/plugins/input_uvc/input_uvc.c 2015-03-02 09:18:22.000000000 +0200 +@@ -311,6 +311,10 @@ + } + memset(cams[id].videoIn, 0, sizeof(struct vdIn)); + ++ /* Non-MJPEG formats seem to fail with unlimited FPS */ ++ if (format != V4L2_PIX_FMT_MJPEG && fps == -1) ++ fps = 15; ++ + /* display the parsed values */ + IPRINT("Using V4L2 device.: %s\n", dev); + IPRINT("Desired Resolution: %i x %i\n", width, height); +diff -ur a/plugins/input_uvc/jpeg_utils.c b/plugins/input_uvc/jpeg_utils.c +--- a/plugins/input_uvc/jpeg_utils.c 2015-03-02 09:17:02.000000000 +0300 ++++ b/plugins/input_uvc/jpeg_utils.c 2015-03-02 09:25:18.000000000 +0200 +@@ -198,7 +198,7 @@ + } + + row_pointer = (JSAMPROW*)line_buffer; +- jpeg_write_scanlines(&cinfo, row_pointer, 1); ++ jpeg_write_scanlines(&cinfo, &row_pointer, 1); + } + } else if (vd->formatIn == V4L2_PIX_FMT_RGB565) { + while(cinfo.next_scanline < vd->height) { +@@ -220,7 +220,7 @@ + } + + row_pointer = (JSAMPROW*)line_buffer; +- jpeg_write_scanlines(&cinfo, row_pointer, 1); ++ jpeg_write_scanlines(&cinfo, &row_pointer, 1); + } + } else if (vd->formatIn == V4L2_PIX_FMT_RGB24) { + jpeg_write_scanlines(&cinfo, (JSAMPROW*)vd->framebuffer, vd->height); +diff -ur a/plugins/input_uvc/v4l2uvc.c b/plugins/input_uvc/v4l2uvc.c +--- a/plugins/input_uvc/v4l2uvc.c 2015-03-02 09:14:05.000000000 +0200 ++++ b/plugins/input_uvc/v4l2uvc.c 2015-03-02 09:22:09.000000000 +0200 +@@ -338,11 +338,15 @@ + vd->frame_period_time = 1000/vd->fps; // calcualate frame period time in ms + IPRINT("Frame period time ......: %ld ms\n", vd->frame_period_time); + +- // set FPS to maximum in order to minimize the lagging + memset(setfps, 0, sizeof(struct v4l2_streamparm)); + setfps->type = V4L2_BUF_TYPE_VIDEO_CAPTURE; + setfps->parm.capture.timeperframe.numerator = 1; +- setfps->parm.capture.timeperframe.denominator = 255; ++ if (vd->formatIn == V4L2_PIX_FMT_MJPEG) ++ // set FPS to maximum in order to minimize the lagging ++ setfps->parm.capture.timeperframe.denominator = 255; ++ else ++ setfps->parm.capture.timeperframe.denominator = vd->fps; ++ + ret = xioctl(vd->fd, VIDIOC_S_PARM, setfps); + if (ret) { + perror("Unable to set the FPS\n"); + diff --git a/multimedia/oggfwd/Makefile b/multimedia/oggfwd/Makefile new file mode 100644 index 000000000..8caf7f1ac --- /dev/null +++ b/multimedia/oggfwd/Makefile @@ -0,0 +1,50 @@ +# +# Copyright (C) 2015 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:=oggfwd +PKG_REV:=506088e5066abd086efc951670906187c120e9a3 +PKG_VERSION:=20150412 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=git://r-w-x.org/oggfwd.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=$(PKG_REV) + +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=LICENSE +PKG_MAINTAINER:=Nicolas Thill + +include $(INCLUDE_DIR)/package.mk + +define Package/oggfwd + SECTION:=multimedia + CATEGORY:=Multimedia + SUBMENU:=Streaming + TITLE:=Pipe media into icecast + URL:=http://www.v2v.cc/~j/oggfwd + DEPENDS:=+libpthread +libshout +endef + +define Package/oggfwd/description + A basic icecast client that is very simple but also very useful for video + streaming. +endef + +MAKE_FLAGS += \ + INCLUDEFLAGS="$(TARGET_LDFLAGS)" \ + LINKFLAGS="$(TARGET_LDFLAGS) -lshout" \ + +define Package/oggfwd/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/oggfwd $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,oggfwd)) diff --git a/net/announce/Makefile b/net/announce/Makefile index d2c17dad1..60d9e63f6 100644 --- a/net/announce/Makefile +++ b/net/announce/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=announce -PKG_VERSION:=1.0 +PKG_VERSION:=1.0.1 PKG_RELEASE:=1 PKG_LICENSE:=BSD-3-Clause PKG_LICENSE_FILES:=src/LICENSE.txt @@ -16,7 +16,7 @@ PKG_MAINTAINER:=Simon Peter PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/probonopd/announce.git -PKG_SOURCE_VERSION:=70d70f998686199deaa5d62b54688c869e237eef +PKG_SOURCE_VERSION:=1368525c7305ca5bb4134242f332344f5f7e94e3 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION) PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_SUBDIR) diff --git a/net/apinger/Makefile b/net/apinger/Makefile new file mode 100644 index 000000000..5d73ae1bf --- /dev/null +++ b/net/apinger/Makefile @@ -0,0 +1,67 @@ +# +# 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:=apinger +PKG_VERSION:=0.6.1 +PKG_RELEASE=$(PKG_SOURCE_VERSION) + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/Jajcus/apinger.git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=c7da72f7ec26eedd7fd8d224c0e10787b204f94e +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz + +PKG_MAINTAINER:=Alex Samorukov +PKG_LICENSE:= GPL-2.0 + +PKG_FIXUP:=autoreconf + +PKG_BUILD_PARALLEL:=1 +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/apinger + SECTION:=net + CATEGORY:=Network + TITLE:=Tool which monitors various IP devices by simple ICMP echo requests + URL:=https://github.com/Jajcus/apinger + PKG_MAINTAINER:=Alex Samorukov +endef + +define Package/apinger/description + Alarm Pinger (apinger) is a little tool which monitors various IP devices by + simple ICMP echo requests. There are various other tools, that can do this, + but most of them are shell or perl scripts, spawning many processes, thus much + CPU-expensive, especially when one wants continuous monitoring and fast + response on target failure. Alarm Pinger is a single program written in C, so + it doesn't need much CPU power even when monitoring many targets with frequent + probes. Alarm Pinger supports both IPv4 and IPv6. The code have been tested + on Linux and FreeBSD. +endef + +define Package/apinger/conffiles +/etc/apinger.conf +endef + +define Build/Configure + $(call Build/Configure/Default) +endef + +define Package/apinger/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/apinger $(1)/usr/sbin/ + $(INSTALL_DIR) $(1)/etc + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/apinger.conf $(1)/etc/apinger.conf + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/apinger.init $(1)/etc/init.d/apinger +endef + +$(eval $(call BuildPackage,apinger)) + diff --git a/net/apinger/files/apinger.init b/net/apinger/files/apinger.init new file mode 100644 index 000000000..8caac3869 --- /dev/null +++ b/net/apinger/files/apinger.init @@ -0,0 +1,18 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2006-2011 OpenWrt.org + +START=80 + +SERVICE_USE_PID=1 + +start() { + service_start /usr/sbin/apinger +} + +stop() { + service_stop /usr/sbin/apinger +} + +reload() { + service_reload /usr/sbin/apinger +} diff --git a/net/apinger/patches/001-autoreconf.patch b/net/apinger/patches/001-autoreconf.patch new file mode 100644 index 000000000..cb5bd454d --- /dev/null +++ b/net/apinger/patches/001-autoreconf.patch @@ -0,0 +1,13 @@ +--- apinger-0.6.1/acinclude.m4 2003-10-21 12:44:48.000000000 +0000 ++++ apinger-0.6.1/acinclude.m4 2015-04-08 15:27:37.451903960 +0000 +@@ -39,9 +39,7 @@ + [$jk_inet_includes + $jk_icmp_includes]) + +-AC_CHECK_MEMBERS([struct icmp.icmp_type, struct icmp.icmp_code,\ +-struct icmp.icmp_cksum, struct icmp.icmp_seq,\ +-struct icmp.icmp_id],[], ++AC_CHECK_MEMBERS([struct icmp.icmp_type, struct icmp.icmp_code,struct icmp.icmp_cksum, struct icmp.icmp_seq,struct icmp.icmp_id],[], + AC_MSG_ERROR(struct icmp not defined or not compatible), + [$jk_inet_includes + $jk_icmp_includes]) diff --git a/net/apinger/patches/002-run_as_user.patch b/net/apinger/patches/002-run_as_user.patch new file mode 100644 index 000000000..16d64acc5 --- /dev/null +++ b/net/apinger/patches/002-run_as_user.patch @@ -0,0 +1,11 @@ +--- apinger-0.6.1/src/apinger.conf.orig 2015-04-08 16:05:24.558919722 +0000 ++++ apinger-0.6.1/src/apinger.conf 2015-04-08 16:07:47.089170236 +0000 +@@ -9,7 +9,7 @@ + + ## User and group the pinger should run as + user "nobody" +-group "nobody" ++group "nogroup" + + ## Mailer to use (default: "/usr/lib/sendmail -t") + #mailer "/var/qmail/bin/qmail-inject" diff --git a/net/apinger/patches/003-no_docs.patch b/net/apinger/patches/003-no_docs.patch new file mode 100644 index 000000000..c08f44de7 --- /dev/null +++ b/net/apinger/patches/003-no_docs.patch @@ -0,0 +1,11 @@ +--- apinger-0.6.1/Makefile.am.orig 2015-04-08 16:47:40.999990050 +0000 ++++ apinger-0.6.1/Makefile.am 2015-04-08 16:48:07.565220137 +0000 +@@ -1,7 +1,7 @@ + + EXTRA_DIST = autogen.sh TODO BUGS + +-SUBDIRS = src doc ++SUBDIRS = src + + .PHONY: ChangeLog + diff --git a/net/bind/patches/002-autoconf-ar-fix.patch b/net/bind/patches/002-autoconf-ar-fix.patch new file mode 100644 index 000000000..501fa7d3b --- /dev/null +++ b/net/bind/patches/002-autoconf-ar-fix.patch @@ -0,0 +1,29 @@ +--- a/configure.in ++++ b/configure.in +@@ -93,26 +93,11 @@ esac + # + AC_CONFIG_FILES([make/rules make/includes]) + +-AC_PATH_PROG(AR, ar) +-ARFLAGS="cruv" +-AC_SUBST(AR) +-AC_SUBST(ARFLAGS) +- + # The POSIX ln(1) program. Non-POSIX systems may substitute + # "copy" or something. + LN=ln + AC_SUBST(LN) + +-case "$AR" in +- "") +- AC_MSG_ERROR([ +-ar program not found. Please fix your PATH to include the directory in +-which ar resides, or set AR in the environment with the full path to ar. +-]) +- +- ;; +-esac +- + # + # Etags. + # diff --git a/net/bridge-utils/Makefile b/net/bridge-utils/Makefile new file mode 100644 index 000000000..0075c0edb --- /dev/null +++ b/net/bridge-utils/Makefile @@ -0,0 +1,59 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk +include $(INCLUDE_DIR)/kernel.mk + +PKG_NAME:=bridge-utils +PKG_VERSION:=1.5 +PKG_RELEASE:=5 + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/bridge-utils.git +PKG_SOURCE_VERSION:=v${PKG_VERSION} +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz + +PKG_LICENSE:=GPL-2.0+ +PKG_LICENSE_FILES:=COPYING +PKG_FIXUP:=autoreconf + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz + +include $(INCLUDE_DIR)/package.mk + +define Package/bridge + SECTION:=net + CATEGORY:=Base system + TITLE:=Ethernet bridging configuration utility + URL:=http://bridge.sourceforge.net/ + PKG_MAINTAINER:=Nikolay Martynov +endef + +define Package/bridge/description + Manage ethernet bridging: a way to connect networks together to + form a larger network. +endef + +TARGET_CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE + +CONFIGURE_ARGS += \ + --with-linux-headers="$(LINUX_DIR)" \ + +define Package/bridge/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/brctl/brctl $(1)/usr/sbin +endef + +define Package/bridge/prerm +#!/bin/sh +$${IPKG_INSTROOT}/bin/busybox brctl -h 2>&1 | grep -q BusyBox && \ +ln -sf ../../bin/busybox $${IPKG_INSTROOT}/usr/sbin/brctl +exit 0 +endef + +$(eval $(call BuildPackage,bridge)) diff --git a/net/bridge-utils/patches/001-libbridge_cflags.patch b/net/bridge-utils/patches/001-libbridge_cflags.patch new file mode 100644 index 000000000..e35a64947 --- /dev/null +++ b/net/bridge-utils/patches/001-libbridge_cflags.patch @@ -0,0 +1,11 @@ +--- a/libbridge/Makefile.in ++++ b/libbridge/Makefile.in +@@ -5,7 +5,7 @@ AR=ar + RANLIB=@RANLIB@ + + CC=@CC@ +-CFLAGS = -Wall -g $(KERNEL_HEADERS) ++CFLAGS = -Wall -g @CFLAGS@ $(KERNEL_HEADERS) + + prefix=@prefix@ + exec_prefix=@exec_prefix@ diff --git a/net/bridge-utils/patches/010-fix_struct_in6_addr_usage.patch b/net/bridge-utils/patches/010-fix_struct_in6_addr_usage.patch new file mode 100644 index 000000000..c2087e590 --- /dev/null +++ b/net/bridge-utils/patches/010-fix_struct_in6_addr_usage.patch @@ -0,0 +1,10 @@ +--- a/libbridge/libbridge.h ++++ b/libbridge/libbridge.h +@@ -20,6 +20,7 @@ + #define _LIBBRIDGE_H + + #include ++#include + #include + #include + diff --git a/net/bridge-utils/patches/100-musl-compat.patch b/net/bridge-utils/patches/100-musl-compat.patch new file mode 100644 index 000000000..5655643d8 --- /dev/null +++ b/net/bridge-utils/patches/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/libbridge/libbridge.h ++++ b/libbridge/libbridge.h +@@ -19,6 +19,8 @@ + #ifndef _LIBBRIDGE_H + #define _LIBBRIDGE_H + ++#include ++#include + #include + #include + #include diff --git a/net/bwm-ng/Makefile b/net/bwm-ng/Makefile index be017cc05..f2084bec9 100644 --- a/net/bwm-ng/Makefile +++ b/net/bwm-ng/Makefile @@ -1,12 +1,12 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # include $(TOPDIR)/rules.mk PKG_NAME:=bwm-ng PKG_VERSION:=0.6 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.gropp.org/bwm-ng diff --git a/net/bwm-ng/patches/0001-fix-gcc-security-build.patch b/net/bwm-ng/patches/0001-fix-gcc-security-build.patch new file mode 100644 index 000000000..742e45d73 --- /dev/null +++ b/net/bwm-ng/patches/0001-fix-gcc-security-build.patch @@ -0,0 +1,11 @@ +--- a/src/output.c ++++ b/src/output.c +@@ -234,7 +234,7 @@ int print_header(int option) { + if (output_method==PLAIN_OUT && ansi_output) printf("\033[1;2H"); + printf("bwm-ng v" VERSION " (delay %2.3fs); ",(float)delay/1000); + if (output_method==PLAIN_OUT) printf("press 'ctrl-c' to end this%s",(ansi_output ? "\033[2;2H" : "")); else printf("input: "); +- printf(input2str()); ++ printf("%s\n",input2str()); + printf("%s\n",show_all_if2str()); + if (output_method==PLAIN_OUT) { + if (ansi_output) diff --git a/net/clamav/Makefile b/net/clamav/Makefile new file mode 100644 index 000000000..3f3edab56 --- /dev/null +++ b/net/clamav/Makefile @@ -0,0 +1,120 @@ +# +# Copyright (C) 2015 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:=clamav +PKG_VERSION:=0.98.7 +PKG_RELEASE:=1 + +PKG_LICENSE:=GPL-2.0 +PKG_MAINTAINER:=Marko Ratkaj + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://sourceforge.net/projects/clamav/files/clamav/$(PKG_VERSION)/ +PKG_MD5SUM:=157c601161da1c2d5a0e48ea1b49e067 + +PKG_BUILD_PARALLEL:=1 +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/uclibc++.mk +include $(INCLUDE_DIR)/package.mk + +define Package/clamav/Default + SECTION:=net + DEPENDS:=+libpthread +uclibcxx +zlib +libcurl +libopenssl + CATEGORY:=Network + SUBMENU:=Web Servers/Proxies + TITLE:=ClamAV + URL:=http://www.clamav.net/ +endef + +define Package/clamav + $(call Package/clamav/Default) +endef + +define Package/freshclam + $(call Package/clamav/Default) + DEPENDS+= +clamav + TITLE+=database updater +endef + +define Package/clamav/description + ClamAV is an open source antivirus engine for detecting trojans, + viruses, malware & other malicious threats. +endef + +define Package/freshclam/description + Database updater for ClamAV +endef + +define Package/clamav/conffiles +endef + +CONFIGURE_VARS += \ + INCLUDES="" \ + CXXFLAGS="$$$$CXXFLAGS -fno-rtti" \ + LIBS="-lpthread" \ + +define Build/Configure + $(call Build/Configure/Default, \ + --sysconfdir=/etc/clamav/ \ + --prefix=/usr/ \ + --exec-prefix=/usr/ \ + --disable-xml \ + --disable-bzip2 \ + --enable-ltdl-install \ + --with-user nobody \ + --with-group nogroup \ + ) +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" \ + all install +endef + +define Package/clamav/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/clamd $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clamav-config $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clambc $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clamconf $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clamdscan $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clamscan $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sigtool $(1)/usr/sbin/ + + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/clamav.h $(1)/usr/include/ + + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib*/* $(1)/usr/lib/ + + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_CONF) ./files/clamav.config $(1)/etc/config/clamav + + $(INSTALL_DIR) $(1)/etc/init.d/ + $(INSTALL_BIN) ./files/clamav.init $(1)/etc/init.d/clamav + + $(INSTALL_DIR) $(1)/usr/share/clamav + $(CP) ./files/bytecode.cvd $(1)/usr/share/clamav/ +endef + +define Package/freshclam/install + $(INSTALL_DIR) $(1)/usr/sbin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/freshclam $(1)/usr/sbin/ + + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_CONF) ./files/freshclam.config $(1)/etc/config/freshclam + + $(INSTALL_DIR) $(1)/etc/init.d/ + $(INSTALL_BIN) ./files/freshclam.init $(1)/etc/init.d/freshclam +endef + +$(eval $(call BuildPackage,clamav)) +$(eval $(call BuildPackage,freshclam)) diff --git a/net/clamav/files/bytecode.cvd b/net/clamav/files/bytecode.cvd new file mode 100644 index 000000000..07ff8ab01 Binary files /dev/null and b/net/clamav/files/bytecode.cvd differ diff --git a/net/clamav/files/clamav.config b/net/clamav/files/clamav.config new file mode 100644 index 000000000..1543caa71 --- /dev/null +++ b/net/clamav/files/clamav.config @@ -0,0 +1,34 @@ +config clamav 'clamav' + option clamd_config_file '/etc/clamav/clamd.conf' + option LogFile '/tmp/clamd.log' + option LogFileMaxSize '1M' + option LogTime 'no' + option LogVerbose 'no' + option ExtendedDetectionInfo 'no' + option OfficialDatabaseOnly 'no' + option StreamMinPort '1024' + option StreamMaxPort '2048' + option MaxThreads '10' + option ReadTimeout '30' + option CommandReadTimeout '5' + option MaxDirectoryRecursion '15' + option FollowDirectorySymlinks 'no' + option FollowFileSymlinks 'no' + option SelfCheck '600' + option DetectPUA 'yes' + option ScanPE 'yes' + option DisableCertCheck 'no' + option ScanELF 'yes' + option DetectBrokenExecutables 'no' + option ScanOLE2 'yes' + option ScanPDF 'yes' + option ScanSWF 'yes' + option ScanMail 'yes' + option ScanPartialMessages 'no' + option ScanArchive 'yes' + option ArchiveBlockEncrypted 'yes' + option MaxFileSize '10M' + option TemporaryDirectory '/tmp' + option LocalSocket '/var/run/clamav/clamd.sock' + option User 'nobody' + option ExitOnOOM 'yes' diff --git a/net/clamav/files/clamav.init b/net/clamav/files/clamav.init new file mode 100644 index 000000000..b2a895019 --- /dev/null +++ b/net/clamav/files/clamav.init @@ -0,0 +1,116 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2015 OpenWrt.org + +START=90 +STOP=10 + +USE_PROCD=1 +PROG=/usr/sbin/clamd +CLAMD_CONFIGFILE="/tmp/clamav/clamd.conf" + +validate_clamav_section() { + uci_validate_section clamav clamav "${1}" \ + 'clamd_config_file:string' \ + 'LogFile:string' \ + 'LogFileMaxSize:string' \ + 'LogVerbose:string' \ + 'ExtendedDetectionInfo:string' \ + 'LogTime:string' \ + 'OfficialDatabaseOnly:string' \ + 'StreamMinPort:uinteger' \ + 'StreamMaxPort:uinteger' \ + 'MaxThreads:uinteger' \ + 'ReadTimeout:uinteger' \ + 'CommandReadTimeout:uinteger' \ + 'MaxDirectoryRecursion:uinteger' \ + 'FollowDirectorySymlinks:string' \ + 'FollowFileSymlinks:string' \ + 'SelfCheck:uinteger' \ + 'DetectPUA:string' \ + 'ScanPE:string' \ + 'DisableCertCheck:string' \ + 'ScanELF:string' \ + 'DetectBrokenExecutables:string' \ + 'ScanOLE2:string' \ + 'ScanPDF:string' \ + 'ScanSWF:string' \ + 'ScanMail:string' \ + 'ScanPartialMessages:string' \ + 'ScanArchive:string' \ + 'TemporaryDirectory:string' \ + 'ArchiveBlockEncrypted:string' \ + 'MaxFileSize:string' \ + 'LocalSocket:string' \ + 'User:string' \ + 'ExitOnOOM:string' +} + +start_service() { + local clamd_config_file LogFile LogTime StreamMinPort \ + StreamMaxPort MaxThreads ReadTimeout CommandReadTimeout MaxDirectoryRecursion \ + FollowFileSymlinks FollowDirectorySymlinks SelfCheck DetectPUA ScanPE DisableCertCheck \ + ScanELF DetectBrokenExecutables ScanOLE2 ScanPDF ScanSWF ScanMail ScanPartialMessages \ + ScanArchive TemporaryDirectory ArchiveBlockEncrypted MaxFileSize LocalSocket User + + validate_clamav_section clamav || { + echo "validation failed" + return 1 + } + + mkdir -p /usr/share/clamav + mkdir -p /etc/clamav/ + mkdir -p /var/run/clamav/ + chmod a+rw /var/run/clamav + + mkdir -p $(dirname $CLAMD_CONFIGFILE) + ln -sf $clamd_config_file $CLAMD_CONFIGFILE + + echo "LogFile " $LogFile > $CLAMD_CONFIGFILE + echo "LogFileMaxSize " $LogFileMaxSize >> $CLAMD_CONFIGFILE + echo "LogVerbose " $LogVerbose >> $CLAMD_CONFIGFILE + echo "ExtendedDetectionInfo " $ExtendedDetectionInfo >> $CLAMD_CONFIGFILE + echo "LogTime " $LogTime >> $CLAMD_CONFIGFILE + echo "OfficialDatabaseOnly " $OfficialDatabaseOnly >> $CLAMD_CONFIGFILE + echo "StreamMinPort " $StreamMinPort >> $CLAMD_CONFIGFILE + echo "StreamMaxPort " $StreamMaxPort >> $CLAMD_CONFIGFILE + echo "MaxThreads " $MaxThreads >> $CLAMD_CONFIGFILE + echo "ReadTimeout " $ReadTimeout >> $CLAMD_CONFIGFILE + echo "CommandReadTimeout " $CommandReadTimeout >> $CLAMD_CONFIGFILE + echo "MaxDirectoryRecursion " $MaxDirectoryRecursion >> $CLAMD_CONFIGFILE + echo "FollowDirectorySymlinks " $FollowDirectorySymlinks >> $CLAMD_CONFIGFILE + echo "FollowFileSymlinks " $FollowFileSymlinks >> $CLAMD_CONFIGFILE + echo "SelfCheck " $SelfCheck >> $CLAMD_CONFIGFILE + echo "DetectPUA " $DetectPUA >> $CLAMD_CONFIGFILE + echo "ScanPE " $ScanPE >> $CLAMD_CONFIGFILE + echo "DisableCertCheck " $DisableCertCheck >> $CLAMD_CONFIGFILE + echo "ScanELF " $ScanELF >> $CLAMD_CONFIGFILE + echo "DetectBrokenExecutables " $DetectBrokenExecutables >> $CLAMD_CONFIGFILE + echo "ScanOLE2 " $ScanOLE2 >> $CLAMD_CONFIGFILE + echo "ScanPDF " $ScanPDF >> $CLAMD_CONFIGFILE + echo "ScanSWF " $ScanSWF >> $CLAMD_CONFIGFILE + echo "ScanMail " $ScanMail >> $CLAMD_CONFIGFILE + echo "ScanPartialMessages " $ScanPartialMessages >> $CLAMD_CONFIGFILE + echo "ScanArchive " $ScanArchive >> $CLAMD_CONFIGFILE + echo "TemporaryDirectory " $TemporaryDirectory >> $CLAMD_CONFIGFILE + echo "ArchiveBlockEncrypted " $ArchiveBlockEncrypted >> $CLAMD_CONFIGFILE + echo "MaxFileSize " $MaxFileSize >> $CLAMD_CONFIGFILE + echo "LocalSocket " $LocalSocket >> $CLAMD_CONFIGFILE + echo "User " $User >> $CLAMD_CONFIGFILE + echo "ExitOnOOM " $ExitOnOOM >> $CLAMD_CONFIGFILE + + procd_open_instance + procd_set_param command $PROG -c $CLAMD_CONFIGFILE + procd_set_param file $CLAMD_CONFIGFILE + procd_close_instance +} + +stop_service() +{ + service_stop ${PROG} +} + +service_triggers() +{ + procd_add_reload_trigger "clamav" + procd_add_validation validate_clamav_section +} diff --git a/net/clamav/files/freshclam.config b/net/clamav/files/freshclam.config new file mode 100644 index 000000000..827e8dd95 --- /dev/null +++ b/net/clamav/files/freshclam.config @@ -0,0 +1,7 @@ +config freshclam 'freshclam' + option freshclam_config_file '/etc/clamav/freshclam.conf' + option UpdateLogFile '/tmp/freshclam.log' + option DatabaseMirror 'database.clamav.net' + option NotifyClamd '/etc/clamav/clamd.conf' + option DatabaseOwner 'root' + option CompressLocalDatabase 'yes' diff --git a/net/clamav/files/freshclam.init b/net/clamav/files/freshclam.init new file mode 100644 index 000000000..37b276729 --- /dev/null +++ b/net/clamav/files/freshclam.init @@ -0,0 +1,63 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2015 OpenWrt.org + +START=90 +STOP=10 + +USE_PROCD=1 +PROG=/usr/sbin/freshclam +FRESHCLAM_CONFIGFILE="/tmp/clamav/freshclam.conf" + +validate_freshclam_section() { + uci_validate_section freshclam freshclam "${1}" \ + 'freshclam_config_file:string' \ + 'UpdateLogFile:string' \ + 'DatabaseMirror:string' \ + 'NotifyClamd:string' \ + 'DatabaseOwner:string' \ + 'CompressLocalDatabase:string:' +} + +start_service() { + local freshclam_config_file UpdateLogFile DatabaseOwner NotifyClamd DatabaseMirror + + validate_freshclam_section freshclam || { + echo "validation failed" + return 1 + } + + [ -f /tmp/freshclam.pid ] && echo "already running" && return 0 + + mkdir -p /usr/share/clamav + mkdir -p /etc/clamav + touch /tmp/freshclam.log + touch /tmp/freshclam.pid + + mkdir -p $(dirname $FRESHCLAM_CONFIGFILE) + ln -sf $freshclam_config_file $FRESHCLAM_CONFIGFILE + + echo "UpdateLogFile " $UpdateLogFile > $FRESHCLAM_CONFIGFILE + echo "DatabaseMirror " $DatabaseMirror >> $FRESHCLAM_CONFIGFILE + echo "NotifyClamd " $NotifyClamd >> $FRESHCLAM_CONFIGFILE + echo "DatabaseOwner " $DatabaseOwner >> $FRESHCLAM_CONFIGFILE + echo "CompressLocalDatabase " $CompressLocalDatabase >> $FRESHCLAM_CONFIGFILE + + procd_open_instance + procd_set_param command $PROG -d --config-file=$FRESHCLAM_CONFIGFILE -p /tmp/freshclam.pid --no-warnings + procd_set_param file $FRESHCLAM_CONFIGFILE + procd_close_instance +} + +stop_service() +{ + [ ! -f /tmp/freshclam.pid ] && echo "not running" && return 0 + PID=`cat /tmp/freshclam.pid` + kill $PID + rm -f /tmp/freshclam.pid +} + +service_triggers() +{ + procd_add_reload_trigger "freshclam" + procd_add_validation validate_freshclam_section +} diff --git a/net/clamav/patches/001-compile.patch b/net/clamav/patches/001-compile.patch new file mode 100644 index 000000000..399225708 --- /dev/null +++ b/net/clamav/patches/001-compile.patch @@ -0,0 +1,10 @@ +--- a/clamdscan/proto.c ++++ b/clamdscan/proto.c +@@ -55,6 +55,7 @@ + #include "shared/misc.h" + #include "shared/clamdcom.h" + ++#include + #include "proto.h" + #include "client.h" + diff --git a/net/coova-chilli/Makefile b/net/coova-chilli/Makefile index 2ff8729ed..b8acf5426 100644 --- a/net/coova-chilli/Makefile +++ b/net/coova-chilli/Makefile @@ -12,7 +12,7 @@ PKG_VERSION:=1.3.0+20141128 PKG_MAINTAINER:=Imre Kaloz PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=git://github.com/coova/coova-chilli @@ -36,6 +36,7 @@ PKG_CONFIG_DEPENDS := \ COOVACHILLI_OPENSSL include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/kernel.mk define Package/coova-chilli SUBMENU:=Captive Portals @@ -61,6 +62,38 @@ define Package/coova-chilli/config source "$(SOURCE)/Config.in" endef +define KernelPackage/ipt-coova + URL:=http://www.coova.org/CoovaChilli + SUBMENU:=Netfilter Extensions + DEPENDS:=coova-chilli +kmod-ipt-core +libxtables + TITLE:=Coova netfilter module + FILES:=$(PKG_BUILD_DIR)/src/linux/xt_*.$(LINUX_KMOD_SUFFIX) + AUTOLOAD:=$(call AutoProbe,xt_coova) +endef + +define KernelPackage/ipt-coova/description + Netfilter kernel module for CoovaChilli + Includes: + - coova +endef + +DISABLE_NLS= + +TARGET_CFLAGS += $(FPIC) + +CONFIGURE_VARS += \ + ARCH="$(LINUX_KARCH)" \ + KERNEL_DIR="$(LINUX_DIR)" + +MAKE_FLAGS += \ + ARCH="$(LINUX_KARCH)" \ + KERNEL_DIR="$(LINUX_DIR)" + +MAKE_INSTALL_FLAGS += \ + ARCH="$(LINUX_KARCH)" \ + KERNEL_DIR="$(LINUX_DIR)" \ + INSTALL_MOD_PATH="$(PKG_INSTALL_DIR)" + define Build/Prepare $(call Build/Prepare/Default) ( cd $(PKG_BUILD_DIR) ; \ @@ -80,13 +113,14 @@ define Build/Configure $(if $(CONFIG_COOVACHILLI_LARGELIMITS),--enable,--disable)-largelimits \ $(if $(CONFIG_COOVACHILLI_UAMDOMAINFILE),--enable,--disable)-uamdomainfile \ $(if $(CONFIG_COOVACHILLI_MATRIXSSL),--with,--without)-matrixssl \ - $(if $(CONFIG_COOVACHILLI_CYASSL),--with,--without)-cyaxssl \ + $(if $(CONFIG_COOVACHILLI_CYASSL),--with,--without)-cyassl \ $(if $(CONFIG_COOVACHILLI_OPENSSL),--with,--without)-openssl \ + $(if $(CONFIG_PACKAGE_kmod-ipt-coova),--with-nfcoova) \ ) endef define Package/coova-chilli/conffiles -/etc/chilli.conf +/etc/config/chilli endef define Package/coova-chilli/install @@ -100,6 +134,17 @@ define Package/coova-chilli/install $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/chilli* $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/usr/lib/ $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*.so.* $(1)/usr/lib/ + $(if $(CONFIG_PACKAGE_kmod-ipt-coova), \ + $(INSTALL_DIR) $(1)/usr/lib/iptables; \ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/iptables/lib*.so $(1)/usr/lib/iptables/ \ + ) + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) files/chilli.init $(1)/etc/init.d/chilli + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_DATA) files/chilli.config $(1)/etc/config/chilli + $(INSTALL_DIR) $(1)/lib/firewall + $(CP) files/chilli.firewall $(1)/lib/firewall/chilli.sh endef $(eval $(call BuildPackage,coova-chilli)) +$(eval $(call KernelPackage,ipt-coova)) diff --git a/net/coova-chilli/files/chilli.config b/net/coova-chilli/files/chilli.config new file mode 100644 index 000000000..6aa98373d --- /dev/null +++ b/net/coova-chilli/files/chilli.config @@ -0,0 +1,230 @@ +# +# Sample Coova-Chilli configuration file +# + +config chilli + # disable to running chilli. remove this option before running. + option disabled 1 + + # name of TUN device name. required. + option tundev 'tun0' + + # Include this flag if process is to run in the foreground + #option fg + + # Include this flag to include debug information. + #option debug 9 + + # Re-read configuration file at this interval. Will also cause new domain + # name lookups to be performed. Value is given in seconds. + #option interval 3600 + + # File to store information about the process id of the program. + # The program must have write access to this file/directory. + #option pidfile /var/run/chilli.pid + + # Directory to use for nonvolatile storage. + # The program must have write access to this directory. + # this option is currently ignored + #option statedir ./ + + + # TUN parameters + + # IP network address of external packet data network + # Used to allocate dynamic IP addresses and set up routing. + # Normally you do not need to uncomment this option. + #option net 192.168.182.0/24 + + # Dynamic IP address pool + # Used to allocate dynamic IP addresses to clients. + # If not set it defaults to the net tag. + # Do not uncomment this option unless you are an experienced user! + #option dynip 192.168.182.0/24 + + # Static IP address pool + # Used to allocate static IP addresses to clients. + # Do not uncomment this option unless you are an experienced user! + #option statip 192.168.182.0/24 + + + # Primary DNS server. + # Will be suggested to the client. + # If omitted the system default will be used. + # Normally you do not need to uncomment this option. + #option dns1 172.16.0.5 + + # Secondary DNS server. + # Will be suggested to the client. + # If omitted the system default will be used. + # Normally you do not need to uncomment this option. + #option dns2 172.16.0.6 + + # Domain name + # Will be suggested to the client. + # Normally you do not need to uncomment this option. + #option domain key.chillispot.org + + # Script executed after network interface has been brought up. + # Executed with the following parameters: + # + # Normally you do not need to uncomment this option. + #option ipup /etc/chilli.ipup + + # Script executed after network interface has been taken down. + # Executed with the following parameters: + # + # Normally you do not need to uncomment this option. + #option ipdown /etc/chilli.ipdown + + + # Radius parameters + + # IP address to listen to + # Normally you do not need to uncomment this option. + #option radiuslisten 127.0.0.1 + + # IP address of radius server 1 + # For most installations you need to modify this option. + radiusserver1 rad01.chillispot.org + + # IP address of radius server 2 + # If you have only one radius server you should set radiusserver2 to the + # same value as radiusserver1. + # For most installations you need to modify this option. + radiusserver2 rad02.chillispot.org + + # Radius authentication port + # The UDP port number to use for radius authentication requests. + # The same port number is used for both radiusserver1 and radiusserver2. + # Normally you do not need to uncomment this option. + #option radiusauthport 1812 + + # Radius accounting port + # The UDP port number to use for radius accounting requests. + # The same port number is used for both radiusserver1 and radiusserver2. + # Normally you do not need to uncomment this option. + #option radiusacctport 1813 + + # Radius shared secret for both servers + # For all installations you should modify this option. + #option radiussecret testing123 + + # Radius NAS-Identifier + # Normally you do not need to uncomment this option. + #option radiusnasid nas01 + + # WISPr Location ID. Should be in the format: isocc=, + # cc=,ac=,network= + # Normally you do not need to uncomment this option. + #option radiuslocationid isocc=us,cc=1,ac=408,network=ACMEWISP_NewarkAirport + + # WISPr Location Name. Should be in the format: + # , + # Normally you do not need to uncomment this option. + #option radiuslocationname ACMEWISP,Gate_14_Terminal_C_of_Newark_Airport + + + # Radius proxy parameters + + # IP address to listen to + # Normally you do not need to uncomment this option. + #option proxylisten 10.0.0.1 + + # UDP port to listen to. + # If not specified a port will be selected by the system + # Normally you do not need to uncomment this option. + #option proxyport 1645 + + # Client(s) from which we accept radius requests + # Normally you do not need to uncomment this option. + #option proxyclient 10.0.0.1/24 + + # Radius proxy shared secret for all clients + # If not specified defaults to radiussecret + # Normally you do not need to uncomment this option. + #option proxysecret testing123 + + + # DHCP Parameters + + # Ethernet interface to listen to. + # This is the network interface which is connected to the access points. + # In a typical configuration this option should be set to eth1. + dhcpif eth1 + + # Use specified MAC address. + # An address in the range 00:00:5E:00:02:00 - 00:00:5E:FF:FF:FF falls + # within the IANA range of addresses and is not allocated for other + # purposes. + # Normally you do not need to uncomment this option. + #option dhcpmac 00:00:5E:00:02:00 + + # Time before DHCP lease expires + # Normally you do not need to uncomment this option. + #option lease 600 + + + # Universal access method (UAM) parameters + + # URL of web server handling authentication. + uamserver https://radius.chillispot.org/hotspotlogin + + # URL of welcome homepage. + # Unauthenticated users will be redirected to this URL. If not specified + # users will be redirected to the uamserver instead. + # Normally you do not need to uncomment this option. + #option uamhomepage http://192.168.182.1/welcome.html + + # Shared between chilli and authentication web server + #option uamsecret ht2eb8ej6s4et3rg1ulp + + # IP address to listen to for authentication requests + # Do not uncomment this option unless you are an experienced user! + #option uamlisten 192.168.182.1 + + # TCP port to listen to for authentication requests + # Do not uncomment this option unless you are an experienced user! + #option uamport 3990 + + # Comma separated list of domain names, IP addresses or network segments + # the client can access without first authenticating. + # It is possible to specify this option multiple times. + # Normally you do not need to uncomment this option. + #option uamallowed www.chillispot.org,10.11.12.0/24 + + # Comma separated list of domain names + # the client can access without first authenticating. + # It is possible to specify this option multiple times. + # Normally you do not need to uncomment this option. + #option uamdomain .chillispot.org,.coova.org + + # If this flag is given unauthenticated users are allowed to use + # any DNS server. + # Normally you do not need to uncomment this option. + #option uamanydns + + + # MAC authentication + + # If this flag is given users will be authenticated only on their MAC + # address. + # Normally you do not need to uncomment this option. + #option macauth + + # List of MAC addresses. + # The MAC addresses specified in this list will be authenticated only on + # their MAC address. + # this option is ignored if the macauth tag is given. + # It is possible to specify this option multiple times. + # Normally you do not need to uncomment this option. + #option macallowed 00-0A-5E-AC-BE-51,00-30-1B-3C-32-E9 + + # Password to use for MAC authentication. + # Normally you do not need to uncomment this option. + #option macpasswd password + + # Suffix to add to MAC address in order to form the username. + # Normally you do not need to uncomment this option. + #option macsuffix suffix + diff --git a/net/coova-chilli/files/chilli.firewall b/net/coova-chilli/files/chilli.firewall new file mode 100644 index 000000000..a5b1d001e --- /dev/null +++ b/net/coova-chilli/files/chilli.firewall @@ -0,0 +1,41 @@ +#!/bin/sh + +chilli_firewall() { + local cfg="$1" + + local network ifname tun + + config_get network "$cfg" network + + . /lib/functions/network.sh + network_get_device ifname ${network:-lan} + + if [ "$ifname" = "" ] + then + config_get ifname "$cfg" dhcpif + fi + + config_get tun "$cfg" tundev + + for n in ACCEPT DROP REJECT + do + iptables -F zone_${network}_${n} + iptables -I zone_${network}_${n} -i $tun -j $n + iptables -I zone_${network}_${n} -o $tun -j $n + done + + iptables -D forward -i ${ifname} -j zone_${network}_forward + iptables -A forward -i ${ifname} -j DROP + iptables -A forward -i $tun -j zone_${network}_forward + + iptables -D input -i ${ifname} -j zone_${network} + iptables -A input -i $tun -j zone_${network} + + iptables -I zone_${network} -p tcp --dport 3990 -j ACCEPT + iptables -I zone_${network} -p tcp --dport 3991 -j ACCEPT +} + +chilli_post_core_cb() { + config_load chilli + config_foreach chilli_firewall chilli +} diff --git a/net/coova-chilli/files/chilli.init b/net/coova-chilli/files/chilli.init new file mode 100644 index 000000000..15b79af37 --- /dev/null +++ b/net/coova-chilli/files/chilli.init @@ -0,0 +1,61 @@ +#!/bin/sh /etc/rc.common + +START=30 +STOP=90 + +config_cb() { + chilli_inst=$2 + if [ "$chilli_inst" != "" ] + then + rm -f /var/run/chilli_${chilli_inst}* + chilli_conf=/var/run/chilli_${chilli_inst}.conf + eval "start_chilli_$chilli_inst=1" + fi +} + +option_cb() { + case "$1" in + # UCI settings + network) + . /lib/functions/network.sh + local ifname + network_get_device ifname $2 + echo "dhcpif=\"$ifname\"" >> $chilli_conf + ;; + disabled) + eval "start_chilli_$chilli_inst=0" + ;; + # boolean settings + dhcpbroadcast|nodynip|vlanlocation|locationstopstart|locationcopycalled|locationimmediateupdate|locationopt82|coanoipcheck|noradallow|proxymacaccept|proxyonacct|dhcpmacset|dhcpradius|noc2c|eapolenable|uamanydns|uamanyip|uamnatanyip|nouamsuccess|nowispr1|nowispr2|domaindnslocal|radsec|macauth|macreauth|macauthdeny|macallowlocal|strictmacauth|strictdhcp|ieee8021q|only8021q|radiusoriginalurl|swapoctets|statusfilesave|wpaguests|openidauth|papalwaysok|mschapv2|chillixml|acctupdate|dnsparanoia|seskeepalive|usetap|noarpentries|framedservice|scalewin|redir|injectwispr|redirurl|routeonetone|nousergardendata|uamgardendata|uamotherdata|withunixipc|uamallowpost|redirssl|uamuissl|layer3|patricia|redirdnsreq|dhcpnotidle|ipv6|ipv6only) + [ "$2" = "true" -o "$2" = "1" ] && echo "$1" >> $chilli_conf + ;; + *) + echo "$1=\"$2\"" >> $chilli_conf + ;; + esac +} + +start_chilli() { + local cfg="$1" + local start_chilli=$(eval "echo \$start_chilli_$cfg") + [ "$start_chilli" = "0" ] && return + local base=/var/run/chilli_${cfg} + chilli -c ${base}.conf \ + --pidfile ${base}.pid \ + --cmdsocket ${base}.sock \ + --unixipc ${base}.ipc & +} + +start() { + config_load chilli + config_foreach start_chilli chilli +} + +stop() { + ls /var/run/chilli*.pid 2>/dev/null && { + kill $(cat /var/run/chilli*.pid) + sleep 1 + killall -9 chilli + rm -f /var/run/chilli* + } +} diff --git a/net/coova-chilli/patches/200-fix_compile_kmod.patch b/net/coova-chilli/patches/200-fix_compile_kmod.patch new file mode 100644 index 000000000..27225786e --- /dev/null +++ b/net/coova-chilli/patches/200-fix_compile_kmod.patch @@ -0,0 +1,17 @@ +--- a/src/linux/Makefile ++++ b/src/linux/Makefile +@@ -21,11 +21,11 @@ lib%.so: lib%.o + $(CC) $(CFLAGS) -shared -o $@ $^; + + lib%.o: lib%.c +- $(CC) $(CFLAGS) -fPIC -O2 -Wall -I${KERNEL_DIR}/include -D_INIT=lib$*_init -c -o $@ $<; ++ $(CC) $(CFLAGS) -D_INIT=lib$*_init -c -o $@ $<; + + install: modules_install libxt_coova.so +- mkdir -p $(DESTDIR)/lib/xtables/ +- cp libxt_coova.so $(DESTDIR)/lib/xtables/ ++ mkdir -p $(DESTDIR)/usr/lib/iptables/ ++ cp libxt_coova.so $(DESTDIR)/usr/lib/iptables/ + + distdir: + diff --git a/net/coova-chilli/patches/201-fix_dereferencing_pointers.patch b/net/coova-chilli/patches/201-fix_dereferencing_pointers.patch new file mode 100644 index 000000000..d608835a4 --- /dev/null +++ b/net/coova-chilli/patches/201-fix_dereferencing_pointers.patch @@ -0,0 +1,49 @@ +--- a/src/linux/xt_coova.c ++++ b/src/linux/xt_coova.c +@@ -292,6 +292,8 @@ static int coova_mt_check(const struct x + struct coova_table *t; + #ifdef CONFIG_PROC_FS + struct proc_dir_entry *pde; ++ kuid_t uid; ++ kgid_t gid; + #endif + unsigned i; + int ret = 0; +@@ -330,8 +332,9 @@ static int coova_mt_check(const struct x + ret = -ENOMEM; + goto out; + } +- pde->uid = ip_list_uid; +- pde->gid = ip_list_gid; ++ uid = make_kuid(&init_user_ns, ip_list_uid); ++ gid = make_kgid(&init_user_ns, ip_list_gid); ++ proc_set_user(pde, uid, gid); + #endif + spin_lock_bh(&coova_lock); + list_add_tail(&t->list, &tables); +@@ -445,14 +448,13 @@ static const struct seq_operations coova + + static int coova_seq_open(struct inode *inode, struct file *file) + { +- struct proc_dir_entry *pde = PDE(inode); + struct coova_iter_state *st; + + st = __seq_open_private(file, &coova_seq_ops, sizeof(*st)); + if (st == NULL) + return -ENOMEM; + +- st->table = pde->data; ++ st->table = PDE_DATA(inode); + return 0; + } + +@@ -460,8 +462,7 @@ static ssize_t + coova_mt_proc_write(struct file *file, const char __user *input, + size_t size, loff_t *loff) + { +- const struct proc_dir_entry *pde = PDE(file->f_path.dentry->d_inode); +- struct coova_table *t = pde->data; ++ struct coova_table *t = PDE_DATA(file->f_path.dentry->d_inode); + struct coova_entry *e; + char buf[sizeof("+b335:1d35:1e55:dead:c0de:1715:5afe:c0de")]; + const char *c = buf; diff --git a/net/coova-chilli/patches/300-fix-compile-with-cyassl.patch b/net/coova-chilli/patches/300-fix-compile-with-cyassl.patch new file mode 100644 index 000000000..3b61d49ca --- /dev/null +++ b/net/coova-chilli/patches/300-fix-compile-with-cyassl.patch @@ -0,0 +1,28 @@ +--- a/src/md5.h ++++ b/src/md5.h +@@ -28,6 +28,14 @@ + #define MD5Update MD5_Update + #define MD5Final MD5_Final + ++#elif HAVE_CYASSL ++#include ++ ++#define MD5Init MD5_Init ++#define MD5Update MD5_Update ++#define MD5Final MD5_Final ++ ++typedef struct CYASSL_MD5_CTX MD5_CTX; + #else + + struct MD5Context { +--- a/src/md5.c ++++ b/src/md5.c +@@ -18,7 +18,7 @@ + #include /* for memcpy() */ + #include "md5.h" + +-#ifndef HAVE_OPENSSL ++#if !defined(HAVE_OPENSSL) && !defined(HAVE_CYASSL) + + void byteReverse(unsigned char *buf, size_t longs); + diff --git a/net/cshark/Makefile b/net/cshark/Makefile index 15cc1203e..cbfbed5fa 100644 --- a/net/cshark/Makefile +++ b/net/cshark/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=cshark -PKG_VERSION:=2014-07-02 +PKG_VERSION:=2015-03-13 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/cloudshark/cshark.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=ec638311b0b8ef74baf0be06dcf03a641e3308a2 +PKG_SOURCE_VERSION:=ab2ae2fbd72b6cbd57c95e3192edc3c1f475412b PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_BUILD_PARALLEL:=1 diff --git a/net/ddns-scripts/Makefile b/net/ddns-scripts/Makefile old mode 100644 new mode 100755 index 7c834c2ab..1ca475661 --- a/net/ddns-scripts/Makefile +++ b/net/ddns-scripts/Makefile @@ -1,19 +1,27 @@ +# +# Copyright (C) 2008-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# + include $(TOPDIR)/rules.mk PKG_NAME:=ddns-scripts # Version == major.minor.patch # increase on new functionality (minor) or patches (patch) -PKG_VERSION:=2.3.0 +PKG_VERSION:=2.4.3 # Release == build # increase on changes of services files or tld_names.dat PKG_RELEASE:=1 PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=Christian Schoenebeck -PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) include $(INCLUDE_DIR)/package.mk +# no default dependencies +PKG_DEFAULT_DEPENDS= + define Package/$(PKG_NAME)/Default SECTION:=net CATEGORY:=Network @@ -21,6 +29,7 @@ define Package/$(PKG_NAME)/Default PKGARCH:=all endef +##### ********************************** define Package/$(PKG_NAME) $(call Package/$(PKG_NAME)/Default) TITLE:=Dynamic DNS Client scripts (with IPv6 support) @@ -41,31 +50,53 @@ define Package/$(PKG_NAME)/config - Proxy server support - log file support - support to run once - + . Version: $(PKG_VERSION)-$(PKG_RELEASE) Info : http://wiki.openwrt.org/doc/howto/ddns.client - + . $(PKG_MAINTAINER) endef -define Package/$(PKG_NAME)_CloudFlare +##### ********************************** +define Package/$(PKG_NAME)_cloudflare $(call Package/$(PKG_NAME)/Default) TITLE:=DDNS extension for CloudFlare DEPENDS:=$(PKG_NAME) endef -define Package/$(PKG_NAME)_CloudFlare/description +define Package/$(PKG_NAME)_cloudflare/description Dynamic DNS Client scripts extension for CloudFlare endef -define Package/$(PKG_NAME)_No-IP_com +##### ********************************** +define Package/$(PKG_NAME)_no-ip_com $(call Package/$(PKG_NAME)/Default) TITLE:=DDNS extension for No-IP.com DEPENDS:=$(PKG_NAME) endef -define Package/$(PKG_NAME)_No-IP_com/description +define Package/$(PKG_NAME)_no-ip_com/description Dynamic DNS Client scripts extension for No-IP.com endef +##### ********************************** +define Package/$(PKG_NAME)_nsupdate + $(call Package/$(PKG_NAME)/Default) + TITLE:=DDNS extension using Bind nsupdate + DEPENDS:=$(PKG_NAME) +bind-client +endef +define Package/$(PKG_NAME)_nsupdate/description + Dynamic DNS Client scripts extension for direct updates using Bind nsupdate +endef +define Package/$(PKG_NAME)_nsupdate/config + help + The script directly updates a PowerDNS (or maybe bind server) via nsupdate + from bind-client package. It requires + "option dns_server" to be set to the server to be used by nsupdate. + "option username" should be set to the key name and + "option password" to the base64 encoded shared secret. + +endef + +##### ********************************** define Build/Configure endef define Build/Compile @@ -78,12 +109,14 @@ define Build/Compile -e '/^\/\/\s/d' \ -e '/^\s*$$$$/d' $$$$FILE; \ done + gzip -f9 $(PKG_BUILD_DIR)/files/tld_names.dat endef define Package/$(PKG_NAME)/conffiles /etc/config/ddns endef +##### ********************************** define Package/$(PKG_NAME)/install $(INSTALL_DIR) $(1)/etc/hotplug.d/iface $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/ddns.hotplug $(1)/etc/hotplug.d/iface/95-ddns @@ -96,16 +129,6 @@ define Package/$(PKG_NAME)/install $(INSTALL_DATA) $(PKG_BUILD_DIR)/files/services* $(1)/usr/lib/ddns $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/dynamic_*.sh $(1)/usr/lib/ddns endef -define Package/$(PKG_NAME)_CloudFlare/install - $(INSTALL_DIR) $(1)/usr/lib/ddns - $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/update_CloudFlare.sh $(1)/usr/lib/ddns - $(INSTALL_DATA) $(PKG_BUILD_DIR)/files/tld_names.dat $(1)/usr/lib/ddns -endef -define Package/$(PKG_NAME)_No-IP_com/install - $(INSTALL_DIR) $(1)/usr/lib/ddns - $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/update_No-IP.com.sh $(1)/usr/lib/ddns -endef - define Package/$(PKG_NAME)/postinst #!/bin/sh # if run within buildroot exit @@ -123,17 +146,6 @@ define Package/$(PKG_NAME)/postinst exit 0 endef -define Package/$(PKG_NAME)_CloudFlare/postinst - #!/bin/sh - echo -e '"CloudFlare"\t"update_CloudFlare.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services - echo -e '"CloudFlare"\t"update_CloudFlare.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services_ipv6 -endef -define Package/$(PKG_NAME)_No-IP_com/postinst - #!/bin/sh - echo -e '"No-IP.com"\t"update_No-IP.com.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services - echo -e '"NoIP.com"\t"update_No-IP.com.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services -endef - define Package/$(PKG_NAME)/prerm #!/bin/sh # if run within buildroot exit @@ -148,16 +160,57 @@ define Package/$(PKG_NAME)/prerm exit 0 endef -define Package/$(PKG_NAME)_CloudFlare/prerm + +##### ********************************** +define Package/$(PKG_NAME)_cloudflare/install + $(INSTALL_DIR) $(1)/usr/lib/ddns + $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/update_CloudFlare.sh $(1)/usr/lib/ddns + $(INSTALL_DATA) $(PKG_BUILD_DIR)/files/tld_names.dat.gz $(1)/usr/lib/ddns +endef +define Package/$(PKG_NAME)_cloudflare/postinst + #!/bin/sh + echo -e '"CloudFlare"\t"update_CloudFlare.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services + echo -e '"CloudFlare"\t"update_CloudFlare.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services_ipv6 +endef +define Package/$(PKG_NAME)_cloudflare/prerm #!/bin/sh /bin/sed -i '/update_CloudFlare\.sh/ d' $${IPKG_INSTROOT}/usr/lib/ddns/services /bin/sed -i '/update_CloudFlare\.sh/ d' $${IPKG_INSTROOT}/usr/lib/ddns/services_ipv6 endef -define Package/$(PKG_NAME)_No-IP_com/prerm + +##### ********************************** +define Package/$(PKG_NAME)_no-ip_com/install + $(INSTALL_DIR) $(1)/usr/lib/ddns + $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/update_No-IP.com.sh $(1)/usr/lib/ddns +endef +define Package/$(PKG_NAME)_no-ip_com/postinst + #!/bin/sh + echo -e '"No-IP.com"\t"update_No-IP.com.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services + echo -e '"NoIP.com"\t"update_No-IP.com.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services +endef +define Package/$(PKG_NAME)_no-ip_com/prerm #!/bin/sh /bin/sed -i '/update_No-IP\.com\.sh/ d' $${IPKG_INSTROOT}/usr/lib/ddns/services endef +##### ********************************** +define Package/$(PKG_NAME)_nsupdate/install + $(INSTALL_DIR) $(1)/usr/lib/ddns + $(INSTALL_BIN) $(PKG_BUILD_DIR)/files/update_nsupdate.sh $(1)/usr/lib/ddns +endef +define Package/$(PKG_NAME)_nsupdate/postinst + #!/bin/sh + echo -e '"Bind-nsupdate"\t"update_nsupdate.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services + echo -e '"Bind-nsupdate"\t"update_nsupdate.sh"' >> $${IPKG_INSTROOT}/usr/lib/ddns/services_ipv6 +endef +define Package/$(PKG_NAME)_nsupdate/prerm + #!/bin/sh + /bin/sed -i '/update_nsupdate\.sh/ d' $${IPKG_INSTROOT}/usr/lib/ddns/services + /bin/sed -i '/update_nsupdate\.sh/ d' $${IPKG_INSTROOT}/usr/lib/ddns/services_ipv6 +endef + +##### ********************************** $(eval $(call BuildPackage,$(PKG_NAME))) -$(eval $(call BuildPackage,$(PKG_NAME)_CloudFlare)) -$(eval $(call BuildPackage,$(PKG_NAME)_No-IP_com)) +$(eval $(call BuildPackage,$(PKG_NAME)_cloudflare)) +$(eval $(call BuildPackage,$(PKG_NAME)_no-ip_com)) +$(eval $(call BuildPackage,$(PKG_NAME)_nsupdate)) diff --git a/net/ddns-scripts/files/ddns.config b/net/ddns-scripts/files/ddns.config index 57b5477f8..5d69bb17c 100644 --- a/net/ddns-scripts/files/ddns.config +++ b/net/ddns-scripts/files/ddns.config @@ -11,7 +11,7 @@ config ddns "global" config service "myddns_ipv4" - option service_name "example.org" + option service_name "dyndns.com" option domain "yourhost.example.com" option username "your_username" option password "your_password" diff --git a/net/ddns-scripts/files/ddns.init b/net/ddns-scripts/files/ddns.init index 84abfd5e5..2cc9b90fa 100644 --- a/net/ddns-scripts/files/ddns.init +++ b/net/ddns-scripts/files/ddns.init @@ -24,4 +24,5 @@ start() { stop() { killall dynamic_dns_updater.sh 2>/dev/null + return 0 # if killall fails, ignore } diff --git a/net/ddns-scripts/files/dynamic_dns_functions.sh b/net/ddns-scripts/files/dynamic_dns_functions.sh old mode 100644 new mode 100755 index 9bd2f818b..cb0db9ac3 --- a/net/ddns-scripts/files/dynamic_dns_functions.sh +++ b/net/ddns-scripts/files/dynamic_dns_functions.sh @@ -37,7 +37,7 @@ PIDFILE="" # pid file UPDFILE="" # store UPTIME of last update DATFILE="" # save stdout data of WGet and other external programs called ERRFILE="" # save stderr output of WGet and other external programs called -TLDFILE=/usr/lib/ddns/tld_names.dat # TLD file used by split_FQDN +TLDFILE=/usr/lib/ddns/tld_names.dat.gz # TLD file used by split_FQDN CHECK_SECONDS=0 # calculated seconds out of given FORCE_SECONDS=0 # interval and unit @@ -486,8 +486,8 @@ verify_host_port() { __IPV4=$(cat $DATFILE | awk -F "address " '/has address/ {print $2; exit}' ) __IPV6=$(cat $DATFILE | awk -F "address " '/has IPv6/ {print $2; exit}' ) else # use BusyBox nslookup - __IPV4=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($IPV4_REGEX\).*$/\\1/p }") - __IPV6=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($IPV6_REGEX\).*$/\\1/p }") + __IPV4=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($IPV4_REGEX\).*$/\\1/p }") + __IPV6=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($IPV6_REGEX\).*$/\\1/p }") fi } @@ -966,7 +966,7 @@ get_registered_ip() { if [ "$__PROG" = "BIND host" ]; then __DATA=$(cat $DATFILE | awk -F "address " '/has/ {print $2; exit}' ) else - __DATA=$(cat $DATFILE | sed -ne "3,\$ { s/^Address[0-9 ]\{0,\}: \($__REGEX\).*$/\\1/p }" ) + __DATA=$(cat $DATFILE | sed -ne "/^Name:/,\$ { s/^Address[0-9 ]\{0,\}: \($__REGEX\).*$/\\1/p }" ) fi [ -n "$__DATA" ] && { write_log 7 "Registered IP '$__DATA' detected" @@ -1058,43 +1058,63 @@ split_FQDN() { # $4 name of variable to store Host/Subdomain [ $# -ne 4 ] && write_log 12 "Error calling 'split_FQDN()' - wrong number of parameters" + [ -z "$1" ] && write_log 12 "Error calling 'split_FQDN()' - missing FQDN to split" + [ -f $TLDFILE ] || write_log 12 "Error calling 'split_FQDN()' - missing file '$TLDFILE'" - _SET="$@" # save given parameters - local _FHOST _FTLD _FOUND - local _FDOM=$(echo "$1" | tr [A-Z] [a-z]) # to lower + local _HOST _FDOM _CTLD _FTLD + local _SET="$@" # save given function parameters - set -- $(echo "$_FDOM" | tr "." " ") # replace DOT with SPACE and set as script parameters - _FDOM="" # clear variable for later reuse + local _PAR=$(echo "$1" | tr [A-Z] [a-z] | tr "." " ") # to lower and replace DOT with SPACE + set -- $_PAR # set new as function parameters + _PAR="" # clear variable for later reuse + while [ -n "$1" ] ; do # as long we have parameters + _PAR="$1 $_PAR" # invert order of parameters + shift + done + set -- $_PAR # use new as function parameters + _PAR="" # clear variable while [ -n "$1" ] ; do # as long we have parameters - _FTLD=$(echo $@ | tr " " ".") # build back dot separated as TLD - # look if match excludes "!" in tld_names.dat - grep -E "^!$_FTLD$" $TLDFILE >/dev/null 2>&1 || { - # Don't match excludes - # check if match any "*" in tld_names.dat - grep -E "^*.$_FTLD$" $TLDFILE >/dev/null 2>&1 && { - _FOUND="VALID" - break # found leave while - } - # check if exact match in tld_names.dat - grep -E "^$_FTLD$" $TLDFILE >/dev/null 2>&1 && { - _FOUND="VALID" - break # found leave while - } + if [ -z "$_CTLD" ]; then # first loop + _CTLD="$1" # CURRENT TLD to look at + shift + else + _CTLD="$1.$_CTLD" # Next TLD to look at + shift + fi + # check if TLD exact match in tld_names.dat, save TLD + zcat $TLDFILE | grep -E "^$_CTLD$" >/dev/null 2>&1 && { + _FTLD="$_CTLD" # save found + _FDOM="$1" # save domain next step might be invalid + continue } - # nothing match so - _FHOST="$_FHOST $_FDOM" # append DOMAIN to last found HOST - _FDOM="$1" # set 1st parameter as DOMAIN - _FTLD="" # clear TLD - shift # delete 1st parameter and retry with the rest + # check if match any "*" in tld_names.dat, + zcat $TLDFILE | grep -E "^\*.$_CTLD$" >/dev/null 2>&1 && { + [ -z "$1" ] && break # no more data break + # check if next level TLD match excludes "!" in tld_names.dat + if zcat $TLDFILE | grep -E "^!$1.$_CTLD$" >/dev/null 2>&1 ; then + _FTLD="$_CTLD" # Yes + else + _FTLD="$1.$_CTLD" + shift + fi + _FDOM="$1"; shift + } + [ -n "$_FTLD" ] && break # we have something valid, break + done + + # the leftover parameters are the HOST/SUBDOMAIN + while [ -n "$1" ]; do + _HOST="$1 $HOST" # remember we need to invert + shift done + _HOST=$(echo $_HOST | tr " " ".") # insert DOT set -- $_SET # set back parameters from function call - [ -n "$_FHOST" ] && _FHOST=$(echo $_FHOST | tr " " ".") # put dots back into HOST - [ -n "$_FOUND" ] && { - eval "$2=$_FTLD" # set found TLD - eval "$3=$_FDOM" # set found registrable domain - eval "$4=$_FHOST" # set found HOST/SUBDOMAIN + [ -n "$_FTLD" ] && { + eval "$2=$_FTLD" # set TLD + eval "$3=$_FDOM" # set registrable domain + eval "$4=$_HOST" # set HOST/SUBDOMAIN return 0 } eval "$2=''" # clear TLD diff --git a/net/ddns-scripts/files/dynamic_dns_lucihelper.sh b/net/ddns-scripts/files/dynamic_dns_lucihelper.sh index cc22d25e6..0f8bb5aa8 100755 --- a/net/ddns-scripts/files/dynamic_dns_lucihelper.sh +++ b/net/ddns-scripts/files/dynamic_dns_lucihelper.sh @@ -22,8 +22,8 @@ # preset some variables, wrong or not set in dynamic_dns_functions.sh SECTION_ID="lucihelper" LOGFILE="$LOGDIR/$SECTION_ID.log" -DATFILE="$RUNDIR/$SECTION_ID.dat" # save stdout data of WGet and other extern programs called -ERRFILE="$RUNDIR/$SECTION_ID.err" # save stderr output of WGet and other extern programs called +DATFILE="$RUNDIR/$SECTION_ID.$$.dat" # save stdout data of WGet and other extern programs called +ERRFILE="$RUNDIR/$SECTION_ID.$$.err" # save stderr output of WGet and other extern programs called VERBOSE_MODE=0 # no console logging # global variables normally set by reading DDNS UCI configuration use_syslog=0 # no syslog diff --git a/net/ddns-scripts/files/dynamic_dns_updater.sh b/net/ddns-scripts/files/dynamic_dns_updater.sh index a0143a73c..95d2c9408 100644 --- a/net/ddns-scripts/files/dynamic_dns_updater.sh +++ b/net/ddns-scripts/files/dynamic_dns_updater.sh @@ -120,7 +120,7 @@ ERR_LAST=$? # save return code - equal 0 if SECTION_ID found # set defaults if not defined [ -z "$enabled" ] && enabled=0 -[ -z "$retry_count" ] && retry_count=5 +[ -z "$retry_count" ] && retry_count=0 # endless retry [ -z "$use_syslog" ] && use_syslog=2 # syslog "Notice" [ -z "$use_https" ] && use_https=0 # not use https [ -z "$use_logfile" ] && use_logfile=1 # use logfile by default diff --git a/net/ddns-scripts/files/services_ipv6 b/net/ddns-scripts/files/services_ipv6 index 88831e9e7..a0781a24f 100644 --- a/net/ddns-scripts/files/services_ipv6 +++ b/net/ddns-scripts/files/services_ipv6 @@ -38,3 +38,6 @@ # IPv6 @ freedns.afraid.org "freedns.afraid.org" "http://freedns.afraid.org/dynamic/update.php?[PASSWORD]&address=[IP]" + +# IPv6 @ LoopiaDNS +"loopia.se" "http://[USERNAME]:[PASSWORD]@dns.loopia.se/XDynDNSServer/XDynDNS.php?system=custom&hostname=[DOMAIN]&myip=[IP]" diff --git a/net/ddns-scripts/files/tld_names.dat b/net/ddns-scripts/files/tld_names.dat index 7e1959f42..1d848b41b 100644 --- a/net/ddns-scripts/files/tld_names.dat +++ b/net/ddns-scripts/files/tld_names.dat @@ -830,6 +830,7 @@ edu.et biz.et name.et info.et +net.et // eu : http://en.wikipedia.org/wiki/.eu eu @@ -936,6 +937,11 @@ org.gi // gl : http://en.wikipedia.org/wiki/.gl // http://nic.gl gl +co.gl +com.gl +edu.gl +net.gl +org.gl // gm : http://www.nic.gm/htmlpages%5Cgm-policy.htm gm @@ -3639,6 +3645,7 @@ ltd.lk assn.lk grp.lk hotel.lk +ac.lk // lr : http://psg.com/dns/lr/lr.txt // Submitted by registry 2008-06-17 @@ -4485,9 +4492,9 @@ mobi.ng // ni : http://www.nic.ni/dominios.htm *.ni -// nl : http://www.domain-registry.nl/ace.php/c,728,122,,,,Home.html -// Confirmed by registry (with technical -// reservations) 2008-06-08 +// nl : http://en.wikipedia.org/wiki/.nl +// https://www.sidn.nl/ +// ccTLD for the Netherlands nl // BV.nl will be a registry for dutch BV's (besloten vennootschap) @@ -5551,14 +5558,11 @@ gos.pk info.pk // pl http://www.dns.pl/english/index.html -// confirmed on 26.09.2014 from Bogna Tchórzewska +// updated by .PL registry on 2015-04-28 pl com.pl net.pl org.pl -info.pl -waw.pl -gov.pl // pl functional domains (http://www.dns.pl/english/index.html) aid.pl agro.pl @@ -5568,6 +5572,7 @@ biz.pl edu.pl gmina.pl gsm.pl +info.pl mail.pl miasta.pl media.pl @@ -5589,16 +5594,55 @@ tm.pl tourism.pl travel.pl turystyka.pl -// Government domains (administred by ippt.gov.pl) -uw.gov.pl -um.gov.pl +// Government domains +gov.pl +ap.gov.pl +ic.gov.pl +is.gov.pl +us.gov.pl +kmpsp.gov.pl +kppsp.gov.pl +kwpsp.gov.pl +psp.gov.pl +wskr.gov.pl +kwp.gov.pl +mw.gov.pl ug.gov.pl +um.gov.pl +umig.gov.pl +ugim.gov.pl upow.gov.pl +uw.gov.pl starostwo.gov.pl +pa.gov.pl +po.gov.pl +psse.gov.pl +pup.gov.pl +rzgw.gov.pl +sa.gov.pl so.gov.pl sr.gov.pl -po.gov.pl -pa.gov.pl +wsa.gov.pl +sko.gov.pl +uzs.gov.pl +wiih.gov.pl +winb.gov.pl +pinb.gov.pl +wios.gov.pl +witd.gov.pl +wzmiuw.gov.pl +piw.gov.pl +wiw.gov.pl +griw.gov.pl +wif.gov.pl +oum.gov.pl +sdn.gov.pl +zp.gov.pl +uppo.gov.pl +mup.gov.pl +wuoz.gov.pl +konsulat.gov.pl +oirm.gov.pl // pl regional domains (http://www.dns.pl/english/index.html) augustow.pl babia-gora.pl @@ -5706,6 +5750,7 @@ ustka.pl walbrzych.pl warmia.pl warszawa.pl +waw.pl wegrow.pl wielun.pl wlocl.pl @@ -6153,6 +6198,38 @@ store.st // su : http://en.wikipedia.org/wiki/.su su +adygeya.su +arkhangelsk.su +balashov.su +bashkiria.su +bryansk.su +dagestan.su +grozny.su +ivanovo.su +kalmykia.su +kaluga.su +karelia.su +khakassia.su +krasnodar.su +kurgan.su +lenug.su +mordovia.su +msk.su +murmansk.su +nalchik.su +nov.su +obninsk.su +penza.su +pokrovsk.su +sochi.su +spb.su +togliatti.su +troitsk.su +tula.su +tuva.su +vladikavkaz.su +vladimir.su +vologda.su // sv : http://www.svnet.org.sv/niveldos.pdf sv @@ -6839,141 +6916,183 @@ edu.ws yt // IDN ccTLDs -// Please sort by ISO 3166 ccTLD, then punicode string -// when submitting patches and follow this format: -// ("" ) : -// [optional sponsoring org] -// +// When submitting patches, please maintain a sort by ISO 3166 ccTLD, then +// U-label, and follow this format: +// // A-Label ("", [, variant info]) : +// // [sponsoring org] +// U-Label -// xn--mgbaam7a8h ("Emerat" Arabic) : AE +// xn--mgbaam7a8h ("Emerat", Arabic) : AE // http://nic.ae/english/arabicdomain/rules.jsp امارات xn--mgbaam7a8h -// xn--54b7fta0cc ("Bangla" Bangla) : BD +// xn--y9a3aq ("hye", Armenian) : AM +// ISOC AM (operated by .am Registry) +հայ +xn--y9a3aq + +// xn--54b7fta0cc ("Bangla", Bangla) : BD বাংলা xn--54b7fta0cc -// xn--fiqs8s ("China" Chinese-Han-Simplified <.Zhongguo>) : CN +// xn--90ais ("bel", Belarusian/Russian Cyrillic) : BY +// Operated by .by registry +бел +xn--90ais + +// xn--fiqs8s ("Zhongguo/China", Chinese, Simplified) : CN // CNNIC // http://cnnic.cn/html/Dir/2005/10/11/3218.htm 中国 xn--fiqs8s -// xn--fiqz9s ("China" Chinese-Han-Traditional <.Zhongguo>) : CN +// xn--fiqz9s ("Zhongguo/China", Chinese, Traditional) : CN // CNNIC // http://cnnic.cn/html/Dir/2005/10/11/3218.htm 中國 xn--fiqz9s -// xn--lgbbat1ad8j ("Algeria / Al Jazair" Arabic) : DZ +// xn--lgbbat1ad8j ("Algeria/Al Jazair", Arabic) : DZ الجزائر xn--lgbbat1ad8j -// xn--wgbh1c ("Egypt" Arabic .masr) : EG +// xn--wgbh1c ("Egypt/Masr", Arabic) : EG // http://www.dotmasr.eg/ مصر xn--wgbh1c -// xn--node ("ge" Georgian (Mkhedruli)) : GE +// xn--node ("ge", Georgian Mkhedruli) : GE გე xn--node -// xn--j6w193g ("Hong Kong" Chinese-Han) : HK +// xn--qxam ("el", Greek) : GR +// Hellenic Ministry of Infrastructure, Transport, and Networks +ελ +xn--qxam + +// xn--j6w193g ("Hong Kong", Chinese) : HK // https://www2.hkirc.hk/register/rules.jsp 香港 xn--j6w193g -// xn--h2brj9c ("Bharat" Devanagari) : IN +// xn--h2brj9c ("Bharat", Devanagari) : IN // India भारत xn--h2brj9c -// xn--mgbbh1a71e ("Bharat" Arabic) : IN +// xn--mgbbh1a71e ("Bharat", Arabic) : IN // India بھارت xn--mgbbh1a71e -// xn--fpcrj9c3d ("Bharat" Telugu) : IN +// xn--fpcrj9c3d ("Bharat", Telugu) : IN // India భారత్ xn--fpcrj9c3d -// xn--gecrj9c ("Bharat" Gujarati) : IN +// xn--gecrj9c ("Bharat", Gujarati) : IN // India ભારત xn--gecrj9c -// xn--s9brj9c ("Bharat" Gurmukhi) : IN +// xn--s9brj9c ("Bharat", Gurmukhi) : IN // India ਭਾਰਤ xn--s9brj9c -// xn--45brj9c ("Bharat" Bengali) : IN +// xn--45brj9c ("Bharat", Bengali) : IN // India ভারত xn--45brj9c -// xn--xkc2dl3a5ee0h ("India" Tamil) : IN +// xn--xkc2dl3a5ee0h ("India", Tamil) : IN // India இந்தியா xn--xkc2dl3a5ee0h -// xn--mgba3a4f16a ("Iran" Persian) : IR +// xn--mgba3a4f16a ("Iran", Persian) : IR ایران xn--mgba3a4f16a -// xn--mgba3a4fra ("Iran" Arabic) : IR +// xn--mgba3a4fra ("Iran", Arabic) : IR ايران xn--mgba3a4fra -// xn--mgbayh7gpa ("al-Ordon" Arabic) : JO +// xn--mgbtx2b ("Iraq", Arabic) : IQ +// Communications and Media Commission +عراق +xn--mgbtx2b + +// xn--mgbayh7gpa ("al-Ordon", Arabic) : JO // National Information Technology Center (NITC) // Royal Scientific Society, Al-Jubeiha الاردن xn--mgbayh7gpa -// xn--3e0b707e ("Republic of Korea" Hangul) : KR +// xn--3e0b707e ("Republic of Korea", Hangul) : KR 한국 xn--3e0b707e -// xn--80ao21a ("Kaz" Kazakh) : KZ +// xn--80ao21a ("Kaz", Kazakh) : KZ қаз xn--80ao21a -// xn--fzc2c9e2c ("Lanka" Sinhalese-Sinhala) : LK +// xn--fzc2c9e2c ("Lanka", Sinhalese-Sinhala) : LK // http://nic.lk ලංකා xn--fzc2c9e2c -// xn--xkc2al3hye2a ("Ilangai" Tamil) : LK +// xn--xkc2al3hye2a ("Ilangai", Tamil) : LK // http://nic.lk இலங்கை xn--xkc2al3hye2a -// xn--mgbc0a9azcg ("Morocco / al-Maghrib" Arabic) : MA +// xn--mgbc0a9azcg ("Morocco/al-Maghrib", Arabic) : MA المغرب xn--mgbc0a9azcg -// xn--l1acc ("mon" Mongolian) : MN +// xn--d1alf ("mkd", Macedonian) : MK +// MARnet +мкд +xn--d1alf + +// xn--l1acc ("mon", Mongolian) : MN мон xn--l1acc -// xn--mgbx4cd0ab ("Malaysia" Malay) : MY +// xn--mix891f ("Macao", Chinese, Traditional) : MO +// MONIC / HNET Asia (Registry Operator for .mo) +澳門 +xn--mix891f + +// xn--mix082f ("Macao", Chinese, Simplified) : MO +澳门 +xn--mix082f + +// xn--mgbx4cd0ab ("Malaysia", Malay) : MY مليسيا xn--mgbx4cd0ab -// xn--mgb9awbf ("Oman" Arabic) : OM +// xn--mgb9awbf ("Oman", Arabic) : OM عمان xn--mgb9awbf -// xn--ygbi2ammx ("Falasteen" Arabic) : PS +// xn--mgbai9azgqp6j ("Pakistan", Urdu/Arabic) : PK +پاکستان +xn--mgbai9azgqp6j + +// xn--mgbai9a5eva00b ("Pakistan", Urdu/Arabic, variant) : PK +پاكستان +xn--mgbai9a5eva00b + +// xn--ygbi2ammx ("Falasteen", Arabic) : PS // The Palestinian National Internet Naming Authority (PNINA) // http://www.pnina.ps فلسطين xn--ygbi2ammx -// xn--90a3ac ("srb" Cyrillic) : RS +// xn--90a3ac ("srb", Cyrillic) : RS // http://www.rnids.rs/en/the-.срб-domain срб xn--90a3ac @@ -6990,78 +7109,83 @@ xn--o1ach.xn--90a3ac ак.срб xn--80au.xn--90a3ac -// xn--p1ai ("rf" Russian-Cyrillic) : RU +// xn--p1ai ("rf", Russian-Cyrillic) : RU // http://www.cctld.ru/en/docs/rulesrf.php рф xn--p1ai -// xn--wgbl6a ("Qatar" Arabic) : QA +// xn--wgbl6a ("Qatar", Arabic) : QA // http://www.ict.gov.qa/ قطر xn--wgbl6a -// xn--mgberp4a5d4ar ("AlSaudiah" Arabic) : SA +// xn--mgberp4a5d4ar ("AlSaudiah", Arabic) : SA // http://www.nic.net.sa/ السعودية xn--mgberp4a5d4ar -// xn--mgberp4a5d4a87g ("AlSaudiah" Arabic) variant : SA +// xn--mgberp4a5d4a87g ("AlSaudiah", Arabic, variant) : SA السعودیة xn--mgberp4a5d4a87g -// xn--mgbqly7c0a67fbc ("AlSaudiah" Arabic) variant : SA +// xn--mgbqly7c0a67fbc ("AlSaudiah", Arabic, variant) : SA السعودیۃ xn--mgbqly7c0a67fbc -// xn--mgbqly7cvafr ("AlSaudiah" Arabic) variant : SA +// xn--mgbqly7cvafr ("AlSaudiah", Arabic, variant) : SA السعوديه xn--mgbqly7cvafr -// xn--ogbpf8fl ("Syria" Arabic) : SY -سورية -xn--ogbpf8fl - -// xn--mgbtf8fl ("Syria" Arabic) variant : SY -سوريا -xn--mgbtf8fl +// xn--mgbpl2fh ("sudan", Arabic) : SD +// Operated by .sd registry +سودان +xn--mgbpl2fh -// xn--yfro4i67o Singapore ("Singapore" Chinese-Han) : SG +// xn--yfro4i67o Singapore ("Singapore", Chinese) : SG 新加坡 xn--yfro4i67o -// xn--clchc0ea0b2g2a9gcd ("Singapore" Tamil) : SG +// xn--clchc0ea0b2g2a9gcd ("Singapore", Tamil) : SG சிங்கப்பூர் xn--clchc0ea0b2g2a9gcd -// xn--o3cw4h ("Thai" Thai) : TH +// xn--ogbpf8fl ("Syria", Arabic) : SY +سورية +xn--ogbpf8fl + +// xn--mgbtf8fl ("Syria", Arabic, variant) : SY +سوريا +xn--mgbtf8fl + +// xn--o3cw4h ("Thai", Thai) : TH // http://www.thnic.co.th ไทย xn--o3cw4h -// xn--pgbs0dh ("Tunis") : TN +// xn--pgbs0dh ("Tunisia", Arabic) : TN // http://nic.tn تونس xn--pgbs0dh -// xn--kpry57d ("Taiwan" Chinese-Han-Traditional) : TW +// xn--kpry57d ("Taiwan", Chinese, Traditional) : TW // http://www.twnic.net/english/dn/dn_07a.htm 台灣 xn--kpry57d -// xn--kprw13d ("Taiwan" Chinese-Han-Simplified) : TW +// xn--kprw13d ("Taiwan", Chinese, Simplified) : TW // http://www.twnic.net/english/dn/dn_07a.htm 台湾 xn--kprw13d -// xn--nnx388a ("Taiwan") variant : TW +// xn--nnx388a ("Taiwan", Chinese, variant) : TW 臺灣 xn--nnx388a -// xn--j1amh ("ukr" Cyrillic) : UA +// xn--j1amh ("ukr", Cyrillic) : UA укр xn--j1amh -// xn--mgb2ddes ("AlYemen" Arabic) : YE +// xn--mgb2ddes ("AlYemen", Arabic) : YE اليمن xn--mgb2ddes @@ -7081,7 +7205,10 @@ xxx *.zw -// List of new gTLDs imported from https://newgtlds.icann.org/newgtlds.csv on 2015-01-27T00:02:07Z +// List of new gTLDs imported from https://newgtlds.icann.org/newgtlds.csv on 2015-05-06T09:31:08Z + +// aaa : 2015-02-26 American Automobile Association, Inc. +aaa // abb : 2014-10-24 ABB Ltd abb @@ -7119,12 +7246,21 @@ ads // adult : 2014-10-16 ICM Registry AD LLC adult +// aeg : 2015-03-19 Aktiebolaget Electrolux +aeg + // afl : 2014-10-02 Australian Football League afl // africa : 2014-03-24 ZA Central Registry NPC trading as Registry.Africa africa +// africamagic : 2015-03-05 Electronic Media Network (Pty) Ltd +africamagic + +// agakhan : 2015-04-23 Fondation Aga Khan (Aga Khan Foundation) +agakhan + // agency : 2013-11-14 Steel Falls, LLC agency @@ -7137,6 +7273,9 @@ airforce // airtel : 2014-10-24 Bharti Airtel Limited airtel +// akdn : 2015-04-23 Fondation Aga Khan (Aga Khan Foundation) +akdn + // alibaba : 2015-01-15 Alibaba Group Holding Limited alibaba @@ -7209,6 +7348,9 @@ axa // azure : 2014-12-18 Microsoft Corporation azure +// baby : 2015-04-09 Johnson & Johnson Services, Inc. +baby + // baidu : 2015-01-08 Baidu, Inc. baidu @@ -7245,6 +7387,9 @@ bbc // bbva : 2014-10-02 BANCO BILBAO VIZCAYA ARGENTARIA, S.A. bbva +// bcg : 2015-04-02 The Boston Consulting Group, Inc. +bcg + // bcn : 2014-07-24 Municipi de Barcelona bcn @@ -7338,6 +7483,9 @@ broadway // broker : 2014-12-11 IG Group Holdings PLC broker +// brother : 2015-01-29 Brother Industries, Ltd. +brother + // brussels : 2014-02-06 DNS.be vzw brussels @@ -7365,6 +7513,9 @@ bzh // cab : 2013-10-24 Half Sunset, LLC cab +// cafe : 2015-02-11 Pioneer Canyon, LLC +cafe + // cal : 2014-07-24 Charleston Road Registry Inc. cal @@ -7431,13 +7582,16 @@ cba // cbn : 2014-08-22 The Christian Broadcasting Network, Inc. cbn +// ceb : 2015-04-09 The Corporate Executive Board Company +ceb + // center : 2013-11-07 Tin Mill, LLC center // ceo : 2013-11-07 CEOTLD Pty Ltd ceo -// cern : 2014-06-05 European Organization for Nuclear Research ( +// cern : 2014-06-05 European Organization for Nuclear Research ("CERN") cern // cfa : 2014-08-28 CFA Institute @@ -7446,9 +7600,15 @@ cfa // cfd : 2014-12-11 IG Group Holdings PLC cfd +// chanel : 2015-04-09 Chanel International B.V. +chanel + // channel : 2014-05-08 Charleston Road Registry Inc. channel +// chase : 2015-04-30 JPMorgan Chase & Co. +chase + // chat : 2014-12-04 Sand Fields, LLC chat @@ -7464,9 +7624,12 @@ christmas // chrome : 2014-07-24 Charleston Road Registry Inc. chrome -// church : 2014-02-06 Holly Fileds, LLC +// church : 2014-02-06 Holly Fields, LLC church +// cipriani : 2015-02-19 Hotel Cipriani Srl +cipriani + // circle : 2014-12-18 Amazon EU S.à r.l. circle @@ -7497,6 +7660,9 @@ clinic // clothing : 2013-08-27 Steel Lake, LLC clothing +// cloud : 2015-04-16 ARUBA S.p.A. +cloud + // club : 2013-11-08 .CLUB DOMAINS, LLC club @@ -7557,6 +7723,12 @@ corsica // country : 2013-12-19 Top Level Domain Holdings Limited country +// coupon : 2015-02-26 Amazon EU S.à r.l. +coupon + +// coupons : 2015-03-26 Black Island, LLC +coupons + // courses : 2014-12-04 OPEN UNIVERSITIES AUSTRALIA PTY LTD courses @@ -7632,6 +7804,9 @@ delivery // dell : 2014-10-24 Dell Inc. dell +// delta : 2015-02-19 Delta Air Lines, Inc. +delta + // democrat : 2013-10-24 United TLD Holdco Ltd. democrat @@ -7689,6 +7864,12 @@ doosan // download : 2014-11-20 dot Support Limited download +// drive : 2015-03-05 Charleston Road Registry Inc. +drive + +// dstv : 2015-03-12 MultiChoice (Proprietary) Limited +dstv + // dubai : 2015-01-01 Dubai Smart Government Department dubai @@ -7764,6 +7945,9 @@ expert // exposed : 2013-12-05 Victor Beach, LLC exposed +// express : 2015-02-11 Sea Sunset, LLC +express + // fage : 2014-12-18 Fage International S.A. fage @@ -7776,6 +7960,9 @@ fairwinds // faith : 2014-11-20 dot Faith Limited faith +// family : 2015-04-02 Bitter Galley, LLC +family + // fan : 2014-03-06 fan @@ -7827,6 +8014,9 @@ fit // fitness : 2014-03-06 Brice Orchard, LLC fitness +// flickr : 2015-04-02 Yahoo! Domain Services Inc. +flickr + // flights : 2013-12-05 Fox Station, LLC flights @@ -7857,6 +8047,9 @@ forex // forsale : 2014-05-22 forsale +// forum : 2015-04-02 Fegistry, LLC +forum + // foundation : 2013-12-05 John Dale, LLC foundation @@ -7866,6 +8059,9 @@ frl // frogans : 2013-12-19 OP3FT frogans +// frontier : 2015-02-05 Frontier Communications Corporation +frontier + // fund : 2014-03-20 John Castle, LLC fund @@ -7875,19 +8071,25 @@ furniture // futbol : 2013-09-20 futbol +// fyi : 2015-04-02 Silver Tigers, LLC +fyi + // gal : 2013-11-07 Asociación puntoGAL gal // gallery : 2013-09-13 Sugar House, LLC gallery +// gallup : 2015-02-19 Gallup, Inc. +gallup + // garden : 2014-06-26 Top Level Domain Holdings Limited garden // gbiz : 2014-07-17 Charleston Road Registry Inc. gbiz -// gdn : 2014-07-31 Joint Stock Company +// gdn : 2014-07-31 Joint Stock Company "Navigation-information systems" gdn // gea : 2014-12-04 GEA Group Aktiengesellschaft @@ -7896,6 +8098,9 @@ gea // gent : 2014-01-23 COMBELL GROUP NV/SA gent +// genting : 2015-03-12 Resorts World Inc Pte. Ltd. +genting + // ggee : 2014-01-09 GMO Internet, Inc. ggee @@ -7956,6 +8161,9 @@ gop // got : 2014-12-18 Amazon EU S.à r.l. got +// gotv : 2015-03-12 MultiChoice (Proprietary) Limited +gotv + // graphics : 2013-09-13 Over Madison, LLC graphics @@ -7995,12 +8203,21 @@ hangout // haus : 2013-12-05 haus +// hdfcbank : 2015-02-12 HDFC Bank Limited +hdfcbank + +// health : 2015-02-11 DotHealth, LLC +health + // healthcare : 2014-06-12 Silver Glen, LLC healthcare // help : 2014-06-26 Uniregistry, Corp. help +// helsinki : 2015-02-05 City of Helsinki +helsinki + // here : 2014-02-06 Charleston Road Registry Inc. here @@ -8016,12 +8233,18 @@ hitachi // hiv : 2014-03-13 dotHIV gemeinnuetziger e.V. hiv +// hockey : 2015-03-19 Half Willow, LLC +hockey + // holdings : 2013-08-27 John Madison, LLC holdings // holiday : 2013-11-07 Goose Woods, LLC holiday +// homedepot : 2015-04-02 Homer TLC, Inc. +homedepot + // homes : 2014-01-09 DERHomes, LLC homes @@ -8037,6 +8260,9 @@ host // hosting : 2014-05-29 Uniregistry, Corp. hosting +// hoteles : 2015-03-05 Travel Reservations SRL +hoteles + // hotmail : 2014-12-18 Microsoft Corporation hotmail @@ -8049,9 +8275,15 @@ how // hsbc : 2014-10-24 HSBC Holdings PLC hsbc +// htc : 2015-04-02 HTC corporation +htc + // ibm : 2014-07-31 International Business Machines Corporation ibm +// icbc : 2015-02-19 Industrial and Commercial Bank of China Limited +icbc + // ice : 2014-10-30 IntercontinentalExchange, Inc. ice @@ -8085,6 +8317,9 @@ ink // institute : 2013-11-07 Outer Maple, LLC institute +// insurance : 2015-02-19 fTLD Registry Services LLC +insurance + // insure : 2014-03-20 Pioneer Willow, LLC insure @@ -8100,6 +8335,9 @@ ipiranga // irish : 2014-08-07 Dot-Irish LLC irish +// iselect : 2015-02-11 iSelect Ltd +iselect + // ist : 2014-08-28 Istanbul Metropolitan Municipality ist @@ -8121,12 +8359,27 @@ java // jcb : 2014-11-20 JCB Co., Ltd. jcb +// jcp : 2015-04-23 JCP Media, Inc. +jcp + // jetzt : 2014-01-09 New TLD Company AB jetzt +// jewelry : 2015-03-05 Wild Bloom, LLC +jewelry + +// jio : 2015-04-02 Affinity Names, Inc. +jio + // jlc : 2014-12-04 Richemont DNS Inc. jlc +// jll : 2015-04-02 Jones Lang LaSalle Incorporated +jll + +// jmp : 2015-03-26 Matrix IP LLC +jmp + // joburg : 2014-03-24 ZA Central Registry NPC trading as ZA Central Registry joburg @@ -8136,6 +8389,9 @@ jot // joy : 2014-12-18 Amazon EU S.à r.l. joy +// jpmorgan : 2015-04-30 JPMorgan Chase & Co. +jpmorgan + // jprs : 2014-09-18 Japan Registry Services Co., Ltd. jprs @@ -8148,6 +8404,15 @@ kaufen // kddi : 2014-09-12 KDDI CORPORATION kddi +// kerryhotels : 2015-04-30 Kerry Trading Co. Limited +kerryhotels + +// kerrylogistics : 2015-04-09 Kerry Trading Co. Limited +kerrylogistics + +// kerryproperties : 2015-04-09 Kerry Trading Co. Limited +kerryproperties + // kfh : 2014-12-04 Kuwait Finance House kfh @@ -8169,6 +8434,9 @@ koeln // komatsu : 2015-01-08 Komatsu Ltd. komatsu +// kpmg : 2015-04-23 KPMG International Cooperative (KPMG International Genossenschaft) +kpmg + // kpn : 2015-01-08 Koninklijke KPN N.V. kpn @@ -8178,18 +8446,30 @@ krd // kred : 2013-12-19 KredTLD Pty Ltd kred +// kuokgroup : 2015-04-09 Kerry Trading Co. Limited +kuokgroup + +// kyknet : 2015-03-05 Electronic Media Network (Pty) Ltd +kyknet + // kyoto : 2014-11-07 Academic Institution: Kyoto Jyoho Gakuen kyoto // lacaixa : 2014-01-09 CAIXA D'ESTALVIS I PENSIONS DE BARCELONA lacaixa +// lancaster : 2015-02-12 LANCASTER +lancaster + // land : 2013-09-10 Pine Moon, LLC land // landrover : 2014-11-13 Jaguar Land Rover Ltd landrover +// lasalle : 2015-04-02 Jones Lang LaSalle Incorporated +lasalle + // lat : 2014-10-16 ECOM-LAC Federaciòn de Latinoamèrica y el Caribe para Internet y el Comercio Electrònico lat @@ -8202,7 +8482,7 @@ law // lawyer : 2014-03-20 lawyer -// lds : 2014-03-20 IRI Domain Management, LLC ( +// lds : 2014-03-20 IRI Domain Management, LLC ("Applicant") lds // lease : 2014-03-06 Victor Trail, LLC @@ -8214,6 +8494,9 @@ leclerc // legal : 2014-10-16 Blue Falls, LLC legal +// lexus : 2015-04-23 TOYOTA MOTOR CORPORATION +lexus + // lgbt : 2014-05-08 Afilias Limited lgbt @@ -8256,12 +8539,18 @@ link // live : 2014-12-04 Half Woods, LLC live +// lixil : 2015-03-19 LIXIL Group Corporation +lixil + // loan : 2014-11-20 dot Loan Limited loan // loans : 2014-03-20 June Woods, LLC loans +// lol : 2015-01-30 Uniregistry, Corp. +lol + // london : 2013-11-14 Dot London Domains Limited london @@ -8322,10 +8611,13 @@ markets // marriott : 2014-10-09 Marriott Worldwide Corporation marriott +// mba : 2015-04-02 Lone Hollow, LLC +mba + // media : 2014-03-06 Grand Glen, LLC media -// meet : 2014-01-16 Afilias Limited +// meet : 2014-01-16 meet // melbourne : 2014-05-29 The Crown in right of the State of Victoria, represented by its Department of State Development, Business and Innovation @@ -8337,6 +8629,9 @@ meme // memorial : 2014-10-16 Dog Beach, LLC memorial +// men : 2015-02-26 Exclusive Registry Limited +men + // menu : 2013-09-11 Wedding TLD2, LLC menu @@ -8352,9 +8647,15 @@ microsoft // mini : 2014-01-09 Bayerische Motoren Werke Aktiengesellschaft mini +// mls : 2015-04-23 The Canadian Real Estate Association +mls + // mma : 2014-11-07 MMA IARD mma +// mnet : 2015-03-05 Electronic Media Network (Pty) Ltd +mnet + // mobily : 2014-12-18 GreenTech Consultancy Company W.L.L. mobily @@ -8367,6 +8668,9 @@ moe // moi : 2014-12-18 Amazon EU S.à r.l. moi +// mom : 2015-04-16 Uniregistry, Corp. +mom + // monash : 2013-09-30 Monash University monash @@ -8376,7 +8680,7 @@ money // montblanc : 2014-06-23 Richemont DNS Inc. montblanc -// mormon : 2013-12-05 IRI Domain Management, LLC ( +// mormon : 2013-12-05 IRI Domain Management, LLC ("Applicant") mormon // mortgage : 2014-03-20 @@ -8391,6 +8695,9 @@ motorcycles // mov : 2014-01-30 Charleston Road Registry Inc. mov +// movie : 2015-02-05 New Frostbite, LLC +movie + // movistar : 2014-10-16 Telefónica S.A. movistar @@ -8400,12 +8707,30 @@ mtn // mtpc : 2014-11-20 Mitsubishi Tanabe Pharma Corporation mtpc +// mtr : 2015-03-12 MTR Corporation Limited +mtr + +// multichoice : 2015-03-12 MultiChoice (Proprietary) Limited +multichoice + +// mutual : 2015-04-02 Northwestern Mutual MU TLD Registry, LLC +mutual + +// mzansimagic : 2015-03-05 Electronic Media Network (Pty) Ltd +mzansimagic + // nadex : 2014-12-11 IG Group Holdings PLC nadex // nagoya : 2013-10-24 GMO Registry, Inc. nagoya +// naspers : 2015-02-12 Intelprop (Proprietary) Limited +naspers + +// natura : 2015-03-12 NATURA COSMÉTICOS S.A. +natura + // navy : 2014-03-06 United TLD Holdco Ltd. navy @@ -8424,7 +8749,7 @@ neustar // new : 2014-01-30 Charleston Road Registry Inc. new -// news : 2014-12-18 Hidden Bloom, LLC +// news : 2014-12-18 news // nexus : 2014-07-24 Charleston Road Registry Inc. @@ -8469,6 +8794,12 @@ nyc // obi : 2014-09-25 OBI Group Holding SE & Co. KGaA obi +// observer : 2015-04-30 Guardian News and Media Limited +observer + +// office : 2015-03-12 Microsoft Corporation +office + // okinawa : 2013-12-05 BusinessRalliart Inc. okinawa @@ -8493,9 +8824,15 @@ ooo // oracle : 2014-06-19 Oracle Corporation oracle +// orange : 2015-03-12 Orange Brand Services Limited +orange + // organic : 2014-03-27 Afilias Limited organic +// orientexpress : 2015-02-05 Belmond Ltd. +orientexpress + // osaka : 2014-09-04 Interlink Co., Ltd. osaka @@ -8508,6 +8845,9 @@ ovh // page : 2014-12-04 Charleston Road Registry Inc. page +// pamperedchef : 2015-02-05 The Pampered Chef, Ltd. +pamperedchef + // panerai : 2014-11-07 Richemont DNS Inc. panerai @@ -8526,6 +8866,12 @@ parts // party : 2014-09-11 Blue Sky Registry Limited party +// passagens : 2015-03-05 Travel Reservations SRL +passagens + +// payu : 2015-02-12 MIH PayU B.V. +payu + // pharmacy : 2014-06-19 National Association of Boards of Pharmacy pharmacy @@ -8571,9 +8917,15 @@ pizza // place : 2014-04-24 Snow Galley, LLC place +// play : 2015-03-05 Charleston Road Registry Inc. +play + // plumbing : 2013-09-10 Spring Tigers, LLC plumbing +// plus : 2015-02-05 Sugar Mill, LLC +plus + // pohl : 2014-06-23 Deutsche Vermögensberatung Aktiengesellschaft DVAG pohl @@ -8607,6 +8959,9 @@ properties // property : 2014-05-22 Uniregistry, Corp. property +// protection : 2015-04-23 Symantec Corporation +protection + // pub : 2013-12-12 United TLD Holdco Ltd. pub @@ -8616,6 +8971,9 @@ qpon // quebec : 2013-12-19 PointQuébec Inc quebec +// quest : 2015-03-26 Quest ION Limited +quest + // racing : 2014-12-04 Premier Registry Limited racing @@ -8625,6 +8983,9 @@ read // realtor : 2014-05-29 Real Estate Domains LLC realtor +// realty : 2015-03-19 Fegistry, LLC +realty + // recipes : 2013-10-17 Grand Island, LLC recipes @@ -8634,6 +8995,9 @@ red // redstone : 2014-10-31 Redstone Haute Couture Co., Ltd. redstone +// redumbrella : 2015-03-26 Travelers TLD, LLC +redumbrella + // rehab : 2014-03-06 United TLD Holdco Ltd. rehab @@ -8646,6 +9010,9 @@ reisen // reit : 2014-09-04 National Association of Real Estate Investment Trusts, Inc. reit +// reliance : 2015-04-02 Reliance Industries Limited +reliance + // ren : 2013-12-12 Beijing Qianxiang Wangjing Technology Development Co., Ltd. ren @@ -8682,6 +9049,9 @@ rich // ricoh : 2014-11-20 Ricoh Company, Ltd. ricoh +// ril : 2015-04-02 Reliance Industries Limited +ril + // rio : 2014-02-27 Empresa Municipal de Informática SA - IPLANRIO rio @@ -8706,6 +9076,12 @@ rsvp // ruhr : 2013-10-02 regiodot GmbH & Co. KG ruhr +// run : 2015-03-19 Snow Park, LLC +run + +// rwe : 2015-04-02 RWE AG +rwe + // ryukyu : 2014-01-09 BusinessRalliart Inc. ryukyu @@ -8748,16 +9124,22 @@ sapo // sarl : 2014-07-03 Delta Orchard, LLC sarl +// sas : 2015-04-02 Research IP LLC +sas + // saxo : 2014-10-31 Saxo Bank A/S saxo +// sbi : 2015-03-12 STATE BANK OF INDIA +sbi + // sbs : 2014-11-07 SPECIAL BROADCASTING SERVICE CORPORATION sbs // sca : 2014-03-13 SVENSKA CELLULOSA AKTIEBOLAGET SCA (publ) sca -// scb : 2014-02-20 The Siam Commercial Bank Public Company Limited ( +// scb : 2014-02-20 The Siam Commercial Bank Public Company Limited ("SCB") scb // schmidt : 2014-04-03 SALM S.A.S. @@ -8808,6 +9190,9 @@ sexy // sharp : 2014-05-01 Sharp Corporation sharp +// shaw : 2015-04-23 Shaw Cablesystems G.P. +shaw + // shia : 2014-09-04 Asia Green IT System Bilgisayar San. ve Tic. Ltd. Sti. shia @@ -8820,15 +9205,24 @@ shoes // shouji : 2015-01-08 QIHOO 360 TECHNOLOGY CO. LTD. shouji +// show : 2015-03-05 Snow Beach, LLC +show + // shriram : 2014-01-23 Shriram Capital Ltd. shriram +// sina : 2015-03-12 Sina Corporation +sina + // singles : 2013-08-27 Fern Madison, LLC singles // site : 2015-01-15 DotSite Inc. site +// ski : 2015-04-09 STARTING DOT LIMITED +ski + // skin : 2015-01-15 L'Oréal skin @@ -8841,6 +9235,12 @@ skype // smile : 2014-12-18 Amazon EU S.à r.l. smile +// sncf : 2015-02-19 Société Nationale des Chemins de fer Francais S N C F +sncf + +// soccer : 2015-03-26 Foggy Shadow, LLC +soccer + // social : 2013-11-07 United TLD Holdco Ltd. social @@ -8856,6 +9256,9 @@ solar // solutions : 2013-11-07 Silver Cover, LLC solutions +// song : 2015-02-26 Amazon EU S.à r.l. +song + // sony : 2015-01-08 Sony Corporation sony @@ -8868,6 +9271,9 @@ space // spiegel : 2014-02-05 SPIEGEL-Verlag Rudolf Augstein GmbH & Co. KG spiegel +// spot : 2015-02-26 Amazon EU S.à r.l. +spot + // spreadbetting : 2014-12-11 IG Group Holdings PLC spreadbetting @@ -8877,6 +9283,12 @@ stada // star : 2015-01-08 Star India Private Limited star +// starhub : 2015-02-05 StarHub Limited +starhub + +// statebank : 2015-03-12 STATE BANK OF INDIA +statebank + // statoil : 2014-12-04 Statoil ASA statoil @@ -8892,6 +9304,12 @@ stockholm // storage : 2014-12-22 Self Storage Company LLC storage +// store : 2015-04-09 DotStore Inc. +store + +// studio : 2015-02-11 Spring Goodbye, LLC +studio + // study : 2014-12-11 OPEN UNIVERSITIES AUSTRALIA PTY LTD study @@ -8901,6 +9319,9 @@ style // sucks : 2014-12-22 Vox Populi Registry Inc. sucks +// supersport : 2015-03-05 SuperSport International Holdings Proprietary Limited +supersport + // supplies : 2013-12-19 Atomic Fields, LLC supplies @@ -8940,10 +9361,16 @@ tab // taipei : 2014-07-10 Taipei City Government taipei +// talk : 2015-04-09 Amazon EU S.à r.l. +talk + // taobao : 2015-01-15 Alibaba Group Holding Limited taobao -// tatar : 2014-04-24 Limited Liability Company +// tatamotors : 2015-03-12 Tata Motors Ltd +tatamotors + +// tatar : 2014-04-24 Limited Liability Company "Coordination Center of Regional Domain of Tatarstan Republic" tatar // tattoo : 2013-08-30 Uniregistry, Corp. @@ -8952,12 +9379,24 @@ tattoo // tax : 2014-03-20 Storm Orchard, LLC tax +// taxi : 2015-03-19 Pine Falls, LLC +taxi + // tci : 2014-09-12 Asia Green IT System Bilgisayar San. ve Tic. Ltd. Sti. tci +// team : 2015-03-05 Atomic Lake, LLC +team + +// tech : 2015-01-30 Dot Tech LLC +tech + // technology : 2013-09-13 Auburn Falls technology +// telecity : 2015-02-19 TelecityGroup International Limited +telecity + // telefonica : 2014-10-16 Telefónica S.A. telefonica @@ -8967,9 +9406,24 @@ temasek // tennis : 2014-12-04 Cotton Bloom, LLC tennis +// thd : 2015-04-02 Homer TLC, Inc. +thd + +// theater : 2015-03-19 Blue Tigers, LLC +theater + +// theguardian : 2015-04-30 Guardian News and Media Limited +theguardian + +// tickets : 2015-02-05 Accent Media Limited +tickets + // tienda : 2013-11-14 Victor Manor, LLC tienda +// tiffany : 2015-01-30 Tiffany and Company +tiffany + // tips : 2013-09-20 Corn Willow, LLC tips @@ -9006,6 +9460,9 @@ tours // town : 2014-03-06 Koko Moon, LLC town +// toyota : 2015-04-23 TOYOTA MOTOR CORPORATION +toyota + // toys : 2014-03-06 Pioneer Orchard, LLC toys @@ -9018,15 +9475,30 @@ trading // training : 2013-11-07 Wild Willow, LLC training +// travelers : 2015-03-26 Travelers TLD, LLC +travelers + +// travelersinsurance : 2015-03-26 Travelers TLD, LLC +travelersinsurance + // trust : 2014-10-16 trust +// trv : 2015-03-26 Travelers TLD, LLC +trv + // tui : 2014-07-03 TUI AG tui +// tunes : 2015-02-26 Amazon EU S.à r.l. +tunes + // tushu : 2014-12-18 Amazon EU S.à r.l. tushu +// tvs : 2015-02-19 T V SUNDRAM IYENGAR & SONS LIMITED +tvs + // ubs : 2014-12-11 UBS AG ubs @@ -9063,6 +9535,9 @@ viajes // video : 2014-10-16 video +// viking : 2015-04-02 Viking River Cruises (Bermuda) Ltd. +viking + // villas : 2013-12-05 New Sky, LLC villas @@ -9102,6 +9577,9 @@ voto // voyage : 2013-08-27 Ruby House, LLC voyage +// vuelos : 2015-03-05 Travel Reservations SRL +vuelos + // wales : 2014-05-08 Nominet UK wales @@ -9123,6 +9601,9 @@ watches // weather : 2015-01-08 The Weather Channel, LLC weather +// weatherchannel : 2015-03-12 The Weather Channel, LLC +weatherchannel + // webcam : 2014-01-23 dot Webcam Limited webcam @@ -9135,6 +9616,12 @@ wed // wedding : 2014-04-24 Top Level Domain Holdings Limited wedding +// weibo : 2015-03-05 Sina Corporation +weibo + +// weir : 2015-01-29 Weir Group IP Limited +weir + // whoswho : 2014-02-20 Who's Who Registry whoswho @@ -9187,6 +9674,10 @@ xin कॉम xn--11b4c3d +// xn--1ck2e1b : 2015-02-26 Amazon EU S.à r.l. +セール +xn--1ck2e1b + // xn--1qqw23a : 2014-01-09 Guangzhou YU Wei Information Technology Co., Ltd. 佛山 xn--1qqw23a @@ -9251,6 +9742,10 @@ xn--80asehdb сайт xn--80aswg +// xn--8y0a063a : 2015-03-26 China United Network Communications Corporation Limited +联通 +xn--8y0a063a + // xn--9dbq2a : 2015-01-15 VeriSign Sarl קום xn--9dbq2a @@ -9259,10 +9754,18 @@ xn--9dbq2a 时尚 xn--9et52u +// xn--9krt00a : 2015-03-12 Sina Corporation +微博 +xn--9krt00a + // xn--b4w605ferd : 2014-08-07 Temasek Holdings (Private) Limited 淡马锡 xn--b4w605ferd +// xn--bck1b9a5dre4c : 2015-02-26 Amazon EU S.à r.l. +ファッション +xn--bck1b9a5dre4c + // xn--c1avg : 2013-11-14 Public Interest Registry орг xn--c1avg @@ -9271,11 +9774,15 @@ xn--c1avg नेट xn--c2br7g +// xn--cck2b3b : 2015-02-26 Amazon EU S.à r.l. +ストア +xn--cck2b3b + // xn--cg4bki : 2013-09-27 SAMSUNG SDS CO., LTD 삼성 xn--cg4bki -// xn--czr694b : 2014-01-16 HU YI GLOBAL INFORMATION RESOURCES(HOLDING) COMPANY.HONGKONG LIMITED +// xn--czr694b : 2014-01-16 HU YI GLOBAL INFORMATION RESOURCES (HOLDING) COMPANY.HONGKONG LIMITED 商标 xn--czr694b @@ -9299,6 +9806,14 @@ xn--eckvdtc9d 新闻 xn--efvy88h +// xn--estv75g : 2015-02-19 Industrial and Commercial Bank of China Limited +工行 +xn--estv75g + +// xn--fct429k : 2015-04-09 Amazon EU S.à r.l. +家電 +xn--fct429k + // xn--fhbei : 2015-01-15 VeriSign Sarl كوم xn--fhbei @@ -9319,6 +9834,14 @@ xn--fjq720a 谷歌 xn--flw351e +// xn--g2xx48c : 2015-01-30 Minds + Machines Group Limited +购物 +xn--g2xx48c + +// xn--gckr3f0f : 2015-02-26 Amazon EU S.à r.l. +クラウド +xn--gckr3f0f + // xn--hxt814e : 2014-05-15 Zodiac Libra Limited 网店 xn--hxt814e @@ -9343,6 +9866,10 @@ xn--j1aef 诺基亚 xn--jlq61u9w7b +// xn--jvr189m : 2015-02-26 Amazon EU S.à r.l. +食品 +xn--jvr189m + // xn--kcrx77d1x4a : 2014-11-07 Koninklijke Philips N.V. 飞利浦 xn--kcrx77d1x4a @@ -9423,6 +9950,10 @@ xn--qcka1pmc 世界 xn--rhqv96g +// xn--rovu88b : 2015-02-26 Amazon EU S.à r.l. +書籍 +xn--rovu88b + // xn--ses554g : 2014-01-16 网址 xn--ses554g @@ -9455,6 +9986,10 @@ xn--vhquv 信息 xn--vuq861b +// xn--w4r85el8fhu5dnra : 2015-04-30 Kerry Trading Co. Limited +嘉里大酒店 +xn--w4r85el8fhu5dnra + // xn--xhq521b : 2013-11-14 Guangzhou YU Wei Information Technology Co., Ltd. 广东 xn--xhq521b @@ -9469,6 +10004,9 @@ xyz // yachts : 2014-01-09 DERYachts, LLC yachts +// yahoo : 2015-04-02 Yahoo! Domain Services Inc. +yahoo + // yamaxun : 2014-12-18 Amazon EU S.à r.l. yamaxun @@ -9484,6 +10022,9 @@ yoga // yokohama : 2013-12-12 GMO Registry, Inc. yokohama +// you : 2015-04-09 Amazon EU S.à r.l. +you + // youtube : 2014-05-01 Charleston Road Registry Inc. youtube @@ -9508,6 +10049,7 @@ zuerich // ===END ICANN DOMAINS=== // ===BEGIN PRIVATE DOMAINS=== +// (Note: these are in alphabetical order by company name) // Amazon CloudFront : https://aws.amazon.com/cloudfront/ // Submitted by Donavan Miller 2013-03-22 @@ -9925,6 +10467,66 @@ webhop.org worse-than.tv writesthisblog.com +// EU.org https://eu.org/ +// Submitted by Pierre Beyssac 2015-04-17 + +eu.org +al.eu.org +asso.eu.org +at.eu.org +au.eu.org +be.eu.org +bg.eu.org +ca.eu.org +cd.eu.org +ch.eu.org +cn.eu.org +cy.eu.org +cz.eu.org +de.eu.org +dk.eu.org +edu.eu.org +ee.eu.org +es.eu.org +fi.eu.org +fr.eu.org +gr.eu.org +hr.eu.org +hu.eu.org +ie.eu.org +il.eu.org +in.eu.org +int.eu.org +is.eu.org +it.eu.org +jp.eu.org +kr.eu.org +lt.eu.org +lu.eu.org +lv.eu.org +mc.eu.org +me.eu.org +mk.eu.org +mt.eu.org +my.eu.org +net.eu.org +ng.eu.org +nl.eu.org +no.eu.org +nz.eu.org +paris.eu.org +pl.eu.org +pt.eu.org +q-a.eu.org +ro.eu.org +ru.eu.org +se.eu.org +si.eu.org +sk.eu.org +tr.eu.org +uk.eu.org +us.eu.org + // Fastly Inc. http://www.fastly.com/ // Submitted by Vladimir Vuksan 2013-05-31 a.ssl.fastly.net @@ -9941,6 +10543,10 @@ firebaseapp.com // Submitted by Jonathan Rudenberg 2014-07-12 flynnhub.com +// GDS : https://www.gov.uk/service-manual/operations/operating-servicegovuk-subdomains +// Submitted by David Illsley 2014-08-28 +service.gov.uk + // GitHub, Inc. // Submitted by Ben Toews 2014-02-06 github.io @@ -10024,6 +10630,10 @@ azurewebsites.net azure-mobile.net cloudapp.net +// Neustar Inc. +// Submitted by Trung Tran 2015-04-23 +4u.com + // NFSN, Inc. : https://www.NearlyFreeSpeech.NET/ // Submitted by Jeff Wheelhouse 2014-02-02 nfshost.com @@ -10052,17 +10662,19 @@ poznan.pl wroc.pl zakopane.pl +// priv.at : http://www.nic.priv.at/ +// Submitted by registry 2008-06-09 +priv.at + // Red Hat, Inc. OpenShift : https://openshift.redhat.com/ // Submitted by Tim Kramer 2012-10-24 rhcloud.com -// GDS : https://www.gov.uk/service-manual/operations/operating-servicegovuk-subdomains -// Submitted by David Illsley 2014-08-28 -service.gov.uk - -// priv.at : http://www.nic.priv.at/ -// Submitted by registry 2008-06-09 -priv.at +// SinaAppEngine : http://sae.sina.com.cn/ +// Submitted by SinaAppEngine 2015-02-02 +sinaapp.com +vipsinaapp.com +1kapp.com // TASK geographical domains (www.task.gda.pl/uslugi/dns) gda.pl diff --git a/net/ddns-scripts/files/update_nsupdate.sh b/net/ddns-scripts/files/update_nsupdate.sh new file mode 100644 index 000000000..1af94041e --- /dev/null +++ b/net/ddns-scripts/files/update_nsupdate.sh @@ -0,0 +1,46 @@ +# +#.Distributed under the terms of the GNU General Public License (GPL) version 2.0 +# +# The script directly updates a PowerDNS (or maybe bind server) via nsupdate from bind-client package. +#.based on github request #957 by Jan Riechers +#.2015 Christian Schoenebeck +# +# This script is parsed by dynamic_dns_functions.sh inside send_update() function +# +# using following options from /etc/config/ddns +# option username - keyname +# option password - shared secret (base64 encoded) +# option domain - full qualified domain to update +# option dns_server - DNS server to update +# +# variable __IP already defined with the ip-address to use for update +# +local __TTL=600 #.preset DNS TTL (in seconds) +local __RRTYPE __PW __TCP + +[ -x /usr/bin/nsupdate ] || write_log 14 "'nsupdate' not installed or not executable !" + +[ -z "$username" ] && write_log 14 "Service section not configured correctly! Missing 'username'" +[ -z "$password" ] && write_log 14 "Service section not configured correctly! Missing 'password'" +[ -z "$dns_server" ] && write_log 14 "Service section not configured correctly! Missing 'dns_server'" + +[ $use_ipv6 -ne 0 ] && __RRTYPE="AAAA" || __RRTYPE="A" +[ $force_dnstcp -ne 0 ] && __TCP="-v" || __TCP="" + +# create command file +cat >$DATFILE <<-EOF +server $dns_server +key $username $password +update del $domain $__RRTYPE +update add $domain $__TTL $__RRTYPE $__IP +show +send +quit +EOF + +/usr/bin/nsupdate -d $__TCP $DATFILE >$ERRFILE 2>&1 + +# nsupdate always return success +write_log 7 "nsupdate reports:\n$(cat $ERRFILE)" + +return 0 \ No newline at end of file diff --git a/net/dmapd/Makefile b/net/dmapd/Makefile index f69622e9c..d53c5576f 100644 --- a/net/dmapd/Makefile +++ b/net/dmapd/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=dmapd -PKG_VERSION:=0.0.70 +PKG_VERSION:=0.0.72 PKG_RELEASE:=1 PKG_MAINTAINER:=W. Michael Petullo @@ -18,7 +18,7 @@ PKG_LICENSE_FILES:=COPYING PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.flyn.org/projects/dmapd -PKG_MD5SUM:=f503bf95f79b5c1f9418cccf26203952 +PKG_MD5SUM:=0fe290d1bf003296b1ed9dfcc0108d6f PKG_FIXUP:=autoreconf PKG_INSTALL:=2 diff --git a/net/dnscrypt-proxy/Makefile b/net/dnscrypt-proxy/Makefile index 22458fbfb..32a872185 100644 --- a/net/dnscrypt-proxy/Makefile +++ b/net/dnscrypt-proxy/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=dnscrypt-proxy -PKG_VERSION:=1.4.3 +PKG_VERSION:=1.5.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://download.dnscrypt.org/dnscrypt-proxy -PKG_MD5SUM:=54d172236a8f321fb5689ff81767f1ba +PKG_MD5SUM:=bcaaaae4797082dd7a6ba618cc3e687c PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/net/e2guardian/Makefile b/net/e2guardian/Makefile index 0823d95fc..10a41b91e 100644 --- a/net/e2guardian/Makefile +++ b/net/e2guardian/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=e2guardian -PKG_VERSION:=3.0.4 +PKG_VERSION:=3.1.2 PKG_RELEASE:=1 PKG_LICENSE:=GPL-2.0 @@ -16,8 +16,8 @@ PKG_MAINTAINER:=Luka Perkov PKG_SOURCE:=v$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/e2guardian/e2guardian/archive/ -PKG_MD5SUM:=f8ffac7ac4f040b672cc4e62121bf4c5 - +PKG_MD5SUM:=85cfa16074737dbc3935f93dfcded285 +PKG_FIXUP:=autoreconf PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 @@ -45,9 +45,12 @@ CONFIGURE_VARS += \ CONFIGURE_ARGS += \ --with-sysconfsubdir=e2guardian \ - --with-proxyuser=root \ - --with-proxygroup=root \ - --enable-pcre=yes + --with-proxyuser=nobody \ + --with-proxygroup=nogroup \ + --enable-pcre=yes \ + --with-piddir=/tmp/e2guardian/ \ + --enable-sslextralists=no \ + --enable-sslmitm=no define Build/Configure $(call Build/Configure/Default,$CONFIGURE_ARGS) diff --git a/net/e2guardian/files/e2guardian.config b/net/e2guardian/files/e2guardian.config index 2b46f2035..a87615138 100644 --- a/net/e2guardian/files/e2guardian.config +++ b/net/e2guardian/files/e2guardian.config @@ -1,13 +1,11 @@ config e2guardian 'e2guardian' - option config_file '/etc/e2guardian/e2guardianf1.conf' option languagedir '/usr/share/e2guardian/languages' option language 'ukenglish' option loglevel '2' option logexceptionhits '2' option logfileformat '1' - option loglocation '/dev/null' + option loglocation '/var/log/e2guardian/access.log' option maxuploadsize '-1' - option filterip '' option filterports '8080' option proxyip '127.0.0.1' option proxyport '3128' @@ -45,6 +43,7 @@ config e2guardian 'e2guardian' option deletedownloadedtempfiles 'on' option initialtrickledelay '20' option trickledelay '10' + option downloadmanager '/etc/e2guardian/downloadmanagers/fancy.conf' option downloadmanager '/etc/e2guardian/downloadmanagers/default.conf' option contentscannertimeout '60' option contentscanexceptions 'off' diff --git a/net/e2guardian/files/e2guardian.init b/net/e2guardian/files/e2guardian.init index 132b61f83..96c2802c1 100644 --- a/net/e2guardian/files/e2guardian.init +++ b/net/e2guardian/files/e2guardian.init @@ -7,13 +7,15 @@ STOP=10 USE_PROCD=1 PROG=/usr/sbin/e2guardian CONFIGFILE="/tmp/e2guardian/e2guardian.conf" +LOGFILE="/tmp/e2guardian/access.log" +GROUPCONFIG="/tmp/e2guardian/e2guardianf1.conf" validate_e2guardian_section() { uci_validate_section e2guardian e2guardian "${1}" \ - 'config_file:string' \ 'accessdeniedaddress:string' \ 'bannediplist:string' \ 'contentscanexceptions:string' \ + 'contentscanner:string' 'contentscannertimeout:uinteger' \ 'createlistcachefiles:string' \ 'custombannedflashfile:string' \ @@ -83,7 +85,7 @@ validate_e2guardian_section() { start_service() { - local config_file accessdeniedaddress bannediplist contentscanexceptions contentscannertimeout \ + local accessdeniedaddress bannediplist contentscanexceptions contentscanner contentscannertimeout \ createlistcachefiles custombannedflashfile custombannedimagefile deletedownloadedtempfiles \ downloadmanager exceptioniplist filecachedir loglocation \ filtergroups filtergroupslist filterip filterports forcequicksearch forwardedfor hexdecodecontent \ @@ -102,10 +104,26 @@ start_service() { } mkdir -p $(dirname $CONFIGFILE) - ln -sf $config_file $(dirname $CONFIGFILE) + chown -R nobody:nogroup $(dirname $CONFIGFILE) + + mkdir -p $(dirname $loglocation) + chown -R nobody:nogroup $(dirname $loglocation) + + touch $loglocation + chown nobody:nogroup $loglocation + + ln -sf $loglocation $(dirname $LOGFILE) + ln -sf /etc/e2guardian/e2guardian.conf $CONFIGFILE + ln -sf /etc/e2guardian/e2guardianf1.conf $GROUPCONFIG echo "accessdeniedaddress = " $accessdeniedaddress > $CONFIGFILE echo "bannediplist = " $bannediplist >> $CONFIGFILE + + if [ "$contentscanner" != "" ] + then + echo "contentscanner = " $contentscanner >> $CONFIGFILE + fi + echo "contentscanexceptions = " $contentscanexceptions >> $CONFIGFILE echo "contentscannertimeout = " $contentscannertimeout >> $CONFIGFILE echo "createlistcachefiles = " $createlistcachefiles >> $CONFIGFILE @@ -174,15 +192,17 @@ start_service() { echo "weightedphrasemode = " $weightedphrasemode >> $CONFIGFILE procd_open_instance - procd_set_param command $PROG -N -c "$CONFIGFILE" + procd_set_param command $PROG -c $CONFIGFILE procd_set_param file $CONFIGFILE - procd_set_param respawn procd_close_instance + } stop_service() { - e2guardian -s | awk -F':' '{ print $2}' | xargs kill -9 + PID=`cat /tmp/e2guardian/e2guardian.pid` + kill $PID + rm -f /tmp/e2guardian/e2guardian.pid } service_triggers() diff --git a/net/e2guardian/files/e2guardianf1.conf b/net/e2guardian/files/e2guardianf1.conf index 21a145a49..c4b821fc3 100644 --- a/net/e2guardian/files/e2guardianf1.conf +++ b/net/e2guardian/files/e2guardianf1.conf @@ -1,4 +1,4 @@ -# e2guardian filter group config file for version 3.0.4 +# e2guardian filter group config file for version 3.1.2 # Filter group mode @@ -25,41 +25,41 @@ groupmode = 1 groupname = '' # Content filtering files location -bannedphraselist = 'etc/e2guardian/lists/bannedphraselist' -weightedphraselist = 'etc/e2guardian/lists/weightedphraselist' -exceptionphraselist = 'etc/e2guardian/lists/exceptionphraselist' -bannedsitelist = 'etc/e2guardian/lists/bannedsitelist' -greysitelist = 'etc/e2guardian/lists/greysitelist' -bannedsslsitelist = 'etc/e2guardian/lists/bannedsslsitelist' -greysslsitelist = 'etc/e2guardian/lists/greysslsitelist' -exceptionsitelist = 'etc/e2guardian/lists/exceptionsitelist' -bannedurllist = 'etc/e2guardian/lists/bannedurllist' -greyurllist = 'etc/e2guardian/lists/greyurllist' -exceptionurllist = 'etc/e2guardian/lists/exceptionurllist' -exceptionregexpurllist = 'etc/e2guardian/lists/exceptionregexpurllist' -bannedregexpurllist = 'etc/e2guardian/lists/bannedregexpurllist' -picsfile = 'etc/e2guardian/lists/pics' -contentregexplist = 'etc/e2guardian/lists/contentregexplist' -urlregexplist = 'etc/e2guardian/lists/urlregexplist' -refererexceptionsitelist = 'etc/e2guardian/lists/refererexceptionsitelist' -refererexceptionurllist = 'etc/e2guardian/lists/refererexceptionurllist' -embededreferersitelist = 'etc/e2guardian/lists/embededreferersitelist' -embededrefererurllist = 'etc/e2guardian/lists/embededrefererurllist' -urlredirectregexplist = 'etc/e2guardian/lists/urlredirectregexplist' +bannedphraselist = '/etc/e2guardian/lists/bannedphraselist' +weightedphraselist = '/etc/e2guardian/lists/weightedphraselist' +exceptionphraselist = '/etc/e2guardian/lists/exceptionphraselist' +bannedsitelist = '/etc/e2guardian/lists/bannedsitelist' +greysitelist = '/etc/e2guardian/lists/greysitelist' +bannedsslsitelist = '/etc/e2guardian/lists/bannedsslsitelist' +greysslsitelist = '/etc/e2guardian/lists/greysslsitelist' +exceptionsitelist = '/etc/e2guardian/lists/exceptionsitelist' +bannedurllist = '/etc/e2guardian/lists/bannedurllist' +greyurllist = '/etc/e2guardian/lists/greyurllist' +exceptionurllist = '/etc/e2guardian/lists/exceptionurllist' +exceptionregexpurllist = '/etc/e2guardian/lists/exceptionregexpurllist' +bannedregexpurllist = '/etc/e2guardian/lists/bannedregexpurllist' +picsfile = '/etc/e2guardian/lists/pics' +contentregexplist = '/etc/e2guardian/lists/contentregexplist' +urlregexplist = '/etc/e2guardian/lists/urlregexplist' +refererexceptionsitelist = '/etc/e2guardian/lists/refererexceptionsitelist' +refererexceptionurllist = '/etc/e2guardian/lists/refererexceptionurllist' +embededreferersitelist = '/etc/e2guardian/lists/embededreferersitelist' +embededrefererurllist = '/etc/e2guardian/lists/embededrefererurllist' +urlredirectregexplist = '/etc/e2guardian/lists/urlredirectregexplist' # local versions of lists (where LOCAL_LISTS enabled) -#localbannedsitelist = 'etc/e2guardian/lists/localbannedsitelist' -#localgreysitelist = 'etc/e2guardian/lists/localgreysitelist' -#localexceptionsitelist = 'etc/e2guardian/lists/localexceptionsitelist' -#localbannedurllist = 'etc/e2guardian/lists/localbannedurllist' -#localgreyurllist = 'etc/e2guardian/lists/localgreyurllist' -#localexceptionurllist = 'etc/e2guardian/lists/localexceptionurllist' -#localbannedsslsitelist = 'etc/e2guardian/lists/localbannedsslsitelist' -#localgreysslsitelist = 'etc/e2guardian/lists/localgreysslsitelist' -#localbannedsearchlist = 'etc/e2guardian/lists/localbannedsearchlist' - -!! Not compiled !! authexceptionsitelist = 'etc/e2guardian/lists/authexceptionsitelist' -!! Not compiled !! authexceptionurllist = 'etc/e2guardian/lists/authexceptionurllist' +#localbannedsitelist = '/etc/e2guardian/lists/localbannedsitelist' +#localgreysitelist = '/etc/e2guardian/lists/localgreysitelist' +#localexceptionsitelist = '/etc/e2guardian/lists/localexceptionsitelist' +#localbannedurllist = '/etc/e2guardian/lists/localbannedurllist' +#localgreyurllist = '/etc/e2guardian/lists/localgreyurllist' +#localexceptionurllist = '/etc/e2guardian/lists/localexceptionurllist' +#localbannedsslsitelist = '/etc/e2guardian/lists/localbannedsslsitelist' +#localgreysslsitelist = '/etc/e2guardian/lists/localgreysslsitelist' +#localbannedsearchlist = '/etc/e2guardian/lists/localbannedsearchlist' + +!! Not compiled !! authexceptionsitelist = '/etc/e2guardian/lists/authexceptionsitelist' +!! Not compiled !! authexceptionurllist = '/etc/e2guardian/lists/authexceptionurllist' # Filetype filtering # @@ -78,20 +78,20 @@ urlredirectregexplist = 'etc/e2guardian/lists/urlredirectregexplist' # (on | off) # blockdownloads = off -exceptionextensionlist = 'etc/e2guardian/lists/exceptionextensionlist' -exceptionmimetypelist = 'etc/e2guardian/lists/exceptionmimetypelist' +exceptionextensionlist = '/etc/e2guardian/lists/exceptionextensionlist' +exceptionmimetypelist = '/etc/e2guardian/lists/exceptionmimetypelist' # # Use the following lists to block specific kinds of file downloads. # The two exception lists above can be used to override these. # -bannedextensionlist = 'etc/e2guardian/lists/bannedextensionlist' -bannedmimetypelist = 'etc/e2guardian/lists/bannedmimetypelist' +bannedextensionlist = '/etc/e2guardian/lists/bannedextensionlist' +bannedmimetypelist = '/etc/e2guardian/lists/bannedmimetypelist' # # In either file filtering mode, the following list can be used to override # MIME type & extension blocks for particular domains & URLs (trusted download sites). # -exceptionfilesitelist = 'etc/e2guardian/lists/exceptionfilesitelist' -exceptionfileurllist = 'etc/e2guardian/lists/exceptionfileurllist' +exceptionfilesitelist = '/etc/e2guardian/lists/exceptionfilesitelist' +exceptionfileurllist = '/etc/e2guardian/lists/exceptionfileurllist' # POST protection (web upload and forms) # does not block forms without any file upload, i.e. this is just for @@ -108,9 +108,9 @@ maxuploadsize = -1 # Supply categorised lists here and the category string shall be logged against # matching requests, but matching these lists does not perform any filtering # action. -#logsitelist = 'etc/e2guardian/lists/logsitelist' -#logurllist = 'etc/e2guardian/lists/logurllist' -#logregexpurllist = 'etc/e2guardian/lists/logregexpurllist' +#logsitelist = '/etc/e2guardian/lists/logsitelist' +#logurllist = '/etc/e2guardian/lists/logurllist' +#logregexpurllist = '/etc/e2guardian/lists/logregexpurllist' # Outgoing HTTP header rules: # Optional lists for blocking based on, and modification of, outgoing HTTP @@ -121,9 +121,9 @@ maxuploadsize = -1 # Headers are matched/replaced on a line-by-line basis, not as a contiguous # block. # Use for example, to remove cookies or prevent certain user-agents. -headerregexplist = 'etc/e2guardian/lists/headerregexplist' -bannedregexpheaderlist = 'etc/e2guardian/lists/bannedregexpheaderlist' -addheaderregexplist = 'etc/e2guardian/lists/addheaderregexplist' +headerregexplist = '/etc/e2guardian/lists/headerregexplist' +bannedregexpheaderlist = '/etc/e2guardian/lists/bannedregexpheaderlist' +addheaderregexplist = '/etc/e2guardian/lists/addheaderregexplist' # Weighted phrase mode # Optional; overrides the weightedphrasemode option in e2guardian.conf @@ -166,11 +166,11 @@ naughtynesslimit = 50 # List of regular expressions for matching search engine URLs. It is assumed # that the search terms themselves will be contained in the # of output of each expression. -#searchregexplist = 'etc/e2guardian/lists/searchregexplist' +#searchregexplist = '/etc/e2guardian/lists/searchregexplist' # # Banned Search Term list(s) for option 1 -#bannedsearchlist = 'etc/e2guardian/lists/bannedsearchlist' -#bannedsearchoveridelist = 'etc/e2guardian/lists/bannedsearchoveridelist' +#bannedsearchlist = '/etc/e2guardian/lists/bannedsearchlist' +#bannedsearchoveridelist = '/etc/e2guardian/lists/bannedsearchoveridelist' # Search term limit (for Option 2) @@ -192,9 +192,9 @@ naughtynesslimit = 50 # of text. # Please note that all or none of the below should be uncommented, not a # mixture. -#bannedsearchtermlist = 'etc/e2guardian/lists/bannedsearchtermlist' -#weightedsearchtermlist = 'etc/e2guardian/lists/weightedsearchtermlist' -#exceptionsearchtermlist = 'etc/e2guardian/lists/exceptionsearchtermlist' +#bannedsearchtermlist = '/etc/e2guardian/lists/bannedsearchtermlist' +#weightedsearchtermlist = '/etc/e2guardian/lists/weightedsearchtermlist' +#exceptionsearchtermlist = '/etc/e2guardian/lists/exceptionsearchtermlist' # Category display threshold # This option only applies to pages blocked by weighted phrase filtering. @@ -330,12 +330,12 @@ reportinglevel = 3 # only used in reporting level 3. # # The default template file path is //template.h -# e.g. share/e2guardian/languages/ukenglish/template.html when using 'ukenglish' +# e.g. /share/e2guardian/languages/ukenglish/template.html when using 'ukenglish' # language. # # This option generates a file path of the form: # // -# e.g. share/e2guardian/languages/ukenglish/custom.html +# e.g. /share/e2guardian/languages/ukenglish/custom.html # #htmltemplate = 'custom.html' @@ -420,7 +420,11 @@ reportinglevel = 3 sslcertcheck = off #SSL man in the middle -# Forge ssl certificates for all sites, decrypt the data then re encrypt it +# Forge ssl certificates for all non-exception sites, decrypt the data then re encrypt it # using a different private key. Used to filter ssl sites sslmitm = off +#Limit SSL MITM to sites in greysslsitelist(s) +# ignored if sslmitm is off +# SSL sites not matching greysslsitelist will be treat as if sslmitm is off. +onlymitmsslgrey = off diff --git a/net/emailrelay/Makefile b/net/emailrelay/Makefile index bbcd6148b..9352db729 100644 --- a/net/emailrelay/Makefile +++ b/net/emailrelay/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=emailrelay PKG_VERSION:=1.9 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-src.tar.gz PKG_SOURCE_URL:=@SF/emailrelay/$(PKG_VERSION) diff --git a/net/emailrelay/files/emailrelay.init b/net/emailrelay/files/emailrelay.init index c63d2f061..9fc33996e 100644 --- a/net/emailrelay/files/emailrelay.init +++ b/net/emailrelay/files/emailrelay.init @@ -6,10 +6,10 @@ START=90 start() { logger -t 'emailrelay' "Starting emailrelay service." - service_start emailrelay --as-server --poll 60 --forward-to smtpserver:smtpport --spool-dir /tmp --client-tls --client-auth /etc/emailrelay.auth --server-auth /etc/emailrelay.auth --log + service_start /usr/bin/emailrelay --as-server --poll 60 --forward-to smtpserver:smtpport --spool-dir /tmp --client-tls --client-auth /etc/emailrelay.auth --server-auth /etc/emailrelay.auth --log } stop() { logger -t 'emailrelay' "Stopping emailrelay service." - killall -9 emailrelay + service_stop /usr/bin/emailrelay } diff --git a/net/etherwake/Makefile b/net/etherwake/Makefile index 7343adc0d..4d05e3dab 100644 --- a/net/etherwake/Makefile +++ b/net/etherwake/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2011 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=etherwake PKG_VERSION:=1.09 -PKG_RELEASE:=3 +PKG_RELEASE:=4 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).orig.tar.gz PKG_SOURCE_URL:=http://ftp.debian.org/debian/pool/main/e/etherwake diff --git a/net/etherwake/patches/120-musl-compat.patch b/net/etherwake/patches/120-musl-compat.patch new file mode 100644 index 000000000..a2cdfba9d --- /dev/null +++ b/net/etherwake/patches/120-musl-compat.patch @@ -0,0 +1,17 @@ +--- a/ether-wake.c ++++ b/ether-wake.c +@@ -82,14 +82,8 @@ static char usage_msg[] = + #include + + #include +-#if __GLIBC__ >= 2 && __GLIBC_MINOR >= 1 + #include + #include +-#else +-#include +-#include +-#include +-#endif + #include + #include + diff --git a/net/ethtool/Config.in b/net/ethtool/Config.in new file mode 100644 index 000000000..7ec55536e --- /dev/null +++ b/net/ethtool/Config.in @@ -0,0 +1,7 @@ +menu "Configuration" + depends on PACKAGE_ethtool + + config ETHTOOL_PRETTY_DUMP + bool "Enable pretty printing" + +endmenu diff --git a/net/ethtool/Makefile b/net/ethtool/Makefile index 5ffb8253c..1a0d832b6 100644 --- a/net/ethtool/Makefile +++ b/net/ethtool/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ethtool -PKG_VERSION:=3.18 +PKG_VERSION:=4.0 PKG_RELEASE:=1 PKG_MAINTAINER:=Matthias Schiffer PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@KERNEL/software/network/ethtool -PKG_MD5SUM:=fbf1a167b88a5966a2c56a2483af68c6 +PKG_MD5SUM:=37c77b02556255e4122c3636f75a8646 PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING @@ -23,6 +23,8 @@ PKG_FIXUP:=autoreconf PKG_INSTALL:=1 PKG_BUILD_PARALLEL:=1 +PKG_CONFIG_DEPENDS:=ETHTOOL_PRETTY_DUMP + include $(INCLUDE_DIR)/package.mk define Package/ethtool @@ -37,6 +39,16 @@ define Package/ethtool/description network interface endef +define Package/ethtool/config + source "$(SOURCE)/Config.in" +endef + +ifeq ($(CONFIG_ETHTOOL_PRETTY_DUMP),y) +CONFIGURE_ARGS += --enable-pretty-dump +else +CONFIGURE_ARGS += --disable-pretty-dump +endif + define Package/ethtool/install $(INSTALL_DIR) $(1)/usr/sbin $(INSTALL_BIN) $(PKG_BUILD_DIR)/ethtool $(1)/usr/sbin diff --git a/net/fastd/Makefile b/net/fastd/Makefile index 027f5491d..0574b399e 100644 --- a/net/fastd/Makefile +++ b/net/fastd/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=fastd PKG_VERSION:=17 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_MAINTAINER:=Matthias Schiffer PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz diff --git a/net/fastd/patches/100-musl-compat.patch b/net/fastd/patches/100-musl-compat.patch new file mode 100644 index 000000000..984aace11 --- /dev/null +++ b/net/fastd/patches/100-musl-compat.patch @@ -0,0 +1,67 @@ +--- a/cmake/checks.cmake ++++ b/cmake/checks.cmake +@@ -54,9 +54,13 @@ if(NOT DARWIN) + endif(NOT DARWIN) + + ++set(CMAKE_EXTRA_INCLUDE_FILES "linux/if_ether.h") ++check_type_size("struct ethhdr" SIZEOF_ETHHDR) ++string(COMPARE NOTEQUAL "${SIZEOF_ETHHDR}" "" HAVE_LINUX_ETHHDR) ++ + set(CMAKE_EXTRA_INCLUDE_FILES "netinet/if_ether.h") + check_type_size("struct ethhdr" SIZEOF_ETHHDR) +-string(COMPARE NOTEQUAL "${SIZEOF_ETHHDR}" "" HAVE_ETHHDR) ++string(COMPARE NOTEQUAL "${SIZEOF_ETHHDR}" "" HAVE_NETINET_ETHHDR) + + + set(CMAKE_REQUIRED_INCLUDES "sys/types.h") +--- a/src/compat.h ++++ b/src/compat.h +@@ -45,7 +45,12 @@ + #include + #include + #include ++ ++#if defined(HAVE_LINUX_ETHHDR) ++#include ++#elif defined(HAVE_NETINET_ETHHDR) + #include ++#endif + + #ifndef ETH_ALEN + /** The length of a MAC address */ +@@ -55,9 +60,8 @@ + #ifndef ETH_HLEN + /** The length of the standard ethernet header */ + #define ETH_HLEN 14 +-#endif + +-#ifndef HAVE_ETHHDR ++#if !defined(HAVE_LINUX_ETHHDR) && !defined(HAVE_NETINET_ETHHDR) + /** An ethernet header */ + struct ethhdr { + uint8_t h_dest[ETH_ALEN]; /**< The destination MAC address field */ +@@ -65,6 +69,7 @@ struct ethhdr { + uint16_t h_proto; /**< The EtherType/length field */ + } __attribute__((packed)); + #endif ++#endif + + #if defined(USE_FREEBIND) && !defined(IP_FREEBIND) + /** Compatiblity define for systems supporting, but not defining IP_FREEBIND */ +--- a/src/fastd_config.h.in ++++ b/src/fastd_config.h.in +@@ -35,8 +35,11 @@ + /** Defined if the platform supports the AI_ADDRCONFIG flag to getaddrinfo() */ + #cmakedefine HAVE_AI_ADDRCONFIG + +-/** Defined if the platform defines the \e ethhdr struct */ +-#cmakedefine HAVE_ETHHDR ++/** Defined if the platform defines the \e ethhdr struct through linux/if_ether.h */ ++#cmakedefine HAVE_LINUX_ETHHDR ++ ++/** Defined if the platform defines the \e ethhdr struct through netinet/if_ether.h */ ++#cmakedefine HAVE_NETINET_ETHHDR + + /** Defined if the platform defines get_current_dir_name() */ + #cmakedefine HAVE_GET_CURRENT_DIR_NAME diff --git a/net/freeradius2/Makefile b/net/freeradius2/Makefile index 1f1d86dce..82a125ba2 100644 --- a/net/freeradius2/Makefile +++ b/net/freeradius2/Makefile @@ -8,12 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=freeradius2 -PKG_VERSION:=2.2.6 +PKG_VERSION:=2.2.7 PKG_RELEASE:=1 PKG_SOURCE:=freeradius-server-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=ftp://ftp.freeradius.org/pub/freeradius/ -PKG_MD5SUM:=e9a6f9bbee9706b008b924061ab3f915 +PKG_SOURCE_URL:=\ + ftp://ftp.freeradius.org/pub/freeradius/ \ + ftp://ftp.freeradius.org/pub/freeradius/old/ +PKG_MD5SUM:=b84b9ffa1ac9b20b2643e5a08ac483a1 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYRIGHT LICENSE diff --git a/net/freeradius2/patches/001-fix-makefile.patch b/net/freeradius2/patches/001-fix-makefile.patch index 2daaec823..676f99cd1 100644 --- a/net/freeradius2/patches/001-fix-makefile.patch +++ b/net/freeradius2/patches/001-fix-makefile.patch @@ -1,5 +1,7 @@ ---- a/Make.inc.in -+++ b/Make.inc.in +Index: freeradius-server-2.2.7/Make.inc.in +=================================================================== +--- freeradius-server-2.2.7.orig/Make.inc.in ++++ freeradius-server-2.2.7/Make.inc.in @@ -5,6 +5,7 @@ # diff --git a/net/freeradius2/patches/002-config.patch b/net/freeradius2/patches/002-config.patch index 8794345fa..c486389b8 100644 --- a/net/freeradius2/patches/002-config.patch +++ b/net/freeradius2/patches/002-config.patch @@ -1,5 +1,7 @@ ---- a/raddb/dictionary.in -+++ b/raddb/dictionary.in +Index: freeradius-server-2.2.7/raddb/dictionary.in +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/dictionary.in ++++ freeradius-server-2.2.7/raddb/dictionary.in @@ -11,7 +11,7 @@ # # The filename given here should be an absolute path. @@ -9,8 +11,10 @@ # # Place additional attributes or $INCLUDEs here. They will ---- a/raddb/eap.conf -+++ b/raddb/eap.conf +Index: freeradius-server-2.2.7/raddb/eap.conf +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/eap.conf ++++ freeradius-server-2.2.7/raddb/eap.conf @@ -27,7 +27,7 @@ # then that EAP type takes precedence over the # default type configured here. @@ -206,8 +210,10 @@ # This option enables support for MS-SoH # see doc/SoH.txt for more info. ---- a/raddb/modules/counter -+++ b/raddb/modules/counter +Index: freeradius-server-2.2.7/raddb/modules/counter +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/modules/counter ++++ freeradius-server-2.2.7/raddb/modules/counter @@ -69,7 +69,7 @@ # 'check-name' attribute. # @@ -217,8 +223,10 @@ key = User-Name count-attribute = Acct-Session-Time reset = daily ---- a/raddb/modules/pap -+++ b/raddb/modules/pap +Index: freeradius-server-2.2.7/raddb/modules/pap +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/modules/pap ++++ freeradius-server-2.2.7/raddb/modules/pap @@ -18,5 +18,5 @@ # # http://www.openldap.org/faq/data/cache/347.html @@ -226,8 +234,10 @@ - auto_header = no + auto_header = yes } ---- a/raddb/modules/radutmp -+++ b/raddb/modules/radutmp +Index: freeradius-server-2.2.7/raddb/modules/radutmp +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/modules/radutmp ++++ freeradius-server-2.2.7/raddb/modules/radutmp @@ -12,7 +12,7 @@ radutmp { # Where the file is stored. It's not a log file, # so it doesn't need rotating. @@ -237,8 +247,10 @@ # The field in the packet to key on for the # 'user' name, If you have other fields which you want ---- a/raddb/modules/sradutmp -+++ b/raddb/modules/sradutmp +Index: freeradius-server-2.2.7/raddb/modules/sradutmp +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/modules/sradutmp ++++ freeradius-server-2.2.7/raddb/modules/sradutmp @@ -10,7 +10,7 @@ # then name "sradutmp" to identify it later in the "accounting" # section. @@ -248,8 +260,10 @@ perm = 0644 callerid = "no" } ---- a/raddb/radiusd.conf.in -+++ b/raddb/radiusd.conf.in +Index: freeradius-server-2.2.7/raddb/radiusd.conf.in +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/radiusd.conf.in ++++ freeradius-server-2.2.7/raddb/radiusd.conf.in @@ -66,7 +66,7 @@ name = radiusd # Location of config and logfiles. @@ -277,7 +291,7 @@ # clients = per_socket_clients } -@@ -584,8 +584,8 @@ security { +@@ -576,8 +576,8 @@ security { # # allowed values: {no, yes} # @@ -288,7 +302,7 @@ # CLIENTS CONFIGURATION -@@ -782,7 +782,7 @@ instantiate { +@@ -774,7 +774,7 @@ instantiate { # The entire command line (and output) must fit into 253 bytes. # # e.g. Framed-Pool = `%{exec:/bin/echo foo}` @@ -297,7 +311,7 @@ # # The expression module doesn't do authorization, -@@ -799,15 +799,15 @@ instantiate { +@@ -791,15 +791,15 @@ instantiate { # other xlat functions such as md5, sha1 and lc. # # We do not recommend removing it's listing here. @@ -316,7 +330,7 @@ # subsections here can be thought of as "virtual" modules. # -@@ -831,7 +831,7 @@ instantiate { +@@ -823,7 +823,7 @@ instantiate { # to multiple times. # ###################################################################### @@ -325,7 +339,7 @@ ###################################################################### # -@@ -841,9 +841,9 @@ $INCLUDE policy.conf +@@ -833,9 +833,9 @@ $INCLUDE policy.conf # match the regular expression: /[a-zA-Z0-9_.]+/ # # It allows you to define new virtual servers simply by placing @@ -337,7 +351,7 @@ ###################################################################### # -@@ -851,7 +851,7 @@ $INCLUDE sites-enabled/ +@@ -843,7 +843,7 @@ $INCLUDE sites-enabled/ # "authenticate {}", "accounting {}", have been moved to the # the file: # @@ -346,8 +360,10 @@ # # This is the "default" virtual server that has the same # configuration as in version 1.0.x and 1.1.x. The default ---- a/raddb/sites-available/default -+++ b/raddb/sites-available/default +Index: freeradius-server-2.2.7/raddb/sites-available/default +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/sites-available/default ++++ freeradius-server-2.2.7/raddb/sites-available/default @@ -85,7 +85,7 @@ authorize { # # It takes care of processing the 'raddb/hints' and the @@ -391,7 +407,7 @@ # ntdomain # -@@ -195,8 +195,8 @@ authorize { +@@ -197,8 +197,8 @@ authorize { # Use the checkval module # checkval @@ -402,7 +418,7 @@ # # If no other module has claimed responsibility for -@@ -277,7 +277,7 @@ authenticate { +@@ -279,7 +279,7 @@ authenticate { # If you have a Cisco SIP server authenticating against # FreeRADIUS, uncomment the following line, and the 'digest' # line in the 'authorize' section. @@ -411,7 +427,7 @@ # # Pluggable Authentication Modules. -@@ -294,7 +294,7 @@ authenticate { +@@ -296,7 +296,7 @@ authenticate { # be used for authentication ONLY for compatibility with legacy # FreeRADIUS configurations. # @@ -420,7 +436,7 @@ # Uncomment it if you want to use ldap for authentication # -@@ -330,8 +330,8 @@ authenticate { +@@ -332,8 +332,8 @@ authenticate { # # Pre-accounting. Decide which accounting type to use. # @@ -431,7 +447,7 @@ # # Session start times are *implied* in RADIUS. -@@ -354,7 +354,7 @@ preacct { +@@ -356,7 +356,7 @@ preacct { # # Ensure that we have a semi-unique identifier for every # request, and many NAS boxes are broken. @@ -440,7 +456,7 @@ # # Look for IPASS-style 'realm/', and if not found, look for -@@ -364,13 +364,13 @@ preacct { +@@ -366,13 +366,13 @@ preacct { # Accounting requests are generally proxied to the same # home server as authentication requests. # IPASS @@ -457,7 +473,7 @@ # # Accounting. Log the accounting data. -@@ -380,7 +380,7 @@ accounting { +@@ -382,7 +382,7 @@ accounting { # Create a 'detail'ed log of the packets. # Note that accounting requests which are proxied # are also logged in the detail file. @@ -466,7 +482,7 @@ # daily # Update the wtmp file -@@ -432,7 +432,7 @@ accounting { +@@ -434,7 +434,7 @@ accounting { exec # Filter attributes from the accounting response. @@ -475,7 +491,7 @@ # # See "Autz-Type Status-Server" for how this works. -@@ -458,7 +458,7 @@ session { +@@ -460,7 +460,7 @@ session { # Post-Authentication # Once we KNOW that the user has been authenticated, there are # additional steps we can take. @@ -484,7 +500,7 @@ # Get an address from the IP Pool. # main_pool -@@ -488,7 +488,7 @@ post-auth { +@@ -490,7 +490,7 @@ post-auth { # ldap # For Exec-Program and Exec-Program-Wait @@ -493,7 +509,7 @@ # # Calculate the various WiMAX keys. In order for this to work, -@@ -572,12 +572,12 @@ post-auth { +@@ -574,18 +574,18 @@ post-auth { # Add the ldap module name (or instance) if you have set # 'edir_account_policy_check = yes' in the ldap module configuration # @@ -502,6 +518,13 @@ +# Post-Auth-Type REJECT { +# # log failed authentications in SQL, too. # sql + + # Insert EAP-Failure message if the request was + # rejected by policy instead of because of an + # authentication failure +- eap ++# eap + - attr_filter.access_reject - } -} @@ -511,7 +534,7 @@ # # When the server decides to proxy a request to a home server, -@@ -587,7 +587,7 @@ post-auth { +@@ -595,7 +595,7 @@ post-auth { # # Only a few modules currently have this method. # @@ -520,7 +543,7 @@ # attr_rewrite # Uncomment the following line if you want to change attributes -@@ -603,14 +603,14 @@ pre-proxy { +@@ -611,14 +611,14 @@ pre-proxy { # server, un-comment the following line, and the # 'detail pre_proxy_log' section, above. # pre_proxy_log @@ -537,7 +560,7 @@ # If you want to have a log of replies from a home server, # un-comment the following line, and the 'detail post_proxy_log' -@@ -634,7 +634,7 @@ post-proxy { +@@ -642,7 +642,7 @@ post-proxy { # hidden inside of the EAP packet, and the end server will # reject the EAP request. # @@ -546,15 +569,17 @@ # # If the server tries to proxy a request and fails, then the -@@ -656,5 +656,5 @@ post-proxy { +@@ -664,5 +664,5 @@ post-proxy { # Post-Proxy-Type Fail { # detail # } -} +#} ---- a/raddb/users -+++ b/raddb/users +Index: freeradius-server-2.2.7/raddb/users +=================================================================== +--- freeradius-server-2.2.7.orig/raddb/users ++++ freeradius-server-2.2.7/raddb/users @@ -169,22 +169,22 @@ # by the terminal server in which case there may not be a "P" suffix. # The terminal server sends "Framed-Protocol = PPP" for auto PPP. diff --git a/net/freeradius2/patches/004-ldap_configure.patch b/net/freeradius2/patches/004-ldap_configure.patch index 7f3e24017..05b6789b3 100644 --- a/net/freeradius2/patches/004-ldap_configure.patch +++ b/net/freeradius2/patches/004-ldap_configure.patch @@ -1,5 +1,7 @@ ---- a/src/modules/rlm_ldap/configure -+++ b/src/modules/rlm_ldap/configure +Index: freeradius-server-2.2.7/src/modules/rlm_ldap/configure +=================================================================== +--- freeradius-server-2.2.7.orig/src/modules/rlm_ldap/configure ++++ freeradius-server-2.2.7/src/modules/rlm_ldap/configure @@ -1,10 +1,10 @@ #! /bin/sh # From configure.in Revision. @@ -4239,8 +4241,10 @@ +fi ---- a/src/modules/rlm_ldap/configure.in -+++ b/src/modules/rlm_ldap/configure.in +Index: freeradius-server-2.2.7/src/modules/rlm_ldap/configure.in +=================================================================== +--- freeradius-server-2.2.7.orig/src/modules/rlm_ldap/configure.in ++++ freeradius-server-2.2.7/src/modules/rlm_ldap/configure.in @@ -87,6 +87,9 @@ if test x$with_[]modname != xno; then ) fi diff --git a/net/freeradius2/patches/008-honor_ccpflags.patch b/net/freeradius2/patches/008-honor_ccpflags.patch index 086e71723..7e6d81e04 100644 --- a/net/freeradius2/patches/008-honor_ccpflags.patch +++ b/net/freeradius2/patches/008-honor_ccpflags.patch @@ -1,5 +1,7 @@ ---- a/src/modules/rules.mak -+++ b/src/modules/rules.mak +Index: freeradius-server-2.2.7/src/modules/rules.mak +=================================================================== +--- freeradius-server-2.2.7.orig/src/modules/rules.mak ++++ freeradius-server-2.2.7/src/modules/rules.mak @@ -63,10 +63,10 @@ $(LT_OBJS): $(SERVER_HEADERS) # ####################################################################### diff --git a/net/freeradius2/patches/010-disbale-openssl-check.patch b/net/freeradius2/patches/010-disbale-openssl-check.patch index c254912d4..483221dbc 100644 --- a/net/freeradius2/patches/010-disbale-openssl-check.patch +++ b/net/freeradius2/patches/010-disbale-openssl-check.patch @@ -1,6 +1,8 @@ ---- a/configure.in -+++ b/configure.in -@@ -796,35 +796,6 @@ if test "x$WITH_OPENSSL" = xyes; then +Index: freeradius-server-2.2.7/configure.in +=================================================================== +--- freeradius-server-2.2.7.orig/configure.in ++++ freeradius-server-2.2.7/configure.in +@@ -820,35 +820,6 @@ if test "x$WITH_OPENSSL" = xyes; then OPENSSL_INCLUDE="-DOPENSSL_NO_KRB5" fi diff --git a/net/fwknop/Config.in b/net/fwknop/Config.in new file mode 100644 index 000000000..ee0e62300 --- /dev/null +++ b/net/fwknop/Config.in @@ -0,0 +1,12 @@ +#fwknop config +menu "Configuration" + depends on PACKAGE_fwknopd + +config FWKNOPD_GPG + bool "Enable GPG support" + select PACKAGE_gnupg + default n + + + +endmenu diff --git a/net/fwknop/Makefile b/net/fwknop/Makefile index df16e15f4..13c2681f5 100644 --- a/net/fwknop/Makefile +++ b/net/fwknop/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=fwknop -PKG_VERSION:=2.6.5 -PKG_RELEASE:=1 +PKG_VERSION:=2.6.6 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.cipherdyne.org/fwknop/download -PKG_MD5SUM:=1ae000a499bf604a2aeef4d0a7a178c8 +PKG_MD5SUM:=1372aeaf1e33ab1d6b9906ef9b5cd02e PKG_MAINTAINER:=Jonathan Bennett PKG_LICENSE:=GPLv2 PKG_INSTALL:=1 @@ -42,7 +42,7 @@ define Package/fwknopd CATEGORY:=Network SUBMENU:=Firewall TITLE+= Daemon - DEPENDS:=+iptables +libfko +libpcap + DEPENDS:=+iptables +libfko +libpcap +FWKNOP_GPG:gnupg endef define Package/fwknopd/description @@ -55,6 +55,10 @@ define Package/fwknopd/conffiles /etc/fwknop/fwknopd.conf endef +define Package/fwknopd/config + source "$(SOURCE)/Config.in" +endef + define Package/fwknop $(call Package/fwknop/Default) SECTION:=net @@ -82,8 +86,12 @@ define Package/libfko/description This package contains the libfko shared library. endef + +ifeq ($(CONFIG_FWKNOPD_GPG),n) + CONFIGURE_ARGS += --without-gpgme +endif + CONFIGURE_ARGS += \ - --without-gpgme \ --with-iptables=/usr/sbin/iptables define Build/InstallDev @@ -94,16 +102,21 @@ define Build/InstallDev endef define Package/fwknopd/install + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_CONF) ./files/fwknopd $(1)/etc/config/fwknopd $(INSTALL_DIR) $(1)/etc/fwknop $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/fwknop/{access,fwknopd}.conf \ $(1)/etc/fwknop/ $(INSTALL_DIR) $(1)/etc/init.d - $(INSTALL_BIN) $(PKG_BUILD_DIR)/extras/fwknop.init.openwrt \ - $(1)/etc/init.d/fwknopd + $(INSTALL_BIN) ./files/fwknopd.init $(1)/etc/init.d/fwknopd $(INSTALL_DIR) $(1)/usr/sbin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fwknopd $(1)/usr/sbin/ endef +define Package/fwknopd/conffiles + /etc/config/fwknopd +endef + define Package/fwknop/install $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/fwknop $(1)/usr/bin/ diff --git a/net/fwknop/files/fwknopd b/net/fwknop/files/fwknopd new file mode 100644 index 000000000..0874ee407 --- /dev/null +++ b/net/fwknop/files/fwknopd @@ -0,0 +1,9 @@ +config global +# option uci_enabled '1' + +config access + option SOURCE 'ANY' + option HMAC_KEY 'CHANGEME' + option KEY 'CHANGEME' + +config config diff --git a/net/fwknop/files/fwknopd.init b/net/fwknop/files/fwknopd.init new file mode 100644 index 000000000..4c86493de --- /dev/null +++ b/net/fwknop/files/fwknopd.init @@ -0,0 +1,94 @@ +#!/bin/sh /etc/rc.common +# +# Fwknop is developed primarily by the people listed in the file 'AUTHORS'. +# Copyright (C) 2009-2014 fwknop developers and contributors. For a full +# list of contributors, see the file 'CREDITS'. +# +. /lib/functions.sh +START=95 + +FWKNOPD_BIN=/usr/sbin/fwknopd + +start() +{ + gen_confs + $FWKNOPD_BIN +} + +stop() +{ + $FWKNOPD_BIN -K +} + +restart() +{ + stop; + sleep 1; + start; +} + +reload() +{ + gen_confs + $FWKNOPD_BIN -R +} + +gen_confs() +{ + [ -f /tmp/access.conf.tmp ] && rm /tmp/access.conf.tmp + if [`uci get fwknopd.@access[0].PCAP_INTF` = ""] + then + . /lib/functions/network.sh + network_get_physdev device wan + uci set fwknopd.@config[0].PCAP_INTF="$device" + uci commit + fi + config_cb() { + local type="$1" + local name="$2" + if [ "$type" = "global" ]; then + option_cb() { + local option="$1" + local value="$2" + if [ "$option" = "uci_enabled" ] && [ "$value" -eq 1 ] ; then + > /etc/fwknop/fwknopd.conf + > /etc/fwknop/access.conf + UCI_ENABLED=1 + fi + } + elif [ "$type" = "config" ]; then + option_cb() { + local option="$1" + local value="$2" + if [ $UCI_ENABLED ]; then + echo "$option $value" >> /etc/fwknop/fwknopd.conf #writing each option to fwknopd.conf + fi + } + elif [ "$type" = "access" ] + then + if [ -f /tmp/access.conf.tmp ] ; then + cat /tmp/access.conf.tmp >> /etc/fwknop/access.conf + rm /tmp/access.conf.tmp + fi + option_cb() { + local option="$1" + local value="$2" + if [ $UCI_ENABLED ] && [ $option = "SOURCE" ]; then + echo "$option $value" >> /etc/fwknop/access.conf #writing each option to access.conf + fi + if [ $UCI_ENABLED ] && [ $option != "SOURCE" ]; then + echo "$option $value" >> /tmp/access.conf.tmp #writing each option to access.conf + fi + } + fi + } + + if [ -f /etc/config/fwknopd ]; then + config_load fwknopd + if [ -f /tmp/access.conf.tmp ] ; then + cat /tmp/access.conf.tmp >> /etc/fwknop/access.conf + rm /tmp/access.conf.tmp + fi + fi + +} diff --git a/net/fwknop/patches/001-add-keygen.patch b/net/fwknop/patches/001-add-keygen.patch new file mode 100644 index 000000000..bbc3d992f --- /dev/null +++ b/net/fwknop/patches/001-add-keygen.patch @@ -0,0 +1,427 @@ +diff --git a/CREDITS b/CREDITS +index de17d9e..38e2108 100644 +--- a/CREDITS ++++ b/CREDITS +@@ -1,5 +1,6 @@ + Jonathan Bennett + - Contributed OpenWRT support - see the extras/openwrt/ directory. ++ - Suggested the addition of the --key-gen option to fwknopd. + + Sebastien Jeanquier + - Assisted with getting fwknop included in BackTrack Linux - the choice +diff --git a/ChangeLog b/ChangeLog +index 21a5093..4daf008 100644 +--- a/ChangeLog ++++ b/ChangeLog +@@ -1,3 +1,8 @@ ++fwknop-2.6.7 (05//2015): ++ - Added --key-gen to fwknopd. This feature was suggested by Jonathan ++ Bennett, and will help with ease of use efforts. The first platform to ++ take advantage of this will likely be OpenWRT thanks to Jonathan. ++ + fwknop-2.6.6 (04/23/2015): + - [server] Add the ability for fwknopd to function as an generic SPA + gateway. This allows scenarios such as the fwknopd system providing DHCP +diff --git a/client/config_init.c b/client/config_init.c +index cdb233d..f0ae135 100644 +--- a/client/config_init.c ++++ b/client/config_init.c +@@ -199,7 +199,7 @@ static int critical_var_array[] = + }; + + /** +- * @brief Generate Rijndael + HMAC keys from /dev/random (base64 encoded) and exit. ++ * @brief Generate Rijndael + HMAC keys from /dev/urandom (base64 encoded). + * + * @param options FKO command line option structure + */ +diff --git a/client/fwknop_common.h b/client/fwknop_common.h +index aef20c4..c57db02 100644 +--- a/client/fwknop_common.h ++++ b/client/fwknop_common.h +@@ -69,8 +69,6 @@ + #define MAX_HOSTNAME_LEN 70 + #define MAX_URL_HOST_LEN 256 + #define MAX_URL_PATH_LEN 1024 +-#define MAX_KEY_LEN 128 +-#define MAX_B64_KEY_LEN 180 + + /* fwknop client configuration parameters and values + */ +@@ -156,10 +154,10 @@ typedef struct fko_cli_options + unsigned char use_gpg; + unsigned char use_gpg_agent; + unsigned char gpg_no_signing_pw; ++ unsigned char key_gen; + int time_offset_plus; + int time_offset_minus; + int fw_timeout; +- int key_gen; + + char use_rc_stanza[MAX_LINE_LEN]; + unsigned char got_named_stanza; +diff --git a/common/common.h b/common/common.h +index b63e7c2..c7b2e57 100644 +--- a/common/common.h ++++ b/common/common.h +@@ -157,6 +157,9 @@ enum { + #define MAX_GPG_KEY_ID 128 + #define MAX_USERNAME_LEN 30 + ++#define MAX_KEY_LEN 128 ++#define MAX_B64_KEY_LEN 180 ++ + /* Command line argument / argv handling + */ + #define MAX_CMDLINE_ARGS 30 /*!< should be way more than enough */ +diff --git a/doc/fwknop.man.asciidoc b/doc/fwknop.man.asciidoc +index 070ac77..efa99a7 100644 +--- a/doc/fwknop.man.asciidoc ++++ b/doc/fwknop.man.asciidoc +@@ -196,6 +196,11 @@ GENERAL OPTIONS + keys are generally more secure than passphrases that are typed in from the + command line. + ++*--key-gen-file*='':: ++ Write generated keys to the specified file. Note that the file is ++ overwritten if it already exists. If this option is not given, then ++ *--key-gen* writes the keys to stdout. ++ + *--key-len*='':: + Specify the number of bytes for a generated Rijndael key. The maximum size + is currently 128 bytes. +diff --git a/server/cmd_opts.h b/server/cmd_opts.h +index bc1eee1..d7a645c 100644 +--- a/server/cmd_opts.h ++++ b/server/cmd_opts.h +@@ -141,6 +141,10 @@ enum { + FW_LIST = 0x200, + FW_LIST_ALL, + FW_FLUSH, ++ KEY_GEN_FILE, ++ KEY_LEN, ++ HMAC_KEY_LEN, ++ HMAC_DIGEST_TYPE, + AFL_PKT_FILE, + GPG_HOME_DIR, + GPG_EXE_PATH, +@@ -178,7 +182,12 @@ static struct option cmd_opts[] = + {"fault-injection-tag", 1, NULL, FAULT_INJECTION_TAG}, + {"help", 0, NULL, 'h'}, + {"interface", 1, NULL, 'i'}, +- {"kill", 0, NULL, 'K'}, ++ {"key-gen", 0, NULL, 'k'}, ++ {"key-gen-file", 1, NULL, KEY_GEN_FILE }, ++ {"key-len", 1, NULL, KEY_LEN }, ++ {"hmac-key-len", 1, NULL, HMAC_KEY_LEN }, ++ {"hmac-digest-type", 1, NULL, HMAC_DIGEST_TYPE }, ++ {"kill", 0, NULL, 'K' }, + {"fw-flush", 0, NULL, FW_FLUSH }, + {"fw-list", 0, NULL, FW_LIST }, + {"fw-list-all", 0, NULL, FW_LIST_ALL }, +diff --git a/server/config_init.c b/server/config_init.c +index 0ddceee..2f1d293 100644 +--- a/server/config_init.c ++++ b/server/config_init.c +@@ -201,6 +201,69 @@ validate_int_var_ranges(fko_srv_options_t *opts) + return; + } + ++/** ++ * @brief Generate Rijndael + HMAC keys from /dev/urandom (base64 encoded). ++ * ++ * @param options FKO command line option structure ++ */ ++static void ++generate_keys(fko_srv_options_t *options) ++{ ++ char key_base64[MAX_B64_KEY_LEN+1]; ++ char hmac_key_base64[MAX_B64_KEY_LEN+1]; ++ ++ FILE *key_gen_file_ptr = NULL; ++ int res; ++ ++ /* Set defaults and validate for --key-gen mode ++ */ ++ if(options->key_len == 0) ++ options->key_len = FKO_DEFAULT_KEY_LEN; ++ ++ if(options->hmac_key_len == 0) ++ options->hmac_key_len = FKO_DEFAULT_HMAC_KEY_LEN; ++ ++ if(options->hmac_type == 0) ++ options->hmac_type = FKO_DEFAULT_HMAC_MODE; ++ ++ /* Zero out the key buffers */ ++ memset(key_base64, 0x00, sizeof(key_base64)); ++ memset(hmac_key_base64, 0x00, sizeof(hmac_key_base64)); ++ ++ /* Generate the key through libfko */ ++ res = fko_key_gen(key_base64, options->key_len, ++ hmac_key_base64, options->hmac_key_len, ++ options->hmac_type); ++ ++ if(res != FKO_SUCCESS) ++ { ++ log_msg(LOG_ERR, "%s: fko_key_gen: Error %i - %s", ++ MY_NAME, res, fko_errstr(res)); ++ clean_exit(options, NO_FW_CLEANUP, EXIT_FAILURE); ++ } ++ ++ if(options->key_gen_file[0] != '\0') ++ { ++ if ((key_gen_file_ptr = fopen(options->key_gen_file, "w")) == NULL) ++ { ++ log_msg(LOG_ERR, "Unable to create key gen file: %s: %s", ++ options->key_gen_file, strerror(errno)); ++ clean_exit(options, NO_FW_CLEANUP, EXIT_FAILURE); ++ } ++ fprintf(key_gen_file_ptr, "KEY_BASE64: %s\nHMAC_KEY_BASE64: %s\n", ++ key_base64, hmac_key_base64); ++ fclose(key_gen_file_ptr); ++ fprintf(stdout, "[+] Wrote Rijndael and HMAC keys to: %s", ++ options->key_gen_file); ++ } ++ else ++ { ++ fprintf(stdout, "KEY_BASE64: %s\nHMAC_KEY_BASE64: %s\n", ++ key_base64, hmac_key_base64); ++ } ++ clean_exit(options, NO_FW_CLEANUP, EXIT_SUCCESS); ++} ++ + /* Parse the config file... + */ + static void +@@ -427,7 +490,7 @@ validate_options(fko_srv_options_t *opts) + if(opts->config[CONF_ENABLE_DIGEST_PERSISTENCE] == NULL) + set_config_entry(opts, CONF_ENABLE_DIGEST_PERSISTENCE, + DEF_ENABLE_DIGEST_PERSISTENCE); +- ++ + /* Enable destination rule. + */ + if(opts->config[CONF_ENABLE_DESTINATION_RULE] == NULL) +@@ -928,8 +991,9 @@ config_init(fko_srv_options_t *opts, int argc, char **argv) + + /* First, scan the command-line args for -h/--help or an alternate + * configuration file. If we find an alternate config file, use it, +- * otherwise use the default. We also grab any override config files +- * as well. ++ * otherwise use the default. We also grab any override config files ++ * as well. In addition, we handle key generation here since this is ++ * independent of configuration parsing. + */ + while ((cmd_arg = getopt_long(argc, argv, + GETOPTS_OPTION_STRING, cmd_opts, &index)) != -1) { +@@ -952,6 +1016,45 @@ config_init(fko_srv_options_t *opts, int argc, char **argv) + if(got_override_config > 0) + break; + ++ case 'k': ++ opts->key_gen = 1; ++ break; ++ case KEY_GEN_FILE: ++ opts->key_gen = 1; ++ strlcpy(opts->key_gen_file, optarg, sizeof(opts->key_gen_file)); ++ break; ++ case KEY_LEN: /* used in --key-gen mode only */ ++ opts->key_len = strtol_wrapper(optarg, 1, ++ MAX_KEY_LEN, NO_EXIT_UPON_ERR, &is_err); ++ if(is_err != FKO_SUCCESS) ++ { ++ log_msg(LOG_ERR, ++ "Invalid key length '%s', must be in [%d-%d]", ++ optarg, 1, MAX_KEY_LEN); ++ clean_exit(opts, NO_FW_CLEANUP, EXIT_FAILURE); ++ } ++ break; ++ case HMAC_DIGEST_TYPE: /* used in --key-gen mode only */ ++ if((opts->hmac_type = hmac_digest_strtoint(optarg)) < 0) ++ { ++ log_msg(LOG_ERR, ++ "* Invalid hmac digest type: %s, use {md5,sha1,sha256,sha384,sha512}", ++ optarg); ++ clean_exit(opts, NO_FW_CLEANUP, EXIT_FAILURE); ++ } ++ break; ++ case HMAC_KEY_LEN: /* used in --key-gen mode only */ ++ opts->hmac_key_len = strtol_wrapper(optarg, 1, ++ MAX_KEY_LEN, NO_EXIT_UPON_ERR, &is_err); ++ if(is_err != FKO_SUCCESS) ++ { ++ log_msg(LOG_ERR, ++ "Invalid hmac key length '%s', must be in [%d-%d]", ++ optarg, 1, MAX_KEY_LEN); ++ clean_exit(opts, NO_FW_CLEANUP, EXIT_FAILURE); ++ } ++ break; ++ + /* Look for override configuration file arg. + */ + case 'O': +@@ -965,6 +1068,9 @@ config_init(fko_srv_options_t *opts, int argc, char **argv) + } + } + ++ if(opts->key_gen) ++ generate_keys(opts); ++ + /* If no alternate configuration file was specified, we use the + * default. + */ +diff --git a/server/fwknopd_common.h b/server/fwknopd_common.h +index ecf2a81..8c33eaa 100644 +--- a/server/fwknopd_common.h ++++ b/server/fwknopd_common.h +@@ -585,10 +585,14 @@ typedef struct fko_srv_options + unsigned char fw_list; /* List current firewall rules */ + unsigned char fw_list_all; /* List all current firewall rules */ + unsigned char fw_flush; /* Flush current firewall rules */ ++ unsigned char key_gen; /* Generate keys and exit */ ++ unsigned char exit_after_parse_config; /* Parse config and exit */ ++ ++ /* Operational flags ++ */ + unsigned char test; /* Test mode flag */ + unsigned char afl_fuzzing; /* SPA pkts from stdin for AFL fuzzing */ + unsigned char verbose; /* Verbose mode flag */ +- unsigned char exit_after_parse_config; /* Parse config and exit */ + unsigned char enable_udp_server; /* Enable UDP server mode */ + + unsigned char firewd_disable_check_support; /* Don't use firewall-cmd ... -C */ +@@ -605,6 +609,13 @@ typedef struct fko_srv_options + int tcp_server_pid; + int lock_fd; + ++ /* Values used in --key-gen mode only ++ */ ++ char key_gen_file[MAX_PATH_LEN]; ++ int key_len; ++ int hmac_key_len; ++ int hmac_type; ++ + #if USE_FILE_CACHE + struct digest_cache_list *digest_cache; /* In-memory digest cache list */ + #endif +diff --git a/test/tests/basic_operations.pl b/test/tests/basic_operations.pl +index f4dde2e..76a509d 100644 +--- a/test/tests/basic_operations.pl ++++ b/test/tests/basic_operations.pl +@@ -390,6 +390,14 @@ + 'exec_err' => $YES, + 'cmdline' => "$default_client_args --key-gen -K " . 'A'x1030 + }, ++ { ++ 'category' => 'basic operations', ++ 'subcategory' => 'server', ++ 'detail' => '--key-gen file path (-K) too long', ++ 'function' => \&generic_exec, ++ 'exec_err' => $YES, ++ 'cmdline' => "$fwknopdCmd --key-gen --key-gen-file " . 'A'x1030 ++ }, + + { + 'category' => 'basic operations', +diff --git a/test/tests/rijndael.pl b/test/tests/rijndael.pl +index 26aab6a..34af65e 100644 +--- a/test/tests/rijndael.pl ++++ b/test/tests/rijndael.pl +@@ -421,33 +421,6 @@ + 'key_file' => $cf{'rc_named_key'}, + }, + +- ### --key-gen tests +- { +- 'category' => 'Rijndael', +- 'subcategory' => 'client', +- 'detail' => '--key-gen', +- 'function' => \&generic_exec, +- 'cmdline' => "$fwknopCmd --key-gen", +- 'positive_output_matches' => [qr/^KEY_BASE64\:?\s\S{10}/, +- qw/HMAC_KEY_BASE64\:?\s\S{10}/], +- }, +- { +- 'category' => 'Rijndael', +- 'subcategory' => 'client', +- 'detail' => "--key-gen $uniq_keys key uniqueness", +- 'function' => \&key_gen_uniqueness, +- 'cmdline' => "$fwknopCmd --key-gen", ### no valgrind string (too slow for 100 client exec's) +- 'disable_valgrind' => $YES, +- }, +- { +- 'category' => 'Rijndael', +- 'subcategory' => 'client', +- 'detail' => '--key-gen to file', +- 'function' => \&generic_exec, +- 'cmdline' => "$fwknopCmd --key-gen --key-gen-file $key_gen_file", +- 'positive_output_matches' => [qr/Wrote.*\skeys/], +- }, +- + ### rc file tests + { + 'category' => 'Rijndael', +diff --git a/test/tests/rijndael_hmac.pl b/test/tests/rijndael_hmac.pl +index fc1a8af..fd80f04 100644 +--- a/test/tests/rijndael_hmac.pl ++++ b/test/tests/rijndael_hmac.pl +@@ -58,6 +58,59 @@ + 'exec_err' => $YES, + }, + ++ ### --key-gen tests ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'client', ++ 'detail' => '--key-gen', ++ 'function' => \&generic_exec, ++ 'cmdline' => "$fwknopCmd --key-gen", ++ 'positive_output_matches' => [qr/^KEY_BASE64\:?\s\S{10}/, ++ qw/HMAC_KEY_BASE64\:?\s\S{10}/], ++ }, ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'server', ++ 'detail' => '--key-gen', ++ 'function' => \&generic_exec, ++ 'cmdline' => "$fwknopdCmd --key-gen", ++ 'positive_output_matches' => [qr/^KEY_BASE64\:?\s\S{10}/, ++ qw/HMAC_KEY_BASE64\:?\s\S{10}/], ++ }, ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'client', ++ 'detail' => "--key-gen $uniq_keys key uniqueness", ++ 'function' => \&key_gen_uniqueness, ++ 'cmdline' => "$fwknopCmd --key-gen", ### no valgrind string (too slow for 100 exec's) ++ 'disable_valgrind' => $YES, ++ }, ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'server', ++ 'detail' => "--key-gen $uniq_keys key uniqueness", ++ 'function' => \&key_gen_uniqueness, ++ 'cmdline' => "$fwknopdCmd --key-gen", ### no valgrind string (too slow for 100 exec's) ++ 'disable_valgrind' => $YES, ++ }, ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'client', ++ 'detail' => '--key-gen to file', ++ 'function' => \&generic_exec, ++ 'cmdline' => "$fwknopCmd --key-gen --key-gen-file $key_gen_file", ++ 'positive_output_matches' => [qr/Wrote.*\skeys/], ++ }, ++ { ++ 'category' => 'Rijndael+HMAC', ++ 'subcategory' => 'server', ++ 'detail' => '--key-gen to file', ++ 'function' => \&generic_exec, ++ 'cmdline' => "$fwknopdCmd --key-gen --key-gen-file $key_gen_file", ++ 'positive_output_matches' => [qr/Wrote.*\skeys/], ++ }, ++ ++ ### complete cycle tests + { + 'category' => 'Rijndael+HMAC', + 'subcategory' => 'client+server', diff --git a/net/fwknop/patches/001-fix_config.patch b/net/fwknop/patches/001-fix_config.patch deleted file mode 100644 index 8e5e59088..000000000 --- a/net/fwknop/patches/001-fix_config.patch +++ /dev/null @@ -1,18 +0,0 @@ ---- a/server/fwknopd.conf.inst -+++ b/server/fwknopd.conf.inst -@@ -402,8 +402,13 @@ - # The IPT_FORWARD_ACCESS variable is only used if ENABLE_IPT_FORWARDING is - # enabled. - # --#IPT_FORWARD_ACCESS ACCEPT, filter, FORWARD, 1, FWKNOP_FORWARD, 1; --#IPT_DNAT_ACCESS DNAT, nat, PREROUTING, 1, FWKNOP_PREROUTING, 1; -+ -+# These two lines are changed specifically for Openwrt, due to -+# different naming conventions. IPT_FORWARD is still disabled -+# by default, and must be enabled earlier in this file to be used. -+ -+IPT_FORWARD_ACCESS ACCEPT, filter, zone_wan_forward, 1, FWKNOP_FORWARD, 1; -+IPT_DNAT_ACCESS DNAT, nat, zone_wan_prerouting, 1, FWKNOP_PREROUTING, 1; - - # The IPT_SNAT_ACCESS variable is not used unless both ENABLE_IPT_SNAT and - # ENABLE_IPT_FORWARDING are enabled. Also, the external static IP must be diff --git a/net/fwknop/patches/002-fix_init.patch b/net/fwknop/patches/002-fix_init.patch deleted file mode 100644 index 6370c8e60..000000000 --- a/net/fwknop/patches/002-fix_init.patch +++ /dev/null @@ -1,17 +0,0 @@ ---- a/extras/openwrt/package/fwknop/files/fwknopd.init -+++ b/extras/openwrt/package/fwknop/files/fwknopd.init -@@ -11,12 +11,12 @@ FWKNOPD_BIN=/usr/sbin/fwknopd - - start() - { -- $FWKNOPD_BIN -+ service_start $FWKNOPD_BIN - } - - stop() - { -- $FWKNOPD_BIN -K -+ service_stop $FWKNOPD_BIN -K - } - - restart() diff --git a/net/git/Makefile b/net/git/Makefile index eea0593d7..c088e722e 100644 --- a/net/git/Makefile +++ b/net/git/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2014 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,19 +8,20 @@ include $(TOPDIR)/rules.mk PKG_NAME:=git -PKG_VERSION:=2.3.0 +PKG_VERSION:=2.4.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@KERNEL/software/scm/git/ -PKG_MD5SUM:=e5880760d1f43f4f49b3bf94b9046eee +PKG_MD5SUM:=0b8dc818ed4766342978d744522aec49 PKG_INSTALL:=1 PKG_BUILD_PARALLEL:=1 +PKG_FIXUP:=autoreconf include $(INCLUDE_DIR)/package.mk -define Package/git +define Package/git/Default SECTION:=net CATEGORY:=Network SUBMENU:=Version Control Systems @@ -30,18 +31,35 @@ define Package/git MAINTAINER:=Peter Wagner endef +define Package/git +$(call Package/git/Default) + DEPENDS:=+libopenssl +libpthread +librt + TITLE:=The fast version control system +endef + define Package/git/description Git is a free & open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency. endef +define Package/git-http +$(call Package/git/Default) + DEPENDS:=git +libcurl +ca-certificates + TITLE:=Git HTTP commands +endef + +define Package/git-http/description +$(call Package/git/description) + + This package allows git push/fetch over http(s) and ftp(s) +endef + MAKE_FLAGS := \ CC="$(TARGET_CC)" \ CFLAGS="$(TARGET_CFLAGS)" \ CPPFLAGS="$(TARGET_CPPFLAGS)" \ LDFLAGS="$(TARGET_LDFLAGS)" \ - NO_CURL="YesPlease" \ NO_EXPAT="YesPlease" \ NO_MKSTEMPS="YesPlease" \ NO_GETTEXT="YesPlease" \ @@ -51,21 +69,46 @@ MAKE_FLAGS := \ NO_NSEC="YesPlease" \ NO_PERL="YesPlease" \ NO_PYTHON="YesPlease" \ - NO_TCLTK="YesPlease" + NO_TCLTK="YesPlease" \ + NO_INSTALL_HARDLINKS="yes" \ + +CONFIGURE_ARGS += \ + --without-iconv \ define Build/Configure $(MAKE) -C $(PKG_BUILD_DIR) \ configure - ( cd $(PKG_BUILD_DIR); \ - ./configure --prefix=/usr \ - ); + $(call Build/Configure/Default,) endef define Package/git/install - $(INSTALL_DIR) $(1) + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/git $(1)/usr/bin $(RM) $(PKG_INSTALL_DIR)/usr/bin/git-cvsserver - $(CP) $(PKG_INSTALL_DIR)/* $(1)/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/git-* $(1)/usr/bin + $(INSTALL_DIR) $(1)/usr/lib/git-core + ( cd $(PKG_INSTALL_DIR); $(TAR) \ + --exclude=usr/lib/git-core/git-http-backend \ + --exclude=usr/lib/git-core/git-http-fetch \ + --exclude=usr/lib/git-core/git-remote-ftp \ + --exclude=usr/lib/git-core/git-remote-ftps \ + --exclude=usr/lib/git-core/git-remote-http \ + --exclude=usr/lib/git-core/git-remote-https \ + -cf - \ + usr/lib/git-core \ + ) | ( cd $(1); $(TAR) -xf - ) +endef + +define Package/git-http/install + $(INSTALL_DIR) $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-http-backend $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-http-fetch $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-remote-ftp $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-remote-ftps $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-remote-http $(1)/usr/lib/git-core + $(CP) $(PKG_INSTALL_DIR)/usr/lib/git-core/git-remote-https $(1)/usr/lib/git-core endef $(eval $(call BuildPackage,git)) +$(eval $(call BuildPackage,git-http)) diff --git a/net/git/patches/100-convert_builtin.patch b/net/git/patches/100-convert_builtin.patch index 20199611c..e3d42007d 100644 --- a/net/git/patches/100-convert_builtin.patch +++ b/net/git/patches/100-convert_builtin.patch @@ -1,37 +1,35 @@ --- a/Makefile +++ b/Makefile -@@ -538,16 +538,7 @@ EXTRA_PROGRAMS = +@@ -549,16 +549,7 @@ EXTRA_PROGRAMS = # ... and all the rest that could be moved out of bindir to gitexecdir PROGRAMS += $(EXTRA_PROGRAMS) -PROGRAM_OBJS += credential-store.o -PROGRAM_OBJS += daemon.o -PROGRAM_OBJS += fast-import.o --PROGRAM_OBJS += http-backend.o + PROGRAM_OBJS += http-backend.o -PROGRAM_OBJS += imap-send.o -PROGRAM_OBJS += sh-i18n--envsubst.o -PROGRAM_OBJS += shell.o -PROGRAM_OBJS += show-index.o -PROGRAM_OBJS += upload-pack.o -PROGRAM_OBJS += remote-testsvn.o -+PROGRAM_OBJS = # Binary suffix, set to .exe for Windows builds X = -@@ -896,6 +887,12 @@ BUILTIN_OBJS += builtin/verify-commit.o +@@ -907,6 +898,11 @@ BUILTIN_OBJS += builtin/verify-commit.o BUILTIN_OBJS += builtin/verify-pack.o BUILTIN_OBJS += builtin/verify-tag.o BUILTIN_OBJS += builtin/write-tree.o +BUILTIN_OBJS += builtin/daemon.o +BUILTIN_OBJS += builtin/fast-import.o -+BUILTIN_OBJS += builtin/http-backend.o +BUILTIN_OBJS += builtin/imap-send.o +BUILTIN_OBJS += builtin/shell.o +BUILTIN_OBJS += builtin/upload-pack.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) EXTLIBS = -@@ -1070,7 +1067,7 @@ endif +@@ -1089,7 +1085,7 @@ endif EXTLIBS += -lz ifndef NO_OPENSSL @@ -40,7 +38,7 @@ ifdef OPENSSLDIR BASIC_CFLAGS += -I$(OPENSSLDIR)/include OPENSSL_LINK = -L$(OPENSSLDIR)/$(lib) $(CC_LD_DYNPATH)$(OPENSSLDIR)/$(lib) -@@ -1933,10 +1930,6 @@ endif +@@ -1956,10 +1952,6 @@ endif git-%$X: %.o GIT-LDFLAGS $(GITLIBS) $(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) $(LIBS) @@ -51,7 +49,7 @@ git-http-fetch$X: http.o http-walker.o http-fetch.o GIT-LDFLAGS $(GITLIBS) $(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \ $(LIBS) $(CURL_LIBCURL) -@@ -2254,24 +2247,22 @@ endif +@@ -2277,10 +2269,11 @@ endif bindir=$$(cd '$(DESTDIR_SQ)$(bindir_SQ)' && pwd) && \ execdir=$$(cd '$(DESTDIR_SQ)$(gitexec_instdir_SQ)' && pwd) && \ { test "$$bindir/" = "$$execdir/" || \ @@ -59,34 +57,19 @@ + for p in $(filter $(install_bindir_programs),$(ALL_PROGRAMS)); do \ $(RM) "$$execdir/$$p" && \ test -z "$(NO_INSTALL_HARDLINKS)$(NO_CROSS_DIRECTORY_HARDLINKS)" && \ -- ln "$$bindir/$$p" "$$execdir/$$p" 2>/dev/null || \ + ln "$$bindir/$$p" "$$execdir/$$p" 2>/dev/null || \ + ln -s git "$$execdir/$$p" 2>/dev/null || \ cp "$$bindir/$$p" "$$execdir/$$p" || exit; \ done; \ } && \ - for p in $(filter $(install_bindir_programs),$(BUILT_INS)); do \ - $(RM) "$$bindir/$$p" && \ - test -z "$(NO_INSTALL_HARDLINKS)" && \ -- ln "$$bindir/git$X" "$$bindir/$$p" 2>/dev/null || \ - ln -s "git$X" "$$bindir/$$p" 2>/dev/null || \ - cp "$$bindir/git$X" "$$bindir/$$p" || exit; \ - done && \ - for p in $(BUILT_INS); do \ - $(RM) "$$execdir/$$p" && \ - test -z "$(NO_INSTALL_HARDLINKS)" && \ -- ln "$$execdir/git$X" "$$execdir/$$p" 2>/dev/null || \ - ln -s "git$X" "$$execdir/$$p" 2>/dev/null || \ - cp "$$execdir/git$X" "$$execdir/$$p" || exit; \ - done && \ --- a/builtin.h +++ b/builtin.h -@@ -138,5 +138,11 @@ extern int cmd_verify_pack(int argc, con +@@ -138,5 +138,10 @@ extern int cmd_verify_pack(int argc, con extern int cmd_show_ref(int argc, const char **argv, const char *prefix); extern int cmd_pack_refs(int argc, const char **argv, const char *prefix); extern int cmd_replace(int argc, const char **argv, const char *prefix); +extern int cmd_daemon(int argc, char **argv, const char *prefix); +extern int cmd_fast_import(int argc, char **argv, const char *prefix); -+extern int cmd_http_backend(int argc, char **argv, const char *prefix); +extern int cmd_imap_send(int argc, char **argv, const char *prefix); +extern int cmd_shell(int argc, char **argv, const char *prefix); +extern int cmd_upload_pack(int argc, char **argv, const char *prefix); @@ -101,10 +84,6 @@ @@ -0,0 +1 @@ +#include "../fast-import.c" --- /dev/null -+++ b/builtin/http-backend.c -@@ -0,0 +1 @@ -+#include "../http-backend.c" ---- /dev/null +++ b/builtin/imap-send.c @@ -0,0 +1 @@ +#include "../imap-send.c" @@ -118,7 +97,7 @@ +#include "../upload-pack.c" --- a/daemon.c +++ b/daemon.c -@@ -1096,7 +1096,7 @@ static int serve(struct string_list *lis +@@ -1192,7 +1192,7 @@ static int serve(struct string_list *lis return service_loop(&socklist); } @@ -127,7 +106,7 @@ { int listen_port = 0; struct string_list listen_addr = STRING_LIST_INIT_NODUP; -@@ -1292,12 +1292,13 @@ int main(int argc, char **argv) +@@ -1388,12 +1388,13 @@ int main(int argc, char **argv) store_pid(pid_file); /* prepare argv for serving-processes */ @@ -148,7 +127,7 @@ } --- a/fast-import.c +++ b/fast-import.c -@@ -3350,7 +3350,7 @@ static void parse_argv(void) +@@ -3351,7 +3351,7 @@ static void parse_argv(void) read_marks(); } @@ -159,7 +138,7 @@ --- a/git.c +++ b/git.c -@@ -309,11 +309,11 @@ static int handle_alias(int *argcp, cons +@@ -311,11 +311,11 @@ static int handle_alias(int *argcp, cons struct cmd_struct { const char *cmd; @@ -173,7 +152,7 @@ { int status, help; struct stat st; -@@ -393,6 +393,7 @@ static struct cmd_struct commands[] = { +@@ -395,6 +395,7 @@ static struct cmd_struct commands[] = { { "config", cmd_config, RUN_SETUP_GENTLY }, { "count-objects", cmd_count_objects, RUN_SETUP }, { "credential", cmd_credential, RUN_SETUP_GENTLY }, @@ -181,16 +160,15 @@ { "describe", cmd_describe, RUN_SETUP }, { "diff", cmd_diff }, { "diff-files", cmd_diff_files, RUN_SETUP | NEED_WORK_TREE }, -@@ -411,6 +412,8 @@ static struct cmd_struct commands[] = { +@@ -413,6 +414,7 @@ static struct cmd_struct commands[] = { { "grep", cmd_grep, RUN_SETUP_GENTLY }, { "hash-object", cmd_hash_object }, { "help", cmd_help }, -+ { "http-backend", cmd_http_backend }, + { "imap-send", cmd_imap_send }, { "index-pack", cmd_index_pack, RUN_SETUP_GENTLY }, { "init", cmd_init_db, NO_SETUP }, { "init-db", cmd_init_db, NO_SETUP }, -@@ -459,6 +462,7 @@ static struct cmd_struct commands[] = { +@@ -461,6 +463,7 @@ static struct cmd_struct commands[] = { { "revert", cmd_revert, RUN_SETUP | NEED_WORK_TREE }, { "rm", cmd_rm, RUN_SETUP }, { "send-pack", cmd_send_pack, RUN_SETUP }, @@ -198,7 +176,7 @@ { "shortlog", cmd_shortlog, RUN_SETUP_GENTLY | USE_PAGER }, { "show", cmd_show, RUN_SETUP }, { "show-branch", cmd_show_branch, RUN_SETUP }, -@@ -475,6 +479,7 @@ static struct cmd_struct commands[] = { +@@ -477,6 +480,7 @@ static struct cmd_struct commands[] = { { "update-server-info", cmd_update_server_info, RUN_SETUP }, { "upload-archive", cmd_upload_archive }, { "upload-archive--writer", cmd_upload_archive_writer }, @@ -206,20 +184,9 @@ { "var", cmd_var, RUN_SETUP_GENTLY }, { "verify-commit", cmd_verify_commit, RUN_SETUP }, { "verify-pack", cmd_verify_pack }, ---- a/http-backend.c -+++ b/http-backend.c -@@ -557,7 +557,7 @@ static struct service_cmd { - {"POST", "/git-receive-pack$", service_rpc} - }; - --int main(int argc, char **argv) -+int cmd_http_backend(int argc, char **argv, const char *prefix) - { - char *method = getenv("REQUEST_METHOD"); - char *dir; --- a/imap-send.c +++ b/imap-send.c -@@ -1484,7 +1484,7 @@ static int curl_append_msgs_to_imap(stru +@@ -1492,7 +1492,7 @@ static int curl_append_msgs_to_imap(stru } #endif @@ -241,7 +208,7 @@ const char **user_argv; --- a/upload-pack.c +++ b/upload-pack.c -@@ -793,7 +793,7 @@ static int upload_pack_config(const char +@@ -797,7 +797,7 @@ static int upload_pack_config(const char return parse_hide_refs_config(var, value, "uploadpack"); } diff --git a/net/git/patches/300-configure_for_crosscompiling b/net/git/patches/300-configure_for_crosscompiling new file mode 100644 index 000000000..0ccfaecd0 --- /dev/null +++ b/net/git/patches/300-configure_for_crosscompiling @@ -0,0 +1,32 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -844,7 +844,8 @@ AC_RUN_IFELSE( + FILE *f = fopen(".", "r"); + return f && fread(&c, 1, 1, f)]])], + [ac_cv_fread_reads_directories=no], +- [ac_cv_fread_reads_directories=yes]) ++ [ac_cv_fread_reads_directories=yes], ++ [ac_cv_fread_reads_directories=no]) + ]) + if test $ac_cv_fread_reads_directories = yes; then + FREAD_READS_DIRECTORIES=UnfortunatelyYes +@@ -878,7 +879,8 @@ AC_RUN_IFELSE( + if (snprintf(buf, 3, "%s", "12345") != 5 + || strcmp(buf, "12")) return 1]])], + [ac_cv_snprintf_returns_bogus=no], +- [ac_cv_snprintf_returns_bogus=yes]) ++ [ac_cv_snprintf_returns_bogus=yes], ++ [ac_cv_snprintf_returns_bogus=no]) + ]) + if test $ac_cv_snprintf_returns_bogus = yes; then + SNPRINTF_RETURNS_BOGUS=UnfortunatelyYes +@@ -901,7 +903,8 @@ yippeeyeswehaveit + #endif + ]), + [ac_cv_sane_mode_bits=yes], +- [ac_cv_sane_mode_bits=no]) ++ [ac_cv_sane_mode_bits=no], ++ [ac_cv_sane_mode_bits=yes]) + ]) + if test $ac_cv_sane_mode_bits = yes; then + NEEDS_MODE_TRANSLATION= diff --git a/net/git/patches/400-imapsend_without_curl.patch b/net/git/patches/400-imapsend_without_curl.patch new file mode 100644 index 000000000..e96330c0e --- /dev/null +++ b/net/git/patches/400-imapsend_without_curl.patch @@ -0,0 +1,11 @@ +--- a/Makefile ++++ b/Makefile +@@ -1058,7 +1058,7 @@ else + endif + curl_check := $(shell (echo 072200; curl-config --vernum | sed -e '/^70[BC]/s/^/0/') 2>/dev/null | sort -r | sed -ne 2p) + ifeq "$(curl_check)" "072200" +- USE_CURL_FOR_IMAP_SEND = YesPlease ++# USE_CURL_FOR_IMAP_SEND = YesPlease + endif + ifdef USE_CURL_FOR_IMAP_SEND + BASIC_CFLAGS += -DUSE_CURL_FOR_IMAP_SEND diff --git a/net/gnunet/Makefile b/net/gnunet/Makefile new file mode 100644 index 000000000..8c8dadc74 --- /dev/null +++ b/net/gnunet/Makefile @@ -0,0 +1,247 @@ +# +# Copyright (C) 2015 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:=gnunet +PKG_SOURCE_VERSION:=35991 +PKG_VERSION:=0.10.1-svn$(PKG_SOURCE_VERSION) +PKG_RELEASE:=1 + +# ToDo: +# - break-out transports +# -> get rid of microhttpd and gnurl dependency for gns and vpn +# requires upstream to split config files +# - break-out {peer,name,data}store for each backend +# - package testing stuff + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://gnunet.org/svn/gnunet/ +PKG_SOURCE_PROTO:=svn + +PKG_LICENSE:=GPL-3.0 +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Daniel Golle + +PKG_BUILD_PARALLEL:=1 +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +CONFIGURE_ARGS+= \ + --with-ltdl \ + $(if $(CONFIG_PACKAGE_$(PKG_NAME)-mysql),--with-mysql="$(STAGING_DIR)/usr",--without-mysql) \ + $(if $(CONFIG_PACKAGE_$(PKG_NAME)-pgsql),--with-postgresql="$(STAGING_DIR)/usr/bin/pg_config",--without-postgresql) \ + $(if $(CONFIG_PACKAGE_$(PKG_NAME)-sqlite),--with-sqlite="$(STAGING_DIR)/usr",--without-sqlite) \ + --with-extractor=$(STAGING_DIR)/usr \ + --with-gnutls=$(STAGING_DIR)/usr \ + --with-libgnurl=$(STAGING_DIR)/usr \ + --with-libunistring-prefix=$(STAGING_DIR)/usr \ + --with-microhttpd=$(STAGING_DIR)/usr + +# ToDo: request upstream to provide --with-pulseaudio=... +TARGET_LDFLAGS+= -Wl,-rpath-link=$(STAGING_DIR)/usr/lib/pulseaudio + +define Package/gnunet/Default + SECTION:=net + CATEGORY:=Network + TITLE:=GNUnet + URL:=https://www.gnunet.org/ +endef + +define Package/gnunet +$(call Package/gnunet/Default) + TITLE+= - a peer-to-peer framework focusing on security + DEPENDS:=+ca-certificates +libgnurl +libgnutls +libidn +libltdl \ + +libmicrohttpd +libunistring +librt + USERID:=gnunet=400:gnunet=400 + MENU:=1 +endef + +define Package/gnunet/description + GNUnet is a peer-to-peer framework focusing on security. The first and + primary application for GNUnet is anonymous file-sharing. GNUnet is + currently developed by a worldwide group of independent free software + developers. GNUnet is a GNU package (http://www.gnu.org/). + + This is an ALPHA release. There are known and significant bugs as + well as many missing features in this release. + + This package provides the core components of GNUnet including the + CADET routing engine, a DHT implementation and most transports as well + as their helpers. +endef + +define BuildComponent + define Package/gnunet-$(1) + $$(call Package/gnunet/Default) + TITLE+= $(2) + DEPENDS:=gnunet $(DEPENDS_$(1)) + $(if $(3),DEFAULT:=y if PACKAGE_gnunet) + $(if $(USERID_$(1)),USERID:=$(USERID_$(1))) + endef + + define Package/gnunet-$(1)/install + ( if [ "$(BIN_$(1))" ]; then \ + $(INSTALL_DIR) $$(1)/usr/bin ; \ + for bin in $(BIN_$(1)); do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnunet-$$$$$$$$bin $$(1)/usr/bin/ ; \ + done \ + fi ) + + ( if [ "$(LIB_$(1))" ]; then \ + $(INSTALL_DIR) $$(1)/usr/lib ; \ + for lib in $(LIB_$(1)); do \ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnunet$$$$$$$$lib.so* $$(1)/usr/lib/ ; \ + done \ + fi ) + + ( if [ "$(PLUGIN_$(1))" ]; then \ + $(INSTALL_DIR) $$(1)/usr/lib/gnunet ; \ + for plug in $(PLUGIN_$(1)); do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libgnunet_plugin_$$$$$$$$plug*.so $$(1)/usr/lib/gnunet ; \ + done \ + fi ) + + ( if [ "$(LIBEXEC_$(1))" ]; then \ + $(INSTALL_DIR) $$(1)/usr/lib/gnunet/libexec ; \ + for lex in $(LIBEXEC_$(1)); do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libexec/gnunet-$$$$$$$$lex $$(1)/usr/lib/gnunet/libexec ; \ + done \ + fi ) + + ( if [ "$(CONF_$(1))" ]; then \ + $(INSTALL_DIR) $$(1)/usr/share/gnunet/config.d ; \ + for conf in $(CONF_$(1)); do \ + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/gnunet/config.d/$$$$$$$$conf.conf $$(1)/usr/share/gnunet/config.d ; \ + done \ + fi ) + endef + + $$(eval $$(call BuildPackage,gnunet-$(1))) +endef + +define Package/gnunet/install + $(INSTALL_DIR) $(1)/usr/bin $(1)/usr/lib/gnunet/libexec + $(INSTALL_DIR) $(1)/usr/share/gnunet/config.d $(1)/usr/share/gnunet/hellos + + ( for bin in arm ats core config ecc identity nat-server nse \ + peerinfo peerstore revocation scalarproduct statistics transport uri; do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnunet-$$$$bin $(1)/usr/bin/ ; \ + done ) + + ( for lib in arm ats block cadet core datacache dht \ + dns dnsparser dnsstub fragmentation friends hello identity nat nse \ + peerinfo peerstore regexblock regex revocation scalarproduct set \ + statistics transport util; do \ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnunet$$$$lib.so* $(1)/usr/lib/ ; \ + done ) + + ( for plug in ats_proportional block_dht block_regex datacache_heap \ + transport_http_client transport_http_server \ + transport_https_client transport_https_server \ + transport_tcp transport_udp transport_unix transport_wlan; do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libgnunet_plugin_$$$$plug*.so $(1)/usr/lib/gnunet ; \ + done ) + + ( for lex in daemon-hostlist daemon-topology helper-nat-client \ + helper-nat-server service-arm service-ats service-cadet \ + service-core service-dht service-identity service-nse \ + service-peerinfo service-peerstore service-regex \ + service-revocation service-scalarproduct-alice \ + service-scalarproduct-bob service-set service-statistics \ + service-transport; do \ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libexec/gnunet-$$$$lex $(1)/usr/lib/gnunet/libexec ; \ + done ) + + ( for conf in arm ats cadet core datacache dht hostlist identity \ + nat nse peerinfo peerstore regex revocation scalarproduct \ + set statistics topology transport util; do \ + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/gnunet/config.d/$$$$conf.conf $(1)/usr/share/gnunet/config.d ; \ + done ) + + $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/gnunet/hellos/* $(1)/usr/share/gnunet/hellos + $(INSTALL_DIR) $(1)/etc/init.d/ + $(INSTALL_BIN) ./files/gnunet.init $(1)/etc/init.d/gnunet +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/gnunet $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{la,so}* $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/*.pc $(1)/usr/lib/pkgconfig + $(CP) $(PKG_INSTALL_DIR)/usr/include/gnunet/*.h $(1)/usr/include/gnunet +endef + +DEPENDS_conversation:=+gnunet-gns +libgst1app +libgst1audio +libgstreamer1 +glib2 +pulseaudio-daemon +libopus +libogg +BIN_conversation:=conversation conversation-test +LIB_conversation:=conversation microphone speaker +PLUGIN_conversation:=gnsrecord_conversation +LIBEXEC_conversation:=helper-audio-playback helper-audio-record +CONF_conversation:=conversation + +DEPENDS_experiments:=+libglpk +PLUGIN_experiments:=ats_mlp ats_ril + +DEPENDS_fs:=+gnunet-datastore +libextractor +BIN_fs:=auto-share directory download download-manager.scm fs publish unindex search +LIB_fs:=fs +PLUGIN_fs:=block_fs +LIB_EXEC_fs:=helper-fs-publish service-fs +CONF_fs:=fs + +DEPENDS_gns:=+gnunet-vpn +USERID_gns:=gnunetdns=401:gnunetdns=401 +BIN_gns:=gns gns-import.sh namecache namestore resolver +LIB_gns:=gns gnsrecord namecache namestore +PLUGIN_gns:=block_dns block_gns gnsrecord_dns gnsrecord_gns +LIBEXEC_gns:=dns2gns gns-proxy helper-dns namestore-fcfsd service-dns service-gns service-namecache service-namestore service-resolver +CONF_gns:=dns gns namecache namestore resolver + +DEPENDS_datastore:=+gnunet-gns +libsqlite3 +BIN_datastore:=datastore +LIB_datastore:=datastore +PLUGIN_datastore:=datacache_sqlite datastore_heap datastore_sqlite namecache_sqlite namestore_sqlite peerstore_sqlite +LIBEXEC_datastore:=daemon-latency-logger service-datastore +CONF_datastore:=datastore + +DEPENDS_mysql:=+gnunet-gns +gnunet-datastore +libmysqlclient +LIB_mysql:=mysql +PLUGIN_mysql:=datastore_mysql + +DEPENDS_pgsql:=+gnunet-gns +gnunet-datastore +libpq +LIB_pgsql:=postgres +PLUGIN_pgsql:=datacache_postgres datastore_postgres namecache_postgres namestore_postgres + +DEPENDS_sqlite:=+gnunet-gns +gnunet-datastore +libsqlite3 +PLUGIN_sqlite:=datacache_sqlite datastore_sqlite namecache_sqlite namestore_sqlite peerstore_sqlite + +DEPENDS_transport-bluetooth:=+bluez-libs +PLUGIN_transport-bluetooth:=transport_bluetooth +LIBEXEC_transport-bluetooth:=helper-transport-bluetooth + +DEPENDS_utils:=+certtool +openssl-util +BIN_utils:=config gns-import.sh gns-proxy-setup-ca transport-certificate-creation + +DEPENDS_vpn:=+kmod-tun +LIB_vpn:=tun vpn +LIBEXEC_vpn:=daemon-exit daemon-pt helper-exit helper-vpn service-vpn +CONF_vpn:=exit pt vpn + +$(eval $(call BuildPackage,gnunet)) +$(eval $(call BuildComponent,conversation,conversation component,)) +$(eval $(call BuildComponent,experiments,experimental components,)) +$(eval $(call BuildComponent,fs,file-sharing components,)) +$(eval $(call BuildComponent,gns,name resolution components,y)) +$(eval $(call BuildComponent,datastore,storage components,)) +$(eval $(call BuildComponent,transport-bluetooth,bluetooth transport,)) +$(eval $(call BuildComponent,utils,administration utililties,)) +$(eval $(call BuildComponent,vpn,vpn components,y)) +$(eval $(call BuildComponent,mysql,mySQL datastore backend,)) +$(eval $(call BuildComponent,pgsql,PostgreSQL backends,)) +$(eval $(call BuildComponent,sqlite,libsqlite3 backends,y)) diff --git a/net/gnunet/files/gnunet.init b/net/gnunet/files/gnunet.init new file mode 100644 index 000000000..66e2600d4 --- /dev/null +++ b/net/gnunet/files/gnunet.init @@ -0,0 +1,55 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2015 OpenWrt.org + +START=50 +STOP=10 + +USE_PROCD=1 +PROG=/usr/lib/gnunet/libexec/gnunet-service-arm + +GNUNET_HOME=/var/run/gnunet +CONFIGFILE=$GNUNET_HOME/gnunet.conf +SUID_ROOT_HELPERS="exit nat-server nat-client transport-bluetooth transport-wlan vpn" + +chmodown_execbin() { + execname=/usr/lib/gnunet/libexec/gnunet-$1 + if [ -x $execname ]; then + chmod $2 $execname + [ "$3" ] && chown $3 $execname + fi +} + +fix_libexec_permissions() { + [ -e /usr/share/gnunet/.permfix ] && return + for helper in $SUID_ROOT_HELPERS; do + chmodown_execbin helper-$helper u+s + done + chmodown_execbin helper-dns 4750 root:gnunetdns + chmodown_execbin service-dns 2750 root:gnunetdns + + touch /usr/share/gnunet/.permfix +} + +prepare_config() { + mkdir -p $GNUNET_HOME + chown gnunet:gnunet $GNUNET_HOME + chmod 0750 $GNUNET_HOME + touch $CONFIGFILE + chown root:gnunet $CONFIGFILE + chmod 0640 $CONFIGFILE + gnunet-config -c /tmp/run/gnunet/gnunet.conf -s PATHS -o GNUNET_HOME -V $GNUNET_HOME + defaultservices=$( gnunet-config -c /tmp/run/gnunet/gnunet.conf -s arm -o DEFAULTSERVICES ) + defaultservices="$defaultservices gns2dns" + gnunet-config -c /tmp/run/gnunet/gnunet.conf -s arm -o DEFAULTSERVICES -V "$defaultservices" +} + +start_service() { + fix_libexec_permissions + [ ! -e $GNUNET_HOME ] && prepare_config + + procd_open_instance + procd_set_param user gnunet + procd_set_param command $PROG -c $CONFIGFILE + procd_set_param respawn + procd_close_instance +} diff --git a/net/gnurl/Makefile b/net/gnurl/Makefile new file mode 100644 index 000000000..e1415de21 --- /dev/null +++ b/net/gnurl/Makefile @@ -0,0 +1,119 @@ +# +# Copyright (C) 2007-2015 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:=gnurl +PKG_VERSION:=7.40.0 +PKG_RELEASE:=3 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=https://gnunet.org/sites/default/files + +PKG_MD5SUM:=f816deb0c1401c841780ec6b91985a14 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=COPYING + +PKG_FIXUP:=autoreconf +PKG_BUILD_PARALLEL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/gnurl/Default + SECTION:=net + CATEGORY:=Network + URL:=https://gnunet.org/gnurl + MAINTAINER:=Daniel Golle +endef + +define Package/gnurl + $(call Package/gnurl/Default) + SUBMENU:=File Transfer + DEPENDS:=+libgnurl + TITLE:=A client-side HTTP/HTTPS transfer utility +endef + +define Package/libgnurl + $(call Package/gnurl/Default) + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=+libgnutls +libidn +zlib + TITLE:=A client-side HTTP/HTTPS transfer library +endef + +TARGET_CFLAGS += $(FPIC) + +CONFIGURE_ARGS += \ + $(call autoconf_bool,CONFIG_IPV6,ipv6) \ + --with-gnutls="$(STAGING_DIR)/usr" \ + --with-libidn="$(STAGING_DIR)/usr" \ + --with-zlib="$(STAGING_DIR)/usr" \ + --enable-shared \ + --enable-static \ + --without-axtls \ + --without-libssh2 \ + --without-libmetalink \ + --without-winidn \ + --without-librtmp \ + --without-nghttp2 \ + --without-nss \ + --without-cyassl \ + --without-polarssl \ + --without-ssl \ + --without-winssl \ + --without-darwinssl \ + --disable-ares \ + --disable-sspi \ + --disable-ntlm-wb \ + --disable-ldap \ + --disable-ldaps \ + --disable-rtsp \ + --disable-dict \ + --disable-telnet \ + --disable-tftp \ + --disable-pop3 \ + --disable-imap \ + --disable-smtp \ + --disable-gopher \ + --disable-file \ + --disable-ftp \ + --disable-smb \ + --disable-debug \ + --disable-manual \ + --disable-verbose + +define Build/Compile + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" \ + CC="$(TARGET_CC)" \ + install +endef + +define Build/InstallDev + $(INSTALL_DIR) $(2)/bin $(1)/usr/bin $(1)/usr/include/gnurl $(1)/usr/lib $(1)/usr/lib/pkgconfig + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl-config $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/include/curl/*.h $(1)/usr/include/gnurl + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.{a,so*} $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/libgnurl.pc $(1)/usr/lib/pkgconfig/ + $(SED) 's,-L$$$${exec_prefix}/lib,,g' $(1)/usr/bin/gnurl-config + [ -n "$(TARGET_LDFLAGS)" ] && $(SED) 's#$(TARGET_LDFLAGS)##g' $(1)/usr/lib/pkgconfig/libgnurl.pc || true + $(LN) $(STAGING_DIR)/usr/bin/gnurl-config $(2)/bin/ +endef + +define Package/gnurl/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl $(1)/usr/bin/ +endef + +define Package/libgnurl/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.so.* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,gnurl)) +$(eval $(call BuildPackage,libgnurl)) diff --git a/net/gnurl/patches/100-check_long_long.patch b/net/gnurl/patches/100-check_long_long.patch new file mode 100644 index 000000000..2dd8cc72d --- /dev/null +++ b/net/gnurl/patches/100-check_long_long.patch @@ -0,0 +1,10 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -2885,6 +2885,7 @@ CURL_VERIFY_RUNTIMELIBS + + AC_CHECK_SIZEOF(size_t) + AC_CHECK_SIZEOF(long) ++AC_CHECK_SIZEOF(long long) + AC_CHECK_SIZEOF(int) + AC_CHECK_SIZEOF(short) + CURL_CONFIGURE_LONG diff --git a/net/gnurl/patches/200-no_docs_tests.patch b/net/gnurl/patches/200-no_docs_tests.patch new file mode 100644 index 000000000..6a1fdf5b6 --- /dev/null +++ b/net/gnurl/patches/200-no_docs_tests.patch @@ -0,0 +1,22 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -129,7 +129,7 @@ CLEANFILES = $(VC6_LIBDSP) $(VC6_SRCDSP) $(VC7_LIBVCPROJ) $(VC7_SRCVCPROJ) \ + bin_SCRIPTS = curl-config + + SUBDIRS = lib src include +-DIST_SUBDIRS = $(SUBDIRS) tests packages docs ++DIST_SUBDIRS = $(SUBDIRS) packages + + pkgconfigdir = $(libdir)/pkgconfig + pkgconfig_DATA = libcurl.pc +--- a/Makefile.in ++++ b/Makefile.in +@@ -577,7 +577,7 @@ CLEANFILES = $(VC6_LIBDSP) $(VC6_SRCDSP) $(VC7_LIBVCPROJ) $(VC7_SRCVCPROJ) \ + + bin_SCRIPTS = curl-config + SUBDIRS = lib src include +-DIST_SUBDIRS = $(SUBDIRS) tests packages docs ++DIST_SUBDIRS = $(SUBDIRS) packages + pkgconfigdir = $(libdir)/pkgconfig + pkgconfig_DATA = libcurl.pc + LIB_VTLS_CFILES = vtls/openssl.c vtls/gtls.c vtls/vtls.c vtls/nss.c \ diff --git a/net/haproxy/Makefile b/net/haproxy/Makefile index 38ce8fd5a..cd37fc776 100644 --- a/net/haproxy/Makefile +++ b/net/haproxy/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=haproxy -PKG_VERSION:=1.5.11 -PKG_RELEASE:=02 +PKG_VERSION:=1.5.13 +PKG_RELEASE:=00 PKG_SOURCE:=haproxy-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://haproxy.1wt.eu/download/1.5/src/ PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) -PKG_MD5SUM:=5500a79d0d2b238d4a1e9749bd0c2cb2 +PKG_MD5SUM:=30cf07875ecae4fd6c4c309627afa8f1 PKG_MAINTAINER:=Thomas Heil PKG_LICENSE:=GPL-2.0 @@ -88,7 +88,7 @@ define Build/Compile CFLAGS="$(TARGET_CFLAGS) -fno-align-jumps -fno-align-functions -fno-align-labels -fno-align-loops -pipe -fomit-frame-pointer -fhonour-copts" \ LD="$(TARGET_CC)" \ LDFLAGS="$(TARGET_LDFLAGS)" \ - PCREDIR="$(STAGING_DIR)/usr/include" \ + PCREDIR="$(STAGING_DIR)/usr" \ SMALL_OPTS="-DBUFSIZE=16384 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=165530 " \ USE_LINUX_TPROXY=1 USE_LINUX_SPLICE=1 USE_REGPARM=1 $(USE_OPENSSL) \ USE_ZLIB=yes USE_PCRE=1 \ @@ -96,12 +96,8 @@ define Build/Compile install $(MAKE) -C $(PKG_BUILD_DIR)/contrib/halog \ - DESTDIR="$(PKG_INSTALL_DIR)" \ - CC="$(TARGET_CC)" \ - CFLAGS="$(TARGET_CFLAGS) -fno-align-jumps -fno-align-functions -fno-align-labels -fno-align-loops -pipe -fomit-frame-pointer -fhonour-copts" \ - LD="$(TARGET_CC)" \ - LDFLAGS="$(TARGET_LDFLAGS)" \ - VERSION="$(PKG_VERSION)-patch$(PKG_RELEASE)" \ + CC="$(TARGET_CC) $(TARGET_CFLAGS) $(TARGET_LDFLAGS)" \ + OPTIMIZE="" \ halog endef diff --git a/net/haproxy/patches/0001-BUG-MINOR-pattern-error-message-missing.patch b/net/haproxy/patches/0001-BUG-MINOR-pattern-error-message-missing.patch deleted file mode 100644 index 91b5be6d3..000000000 --- a/net/haproxy/patches/0001-BUG-MINOR-pattern-error-message-missing.patch +++ /dev/null @@ -1,30 +0,0 @@ -From e338a8741983acc9a4501a03ecd593d89e6fade3 Mon Sep 17 00:00:00 2001 -From: Thierry FOURNIER -Date: Fri, 6 Feb 2015 17:50:55 +0100 -Subject: [PATCH 1/2] BUG/MINOR: pattern: error message missing - -This patch must be backported in 1.5 version. -(cherry picked from commit 8aa8384e22dd0b66ded00c70a9c6034278b4bb69) ---- - src/pattern.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) - -diff --git a/src/pattern.c b/src/pattern.c -index 208e33a..a6fc52d 100644 ---- a/src/pattern.c -+++ b/src/pattern.c -@@ -989,8 +989,10 @@ int pat_idx_list_ptr(struct pattern_expr *expr, struct pattern *pat, char **err) - - /* allocate pattern */ - patl = calloc(1, sizeof(*patl)); -- if (!patl) -+ if (!patl) { -+ memprintf(err, "out of memory while indexing pattern"); - return 0; -+ } - - /* duplicate pattern */ - memcpy(&patl->pat, pat, sizeof(*pat)); --- -2.0.4 - diff --git a/net/haproxy/patches/0002-BUG-MEDIUM-pattern-some-entries-are-not-deleted-with.patch b/net/haproxy/patches/0002-BUG-MEDIUM-pattern-some-entries-are-not-deleted-with.patch deleted file mode 100644 index 2a0b7cf5d..000000000 --- a/net/haproxy/patches/0002-BUG-MEDIUM-pattern-some-entries-are-not-deleted-with.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 623401b983185c1e0f6507e96557de3bc46fd41b Mon Sep 17 00:00:00 2001 -From: Thierry FOURNIER -Date: Fri, 6 Feb 2015 17:53:54 +0100 -Subject: [PATCH 2/2] BUG/MEDIUM: pattern: some entries are not deleted with - case insensitive match - -ACL or map entries are not deleted with the command "del acl" or "del map" -if the case insentive flag is set. - -This is because the the case insensitive string are stored in a list and the -default delete function associated with string looks in a tree. I add a check -of the case insensitive flag and execute the delete function for lists if it -is set. - -This patch must be backported in 1.5 version. -(cherry picked from commit 73bc285be194f443dc7eab9c949e87e1dbe8f70c) ---- - src/pattern.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/src/pattern.c b/src/pattern.c -index a6fc52d..b19ffe2 100644 ---- a/src/pattern.c -+++ b/src/pattern.c -@@ -1308,6 +1308,10 @@ void pat_del_tree_str(struct pattern_expr *expr, struct pat_ref_elt *ref) - struct ebmb_node *node, *next_node; - struct pattern_tree *elt; - -+ /* If the flag PAT_F_IGNORE_CASE is set, we cannot use trees */ -+ if (expr->mflags & PAT_MF_IGNORE_CASE) -+ return pat_del_list_ptr(expr, ref); -+ - /* browse each node of the tree. */ - for (node = ebmb_first(&expr->pattern_tree), next_node = node ? ebmb_next(node) : NULL; - node; --- -2.0.4 - diff --git a/net/iodine/Makefile b/net/iodine/Makefile index af97aab58..066399757 100644 --- a/net/iodine/Makefile +++ b/net/iodine/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=iodine PKG_VERSION:=0.7.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://code.kryo.se/iodine/ diff --git a/net/iodine/patches/100-musl-compatibility.patch b/net/iodine/patches/100-musl-compatibility.patch new file mode 100644 index 000000000..17ddc0483 --- /dev/null +++ b/net/iodine/patches/100-musl-compatibility.patch @@ -0,0 +1,26 @@ +commit 9603c1848ddd4d9bb2d6ab031fcef91f543b71a0 +Author: Maxim Storchak +Date: Thu Jun 25 19:38:24 2015 +0300 + + Fix compatibility with musl for OpenWRT + + This patch breaks builds for Windows and Android, but since the only + libc flavors OpenWRT currently cares about are musl, uClibc and glibc, + this should be fine. + + The reason for such brutal intrusiuon is explained in musl FAQ: + http://wiki.musl-libc.org/wiki/FAQ#Q:_why_is_there_no_MUSL_macro_.3F + +diff --git a/src/common.c b/src/common.c +index 2715979..5f0e370 100644 +--- a/src/common.c ++++ b/src/common.c +@@ -57,7 +57,7 @@ + const unsigned char raw_header[RAW_HDR_LEN] = { 0x10, 0xd1, 0x9e, 0x00 }; + + /* daemon(3) exists only in 4.4BSD or later, and in GNU libc */ +-#if !defined(ANDROID) && !defined(WINDOWS32) && !(defined(BSD) && (BSD >= 199306)) && !defined(__GLIBC__) ++#ifdef __UCLIBC__ + static int daemon(int nochdir, int noclose) + { + int fd, i; diff --git a/net/ipsec-tools/Makefile b/net/ipsec-tools/Makefile index 405a95ee2..a1c439e13 100644 --- a/net/ipsec-tools/Makefile +++ b/net/ipsec-tools/Makefile @@ -1,6 +1,6 @@ # -# Copyright (C) 2006-2011 OpenWrt.org -# 2014-2015 Noah Meyerhans +# Copyright (C) 2006-2015 OpenWrt.org +# 2014 Noah Meyerhans # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -11,7 +11,7 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=ipsec-tools PKG_VERSION:=0.8.2 -PKG_RELEASE:=3 +PKG_RELEASE:=4 PKG_MAINTAINER := "Noah Meyerhans " PKG_LICENSE := BSD-3-Clause diff --git a/net/ipsec-tools/patches/002-patch8-utmp.patch b/net/ipsec-tools/patches/002-patch8-utmp.patch index 16dc9237c..547539043 100644 --- a/net/ipsec-tools/patches/002-patch8-utmp.patch +++ b/net/ipsec-tools/patches/002-patch8-utmp.patch @@ -9,7 +9,7 @@ #if defined(__APPLE__) && defined(__MACH__) #include #endif -@@ -1661,7 +1661,8 @@ isakmp_cfg_accounting_system(port, raddr +@@ -1664,7 +1664,8 @@ isakmp_cfg_accounting_system(port, raddr int inout; { int error = 0; @@ -19,7 +19,7 @@ char addr[NI_MAXHOST]; if (usr == NULL || usr[0]=='\0') { -@@ -1670,34 +1671,37 @@ isakmp_cfg_accounting_system(port, raddr +@@ -1673,34 +1674,37 @@ isakmp_cfg_accounting_system(port, raddr return -1; } diff --git a/net/ipsec-tools/patches/003-microsoft-fqdn-in-main.patch b/net/ipsec-tools/patches/003-microsoft-fqdn-in-main.patch index 443d38d5e..7174300da 100644 --- a/net/ipsec-tools/patches/003-microsoft-fqdn-in-main.patch +++ b/net/ipsec-tools/patches/003-microsoft-fqdn-in-main.patch @@ -1,6 +1,6 @@ --- a/src/racoon/ipsec_doi.c +++ b/src/racoon/ipsec_doi.c -@@ -3582,8 +3582,8 @@ ipsecdoi_checkid1(iph1) +@@ -3581,8 +3581,8 @@ ipsecdoi_checkid1(iph1) iph1->approval->authmethod == OAKLEY_ATTR_AUTH_METHOD_PSKEY) { if (id_b->type != IPSECDOI_ID_IPV4_ADDR && id_b->type != IPSECDOI_ID_IPV6_ADDR) { diff --git a/net/ipsec-tools/patches/force_HAVE_POLICY_FWD b/net/ipsec-tools/patches/007-force_have_policy_fwd.patch similarity index 72% rename from net/ipsec-tools/patches/force_HAVE_POLICY_FWD rename to net/ipsec-tools/patches/007-force_have_policy_fwd.patch index 24e64458b..69cd1c039 100644 --- a/net/ipsec-tools/patches/force_HAVE_POLICY_FWD +++ b/net/ipsec-tools/patches/007-force_have_policy_fwd.patch @@ -1,8 +1,6 @@ -diff --git a/configure.ac b/configure.ac -index 8506245..eca8895 100644 --- a/configure.ac +++ b/configure.ac -@@ -724,7 +724,8 @@ case $host in +@@ -732,7 +732,8 @@ case $host in ], [AC_MSG_RESULT(yes) AC_DEFINE([HAVE_POLICY_FWD], [], [Have forward policy])], diff --git a/net/ipsec-tools/patches/008-racoon-fix_dereference_crash.patch b/net/ipsec-tools/patches/008-racoon-fix_dereference_crash.patch new file mode 100644 index 000000000..5e3a2d4dd --- /dev/null +++ b/net/ipsec-tools/patches/008-racoon-fix_dereference_crash.patch @@ -0,0 +1,16 @@ +Fix null dereference in racoon/gssapi.c (CVE-2015-4047) + +--- a/src/racoon/gssapi.c ++++ b/src/racoon/gssapi.c +@@ -192,6 +192,11 @@ gssapi_init(struct ph1handle *iph1) + gss_name_t princ, canon_princ; + OM_uint32 maj_stat, min_stat; + ++ if (iph1->rmconf == NULL) { ++ plog(LLV_ERROR, LOCATION, NULL, "no remote config\n"); ++ return -1; ++ } ++ + gps = racoon_calloc(1, sizeof (struct gssapi_ph1_state)); + if (gps == NULL) { + plog(LLV_ERROR, LOCATION, NULL, "racoon_calloc failed\n"); diff --git a/net/ipsec-tools/patches/009-musl-compat.patch b/net/ipsec-tools/patches/009-musl-compat.patch new file mode 100644 index 000000000..85d03f9ad --- /dev/null +++ b/net/ipsec-tools/patches/009-musl-compat.patch @@ -0,0 +1,187 @@ +--- a/src/racoon/grabmyaddr.c ++++ b/src/racoon/grabmyaddr.c +@@ -47,7 +47,6 @@ + #include + #include + #include +-#include + #define USE_ROUTE + #endif + +--- a/src/racoon/pfkey.c ++++ b/src/racoon/pfkey.c +@@ -59,7 +59,6 @@ + #include + #include + #include +-#include + + #include + #include +--- a/src/setkey/setkey.c ++++ b/src/setkey/setkey.c +@@ -40,7 +40,6 @@ + #include + #include + #include +-#include + #include + #include + #include +--- a/src/libipsec/ipsec_strerror.h ++++ b/src/libipsec/ipsec_strerror.h +@@ -34,6 +34,8 @@ + #ifndef _IPSEC_STRERROR_H + #define _IPSEC_STRERROR_H + ++#include ++ + extern int __ipsec_errcode; + extern void __ipsec_set_strerror __P((const char *)); + +--- a/src/libipsec/libpfkey.h ++++ b/src/libipsec/libpfkey.h +@@ -34,6 +34,8 @@ + #ifndef _LIBPFKEY_H + #define _LIBPFKEY_H + ++#include ++ + #ifndef KAME_LIBPFKEY_H + #define KAME_LIBPFKEY_H + +--- a/src/racoon/backupsa.c ++++ b/src/racoon/backupsa.c +@@ -276,9 +276,9 @@ do { \ + GETNEXTNUM(sa_args.a_keylen, strtoul); + GETNEXTNUM(sa_args.flags, strtoul); + GETNEXTNUM(sa_args.l_alloc, strtoul); +- GETNEXTNUM(sa_args.l_bytes, strtouq); +- GETNEXTNUM(sa_args.l_addtime, strtouq); +- GETNEXTNUM(sa_args.l_usetime, strtouq); ++ GETNEXTNUM(sa_args.l_bytes, strtoull); ++ GETNEXTNUM(sa_args.l_addtime, strtoull); ++ GETNEXTNUM(sa_args.l_usetime, strtoull); + GETNEXTNUM(sa_args.seq, strtoul); + + #undef GETNEXTNUM +--- a/src/racoon/cftoken.l ++++ b/src/racoon/cftoken.l +@@ -77,6 +77,10 @@ + + #include "cfparse.h" + ++#ifndef GLOB_TILDE ++#define GLOB_TILDE 0 ++#endif ++ + int yyerrorcount = 0; + + #if defined(YIPS_DEBUG) +--- a/src/racoon/logger.h ++++ b/src/racoon/logger.h +@@ -34,6 +34,8 @@ + #ifndef _LOGGER_H + #define _LOGGER_H + ++#include ++ + struct log { + int head; + int siz; +--- a/src/racoon/misc.h ++++ b/src/racoon/misc.h +@@ -34,6 +34,8 @@ + #ifndef _MISC_H + #define _MISC_H + ++#include ++ + #define BIT2STR(b) bit2str(b, sizeof(b)<<3) + + #ifdef HAVE_FUNC_MACRO +--- a/src/racoon/missing/crypto/sha2/sha2.h ++++ b/src/racoon/missing/crypto/sha2/sha2.h +@@ -40,6 +40,8 @@ + #ifndef __SHA2_H__ + #define __SHA2_H__ + ++#include ++ + #ifdef __cplusplus + extern "C" { + #endif +--- a/src/racoon/netdb_dnssec.h ++++ b/src/racoon/netdb_dnssec.h +@@ -34,6 +34,8 @@ + #ifndef _NETDB_DNSSEC_H + #define _NETDB_DNSSEC_H + ++#include ++ + #ifndef T_CERT + #define T_CERT 37 /* defined by RFC2538 section 2 */ + #endif +--- a/src/racoon/plog.h ++++ b/src/racoon/plog.h +@@ -34,6 +34,8 @@ + #ifndef _PLOG_H + #define _PLOG_H + ++#include ++ + #ifdef HAVE_STDARG_H + #include + #else +--- a/src/racoon/str2val.h ++++ b/src/racoon/str2val.h +@@ -34,6 +34,8 @@ + #ifndef _STR2VAL_H + #define _STR2VAL_H + ++#include ++ + extern caddr_t val2str __P((const char *, size_t)); + extern char *str2val __P((const char *, int, size_t *)); + +--- a/src/racoon/vmbuf.h ++++ b/src/racoon/vmbuf.h +@@ -34,6 +34,8 @@ + #ifndef _VMBUF_H + #define _VMBUF_H + ++#include ++ + /* + * bp v + * v v +--- a/src/setkey/extern.h ++++ b/src/setkey/extern.h +@@ -1,6 +1,6 @@ + /* $NetBSD: extern.h,v 1.5 2009/03/06 11:45:03 tteras Exp $ */ + +- ++#include + + void parse_init __P((void)); + int parse __P((FILE **)); +--- a/src/racoon/isakmp_cfg.c ++++ b/src/racoon/isakmp_cfg.c +@@ -1694,8 +1694,6 @@ isakmp_cfg_accounting_system(port, raddr + "Accounting : '%s' logging on '%s' from %s.\n", + ut.ut_name, ut.ut_line, ut.ut_host); + +- login(&ut); +- + break; + case ISAKMP_CFG_LOGOUT: + +@@ -1703,8 +1701,6 @@ isakmp_cfg_accounting_system(port, raddr + "Accounting : '%s' unlogging from '%s'.\n", + usr, term); + +- logout(term); +- + break; + default: + plog(LLV_ERROR, LOCATION, NULL, "Unepected inout\n"); diff --git a/net/keepalived/Makefile b/net/keepalived/Makefile index 0f13149d4..b68c726bc 100644 --- a/net/keepalived/Makefile +++ b/net/keepalived/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=keepalived -PKG_VERSION:=1.2.15 -PKG_RELEASE:=1 +PKG_VERSION:=1.2.16 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:= http://www.keepalived.org/software -PKG_MD5SUM:=d85fcb8e564ea03b0ca7b2357bf30c51 +PKG_MD5SUM:=f834ab2cfc2e7300edf1bafaf4a5d83e PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING diff --git a/net/keepalived/patches/100-musl-compat.patch b/net/keepalived/patches/100-musl-compat.patch new file mode 100644 index 000000000..9668c2bb2 --- /dev/null +++ b/net/keepalived/patches/100-musl-compat.patch @@ -0,0 +1,10 @@ +--- a/lib/utils.h ++++ b/lib/utils.h +@@ -31,6 +31,7 @@ + #include + #include + #include ++#include + #include + #include + diff --git a/net/knot/Makefile b/net/knot/Makefile index d35fb7f94..fa32c6554 100644 --- a/net/knot/Makefile +++ b/net/knot/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=knot -PKG_VERSION:=1.6.2 +PKG_VERSION:=1.6.3 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE_URL:=https://secure.nic.cz/files/knot-dns/ -PKG_MD5SUM:=ad0a2d641556ad30d17d45200a2c45df +PKG_MD5SUM:=fb744b50493ac7e724d5228ade2e35b1 PKG_MAINTAINER:=Daniel Salzman PKG_LICENSE:=GPL-2.0+ diff --git a/net/knot/patches/03_zscanner_tests.patch b/net/knot/patches/03_zscanner_tests.patch index 279df2799..a0d052421 100644 --- a/net/knot/patches/03_zscanner_tests.patch +++ b/net/knot/patches/03_zscanner_tests.patch @@ -34,8 +34,8 @@ index 846f351..272856c 100644 TESTS_DIR="$SOURCE"/data ZSCANNER_TOOL="$BUILD"/zscanner-tool --plan 69 -+plan 67 +-plan 71 ++plan 69 mkdir -p "$TMPDIR"/includes/ for a in 1 2 3 4 5 6; do diff --git a/net/knxd/Makefile b/net/knxd/Makefile index cbf5ab18a..238840629 100644 --- a/net/knxd/Makefile +++ b/net/knxd/Makefile @@ -11,34 +11,34 @@ include $(TOPDIR)/rules.mk PKG_NAME:=knxd -PKG_REV:=9cdcf0f25d34ed7939ecc41029caf6213581baa8 -PKG_VERSION:=2015-02-13 +PKG_VERSION=2015-06-27-$(PKG_SOURCE_VERSION) PKG_RELEASE:=1 +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/knxd/knxd.git +PKG_SOURCE_VERSION:=50e7f6e6bfa13c2b6140b0f76aaa70234bf44b1d +PKG_SOURCE_SUBDIR:=$(PKG_NAME) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz + PKG_MAINTAINER:=Othmar Truniger + PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=LICENSE - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_PROTO:=git -PKG_SOURCE_URL:=git://github.com/Makki1/knxd.git -PKG_SOURCE_SUBDIR:=$(PKG_NAME) -PKG_SOURCE_VERSION:=$(PKG_REV) - +PKG_BUILD_PARALLEL:=1 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) -PKG_BUILD_DEPENDS:=pthsem argp-standalone +PKG_BUILD_DEPENDS:=argp-standalone PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk define Package/knxd SECTION:=net CATEGORY:=Network - TITLE:=Eib KNX deamon - URL:=https://github.com/Makki1/knxd - DEPENDS:=pthsem libusb-1.0 + TITLE:=EIB KNX daemon + DEPENDS:=+pthsem +libusb-1.0 endef define Package/knxd/description @@ -49,105 +49,104 @@ define Package/knxd/conffiles /etc/config/knxd endef +define Package/libeibclient + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Library for EIB clients + DEPENDS:=+pthsem +endef + +define Package/libeibclient/description +EIB KNX client library +endef + define Package/knxd-tools SECTION:=net CATEGORY:=Network - TITLE:=Eib KNX Utils - URL:=https://github.com/Makki1/knxd - DEPENDS:=pthsem libusb-1.0 + TITLE:=EIB KNX Utils + DEPENDS:=+libeibclient endef define Package/knxd-tools/description EIB KNX Tools endef -define Build/Prepare - $(call Build/Prepare/Default) -endef - -define Build/Configure - $(call Build/Configure/Default,\ - --disable-ft12 \ - --enable-eibnetip \ - --enable-eibnetiptunnel \ - --enable-eibnetipserver \ - --enable-usb \ - --enable-tpuart \ - --enable-tpuarts \ - --disable-pei16 \ - --disable-pei16s \ - --enable-groupcache \ - --without-pth-test \ - --without-libstdc ) -endef +CONFIGURE_ARGS+= \ + --disable-ft12 \ + --enable-eibnetip \ + --enable-eibnetiptunnel \ + --enable-eibnetipserver \ + --enable-usb \ + --enable-tpuart \ + --enable-tpuarts \ + --disable-pei16 \ + --disable-pei16s \ + --enable-groupcache \ + --without-pth-test \ + --without-libstdc + +EXTRA_LDFLAGS+= \ + -fno-builtin -nodefaultlibs -lc -lgcc + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) $(PKG_INSTALL_DIR)/usr/include/eib*.h $(1)/usr/include/ -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - CC=$(TARGET_CC) \ - LIBS="-L$(STAGING_DIR)/lib -L$(STAGING_DIR)/usr/lib -fno-builtin -nodefaultlibs -lc -lm -lgcc -largp -lpthsem" \ - CPPFLAGS="-I$(STAGING_DIR)/include -I$(STAGING_DIR)/usr/include" + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libeibclient.{a,so*} $(1)/usr/lib/ endef define Package/knxd/install $(INSTALL_DIR) $(1)/usr/bin - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/server/knxd $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/tools/bcu/bcuaddrtab $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/tools/bcu/bcuread $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/tools/eibnet/eibnetsearch $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/tools/eibnet/eibnetdescribe $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/usb/findknxusb $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/ + $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/knxd.init $(1)/etc/init.d/knxd + $(INSTALL_DIR) $(1)/etc/config $(INSTALL_DATA) ./files/knxd.config $(1)/etc/config/knxd endef -define Package/knxd-tools/install +define Package/libeibclient/install $(INSTALL_DIR) $(1)/usr/lib - $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/client/c/.libs/libeibclient.so.0.0.0 $(1)/usr/lib/ - ln -s libeibclient.so.0.0.0 $(1)/usr/lib/libeibclient.so - ln -s libeibclient.so.0.0.0 $(1)/usr/lib/libeibclient.so.0 + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libeibclient.so* $(1)/usr/lib/ +endef + +define Package/knxd-tools/install $(INSTALL_DIR) $(1)/usr/bin - -rm -f $(1)/usr/bin/knxread - -rm -f $(1)/usr/bin/knxreadtemp - -rm -f $(1)/usr/bin/knxwrite - -rm -f $(1)/usr/bin/knxlog - -rm -f $(1)/usr/bin/knxon - -rm -f $(1)/usr/bin/knxoff - -rm -f $(1)/usr/bin/knxif - -rm -f $(1)/usr/bin/knxswrite - -rm -f $(1)/usr/bin/knxbool - -rm -f $(1)/usr/bin/knxdimup - ln -s knxtool $(1)/usr/bin/knxread - ln -s knxtool $(1)/usr/bin/knxreadtemp - ln -s knxtool $(1)/usr/bin/knxwrite - ln -s knxtool $(1)/usr/bin/knxlog - ln -s knxtool $(1)/usr/bin/knxon - ln -s knxtool $(1)/usr/bin/knxoff - ln -s knxtool $(1)/usr/bin/knxif - ln -s knxtool $(1)/usr/bin/knxswrite - ln -s knxtool $(1)/usr/bin/knxbool - ln -s knxtool $(1)/usr/bin/knxdimup - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/knxtool $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/busmonitor1 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/busmonitor2 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/busmonitor3 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/eibread-cgi $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/eibwrite-cgi $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/vbusmonitor1 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/vbusmonitor2 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/vbusmonitor3 $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupwrite $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupswrite $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/grouplisten $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupread $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupresponse $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupreadresponse $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupsocketlisten $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupsocketread $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupsocketwrite $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/examples/.libs/groupsocketswrite $(1)/usr/bin/ + + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/knxtool $(1)/usr/bin/ + ln -sf knxtool $(1)/usr/bin/knxread + ln -sf knxtool $(1)/usr/bin/knxreadtemp + ln -sf knxtool $(1)/usr/bin/knxwrite + ln -sf knxtool $(1)/usr/bin/knxlog + ln -sf knxtool $(1)/usr/bin/knxon + ln -sf knxtool $(1)/usr/bin/knxoff + ln -sf knxtool $(1)/usr/bin/knxif + ln -sf knxtool $(1)/usr/bin/knxswrite + ln -sf knxtool $(1)/usr/bin/knxbool + ln -sf knxtool $(1)/usr/bin/knxdimup + + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/busmonitor1 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/busmonitor2 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/busmonitor3 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/eibread-cgi $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/eibwrite-cgi $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/vbusmonitor1 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/vbusmonitor2 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/vbusmonitor3 $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupwrite $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupswrite $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/grouplisten $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupread $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupresponse $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupreadresponse $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupsocketlisten $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupsocketread $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupsocketwrite $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/share/knxd/examples/bin/groupsocketswrite $(1)/usr/bin/ endef $(eval $(call BuildPackage,knxd)) +$(eval $(call BuildPackage,libeibclient)) $(eval $(call BuildPackage,knxd-tools)) diff --git a/net/knxd/files/knxd.init b/net/knxd/files/knxd.init index 31e909169..026e4cf6a 100644 --- a/net/knxd/files/knxd.init +++ b/net/knxd/files/knxd.init @@ -6,8 +6,6 @@ STOP=20 NAME=knxd PROG=/usr/bin/$NAME -. /lib/functions.sh - start() { local options url config_load "$NAME" @@ -19,4 +17,3 @@ start() { stop() { service_stop $PROG } - diff --git a/net/knxd/patches/0099-openwrt.patch b/net/knxd/patches/0099-openwrt.patch index fd73c0555..f7e33ed10 100644 --- a/net/knxd/patches/0099-openwrt.patch +++ b/net/knxd/patches/0099-openwrt.patch @@ -1,5 +1,5 @@ ---- knxd/src/client/Makefile.am.orig 2014-12-21 20:17:14.000000000 +0100 -+++ knxd/src/client/Makefile.am 2014-12-21 20:18:50.639995000 +0100 +--- a/src/client/Makefile.am 2014-12-21 20:17:14.000000000 +0100 ++++ b/src/client/Makefile.am 2014-12-21 20:18:50.639995000 +0100 @@ -4,5 +4,5 @@ BUILDJAVA = endif diff --git a/net/knxd/patches/0100-musl-compat b/net/knxd/patches/0100-musl-compat new file mode 100644 index 000000000..0c2a09b24 --- /dev/null +++ b/net/knxd/patches/0100-musl-compat @@ -0,0 +1,10 @@ +--- a/src/examples/common.h 2015-06-27 15:20:15.266563893 +0200 ++++ b/src/examples/common.h 2015-06-27 15:23:09.406457392 +0200 +@@ -20,6 +20,7 @@ + #include + #include + #include ++#include + #include "eibclient.h" + + /** unsigned char*/ diff --git a/net/krb5/Makefile b/net/krb5/Makefile index c0de8524a..5f6907032 100644 --- a/net/krb5/Makefile +++ b/net/krb5/Makefile @@ -79,6 +79,7 @@ CONFIGURE_VARS += \ ac_cv_file__etc_TIMEZONE=no CONFIGURE_ARGS += \ + --without-system-verto \ --without-tcl \ --without-libedit \ --localstatedir=/etc diff --git a/net/lftp/Makefile b/net/lftp/Makefile index 8a4819cc0..01ea99820 100644 --- a/net/lftp/Makefile +++ b/net/lftp/Makefile @@ -8,11 +8,16 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lftp -PKG_VERSION:=4.6.0 +PKG_VERSION:=4.6.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=http://lftp.yar.ru/ftp \ http://lftp.cybermirror.org \ http://lftp.cybermirror.org/old -PKG_MD5SUM:=fc5f4e3b45c9011a193eb8c0c12eb2eb +PKG_SOURCE_URL:=http://lftp.yar.ru/ftp \ + http://lftp.yar.ru/ftp/old \ + http://lftp.cybermirror.org \ + http://lftp.cybermirror.org/old +PKG_MD5SUM:=487c064ee1bd732e5f95928e530435a8 + + PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=COPYING diff --git a/net/linknx/Makefile b/net/linknx/Makefile index e3aed3b15..3af3842be 100644 --- a/net/linknx/Makefile +++ b/net/linknx/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=linknx PKG_VERSION:=0.0.1.32 -PKG_RELEASE:=4 +PKG_RELEASE:=7 PKG_MD5SUM:=7ecc1208f59bceb05068c752b2250b63 PKG_MAINTAINER:=Othmar Truniger @@ -17,7 +17,8 @@ PKG_LICENSE:=GPL-2.0+ PKG_SOURCE_URL:=@SF/linknx PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_BUILD_DEPENDS:=pthsem curl libesmtp +PKG_BUILD_DEPENDS:=argp-standalone +PKG_FORTIFY_SOURCE:=1 include $(INCLUDE_DIR)/package.mk @@ -26,26 +27,19 @@ define Package/linknx CATEGORY:=Network TITLE:=KNX home automation platform URL:=http://sourceforge.net/projects/linknx/ - DEPENDS:=pthsem +lua +luac +libstdcpp +libcurl +libesmtp + DEPENDS:=+pthsem +lua +luac +libstdcpp +libcurl +libesmtp endef -define Build/Configure - (cd $(PKG_BUILD_DIR); touch aclocal.m4 Makefile.in config.h.in configure; \ - $(SED) 's,\"2.0.4\",\"2.0.4\"\n_pth_version=\"2.0.8\",g' $(PKG_BUILD_DIR)/configure ) - $(call Build/Configure/Default,--verbose --without-pth-test --with-pth=$(STAGING_DIR) --without-log4cpp --with-lua --with-libcurl --without-mysql, \ - CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -lcrypt" \ - ) -endef +CONFIGURE_ARGS+= \ + --verbose \ + --without-pth-test \ + --without-log4cpp \ + --with-lua \ + --with-libcurl \ + --without-mysql -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR)/ \ - LIBDIR="$(TARGET_LDFLAGS)" \ - CC="$(TARGET_CC) $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) " \ - LD="$(TARGET_CROSS)ld -shared" \ - LUA="$(STAGING_DIR_HOST)/bin/lua" \ - LUAC="$(STAGING_DIR_HOST)/bin/luac" \ - CFLAGS="$(TARGET_CFLAGS) -nodefaultlibs" all -endef +EXTRA_LDFLAGS+= \ + -fno-builtin define Package/linknx/install $(INSTALL_DIR) $(1)/usr/bin diff --git a/net/linknx/patches/010-musl-compat b/net/linknx/patches/010-musl-compat new file mode 100644 index 000000000..15c757ee0 --- /dev/null +++ b/net/linknx/patches/010-musl-compat @@ -0,0 +1,10 @@ +--- a/src/eibclient.c 2007-10-11 01:55:31.000000000 +0200 ++++ b/src/eibclient.c 2015-06-27 22:18:01.433296921 +0200 +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + + #include "config.h" + diff --git a/net/linknx/patches/012-fix-linknx.cpp b/net/linknx/patches/012-fix-linknx.cpp new file mode 100644 index 000000000..8394cf12e --- /dev/null +++ b/net/linknx/patches/012-fix-linknx.cpp @@ -0,0 +1,11 @@ +--- a/src/linknx.cpp 2012-06-04 22:12:13.000000000 +0200 ++++ b/src/linknx.cpp 2015-06-27 22:35:23.705721355 +0200 +@@ -136,7 +136,7 @@ + if (errno) + printf (": %s\n", strerror (errno)); + else +- printf ("\n", strerror (errno)); ++ printf ("\n"); + exit (1); + } + diff --git a/net/lksctp-tools/Makefile b/net/lksctp-tools/Makefile new file mode 100644 index 000000000..0d652920b --- /dev/null +++ b/net/lksctp-tools/Makefile @@ -0,0 +1,92 @@ +# +# Copyright (C) 2010-2015 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:=lksctp-tools +PKG_VERSION:=1.0.16 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=@SF/lksctp +PKG_MD5SUM:=708bb0b5a6806ad6e8d13c55b067518e + +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Nicolas Thill + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/lksctp-tools/Default + SECTION:=net + CATEGORY:=Network + TITLE:=SCTP user-land + URL:=http://lksctp.sourceforge.net +endef + +define Package/libsctp +$(call Package/lksctp-tools/Default) + SUBMENU:=Networking + SECTION:=libs + CATEGORY:=Libraries + TITLE+= library + URL:=http://lksctp.sourceforge.net + DEPENDS:=+kmod-sctp +endef + +define Package/sctp +$(call Package/lksctp-tools/Default) + TITLE+= (meta) + URL:=http://lksctp.sourceforge.net + DEPENDS:=+libsctp +sctp-tools +endef + +define Package/sctp-tools +$(call Package/lksctp-tools/Default) + TITLE+= tools + URL:=http://lksctp.sourceforge.net + DEPENDS:=+libsctp +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/netinet \ + $(STAGING_DIR)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libsctp.{a,so*} \ + $(1)/usr/lib/ +endef + +define Package/libsctp/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libsctp.so.* \ + $(1)/usr/lib/ +endef + +define Package/sctp/install + : +endef + +define Package/sctp-tools/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) \ + $(PKG_INSTALL_DIR)/usr/bin/checksctp \ + $(1)/usr/bin/ + $(CP) \ + $(PKG_INSTALL_DIR)/usr/bin/sctp_{darn,status,test} \ + $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,libsctp)) +$(eval $(call BuildPackage,sctp)) +$(eval $(call BuildPackage,sctp-tools)) diff --git a/net/luci-app-clamav/Makefile b/net/luci-app-clamav/Makefile new file mode 100644 index 000000000..fed8e63a7 --- /dev/null +++ b/net/luci-app-clamav/Makefile @@ -0,0 +1,53 @@ +# +# Copyright (C) 2015 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:=luci-app-clamav +PKG_RELEASE:=20150520 + +PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) + +PKG_LICENSE:=Apache-2.0 +PKG_MAINTAINER:=Marko Ratkaj + +include $(INCLUDE_DIR)/package.mk + +define Package/luci-app-clamav + SECTION:=luci + CATEGORY:=LuCI + SUBMENU:=3. Applications + TITLE:=ClamAV Web UI + DEPENDS:=+luci-mod-admin-full +clamav +endef + +define Package/luci-app-clamav/description + This package will install ClamAV Web UI. +endef + +define Build/Prepare +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Package/luci-app-clamav/install + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/controller/ + $(INSTALL_BIN) \ + ./files/controller/clamav-controller.lua \ + $(1)/usr/lib/lua/luci/controller/clamav.lua + + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/model/cbi/ + $(INSTALL_BIN) \ + ./files/model/cbi/clamav-cbi.lua \ + $(1)/usr/lib/lua/luci/model/cbi/clamav.lua +endef + +$(eval $(call BuildPackage,luci-app-clamav)) diff --git a/net/luci-app-clamav/files/controller/clamav-controller.lua b/net/luci-app-clamav/files/controller/clamav-controller.lua new file mode 100644 index 000000000..02f3bfc4b --- /dev/null +++ b/net/luci-app-clamav/files/controller/clamav-controller.lua @@ -0,0 +1,22 @@ +--[[ + +LuCI ClamAV module + +Copyright (C) 2015, Itus Networks, Inc. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + Luka Perkov + +]]-- + +module("luci.controller.clamav", package.seeall) + +function index() + entry({"admin", "services", "clamav"}, cbi("clamav"), _("ClamAV")) +end diff --git a/net/luci-app-clamav/files/model/cbi/clamav-cbi.lua b/net/luci-app-clamav/files/model/cbi/clamav-cbi.lua new file mode 100644 index 000000000..ff98139d4 --- /dev/null +++ b/net/luci-app-clamav/files/model/cbi/clamav-cbi.lua @@ -0,0 +1,178 @@ +--[[ + +LuCI ClamAV module + +Copyright (C) 2015, Itus Networks, Inc. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + Luka Perkov + +]]-- + +local fs = require "nixio.fs" +local sys = require "luci.sys" +require "ubus" + +m = Map("clamav", translate("ClamAV")) +m.on_after_commit = function() luci.sys.call("/etc/init.d/clamav restart") end + +s = m:section(TypedSection, "clamav") +s.anonymous = true +s.addremove = false + +s:tab("tab_advanced", translate("Settings")) +s:tab("tab_logs", translate("Log")) + +--------------- Settings -------------- + +LogFileMaxSize = s:taboption("tab_advanced", Value, "LogFileMaxSize", translate("Max size of log file")) +LogFileMaxSize:value("512K", translate("512K")) +LogFileMaxSize:value("1M", translate("1M")) +LogFileMaxSize:value("2M", translate("2M")) +LogFileMaxSize.default = "1M" + +LogTime = s:taboption("tab_advanced", ListValue, "LogTime", translate("Log time with each message")) +LogTime:value("no", translate("No")) +LogTime:value("yes", translate("Yes")) +LogTime.default = "no" + +LogVerbose = s:taboption("tab_advanced", ListValue, "LogVerbose", translate("Enable verbose logging")) +LogVerbose:value("no", translate("No")) +LogVerbose:value("yes", translate("Yes")) +LogVerbose.default = "no" + +ExtendedDetectionInfo = s:taboption("tab_advanced", ListValue, "ExtendedDetectionInfo", translate("Log additional infection info")) +ExtendedDetectionInfo:value("no", translate("No")) +ExtendedDetectionInfo:value("yes", translate("Yes")) +ExtendedDetectionInfo.default = "no" + +dummy3 = s:taboption("tab_advanced", DummyValue, "") +dummy4 = s:taboption("tab_advanced", DummyValue, "") + +MaxDirectoryRecursion = s:taboption("tab_advanced", Value, "MaxDirectoryRecursion", translate("Max directory scan depth")) +MaxDirectoryRecursion:value("15", translate("15")) +MaxDirectoryRecursion:value("20", translate("20")) +MaxDirectoryRecursion.default = "15" + +FollowDirectorySymlink = s:taboption("tab_advanced", ListValue, "FollowDirectorySymlink", translate("Follow directory symlinks")) +FollowDirectorySymlink:value("no", translate("No")) +FollowDirectorySymlink:value("yes", translate("Yes")) +FollowDirectorySymlink.default = "no" + +FollowFileSymlinks = s:taboption("tab_advanced", ListValue, "FollowFileSymlinks", translate("Follow file symlinks")) +FollowFileSymlinks:value("no", translate("No")) +FollowFileSymlinks:value("yes", translate("Yes")) +FollowFileSymlinks.default = "no" + +DetectPUA = s:taboption("tab_advanced", ListValue, "DetectPUA", translate("Detect possibly unwanted apps")) +DetectPUA:value("no", translate("No")) +DetectPUA:value("yes", translate("Yes")) +DetectPUA.default = "no" + +ScanPE = s:taboption("tab_advanced", ListValue, "ScanPE", translate("Scan portable executables")) +ScanPE:value("no", translate("No")) +ScanPE:value("yes", translate("Yes")) +ScanPE.default = "yes" + +ScanELF = s:taboption("tab_advanced", ListValue, "ScanELF", translate("Scan ELF files")) +ScanELF:value("no", translate("No")) +ScanELF:value("yes", translate("Yes")) +ScanELF.default = "yes" + +DetectBrokenExecutables = s:taboption("tab_advanced", ListValue, "DetectBrokenExecutables", translate("Detect broken executables")) +DetectBrokenExecutables:value("no", translate("No")) +DetectBrokenExecutables:value("yes", translate("Yes")) +DetectBrokenExecutables.default = "no" + +ScanOLE2 = s:taboption("tab_advanced", ListValue, "ScanOLE2", translate("Scan MS Office and .msi files")) +ScanOLE2:value("no", translate("No")) +ScanOLE2:value("yes", translate("Yes")) +ScanOLE2.default = "yes" + +ScanPDF = s:taboption("tab_advanced", ListValue, "ScanPDF", translate("Scan pdf files")) +ScanPDF:value("no", translate("No")) +ScanPDF:value("yes", translate("Yes")) +ScanPDF.default = "yes" + +ScanSWF = s:taboption("tab_advanced", ListValue, "ScanSWF", translate("Scan swf files")) +ScanSWF:value("no", translate("No")) +ScanSWF:value("yes", translate("Yes")) +ScanSWF.default = "yes" + +ScanMail = s:taboption("tab_advanced", ListValue, "ScanMail", translate("Scan emails")) +ScanMail:value("no", translate("No")) +ScanMail:value("yes", translate("Yes")) +ScanMail.default = "yes" + +ScanPartialMessages = s:taboption("tab_advanced", ListValue, "ScanPartialMessages", translate("Scan RFC1341 messages split over many emails")) +ScanPartialMessages:value("no", translate("No")) +ScanPartialMessages:value("yes", translate("Yes")) +ScanPartialMessages.default = "no" + +ScanArchive = s:taboption("tab_advanced", ListValue, "ScanArchive", translate("Scan archives")) +ScanArchive:value("no", translate("No")) +ScanArchive:value("yes", translate("Yes")) +ScanArchive.default = "yes" + +ArchiveBlockEncrypted = s:taboption("tab_advanced", ListValue, "ArchiveBlockEncrypted", translate("Block encrypted archives")) +ArchiveBlockEncrypted:value("no", translate("No")) +ArchiveBlockEncrypted:value("yes", translate("Yes")) +ArchiveBlockEncrypted.default = "no" + +dummy5 = s:taboption("tab_advanced", DummyValue, "") +dummy6 = s:taboption("tab_advanced", DummyValue, "") + +StreamMinPort = s:taboption("tab_advanced", Value, "StreamMinPort", translate("Port range, lowest port")) +StreamMinPort.datatype = "portrange" +StreamMinPort:value("1024",translate("1024")) +StreamMinPort.default = "1024" + +StreamMaxPort = s:taboption("tab_advanced", Value, "StreamMaxPort", translate("Port range, highest port")) +StreamMaxPort.datatype = "portrange" +StreamMaxPort:value("2048",translate("2048")) +StreamMaxPort.default = "2048" + +MaxThreads = s:taboption("tab_advanced", Value, "MaxThreads", translate("Max number of threads")) +MaxThreads.datatype = "and(uinteger,min(1))" +MaxThreads:value("10",translate("10")) +MaxThreads:value("20",translate("20")) +MaxThreads.default = "10" + +SelfCheck = s:taboption("tab_advanced", Value, "SelfCheck", translate("Database check every N sec")) +SelfCheck.datatype = "and(uinteger,min(1))" +SelfCheck:value("600",translate("600")) +SelfCheck.default = "600" + +MaxFileSize = s:taboption("tab_advanced", Value, "MaxFileSize", translate("Max size of scanned file")) +MaxFileSize.datatype = "string" +MaxFileSize:value("150M",translate("150M")) +MaxFileSize:value("50M",translate("50M")) +MaxFileSize.default = "150M" + +------------------ Log -------------------- + +clamav_logfile = s:taboption("tab_logs", TextValue, "lines", "") +clamav_logfile.wrap = "off" +clamav_logfile.rows = 25 +clamav_logfile.rmempty = true + +function clamav_logfile.cfgvalue() + local uci = require "luci.model.uci".cursor_state() + local file = "/tmp/clamd.log" + if file then + return fs.readfile(file) or "" + else + return "" + end +end + +function clamav_logfile.write() +end + +return m diff --git a/net/luci-app-e2guardian/Makefile b/net/luci-app-e2guardian/Makefile new file mode 100644 index 000000000..880f373bd --- /dev/null +++ b/net/luci-app-e2guardian/Makefile @@ -0,0 +1,53 @@ +# +# Copyright (C) 2015 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:=luci-app-e2guardian +PKG_RELEASE:=20150520 + +PKG_LICENSE:=Apache-2.0 + +PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) + +include $(INCLUDE_DIR)/package.mk + +define Package/luci-app-e2guardian + SECTION:=luci + CATEGORY:=LuCI + SUBMENU:=3. Applications + TITLE:=E2Guardian Web UI + DEPENDS:=+luci-mod-admin-full +e2guardian + MAINTAINER:=Marko Ratkaj +endef + +define Package/luci-app-e2guardian/description + This package will install E2Guardian Web UI. +endef + +define Build/Prepare +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Package/luci-app-e2guardian/install + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/controller/ + $(INSTALL_BIN) \ + ./files/e2guardian-controller.lua \ + $(1)/usr/lib/lua/luci/controller/e2guardian.lua + + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/model/cbi/ + $(INSTALL_BIN) \ + ./files//e2guardian-cbi.lua \ + $(1)/usr/lib/lua/luci/model/cbi/e2guardian.lua +endef + +$(eval $(call BuildPackage,luci-app-e2guardian)) diff --git a/net/luci-app-e2guardian/files/e2guardian-cbi.lua b/net/luci-app-e2guardian/files/e2guardian-cbi.lua new file mode 100644 index 000000000..a943115b8 --- /dev/null +++ b/net/luci-app-e2guardian/files/e2guardian-cbi.lua @@ -0,0 +1,399 @@ +--[[ + +LuCI E2Guardian module + +Copyright (C) 2015, Itus Networks, Inc. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + Luka Perkov + +]]-- + +local fs = require "nixio.fs" +local sys = require "luci.sys" + +m = Map("e2guardian", translate("E2Guardian")) +m.on_after_commit = function() luci.sys.call("/etc/init.d/e2guardian restart") end + +s = m:section(TypedSection, "e2guardian") +s.anonymous = true +s.addremove = false + +s:tab("tab_general", translate("General Settings")) +s:tab("tab_additional", translate("Additional Settings")) +s:tab("tab_logs", translate("Logs")) + + +----------------- General Settings Tab ----------------------- + +filterip = s:taboption("tab_general", Value, "filterip", translate("IP that E2Guardian listens")) +filterip.datatype = "ip4addr" + +filterports = s:taboption("tab_general", Value, "filterports", translate("Port that E2Guardian listens")) +filterports.datatype = "portrange" +filterports.placeholder = "0-65535" + +proxyip = s:taboption("tab_general", Value, "proxyip", translate("IP address of the proxy")) +proxyip.datatype = "ip4addr" +proxyip.default = "127.0.0.1" + +proxyport = s:taboption("tab_general", Value, "proxyport", translate("Port of the proxy")) +proxyport.datatype = "portrange" +proxyport.placeholder = "0-65535" + +languagedir = s:taboption("tab_general", Value, "languagedir", translate("Language dir")) +languagedir.datatype = "string" +languagedir.default = "/usr/share/e2guardian/languages" + +language = s:taboption("tab_general", Value, "language", translate("Language to use")) +language.datatype = "string" +language.default = "ukenglish" + +loglevel = s:taboption("tab_general", ListValue, "loglevel", translate("Logging Settings")) +loglevel:value("0", translate("none")) +loglevel:value("1", translate("just denied")) +loglevel:value("2", translate("all text based")) +loglevel:value("3", translate("all requests")) +loglevel.default = "2" + +logexceptionhits = s:taboption("tab_general", ListValue, "logexceptionhits", translate("Log Exception Hits")) +logexceptionhits:value("0", translate("never")) +logexceptionhits:value("1", translate("log, but dont mark as exceptions")) +logexceptionhits:value("2", translate("log and mark")) +logexceptionhits.default = "2" + +logfileformat = s:taboption("tab_general", ListValue, "logfileformat", translate("Log File Format")) +logfileformat:value("1", translate("DansgGuardian format, space delimited")) +logfileformat:value("2", translate("CSV-style format")) +logfileformat:value("3", translate("Squid Log File Format")) +logfileformat:value("4", translate("Tab delimited")) +logfileformat:value("5", translate("Protex format")) +logfileformat:value("6", translate("Protex format with server field blanked")) +logfileformat.default = "1" + +accessdeniedaddress = s:taboption("tab_general", Value, "accessdeniedaddress", translate("Access denied address"), +translate("Server to which the cgi e2guardian reporting script was copied. Reporting levels 1 and 2 only")) +accessdeniedaddress.datatype = "string" +accessdeniedaddress.default = "http://YOURSERVER.YOURDOMAIN/cgi-bin/e2guardian.pl" + +usecustombannedimage = s:taboption("tab_general", ListValue, "usecustombannedimage", translate("Banned image replacement")) +usecustombannedimage:value("on", translate("Yes")) +usecustombannedimage:value("off", translate("No")) +usecustombannedimage.default = "on" + +custombannedimagefile = s:taboption("tab_general", Value, "custombannedimagefile", translate("Custom banned image file")) +custombannedimagefile.datatype = "string" +custombannedimagefile.default = "/usr/share/e2guardian/transparent1x1.gif" + +usecustombannedflash = s:taboption("tab_general", ListValue, "usecustombannedflash", translate("Banned flash replacement")) +usecustombannedflash:value("on", translate("Yes")) +usecustombannedflash:value("off", translate("No")) +usecustombannedflash.default = "on" + +custombannedflashfile = s:taboption("tab_general", Value, "custombannedflashfile", translate("Custom banned flash file")) +custombannedflashfile.datatype = "string" +custombannedflashfile.default = "/usr/share/e2guardian/blockedflash.swf" + +filtergroups = s:taboption("tab_general", Value, "filtergroups", translate("Number of filter groups")) +filtergroups.datatype = "and(uinteger,min(1))" +filtergroups.default = "1" + +filtergroupslist = s:taboption("tab_general", Value, "filtergroupslist", translate("List of filter groups")) +filtergroupslist.datatype = "string" +filtergroupslist.default = "/etc/e2guardian/lists/filtergroupslist" + +bannediplist = s:taboption("tab_general", Value, "bannediplist", translate("List of banned IPs")) +bannediplist.datatype = "string" +bannediplist.default = "/etc/e2guardian/lists/bannediplist" + +exceptioniplist = s:taboption("tab_general", Value, "exceptioniplist", translate("List of IP exceptions")) +exceptioniplist.datatype = "string" +exceptioniplist.default = "/etc/e2guardian/lists/exceptioniplist" + +perroomblockingdirectory = s:taboption("tab_general", Value, "perroomblockingdirectory", translate("Per-Room blocking definition directory")) +perroomblockingdirectory.datatype = "string" +perroomblockingdirectory.default = "/etc/e2guardian/lists/bannedrooms/" + +showweightedfound = s:taboption("tab_general", ListValue, "showweightedfound", translate("Show weighted phrases found")) +showweightedfound:value("on", translate("Yes")) +showweightedfound:value("off", translate("No")) +showweightedfound.default = "on" + +weightedphrasemode = s:taboption("tab_general", ListValue, "weightedphrasemode", translate("Weighted phrase mode")) +weightedphrasemode:value("0", translate("off")) +weightedphrasemode:value("1", translate("on, normal operation")) +weightedphrasemode:value("2", translate("on, phrase found only counts once on a page")) +weightedphrasemode.default = "2" + +urlcachenumber = s:taboption("tab_general", Value, "urlcachenumber", translate("Clean result caching for URLs")) +urlcachenumber.datatype = "and(uinteger,min(0))" +urlcachenumber.default = "1000" + +urlcacheage = s:taboption("tab_general", Value, "urlcacheage", translate("Age before they should be ignored in seconds")) +urlcacheage.datatype = "and(uinteger,min(0))" +urlcacheage.default = "900" + +scancleancache = s:taboption("tab_general", ListValue, "scancleancache", translate("Cache for content (AV) scans as 'clean'")) +scancleancache:value("on", translate("Yes")) +scancleancache:value("off", translate("No")) +scancleancache.default = "on" + +phrasefiltermode = s:taboption("tab_general", ListValue, "phrasefiltermode", translate("Filtering options")) +phrasefiltermode:value("0", translate("raw")) +phrasefiltermode:value("1", translate("smart")) +phrasefiltermode:value("2", translate("both raw and smart")) +phrasefiltermode:value("3", translate("meta/title")) +phrasefiltermode.default = "2" + +preservecase = s:taboption("tab_general", ListValue, "perservecase", translate("Lower caseing options")) +preservecase:value("0", translate("force lower case")) +preservecase:value("1", translate("dont change")) +preservecase:value("2", translate("scan fist in lower, then in original")) +preservecase.default = "0" + +hexdecodecontent = s:taboption("tab_general", ListValue, "hexdecodecontent", translate("Hex decoding options")) +hexdecodecontent:value("on", translate("Yes")) +hexdecodecontent:value("off", translate("No")) +hexdecodecontent.default = "off" + +forcequicksearch = s:taboption("tab_general", ListValue, "forcequicksearch", translate("Quick search")) +forcequicksearch:value("on", translate("Yes")) +forcequicksearch:value("off", translate("No")) +forcequicksearch.default = "off" + +reverseaddresslookups= s:taboption("tab_general", ListValue, "reverseaddresslookups", translate("Reverse lookups for banned site and URLs")) +reverseaddresslookups:value("on", translate("Yes")) +reverseaddresslookups:value("off", translate("No")) +reverseaddresslookups.default = "off" + +reverseclientiplookups = s:taboption("tab_general", ListValue, "reverseclientiplookups", translate("Reverse lookups for banned and exception IP lists")) +reverseclientiplookups:value("on", translate("Yes")) +reverseclientiplookups:value("off", translate("No")) +reverseclientiplookups.default = "off" + +logclienthostnames = s:taboption("tab_general", ListValue, "logclienthostnames", translate("Perform reverse lookups on client IPs for successful requests")) +logclienthostnames:value("on", translate("Yes")) +logclienthostnames:value("off", translate("No")) +logclienthostnames.default = "off" + +createlistcachefiles = s:taboption("tab_general", ListValue, "createlistcachefiles", translate("Build bannedsitelist and bannedurllist cache files")) +createlistcachefiles:value("on",translate("Yes")) +createlistcachefiles:value("off",translate("No")) +createlistcachefiles.default = "on" + +prefercachedlists = s:taboption("tab_general", ListValue, "prefercachedlists", translate("Prefer cached list files")) +prefercachedlists:value("on", translate("Yes")) +prefercachedlists:value("off", translate("No")) +prefercachedlists.default = "off" + +maxuploadsize = s:taboption("tab_general", Value, "maxuploadsize", translate("Max upload size (in Kbytes)")) +maxuploadsize:value("-1", translate("no blocking")) +maxuploadsize:value("0", translate("complete block")) +maxuploadsize.default = "-1" + +maxcontentfiltersize = s:taboption("tab_general", Value, "maxcontentfiltersize", translate("Max content filter size"), +translate("The value must not be higher than max content ram cache scan size or 0 to match it")) +maxcontentfiltersize.datatype = "and(uinteger,min(0))" +maxcontentfiltersize.default = "256" + +maxcontentramcachescansize = s:taboption("tab_general", Value, "maxcontentramcachescansize", translate("Max content ram cache scan size"), +translate("This is the max size of file that DG will download and cache in RAM")) +maxcontentramcachescansize.datatype = "and(uinteger,min(0))" +maxcontentramcachescansize.default = "2000" + +maxcontentfilecachescansize = s:taboption("tab_general", Value, "maxcontentfilecachescansize", translate("Max content file cache scan size")) +maxcontentfilecachescansize.datatype = "and(uinteger,min(0))" +maxcontentfilecachescansize.default = "20000" + +proxytimeout = s:taboption("tab_general", Value, "proxytimeout", translate("Proxy timeout (5-100)")) +proxytimeout.datatype = "range(5,100)" +proxytimeout.default = "20" + +proxyexchange = s:taboption("tab_general", Value, "proxyexchange", translate("Proxy header excahnge (20-300)")) +proxyexchange.datatype = "range(20,300)" +proxyexchange.default = "20" + +pcontimeout = s:taboption("tab_general", Value, "pcontimeout", translate("Pconn timeout"), +translate("How long a persistent connection will wait for other requests")) +pcontimeout.datatype = "range(5,300)" +pcontimeout.default = "55" + +filecachedir = s:taboption("tab_general", Value, "filecachedir", translate("File cache directory")) +filecachedir.datatype = "string" +filecachedir.default = "/tmp" + +deletedownloadedtempfiles = s:taboption("tab_general", ListValue, "deletedownloadedtempfiles", translate("Delete file cache after user completes download")) +deletedownloadedtempfiles:value("on", translate("Yes")) +deletedownloadedtempfiles:value("off", translate("No")) +deletedownloadedtempfiles.default = "on" + +initialtrickledelay = s:taboption("tab_general", Value, "initialtrickledelay", translate("Initial Trickle delay"), +translate("Number of seconds a browser connection is left waiting before first being sent *something* to keep it alive")) +initialtrickledelay.datatype = "and(uinteger,min(0))" +initialtrickledelay.default = "20" + +trickledelay = s:taboption("tab_general", Value, "trickledelay", translate("Trickle delay"), +translate("Number of seconds a browser connection is left waiting before being sent more *something* to keep it alive")) +trickledelay.datatype = "and(uinteger,min(0))" +trickledelay.default = "10" + +downloadmanager = s:taboption("tab_general", Value, "downloadmanager", translate("Download manager")) +downloadmanager.datatype = "string" +downloadmanager.default = "/etc/e2guardian/downloadmanagers/default.conf" + +contentscannertimeout = s:taboption("tab_general", Value, "contentscannertimeout", translate("Content scanner timeout")) +contentscannertimeout.datatype = "and(uinteger,min(0))" +contentscannertimeout.default = "60" + +contentscanexceptions = s:taboption("tab_general", ListValue, "contentscanexceptions", translate("Content scan exceptions")) +contentscanexceptions:value("on", translate("Yes")) +contentscanexceptions:value("off", translate("No")) +contentscanexceptions.default = "off" + +recheckreplacedurls = s:taboption("tab_general", ListValue, "recheckreplacedurls", translate("e-check replaced URLs")) +recheckreplacedurls:value("on", translate("Yes")) +recheckreplacedurls:value("off", translate("No")) +recheckreplacedurls.default = "off" + +forwardedfor = s:taboption("tab_general", ListValue, "forwardedfor", translate("Misc setting: forwardedfor"), +translate("If on, it may help solve some problem sites that need to know the source ip.")) +forwardedfor:value("on", translate("Yes")) +forwardedfor:value("off", translate("No")) +forwardedfor.default = "off" + +usexforwardedfor = s:taboption("tab_general", ListValue, "usexforwardedfor", translate("Misc setting: usexforwardedfor"), +translate("This is for when you have squid between the clients and E2Guardian")) +usexforwardedfor:value("on", translate("Yes")) +usexforwardedfor:value("off", translate("No")) +usexforwardedfor.default = "off" + +logconnectionhandlingerrors = s:taboption("tab_general", ListValue, "logconnectionhandlingerrors", translate("Log debug info about log()ing and accept()ing")) +logconnectionhandlingerrors:value("on", translate("Yes")) +logconnectionhandlingerrors:value("off", translate("No")) +logconnectionhandlingerrors.default = "on" + +logchildprocesshandling = s:taboption("tab_general", ListValue, "logchildprocesshandling", translate("Log child process handling")) +logchildprocesshandling:value("on", translate("Yes")) +logchildprocesshandling:value("off", translate("No")) +logchildprocesshandling.default = "off" + +maxchildren = s:taboption("tab_general", Value, "maxchildren", translate("Max number of processes to spawn")) +maxchildren.datatype = "and(uinteger,min(0))" +maxchildren.default = "180" + +minchildren = s:taboption("tab_general", Value, "minchildren", translate("Min number of processes to spawn")) +minchildren.datatype = "and(uinteger,min(0))" +minchildren.default = "20" + +minsparechildren = s:taboption("tab_general", Value, "minsparechildren", translate("Min number of processes to keep ready")) +minsparechildren.datatype = "and(uinteger,min(0))" +minsparechildren.default = "16" + +preforkchildren = s:taboption("tab_general", Value, "preforkchildren", translate("Sets minimum nuber of processes when it runs out")) +preforkchildren.datatype = "and(uinteger,min(0))" +preforkchildren.default = "10" + +maxsparechildren = s:taboption("tab_general", Value, "maxsparechildren", translate("Sets the maximum number of processes to have doing nothing")) +maxsparechildren.datatype = "and(uinteger,min(0))" +maxsparechildren.default = "32" + +maxagechildren = s:taboption("tab_general", Value, "maxagechildren", translate("Max age of child process")) +maxagechildren.datatype = "and(uinteger,min(0))" +maxagechildren.default = "500" + +maxips = s:taboption("tab_general", Value, "maxips", translate("Max number of clinets allowed to connect")) +maxips:value("0", translate("no limit")) +maxips.default = "0" + +ipipcfilename = s:taboption("tab_general", Value, "ipipcfilename", translate("IP list IPC server directory and filename")) +ipipcfilename.datatype = "string" +ipipcfilename.default = "/tmp/.dguardianipc" + +urlipcfilename = s:taboption("tab_general", Value, "urlipcfilename", translate("Defines URL list IPC server directory and filename used to communicate with the URL cache process")) +urlipcfilename.datatype = "string" +urlipcfilename.default = "/tmp/.dguardianurlipc" + +ipcfilename = s:taboption("tab_general", Value, "ipcfilename", translate("Defines URL list IPC server directory and filename used to communicate with the URL cache process")) +ipcfilename.datatype = "string" +ipcfilename.default = "/tmp/.dguardianipipc" + +nodeamon = s:taboption("tab_general", ListValue, "nodeamon", translate("Disable deamoning")) +nodeamon:value("on", translate("Yes")) +nodeamon:value("off", translate("No")) +nodeamon.default = "off" + +nologger = s:taboption("tab_general", ListValue, "nologger", translate("Disable logger")) +nologger:value("on", translate("Yes")) +nologger:value("off", translate("No")) +nologger.default = "off" + +logadblock = s:taboption("tab_general", ListValue, "logadblock", translate("Enable logging of ADs")) +logadblock:value("on", translate("Yes")) +logadblock:value("off", translate("No")) +logadblock.default = "off" + +loguseragent = s:taboption("tab_general", ListValue, "loguseragent", translate("Enable logging of client user agent")) +loguseragent:value("on", translate("Yes")) +loguseragent:value("off", translate("No")) +loguseragent.default = "off" + +softrestart = s:taboption("tab_general", ListValue, "softrestart", translate("Enable soft restart")) +softrestart:value("on", translate("Yes")) +softrestart:value("off", translate("No")) +softrestart.default = "off" + + +------------------------ Additional Settings Tab ---------------------------- + +e2guardian_config_file = s:taboption("tab_additional", TextValue, "_data", "") +e2guardian_config_file.wrap = "off" +e2guardian_config_file.rows = 25 +e2guardian_config_file.rmempty = false + +function e2guardian_config_file.cfgvalue() + local uci = require "luci.model.uci".cursor_state() + file = "/etc/e2guardian/e2guardianf1.conf" + if file then + return fs.readfile(file) or "" + else + return "" + end +end + +function e2guardian_config_file.write(self, section, value) + if value then + local uci = require "luci.model.uci".cursor_state() + file = "/etc/e2guardian/e2guardianf1.conf" + fs.writefile(file, value:gsub("\r\n", "\n")) + end +end + + +---------------------------- Logs Tab ----------------------------- + +e2guardian_logfile = s:taboption("tab_logs", TextValue, "lines", "") +e2guardian_logfile.wrap = "off" +e2guardian_logfile.rows = 25 +e2guardian_logfile.rmempty = true + +function e2guardian_logfile.cfgvalue() + local uci = require "luci.model.uci".cursor_state() + file = "/tmp/e2guardian/access.log" + if file then + return fs.readfile(file) or "" + else + return "Can't read log file" + end +end + +function e2guardian_logfile.write() + return "" +end + +return m diff --git a/net/luci-app-e2guardian/files/e2guardian-controller.lua b/net/luci-app-e2guardian/files/e2guardian-controller.lua new file mode 100644 index 000000000..dd545f50b --- /dev/null +++ b/net/luci-app-e2guardian/files/e2guardian-controller.lua @@ -0,0 +1,22 @@ +--[[ + +LuCI E2Guardian module + +Copyright (C) 2015, Itus Networks, Inc. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + Luka Perkov + +]]-- + +module("luci.controller.e2guardian", package.seeall) + +function index() + entry({"admin", "services", "e2guardian"}, cbi("e2guardian"), _("E2Guardian")) +end diff --git a/net/luci-app-sqm/Makefile b/net/luci-app-sqm/Makefile index f0bb2a0ac..c4fbc1283 100644 --- a/net/luci-app-sqm/Makefile +++ b/net/luci-app-sqm/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luci-app-sqm PKG_VERSION:=3 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_LICENSE:=GPLv2 LUCI_DIR:=/usr/lib/lua/luci diff --git a/net/luci-app-sqm/files/sqm-cbi.lua b/net/luci-app-sqm/files/sqm-cbi.lua index e7d79df00..49ab13057 100644 --- a/net/luci-app-sqm/files/sqm-cbi.lua +++ b/net/luci-app-sqm/files/sqm-cbi.lua @@ -52,11 +52,11 @@ end n.rmempty = false -dl = s:taboption("tab_basic", Value, "download", translate("Download speed (kbit/s) (ingress):")) +dl = s:taboption("tab_basic", Value, "download", translate("Download speed (kbit/s) (ingress) set to 0 to selectively disable ingress shaping:")) dl.datatype = "and(uinteger,min(0))" dl.rmempty = false -ul = s:taboption("tab_basic", Value, "upload", translate("Upload speed (kbit/s) (egress):")) +ul = s:taboption("tab_basic", Value, "upload", translate("Upload speed (kbit/s) (egress) set to 0 to selectively disable egress shaping:")) ul.datatype = "and(uinteger,min(0))" ul.rmempty = false @@ -89,7 +89,7 @@ sc.default = "simple.qos" sc.rmempty = false sc.description = qos_desc -ad = s:taboption("tab_qdisc", Flag, "qdisc_advanced", translate("Show Advanced Configuration")) +ad = s:taboption("tab_qdisc", Flag, "qdisc_advanced", translate("Show and Use Advanced Configuration")) ad.default = false ad.rmempty = true @@ -121,7 +121,7 @@ eecn.default = "NOECN" eecn.rmempty = true eecn:depends("qdisc_advanced", "1") -ad2 = s:taboption("tab_qdisc", Flag, "qdisc_really_really_advanced", translate("Show Dangerous Configuration")) +ad2 = s:taboption("tab_qdisc", Flag, "qdisc_really_really_advanced", translate("Show and Use Dangerous Configuration")) ad2.default = false ad2.rmempty = true ad2:depends("qdisc_advanced", "1") @@ -140,12 +140,12 @@ elim.rmempty = true elim:depends("qdisc_really_really_advanced", "1") -itarg = s:taboption("tab_qdisc", Value, "itarget", translate("Latency target for ingress, e.g 5ms [units: s, ms, or us]; leave empty for default, or auto for automatic selection.")) +itarg = s:taboption("tab_qdisc", Value, "itarget", translate("Latency target for ingress, e.g 5ms [units: s, ms, or us]; leave empty for automatic selection, put in the word default for the qdisc's default.")) itarg.datatype = "string" itarg.rmempty = true itarg:depends("qdisc_really_really_advanced", "1") -etarg = s:taboption("tab_qdisc", Value, "etarget", translate("Latency target for egress, e.g. 5ms [units: s, ms, or us]; leave empty for default, or auto for automatic selection.")) +etarg = s:taboption("tab_qdisc", Value, "etarget", translate("Latency target for egress, e.g. 5ms [units: s, ms, or us]; leave empty for automatic selection, put in the word default for the qdisc's default.")) etarg.datatype = "string" etarg.rmempty = true etarg:depends("qdisc_really_really_advanced", "1") diff --git a/net/luci-app-squid/Makefile b/net/luci-app-squid/Makefile new file mode 100644 index 000000000..91ce72414 --- /dev/null +++ b/net/luci-app-squid/Makefile @@ -0,0 +1,53 @@ +# +# Copyright (C) 2015 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:=luci-app-squid +PKG_RELEASE:=20150608 + +PKG_LICENSE:=Apache-2.0 + +PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) + +include $(INCLUDE_DIR)/package.mk + +define Package/luci-app-squid + SECTION:=luci + CATEGORY:=LuCI + SUBMENU:=3. Applications + TITLE:=Squid Web UI + DEPENDS:=+luci-mod-admin-full +squid + MAINTAINER:=Marko Ratkaj +endef + +define Package/luci-app-squid/description + This package will install Squid Web UI. +endef + +define Build/Prepare +endef + +define Build/Configure +endef + +define Build/Compile +endef + +define Package/luci-app-squid/install + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/controller/ + $(INSTALL_BIN) \ + ./files/squid-controller.lua \ + $(1)/usr/lib/lua/luci/controller/squid.lua + + $(INSTALL_DIR) $(1)/usr/lib/lua/luci/model/cbi/ + $(INSTALL_BIN) \ + ./files//squid-cbi.lua \ + $(1)/usr/lib/lua/luci/model/cbi/squid.lua +endef + +$(eval $(call BuildPackage,luci-app-squid)) diff --git a/net/luci-app-squid/files/squid-cbi.lua b/net/luci-app-squid/files/squid-cbi.lua new file mode 100644 index 000000000..0ac554a3e --- /dev/null +++ b/net/luci-app-squid/files/squid-cbi.lua @@ -0,0 +1,67 @@ +--[[ + +LuCI Squid module + +Copyright (C) 2015, OpenWrt.org + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + +]]-- + +local fs = require "nixio.fs" +local sys = require "luci.sys" +require "ubus" + +m = Map("squid", translate("Squid")) +m.on_after_commit = function() luci.sys.call("/etc/init.d/squid restart") end + +s = m:section(TypedSection, "squid") +s.anonymous = true +s.addremove = false + +s:tab("general", translate("General Settings")) + +http_port = s:taboption("general", Value, "http_port", translate("Port")) +http_port.datatype = "portrange" +http_port.placeholder = "0-65535" + +visible_hostname = s:taboption("general", Value, "visible_hostname", translate("Visible Hostname")) +visible_hostname.datatype="string" +visible_hostname.placeholder = "OpenWrt" + +coredump_dir = s:taboption("general", Value, "coredump_dir", translate("Coredump files directory")) +coredump_dir.datatype="string" +coredump_dir.placeholder = "/tmp/squid" + +s:tab("advanced", translate("Advanced Settings")) + +squid_config_file = s:taboption("advanced", TextValue, "_data", "") +squid_config_file.wrap = "off" +squid_config_file.rows = 25 +squid_config_file.rmempty = false + +function squid_config_file.cfgvalue() + local uci = require "luci.model.uci".cursor_state() + local file = uci:get("squid", "squid", "config_file") + if file then + return fs.readfile(file) or "" + else + return "" + end +end + +function squid_config_file.write(self, section, value) + if value then + local uci = require "luci.model.uci".cursor_state() + local file = uci:get("squid", "squid", "config_file") + fs.writefile(file, value:gsub("\r\n", "\n")) + end +end + +return m diff --git a/net/luci-app-squid/files/squid-controller.lua b/net/luci-app-squid/files/squid-controller.lua new file mode 100644 index 000000000..09946a151 --- /dev/null +++ b/net/luci-app-squid/files/squid-controller.lua @@ -0,0 +1,21 @@ +--[[ + +LuCI Squid module + +Copyright (C) 2015, OpenWrt.org + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Author: Marko Ratkaj + +]]-- + +module("luci.controller.squid", package.seeall) + +function index() + entry({"admin", "services", "squid"}, cbi("squid"), _("Squid")) +end diff --git a/net/mdnsresponder/Makefile b/net/mdnsresponder/Makefile index 91e7e9827..5eaedd2ec 100644 --- a/net/mdnsresponder/Makefile +++ b/net/mdnsresponder/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mDNSResponder -PKG_VERSION:=561.1.1 +PKG_VERSION:=567 PKG_RELEASE:=1 PKG_SOURCE:=mDNSResponder-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://opensource.apple.com/tarballs/mDNSResponder/ -PKG_MD5SUM:=d4b56e22798d6f45e29b42cd6720ab6e +PKG_MD5SUM:=6eff6d243a12a3d4b6fca03c05a9893b PKG_MAINTAINER:=Steven Barth PKG_LICENSE:=Apache-2.0 diff --git a/net/mdnsresponder/patches/001-cross_compile.patch b/net/mdnsresponder/patches/001-cross_compile.patch index ad4eaee44..b1685fc45 100644 --- a/net/mdnsresponder/patches/001-cross_compile.patch +++ b/net/mdnsresponder/patches/001-cross_compile.patch @@ -1,6 +1,6 @@ --- a/Clients/Makefile +++ b/Clients/Makefile -@@ -23,6 +23,8 @@ +@@ -27,6 +27,8 @@ ############################################################################# @@ -9,22 +9,22 @@ # On OS X the dns_sd library functions are included in libSystem, which is implicitly linked with every executable # If /usr/lib/libSystem.dylib exists, then we're on OS X, so we don't need also to link the "dns_sd" shared library ifneq "$(wildcard /usr/lib/libSystem.dylib)" "" -@@ -42,10 +44,10 @@ build: +@@ -46,10 +48,10 @@ build: mkdir build build/dns-sd: build dns-sd.c ClientCommon.c -- cc $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ +- $(CC) $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ + $(CC) $(CFLAGS) $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ build/dns-sd64: build dns-sd.c ClientCommon.c -- cc $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ -m64 +- $(CC) $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ -m64 + $(CC) $(CFLAGS) $(filter %.c %.o, $+) $(LIBS) -I../mDNSShared -Wall -o $@ -m64 # Note, we can make a 'fat' version of dns-sd using 'lipo', as shown below, but we # don't, because we don't want or need a 'fat' version of dns-sd, because it will --- a/mDNSPosix/Makefile +++ b/mDNSPosix/Makefile -@@ -54,10 +54,11 @@ COREDIR = ../mDNSCore +@@ -54,11 +54,12 @@ COREDIR = ../mDNSCore SHAREDDIR ?= ../mDNSShared JDK = /usr/jdk @@ -32,22 +32,14 @@ +CC = @gcc BISON = @bison FLEX = @flex + ST = @strip -LD = ld -shared +LD = @ld +SOOPTS = -shared CP = cp RM = rm LN = ln -s -f -@@ -82,7 +83,7 @@ else - CFLAGS_DEBUG = -Os -DMDNS_DEBUGMSGS=0 - OBJDIR ?= objects/prod - BUILDDIR ?= build/prod --STRIP = strip -S -+STRIP = @strip -S - endif - - # Configure per-OS peculiarities -@@ -91,7 +92,7 @@ CFLAGS_DEBUG = -O0 -DMDNS_DEBUGMSGS=0 +@@ -92,7 +93,7 @@ CFLAGS_DEBUG = -O0 -DMDNS_DEBUGMSGS=0 CFLAGS_OS = -DNOT_HAVE_DAEMON -DNOT_HAVE_SA_LEN -DNOT_HAVE_SOCKLEN_T -DNOT_HAVE_IF_NAMETOINDEX \ -DLOG_PERROR=0 -D_XPG4_2 -D__EXTENSIONS__ -DHAVE_BROKEN_RECVIF_NAME -DTARGET_OS_SOLARIS CC = gcc @@ -56,7 +48,7 @@ LINKOPTS = -lsocket -lnsl -lresolv JAVACFLAGS_OS += -I$(JDK)/include/solaris ifneq ($(DEBUG),1) -@@ -147,7 +148,8 @@ CFLAGS_OS = -DHAVE_IPV6 -no-cpp-precomp +@@ -148,7 +149,8 @@ CFLAGS_OS = -DHAVE_IPV6 -no-cpp-precomp -D__MAC_OS_X_VERSION_MIN_REQUIRED=__MAC_OS_X_VERSION_10_4 \ -D__APPLE_USE_RFC_2292 #-Wunreachable-code CC = gcc @@ -66,7 +58,7 @@ LINKOPTS = -lSystem LDSUFFIX = dylib JDK = /System/Library/Frameworks/JavaVM.framework/Home -@@ -169,8 +171,9 @@ NSSLIBFILE := $(NSSLIBNAME)-$(NSSVERSIO +@@ -170,8 +172,9 @@ NSSLIBFILE := $(NSSLIBNAME)-$(NSSVERSIO NSSLINKNAME := $(NSSLIBNAME).so.2 NSSINSTPATH := /lib @@ -77,7 +69,7 @@ INSTBASE?=/usr STARTUPSCRIPTNAME?=mdns -@@ -256,7 +259,7 @@ libdns_sd: setup $(BUILDDIR)/libdns_sd.$ +@@ -257,7 +260,7 @@ libdns_sd: setup $(BUILDDIR)/libdns_sd.$ CLIENTLIBOBJS = $(OBJDIR)/dnssd_clientlib.c.so.o $(OBJDIR)/dnssd_clientstub.c.so.o $(OBJDIR)/dnssd_ipc.c.so.o $(BUILDDIR)/libdns_sd.$(LDSUFFIX): $(CLIENTLIBOBJS) @@ -86,7 +78,7 @@ @$(STRIP) $@ Clients: setup libdns_sd ../Clients/build/dns-sd -@@ -291,7 +294,7 @@ InstalledManPages: $(MANPATH)/man8/mdnsd +@@ -292,7 +295,7 @@ InstalledManPages: $(MANPATH)/man8/mdnsd InstalledClients: $(INSTBASE)/bin/dns-sd @echo $+ " installed" @@ -95,7 +87,7 @@ @echo $+ " installed" # Note: If daemon already installed, we make sure it's stopped before overwriting it -@@ -346,19 +349,21 @@ $(INSTBASE)/bin/dns-sd: ../Clients/build +@@ -347,19 +350,21 @@ $(INSTBASE)/bin/dns-sd: ../Clients/build $(NSSINSTPATH)/$(NSSLINKNAME): $(NSSINSTPATH)/$(NSSLIBFILE) $(LN) $< $@ diff --git a/net/mdnsresponder/patches/100-linux_fixes.patch b/net/mdnsresponder/patches/100-linux_fixes.patch index ea598a75d..02940cf2f 100644 --- a/net/mdnsresponder/patches/100-linux_fixes.patch +++ b/net/mdnsresponder/patches/100-linux_fixes.patch @@ -1,3 +1,6 @@ +diff --git a/.gitignore b/.gitignore +new file mode 100644 +index 0000000..920cdfc --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ @@ -5,6 +8,21 @@ +mDNSPosix/build +mDNSPosix/objects + +diff --git a/Clients/Makefile b/Clients/Makefile +index 383af31..925c20e 100755 +--- a/Clients/Makefile ++++ b/Clients/Makefile +@@ -34,7 +34,7 @@ TARGETS = build/dns-sd build/dns-sd64 + LIBS = + else + TARGETS = build/dns-sd +-LIBS = -L../mDNSPosix/build/prod/ -ldns_sd ++LIBS ?= -L../mDNSPosix/build/prod/ -ldns_sd + endif + + all: $(TARGETS) +diff --git a/mDNSPosix/PosixDaemon.c b/mDNSPosix/PosixDaemon.c +index 88b3292..e86a6c7 100644 --- a/mDNSPosix/PosixDaemon.c +++ b/mDNSPosix/PosixDaemon.c @@ -37,6 +37,11 @@ @@ -70,9 +88,11 @@ if (mStatus_NoError == err) err = MainLoop(&mDNSStorage); +diff --git a/mDNSPosix/Responder.c b/mDNSPosix/Responder.c +index 3996b7b..e58d8eb 100755 --- a/mDNSPosix/Responder.c +++ b/mDNSPosix/Responder.c -@@ -603,7 +603,8 @@ static mStatus RegisterServicesInFile(co +@@ -603,7 +603,8 @@ static mStatus RegisterServicesInFile(const char *filePath) status = mStatus_UnknownErr; } @@ -82,9 +102,11 @@ return status; } +diff --git a/mDNSPosix/mDNSPosix.c b/mDNSPosix/mDNSPosix.c +index 6effa12..7c1d6eb 100755 --- a/mDNSPosix/mDNSPosix.c +++ b/mDNSPosix/mDNSPosix.c -@@ -136,7 +136,7 @@ mDNSlocal void SockAddrTomDNSAddr(const +@@ -138,7 +138,7 @@ mDNSlocal void SockAddrTomDNSAddr(const struct sockaddr *const sa, mDNSAddr *ipA // mDNS core calls this routine when it needs to send a packet. mDNSexport mStatus mDNSPlatformSendUDP(const mDNS *const m, const void *const msg, const mDNSu8 *const end, @@ -93,7 +115,7 @@ mDNSIPPort dstPort, mDNSBool useBackgroundTrafficClass) { int err = 0; -@@ -574,9 +574,17 @@ mDNSlocal void FreePosixNetworkInterface +@@ -583,9 +583,17 @@ mDNSlocal void FreePosixNetworkInterface(PosixNetworkInterface *intf) { assert(intf != NULL); if (intf->intfName != NULL) free((void *)intf->intfName); @@ -111,9 +133,9 @@ + assert(rv == 0); + } #endif - free(intf); - } -@@ -703,6 +711,29 @@ mDNSlocal int SetupSocket(struct sockadd + + // Move interface to the RecentInterfaces list for a minute +@@ -724,6 +732,29 @@ mDNSlocal int SetupSocket(struct sockaddr *intfAddr, mDNSIPPort port, int interf if (err < 0) { err = errno; perror("setsockopt - IP_MULTICAST_TTL"); } } @@ -143,7 +165,7 @@ // And start listening for packets if (err == 0) { -@@ -784,6 +815,29 @@ mDNSlocal int SetupSocket(struct sockadd +@@ -805,6 +836,29 @@ mDNSlocal int SetupSocket(struct sockaddr *intfAddr, mDNSIPPort port, int interf if (err < 0) { err = errno; perror("setsockopt - IPV6_MULTICAST_HOPS"); } } @@ -173,7 +195,7 @@ // And start listening for packets if (err == 0) { -@@ -815,7 +869,12 @@ mDNSlocal int SetupSocket(struct sockadd +@@ -836,7 +890,12 @@ mDNSlocal int SetupSocket(struct sockaddr *intfAddr, mDNSIPPort port, int interf } // Clean up @@ -187,7 +209,30 @@ assert((err == 0) == (*sktPtr != -1)); return err; } -@@ -994,7 +1053,7 @@ mDNSlocal mStatus OpenIfNotifySocket(int +@@ -938,19 +997,14 @@ mDNSlocal int SetupInterfaceList(mDNS *const m) + int err = 0; + struct ifi_info *intfList = get_ifi_info(AF_INET, mDNStrue); + struct ifi_info *firstLoopback = NULL; ++ struct ifi_info **p = &intfList; + + assert(m != NULL); + debugf("SetupInterfaceList"); + +- if (intfList == NULL) err = ENOENT; +- + #if HAVE_IPV6 +- if (err == 0) /* Link the IPv6 list to the end of the IPv4 list */ +- { +- struct ifi_info **p = &intfList; +- while (*p) p = &(*p)->ifi_next; +- *p = get_ifi_info(AF_INET6, mDNStrue); +- } ++ while (*p) p = &(*p)->ifi_next; ++ *p = get_ifi_info(AF_INET6, mDNStrue); + #endif + + if (err == 0) +@@ -1026,7 +1080,7 @@ mDNSlocal mStatus OpenIfNotifySocket(int *pFD) /* Subscribe the socket to Link & IP addr notifications. */ mDNSPlatformMemZero(&snl, sizeof snl); snl.nl_family = AF_NETLINK; @@ -196,7 +241,7 @@ ret = bind(sock, (struct sockaddr *) &snl, sizeof snl); if (0 == ret) *pFD = sock; -@@ -1072,11 +1131,18 @@ mDNSlocal mDNSu32 ProcessRoutingNo +@@ -1104,11 +1158,18 @@ mDNSlocal mDNSu32 ProcessRoutingNotification(int sd) PrintNetLinkMsg(pNLMsg); #endif @@ -217,7 +262,7 @@ // Advance pNLMsg to the next message in the buffer if ((pNLMsg->nlmsg_flags & NLM_F_MULTI) != 0 && pNLMsg->nlmsg_type != NLMSG_DONE) -@@ -1247,8 +1313,12 @@ mDNSexport mStatus mDNSPlatformInit(mDNS +@@ -1279,8 +1340,12 @@ mDNSexport mStatus mDNSPlatformInit(mDNS *const m) if (err == mStatus_NoError) err = SetupSocket(&sa, zeroIPPort, 0, &m->p->unicastSocket6); #endif @@ -230,7 +275,7 @@ // Tell mDNS core about DNS Servers mDNS_Lock(m); -@@ -1281,9 +1351,17 @@ mDNSexport void mDNSPlatformClose(mDNS * +@@ -1313,9 +1378,17 @@ mDNSexport void mDNSPlatformClose(mDNS *const m) { assert(m != NULL); ClearInterfaceList(m); @@ -250,7 +295,7 @@ #endif } -@@ -1533,14 +1611,14 @@ mDNSexport mStatus mDNSPlatformClearS +@@ -1571,14 +1644,14 @@ mDNSexport mStatus mDNSPlatformClearSPSMACAddr(void) mDNSexport mDNSu16 mDNSPlatformGetUDPPort(UDPSocket *sock) { (void) sock; // unused @@ -267,257 +312,63 @@ return mDNSfalse; } +diff --git a/mDNSPosix/mDNSUNP.c b/mDNSPosix/mDNSUNP.c +index b392fc7..fe800af 100755 --- a/mDNSPosix/mDNSUNP.c +++ b/mDNSPosix/mDNSUNP.c -@@ -61,154 +61,86 @@ - #endif - +@@ -63,6 +63,7 @@ #if defined(AF_INET6) && HAVE_IPV6 && HAVE_LINUX --#include --#include -+#include -+#include - --/* Converts a prefix length to IPv6 network mask */ --void plen_to_mask(int plen, char *addr) { -- int i; -- int colons=7; /* Number of colons in IPv6 address */ -- int bits_in_block=16; /* Bits per IPv6 block */ -- for(i=0; i<=colons; i++) { -- int block, ones=0xffff, ones_in_block; -- if (plen>bits_in_block) ones_in_block=bits_in_block; -- else ones_in_block=plen; -- block = ones & (ones << (bits_in_block-ones_in_block)); -- i==0 ? sprintf(addr, "%x", block) : sprintf(addr, "%s:%x", addr, block); -- plen -= ones_in_block; -- } --} - --/* Gets IPv6 interface information from the /proc filesystem in linux*/ --struct ifi_info *get_ifi_info_linuxv6(int family, int doaliases) -+/* Correct way to deal with this is just to use getifaddrs (glibc -+ * 2.3.3+ and various BSDs, but BSDs are 'slightly different' just to -+ * make life interesting). We assume Linux getifaddrs is available, -+ * and if not, please upgrade. */ -+struct ifi_info *get_ifi_info_linuxv6(int doaliases) - { -- struct ifi_info *ifi, *ifihead, **ifipnext, *ifipold, **ifiptr; -- FILE *fp; -- char addr[8][5]; -- int flags, myflags, index, plen, scope; + #include + #include ++#include + + /* Converts a prefix length to IPv6 network mask */ + void plen_to_mask(int plen, char *addr) { +@@ -86,7 +87,7 @@ struct ifi_info *get_ifi_info_linuxv6(int family, int doaliases) + FILE *fp; + char addr[8][5]; + int flags, myflags, index, plen, scope; - char ifname[9], lastname[IFNAMSIZ]; -- char addr6[32+7+1]; /* don't forget the seven ':' */ -- struct addrinfo hints, *res0; -- struct sockaddr_in6 *sin6; -- struct in6_addr *addrptr; -- int err; -- int sockfd = -1; -- struct ifreq ifr; -- -- res0=NULL; -- ifihead = NULL; -- ifipnext = &ifihead; -- lastname[0] = 0; ++ char ifname[IFNAMSIZ], lastname[IFNAMSIZ]; + char addr6[32+7+1]; /* don't forget the seven ':' */ + struct addrinfo hints, *res0; + struct sockaddr_in6 *sin6; +@@ -94,7 +95,8 @@ struct ifi_info *get_ifi_info_linuxv6(int family, int doaliases) + int err; + int sockfd = -1; + struct ifreq ifr; - -- if ((fp = fopen(PROC_IFINET6_PATH, "r")) != NULL) { -- sockfd = socket(AF_INET6, SOCK_DGRAM, 0); -- if (sockfd < 0) { -- goto gotError; -- } -- while (fscanf(fp, ++ char mask[64] = "%4s%4s%4s%4s%4s%4s%4s%4s %02x %02x %02x %02x %"; ++ sprintf(mask+strlen(mask), "%ds\n", IFNAMSIZ); + res0=NULL; + ifihead = NULL; + ifipnext = &ifihead; +@@ -106,11 +108,12 @@ struct ifi_info *get_ifi_info_linuxv6(int family, int doaliases) + goto gotError; + } + while (fscanf(fp, - "%4s%4s%4s%4s%4s%4s%4s%4s %02x %02x %02x %02x %8s\n", -- addr[0],addr[1],addr[2],addr[3], -- addr[4],addr[5],addr[6],addr[7], -- &index, &plen, &scope, &flags, ifname) != EOF) { -- -- myflags = 0; -- if (strncmp(lastname, ifname, IFNAMSIZ) == 0) { -- if (doaliases == 0) -- continue; /* already processed this interface */ -- myflags = IFI_ALIAS; -- } -- memcpy(lastname, ifname, IFNAMSIZ); -- ifi = (struct ifi_info*)calloc(1, sizeof(struct ifi_info)); -- if (ifi == NULL) { -- goto gotError; -- } -- -- ifipold = *ifipnext; /* need this later */ -- ifiptr = ifipnext; -- *ifipnext = ifi; /* prev points to this new one */ -- ifipnext = &ifi->ifi_next; /* pointer to next one goes here */ -- -- sprintf(addr6, "%s:%s:%s:%s:%s:%s:%s:%s", -- addr[0],addr[1],addr[2],addr[3], -- addr[4],addr[5],addr[6],addr[7]); -- -- /* Add address of the interface */ -- memset(&hints, 0, sizeof(hints)); -- hints.ai_family = AF_INET6; -- hints.ai_flags = AI_NUMERICHOST; -- err = getaddrinfo(addr6, NULL, &hints, &res0); -- if (err) { -- goto gotError; -- } -- ifi->ifi_addr = calloc(1, sizeof(struct sockaddr_in6)); -- if (ifi->ifi_addr == NULL) { -- goto gotError; -- } -- memcpy(ifi->ifi_addr, res0->ai_addr, sizeof(struct sockaddr_in6)); -- -- /* Add netmask of the interface */ -- char ipv6addr[INET6_ADDRSTRLEN]; -- plen_to_mask(plen, ipv6addr); -- ifi->ifi_netmask = calloc(1, sizeof(struct sockaddr_in6)); -- if (ifi->ifi_addr == NULL) { -- goto gotError; -- } -- sin6=calloc(1, sizeof(struct sockaddr_in6)); -- addrptr=calloc(1, sizeof(struct in6_addr)); -- inet_pton(family, ipv6addr, addrptr); -- sin6->sin6_family=family; -- sin6->sin6_addr=*addrptr; -- sin6->sin6_scope_id=scope; -- memcpy(ifi->ifi_netmask, sin6, sizeof(struct sockaddr_in6)); -- free(sin6); -- -- -- /* Add interface name */ -- memcpy(ifi->ifi_name, ifname, IFI_NAME); -- -- /* Add interface index */ -- ifi->ifi_index = index; -- -- /* Add interface flags*/ -- memcpy(ifr.ifr_name, ifname, IFNAMSIZ); -- if (ioctl(sockfd, SIOCGIFFLAGS, &ifr) < 0) { -- if (errno == EADDRNOTAVAIL) { -- /* -- * If the main interface is configured with no IP address but -- * an alias interface exists with an IP address, you get -- * EADDRNOTAVAIL for the main interface -- */ -- free(ifi->ifi_addr); -- free(ifi); -- ifipnext = ifiptr; -- *ifipnext = ifipold; -- continue; -- } else { -- goto gotError; -- } -- } -- ifi->ifi_flags = ifr.ifr_flags; -- freeaddrinfo(res0); -- res0=NULL; -- } -- } -- goto done; -+ struct ifaddrs *ifap, *ifa; -+ struct ifi_info *ifi = NULL, *head = NULL; - --gotError: -- if (ifihead != NULL) { -- free_ifi_info(ifihead); -- ifihead = NULL; -- } -- if (res0 != NULL) { -- freeaddrinfo(res0); -- res0=NULL; -+ /* doaliases seems always true in the calls in current code */ -+ assert(doaliases); -+ -+ if (getifaddrs(&ifap) < 0) -+ { -+ return NULL; ++ mask, + addr[0],addr[1],addr[2],addr[3], + addr[4],addr[5],addr[6],addr[7], + &index, &plen, &scope, &flags, ifname) != EOF) { + ++ if (flags & IFA_F_DEPRECATED) continue; + myflags = 0; + if (strncmp(lastname, ifname, IFNAMSIZ) == 0) { + if (doaliases == 0) +@@ -205,7 +208,8 @@ gotError: } --done: -- if (sockfd != -1) { + done: + if (sockfd != -1) { - assert(close(sockfd) == 0); -+ for (ifa = ifap ; ifa ; ifa = ifa->ifa_next) -+ { -+ /* Care only about IPv6 addresses on non-point-to-point links. */ -+ if (!ifa->ifa_addr -+ || ifa->ifa_addr->sa_family != AF_INET6) -+ continue; -+ ifi = calloc(1, sizeof(*ifi)); -+ if (!ifi) -+ break; -+ strncpy(ifi->ifi_name, ifa->ifa_name, IFI_NAME); -+ /* We ignore ifi_{haddr,hlen}, everyone else does too */ -+ ifi->ifi_flags = ifa->ifa_flags; -+ /* We ignore ifi_myflags; IFI_ALIAS isn't used anywhere */ -+ ifi->ifi_index = if_nametoindex(ifa->ifa_name); -+ if (!(ifi->ifi_addr = malloc(sizeof(struct sockaddr_in6)))) -+ break; -+ memcpy(ifi->ifi_addr, ifa->ifa_addr, sizeof(struct sockaddr_in6)); -+ -+ if (ifa->ifa_netmask) -+ { -+ if (!(ifi->ifi_netmask = malloc(sizeof(struct sockaddr_in6)))) -+ break; -+ memcpy(ifi->ifi_netmask, ifa->ifa_netmask, -+ sizeof(struct sockaddr_in6)); -+ } -+ -+ if (!(ifi->ifi_addr = malloc(sizeof(struct sockaddr_in6)))) -+ break; -+ memcpy(ifi->ifi_addr, ifa->ifa_addr, sizeof(struct sockaddr_in6)); -+ -+ -+ if (ifa->ifa_flags & IFF_POINTOPOINT && ifa->ifa_dstaddr) -+ { -+ if (!(ifi->ifi_dstaddr = malloc(sizeof(struct sockaddr_in6)))) -+ break; -+ memcpy(ifi->ifi_dstaddr, ifa->ifa_dstaddr, -+ sizeof(struct sockaddr_in6)); -+ } -+ else if (ifa->ifa_broadaddr) -+ { -+ if (!(ifi->ifi_brdaddr = malloc(sizeof(struct sockaddr_in6)))) -+ break; -+ memcpy(ifi->ifi_brdaddr, ifa->ifa_broadaddr, -+ sizeof(struct sockaddr_in6)); -+ } -+ ifi->ifi_next = head; -+ head = ifi; -+ ifi = NULL; -+ }; -+ if (ifi) -+ { -+ /* An error occurred. Let's bail out. */ -+ ifi->ifi_next = head; -+ free_ifi_info(head); -+ return NULL; ++ int rv = close(sockfd); ++ assert(rv == 0); } -- return(ifihead); /* pointer to first structure in linked list */ -+ freeifaddrs(ifap); -+ return head; + return(ifihead); /* pointer to first structure in linked list */ } -+ - #endif // defined(AF_INET6) && HAVE_IPV6 && HAVE_LINUX - - struct ifi_info *get_ifi_info(int family, int doaliases) -@@ -229,7 +161,7 @@ struct ifi_info *get_ifi_info(int family - #endif - - #if defined(AF_INET6) && HAVE_IPV6 && HAVE_LINUX -- if (family == AF_INET6) return get_ifi_info_linuxv6(family, doaliases); -+ if (family == AF_INET6) return get_ifi_info_linuxv6(doaliases); - #endif - - sockfd = -1; ---- a/mDNSPosix/mDNSUNP.h -+++ b/mDNSPosix/mDNSUNP.h -@@ -97,8 +97,7 @@ struct ifi_info { - }; - - #if defined(AF_INET6) && HAVE_IPV6 && HAVE_LINUX --#define PROC_IFINET6_PATH "/proc/net/if_inet6" --extern struct ifi_info *get_ifi_info_linuxv6(int family, int doaliases); -+extern struct ifi_info *get_ifi_info_linuxv6(int doaliases); - #endif - - #if defined(AF_INET6) && HAVE_IPV6 +diff --git a/mDNSShared/dnsextd_parser.y b/mDNSShared/dnsextd_parser.y +index 18c5990..d4b63ce 100644 --- a/mDNSShared/dnsextd_parser.y +++ b/mDNSShared/dnsextd_parser.y @@ -15,6 +15,8 @@ diff --git a/net/memcached/Makefile b/net/memcached/Makefile index 91ae4da64..111b14d57 100644 --- a/net/memcached/Makefile +++ b/net/memcached/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=memcached -PKG_VERSION:=1.4.22 +PKG_VERSION:=1.4.24 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://memcached.org/files -PKG_MD5SUM:=2b7eefa17c811998f4cd55bfabc12b8e +PKG_MD5SUM:=4d6e8c90e2068580526c7579dd7f37f6 PKG_INSTALL:=1 PKG_MAINTAINER:=Thomas Heil PKG_LICENSE:=permissive free software license diff --git a/net/mosquitto/Makefile b/net/mosquitto/Makefile index f7b0a918c..7ad3bc8ce 100644 --- a/net/mosquitto/Makefile +++ b/net/mosquitto/Makefile @@ -9,14 +9,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mosquitto -PKG_VERSION:=1.4 +PKG_VERSION:=1.4.2 PKG_RELEASE:=2 PKG_LICENSE:=BSD-3-Clause PKG_LICENSE_FILES:=LICENSE.txt PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://mosquitto.org/files/source/ -PKG_MD5SUM:=cd879f5964311501ba8e2275add71484 +PKG_MD5SUM:=2c3b19686c04849ed4b183c63149bfe1 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) include $(INCLUDE_DIR)/package.mk diff --git a/net/mosquitto/patches/100-libwebsockets-fixes.patch b/net/mosquitto/patches/100-libwebsockets-fixes.patch deleted file mode 100644 index 4d107b19c..000000000 --- a/net/mosquitto/patches/100-libwebsockets-fixes.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/src/websockets.c b/src/websockets.c -index 95f8a81..cf2b5e7 100644 ---- a/src/websockets.c -+++ b/src/websockets.c -@@ -72,7 +72,7 @@ struct libws_http_data { - FILE *fptr; - }; - --#ifndef HTTP_STATUS_NOT_FOUND -+#ifndef LWS_FEATURE_SERVE_HTTP_FILE_HAS_OTHER_HEADERS_ARG - /* This is libwebsockets 1.2.x or earlier, we have to degrade our capabilities. - * Once lws 1.3 is widely available this should be removed. */ - # define LWS_IS_OLD diff --git a/net/mtr/Makefile b/net/mtr/Makefile index 7214991be..1a4660111 100644 --- a/net/mtr/Makefile +++ b/net/mtr/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,12 +8,16 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mtr -PKG_VERSION:=0.86 +PKG_REV:=dd2b750 +PKG_VERSION:=0.85+newdns-$(PKG_REV) PKG_RELEASE:=1 -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=ftp://ftp.bitwizard.nl/mtr -PKG_MD5SUM:=8d63592c9d4579ef20cf491b41843eb2 +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://github.com/traviscross/mtr.git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=$(PKG_REV) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz + PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING @@ -46,6 +50,7 @@ endef CONFIGURE_ARGS += \ --without-gtk \ --without-glib \ + $(call autoconf_bool,CONFIG_IPV6,ipv6) define Build/Configure (cd $(PKG_BUILD_DIR); touch \ diff --git a/net/mtr/patches/501-dns.patch b/net/mtr/patches/501-dns.patch deleted file mode 100644 index e50b7fbff..000000000 --- a/net/mtr/patches/501-dns.patch +++ /dev/null @@ -1,510 +0,0 @@ ---- a/dns.c -+++ b/dns.c -@@ -921,6 +921,507 @@ void restell(char *s) - fputs("\r",stderr); - } - -+#ifdef __UCLIBC__ -+ -+static const char digits[] = "0123456789"; -+#define __set_errno(e) (errno = (e)) -+ -+#define NS_PUT16(s, cp) do { \ -+ register u_int16_t t_s = (u_int16_t)(s); \ -+ register u_char *t_cp = (u_char *)(cp); \ -+ *t_cp++ = t_s >> 8; \ -+ *t_cp = t_s; \ -+ (cp) += NS_INT16SZ; \ -+} while (0) -+ -+ -+ -+#define NS_PUT32(l, cp) do { \ -+ register u_int32_t t_l = (u_int32_t)(l); \ -+ register u_char *t_cp = (u_char *)(cp); \ -+ *t_cp++ = t_l >> 24; \ -+ *t_cp++ = t_l >> 16; \ -+ *t_cp++ = t_l >> 8; \ -+ *t_cp = t_l; \ -+ (cp) += NS_INT32SZ; \ -+} while (0) -+ -+ -+void -+ns_put16(u_int src, u_char *dst) { -+ NS_PUT16(src, dst); -+} -+ -+void -+ns_put32(u_long src, u_char *dst) { -+ NS_PUT32(src, dst); -+} -+ -+void __putshort(u_int16_t src, u_char *dst) { ns_put16(src, dst); } -+void __putlong(u_int32_t src, u_char *dst) { ns_put32(src, dst); } -+ -+int -+mklower(int ch) { -+ if (ch >= 0x41 && ch <= 0x5A) -+ return (ch + 0x20); -+ return (ch); -+} -+ -+ -+static int -+dn_find(const u_char *domain, const u_char *msg, -+ const u_char * const *dnptrs, -+ const u_char * const *lastdnptr) -+{ -+ const u_char *dn, *cp, *sp; -+ const u_char * const *cpp; -+ u_int n; -+ -+ for (cpp = dnptrs; cpp < lastdnptr; cpp++) { -+ sp = *cpp; -+ /* -+ * terminate search on: -+ * root label -+ * compression pointer -+ * unusable offset -+ */ -+ while (*sp != 0 && (*sp & NS_CMPRSFLGS) == 0 && -+ (sp - msg) < 0x4000) { -+ dn = domain; -+ cp = sp; -+ while ((n = *cp++) != 0) { -+ /* -+ * check for indirection -+ */ -+ switch (n & NS_CMPRSFLGS) { -+ case 0: /* normal case, n == len */ -+ if (n != *dn++) -+ goto next; -+ for ((void)NULL; n > 0; n--) -+ if (mklower(*dn++) != -+ mklower(*cp++)) -+ goto next; -+ /* Is next root for both ? */ -+ if (*dn == '\0' && *cp == '\0') -+ return (sp - msg); -+ if (*dn) -+ continue; -+ goto next; -+ -+ case NS_CMPRSFLGS: /* indirection */ -+ cp = msg + (((n & 0x3f) << 8) | *cp); -+ break; -+ -+ default: /* illegal type */ -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ } -+ next: -+ sp += *sp + 1; -+ } -+ } -+ __set_errno (ENOENT); -+ return (-1); -+} -+ -+ -+int -+ns_name_pack(const u_char *src, u_char *dst, int dstsiz, -+ const u_char **dnptrs, const u_char **lastdnptr) -+{ -+ u_char *dstp; -+ const u_char **cpp, **lpp, *eob, *msg; -+ const u_char *srcp; -+ int n, l, first = 1; -+ -+ srcp = src; -+ dstp = dst; -+ eob = dstp + dstsiz; -+ lpp = cpp = NULL; -+ if (dnptrs != NULL) { -+ if ((msg = *dnptrs++) != NULL) { -+ for (cpp = dnptrs; *cpp != NULL; cpp++) -+ (void)NULL; -+ lpp = cpp; /* end of list to search */ -+ } -+ } else -+ msg = NULL; -+ -+ /* make sure the domain we are about to add is legal */ -+ l = 0; -+ do { -+ n = *srcp; -+ if ((n & NS_CMPRSFLGS) != 0 && n != 0x41) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ if (n == 0x41) -+ n = *++srcp / 8; -+ l += n + 1; -+ if (l > MAXCDNAME) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ srcp += n + 1; -+ } while (n != 0); -+ -+ /* from here on we need to reset compression pointer array on error */ -+ srcp = src; -+ do { -+ /* Look to see if we can use pointers. */ -+ n = *srcp; -+ if (n != 0 && n != 0x41 && msg != NULL) { -+ l = dn_find(srcp, msg, (const u_char * const *)dnptrs, -+ (const u_char * const *)lpp); -+ if (l >= 0) { -+ if (dstp + 1 >= eob) { -+ goto cleanup; -+ } -+ *dstp++ = (l >> 8) | NS_CMPRSFLGS; -+ *dstp++ = l % 256; -+ return (dstp - dst); -+ } -+ /* Not found, save it. */ -+ if (lastdnptr != NULL && cpp < lastdnptr - 1 && -+ (dstp - msg) < 0x4000 && first) { -+ *cpp++ = dstp; -+ *cpp = NULL; -+ first = 0; -+ } -+ } -+ /* copy label to buffer */ -+ if ((n & NS_CMPRSFLGS) != 0 && n != 0x41) { /* Should not happen. */ -+ goto cleanup; -+ } -+ if (n == 0x41) { -+ n = *++srcp / 8; -+ if (dstp + 1 >= eob) -+ goto cleanup; -+ *dstp++ = 0x41; -+ } -+ if (dstp + 1 + n >= eob) { -+ goto cleanup; -+ } -+ memcpy(dstp, srcp, n + 1); -+ srcp += n + 1; -+ dstp += n + 1; -+ } while (n != 0); -+ -+ if (dstp > eob) { -+cleanup: -+ if (msg != NULL) -+ *lpp = NULL; -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ return (dstp - dst); -+} -+ -+ -+int -+ns_name_pton(const char *src, u_char *dst, size_t dstsiz) { -+ u_char *label, *bp, *eom; -+ int c, n, escaped; -+ char *cp; -+ -+ escaped = 0; -+ bp = dst; -+ eom = dst + dstsiz; -+ label = bp++; -+ -+ while ((c = *src++) != 0) { -+ if (escaped) { -+ if ((cp = strchr(digits, c)) != NULL) { -+ n = (cp - digits) * 100; -+ if ((c = *src++) == 0 || -+ (cp = strchr(digits, c)) == NULL) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ n += (cp - digits) * 10; -+ if ((c = *src++) == 0 || -+ (cp = strchr(digits, c)) == NULL) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ n += (cp - digits); -+ if (n > 255) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ c = n; -+ } else if (c == '[' && label == bp - 1 && *src == 'x') { -+ /* Theoretically we would have to handle \[o -+ as well but we do not since we do not need -+ it internally. */ -+ *label = 0x41; -+ label = bp++; -+ ++src; -+ while (isxdigit (*src)) { -+ n = *src > '9' ? *src - 'a' + 10 : *src - '0'; -+ ++src; -+ if (! isxdigit(*src)) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ n <<= 4; -+ n += *src > '9' ? *src - 'a' + 10 : *src - '0'; -+ if (bp + 1 >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *bp++ = n; -+ ++src; -+ } -+ *label = (bp - label - 1) * 8; -+ if (*src++ != ']' || *src++ != '.') { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ escaped = 0; -+ label = bp++; -+ if (bp >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ continue; -+ } -+ escaped = 0; -+ } else if (c == '\\') { -+ escaped = 1; -+ continue; -+ } else if (c == '.') { -+ c = (bp - label - 1); -+ if ((c & NS_CMPRSFLGS) != 0) { /* Label too big. */ -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ if (label >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *label = c; -+ /* Fully qualified ? */ -+ if (*src == '\0') { -+ if (c != 0) { -+ if (bp >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *bp++ = '\0'; -+ } -+ if ((bp - dst) > MAXCDNAME) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ return (1); -+ } -+ if (c == 0 || *src == '.') { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ label = bp++; -+ continue; -+ } -+ if (bp >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *bp++ = (u_char)c; -+ } -+ c = (bp - label - 1); -+ if ((c & NS_CMPRSFLGS) != 0) { /* Label too big. */ -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ if (label >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *label = c; -+ if (c != 0) { -+ if (bp >= eom) { -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ *bp++ = 0; -+ } -+ if ((bp - dst) > MAXCDNAME) { /* src too big */ -+ __set_errno (EMSGSIZE); -+ return (-1); -+ } -+ return (0); -+} -+ -+ -+ -+int -+ns_name_compress(const char *src, u_char *dst, size_t dstsiz, -+ const u_char **dnptrs, const u_char **lastdnptr) -+{ -+ u_char tmp[NS_MAXCDNAME]; -+ -+ if (ns_name_pton(src, tmp, sizeof tmp) == -1) -+ return (-1); -+ return (ns_name_pack(tmp, dst, dstsiz, dnptrs, lastdnptr)); -+} -+ -+ -+int -+dn_comp(const char *src, u_char *dst, int dstsiz, -+ u_char **dnptrs, u_char **lastdnptr) -+{ -+ return (ns_name_compress(src, dst, (size_t)dstsiz, -+ (const u_char **)dnptrs, -+ (const u_char **)lastdnptr)); -+} -+ -+ -+ -+ -+int -+res_nmkquery(res_state statp, -+ int op, /* opcode of query */ -+ const char *dname, /* domain name */ -+ int class, int type, /* class and type of query */ -+ const u_char *data, /* resource record data */ -+ int datalen, /* length of data */ -+ const u_char *newrr_in, /* new rr for modify or append */ -+ u_char *buf, /* buffer to put query */ -+ int buflen) /* size of buffer */ -+{ -+ register HEADER *hp; -+ register u_char *cp; -+ register int n; -+ u_char *dnptrs[20], **dpp, **lastdnptr; -+ -+#ifdef DEBUG -+ if (statp->options & RES_DEBUG) -+ printf(";; res_nmkquery(%s, %s, %s, %s)\n", -+ _res_opcodes[op], dname, p_class(class), p_type(type)); -+#endif -+ /* -+ * Initialize header fields. -+ */ -+ if ((buf == NULL) || (buflen < HFIXEDSZ)) -+ return (-1); -+ memset(buf, 0, HFIXEDSZ); -+ hp = (HEADER *) buf; -+ /* We randomize the IDs every time. The old code just -+ incremented by one after the initial randomization which -+ still predictable if the application does multiple -+ requests. */ -+#if 0 -+ hp->id = htons(++statp->id); -+#else -+ hp->id = htons(statp->id); -+ int randombits; -+ do -+ { -+#ifdef RANDOM_BITS -+ RANDOM_BITS (randombits); -+#else -+ struct timeval tv; -+ gettimeofday (&tv, NULL); -+ randombits = (tv.tv_sec << 8) ^ tv.tv_usec; -+#endif -+ } -+ while ((randombits & 0xffff) == 0); -+ statp->id = (statp->id + randombits) & 0xffff; -+#endif -+ hp->opcode = op; -+ hp->rd = (statp->options & RES_RECURSE) != 0; -+ hp->rcode = NOERROR; -+ cp = buf + HFIXEDSZ; -+ buflen -= HFIXEDSZ; -+ dpp = dnptrs; -+ *dpp++ = buf; -+ *dpp++ = NULL; -+ lastdnptr = dnptrs + sizeof dnptrs / sizeof dnptrs[0]; -+ /* -+ * perform opcode specific processing -+ */ -+ switch (op) { -+ case QUERY: /*FALLTHROUGH*/ -+ case NS_NOTIFY_OP: -+ if ((buflen -= QFIXEDSZ) < 0) -+ return (-1); -+ if ((n = dn_comp(dname, cp, buflen, dnptrs, lastdnptr)) < 0) -+ return (-1); -+ cp += n; -+ buflen -= n; -+ __putshort(type, cp); -+ cp += INT16SZ; -+ __putshort(class, cp); -+ cp += INT16SZ; -+ hp->qdcount = htons(1); -+ if (op == QUERY || data == NULL) -+ break; -+ /* -+ * Make an additional record for completion domain. -+ */ -+ buflen -= RRFIXEDSZ; -+ n = dn_comp((char *)data, cp, buflen, dnptrs, lastdnptr); -+ if (n < 0) -+ return (-1); -+ cp += n; -+ buflen -= n; -+ __putshort(T_NULL, cp); -+ cp += INT16SZ; -+ __putshort(class, cp); -+ cp += INT16SZ; -+ __putlong(0, cp); -+ cp += INT32SZ; -+ __putshort(0, cp); -+ cp += INT16SZ; -+ hp->arcount = htons(1); -+ break; -+ -+ case IQUERY: -+ /* -+ * Initialize answer section -+ */ -+ if (buflen < 1 + RRFIXEDSZ + datalen) -+ return (-1); -+ *cp++ = '\0'; /* no domain name */ -+ __putshort(type, cp); -+ cp += INT16SZ; -+ __putshort(class, cp); -+ cp += INT16SZ; -+ __putlong(0, cp); -+ cp += INT32SZ; -+ __putshort(datalen, cp); -+ cp += INT16SZ; -+ if (datalen) { -+ memcpy(cp, data, datalen); -+ cp += datalen; -+ } -+ hp->ancount = htons(1); -+ break; -+ -+ default: -+ return (-1); -+ } -+ return (cp - buf); -+} -+ -+int -+res_mkquery(int op, /* opcode of query */ -+ const char *dname, /* domain name */ -+ int class, int type, /* class and type of query */ -+ const u_char *data, /* resource record data */ -+ int datalen, /* length of data */ -+ const u_char *newrr_in, /* new rr for modify or append */ -+ u_char *buf, /* buffer to put query */ -+ int buflen) /* size of buffer */ -+{ -+ return (res_nmkquery(&_res, op, dname, class, type, -+ data, datalen, -+ newrr_in, buf, buflen)); -+} -+ -+#endif - - void dorequest(char *s,int type,word id) - { diff --git a/net/mtr/patches/502-fix-res_ninit.patch b/net/mtr/patches/502-fix-res_ninit.patch deleted file mode 100644 index 2d9883b4a..000000000 --- a/net/mtr/patches/502-fix-res_ninit.patch +++ /dev/null @@ -1,31 +0,0 @@ ---- a/dns.c -+++ b/dns.c -@@ -1308,28 +1308,6 @@ res_nmkquery(res_state statp, - return (-1); - memset(buf, 0, HFIXEDSZ); - hp = (HEADER *) buf; -- /* We randomize the IDs every time. The old code just -- incremented by one after the initial randomization which -- still predictable if the application does multiple -- requests. */ --#if 0 -- hp->id = htons(++statp->id); --#else -- hp->id = htons(statp->id); -- int randombits; -- do -- { --#ifdef RANDOM_BITS -- RANDOM_BITS (randombits); --#else -- struct timeval tv; -- gettimeofday (&tv, NULL); -- randombits = (tv.tv_sec << 8) ^ tv.tv_usec; --#endif -- } -- while ((randombits & 0xffff) == 0); -- statp->id = (statp->id + randombits) & 0xffff; --#endif - hp->opcode = op; - hp->rd = (statp->options & RES_RECURSE) != 0; - hp->rcode = NOERROR; diff --git a/net/mwan3-luci/Makefile b/net/mwan3-luci/Makefile index eed234875..6656806b5 100644 --- a/net/mwan3-luci/Makefile +++ b/net/mwan3-luci/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=luci-app-mwan3 -PKG_VERSION:=1.3 -PKG_RELEASE:=5 +PKG_VERSION:=1.4 +PKG_RELEASE:=2 PKG_MAINTAINER:=Aedan Renner PKG_LICENSE:=GPLv2 diff --git a/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/rule.lua b/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/rule.lua index bf524d1df..cbd8bdd03 100644 --- a/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/rule.lua +++ b/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/rule.lua @@ -88,6 +88,39 @@ proto = mwan_rule:option(DummyValue, "proto", translate("Protocol")) return self.map:get(s, "proto") or "all" end +sticky = mwan_rule:option(DummyValue, "sticky", translate("Sticky")) + sticky.rawhtml = true + function sticky.cfgvalue(self, s) + if self.map:get(s, "sticky") == "1" then + stickied = 1 + return "Yes" + else + stickied = nil + return "No" + end + end + +timeout = mwan_rule:option(DummyValue, "timeout", translate("Sticky timeout")) + timeout.rawhtml = true + function timeout.cfgvalue(self, s) + if stickied then + local timeoutValue = self.map:get(s, "timeout") + if timeoutValue then + return timeoutValue .. "s" + else + return "600s" + end + else + return "—" + end + end + +ipset = mwan_rule:option(DummyValue, "ipset", translate("IPset")) + ipset.rawhtml = true + function ipset.cfgvalue(self, s) + return self.map:get(s, "ipset") or "—" + end + use_policy = mwan_rule:option(DummyValue, "use_policy", translate("Policy assigned")) use_policy.rawhtml = true function use_policy.cfgvalue(self, s) diff --git a/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/ruleconfig.lua b/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/ruleconfig.lua index 831ab35b9..d880a72e2 100644 --- a/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/ruleconfig.lua +++ b/net/mwan3-luci/files/usr/lib/lua/luci/model/cbi/mwan/ruleconfig.lua @@ -81,6 +81,19 @@ proto = mwan_rule:option(Value, "proto", translate("Protocol"), proto:value("esp") cbiAddProtocol(proto) +sticky = mwan_rule:option(ListValue, "sticky", translate("Sticky"), + translate("Traffic from the same source IP address that previously matched this rule within the sticky timeout period will use the same WAN interface")) + sticky.default = "0" + sticky:value("1", translate("Yes")) + sticky:value("0", translate("No")) + +timeout = mwan_rule:option(Value, "timeout", translate("Sticky timeout"), + translate("Seconds. Acceptable values: 1-1000000. Defaults to 600 if not set")) + timeout.datatype = "range(1, 1000000)" + +ipset = mwan_rule:option(Value, "ipset", translate("IPset"), + translate("Name of IPset rule. Requires IPset rule in /etc/dnsmasq.conf (eg \"ipset=/youtube.com/youtube\")")) + use_policy = mwan_rule:option(Value, "use_policy", translate("Policy assigned")) cbiAddPolicy(use_policy) use_policy:value("unreachable", translate("unreachable (reject)")) diff --git a/net/mwan3/Makefile b/net/mwan3/Makefile index c0f720bae..d714d4fe9 100644 --- a/net/mwan3/Makefile +++ b/net/mwan3/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mwan3 -PKG_VERSION:=1.5 -PKG_RELEASE:=10 +PKG_VERSION:=1.6 +PKG_RELEASE:=1 PKG_MAINTAINER:=Jeroen Louwes PKG_LICENSE:=GPLv2 @@ -19,7 +19,7 @@ define Package/mwan3 SECTION:=net CATEGORY:=Network SUBMENU:=Routing and Redirection - DEPENDS:=+ip +iptables +iptables-mod-conntrack-extra +iptables-mod-ipopt + DEPENDS:=+ip +ipset +iptables +iptables-mod-conntrack-extra +iptables-mod-ipopt TITLE:=Multiwan hotplug script with connection tracking support MAINTAINER:=Jeroen Louwes PKGARCH:=all diff --git a/net/mwan3/files/etc/config/mwan3 b/net/mwan3/files/etc/config/mwan3 index 53f2f9832..f66c024c0 100644 --- a/net/mwan3/files/etc/config/mwan3 +++ b/net/mwan3/files/etc/config/mwan3 @@ -61,17 +61,18 @@ config policy 'wan2_wan' list use_member 'wan_m2_w3' list use_member 'wan2_m1_w2' -config rule 'sticky_even' - option src_ip '0.0.0.0/0.0.0.1' - option dest_port '443' +config rule 'youtube' + option sticky '1' + option ipset 'youtube' + option dest_port '80,443' option proto 'tcp' - option use_policy 'wan_wan2' + option use_policy 'balanced' -config rule 'sticky_odd' - option src_ip '0.0.0.1/0.0.0.1' +config rule 'https' + option sticky '1' option dest_port '443' option proto 'tcp' - option use_policy 'wan2_wan' + option use_policy 'balanced' config rule 'default_rule' option dest_ip '0.0.0.0/0' diff --git a/net/mwan3/files/etc/hotplug.d/iface/15-mwan3 b/net/mwan3/files/etc/hotplug.d/iface/15-mwan3 index 25044c4d3..f117e49e6 100644 --- a/net/mwan3/files/etc/hotplug.d/iface/15-mwan3 +++ b/net/mwan3/files/etc/hotplug.d/iface/15-mwan3 @@ -12,12 +12,18 @@ mwan3_set_general_iptables() $IPT -N mwan3_ifaces fi - if ! $IPT -S mwan3_rules &> /dev/null; then - $IPT -N mwan3_rules - fi - if ! $IPT -S mwan3_connected &> /dev/null; then $IPT -N mwan3_connected + $IPS create mwan3_connected hash:net + $IPT -A mwan3_connected -m set --match-set mwan3_connected dst -j MARK --set-xmark 0xff00/0xff00 + fi + + if ! $IPT -S mwan3_track &> /dev/null; then + $IPT -N mwan3_track + fi + + if ! $IPT -S mwan3_rules &> /dev/null; then + $IPT -N mwan3_rules fi if ! $IPT -S mwan3_hook &> /dev/null; then @@ -25,15 +31,12 @@ mwan3_set_general_iptables() $IPT -A mwan3_hook -j CONNMARK --restore-mark --nfmask 0xff00 --ctmask 0xff00 $IPT -A mwan3_hook -m mark --mark 0x0/0xff00 -j mwan3_ifaces $IPT -A mwan3_hook -m mark --mark 0x0/0xff00 -j mwan3_connected + $IPT -A mwan3_hook -m mark --mark 0x0/0xff00 -j mwan3_track $IPT -A mwan3_hook -m mark --mark 0x0/0xff00 -j mwan3_rules $IPT -A mwan3_hook -j CONNMARK --save-mark --nfmask 0xff00 --ctmask 0xff00 $IPT -A mwan3_hook -m mark ! --mark 0xff00/0xff00 -j mwan3_connected fi - if ! $IPT -S mwan3_output_hook &> /dev/null; then - $IPT -N mwan3_output_hook - fi - if ! $IPT -S PREROUTING | grep mwan3_hook &> /dev/null; then $IPT -A PREROUTING -j mwan3_hook fi @@ -42,10 +45,6 @@ mwan3_set_general_iptables() $IPT -A OUTPUT -j mwan3_hook fi - if ! $IPT -S OUTPUT | grep mwan3_output_hook &> /dev/null; then - $IPT -A OUTPUT -j mwan3_output_hook - fi - $IPT -F mwan3_rules } @@ -62,28 +61,29 @@ mwan3_set_general_rules() mwan3_set_connected_iptables() { - local connected_networks + local connected_network if $IPT -S mwan3_connected &> /dev/null; then - $IPT -F mwan3_connected - for connected_networks in $($IP route | awk '{print $1}' | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}'); do - $IPT -A mwan3_connected -d $connected_networks -j MARK --set-xmark 0xff00/0xff00 + $IPS create mwan3_connected_temp hash:net + + for connected_network in $($IP route | awk '{print $1}' | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}'); do + $IPS -! add mwan3_connected_temp $connected_network done - for connected_networks in $($IP route list table 0 | awk '{print $2}' | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}'); do - $IPT -A mwan3_connected -d $connected_networks -j MARK --set-xmark 0xff00/0xff00 + for connected_network in $($IP route list table 0 | awk '{print $2}' | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}'); do + $IPS -! add mwan3_connected_temp $connected_network done - $IPT -I mwan3_connected -d 224.0.0.0/3 -j MARK --set-xmark 0xff00/0xff00 - $IPT -I mwan3_connected -d 127.0.0.0/8 -j MARK --set-xmark 0xff00/0xff00 + $IPS add mwan3_connected_temp 224.0.0.0/3 + $IPS swap mwan3_connected_temp mwan3_connected + $IPS destroy mwan3_connected_temp + fi } mwan3_set_iface_iptables() { - local local_net local_nets - if ! $IPT -S mwan3_iface_$INTERFACE &> /dev/null; then $IPT -N mwan3_iface_$INTERFACE fi @@ -92,16 +92,7 @@ mwan3_set_iface_iptables() $IPT -D mwan3_ifaces -m mark --mark 0x0/0xff00 -j mwan3_iface_$INTERFACE &> /dev/null if [ $ACTION == "ifup" ]; then - local_nets=$($IP route list dev $DEVICE scope link | awk '{print $1}' | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}') - - if [ -n "$local_nets" ]; then - for local_net in $local_nets ; do - if [ $ACTION == "ifup" ]; then - $IPT -I mwan3_iface_$INTERFACE -i $DEVICE -s $local_net -m mark --mark 0x0/0xff00 -m comment --comment "default" -j MARK --set-xmark 0xff00/0xff00 - fi - done - fi - + $IPT -I mwan3_iface_$INTERFACE -i $DEVICE -m set --match-set mwan3_connected src -m mark --mark 0x0/0xff00 -m comment --comment "default" -j MARK --set-xmark 0xff00/0xff00 $IPT -A mwan3_iface_$INTERFACE -i $DEVICE -m mark --mark 0x0/0xff00 -m comment --comment "$INTERFACE" -j MARK --set-xmark $(($iface_id*256))/0xff00 $IPT -A mwan3_ifaces -m mark --mark 0x0/0xff00 -j mwan3_iface_$INTERFACE fi @@ -131,6 +122,17 @@ mwan3_set_iface_rules() [ $ACTION == "ifup" ] && $IP rule add pref $(($iface_id+2000)) fwmark $(($iface_id*256))/0xff00 lookup $iface_id } +mwan3_set_iface_ipset() +{ + local setname entry + + for setname in $(ipset -n list | grep ^mwan3_sticky_); do + for entry in $(ipset list $setname | grep "$(echo $(($iface_id*256)) | awk '{ printf "0x%08x", $1; }')" | cut -d ' ' -f 1); do + $IPS del $setname $entry + done + done +} + mwan3_track() { local track_ip track_ips reliability count timeout interval down up @@ -154,22 +156,23 @@ mwan3_track() config_get down $INTERFACE down 5 config_get up $INTERFACE up 5 - if ! $IPT -S mwan3_track_$INTERFACE &> /dev/null; then - $IPT -N mwan3_track_$INTERFACE - $IPT -A mwan3_output_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE - fi - - $IPT -F mwan3_track_$INTERFACE + $IPS -! create mwan3_track_$INTERFACE hash:ip + $IPS create mwan3_track_temp_$INTERFACE hash:ip for track_ip in $track_ips; do - $IPT -A mwan3_track_$INTERFACE -d $track_ip -j MARK --set-xmark 0xff00/0xff00 + $IPS -! add mwan3_track_temp_$INTERFACE $track_ip done + $IPS swap mwan3_track_temp_$INTERFACE mwan3_track_$INTERFACE + $IPS destroy mwan3_track_temp_$INTERFACE + + $IPT -D mwan3_track -p icmp -m set --match-set mwan3_track_$INTERFACE dst -m icmp --icmp-type 8 -m length --length 32 -j MARK --set-xmark 0xff00/0xff00 &> /dev/null + $IPT -A mwan3_track -p icmp -m set --match-set mwan3_track_$INTERFACE dst -m icmp --icmp-type 8 -m length --length 32 -j MARK --set-xmark 0xff00/0xff00 + [ -x /usr/sbin/mwan3track ] && /usr/sbin/mwan3track $INTERFACE $DEVICE $reliability $count $timeout $interval $down $up $track_ips & else - $IPT -D mwan3_output_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE &> /dev/null - $IPT -F mwan3_track_$INTERFACE &> /dev/null - $IPT -X mwan3_track_$INTERFACE &> /dev/null + $IPT -D mwan3_track -p icmp -m set --match-set mwan3_track_$INTERFACE dst -m icmp --icmp-type 8 -m length --length 32 -j MARK --set-xmark 0xff00/0xff00 &> /dev/null + $IPS destroy mwan3_track_$INTERFACE fi } @@ -182,7 +185,7 @@ mwan3_set_policy() config_get weight $1 weight 1 [ -n "$INTERFACE" ] || return 0 - + config_foreach mwan3_get_iface_id interface [ -n "$iface_id" ] || return 0 @@ -200,19 +203,19 @@ mwan3_set_policy() total_weight=$(($total_weight+$weight)) probability=$(($weight*1000/$total_weight)) - + if [ "$probability" -lt 10 ]; then probability="0.00$probability" - elif [ $probability -lt 100 ]; then + elif [ $probability -lt 100 ]; then probability="0.0$probability" - elif [ $probability -lt 1000 ]; then + elif [ $probability -lt 1000 ]; then probability="0.$probability" else probability="1" fi probability="-m statistic --mode random --probability $probability" - + $IPT -I mwan3_policy_$policy -m mark --mark 0x0/0xff00 $probability -m comment --comment "$INTERFACE $weight $total_weight" -j MARK --set-xmark $(($iface_id*256))/0xff00 fi fi @@ -254,10 +257,34 @@ mwan3_set_policies_iptables() config_list_foreach $policy use_member mwan3_set_policy } +mwan3_set_sticky_iptables() +{ + local INTERFACE iface_count iface_id + + INTERFACE="$1" + + config_foreach mwan3_get_iface_id interface + unset iface_count + + $IPS -! create mwan3_sticky_$rule hash:ip,mark markmask 0xff00 timeout $timeout + + if [ -n "$iface_id" ]; then + if [ -n "$($IPT -S mwan3_iface_$1 2> /dev/null)" ]; then + $IPT -I mwan3_rule_$rule -m set ! --match-set mwan3_sticky_$rule src,src -j MARK --set-xmark 0x0/0xff00 + $IPT -I mwan3_rule_$rule -m mark --mark 0/0xff00 -j MARK --set-xmark $(($iface_id*256))/0xff00 + fi + fi + + unset iface_id +} + mwan3_set_user_rules_iptables() { - local proto src_ip src_port dest_ip dest_port use_policy + local ipset proto src_ip src_port sticky dest_ip dest_port use_policy rule timeout + config_get sticky $1 sticky 0 + config_get timeout $1 timeout 600 + config_get ipset $1 ipset config_get proto $1 proto all config_get src_ip $1 src_ip 0.0.0.0/0 config_get src_port $1 src_port 0:65535 @@ -265,6 +292,20 @@ mwan3_set_user_rules_iptables() config_get dest_port $1 dest_port 0:65535 config_get use_policy $1 use_policy + rule="$1" + + if [ "$rule" != $(echo "$rule" | cut -c1-15) ]; then + $LOG warn "Rule $rule exceeds max of 15 chars. Not setting rule" && return 0 + fi + + if [ -n "$ipset" ]; then + if [ -z "$($IPS -n list $ipset)" ]; then + $IPS create $ipset hash:ip timeout 3600 + fi + + ipset="-m set --match-set $ipset dst" + fi + if [ -n "$use_policy" ]; then if [ "$use_policy" == "default" ]; then use_policy="MARK --set-xmark 0xff00/0xff00" @@ -273,15 +314,32 @@ mwan3_set_user_rules_iptables() elif [ "$use_policy" == "blackhole" ]; then use_policy="MARK --set-xmark 0xfd00/0xff00" else - use_policy="mwan3_policy_$use_policy" + if [ "$sticky" -eq 1 ]; then + + if ! $IPT -S mwan3_rule_$rule &> /dev/null; then + $IPT -N mwan3_rule_$rule + fi + + $IPT -F mwan3_rule_$rule + + config_foreach mwan3_set_sticky_iptables interface + + $IPT -A mwan3_rule_$rule -m mark --mark 0/0xff00 -j mwan3_policy_$use_policy + $IPT -A mwan3_rule_$rule -m mark ! --mark 0xfc00/0xfc00 -j SET --del-set mwan3_sticky_$rule src,src + $IPT -A mwan3_rule_$rule -m mark ! --mark 0xfc00/0xfc00 -j SET --add-set mwan3_sticky_$rule src,src + + use_policy="mwan3_rule_$rule" + else + use_policy="mwan3_policy_$use_policy" + fi fi case $proto in tcp|udp) - $IPT -A mwan3_rules -p $proto -s $src_ip -d $dest_ip -m multiport --sports $src_port -m multiport --dports $dest_port -m mark --mark 0/0xff00 -m comment --comment "$1" -j $use_policy &> /dev/null + $IPT -A mwan3_rules -p $proto -s $src_ip -d $dest_ip $ipset -m multiport --sports $src_port -m multiport --dports $dest_port -m mark --mark 0/0xff00 -m comment --comment "$1" -j $use_policy &> /dev/null ;; *) - $IPT -A mwan3_rules -p $proto -s $src_ip -d $dest_ip -m mark --mark 0/0xff00 -m comment --comment "$1" -j $use_policy &> /dev/null + $IPT -A mwan3_rules -p $proto -s $src_ip -d $dest_ip $ipset -m mark --mark 0/0xff00 -m comment --comment "$1" -j $use_policy &> /dev/null ;; esac fi @@ -333,6 +391,7 @@ mwan3_ifupdown() mwan3_set_iface_route mwan3_set_iface_rules + [ $ACTION == "ifdown" ] && mwan3_set_iface_ipset [ $ACTION == "ifup" ] && mwan3_track config_foreach mwan3_set_policies_iptables policy @@ -346,9 +405,15 @@ if [ $ACTION == "ifup" ]; then [ -n "$DEVICE" ] || exit 0 fi -local IP IPT LOG +[ -x /usr/sbin/ip ] || exit 1 +[ -x /usr/sbin/ipset ] || exit 1 +[ -x /usr/sbin/iptables ] || exit 1 +[ -x /usr/bin/logger ] || exit 1 + +local IP IPS IPT LOG IP="/usr/sbin/ip -4" +IPS="/usr/sbin/ipset" IPT="/usr/sbin/iptables -t mangle -w" LOG="/usr/bin/logger -t mwan3 -p" diff --git a/net/mwan3/files/usr/sbin/mwan3 b/net/mwan3/files/usr/sbin/mwan3 index 286603a85..c69d94eeb 100755 --- a/net/mwan3/files/usr/sbin/mwan3 +++ b/net/mwan3/files/usr/sbin/mwan3 @@ -2,14 +2,15 @@ . /lib/functions.sh IP="/usr/sbin/ip -4" +IPS="/usr/sbin/ipset" IPT="/usr/sbin/iptables -t mangle -w" help() -{ - cat <" && exit 0 fi - + config_get enabled "$1" enabled 0 device=$(uci get -p /var/state network.$1.ifname) &> /dev/null - + if [ -n "$device" ] ; then [ "$enabled" -eq 1 ] && ACTION=ifup INTERFACE=$1 DEVICE=$device /sbin/hotplug-call iface fi @@ -71,14 +72,14 @@ interfaces() config_load mwan3 echo "Interface status:" - + check_iface_status() { let iface_id++ device=$(uci get -p /var/state network.$1.ifname) &> /dev/null if [ -z "$device" ]; then - echo "Interface $1 is unknown" + echo " interface $1 is unknown" return 0 fi @@ -92,21 +93,21 @@ interfaces() if [ -n "$($IP rule | awk '$5 == "'$device'"')" -a -n "$($IPT -S mwan3_iface_$1 2> /dev/null)" -a -n "$($IP route list table $iface_id default dev $device 2> /dev/null)" ]; then if [ -n "$(uci get -p /var/state mwan3.$1.track_ip 2> /dev/null)" ]; then - echo "Interface $1 is online (tracking $tracking)" + echo " interface $1 is online (tracking $tracking)" else - echo "Interface $1 is online" + echo " interface $1 is online" fi elif [ -n "$($IP rule | awk '$5 == "'$device'"')" -o -n "$($IPT -S mwan3_iface_$1 2> /dev/null)" -o -n "$($IP route list table $iface_id default dev $device 2> /dev/null)" ]; then - echo "Interface $1 error" + echo " interface $1 error" else if [ "$enabled" -eq 1 ]; then if [ -n "$(uci get -p /var/state mwan3.$1.track_ip 2> /dev/null)" ]; then - echo "Interface $1 is offline (tracking $tracking)" + echo " interface $1 is offline (tracking $tracking)" else - echo "Interface $1 is offline" + echo " interface $1 is offline" fi else - echo "Interface $1 is disabled" + echo " interface $1 is disabled" fi fi } @@ -141,17 +142,19 @@ policies() } rules() { + local address + if [ -n "$($IPT -S mwan3_connected 2> /dev/null)" ]; then echo "Known networks:" - echo "destination policy hits" | awk '{ printf "%-19s%-19s%-9s%s\n",$1,$2,$3}' | awk '1; {gsub(".","-")}1' - $IPT -L mwan3_connected -n -v 2> /dev/null | tail -n+3 | sed 's/mark.*//' | sed 's/mwan3_policy_//' | awk '{printf "%-19s%-19s%-9s%s\n",$9,"default",$1}' + for address in $($IPS list mwan3_connected | egrep '[0-9]{1,3}(\.[0-9]{1,3}){3}'); do + echo " $address" + done echo -e fi if [ -n "$($IPT -S mwan3_rules 2> /dev/null)" ]; then echo "Active rules:" - echo "source destination proto src-port dest-port policy hits" | awk '{ printf "%-19s%-19s%-7s%-14s%-14s%-16s%-9s%s\n",$1,$2,$3,$4,$5,$6,$7}' | awk '1; {gsub(".","-")}1' - $IPT -L mwan3_rules -n -v 2> /dev/null | tail -n+3 | sed 's/mark.*//' | sed 's/mwan3_policy_//' | awk '{ printf "%-19s%-19s%-7s%-14s%-14s%-16s%-9s%s\n",$8,$9,$4,$12,$15,$3,$1}' + $IPT -L mwan3_rules -n -v 2> /dev/null | tail -n+3 | sed 's/mark.*//' | sed 's/mwan3_policy_/- /' | sed 's/mwan3_rule_/S /' echo -e fi } @@ -171,7 +174,7 @@ start() stop() { - local route rule table + local ipset route rule table killall mwan3track &> /dev/null rm /var/run/mwan3track-* &> /dev/null @@ -186,7 +189,6 @@ stop() $IPT -D PREROUTING -j mwan3_hook &> /dev/null $IPT -D OUTPUT -j mwan3_hook &> /dev/null - $IPT -D OUTPUT -j mwan3_output_hook &> /dev/null for table in $($IPT -S | awk '{print $2}' | grep mwan3 | sort -u); do $IPT -F $table &> /dev/null @@ -195,6 +197,10 @@ stop() for table in $($IPT -S | awk '{print $2}' | grep mwan3 | sort -u); do $IPT -X $table &> /dev/null done + + for ipset in $(ipset -n list | grep mwan3); do + $IPS destroy $ipset + done } restart() { diff --git a/net/net-snmp/Makefile b/net/net-snmp/Makefile index 6fbf1b8bd..38d038035 100644 --- a/net/net-snmp/Makefile +++ b/net/net-snmp/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=net-snmp PKG_VERSION:=5.4.4 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/net-snmp @@ -216,7 +216,6 @@ define Package/libnetsnmp/install endef define Package/snmpd/conffiles -/etc/default/snmpd /etc/config/snmpd endef @@ -225,8 +224,6 @@ define Package/snmpd/install $(INSTALL_DATA) ./files/snmpd.conf $(1)/etc/config/snmpd $(INSTALL_DIR) $(1)/etc/snmp ln -sf /var/run/snmpd.conf $(1)/etc/snmp/ - $(INSTALL_DIR) $(1)/etc/default - $(INSTALL_DATA) ./files/snmpd.default $(1)/etc/default/snmpd $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/snmpd.init $(1)/etc/init.d/snmpd $(INSTALL_DIR) $(1)/usr/sbin @@ -234,7 +231,6 @@ define Package/snmpd/install endef define Package/snmpd-static/conffiles -/etc/default/snmpd /etc/config/snmpd endef @@ -243,8 +239,6 @@ define Package/snmpd-static/install $(INSTALL_DATA) ./files/snmpd.conf $(1)/etc/config/snmpd $(INSTALL_DIR) $(1)/etc/snmp ln -sf /var/run/snmpd.conf $(1)/etc/snmp/ - $(INSTALL_DIR) $(1)/etc/default - $(INSTALL_DATA) ./files/snmpd.default $(1)/etc/default/snmpd $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/snmpd.init $(1)/etc/init.d/snmpd $(INSTALL_DIR) $(1)/usr/sbin diff --git a/net/net-snmp/files/snmpd.default b/net/net-snmp/files/snmpd.default deleted file mode 100644 index 758c8e44f..000000000 --- a/net/net-snmp/files/snmpd.default +++ /dev/null @@ -1 +0,0 @@ -OPTIONS="-Lf /dev/null -p /var/run/snmpd.pid" diff --git a/net/net-snmp/files/snmpd.init b/net/net-snmp/files/snmpd.init index 2668b7b3e..3dd8c41dc 100644 --- a/net/net-snmp/files/snmpd.init +++ b/net/net-snmp/files/snmpd.init @@ -2,35 +2,35 @@ # Copyright (C) 2008 OpenWrt.org START=50 -DEFAULT=/etc/default/snmpd -LIB_D=/var/lib/snmp -LOG_D=/var/log -RUN_D=/var/run -PID_F=$RUN_D/snmpd.pid -RUN_C=$RUN_D/snmpd.conf +USE_PROCD=1 +PROG="/usr/sbin/snmpd" + +CONFIGFILE="/var/run/snmpd.conf" snmpd_agent_add() { local cfg="$1" config_get agentaddress "$cfg" agentaddress [ -n "$agentaddress" ] || return 0 - echo "agentaddress $agentaddress" >> $RUN_C + echo "agentaddress $agentaddress" >> $CONFIGFILE } + snmpd_system_add() { local cfg="$1" config_get syslocation "$cfg" sysLocation - [ -n "$syslocation" ] && echo "sysLocation $syslocation" >> $RUN_C + [ -n "$syslocation" ] && echo "sysLocation $syslocation" >> $CONFIGFILE config_get syscontact "$cfg" sysContact - [ -n "$syscontact" ] && echo "sysContact $syscontact" >> $RUN_C + [ -n "$syscontact" ] && echo "sysContact $syscontact" >> $CONFIGFILE config_get sysname "$cfg" sysName - [ -n "$sysname" ] && echo "sysName $sysname" >> $RUN_C + [ -n "$sysname" ] && echo "sysName $sysname" >> $CONFIGFILE config_get sysservice "$cfg" sysService - [ -n "$sysservice" ] && echo "sysService $sysservice" >> $RUN_C + [ -n "$sysservice" ] && echo "sysService $sysservice" >> $CONFIGFILE config_get sysdescr "$cfg" sysDescr - [ -n "$sysdescr" ] && echo "sysDescr $sysdescr" >> $RUN_C + [ -n "$sysdescr" ] && echo "sysDescr $sysdescr" >> $CONFIGFILE config_get sysobjectid "$cfg" sysObjectID - [ -n "$sysobjectid" ] && echo "sysObjectID $sysobjectid" >> $RUN_C + [ -n "$sysobjectid" ] && echo "sysObjectID $sysobjectid" >> $CONFIGFILE } + snmpd_com2sec_add() { local cfg="$1" config_get secname "$cfg" secname @@ -39,8 +39,9 @@ snmpd_com2sec_add() { [ -n "$source" ] || return 0 config_get community "$cfg" community [ -n "$community" ] || return 0 - echo "com2sec $secname $source $community" >> $RUN_C + echo "com2sec $secname $source $community" >> $CONFIGFILE } + snmpd_com2sec6_add() { local cfg="$1" config_get secname "$cfg" secname @@ -49,8 +50,9 @@ snmpd_com2sec6_add() { [ -n "$source" ] || return 0 config_get community "$cfg" community [ -n "$community" ] || return 0 - echo "com2sec6 $secname $source $community" >> $RUN_C + echo "com2sec6 $secname $source $community" >> $CONFIGFILE } + snmpd_group_add() { local cfg="$1" config_get group "$cfg" group @@ -59,8 +61,9 @@ snmpd_group_add() { [ -n "$version" ] || return 0 config_get secname "$cfg" secname [ -n "$secname" ] || return 0 - echo "group $group $version $secname" >> $RUN_C + echo "group $group $version $secname" >> $CONFIGFILE } + snmpd_view_add() { local cfg="$1" config_get viewname "$cfg" viewname @@ -71,8 +74,9 @@ snmpd_view_add() { [ -n "$oid" ] || return 0 # optional mask config_get mask "$cfg" mask - echo "view $viewname $type $oid $mask" >> $RUN_C + echo "view $viewname $type $oid $mask" >> $CONFIGFILE } + snmpd_access_add() { local cfg="$1" config_get group "$cfg" group @@ -92,8 +96,9 @@ snmpd_access_add() { [ -n "$write" ] || return 0 config_get notify "$cfg" notify [ -n "$notify" ] || return 0 - echo "access $group $context $version $level $prefix $read $write $notify" >> $RUN_C + echo "access $group $context $version $level $prefix $read $write $notify" >> $CONFIGFILE } + snmpd_pass_add() { local cfg="$1" local pass='pass' @@ -106,8 +111,9 @@ snmpd_pass_add() { [ $persist -ne 0 ] && pass='pass_persist' config_get priority "$cfg" priority priority=${priority:+-p $priority} - echo "$pass $priority $miboid $prog" >> $RUN_C + echo "$pass $priority $miboid $prog" >> $CONFIGFILE } + snmpd_exec_add() { local cfg="$1" @@ -117,8 +123,9 @@ snmpd_exec_add() { [ -n "$prog" ] || return 0 config_get args "$cfg" args config_get miboid "$cfg" miboid - echo "exec $miboid $name $prog $args" >> $RUN_C + echo "exec $miboid $name $prog $args" >> $CONFIGFILE } + snmpd_disk_add() { local cfg="$1" local disk='disk' @@ -127,13 +134,13 @@ snmpd_disk_add() { [ -n "$partition" ] || return 0 config_get size "$cfg" size [ -n "$size" ] || return 0 - echo "$disk $partition $size" >> $RUN_C + echo "$disk $partition $size" >> $CONFIGFILE } -start() { - [ -d $LIB_D ] || mkdir -p $LIB_D - [ -d $LOG_D ] || mkdir -p $LOG_D - [ -d $RUN_D ] || mkdir -p $RUN_D - [ -f $RUN_C ] && rm -f $RUN_C + +start_service() { + [ -f "$CONFIGFILE" ] && rm -f "$CONFIGFILE" + + procd_open_instance config_load snmpd @@ -148,10 +155,17 @@ start() { config_foreach snmpd_exec_add exec config_foreach snmpd_disk_add disk - [ -f $DEFAULT ] && . $DEFAULT - $DEBUG /usr/sbin/snmpd $OPTIONS + procd_set_param command $PROG -Lf /dev/null -f + procd_set_param file $CONFIGFILE + procd_set_param respawn + + for iface in $(ls /sys/class/net 2>/dev/null); do + procd_append_param netdev "$iface" + done + + procd_close_instance } -stop() { - [ -f $PID_F ] && kill $(cat $PID_F) - [ -f $RUN_C ] && rm -f $RUN_C + +stop_service() { + [ -f "$CONFIGFILE" ] && rm -f "$CONFIGFILE" } diff --git a/net/net-snmp/patches/900-musl-compat.patch b/net/net-snmp/patches/900-musl-compat.patch new file mode 100644 index 000000000..fa9a01e1b --- /dev/null +++ b/net/net-snmp/patches/900-musl-compat.patch @@ -0,0 +1,14 @@ +--- a/agent/mibgroup/iwlib.h ++++ b/agent/mibgroup/iwlib.h +@@ -85,6 +85,11 @@ + && LINUX_VERSION_CODE < KERNEL_VERSION(2,1,0) + #define LIBC5_HEADERS + ++/* Musl */ ++#elif !defined(__GLIBC__) && !defined(__UCLIBC__) \ ++ && LINUX_VERSION_CODE >= KERNEL_VERSION(3,0,0) ++#define GENERIC_HEADERS ++ + /* Unsupported combination */ + #else + #error "Your kernel/libc combination is not supported" diff --git a/net/netdiscover/Makefile b/net/netdiscover/Makefile new file mode 100644 index 000000000..086279908 --- /dev/null +++ b/net/netdiscover/Makefile @@ -0,0 +1,42 @@ +# +# Copyright (C) 2015 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:=netdiscover +PKG_VERSION:=0.3-pre-beta7 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-LINUXONLY.tar.gz +PKG_SOURCE_URL:=http://nixgeneration.com/~jaime/netdiscover/releases/ +PKG_MD5SUM:=8780e66d00496e933b4064cfe9ae61da +PKG_MAINTAINER:=Mislav Novakovic +PKG_LICENSE:=GPL-2.0 + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/netdiscover + SECTION:=net + CATEGORY:=Network + DEPENDS:=+libpcap +libnet-1.2.x +libpthread + TITLE:=An active/passive address reconnaissance tool + URL:=http://nixgeneration.com/~jaime/netdiscover/ +endef + +CONFIGURE_VARS+= \ + CPPFLAGS="$(TARGET_CPPFLAGS) -I$(STAGING_DIR)/usr/lib/libnet-1.2.x/lib" \ + LDFLAGS="$(TARGET_LDFLAGS) -L$(STAGING_DIR)/usr/lib/libnet-1.2.x/lib" + +define Package/netdiscover/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/netdiscover $(1)/usr/sbin/ +endef + +$(eval $(call BuildPackage,netdiscover)) diff --git a/net/nfs-kernel-server/Makefile b/net/nfs-kernel-server/Makefile index 791676a23..e66fe65f5 100644 --- a/net/nfs-kernel-server/Makefile +++ b/net/nfs-kernel-server/Makefile @@ -1,4 +1,4 @@ -# Copyright (C) 2009 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=nfs-kernel-server PKG_VERSION:=1.3.2 -PKG_RELEASE:=1 +PKG_RELEASE:=4 PKG_MD5SUM:=1e2f3c1ed468dee02d00c534c002ea10 PKG_SOURCE_URL:=@SF/nfs @@ -85,6 +85,7 @@ CONFIGURE_ARGS += \ --disable-nfsdcld CONFIGURE_VARS += \ + libblkid_cv_is_recent=yes \ CONFIG_SQLITE3_TRUE="\#" \ CONFIG_NFSDCLD_TRUE="\#" diff --git a/net/nginx/Makefile b/net/nginx/Makefile index e93326e52..667bacb5d 100644 --- a/net/nginx/Makefile +++ b/net/nginx/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2012 OpenWrt.org +# Copyright (C) 2012-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=nginx PKG_VERSION:=1.4.7 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://nginx.org/download/ diff --git a/net/nginx/patches/100-musl-no-sysctl.patch b/net/nginx/patches/100-musl-no-sysctl.patch new file mode 100644 index 000000000..4e35bf6ba --- /dev/null +++ b/net/nginx/patches/100-musl-no-sysctl.patch @@ -0,0 +1,35 @@ +Index: nginx-1.4.7/src/os/unix/ngx_linux_config.h +=================================================================== +--- nginx-1.4.7.orig/src/os/unix/ngx_linux_config.h ++++ nginx-1.4.7/src/os/unix/ngx_linux_config.h +@@ -51,7 +51,6 @@ + #include /* memalign() */ + #include /* IOV_MAX */ + #include +-#include + #include + #include /* uname() */ + +--- nginx-1.2.7/src/os/unix/ngx_user.c ++++ nginx-1.2.7-patched/src/os/unix/ngx_user.c +@@ -31,8 +31,6 @@ + struct crypt_data cd; + + cd.initialized = 0; +- /* work around the glibc bug */ +- cd.current_salt[0] = ~salt[0]; + + value = crypt_r((char *) key, (char *) salt, &cd); + +diff --git a/auto/lib/openssl/conf b/auto/lib/openssl/conf +index 528ee17..73ef359 100644 +--- a/auto/lib/openssl/conf ++++ b/auto/lib/openssl/conf +@@ -47,7 +47,7 @@ else + ngx_feature_run=no + ngx_feature_incs="#include " + ngx_feature_path= +- ngx_feature_libs="-lssl -lcrypto" ++ ngx_feature_libs="-lssl -lcrypto -lz" + ngx_feature_test="SSL_library_init()" + . auto/feature diff --git a/net/nsd/Makefile b/net/nsd/Makefile index ba1c1993f..14b2144a4 100644 --- a/net/nsd/Makefile +++ b/net/nsd/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 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:=nsd -PKG_VERSION:=4.0.3 +PKG_VERSION:=4.1.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.nlnetlabs.nl/downloads/nsd -PKG_MD5SUM:=9331dd18478295206775433a0b23e490 +PKG_MD5SUM:=73014bab5514b9babaf6c9007a6b36d8 PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/net/ntpd/Makefile b/net/ntpd/Makefile index 34a8ddae9..787e77955 100644 --- a/net/ntpd/Makefile +++ b/net/ntpd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ntp -PKG_VERSION:=4.2.8p1 -PKG_RELEASE:=1 +PKG_VERSION:=4.2.8p2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ -PKG_MD5SUM:=65d8cdfae4722226fbe29863477641ed +PKG_MD5SUM:=fa37049383316322d060ec9061ac23a9 PKG_LICENSE:=Unique PKG_LICENSE_FILES:=COPYRIGHT html/copyright.html @@ -93,7 +93,9 @@ endef CONFIGURE_VARS += \ ac_cv_header_md5_h=no \ ac_cv_lib_rt_sched_setscheduler=no \ - ac_cv_header_dns_sd_h=no + ac_cv_header_dns_sd_h=no \ + hw_cv_func_snprintf_c99=yes \ + hw_cv_func_vsnprintf_c99=yes \ CONFIGURE_ARGS += \ --disable-all-clocks \ @@ -103,6 +105,7 @@ CONFIGURE_ARGS += \ --enable-NMEA \ --enable-LOCAL-CLOCK \ --enable-SHM \ + --enable-ATOM \ --enable-linuxcaps \ --with-yielding-select=yes \ --with-crypto \ diff --git a/net/ntpd/files/ntpd.hotplug b/net/ntpd/files/ntpd.hotplug index 992628f6c..975be751e 100644 --- a/net/ntpd/files/ntpd.hotplug +++ b/net/ntpd/files/ntpd.hotplug @@ -1,6 +1,6 @@ NAME=ntpd CONFIG=/etc/ntp.conf -COMMAND=/usr/sbin/$NAME +COMMAND=/sbin/$NAME [ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && { [ -x $COMMAND ] && [ -r $CONFIG ] && { diff --git a/net/ntripclient/Makefile b/net/ntripclient/Makefile index 249f75ba2..2276b31ad 100644 --- a/net/ntripclient/Makefile +++ b/net/ntripclient/Makefile @@ -1,6 +1,6 @@ # # Copyright (C) 2011 segal.ubi.pt -# Copyright (C) 2010-2014 OpenWrt.org +# Copyright (C) 2010-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ntripclient PKG_VERSION:=1.5.0 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_LICENSE:=GPL-2.0+ PKG_SOURCE:=$(PKG_NAME).zip @@ -36,6 +36,7 @@ endef define Build/Prepare mkdir -p $(PKG_BUILD_DIR) unzip $(DL_DIR)/$(PKG_SOURCE) -d $(PKG_BUILD_DIR) + $(call Build/Prepare/Default) endef MAKE_FLAGS += \ diff --git a/net/ntripclient/patches/100-musl-compat.patch b/net/ntripclient/patches/100-musl-compat.patch new file mode 100644 index 000000000..10f690fd9 --- /dev/null +++ b/net/ntripclient/patches/100-musl-compat.patch @@ -0,0 +1,10 @@ +--- a/ntripclient.c ++++ b/ntripclient.c +@@ -44,6 +44,7 @@ + #include + #include + #include ++ #include + #include + #include + #include diff --git a/net/nut/Makefile b/net/nut/Makefile index d23b7cb5d..32a3e1343 100644 --- a/net/nut/Makefile +++ b/net/nut/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=nut -PKG_VERSION:=2.7.2 +PKG_VERSION:=2.7.3 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.networkupstools.org/source/2.7/ -PKG_MD5SUM:=c3568b42e058cfc385b46d25140dced4 +PKG_MD5SUM:=a1a7f747093663e1f39ab595b63b45e4 PKG_MAINTAINER:=Martin Rowe PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=LICENSE-GPL2 diff --git a/net/nut/patches/001-fix-missing-libmath-flags.patch b/net/nut/patches/001-fix-missing-libmath-flags.patch deleted file mode 100644 index 88996be6e..000000000 --- a/net/nut/patches/001-fix-missing-libmath-flags.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/drivers/Makefile.am -+++ b/drivers/Makefile.am -@@ -171,7 +171,7 @@ tripplite_usb_SOURCES = tripplite_usb.c - tripplite_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm - - bcmxcp_usb_SOURCES = bcmxcp_usb.c bcmxcp.c usb-common.c --bcmxcp_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -+bcmxcp_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm - - blazer_usb_SOURCES = blazer.c blazer_usb.c libusb.c usb-common.c - blazer_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm ---- a/drivers/Makefile.in -+++ b/drivers/Makefile.in -@@ -785,7 +785,7 @@ usbhid_ups_LDADD = $(LDADD_DRIVERS) $(LI - tripplite_usb_SOURCES = tripplite_usb.c libusb.c usb-common.c - tripplite_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm - bcmxcp_usb_SOURCES = bcmxcp_usb.c bcmxcp.c usb-common.c --bcmxcp_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -+bcmxcp_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm - blazer_usb_SOURCES = blazer.c blazer_usb.c libusb.c usb-common.c - blazer_usb_LDADD = $(LDADD_DRIVERS) $(LIBUSB_LIBS) -lm - nutdrv_atcl_usb_SOURCES = nutdrv_atcl_usb.c usb-common.c diff --git a/net/nut/patches/010-ignore_automake_k_bug.patch b/net/nut/patches/010-ignore_automake_k_bug.patch deleted file mode 100644 index 8d3645d09..000000000 --- a/net/nut/patches/010-ignore_automake_k_bug.patch +++ /dev/null @@ -1,28 +0,0 @@ ---- a/Makefile.in -+++ b/Makefile.in -@@ -431,12 +431,6 @@ distclean-libtool: - # (2) otherwise, pass the desired values on the `make' command line. - $(RECURSIVE_TARGETS): - @fail= failcom='exit 1'; \ -- for f in x $$MAKEFLAGS; do \ -- case $$f in \ -- *=* | --[!k]*);; \ -- *k*) failcom='fail=yes';; \ -- esac; \ -- done; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ -@@ -456,12 +450,6 @@ $(RECURSIVE_TARGETS): - - $(RECURSIVE_CLEAN_TARGETS): - @fail= failcom='exit 1'; \ -- for f in x $$MAKEFLAGS; do \ -- case $$f in \ -- *=* | --[!k]*);; \ -- *k*) failcom='fail=yes';; \ -- esac; \ -- done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ diff --git a/net/ocserv/Config.in b/net/ocserv/Config.in index 88c5f5091..b6460cd8e 100644 --- a/net/ocserv/Config.in +++ b/net/ocserv/Config.in @@ -11,6 +11,10 @@ config OCSERV_SECCOMP bool "enable seccomp" default n +config OCSERV_RADIUS + bool "enable radius authentication" + default n + config OCSERV_PROTOBUF bool "use external libprotobuf" default y diff --git a/net/ocserv/Makefile b/net/ocserv/Makefile index 529071d2c..a59e9dc0d 100644 --- a/net/ocserv/Makefile +++ b/net/ocserv/Makefile @@ -8,13 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ocserv -PKG_VERSION:=0.9.2 -PKG_RELEASE:=1 +PKG_VERSION:=0.10.5 +PKG_RELEASE:=2 +PKG_USE_MIPS16:=0 PKG_BUILD_DIR :=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL :=ftp://ftp.infradead.org/pub/ocserv/ -PKG_MD5SUM:=9697c37cc81b30be2b178258ee595d97 +PKG_SOURCE_URL:=ftp://ftp.infradead.org/pub/ocserv/ +PKG_MD5SUM:=17ee861f352d6ef7cd33114819b215ba PKG_LICENSE:=GPLv2 PKG_LICENSE_FILES:=COPYING @@ -38,7 +39,7 @@ define Package/ocserv TITLE:=OpenConnect VPN server URL:=http://www.infradead.org/ocserv/ MAINTAINER:=Nikos Mavrogiannopoulos - DEPENDS:= +OCSERV_HTTP_PARSER:libhttp-parser +OCSERV_SECCOMP:libseccomp +libgnutls +certtool +libncurses +libreadline +OCSERV_PAM:libpam +OCSERV_PROTOBUF:libprotobuf-c +kmod-tun + DEPENDS:= +OCSERV_RADIUS:libradcli +OCSERV_HTTP_PARSER:libhttp-parser +OCSERV_SECCOMP:libseccomp +libgnutls +certtool +libncurses +libreadline +OCSERV_PAM:libpam +OCSERV_PROTOBUF:libprotobuf-c +kmod-tun USERID:=ocserv=72:ocserv=72 endef @@ -58,11 +59,17 @@ CONFIGURE_ARGS+= \ --enable-local-libopts \ --with-libreadline-prefix="$(STAGING_DIR)/" \ --without-libnl \ + --without-gssapi \ + --with-libcrypt-prefix="$(STAGING_DIR)/" \ ifneq ($(CONFIG_OCSERV_PAM),y) CONFIGURE_ARGS += --without-pam endif +ifneq ($(CONFIG_OCSERV_RADIUS),y) +CONFIGURE_ARGS += --without-radius +endif + ifneq ($(CONFIG_OCSERV_SECCOMP),y) CONFIGURE_ARGS += --disable-seccomp endif diff --git a/net/ocserv/files/ocserv.conf.template b/net/ocserv/files/ocserv.conf.template index 1694fd782..dce96d832 100644 --- a/net/ocserv/files/ocserv.conf.template +++ b/net/ocserv/files/ocserv.conf.template @@ -18,7 +18,7 @@ auth = "|AUTH|" # A banner to be displayed on clients banner = "Welcome to OpenWRT" -isolate-workers = true +#isolate-workers = true # When the server has a dynamic DNS address (that may change), # should set that to true to ask the client to resolve again on @@ -35,7 +35,7 @@ max-clients = |MAX_CLIENTS| # Limit the number of client connections to one every X milliseconds # (X is the provided value). Set to zero for no limit. -#rate-limit-ms = 100 +rate-limit-ms = 100 # Limit the number of identical clients (i.e., users connecting # multiple times). Unset or set to zero for unlimited. @@ -142,6 +142,27 @@ auth-timeout = 40 # a failed authentication attempt. min-reauth-time = 360 +# Banning clients in ocserv works with a point system. IP addresses +# that get a score over that configured number are banned for +# min-reauth-time seconds. By default a wrong password attempt is 10 points, +# a KKDCP POST is 1 point, and a connection is 1 point. Note that +# due to difference processes being involved the count of points +# will not be real-time precise. +# +# Score banning cannot be reliably used when receiving proxied connections +# locally from an HTTP server (i.e., when listen-clear-file is used). +# +# Set to zero to disable. +max-ban-score = 50 + +# The time (in seconds) that all score kept for a client is reset. +ban-reset-time = 300 + +# In case you'd like to change the default points. +#ban-points-wrong-password = 10 +#ban-points-connection = 1 +#ban-points-kkdcp = 1 + # Cookie timeout (in seconds) # which he can reconnect. That cookie will be invalided if not # used within this timeout value. On a user disconnection, that diff --git a/net/ocserv/files/ocserv.init b/net/ocserv/files/ocserv.init index aee342d68..c4597a40f 100644 --- a/net/ocserv/files/ocserv.init +++ b/net/ocserv/files/ocserv.init @@ -1,8 +1,7 @@ #!/bin/sh /etc/rc.common -SERVICE_USE_PID=1 - START=50 +USE_PROCD=1 setup_config() { config_get port $1 port "4443" @@ -34,10 +33,10 @@ setup_config() { ipv6_addr=`echo $ip6addr|cut -d '/' -f 1` ipv6_prefix=`echo $ip6addr|cut -d '/' -f 2` - test $auth = "plain" && authsuffix="\[/var/etc/ocpasswd\]" + test $auth = "plain" && authsuffix="\[passwd=/var/etc/ocpasswd\]" dyndns="false" - hostname=`uci show ddns|grep domain|head -1|cut -d '=' -f 2 2>/dev/null` + hostname=`uci show ddns 2>/dev/null|grep domain|head -1|cut -d '=' -f 2` [ -n "$hostname" ] && dyndns="true" mkdir -p /var/etc @@ -67,10 +66,9 @@ setup_users() { local password config_get name $1 name - config_get group $1 group + config_get group $1 group '*' config_get password $1 password - [ -z "$group" ] && group='*' [ -z "$name" -o -z "$password" ] && return echo "$name:$group:$password" >> /var/etc/ocpasswd @@ -97,10 +95,10 @@ setup_dns() { echo "dns = $ip" >> /var/etc/ocserv.conf } -start() { +start_service() { local hostname iface - hostname=`uci show ddns|grep domain|head -1|cut -d '=' -f 2 2>/dev/null` + hostname=`uci show ddns 2>/dev/null|grep domain|head -1|cut -d '=' -f 2` [ -z "$hostname" ] && hostname=`uci get system.@system[0].hostname 2>/dev/null` [ -f /etc/config/ocserv-dir/ca-key.pem ] && mv /etc/config/ocserv-dir/ca-key.pem /etc/ocserv/ca-key.pem @@ -163,23 +161,8 @@ start() { chmod 600 /var/etc/ocpasswd config_foreach setup_users ocservusers - service_start /usr/sbin/ocserv -c /var/etc/ocserv.conf -} - -stop() { - service_stop /usr/sbin/ocserv -} - -reload() { - rm -f /var/etc/ocpasswd - touch /var/etc/ocpasswd - chmod 600 /var/etc/ocpasswd - config_foreach setup_users ocservusers - - /usr/bin/occtl show status >/dev/null 2>&1 - if test $? != 0;then - start - else - /usr/bin/occtl reload - fi + procd_open_instance + procd_set_param command /usr/sbin/ocserv -f -c /var/etc/ocserv.conf + procd_set_param respawn + procd_close_instance } diff --git a/net/openconnect/Makefile b/net/openconnect/Makefile index c3098b4d3..38ac391c1 100644 --- a/net/openconnect/Makefile +++ b/net/openconnect/Makefile @@ -8,12 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openconnect -PKG_VERSION:=7.04 -PKG_RELEASE:=3 +PKG_VERSION:=7.06 +PKG_RELEASE:=1 +PKG_USE_MIPS16:=0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=ftp://ftp.infradead.org/pub/openconnect/ -PKG_MD5SUM:=828fe81388b7ea1155419b8be64a350f +PKG_MD5SUM:=80f397911e1fed43d897d99be3d5f1a1 PKG_CONFIG_DEPENDS:= \ CONFIG_OPENCONNECT_GNUTLS \ diff --git a/net/openconnect/README b/net/openconnect/README index f6d2f051c..772b0e3cc 100644 --- a/net/openconnect/README +++ b/net/openconnect/README @@ -10,10 +10,22 @@ config interface 'MYVPN' option username 'test' option password 'secret' option serverhash 'AE7FF6A0426F0A0CD0A02EB9EC3C5066FAEB0B25' - option token_mode 'rsa' # when built with stoken support - option token_secret 'secret' # when built with stoken support + option defaultroute '0' option authgroup 'DEFAULT' + # For second factor auth: + + # when a fixed 2FA password can be used + #option password2 'my-fixed-2fa-password' + + # RSA tokens, must be built with stoken support + #option token_mode 'rsa' + #option token_secret 'secret' + + # HOTP/TOTP tokens + #option token_mode 'hotp' + #option token_secret '00' + The additional files are also used: /etc/openconnect/user-cert-vpn-MYVPN.pem: The user certificate /etc/openconnect/user-key-vpn-MYVPN.pem: The user private key diff --git a/net/openconnect/files/openconnect.sh b/net/openconnect/files/openconnect.sh index bdac9bc86..9b1e652bd 100755 --- a/net/openconnect/files/openconnect.sh +++ b/net/openconnect/files/openconnect.sh @@ -10,9 +10,12 @@ proto_openconnect_init_config() { proto_config_add_string "serverhash" proto_config_add_string "authgroup" proto_config_add_string "password" + proto_config_add_string "password2" proto_config_add_string "token_mode" proto_config_add_string "token_secret" proto_config_add_string "interface" + proto_config_add_string "os" + proto_config_add_string "csd_wrapper" no_device=1 available=1 } @@ -20,7 +23,7 @@ proto_openconnect_init_config() { proto_openconnect_setup() { local config="$1" - json_get_vars server port username serverhash authgroup password interface token_mode token_secret + json_get_vars server port username serverhash authgroup password password2 interface token_mode token_secret os csd_wrapper grep -q tun /proc/modules || insmod tun @@ -63,11 +66,14 @@ proto_openconnect_setup() { mkdir -p /var/etc pwfile="/var/etc/openconnect-$config.passwd" echo "$password" > "$pwfile" + [ -n "$password2" ] && echo "$password2" >> "$pwfile" append cmdline "--passwd-on-stdin" } [ -n "$token_mode" ] && append cmdline "--token-mode=$token_mode" [ -n "$token_secret" ] && append cmdline "--token-secret=$token_secret" + [ -n "$os" ] && append cmdline "--os=$os" + [ -n "$csd_wrapper" ] && [ -x "$csd_wrapper" ] && append cmdline "--csd-wrapper=$csd_wrapper" proto_export INTERFACE="$config" logger -t openconnect "executing 'openconnect $cmdline'" diff --git a/net/openconnect/patches/001-Allow-processing-two-passwords-from-stdin-in-non-int.patch b/net/openconnect/patches/001-Allow-processing-two-passwords-from-stdin-in-non-int.patch new file mode 100644 index 000000000..be652f8eb --- /dev/null +++ b/net/openconnect/patches/001-Allow-processing-two-passwords-from-stdin-in-non-int.patch @@ -0,0 +1,125 @@ +From 5f2e24fdc9935d049a7e4a5b6e10461e9467597f Mon Sep 17 00:00:00 2001 +From: Nikos Mavrogiannopoulos +Date: Thu, 18 Jun 2015 22:38:05 +0200 +Subject: [PATCH] Allow processing two passwords from stdin in non-interactive + mode + +Signed-off-by: Nikos Mavrogiannopoulos +--- + main.c | 38 ++++++++++++++++++++++++++------------ + 1 file changed, 26 insertions(+), 12 deletions(-) + +diff --git a/main.c b/main.c +index 3b976d8..f853afe 100644 +--- a/main.c ++++ b/main.c +@@ -85,6 +85,7 @@ static int do_passphrase_from_fsid; + static int nocertcheck; + static int non_inter; + static int cookieonly; ++static int allow_stdin_read; + + static char *token_filename; + static char *server_cert = NULL; +@@ -358,7 +359,7 @@ static char *convert_arg_to_utf8(char **argv, char *arg) + #define vfprintf vfprintf_utf8 + #define is_arg_utf8(str) (0) + +-static void read_stdin(char **string, int hidden) ++static void read_stdin(char **string, int hidden, int allow_fail) + { + CONSOLE_READCONSOLE_CONTROL rcc = { sizeof(rcc), 0, 13, 0 }; + HANDLE stdinh = GetStdHandle(STD_INPUT_HANDLE); +@@ -375,6 +376,7 @@ static void read_stdin(char **string, int hidden) + char *errstr = openconnect__win32_strerror(GetLastError()); + fprintf(stderr, _("ReadConsole() failed: %s\n"), errstr); + free(errstr); ++ *string = NULL; + goto out; + } + +@@ -622,7 +624,7 @@ static void print_build_opts(void) + + #ifndef _WIN32 + static const char default_vpncscript[] = DEFAULT_VPNCSCRIPT; +-static void read_stdin(char **string, int hidden) ++static void read_stdin(char **string, int hidden, int allow_fail) + { + char *c, *buf = malloc(1025); + int fd = fileno(stdin); +@@ -648,8 +650,14 @@ static void read_stdin(char **string, int hidden) + } + + if (!buf) { +- perror(_("fgets (stdin)")); +- exit(1); ++ if (allow_fail) { ++ *string = NULL; ++ free(buf); ++ return; ++ } else { ++ perror(_("fgets (stdin)")); ++ exit(1); ++ } + } + + c = strchr(buf, '\n'); +@@ -1160,13 +1168,14 @@ int main(int argc, char **argv) + cookieonly = 3; + break; + case OPT_COOKIE_ON_STDIN: +- read_stdin(&vpninfo->cookie, 0); ++ read_stdin(&vpninfo->cookie, 0, 0); + /* If the cookie is empty, ignore it */ + if (!*vpninfo->cookie) + vpninfo->cookie = NULL; + break; + case OPT_PASSWORD_ON_STDIN: +- read_stdin(&password, 0); ++ read_stdin(&password, 0, 0); ++ allow_stdin_read = 1; + break; + case OPT_NO_PASSWD: + vpninfo->nopasswd = 1; +@@ -1708,7 +1717,7 @@ static int validate_peer_cert(void *_vpninfo, const char *reason) + fprintf(stderr, _("Enter '%s' to accept, '%s' to abort; anything else to view: "), + _("yes"), _("no")); + +- read_stdin(&response, 0); ++ read_stdin(&response, 0, 0); + if (!response) + return -EINVAL; + +@@ -1779,19 +1788,24 @@ static char *prompt_for_input(const char *prompt, + struct openconnect_info *vpninfo, + int hidden) + { +- char *response; ++ char *response = NULL; + + fprintf(stderr, "%s", prompt); + fflush(stderr); + + if (non_inter) { +- fprintf(stderr, "***\n"); +- vpn_progress(vpninfo, PRG_ERR, ++ if (allow_stdin_read) { ++ read_stdin(&response, hidden, 1); ++ } ++ if (response == NULL) { ++ fprintf(stderr, "***\n"); ++ vpn_progress(vpninfo, PRG_ERR, + _("User input required in non-interactive mode\n")); +- return NULL; ++ } ++ return response; + } + +- read_stdin(&response, hidden); ++ read_stdin(&response, hidden, 0); + return response; + } + +-- +2.1.4 + diff --git a/net/openssh/Makefile b/net/openssh/Makefile index 055b0030e..279fa0ba4 100644 --- a/net/openssh/Makefile +++ b/net/openssh/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openssh -PKG_VERSION:=6.7p1 -PKG_RELEASE:=3 +PKG_VERSION:=6.8p1 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/ \ http://ftp.belnet.be/pub/OpenBSD/OpenSSH/portable/ -PKG_MD5SUM:=3246aa79317b1d23cae783a3bf8275d6 +PKG_MD5SUM:=08f72de6751acfbd0892b5f003922701 PKG_LICENSE:=BSD ISC PKG_LICENSE_FILES:=LICENCE @@ -29,7 +29,7 @@ include $(INCLUDE_DIR)/package.mk define Package/openssh/Default SECTION:=net CATEGORY:=Network - DEPENDS:=+libopenssl +zlib +SSP_SUPPORT:libssp + DEPENDS:=+libopenssl +zlib TITLE:=OpenSSH MAINTAINER:=Peter Wagner URL:=http://www.openssh.com/ @@ -124,7 +124,8 @@ endef define Package/openssh-sftp-server $(call Package/openssh/Default) TITLE+= SFTP server - DEPENDS:=+SSP_SUPPORT:libssp + # Strip dependencies to avoid pulling in OpenSSL etc. + DEPENDS:= endef define Package/openssh-sftp-server/description diff --git a/net/openssh/patches/130-implicit_memset_decl_fix.patch b/net/openssh/patches/130-implicit_memset_decl_fix.patch index be8bbcf9c..7d46d20d3 100644 --- a/net/openssh/patches/130-implicit_memset_decl_fix.patch +++ b/net/openssh/patches/130-implicit_memset_decl_fix.patch @@ -1,6 +1,6 @@ --- a/includes.h +++ b/includes.h -@@ -59,6 +59,9 @@ +@@ -60,6 +60,9 @@ /* *-*-nto-qnx needs these headers for strcasecmp and LASTLOG_FILE respectively */ diff --git a/net/opentracker/Makefile b/net/opentracker/Makefile index 9fafaf2e3..4422cd399 100644 --- a/net/opentracker/Makefile +++ b/net/opentracker/Makefile @@ -8,9 +8,9 @@ include $(TOPDIR)/rules.mk PKG_NAME:=opentracker -PKG_VERSION:=20141007 +PKG_VERSION:=20150427 PKG_RELEASE:=1 -PKG_REV:=6c60309745ced3c121a2c5c7d80ed85a573b848e +PKG_REV:=27499d7a55bde404f3273a23026f2495e96adf87 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=Beerware diff --git a/net/openvswitch/Makefile b/net/openvswitch/Makefile index 7f3737cfb..d51d78a76 100644 --- a/net/openvswitch/Makefile +++ b/net/openvswitch/Makefile @@ -11,8 +11,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openvswitch -PKG_RELEASE:=2 -PKG_VERSION:=2.3.1 +PKG_RELEASE:=3 +PKG_VERSION:=2.3.90 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_LICENSE:=Apache-2.0 PKG_LICENSE_FILES:=COPYING @@ -21,15 +21,19 @@ PKG_USE_MIPS16:=0 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/openvswitch/ovs PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=0dfed4ba9c8a16a1f316d709b7831a4e139472d4 +PKG_SOURCE_VERSION:=58be9c9fd732b5bdd3d4c2e9b8cc2313f570094d PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz +PKG_BUILD_PARALLEL:=1 +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +SUPPORTED_KERNELS:=LINUX_3_8||LINUX_3_10||LINUX_3_13||LINUX_3_14||LINUX_3_18||LINUX_4_0 + include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/kernel.mk $(call include_mk, python-package.mk) -PKG_FIXUP=libtool - define Package/openvswitch/Default SECTION:=net CATEGORY:=Network @@ -50,7 +54,7 @@ endef define Package/openvswitch $(call Package/openvswitch/Default) TITLE:=Open vSwitch Userspace Package - DEPENDS:=+libpcap +libopenssl +librt +libatomic +kmod-openvswitch + DEPENDS:=+libpcap +libopenssl +librt +kmod-openvswitch @($(SUPPORTED_KERNELS)) endef define Package/openvswitch/description @@ -94,7 +98,7 @@ define KernelPackage/openvswitch SUBMENU:=Network Support TITLE:=Open vSwitch Kernel Package KCONFIG:=CONFIG_BRIDGE - DEPENDS:=+kmod-stp +kmod-ipv6 +kmod-gre +kmod-lib-crc32c +kmod-vxlan + DEPENDS:=+kmod-stp +kmod-ipv6 +kmod-gre +kmod-lib-crc32c +kmod-vxlan @($(SUPPORTED_KERNELS)) FILES:= \ $(PKG_BUILD_DIR)/datapath/linux/openvswitch.$(LINUX_KMOD_SUFFIX) AUTOLOAD:=$(call AutoLoad,21,openvswitch) @@ -110,35 +114,7 @@ CONFIGURE_ARGS += --enable-ndebug CONFIGURE_ARGS += --disable-ssl CONFIGURE_ARGS += --enable-shared -TARGET_CFLAGS += -flto - -define Build/Configure - (cd $(PKG_BUILD_DIR); \ - autoreconf -v --install --force || exit 1 \ - ); - $(call Build/Configure/Default,$(CONFIGURE_ARGS)) -endef - -KCFLAGS= -ifeq ($(CONFIG_GCC_VERSION_4_9),y) -KCFLAGS:=-Wno-error=date-time -endif - -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - $(TARGET_CONFIGURE_OPTS) \ - CFLAGS="-I$(PKG_BUILD_DIR)/lib $(TARGET_CFLAGS) -std=gnu99" \ - LDFLAGS="-L$(PKG_BUILD_DIR)/lib $(TARGET_LDFLAGS)" \ - LDFLAGS_MODULES="$(TARGET_LDFLAGS) -L$(PKG_BUILD_DIR)/lib" \ - STAGING_DIR="$(STAGING_DIR)" \ - DESTDIR="$(PKG_INSTALL_DIR)/usr" \ - CROSS_COMPILE="$(TARGET_CROSS)" \ - ARCH="$(LINUX_KARCH)" \ - SUBDIRS="$(PKG_BUILD_DIR)/datapath/linux" \ - PATH="$(TARGET_PATH)" \ - EXTRA_CFLAGS="$(KCFLAGS)" \ - KCC="$(KERNEL_CC)" -endef +TARGET_CFLAGS += -flto -std=gnu99 define Package/openvswitch/install $(INSTALL_DIR) $(1)/etc/openvswitch @@ -147,10 +123,10 @@ define Package/openvswitch/install $(INSTALL_BIN) ./files/etc/init.d/openvswitch.init $(1)/etc/init.d/openvswitch $(INSTALL_DIR) $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/lib/.libs/libsflow-$(PKG_VERSION).so $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/lib/.libs/libopenvswitch-$(PKG_VERSION).so $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/ofproto/.libs/libofproto-$(PKG_VERSION).so $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/ovsdb/.libs/libovsdb-$(PKG_VERSION).so $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/lib/.libs/libsflow.so* $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/lib/.libs/libopenvswitch.so* $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/ofproto/.libs/libofproto.so* $(1)/usr/lib/ + $(CP) $(PKG_BUILD_DIR)/ovsdb/.libs/libovsdb.so* $(1)/usr/lib/ $(INSTALL_DIR) $(1)/usr/bin/ $(INSTALL_BIN) $(PKG_BUILD_DIR)/utilities/.libs/ovs-appctl $(1)/usr/bin/ diff --git a/net/openvswitch/patches/0002-netdev-linux-Use-unsigned-int-for-ifi_flags.patch b/net/openvswitch/patches/0001-netdev-linux-Use-unsigned-int-for-ifi_flags.patch similarity index 92% rename from net/openvswitch/patches/0002-netdev-linux-Use-unsigned-int-for-ifi_flags.patch rename to net/openvswitch/patches/0001-netdev-linux-Use-unsigned-int-for-ifi_flags.patch index 19c774799..ed537d10c 100644 --- a/net/openvswitch/patches/0002-netdev-linux-Use-unsigned-int-for-ifi_flags.patch +++ b/net/openvswitch/patches/0001-netdev-linux-Use-unsigned-int-for-ifi_flags.patch @@ -14,7 +14,7 @@ diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c index 9bdbbdf..9eaac33 100644 --- a/lib/netdev-linux.c +++ b/lib/netdev-linux.c -@@ -2566,7 +2566,7 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, +@@ -2709,7 +2709,7 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, enum netdev_flags on, enum netdev_flags *old_flagsp) OVS_REQUIRES(netdev->mutex) { diff --git a/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch b/net/openvswitch/patches/0002-netdev-linux-Let-interface-flag-survive-internal-por.patch similarity index 95% rename from net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch rename to net/openvswitch/patches/0002-netdev-linux-Let-interface-flag-survive-internal-por.patch index 1e79f3ae1..b31816ab3 100644 --- a/net/openvswitch/patches/0001-netdev-linux-Let-interface-flag-survive-internal-por.patch +++ b/net/openvswitch/patches/0002-netdev-linux-Let-interface-flag-survive-internal-por.patch @@ -21,7 +21,7 @@ diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c index 9eaac33..423e72e 100644 --- a/lib/netdev-linux.c +++ b/lib/netdev-linux.c -@@ -2569,7 +2569,13 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, +@@ -2712,7 +2712,13 @@ update_flags(struct netdev_linux *netdev, enum netdev_flags off, unsigned int old_flags, new_flags; int error = 0; diff --git a/net/openvswitch/patches/0003-datapath-do-not-add-vlan_hwaccel_push_inside-for-ker.patch b/net/openvswitch/patches/0003-datapath-do-not-add-vlan_hwaccel_push_inside-for-ker.patch new file mode 100644 index 000000000..673b8d6b5 --- /dev/null +++ b/net/openvswitch/patches/0003-datapath-do-not-add-vlan_hwaccel_push_inside-for-ker.patch @@ -0,0 +1,35 @@ +From 5919cb26c631b1dd77a745a3c546f9d117ed34b3 Mon Sep 17 00:00:00 2001 +From: Hauke Mehrtens +Date: Sat, 23 May 2015 18:12:09 +0200 +Subject: [PATCH] datapath: do not add vlan_hwaccel_push_inside() for kernel >= + 3.18.13 + +The vlan_hwaccel_push_inside() function was backported in this commit +to kernel 3.18.13: + +commit a67e2e88342accd49587d9bad72f6dabd7673f7c +Author: Jiri Pirko +Date: Wed Nov 19 14:04:59 2014 +0100 + + vlan: introduce *vlan_hwaccel_push_inside helpers + + [ Upstream commit 5968250c868ceee680aa77395b24e6ddcae17d36 ] + +Without this patch compilation breaks on kernel >= 3.18.13 + +Signed-off-by: Hauke Mehrtens +--- + datapath/linux/compat/include/linux/if_vlan.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/datapath/linux/compat/include/linux/if_vlan.h ++++ b/datapath/linux/compat/include/linux/if_vlan.h +@@ -52,7 +52,7 @@ static inline struct sk_buff *rpl_vlan_i + } + #endif + +-#if LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0) ++#if LINUX_VERSION_CODE < KERNEL_VERSION(3,18,13) + /* + * __vlan_hwaccel_push_inside - pushes vlan tag to the payload + * @skb: skbuff to tag diff --git a/net/openvswitch/patches/0003-lib-util.h-Disable-ovs_assert-when-build-with-NDEBUG.patch b/net/openvswitch/patches/0003-lib-util.h-Disable-ovs_assert-when-build-with-NDEBUG.patch deleted file mode 100644 index 2aade29ec..000000000 --- a/net/openvswitch/patches/0003-lib-util.h-Disable-ovs_assert-when-build-with-NDEBUG.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 34b51e26555d05c00b2320f943a645added5dae4 Mon Sep 17 00:00:00 2001 -From: Helmut Schaa -Date: Mon, 9 Dec 2013 14:15:11 +0100 -Subject: [PATCH 5/6] lib/util.h: Disable ovs_assert when build with NDEBUG - -Reduces binary size. Use a static inline function instead of -a macro to not get "unused variable" warning everywhere. - -Signed-off-by: Helmut Schaa ---- - lib/util.h | 5 +++++ - 1 file changed, 5 insertions(+) - -diff --git a/lib/util.h b/lib/util.h -index 5c23962..9e5866d 100644 ---- a/lib/util.h -+++ b/lib/util.h -@@ -69,10 +69,15 @@ - * - Writes the failure message to the log. - * - * - Not affected by NDEBUG. */ -+#ifndef NDEBUG - #define ovs_assert(CONDITION) \ - if (!OVS_LIKELY(CONDITION)) { \ - ovs_assert_failure(SOURCE_LOCATOR, __func__, #CONDITION); \ - } -+#else -+static inline void ovs_assert(bool cond OVS_UNUSED) {} -+#endif -+ - void ovs_assert_failure(const char *, const char *, const char *) NO_RETURN; - - /* Casts 'pointer' to 'type' and issues a compiler warning if the cast changes --- -1.8.1.4 - diff --git a/net/openvswitch/patches/0004-datapath-Use-ccflags-y-instead-of-deprecated-EXTRA_C.patch b/net/openvswitch/patches/0004-datapath-Use-ccflags-y-instead-of-deprecated-EXTRA_C.patch deleted file mode 100644 index 95891a1a5..000000000 --- a/net/openvswitch/patches/0004-datapath-Use-ccflags-y-instead-of-deprecated-EXTRA_C.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 36fd4f214f9ba74aaf0e5fb3e4ba271b946a1550 Mon Sep 17 00:00:00 2001 -From: Thomas Graf -Date: Wed, 26 Nov 2014 15:52:31 +0100 -Subject: [PATCH] datapath: Use ccflags-y instead of deprecated EXTRA_CFLAGS - -This allows users to pass in additional compiler flags through the -environment variable EXTRA_CFLAGS, e.g. - - make EXTRA_CFLAGS=-Wno-error=foo V=1 - -Reported-by: Alexandru Ardelean -Signed-off-by: Thomas Graf -Acked-by: Pravin B Shelar ---- - datapath/linux/Kbuild.in | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) - -diff --git a/datapath/linux/Kbuild.in b/datapath/linux/Kbuild.in -index 6f6f65f..cb98c11 100644 ---- a/datapath/linux/Kbuild.in -+++ b/datapath/linux/Kbuild.in -@@ -7,11 +7,11 @@ export VERSION = @VERSION@ - include $(srcdir)/../Modules.mk - include $(srcdir)/Modules.mk - --EXTRA_CFLAGS := -DVERSION=\"$(VERSION)\" --EXTRA_CFLAGS += -I$(srcdir)/.. --EXTRA_CFLAGS += -I$(builddir)/.. --EXTRA_CFLAGS += -g --EXTRA_CFLAGS += -include $(builddir)/kcompat.h -+ccflags-y := -DVERSION=\"$(VERSION)\" -+ccflags-y += -I$(srcdir)/.. -+ccflags-y += -I$(builddir)/.. -+ccflags-y += -g -+ccflags-y += -include $(builddir)/kcompat.h - - # These include directories have to go before -I$(KSRC)/include. - # NOSTDINC_FLAGS just happens to be a variable that goes in the --- -2.1.2 - diff --git a/net/openvswitch/patches/0004-musl-compatibility.patch b/net/openvswitch/patches/0004-musl-compatibility.patch new file mode 100644 index 000000000..25aa45d8a --- /dev/null +++ b/net/openvswitch/patches/0004-musl-compatibility.patch @@ -0,0 +1,39 @@ +diff --git a/configure.ac b/configure.ac +index 8d47eb9..69eeed8 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -117,7 +117,6 @@ OVS_CHECK_XENSERVER_VERSION + OVS_CHECK_GROFF + OVS_CHECK_GNU_MAKE + OVS_CHECK_TLS +-OVS_CHECK_ATOMIC_LIBS + OVS_CHECK_GCC4_ATOMICS + OVS_CHECK_ATOMIC_ALWAYS_LOCK_FREE(1) + OVS_CHECK_ATOMIC_ALWAYS_LOCK_FREE(2) +diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c +index 9b2e74f..70126bb 100644 +--- a/lib/netdev-linux.c ++++ b/lib/netdev-linux.c +@@ -40,7 +40,9 @@ + #include + #include + #include ++#if defined(__UCLIBC__) || defined(__GLIBC__) + #include ++#endif + #include + #include + #include +diff --git a/lib/ovs-atomic.h b/lib/ovs-atomic.h +index 9ead907..86d3341 100644 +--- a/lib/ovs-atomic.h ++++ b/lib/ovs-atomic.h +@@ -325,8 +325,6 @@ + #include "ovs-atomic-clang.h" + #elif HAVE_STDATOMIC_H + #include "ovs-atomic-c11.h" +- #elif __GNUC__ >= 4 && __GNUC_MINOR__ >= 7 +- #include "ovs-atomic-gcc4.7+.h" + #elif __GNUC__ && defined(__x86_64__) + #include "ovs-atomic-x86_64.h" + #elif __GNUC__ && defined(__i386__) diff --git a/net/pen/Makefile b/net/pen/Makefile index cb597a0ab..646c722dc 100644 --- a/net/pen/Makefile +++ b/net/pen/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=pen -PKG_VERSION:=0.27.1 +PKG_VERSION:=0.27.5 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://siag.nu/pub/pen/ -PKG_MD5SUM:=652c457266b6ec6a295f4c7895785674 +PKG_MD5SUM:=8430c6941e2047218c55274e3e7d06f2 PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING diff --git a/net/pptpd/Makefile b/net/pptpd/Makefile new file mode 100644 index 000000000..d17d1962e --- /dev/null +++ b/net/pptpd/Makefile @@ -0,0 +1,69 @@ +# +# Copyright (C) 2006-2015 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:=pptpd +PKG_VERSION:=1.4.0 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=@SF/poptop +PKG_MD5SUM:=36f9f45c6ffa92bc3b6e24ae2d053505 + +PKG_INSTALL:=1 +PKG_BUILD_PARALLEL:=1 + +PKG_MAINTAINER:=Luka Perkov + +include $(INCLUDE_DIR)/package.mk + +define Package/pptpd + SECTION:=net + CATEGORY:=Network + DEPENDS:=+kmod-ppp +kmod-gre +kmod-mppe +ppp + TITLE:=PopTop pptp server + URL:=http://poptop.sourceforge.net/ + SUBMENU:=VPN +endef + +CONFIGURE_ARGS += \ + --enable-bcrelay \ + +CONFIGURE_VARS += \ + ac_cv_header_libintl_h=no \ + +MAKE_FLAGS += \ + COPTS="$(TARGET_CFLAGS)" \ + INSTALL="install" \ + +define Package/pptpd/conffiles +/etc/pptpd.conf +/etc/ppp/options.pptpd +/etc/config/pptpd +endef + +define Package/pptpd/install + $(INSTALL_DIR) $(1)/usr/sbin + $(CP) \ + $(PKG_INSTALL_DIR)/usr/sbin/bcrelay \ + $(PKG_INSTALL_DIR)/usr/sbin/pptpctrl \ + $(PKG_INSTALL_DIR)/usr/sbin/pptpd \ + $(1)/usr/sbin/ + $(INSTALL_DIR) $(1)/usr/lib/pptpd + $(CP) $(PKG_INSTALL_DIR)/usr/lib/pptpd/* $(1)/usr/lib/pptpd/ + $(INSTALL_DIR) $(1)/etc + $(INSTALL_DATA) ./files/pptpd.conf $(1)/etc/ + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/pptpd.init $(1)/etc/init.d/pptpd + $(INSTALL_DIR) $(1)/etc/ppp + $(INSTALL_DATA) ./files/options.pptpd $(1)/etc/ppp/ + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_DATA) ./files/pptpd.config $(1)/etc/config/pptpd +endef + +$(eval $(call BuildPackage,pptpd)) diff --git a/net/pptpd/files/options.pptpd b/net/pptpd/files/options.pptpd new file mode 100644 index 000000000..f73eeea23 --- /dev/null +++ b/net/pptpd/files/options.pptpd @@ -0,0 +1,22 @@ +#debug +#logfile /tmp/pptp-server.log +auth +name "pptp-server" +lcp-echo-failure 3 +lcp-echo-interval 60 +default-asyncmap +mtu 1482 +mru 1482 +nobsdcomp +nodeflate +#noproxyarp +#nomppc +mppe required,no40,no56,stateless +require-mschap-v2 +refuse-chap +refuse-mschap +refuse-eap +refuse-pap +#ms-dns 172.16.1.1 +#plugin radius.so +#radius-config-file /etc/radius.conf diff --git a/net/pptpd/files/pptpd.conf b/net/pptpd/files/pptpd.conf new file mode 100644 index 000000000..354745f59 --- /dev/null +++ b/net/pptpd/files/pptpd.conf @@ -0,0 +1,5 @@ +#debug +option /etc/ppp/options.pptpd +speed 115200 +stimeout 10 +#localip & remoteip are not needed, ip management is done by pppd diff --git a/net/pptpd/files/pptpd.config b/net/pptpd/files/pptpd.config new file mode 100644 index 000000000..b2d5df5d7 --- /dev/null +++ b/net/pptpd/files/pptpd.config @@ -0,0 +1,8 @@ +config service 'pptpd' + option 'enabled' '0' + option 'localip' '192.168.0.1' + option 'remoteip' '192.168.0.20-30' + +config 'login' + option 'username' 'youruser' + option 'password' 'yourpass' diff --git a/net/pptpd/files/pptpd.init b/net/pptpd/files/pptpd.init new file mode 100644 index 000000000..0d0639fee --- /dev/null +++ b/net/pptpd/files/pptpd.init @@ -0,0 +1,58 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2006 OpenWrt.org + +START=60 +BIN=/usr/sbin/pptpd +DEFAULT=/etc/default/$BIN +RUN_D=/var/run +PID_F=$RUN_D/$BIN.pid +CONFIG=/var/etc/pptpd.conf +CHAP_SECRETS=/var/etc/chap-secrets + +setup_login() { + local section="$1" + + config_get username "$section" username + config_get password "$section" password + [ -n "$username" ] || return 0 + [ -n "$password" ] || return 0 + + echo "$username pptp-server $password *" >> $CHAP_SECRETS +} + +setup_config() { + local section="$1" + + config_get enabled "$section" enabled + [ "$enabled" -eq 0 ] && return 1 + + mkdir -p /var/etc + cp /etc/pptpd.conf $CONFIG + + config_get localip "$section" localip + config_get remoteip "$section" remoteip + [ -n "$localip" ] && echo "localip $localip" >> $CONFIG + [ -n "$remoteip" ] && echo "remoteip $remoteip" >> $CONFIG + return 0 +} + +start_pptpd() { + [ -f $DEFAULT ] && . $DEFAULT + mkdir -p $RUN_D + for m in arc4 sha1_generic slhc crc-ccitt ppp_generic ppp_async ppp_mppe; do + insmod $m >/dev/null 2>&1 + done + ln -sfn $CHAP_SECRETS /etc/ppp/chap-secrets + service_start $BIN $OPTIONS -c $CONFIG +} + +start() { + config_load pptpd + setup_config pptpd || return + config_foreach setup_login login + start_pptpd +} + +stop() { + service_stop $BIN +} diff --git a/net/pptpd/patches/001-bad_pqueue_debug.patch b/net/pptpd/patches/001-bad_pqueue_debug.patch new file mode 100644 index 000000000..50d525284 --- /dev/null +++ b/net/pptpd/patches/001-bad_pqueue_debug.patch @@ -0,0 +1,18 @@ +--- a/pqueue.c ++++ b/pqueue.c +@@ -7,13 +7,11 @@ + #include "pqueue.h" + + #ifdef DEBUG_PQUEUE +-#define DEBUG_ON 1 ++#define DEBUG_CMD(_a) { _a } + #else +-#define DEBUG_ON 0 ++#define DEBUG_CMD(_a) + #endif + +-#define DEBUG_CMD(_a) if (DEBUG_ON) { _a } +- + #define MIN_CAPACITY 128 /* min allocated buffer for a packet */ + + static int pqueue_alloc (int seq, unsigned char *packet, int packlen, pqueue_t **new); diff --git a/net/pptpd/patches/002-makefile_fix.patch b/net/pptpd/patches/002-makefile_fix.patch new file mode 100644 index 000000000..74e333509 --- /dev/null +++ b/net/pptpd/patches/002-makefile_fix.patch @@ -0,0 +1,11 @@ +--- a/plugins/Makefile ++++ b/plugins/Makefile +@@ -18,7 +18,7 @@ all: $(PLUGINS) + %.so: %.c + $(CC) -o $@ $(LDFLAGS) $(CFLAGS) $^ $(LDADD) + +-LIBDIR ?= $(DESTDIR)$(prefix)/lib/pptpd ++LIBDIR = $(DESTDIR)$(prefix)/lib/pptpd + + install: $(PLUGINS) + $(INSTALL) -d $(LIBDIR) diff --git a/net/pptpd/patches/003-opt_flags.patch b/net/pptpd/patches/003-opt_flags.patch new file mode 100644 index 000000000..cc136c516 --- /dev/null +++ b/net/pptpd/patches/003-opt_flags.patch @@ -0,0 +1,11 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -153,7 +153,7 @@ AUTOMAKE = @AUTOMAKE@ + AWK = @AWK@ + CC = @CC@ + CCDEPMODE = @CCDEPMODE@ +-CFLAGS = -O2 -fno-builtin -Wall -DSBINDIR='"$(sbindir)"' ++CFLAGS = $(COPTS) -fno-builtin -Wall -DSBINDIR='"$(sbindir)"' + CPP = @CPP@ + CPPFLAGS = @CPPFLAGS@ + CYGPATH_W = @CYGPATH_W@ diff --git a/net/pptpd/patches/100-musl-compat.patch b/net/pptpd/patches/100-musl-compat.patch new file mode 100644 index 000000000..6ce625a41 --- /dev/null +++ b/net/pptpd/patches/100-musl-compat.patch @@ -0,0 +1,38 @@ +--- a/bcrelay.c ++++ b/bcrelay.c +@@ -667,7 +667,7 @@ static void mainloop(int argc, char **ar + * there is no need to concern about the physical/link layer header because it is + * filled in automatically (based on the contents of sa). + */ +- if ((nrsent = sendto(cur_ifsnr[j].sock_nr, ipp_p, rlen, MSG_DONTWAIT|MSG_TRYHARD, (struct sockaddr *)&sa, salen)) < 0) ++ if ((nrsent = sendto(cur_ifsnr[j].sock_nr, ipp_p, rlen, MSG_DONTWAIT|MSG_DONTROUTE, (struct sockaddr *)&sa, salen)) < 0) + { + if (errno == ENETDOWN) { + syslog(LOG_NOTICE, "ignored ENETDOWN from sendto(), a network interface was going down?"); +--- a/compat.c ++++ b/compat.c +@@ -11,10 +11,10 @@ + #include "compat.h" + #include "our_syslog.h" + +-#ifndef HAVE_STRLCPY + #include + #include + ++#ifndef HAVE_STRLCPY + void strlcpy(char *dst, const char *src, size_t size) + { + strncpy(dst, src, size - 1); +--- /dev/null ++++ b/net/ppp_defs.h +@@ -0,0 +1,10 @@ ++#ifndef _NET_PPP_DEFS_H ++#define _NET_PPP_DEFS_H 1 ++ ++#define __need_time_t ++#include ++ ++#include ++#include ++ ++#endif /* net/ppp_defs.h */ diff --git a/net/prosody/Makefile b/net/prosody/Makefile index a829ce8c2..4ff6d38ad 100644 --- a/net/prosody/Makefile +++ b/net/prosody/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=prosody -PKG_VERSION:=0.9.7 -PKG_RELEASE:=2 +PKG_VERSION:=0.9.8 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://prosody.im/downloads/source -PKG_MD5SUM:=47de7f593279e327792df78cfa93e8a7 +PKG_MD5SUM:=5144cd832a1860443e21e336dc560ee7 PKG_MAINTAINER:=Thomas Heil PKG_LICENSE:=MIT/X11 diff --git a/net/radicale/Makefile b/net/radicale/Makefile new file mode 100644 index 000000000..f604a9fdf --- /dev/null +++ b/net/radicale/Makefile @@ -0,0 +1,138 @@ +# +# Copyright (C) 2008-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=radicale +PKG_VERSION:=0.10 +PKG_RELEASE:=2 +PKG_MAINTAINER:=Christian Schoenebeck + +PKG_LICENSE:=GPL-3.0 +PKG_LICENSE_FILES:=COPYING + +PKG_SOURCE:=Radicale-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://pypi.python.org/packages/source/R/Radicale/ +PKG_MD5SUM:=32655d8893962956ead0ad690cca6044 + +# needed for "r"adicale <-> "R"adicale +PKG_BUILD_DIR:=$(BUILD_DIR)/Radicale-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +# no default dependencies +PKG_DEFAULT_DEPENDS= + +define Package/$(PKG_NAME)/Default + SECTION:=net + CATEGORY:=Network + SUBMENU:=Web Servers/Proxies + URL:=http://radicale.org/ + PKGARCH:=all + USERID:=radicale=5232:radicale=5232 +endef +define Package/$(PKG_NAME)-py2 + $(call Package/$(PKG_NAME)/Default) + PYTHON_VERSION:=2.7 + TITLE:=Radicale CalDAV/CardDAV server (Python 2) + VARIANT:=python2 + DEPENDS:=+python-logging +python-openssl +python-xml +python-codecs +endef +define Package/$(PKG_NAME)-py3 + $(call Package/$(PKG_NAME)/Default) + PYTHON_VERSION:=3.4 + TITLE:=Radicale CalDAV/CardDAV server (Python 3) + VARIANT:=python3 + DEPENDS:=+python3-logging +python3-openssl +python3-xml +python3-codecs +python3-email @BROKEN +endef + +# shown in LuCI package description +define Package/$(PKG_NAME)-py2/description +Radicale CalDAV/CardDAV server (Python 2) - Homepage: http://radicale.org/ +endef +define Package/$(PKG_NAME)-py3/description +Radicale CalDAV/CardDAV server (Python 3) - Homepage: http://radicale.org/ +endef + +# shown in make menuconfig +define Package/$(PKG_NAME)-py2/config + help + The Radicale Project is a CalDAV (calendar) and CardDAV (contact) server. + It aims to be a light solution, easy to use, easy to install, easy to configure. + As a consequence, it requires few software dependances and is pre-configured to work out-of-the-box. + !!! Will install and use Python $(PYTHON_VERSION) !!! + . + Version : $(PKG_VERSION) + Homepage: http://radicale.org/ + . + $(PKG_MAINTAINER) +endef +Package/$(PKG_NAME)-py3/config = $(Package/$(PKG_NAME)-py2/config) + +define Package/$(PKG_NAME)-py2/conffiles +/etc/config/radicale +/etc/radicale/users +/etc/radicale/rights +endef +Package/$(PKG_NAME)-py3/conffiles = $(Package/$(PKG_NAME)-py2/conffiles) + +define Build/Configure +endef +define Build/Compile +endef + +define Package/$(PKG_NAME)-py2/preinst + #!/bin/sh + [ -n "$${IPKG_INSTROOT}" ] && exit 0 # if run within buildroot exit + + # stop service if PKG_UPGRADE + [ "$${PKG_UPGRADE}" = "1" ] && /etc/init.d/$(PKG_NAME) stop >/dev/null 2>&1 + + exit 0 # supress errors from stop command +endef +define Package/$(PKG_NAME)-py3/preinst +$(call Package/$(PKG_NAME)-py2/preinst) +endef + +define Package/$(PKG_NAME)-py2/install + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/radicale.init $(1)/etc/init.d/radicale + $(INSTALL_DIR) $(1)/etc/hotplug.d/iface + $(INSTALL_BIN) ./files/radicale.hotplug $(1)/etc/hotplug.d/iface/80-radicale + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_CONF) ./files/radicale.config $(1)/etc/config/radicale + + $(INSTALL_DIR) $(1)/etc/radicale/ssl + $(INSTALL_DATA) ./files/config.template $(1)/etc/radicale/ + $(INSTALL_DATA) ./files/logging.template $(1)/etc/radicale/ + $(INSTALL_DATA) ./files/radicale.users $(1)/etc/radicale/users + $(INSTALL_DATA) ./files/radicale.rights $(1)/etc/radicale/rights + + $(INSTALL_DIR) $(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/radicale + $(CP) \ + $(PKG_BUILD_DIR)/radicale/* \ + $(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/radicale + + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/radicale $(1)/usr/bin/ +endef +define Package/$(PKG_NAME)-py3/install + $(call Package/$(PKG_NAME)-py2/install, $(1)) +endef + +define Package/$(PKG_NAME)-py2/postinst + #!/bin/sh + # patch /usr/bin/radicale force run using python2 + /bin/sed -i 's/python/python2/' $${IPKG_INSTROOT}/usr/bin/radicale +endef +define Package/$(PKG_NAME)-py3/postinst + #!/bin/sh + # patch /usr/bin/radicale force run using python3 + /bin/sed -i 's/python/python3/' $${IPKG_INSTROOT}/usr/bin/radicale +endef + +$(eval $(call BuildPackage,$(PKG_NAME)-py2)) +$(eval $(call BuildPackage,$(PKG_NAME)-py3)) diff --git a/net/radicale/files/config.template b/net/radicale/files/config.template new file mode 100644 index 000000000..1b8fcf294 --- /dev/null +++ b/net/radicale/files/config.template @@ -0,0 +1,30 @@ +# -*- mode: conf -*- +# vim:ft=cfg + +### AUTO-GENERATED CONFIGURATION +### USED BY RADICALE +### DO NOT EDIT +### SEE /etc/config/radicale INSTEAD + +[server] +# daemon # handled by /etc/init.d/radicale +# pid # handled by /etc/init.d/radicale + +[encoding] + +[well-known] + +[auth] +# htpasswd_filename # hard-coded /etc/radicale/users + +[git] + +[rights] +# file # hard-coded /etc/radicale/rights + +[storage] + +[logging] +# config # hard-coded /var/etc/radicale/logging + +[headers] diff --git a/net/radicale/files/logging.template b/net/radicale/files/logging.template new file mode 100644 index 000000000..a730ca01a --- /dev/null +++ b/net/radicale/files/logging.template @@ -0,0 +1,47 @@ +# -*- mode: conf -*- +# vim:ft=cfg + +### AUTO-GENERATED CONFIGURATION +### USED BY RADICALE +### DO NOT EDIT +### SEE /etc/config/radicale INSTEAD + +[loggers] +keys = root + +[handlers] +keys = console,file,syslog + +[formatters] +keys = simple,full,syslog + +[logger_root] +level = DEBUG +handlers = console,file,syslog + +[handler_console] +class = StreamHandler +args = (sys.stdout,) +formatter = simple +# level = WARNING # set via /etc/config/radicale + +[handler_file] +class = handlers.RotatingFileHandler +formatter = full +# level = INFO # set via /etc/config/radicale +# args = ('[filename]','a',[maxbytes],[backupcount]) # set via /etc/config/radicale + +[handler_syslog] +class = handlers.SysLogHandler +args = ('/dev/log', handlers.SysLogHandler.LOG_DAEMON) +formatter = syslog +# level = WARNING # set via /etc/config/radicale + +[formatter_simple] +format = %(message)s + +[formatter_full] +format = %(asctime)s - %(levelname)s: %(message)s + +[formatter_syslog] +format = radicale [%(process)d]: %(message)s diff --git a/net/radicale/files/radicale.config b/net/radicale/files/radicale.config new file mode 100644 index 000000000..58148f823 --- /dev/null +++ b/net/radicale/files/radicale.config @@ -0,0 +1,190 @@ +# +# You find additional information on Radicale Homepage +# http://radicale.org +# +# OpenWrt's wiki needs to be setup/updated ;-) +# +# if setting additional options please remember that UCI does not support +# section names and option names with "-" (Dash) inside their name +# to use them anyway replace "-" with "_" (Underscore) +# Each Radicale's config [section] is setup as UCI config setting 'section' +# + +#################################################### +# Server options +# +config setting 'server' + + # hostname:port + # IPv4 syntax: address:port + # IPv6 syntax: [address]:port + # ATTENTION: + # only use ports > 1024 (non-privileged Ports) + # because this implementation is running as non-root user + # Default: 0.0.0.0:5232 +# list hosts '0.0.0.0:5232' +# list hosts 'localhost:5232' + + # SSL flag, enable HTTPS protocol + # Default: 0 (disabled) +# option ssl '1' + + # SSL Protocol used. See python's ssl module for available values + # Default: PROTOCOL_SSLv23 +# option protocol 'PROTOCOL_SSLv23' + + # Ciphers available. See python's ssl module for available ciphers +# option ciphers '' + + # SSL certificate path and file +# option certificate '/etc/radicale/ssl/server.crt' + + # SSL private key path and file +# option key '/etc/radicale/ssl/server.key' + + # Reverse DNS to resolve client address in logs + # Default: 0 (disabled) +# option dns_lookup '1' + + # Message displayed in the client when a password is needed +# option realm 'Radicale - Password Required' + + +#################################################### +# Encoding options +# +config setting 'encoding' + + # Encoding for responding requests +# option request 'utf-8' + + # Encoding for storing local collections +# option stock 'utf-8' + + +#################################################### +# Authentication options +# +config setting 'auth' + + # Authentication method + # Value: None | htpasswd | IMAP | LDAP | PAM | courier | http | remote_user | custom + # Default: None + # if setting 'htpasswd' the file /etc/radicale/users is used (hardcoded) + + # Htpasswd encryption method + # Value: plain | sha1 | ssha | crypt +# option htpasswd_encryption 'crypt' + + # for other authenication methods consult Radicale documentation + # and set options here + + +#################################################### +# Git default options +# +config setting 'git' + + # Git default options +# option committer 'Radicale ' + + +#################################################### +# Rights backend +# +config setting 'rights' + + # Value: None | authenticated | owner_only | owner_write | from_file | custom + # Default: None + # if setting 'from_file' the file /etc/radicale/rights is used (hardcoded) + + # Custom rights handler +# option custom_handler '' + + +#################################################### +# Storage backend +# ------- +# WARNING: ONLY "filesystem" IS DOCUMENTED AND TESTED, +# OTHER BACKENDS ARE NOT READY FOR PRODUCTION. +# ------- +# +config setting 'storage' + # Value: filesystem | multifilesystem | database | custom + option type 'filesystem' + option filesystem_folder '/srv/radicale' + + +#################################################### +# Additional HTTP headers +# +config setting 'headers' + # enable all if using CardDavMATE-, CalDavZAP- or InfCloud- WEBclient +# list Access_Control_Allow_Origin '*' +# list Access_Control_Allow_Methods 'GET' +# list Access_Control_Allow_Methods 'POST' +# list Access_Control_Allow_Methods 'OPTIONS' +# list Access_Control_Allow_Methods 'PROPFIND' +# list Access_Control_Allow_Methods 'PROPPATCH' +# list Access_Control_Allow_Methods 'REPORT' +# list Access_Control_Allow_Methods 'PUT' +# list Access_Control_Allow_Methods 'MOVE' +# list Access_Control_Allow_Methods 'DELETE' +# list Access_Control_Allow_Methods 'LOCK' +# list Access_Control_Allow_Methods 'UNLOCK' +# list Access_Control_Allow_Headers 'User-Agent' +# list Access_Control_Allow_Headers 'Authorization' +# list Access_Control_Allow_Headers 'Content-type' +# list Access_Control_Allow_Headers 'Depth' +# list Access_Control_Allow_Headers 'If-match' +# list Access_Control_Allow_Headers 'If-None-Match' +# list Access_Control_Allow_Headers 'Lock-Token' +# list Access_Control_Allow_Headers 'Timeout' +# list Access_Control_Allow_Headers 'Destination' +# list Access_Control_Allow_Headers 'Overwrite' +# list Access_Control_Allow_Headers 'X-client' +# list Access_Control_Allow_Headers 'X-Requested-With' +# list Access_Control_Expose_Headers 'Etag' + + +#################################################### +# Global logging options +# +config setting 'logging' + + # Set the default logging level to debug for all outputs (ignore output level settings) + # Default: 0 (disabled) +# option debug '1' + # Log all environment variables (including those set in the shell) when starting + # Default: 0 (disabled) +# option full_environment '1' + + +#################################################### +# Spezial logging options +# !!! not documented in Radicale documentation +# !!! special settings for this implementation +# +config logging 'logger' + + # Level: DEBUG | INFO | WARNING | ERROR | CRITICAL + # To nearly disable logging set level to critical + + # log level on console +# option console_level 'ERROR' + + # Here we use Rotating Logfiles in this implementation + # !!! if maxbytes and/or backupcount is set to 0 !!! + # !!! file rotation is disabled and logfile grows endless !!! + # log level +# option file_level 'INFO' + # directory where log files are written +# option file_path '/var/log/radicale' + # max size of each logfile (see warning above) +# option file_maxbytes '8196' + # number of backup files to create (see warning above) +# option file_backupcount '1' + + # log level for syslog logging +# option syslog_level 'WARNING' + diff --git a/net/radicale/files/radicale.hotplug b/net/radicale/files/radicale.hotplug new file mode 100644 index 000000000..3b9141986 --- /dev/null +++ b/net/radicale/files/radicale.hotplug @@ -0,0 +1,16 @@ +#!/bin/sh + +# only (re-)start on ifup +[ "$ACTION" = "ifup" ] || exit 0 + +_PID=$(ps | grep '[p]ython.*[r]adicale' 2>/dev/null | awk '{print $1}') +kill -1 $_PID 2>/dev/null +if [ $? -eq 0 ]; then + # only restart if already running + logger -p user.info -t "radicale[$_PID]" \ + "Restart request due to '$ACTION' of interface '$INTERFACE'" + /etc/init.d/radicale restart +else + # only start if enabled + /etc/init.d/radicale enabled && /etc/init.d/radicale start +fi diff --git a/net/radicale/files/radicale.init b/net/radicale/files/radicale.init new file mode 100755 index 000000000..991ca5051 --- /dev/null +++ b/net/radicale/files/radicale.init @@ -0,0 +1,220 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2006-2015 OpenWrt.org + +START=80 +STOP=10 + +CFGDIR=/var/etc/radicale +SYSCFG=$CFGDIR/config +LOGCFG=$CFGDIR/logging + +DATADIR="/srv/radicale" +LOGDIR="" + +PGREP="ps | grep '[p]ython.*[r]adicale' 2>/dev/null | awk '{print \$1}' " + +# we could start with empty configuration file using defaults +[ -f /etc/config/radicale ] || touch /etc/config/radicale + +_uci2radicale() { + local _SYSTMP="$SYSCFG.tmp" + local _LOGTMP="$LOGCFG.tmp" + local _LOPT # list option name + local _LVAL # list option value + local _STYPE # section type + local _SNAME # section name + local _console_level="ERROR" # logging console level + local _file_level="INFO" # logging file level + local _file_path="/var/log/radicale" # logging file path + local _file_maxbytes="8196" # logging file maxBytes + local _file_backupcount="1" # logging file backupCount + local _syslog_level="WARNING" # logging syslog level + + # write list values to config + _write_list() { + _write_value "$_LOPT" "$_LVAL" # there might be spaces in _LVAL + _LOPT="" + _LVAL="" + } + + _write_value() { + # $1 option + # $2 value + local __OPT=$1 + local __VAL=$2 + # section "server" ignore option "daemon" and "pid" + [ "$_SNAME" = "server" -a "$__OPT" = "daemon" ] && return 0 + [ "$_SNAME" = "server" -a "$__OPT" = "pid" ] && return 0 + # section "logging" ignore option "config" (logging config file) + [ "$_SNAME" = "logging" -a "$__OPT" = "config" ] && return 0 + # section "auth" ignore option "htpasswd_filename" (htpasswd file) + [ "$_SNAME" = "auth" -a "$__OPT" = "htpasswd_filename" ] && return 0 + # section "rights" ignore option "file" (reg-based rights file) + [ "$_SNAME" = "rights" -a "$__OPT" = "file" ] && return 0 + # section "headers" replace "_" with "-" in option (UCI problem) + [ "$_SNAME" = "headers" ] && __OPT=$(echo "$__OPT" | sed -e "s#_#-#g") + # save data driectory + [ "$_SNAME" = "storage" -a "$__OPT" = "filesystem_folder" ] && DATADIR="$__VAL" + # special handling for well-known, value needs single quotes + [ "$_SNAME" = "well-known" -a "${__VAL#*\%\(}" != "$__VAL" ] && __VAL="'$__VAL'" + # handling of log settings + if [ "$_STYPE" = "logging" -a "$_SNAME" = "logger" ]; then + eval "_$__OPT='$__VAL'" # set to environment for later use + else + # handle bool + [ "$__VAL" = "0" ] && __VAL="False" + [ "$__VAL" = "1" ] && __VAL="True" + # append data to the corresponding section + sed -i "/\[$_SNAME\]/a $__OPT = $__VAL" $_SYSTMP + fi + } + + # redefined callback for sections when calling config_load + config_cb() { + # $1 "Type" + # $2 "Name" + # write out last list option + [ -n "$_LOPT" ] && _write_list + # mark invalid + _STYPE="" + _SNAME="" + # check section type + [ "$1" = "setting" -o "$1" = "logging" ] && { + _STYPE="$1" + _SNAME="$2" + } + # translate section name + [ "$2" = "well_known" ] && _SNAME="well-known" + return 0 + } + + # redefined callback for lists when calling config_load + list_cb() { + # $1 name of variable + # $2 value + # invalid section type then ignore + [ -z "$_STYPE" -o -z "$_SNAME" ] && return 0 + # write out last list option if new list starts + [ -n "$_LOPT" -a "$_LOPT" != "$1" ] && _write_list + # new list option + if [ -z "$_LOPT" ]; then + _LOPT="$1" + _LVAL="$2" + else + _LVAL="$_LVAL, $2" + fi + return 0 + } + + # redefined callback for options when calling config_load + option_cb() { + # $1 name of variable + # $2 value + local __OPT="$1" + local __VAL="$2" + # invalid section type then ignore + [ -z "$_STYPE" -o -z "$_SNAME" ] && return 0 + # ignore list entrys will be handled by list_cb() + [ "${__OPT#*_ITEM}" != "$__OPT" ] && return 0 # ignore lists *_ITEM* + [ "${__OPT#*_LENGTH}" != "$__OPT" ] && return 0 # ignore lists *_LENGTH + # write out last list option and clear + [ -n "$_LOPT" ] && _write_list + # write to file + _write_value "$__OPT" "$__VAL" # there might be spaces in __VAL + return 0 + } + + # temporary config file + # radicale need read access + mkdir -m0755 -p $CFGDIR + + cp /etc/radicale/config.template $_SYSTMP + config_load radicale # calling above config_cb()/option_cb()/list_cb() and write into $_SYSTMP + sed -i "/\[logging\]/a config = /var/etc/radicale/logging" $_SYSTMP # hard-code logging config + sed -i "/\[auth\]/a htpasswd_filename = /etc/radicale/users" $_SYSTMP # hard-code htpasswd + sed -i "/\[rights\]/a file = /etc/radicale/rights" $_SYSTMP # hard-code regexp-based rights + + # temporary logging config file + cp /etc/radicale/logging.template $_LOGTMP + LOGDIR="$_file_path" + sed -i "/\[handler_console\]/a level = $_console_level" $_LOGTMP + sed -i "/\[handler_file\]/a level = $_file_level" $_LOGTMP + sed -i "/\[handler_file\]/a args = ('$_file_path/radicale','a',$_file_maxbytes,$_file_backupcount)" $_LOGTMP + sed -i "/\[handler_syslog\]/a level = $_syslog_level" $_LOGTMP + + # move tmp to final + mv -f $_SYSTMP $SYSCFG + mv -f $_LOGTMP $LOGCFG +} + +_set_permission() { + # config file permissions (read access for group) + chmod 644 $SYSCFG $LOGCFG + chgrp -R radicale $CFGDIR + # log directory (full access and owner) + [ -d $LOGDIR ] || mkdir -m0755 -p $LOGDIR + chown -R radicale:radicale $LOGDIR + # data directory does not exist + [ -d $DATADIR ] || { + logger -p user.error -t "radicale[----]" "Data directory '$DATADIR' does not exists. Startup failed !!!" + exit 1 + } + chgrp -R radicale $DATADIR +} + +boot() { + return 0 # will be started by "iface" hotplug events +} + +start() { + _running() { + sleep 2 # give radicale time to completely come up + local _PID=$(eval "$PGREP") + kill -1 $_PID 2>/dev/null + [ $? -eq 0 ] \ + && logger -p user.notice -t "radicale[$_PID]" "Service started successfully"\ + || logger -p user.warn -t "radicale[----]" "Service failed to start" + } + + # if already running do nothing + local _PID=$(eval "$PGREP") + kill -1 $_PID 2>/dev/null && return 0 + + _uci2radicale + _set_permission + + radicale --daemon --config=$SYSCFG + + _running & # check if running and syslog + + return 0 +} + +reload() { + # reload is also used by luci + local _PID=$(eval "$PGREP") + kill -1 $_PID 2>/dev/null + if [ $? -eq 0 ]; then + # only restart if already running + restart + else + # only start if enabled + enabled && start + fi + return 0 +} + +stop() { + local _PID=$(eval "$PGREP") + [ -z "$_PID" ] && return 0 # not running + kill -15 $_PID 2>/dev/null + sleep 3 # give time to shutdown + local _tmp=$(eval "$PGREP") + if [ -z "$_tmp" ]; then + logger -p user.notice -t "radicale[$_PID]" "Service shutdown successfully" + else + kill -9 $_tmp # Normally never come here + logger -p user.warn -t "radicale[----]" "Service shutdown FORCED" + fi + return 0 +} diff --git a/net/radicale/files/radicale.rights b/net/radicale/files/radicale.rights new file mode 100644 index 000000000..3de3955d3 --- /dev/null +++ b/net/radicale/files/radicale.rights @@ -0,0 +1,49 @@ +# +# Authentication login is matched against the "user" key, and collection's path is matched against the "collection" key. +# You can use Python's ConfigParser interpolation values %(login)s and %(path)s. +# You can also get groups from the user regex in the collection with {0}, {1}, etc. +# +# For example, for the "user" key, ".+" means "authenticated user" and ".*" means "anybody" (including anonymous users). +# +# Section names are only used for naming the rule. +# Leading or ending slashes are trimmed from collection's path. +# + +# This means all users starting with "admin" may read any collection +[admin] +user: ^admin.*$ +collection: .* +permission: r + +# This means all users may read and write any collection starting with public. +# We do so by just not testing against the user string. +[public] +user: .* +collection: ^public(/.+)?$ +permission: rw + +# A little more complex: give read access to users from a domain for all +# collections of all the users (ie. user@domain.tld can read domain/\*). +[domain-wide-access] +user: ^.+@(.+)\..+$ +collection: ^{0}/.+$ +permission: r + +# Allow authenticated user to read all collections +[allow-everyone-read] +user: .+ +collection: .* +permission: r + +# Give write access to owners +[owner-write] +user: .+ +collection: ^%(login)s(/.+)?$ +permission: rw + +# Allow CardDavMATE-, CalDavZAP- or InfCloud- WEBclient to work +# anonymous users have read access to "/" but no files or subdir +[infcloud] +user: .* +collection: / +permission: r diff --git a/net/radicale/files/radicale.users b/net/radicale/files/radicale.users new file mode 100644 index 000000000..772217674 --- /dev/null +++ b/net/radicale/files/radicale.users @@ -0,0 +1,6 @@ +# +# Sample File +# + +user1:password1 +user2:password2 \ No newline at end of file diff --git a/net/radicale/patches/010-Run-as-user-group-radicale-radicale.patch b/net/radicale/patches/010-Run-as-user-group-radicale-radicale.patch new file mode 100644 index 000000000..e1f1c21eb --- /dev/null +++ b/net/radicale/patches/010-Run-as-user-group-radicale-radicale.patch @@ -0,0 +1,30 @@ +Subject: [PATCH] Run as user radicale and group radicale + +Patch to run Radicale service as radicale:radicale non root user + +Signed-off-by: Christian Schoenebeck +--- + bin/radicale | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/bin/radicale b/bin/radicale +index 619aca5..7466020 100755 +--- a/bin/radicale ++++ b/bin/radicale +@@ -26,6 +26,13 @@ Launch the server according to configuration and command-line options. + + """ + ++# inserted to run as user radicale ++import pwd, grp, os ++uid = pwd.getpwnam('radicale').pw_uid ++gid = grp.getgrnam('radicale').gr_gid ++os.setegid(gid) ++os.seteuid(uid) ++ + import radicale.__main__ + + +-- +2.1.0 + diff --git a/net/redsocks/Makefile b/net/redsocks/Makefile index 91f047736..caf541e1b 100644 --- a/net/redsocks/Makefile +++ b/net/redsocks/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2014-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -11,10 +11,12 @@ PKG_NAME:=redsocks PKG_VERSION:=0.4 PKG_RELEASE:=1 -PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-release-$(PKG_VERSION) -PKG_SOURCE:=release-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://github.com/darkk/redsocks/archive/ -PKG_MD5SUM:=810102ef06a9ea796f310ae811afc6a8 +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/darkk/redsocks.git +PKG_SOURCE_VERSION:=release-0.4 + PKG_MAINTAINER:=Johannes Morgenroth PKG_LICENSE:=Apache-2.0 diff --git a/net/rtorrent/Makefile b/net/rtorrent/Makefile index af644100d..bba6ddee0 100644 --- a/net/rtorrent/Makefile +++ b/net/rtorrent/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=rtorrent -PKG_VERSION:=0.9.4-git-0 +PKG_VERSION:=0.9.4-git-1 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git @@ -72,7 +72,8 @@ TARGET_LDFLAGS += -lz -lpthread -Wl,-rpath-link=$(STAGING_DIR)/usr/lib CONFIGURE_ARGS+= \ --enable-shared \ --disable-static \ - --disable-debug + --disable-debug \ + $(call autoconf_bool,CONFIG_IPV6,ipv6) ifeq ($(BUILD_VARIANT),rpc) CONFIGURE_ARGS += \ diff --git a/net/seafile-ccnet/Makefile b/net/seafile-ccnet/Makefile index 898b939eb..6c7ae8d7b 100644 --- a/net/seafile-ccnet/Makefile +++ b/net/seafile-ccnet/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=seafile-ccnet -PKG_VERSION:=4.0.6 +PKG_VERSION:=4.1.2 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_LICENSE:=GPL-3.0 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/haiwen/ccnet.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=1e1aeae83cc33356ebd5f064f4a4c148186b814d +PKG_SOURCE_VERSION:=a73109f09af4ecc49cdc4c57cdde51b38e15c31a PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/net/seafile-seahub/Makefile b/net/seafile-seahub/Makefile index ef2d4907f..cbedc5c7f 100644 --- a/net/seafile-seahub/Makefile +++ b/net/seafile-seahub/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=seafile-seahub -PKG_VERSION:=4.0.6 +PKG_VERSION:=4.1.2 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_LICENSE:=Apache-2.0 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/haiwen/seahub.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=739b32b02c4803448d5cb75b3e22ec0073930aed +PKG_SOURCE_VERSION:=3fb1288f920de03a4e2e6a06b60671ce98971742 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz include $(INCLUDE_DIR)/package.mk @@ -40,38 +40,104 @@ endef PKG_BUILD_DEPENDS:=python-setuptools PYTHONPATH:=$(PYTHONPATH):$(PKG_BUILD_DIR)/thirdpart +define Download/django + FILE=Django-1.5.8.tar.gz + URL=https://www.djangoproject.com/m/releases/1.5/ + MD5SUM:=675fc736e2c29090f005e217ccf90b5b +endef + +define Download/djblets + PROTO=git + URL=https://github.com/djblets/djblets.git + SUBDIR=djblets-0.6.14 + FILE=djblets-0.6.14.tar.gz + VERSION=58c09bae9b71ac164f78c76746fd2e545aae6c68 +endef + +define Download/gunicorn + FILE=gunicorn-0.16.1.tar.gz + URL=https://pypi.python.org/packages/source/g/gunicorn/ + MD5SUM:=d53d5d04d941f2a3089e814e753a218f +endef + +define Download/six + FILE=six-1.4.1.tar.gz + URL=https://pypi.python.org/packages/source/s/six/ + MD5SUM:=bdbb9e12d3336c198695aa4cf3a61d62 +endef + +define Download/chardet + FILE=chardet-2.1.1.tar.gz + URL=https://pypi.python.org/packages/source/c/chardet/ + MD5SUM:=295367fd210d20f3febda615a88e1ef0 +endef + +define Download/flup + FILE=flup-1.0.2-py2.6.egg + URL=https://pypi.python.org/packages/2.6/f/flup/ + MD5SUM:=93ec6e3baeee3e5649a8456105178d4e +endef + +define Download/lockfile + FILE=lockfile-0.9.1.tar.gz + URL=https://pypi.python.org/packages/source/l/lockfile/ + MD5SUM:=ce61468d4c1263e3005737bbed2641f0 +endef + +define Download/python-daemon + FILE=python-daemon-1.5.5.tar.gz + URL=https://pypi.python.org/packages/source/p/python-daemon/ + MD5SUM:=1f6cd41473c2e201021a0aeef395b2b1 +endef + +define Download/python-dateutil + FILE=python-dateutil-1.5.tar.gz + URL=https://pypi.python.org/packages/source/p/python-dateutil/ + MD5SUM:=0dcb1de5e5cad69490a3b6ab63f0cfa5 +endef + define Build/Configure endef define Build/Compile + # Download python dependencies + $(eval $(call Download,django)) + $(eval $(call Download,djblets)) + $(eval $(call Download,gunicorn)) + $(eval $(call Download,six)) + $(eval $(call Download,chardet)) + $(eval $(call Download,flup)) + $(eval $(call Download,lockfile)) + $(eval $(call Download,python-daemon)) + $(eval $(call Download,python-dateutil)) # Install python dependencies $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://www.djangoproject.com/m/releases/1.5/Django-1.5.8.tar.gz) + $(DL_DIR)/Django-1.5.8.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://github.com/djblets/djblets/archive/release-0.6.14.tar.gz) + $(DL_DIR)/djblets-0.6.14.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/g/gunicorn/gunicorn-0.16.1.tar.gz) + $(DL_DIR)/gunicorn-0.16.1.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/s/six/six-1.4.1.tar.gz) + $(DL_DIR)/six-1.4.1.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/c/chardet/chardet-2.1.1.tar.gz) + $(DL_DIR)/chardet-2.1.1.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/2.6/f/flup/flup-1.0.2-py2.6.egg) + $(DL_DIR)/flup-1.0.2-py2.6.egg) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/l/lockfile/lockfile-0.9.1.tar.gz) + $(DL_DIR)/lockfile-0.9.1.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/p/python-daemon/python-daemon-1.5.5.tar.gz) + $(DL_DIR)/python-daemon-1.5.5.tar.gz) $(call HostPython,, \ $(STAGING_DIR_ROOT)/usr/bin/easy_install -d $(PKG_BUILD_DIR)/thirdpart -Z -N \ - https://pypi.python.org/packages/source/p/python-dateutil/python-dateutil-1.5.tar.gz) + $(DL_DIR)/python-dateutil-1.5.tar.gz) endef define Package/seafile-seahub/install diff --git a/net/seafile-server/Makefile b/net/seafile-server/Makefile index a0931d1c0..f671a799f 100644 --- a/net/seafile-server/Makefile +++ b/net/seafile-server/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=seafile-server -PKG_VERSION:=4.0.6 -PKG_RELEASE=$(PKG_SOURCE_VERSION) +PKG_VERSION:=4.1.2 +PKG_RELEASE=$(PKG_SOURCE_VERSION)-2 PKG_LICENSE:=GPL-3.0 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/haiwen/seafile.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=adf9a875a960c1471bf6c93fce397c576e985bb3 +PKG_SOURCE_VERSION:=c0166019c712e2e1d5e532fd5f7401b1b72db6d8 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_FIXUP:=autoreconf PKG_INSTALL:=1 @@ -31,15 +31,19 @@ define Package/seafile-server URL:=http://seafile.com/ DEPENDS:=+shadow-useradd +libarchive +libopenssl +glib2 +libsearpc +seafile-ccnet +seafile-seahub \ +sqlite3-cli +python-mysql +jansson +libevent2 +libevent2-openssl +zlib +libzdb +libsqlite3 \ - +libmysqlclient +libevhtp +libpthread +libuuid \ + +libmysqlclient +libpthread +libuuid \ +bash +sudo +procps +procps-pkill $(ICONV_DEPENDS) - EXTRA_DEPENDS:=seafile-ccnet (=4.0.6-1e1aeae83cc33356ebd5f064f4a4c148186b814d), seafile-seahub (=4.0.6-739b32b02c4803448d5cb75b3e22ec0073930aed) + EXTRA_DEPENDS:=seafile-ccnet (=4.1.2-a73109f09af4ecc49cdc4c57cdde51b38e15c31a), seafile-seahub (=4.1.2-3fb1288f920de03a4e2e6a06b60671ce98971742) endef define Package/seafile-server/description Open source cloud storage with advanced features on privacy protection and teamwork. endef +define Package/seafile-server/conffiles +/etc/config/seafile +endef + CONFIGURE_ARGS += --disable-riak \ --disable-client \ --disable-fuse \ @@ -50,7 +54,8 @@ CONFIGURE_ARGS += --disable-riak \ --disable-console PKG_BUILD_DEPENDS:=vala/host \ - libsearpc/host + libsearpc/host \ + libevhtp-1.1 TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib -liconv \ -L$(STAGING_DIR)/usr/lib/mysql -lmysqlclient -lz @@ -60,6 +65,7 @@ define Package/seafile-server/install $(INSTALL_DIR) $(1)/usr/lib/python2.7/site-packages $(INSTALL_DIR) $(1)/usr/share/seafile/seafile-server/runtime $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_DIR) $(1)/etc/config $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/ $(CP) $(PKG_INSTALL_DIR)/usr/lib/python2.7/site-packages/seafile/ $(1)/usr/lib/python2.7/site-packages/ $(CP) $(PKG_INSTALL_DIR)/usr/lib/python2.7/site-packages/seaserv/ $(1)/usr/lib/python2.7/site-packages/ @@ -71,6 +77,7 @@ define Package/seafile-server/install $(CP) $(PKG_BUILD_DIR)/scripts/sqlite2mysql.sh $(1)/usr/share/seafile/seafile-server/ $(CP) $(PKG_BUILD_DIR)/scripts/upgrade/ $(1)/usr/share/seafile/seafile-server/ $(INSTALL_BIN) ./files/seafile.init $(1)/etc/init.d/seafile + $(CP) ./files/seafile.conf $(1)/etc/config/seafile endef define Build/InstallDev diff --git a/net/seafile-server/files/seafile.conf b/net/seafile-server/files/seafile.conf new file mode 100644 index 000000000..fa8240e94 --- /dev/null +++ b/net/seafile-server/files/seafile.conf @@ -0,0 +1,2 @@ +# Start Seahub in fastcgi mode - 1 = enable, 0 = disable +SEAHUB_FASTCGI=0 diff --git a/net/seafile-server/files/seafile.init b/net/seafile-server/files/seafile.init index e9d3b03dc..42f98e2d9 100755 --- a/net/seafile-server/files/seafile.init +++ b/net/seafile-server/files/seafile.init @@ -7,8 +7,13 @@ EXTRA_HELP=" setup Runs the setup script reset_admin Alias to create_admin" EXTRA_COMMANDS="setup create_admin reset_admin" -export PATH="/usr/share/seafile/seafile-server/seahub/thirdpart:$PATH" -export PYTHONPATH="/usr/share/seafile/seafile-server/seahub/thirdpart:$PYTHONPATH" +SEAHUB_FASTCGI=0 + +[ -f /etc/config/seafile ] && \ + . /etc/config/seafile + +export PATH="/usr/share/seafile/seafile-server/seahub/thirdpart:${PATH}" +export PYTHONPATH="/usr/share/seafile/seafile-server/seahub/thirdpart:${PYTHONPATH}" start() { if [ ! -d /var/run/seafile ] @@ -18,27 +23,32 @@ start() { chmod o-rwx /var/run/seafile fi - # append parameter "--fastcgi" here to start seahub in fastcgi mode - cd "/usr/share/seafile" && \ - sudo PYTHONPATH="$PYTHONPATH" -u seafile -E \ - "/usr/bin/seafile-admin" start + if [ ${SEAHUB_FASTCGI} -eq 1 ]; then + cd "/usr/share/seafile" && \ + sudo PYTHONPATH="${PYTHONPATH}" -u seafile -E \ + "/usr/bin/seafile-admin" start --fastcgi + else + cd "/usr/share/seafile" && \ + sudo PYTHONPATH="${PYTHONPATH}" -u seafile -E \ + "/usr/bin/seafile-admin" start + fi } stop() { cd "/usr/share/seafile" && \ - sudo PYTHONPATH="$PYTHONPATH" -u seafile -E \ + sudo PYTHONPATH="${PYTHONPATH}" -u seafile -E \ "/usr/bin/seafile-admin" stop } setup() { cd "/usr/share/seafile" && \ - sudo PYTHONPATH="$PYTHONPATH" -u seafile -E \ + sudo PYTHONPATH="${PYTHONPATH}" -u seafile -E \ "/usr/bin/seafile-admin" setup } create_admin() { cd "/usr/share/seafile" && \ - sudo PYTHONPATH="$PYTHONPATH" -u seafile -E \ + sudo PYTHONPATH="${PYTHONPATH}" -u seafile -E \ "/usr/bin/seafile-admin" create-admin } diff --git a/net/seafile-server/patches/010-makefile-fix.patch b/net/seafile-server/patches/010-makefile-fix.patch deleted file mode 100644 index 1ae971e37..000000000 --- a/net/seafile-server/patches/010-makefile-fix.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -rupN seafile-3.1.7-server.orig/fileserver/Makefile.am seafile-3.1.7-server/fileserver/Makefile.am ---- seafile-3.1.7-server.orig/fileserver/Makefile.am 2014-10-16 05:30:04.000000000 +0200 -+++ seafile-3.1.7-server/fileserver/Makefile.am 2014-12-08 00:16:44.289364980 +0100 -@@ -6,7 +6,7 @@ AM_CFLAGS = -DPKGDATADIR=\"$(pkgdatadir) - -I$(top_srcdir)/lib \ - -I$(top_builddir)/lib \ - -I$(top_srcdir)/common \ -- -I$(includedir) \ -+ -I$(STAGING_DIR)$(includedir) \ - @CCNET_CFLAGS@ \ - @SEARPC_CFLAGS@ \ - @GLIB2_CFLAGS@ \ diff --git a/net/seafile-server/patches/050-libevhtp-search-path-fix.patch b/net/seafile-server/patches/050-libevhtp-search-path-fix.patch new file mode 100644 index 000000000..cb7e545d1 --- /dev/null +++ b/net/seafile-server/patches/050-libevhtp-search-path-fix.patch @@ -0,0 +1,17 @@ +diff -rupN seafile-server-4.1.2.orig/server/Makefile.am seafile-server-4.1.2/server/Makefile.am +--- seafile-server-4.1.2.orig/server/Makefile.am 2015-05-02 11:04:11.000000000 +0200 ++++ seafile-server-4.1.2/server/Makefile.am 2015-06-14 01:28:55.924834806 +0200 +@@ -4,6 +4,7 @@ AM_CFLAGS = -DPKGDATADIR=\"$(pkgdatadir) + -DPACKAGE_DATA_DIR=\""$(pkgdatadir)"\" \ + -DSEAFILE_SERVER \ + -DFULL_FEATURE \ ++ -I$(STAGING_DIR)/usr/include/libevhtp-1.1 \ + -I$(top_srcdir)/include \ + -I$(top_srcdir)/lib \ + -I$(top_builddir)/lib \ +@@ -122,4 +123,4 @@ seaf_server_LDADD = @CCNET_LIBS@ \ + @SEARPC_LIBS@ @JANSSON_LIBS@ @ZDB_LIBS@ @CURL_LIBS@ ${LIB_WS32} @ZLIB_LIBS@ \ + @LIBARCHIVE_LIBS@ + +-seaf_server_LDFLAGS = @STATIC_COMPILE@ @SERVER_PKG_RPATH@ ++seaf_server_LDFLAGS = @STATIC_COMPILE@ @SERVER_PKG_RPATH@ -L$(STAGING_DIR)/usr/lib/libevhtp-1.1 diff --git a/net/ser2net/Makefile b/net/ser2net/Makefile index ec0b5731f..49c9774ed 100644 --- a/net/ser2net/Makefile +++ b/net/ser2net/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ser2net PKG_VERSION:=2.10.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/ser2net diff --git a/net/ser2net/patches/002-LED-trigger.patch b/net/ser2net/patches/002-LED-trigger.patch new file mode 100644 index 000000000..bfc2734f9 --- /dev/null +++ b/net/ser2net/patches/002-LED-trigger.patch @@ -0,0 +1,418 @@ +From fa68debd94d40299dd2a69abd0a820ccfaadcbe8 Mon Sep 17 00:00:00 2001 +From: Michael Heimpold +Date: Wed, 22 Apr 2015 13:35:43 +0200 +Subject: [PATCH] Add support for triggering LEDs during serial traffic + +Signed-off-by: Michael Heimpold +--- + +Patch sent upstream: + http://sourceforge.net/p/ser2net/mailman/message/34064847/ + + Makefile.am | 4 +-- + dataxfer.c | 20 ++++++++++++ + readconfig.c | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + ser2net.conf | 13 ++++++++ + sysfs-led.c | 43 +++++++++++++++++++++++++ + sysfs-led.h | 11 +++++++ + utils.c | 30 ++++++++++++++++++ + utils.h | 9 ++++++ + 8 files changed, 228 insertions(+), 2 deletions(-) + create mode 100644 sysfs-led.c + create mode 100644 sysfs-led.h + +diff --git a/Makefile.am b/Makefile.am +index d56179f..866eb89 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -2,9 +2,9 @@ sbin_PROGRAMS = ser2net + ACLOCAL_AMFLAGS = -I m4 + AM_CFLAGS=-Wall + ser2net_SOURCES = controller.c dataxfer.c devcfg.c readconfig.c selector.c \ +- ser2net.c utils.c telnet.c buffer.c ++ ser2net.c utils.c telnet.c buffer.c sysfs-led.c + noinst_HEADERS = controller.h dataxfer.h devio.h readconfig.h selector.h \ +- utils.h telnet.h buffer.h ser2net.h ++ utils.h telnet.h buffer.h sysfs-led.h ser2net.h + man_MANS = ser2net.8 + EXTRA_DIST = $(man_MANS) ser2net.conf ser2net.spec ser2net.init + +diff --git a/dataxfer.c b/dataxfer.c +index 646a71b..b99cabf 100644 +--- a/dataxfer.c ++++ b/dataxfer.c +@@ -42,6 +42,7 @@ + #include "telnet.h" + #include "devio.h" + #include "buffer.h" ++#include "sysfs-led.h" + + #define SERIAL "term" + #define NET "tcp " +@@ -230,6 +231,12 @@ typedef struct port_info + #ifdef USE_RS485_FEATURE + struct serial_rs485 *rs485conf; + #endif ++ ++ /* ++ * LED names to flash for serial traffic ++ */ ++ char *led_tx; ++ char *led_rx; + } port_info_t; + + port_info_t *ports = NULL; /* Linked list of ports. */ +@@ -311,6 +318,8 @@ init_port_data(port_info_t *port) + #ifdef USE_RS485_FEATURE + port->rs485conf = NULL; + #endif ++ port->led_tx = NULL; ++ port->led_rx = NULL; + } + + static void +@@ -530,6 +539,9 @@ handle_dev_fd_read(struct devio *io) + /* Do both tracing, ignore errors. */ + do_trace(port, port->tb, port->dev_to_tcp.buf, count, SERIAL); + ++ if (port->led_rx) ++ led_blink_kick(port->led_rx); ++ + port->dev_bytes_received += count; + + if (port->enabled == PORT_TELNET) { +@@ -759,6 +771,8 @@ handle_tcp_fd_read(int fd, void *data) + return; + } + } else { ++ if (port->led_tx) ++ led_blink_kick(port->led_tx); + port->dev_bytes_sent += count; + port->tcp_to_dev.cursize -= count; + if (port->tcp_to_dev.cursize != 0) { +@@ -1854,6 +1868,12 @@ myconfig(void *data, struct absout *eout, const char *pos) + } else if (strncmp(pos, "tb=", 3) == 0) { + /* trace both directions. */ + port->trace_both.filename = find_tracefile(pos + 3); ++ } else if (strncmp(pos, "led-rx=", 7) == 0) { ++ /* LED for UART RX traffic */ ++ port->led_rx = find_led(pos + 7); ++ } else if (strncmp(pos, "led-tx=", 7) == 0) { ++ /* LED for UART TX traffic */ ++ port->led_tx = find_led(pos + 7); + #ifdef USE_RS485_FEATURE + } else if (strncmp(pos, "rs485=", 6) == 0) { + /* get RS485 configuration. */ +diff --git a/readconfig.c b/readconfig.c +index d4ca0d4..62cff5c 100644 +--- a/readconfig.c ++++ b/readconfig.c +@@ -31,6 +31,7 @@ + #include "readconfig.h" + #include "utils.h" + #include "telnet.h" ++#include "sysfs-led.h" + + #define MAX_LINE_SIZE 256 /* Maximum line length in the config file. */ + +@@ -361,6 +362,89 @@ free_rs485confs(void) + } + #endif + ++struct led_s ++{ ++ char *name; ++ char *device; ++ unsigned int duration; ++ struct led_s *next; ++}; ++ ++/* all LEDs in the system. */ ++struct led_s *leds = NULL; ++ ++static void ++handle_led(char *name, char *cfg) ++{ ++ struct led_s *new_led; ++ char devicename[256]; ++ ++ new_led = malloc(sizeof(*new_led)); ++ if (!new_led) { ++ syslog(LOG_ERR, "Out of memory handling LED on %d", lineno); ++ return; ++ } ++ ++ new_led->name = strdup(name); ++ if (!new_led->name) { ++ syslog(LOG_ERR, "Out of memory handling LED on %d", lineno); ++ free(new_led); ++ return; ++ } ++ ++ if (sscanf(cfg, "%256s %u", devicename, &new_led->duration) != 2) { ++ syslog(LOG_ERR, "Couldn't parse LED config on %d", lineno); ++ free(new_led->name); ++ free(new_led); ++ return; ++ } ++ ++ new_led->device = strdup(devicename); ++ if (!new_led->device) { ++ syslog(LOG_ERR, "Out of memory handling LED on %d", lineno); ++ free(new_led->name); ++ free(new_led); ++ return; ++ } ++ ++ /* setup the led */ ++ led_blink_prepare(new_led->device, new_led->duration); ++ ++ new_led->next = leds; ++ leds = new_led; ++} ++ ++char * ++find_led(const char *name) ++{ ++ struct led_s *led = leds; ++ ++ while (led) { ++ if (strcmp(name, led->name) == 0) ++ return strdup(led->device); ++ led = led->next; ++ } ++ syslog(LOG_ERR, "LED %s not found, it will be ignored", name); ++ return NULL; ++} ++ ++static void ++free_leds(void) ++{ ++ struct led_s *led; ++ ++ while (leds) { ++ led = leds; ++ leds = leds->next; ++ ++ led_off(led->device); ++ ++ free(led->name); ++ free(led->device); ++ free(led); ++ } ++} ++ + static int + startswith(char *str, const char *test, char **strtok_data) + { +@@ -503,6 +587,21 @@ handle_config_line(char *inbuf) + return; + } + ++ if (startswith(inbuf, "LED", &strtok_data)) { ++ char *name = strtok_r(NULL, ":", &strtok_data); ++ char *str = strtok_r(NULL, "\n", &strtok_data); ++ if (name == NULL) { ++ syslog(LOG_ERR, "No LED name given on line %d", lineno); ++ return; ++ } ++ if ((str == NULL) || (strlen(str) == 0)) { ++ syslog(LOG_ERR, "No LED given on line %d", lineno); ++ return; ++ } ++ handle_led(name, str); ++ return; ++ } ++ + comma = strchr(inbuf, ','); + if (comma) { + if (!strtok_r(comma, ":", &strtok_data)) { +@@ -568,6 +667,7 @@ readconfig(char *filename) + #ifdef USE_RS485_FEATURE + free_rs485confs(); + #endif ++ free_leds(); + + config_num++; + +diff --git a/ser2net.conf b/ser2net.conf +index 870926c..dc2ba19 100644 +--- a/ser2net.conf ++++ b/ser2net.conf +@@ -53,6 +53,8 @@ + # specified in TRACEFILE that will take all traced data. + # tw is data written to the device, tr is data read from + # the device, and tb is both. ++# The "led-tx" and "led-rx" options allow to specify ++# a LED defined above to trigger for traffic. + # + # or... + +@@ -79,6 +81,12 @@ + # This specifies a filename to trace output into, as tw=/tmp/trace1. + # This takes the same escape sequences as banners. + # ++# LED::sysfs-filename duration ++# This specifies a LED which will be configured to use linux's transient trigger. ++# The LED is always kicked when traffic is detected on serial side. The duration ++# is given in milliseconds. See Linux's documentation for transient trigger for ++# details. ++# + # OPENSTR::str + # This specifies a string to be transmitted to the device when the + # port is opened. This takes the same escape sequences as banners. +@@ -108,6 +116,9 @@ SIGNATURE:signature1:ser2net port ttyS2 + + RS485CONF:rs485port1:0:0:0:0 + ++LED:rx:duckbill:green:rs485 10 ++LED:tx:duckbill:red:rs485 10 ++ + TRACEFILE:tw1:/tmp/tw-\p-\Y-\M-\D-\H:\i:\s.\U + TRACEFILE:tr1:/tmp/tr-\p-\Y-\M-\D-\H:\i:\s.\U + +@@ -138,3 +149,5 @@ CLOSESTR:close1:close str\r\n + + 3020:telnet:0:/dev/ttyUSB0:9600 banner1 remctl asdfasd + 3021:telnet:0:/dev/ttyUSB1:9600 banner2 open1 close1 remctl ++ ++5000:telnet:0:/dev/ttyAPP0:9600 NONE 1STOPBIT 8DATABITS -XONXOFF LOCAL -RTSCTS led-tx=tx led-rx=rx +diff --git a/sysfs-led.c b/sysfs-led.c +new file mode 100644 +index 0000000..efe0b29 +--- /dev/null ++++ b/sysfs-led.c +@@ -0,0 +1,43 @@ ++/* ++ * Copyright (C) 2015 I2SE GmbH ++ */ ++#include ++#include ++ ++#include "utils.h" ++#include "sysfs-led.h" ++ ++#define SYSFS_LED_BASE "/sys/class/leds" ++ ++static int led_write(char *led, char *property, char *buf) ++{ ++ char fn[255]; ++ ++ snprintf(fn, sizeof(fn), "%s/%s/%s", SYSFS_LED_BASE, led, property); ++ ++ return file_store(fn, buf, strlen(buf)); ++} ++ ++int led_off(char *led) ++{ ++ led_write(led, "trigger", "none"); ++ led_write(led, "brightness", "0"); ++ return 0; ++} ++ ++int led_blink_prepare(char *led, unsigned int duration) ++{ ++ char buffer[10]; ++ ++ snprintf(buffer, sizeof(buffer), "%u", duration); ++ led_write(led, "trigger", "transient"); ++ msleep(10); ++ led_write(led, "state", "1"); ++ led_write(led, "duration", buffer); ++ return 0; ++} ++ ++int led_blink_kick(char *led) ++{ ++ return led_write(led, "activate", "1"); ++} +diff --git a/sysfs-led.h b/sysfs-led.h +new file mode 100644 +index 0000000..00b21b6 +--- /dev/null ++++ b/sysfs-led.h +@@ -0,0 +1,11 @@ ++/* ++ * Copyright (C) 2015 I2SE GmbH ++ */ ++#ifndef SYSFS_LED_H ++#define SYSFS_LED_H ++ ++int led_off(char *led); ++int led_blink_prepare(char *led, unsigned int duration); ++int led_blink_kick(char *led); ++ ++#endif /* SYSFS_LED_H */ +diff --git a/utils.c b/utils.c +index c194c4c..c96cedb 100644 +--- a/utils.c ++++ b/utils.c +@@ -25,6 +25,9 @@ + #include + #include + #include ++#include ++#include ++#include + + #include "ser2net.h" + #include "utils.h" +@@ -205,3 +208,30 @@ write_ignore_fail(int fd, const char *data, size_t count) + count -= written; + } + } ++ ++int ++msleep(int msec) ++{ ++ struct timespec req; ++ ++ req.tv_sec = 0; ++ req.tv_nsec = msec * 1000000; ++ ++ return nanosleep(&req, NULL); ++} ++ ++int ++file_store(const char *filename, const char *buf, size_t count) ++{ ++ int fd; ++ ++ if ((fd = open(filename, O_WRONLY | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR)) == -1) ++ return -1; ++ ++ if (write(fd, buf, count) != count) { ++ close(fd); ++ return -1; ++ } ++ ++ return close(fd); ++} +diff --git a/utils.h b/utils.h +index 582ea88..8af65ec 100644 +--- a/utils.h ++++ b/utils.h +@@ -64,6 +64,9 @@ char *find_tracefile(const char *name); + /* Search for RS485 configuration by name. */ + struct serial_rs485 *find_rs485conf(const char *name); + ++/* Search for a LED by name */ ++char *find_led(const char *name); ++ + void check_ipv6_only(int family, struct sockaddr *addr, int fd); + + /* Make sure the full contents get written, return an error if it occurs. */ +@@ -72,4 +75,10 @@ int write_full(int fd, char *data, size_t count); + /* Write the data completely out, return without comment on error. */ + void write_ignore_fail(int fd, const char *data, size_t count); + ++/* Helper to sleep a given amount of milli-seconds */ ++int msleep(int msec); ++ ++/* Store the given data to a file */ ++int file_store(const char *filename, const char *buf, size_t count); ++ + #endif /* UTILS */ +-- +1.7.10.4 + diff --git a/net/siit/Makefile b/net/siit/Makefile new file mode 100644 index 000000000..6d6d2987f --- /dev/null +++ b/net/siit/Makefile @@ -0,0 +1,42 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk +include $(INCLUDE_DIR)/kernel.mk + +PKG_NAME:=siit +PKG_VERSION:=1.2 +PKG_RELEASE:=1 +PKG_LICENSE:=GPLv2+ + +include $(INCLUDE_DIR)/package.mk + +define KernelPackage/siit + SUBMENU:=Network Devices + TITLE:=Stateless IP ICMP Translation Algorithm + DEPENDS:= @(!(TARGET_ps3||TARGET_pxcab)) + FILES:=$(PKG_BUILD_DIR)/siit.ko + AUTOLOAD:=$(call AutoLoad,50,siit) + MAINTAINER=Vladimir Ulrich +endef + +include $(INCLUDE_DIR)/kernel-defaults.mk + +define KernelPackage/siit/description + Stateless IP ICMP Translation Algorithm +endef + +define Build/Prepare + mkdir -p $(PKG_BUILD_DIR) + cp src/Makefile src/siit.h src/siit.c $(PKG_BUILD_DIR)/ +endef + +define Build/Compile + $(MAKE) $(KERNEL_MAKEOPTS) SUBDIRS="$(PKG_BUILD_DIR)" modules +endef + +$(eval $(call KernelPackage,siit)) diff --git a/net/siit/src/Makefile b/net/siit/src/Makefile new file mode 100644 index 000000000..06c36f1e3 --- /dev/null +++ b/net/siit/src/Makefile @@ -0,0 +1,5 @@ +obj-m := siit.o +ifeq ($(MAKING_MODULES),1) +-include $(TOPDIR)/Rules.make +endif + diff --git a/net/siit/src/siit.c b/net/siit/src/siit.c new file mode 100644 index 000000000..a25da9a9e --- /dev/null +++ b/net/siit/src/siit.c @@ -0,0 +1,1429 @@ +/* + * siit.c: the Stateless IP/ICMP Translator (SIIT) module for Linux. + * + * + */ + +#include +#include +#include +#include /* printk() */ +#include + +#include /* error codes */ +#include /* size_t */ +#include /* mark_bh */ +#include +#include +#include /* struct device, and other headers */ +#include /* eth_type_trans */ +#include /* struct iphdr */ +#include /* struct icmphdr */ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "siit.h" + +MODULE_AUTHOR("Dmitriy Moscalev, Grigory Klyuchnikov, Felix Fietkau"); + +/* + * If tos_ignore_flag != 0, we don't copy TOS and Traffic Class + * from origin paket and set it to 0 + */ +int tos_ignore_flag = 0; + +#define siit_stats(_dev) (&(_dev)->stats) + +/* + * The Utility stuff + */ + +#ifdef SIIT_DEBUG +/* print dump bytes (data point data area sizeof len and message + * before dump. + */ +static int siit_print_dump(char *data, int len, char *message) +{ + int i; + int j = 0, k = 1; + + len = len > BUFF_SIZE ? BUFF_SIZE : len; + printk("%s:\n", message); + for (i=0; i < len; i++, k++) { + if( i == len-1 || k == 16) { + printk("%02x\n", (~(~0 << 8) & *(data+i))); + j = 0; + k = 0; + } + else if (j) { + printk("%02x ", (~(~0 << 8) & *(data+i))); + j--; + } + else { + printk("%02x", (~(~0 << 8) & *(data+i))); + j++; + } + } + return 0; +} +#endif + +/* + * Open and close + */ +static int siit_open(struct net_device *dev) +{ + netif_start_queue(dev); + return 0; +} + + +static int siit_release(struct net_device *dev) +{ + netif_stop_queue(dev); /* can't transmit any more */ + return 0; +} + +/* + * Translation IPv4 to IPv6 stuff + * + * ip4_ip6 (src, len, dst, include_flag) + * + * where + * src - buffer with original IPv4 packet, + * len - size of original packet, + * dst - new buffer for IPv6 packet, + * include_flag - if = 1, dst point to IPv4 packet that is ICMP error + * included IP packet, else = 0 + */ + +static int ip4_ip6(char *src, int len, char *dst, int include_flag) +{ + struct iphdr *ih4 = (struct iphdr *) src; /* point to current IPv4 header struct */ + struct icmphdr *icmp_hdr; /* point to current ICMPv4 header struct */ + struct udphdr *udp_hdr; /* point to current IPv4 UDP header struct */ + + struct ipv6hdr *ih6 = (struct ipv6hdr *) dst; /* point to current IPv6 header struct */ + struct frag_hdr *ih6_frag = (struct frag_hdr *)(dst+sizeof(struct ipv6hdr)); + /* point to current IPv6 fragment header struct */ + struct icmp6hdr *icmp6_hdr; /* point to current ICMPv6 header */ + + int hdr_len = (int)(ih4->ihl * 4); /* IPv4 header length */ + int icmp_len; /* ICMPv4 packet length */ + int plen; /* payload length */ + + unsigned int csum; /* need to calculate ICMPv6 and UDP checksum */ + int fl_csum = 0; /* flag to calculate UDP checksum */ + int icmperr = 1; /* flag to indicate ICMP error message and to need + translate ICMP included IP packet */ + int fr_flag = 0; /* fragment flag, if = 0 - don't add + fragment header */ + __u16 new_tot_len; /* need to calculate IPv6 total length */ + __u8 new_nexthdr; /* next header code */ + __u16 icmp_ptr = 0; /* Pointer field in ICMP_PARAMETERPROB */ + +#ifdef SIIT_DEBUG /* print IPv4 header dump */ + siit_print_dump(src, hdr_len, "siit: ip4_ip6() (in) ip4 header dump"); +#endif + + /* If DF == 1 && MF == 0 && Fragment Offset == 0 + * or this packet is ICMP included IP packet + * we don't need fragment header */ + if (ntohs(ih4->frag_off) == IP_DF || include_flag ) { + /* not fragment and we need not to add Fragment + * Header to IPv6 packet. */ + /* total length = total length from IPv4 packet */ + new_tot_len = ntohs(ih4->tot_len); + + if (ih4->protocol == IPPROTO_ICMP) + new_nexthdr = NEXTHDR_ICMP; + else + new_nexthdr = ih4->protocol; + } + else { + /* need to add Fragment Header */ + fr_flag = 1; + /* total length = total length from IPv4 packet + + length of Fragment Header */ + new_tot_len = ntohs(ih4->tot_len) + sizeof(struct frag_hdr); + /* IPv6 Header NextHeader = NEXTHDR_FRAGMENT */ + new_nexthdr = NEXTHDR_FRAGMENT; + /* Fragment Header NextHeader copy from IPv4 packet */ + if (ih4->protocol == IPPROTO_ICMP) + ih6_frag->nexthdr = NEXTHDR_ICMP; + else + ih6_frag->nexthdr = ih4->protocol; + + /* copy frag offset from IPv4 packet */ + ih6_frag->frag_off = htons((ntohs(ih4->frag_off) & IP_OFFSET) << 3); + /* copy MF flag from IPv4 packet */ + ih6_frag->frag_off = htons((ntohs(ih6_frag->frag_off) | + ((ntohs(ih4->frag_off) & IP_MF) >> 13))); + /* copy Identification field from IPv4 packet */ + ih6_frag->identification = htonl(ntohs(ih4->id)); + /* reserved field initialized to zero */ + ih6_frag->reserved = 0; + } + + /* Form rest IPv6 fields */ + + /* + * At this point we need to add checking of unxpired source + * route optin and if it is, send ICMPv4 "destination + * unreacheble/source route failes" Type 3/Code 5 and + * drop packet. (NOT RELEASED YET) + */ + + /* IP version = 6 */ + ih6->version = 6; + + if (tos_ignore_flag) { + ih6->priority = 0; + ih6->flow_lbl[0] = 0; + } else { + ih6->priority = (ih4->tos & 0xf0) >> 4; + ih6->flow_lbl[0] = (ih4->tos & 0x0f) << 4; + } + ih6->flow_lbl[1] = 0; + ih6->flow_lbl[2] = 0; + + /* Hop Limit = IPv4 TTL */ + ih6->hop_limit = ih4->ttl; + + /* Translate source destination addresses, + for IPv6 host it's IPv4-translated IPv6 address, + for IPv4 host it's IPv4-mapped IPv6 address + + !!WARNING!! Instead IPv4-mapped IPv6 addresses we use addreesses + with unused prefix ::ffff:ffff:0:0/96, because KAME implementation + doesn't support IPv4-mapped addresses in IPv6 packets and discard them. + + */ + + if (include_flag) { + /* + It's ICMP included IP packet and there is a diffirence + in src/dst addresses then src/dst in normal direction + */ + + /* + Source address + is IPv4-translated IPv6 address because packet traveled + from IPv6 to IPv4 area + */ + ih6->saddr.in6_u.u6_addr32[0] = 0; + ih6->saddr.in6_u.u6_addr32[1] = 0; + ih6->saddr.in6_u.u6_addr32[2] = htonl(TRANSLATED_PREFIX); /* to network order bytes */ + ih6->saddr.in6_u.u6_addr32[3] = ih4->saddr; + + /* + Destination address + is IPv4-mapped address (but it's not IPv4- mapped, we use + prefix ::ffff:ffff:0:0/96 + */ + ih6->daddr.in6_u.u6_addr32[0] = 0; + ih6->daddr.in6_u.u6_addr32[1] = 0; + ih6->daddr.in6_u.u6_addr32[2] = htonl(MAPPED_PREFIX); /* to network order bytes */ + ih6->daddr.in6_u.u6_addr32[3] = ih4->daddr; + } + else { + + /* + This is normal case (packet isn't included IP packet) + + Source address + is IPv4-mapped address (but it's not IPv4- mapped, we use + prefix ::ffff:ffff:0:0/96) + */ + ih6->saddr.in6_u.u6_addr32[0] = 0; + ih6->saddr.in6_u.u6_addr32[1] = 0; + ih6->saddr.in6_u.u6_addr32[2] = htonl(MAPPED_PREFIX); /* to network order bytes */ + ih6->saddr.in6_u.u6_addr32[3] = ih4->saddr; + + /* Destination address + is is IPv4-translated IPv6 address + */ + ih6->daddr.in6_u.u6_addr32[0] = 0; + ih6->daddr.in6_u.u6_addr32[1] = 0; + ih6->daddr.in6_u.u6_addr32[2] = htonl(TRANSLATED_PREFIX); /* to network order bytes */ + ih6->daddr.in6_u.u6_addr32[3] = ih4->daddr; + } + + /* Payload Length */ + plen = new_tot_len - hdr_len; /* Payload length = IPv4 total len - IPv4 header len */ + ih6->payload_len = htons(plen); + + /* Next Header */ + ih6->nexthdr = new_nexthdr; /* Next Header */ + + /* Process ICMP protocols data */ + + switch (ih4->protocol) { + case IPPROTO_ICMP: + if ( (ntohs(ih4->frag_off) & IP_OFFSET) != 0 || (ntohs(ih4->frag_off) & IP_MF) != 0 ) { + PDEBUG("ip4_ip6(): don't translate ICMPv4 fragments - packet dropped.\n"); + return -1; + } + + icmp_hdr = (struct icmphdr *) (src+hdr_len); /* point to ICMPv4 header */ + csum = 0; + icmp_len = ntohs(ih4->tot_len) - hdr_len; /* ICMPv4 packet length */ + icmp6_hdr = (struct icmp6hdr *)(dst+sizeof(struct ipv6hdr) + +fr_flag*sizeof(struct frag_hdr)); /* point to ICMPv6 header */ + + if (include_flag) { + /* ICMPv4 packet cannot be included in ICMPv4 Error message */ + /* !!! May be it's WRONG !!! ICMPv4 QUERY packet can be included + in ICMPv4 Error message */ + PDEBUG("ip4_ip6(): It's included ICMPv4 in ICMPv4 Error message - packet dropped.\n"); + return -1; + } + + /* Check ICMPv4 Type field */ + switch (icmp_hdr->type) { + /* ICMP Error messages */ + /* Destination Unreachable (Type 3) */ + case ICMP_DEST_UNREACH: + icmp6_hdr->icmp6_type = ICMPV6_DEST_UNREACH; /* to Type 1 */ + icmp6_hdr->icmp6_unused = 0; + switch (icmp_hdr->code) + { + case ICMP_NET_UNREACH: /* Code 0 */ + case ICMP_HOST_UNREACH: /* Code 1 */ + case ICMP_SR_FAILED: /* Code 5 */ + case ICMP_NET_UNKNOWN: /* Code 6 */ + case ICMP_HOST_UNKNOWN: /* Code 7 */ + case ICMP_HOST_ISOLATED: /* Code 8 */ + case ICMP_NET_UNR_TOS: /* Code 11 */ + case ICMP_HOST_UNR_TOS: /* Code 12 */ + icmp6_hdr->icmp6_code = ICMPV6_NOROUTE; /* to Code 0 */ + break; + case ICMP_PROT_UNREACH: /* Code 2 */ + icmp6_hdr->icmp6_type = ICMPV6_PARAMPROB; /* to Type 4 */ + icmp6_hdr->icmp6_code = ICMPV6_UNK_NEXTHDR; /* to Code 1 */ + /* Set pointer filed to 6, it's octet offset IPv6 Next Header field */ + icmp6_hdr->icmp6_pointer = htonl(6); + break; + case ICMP_PORT_UNREACH: /* Code 3 */ + icmp6_hdr->icmp6_code = ICMPV6_PORT_UNREACH; /* to Code 4 */ + break; + case ICMP_FRAG_NEEDED: /* Code 4 */ + icmp6_hdr->icmp6_type = ICMPV6_PKT_TOOBIG; /* to Type 2 */ + icmp6_hdr->icmp6_code = 0; + /* Correct MTU */ + if (icmp_hdr->un.frag.mtu == 0) + /* we use minimum MTU for IPv4 PMTUv4 RFC1191, section 5; + IPv6 implementation wouldn't accept Path MTU < 1280, + but it records info correctly to always include + a fragment header */ + icmp6_hdr->icmp6_mtu = htonl(576); + else + /* needs to adjusted for difference between IPv4/IPv6 headers + * SIIT RFC2765, section 3.3, + * we assume that difference is 20 bytes */ + icmp6_hdr->icmp6_mtu = htonl(ntohs(icmp_hdr->un.frag.mtu)+IP4_IP6_HDR_DIFF); + + break; + case ICMP_NET_ANO: /* Code 9 */ + case ICMP_HOST_ANO: /* Code 10 */ + icmp6_hdr->icmp6_code = ICMPV6_ADM_PROHIBITED; /* to Code 1 */ + break; + default: /* discard any other Code */ + PDEBUG("ip4_ip6(): Unknown ICMPv4 Type %d Code %d - packet dropped.\n", + ICMP_DEST_UNREACH, icmp_hdr->code); + return -1; + } + break; + /* Time Exceeded (Type 11) */ + case ICMP_TIME_EXCEEDED: + icmp6_hdr->icmp6_type = ICMPV6_TIME_EXCEED; + icmp6_hdr->icmp6_code = icmp_hdr->code; + break; + /* Parameter Problem (Type 12) */ + case ICMP_PARAMETERPROB: + icmp6_hdr->icmp6_type = ICMPV6_PARAMPROB; + icmp6_hdr->icmp6_code = icmp_hdr->code; + + icmp_ptr = ntohs(icmp_hdr->un.echo.id) >> 8; + switch (icmp_ptr) { + case 0: + icmp6_hdr->icmp6_pointer = 0; /* IPv4 Version -> IPv6 Version */ + break; + case 2: + icmp6_hdr->icmp6_pointer = __constant_htonl(4); /* IPv4 length -> IPv6 Payload Length */ + break; + case 8: + icmp6_hdr->icmp6_pointer = __constant_htonl(7); /* IPv4 TTL -> IPv6 Hop Limit */ + break; + case 9: + icmp6_hdr->icmp6_pointer = __constant_htonl(6); /* IPv4 Protocol -> IPv6 Next Header */ + break; + case 12: + icmp6_hdr->icmp6_pointer = __constant_htonl(8); /* IPv4 Src Addr -> IPv6 Src Addr */ + break; + case 16: + icmp6_hdr->icmp6_pointer = __constant_htonl(24); /* IPv4 Dst Addr -> IPv6 Dst Addr */ + break; + default: + icmp6_hdr->icmp6_pointer = 0xffffffff; /* set to all ones in any other cases */ + break; + } + break; + case ICMP_ECHO: + icmperr = 0; + icmp6_hdr->icmp6_type = ICMPV6_ECHO_REQUEST; + icmp6_hdr->icmp6_code = 0; + /* Copy rest ICMP data to new IPv6 packet without changing */ + memcpy(((char *)icmp6_hdr)+4, ((char *)icmp_hdr)+4, len - hdr_len - 4); + break; + + case ICMP_ECHOREPLY: + icmperr = 0; + icmp6_hdr->icmp6_type = ICMPV6_ECHO_REPLY; + icmp6_hdr->icmp6_code = 0; + /* Copy rest ICMP data to new IPv6 packet without changing */ + memcpy(((char *)icmp6_hdr)+4, ((char *)icmp_hdr)+4, len - hdr_len - 4); + break; + + /* Discard any other ICMP messages */ + default: + PDEBUG("ip4_ip6(): Unknown ICMPv4 packet Type %x - packet dropped.\n", icmp_hdr->type); + return -1; + } + + /* Now if it's ICMPv4 Error message we must translate included IP packet */ + + if (icmperr) { + /* Call our ip4_ip6() to translate included IP packet */ + if (ip4_ip6(src+hdr_len+sizeof(struct icmphdr), len - hdr_len - sizeof(struct icmphdr), + dst+sizeof(struct ipv6hdr)+fr_flag*sizeof(struct frag_hdr) + +sizeof(struct icmp6hdr), 1) == -1) { + PDEBUG("ip4_ip6(): Uncorrect translation of ICMPv4 Error message - packet dropped.\n"); + return -1; + } + /* correct ICMPv6 packet length for diffirence between IPv4 and IPv6 headers + in included IP packet + */ + icmp_len += 20; + /* and correct Payload length for diffirence between IPv4 and IPv6 headers */ + plen += 20; + ih6->payload_len = htons(plen); + } + + /* Calculate ICMPv6 checksum */ + + icmp6_hdr->icmp6_cksum = 0; + csum = 0; + + csum = csum_partial((u_char *)icmp6_hdr, icmp_len, csum); + icmp6_hdr->icmp6_cksum = csum_ipv6_magic(&ih6->saddr, &ih6->daddr, icmp_len, + IPPROTO_ICMPV6, csum); + break; + + /* Process TCP protocols data */ + case IPPROTO_TCP: + /* Copy TCP data to new IPv6 packet without changing */ + memcpy(dst+sizeof(struct ipv6hdr)+fr_flag*sizeof(struct frag_hdr), + src+hdr_len, len - hdr_len); + break; + + /* Process UDP protocols data */ + case IPPROTO_UDP: + udp_hdr = (struct udphdr *)(src+hdr_len); + if ((ntohs(ih4->frag_off) & IP_OFFSET) == 0) { + if ((ntohs(ih4->frag_off) & IP_MF) != 0) { + /* It's a first fragment */ + if (udp_hdr->check == 0) { + /* System management event */ + printk("siit: First fragment of UDP with zero checksum - packet droped\n"); + printk("siit: addr: %x src port: %d dst port: %d\n", + htonl(ih4->saddr), htons(udp_hdr->source), htons(udp_hdr->dest)); + return -1; + } + } + else if (udp_hdr->check == 0) + fl_csum = 1; + } + + /* Copy UDP data to new IPv6 packet */ + udp_hdr = (struct udphdr *)(dst+sizeof(struct ipv6hdr) + + fr_flag*sizeof(struct frag_hdr)); + memcpy((char *)udp_hdr, src+hdr_len, len - hdr_len); + + /* Calculate UDP checksum if UDP checksum in IPv4 packet was ZERO + and if it isn't included IP packet + */ + if (fl_csum && (!include_flag)) { + udp_hdr->check = 0; + csum = 0; + csum = csum_partial((unsigned char *)udp_hdr, plen - fr_flag*sizeof(struct frag_hdr), csum); + udp_hdr->check = csum_ipv6_magic(&ih6->saddr, &ih6->daddr, plen - + fr_flag*sizeof(struct frag_hdr), IPPROTO_UDP, csum); + } + break; + + /* Discard packets with any other protocol */ + default: + PDEBUG("ip4_ip6(): Unknown upper protocol - packet dropped.\n"); + return -1; + } + +#ifdef SIIT_DEBUG + siit_print_dump(dst, sizeof(struct ipv6hdr), "siit: ip4_ip6(): (out) ipv6 header dump"); +#endif + + return 0; +} + +/* + * Translation IPv6 to IPv4 stuff + * + * ip6_ip4(src, len, dst, include_flag) + * + * where + * src - buffer with original IPv6 packet, + * len - size of original packet, + * dst - new buffer for IPv4 packet, + * include_flag - if = 1, dst point to IPv6 packet that is ICMP error + * included IP packet, else = 0 + * + */ + +static int ip6_ip4(char *src, int len, char *dst, int include_flag) +{ + struct ipv6hdr *ip6_hdr; /* point to current IPv6 header struct */ + struct iphdr *ip_hdr; /* point to current IPv4 header struct */ + int opts_len = 0; /* to sum Option Headers length */ + int icmperr = 1; /* if = 1, indicate that packet is ICMP Error message, else = 0 */ + int ntot_len = 0; /* to calculate IPv6 Total Length field */ + int real_len; + int len_delta; + int ip6_payload_len; + int inc_opts_len = 0; /* to sum Option Headers length in ICMP included IP packet */ + __u8 next_hdr; /* Next Header */ + +#ifdef SIIT_DEBUG + siit_print_dump(src, sizeof(struct ipv6hdr), "siit: ip6_ip4(): (in) ipv6 header dump"); +#endif + + if ( (len_delta = len - sizeof(struct ipv6hdr)) >= 0) + { + ip6_hdr = (struct ipv6hdr *)src; + ip_hdr = (struct iphdr *)dst; + + real_len = sizeof(struct iphdr); + + /* Check validation of Saddr & Daddr? is a packet to fall under our translation? */ + if (include_flag) { /* It's ICMP included IP packet, + about process include_flag see comment in ip4_ip6() */ + if (ip6_hdr->saddr.s6_addr32[2] != htonl(MAPPED_PREFIX)) { + PDEBUG("ip6_ip4(): Included IP packet Src addr isn't mapped addr: %x%x%x%x, packet dropped.\n", + ip6_hdr->saddr.s6_addr32[0], ip6_hdr->saddr.s6_addr32[1], + ip6_hdr->saddr.s6_addr32[2], ip6_hdr->saddr.s6_addr32[3]); + return -1; + } + if ( ip6_hdr->daddr.s6_addr32[2] != htonl(TRANSLATED_PREFIX)) { + PDEBUG("ip6_ip4(): Included IP packet Dst addr isn't translated addr: %x%x%x%x, packet dropped.\n", + ip6_hdr->daddr.s6_addr32[0], ip6_hdr->daddr.s6_addr32[1], + ip6_hdr->daddr.s6_addr32[2], ip6_hdr->daddr.s6_addr32[3]); + return -1; + } + } + else { /* It's normal IP packet (not included in ICMP) */ + if (ip6_hdr->saddr.s6_addr32[2] != htonl(TRANSLATED_PREFIX)) { + PDEBUG("ip6_ip4(): Src addr isn't translated addr: %x%x%x%x, packet dropped.\n", + ip6_hdr->saddr.s6_addr32[0], ip6_hdr->saddr.s6_addr32[1], + ip6_hdr->saddr.s6_addr32[2], ip6_hdr->saddr.s6_addr32[3]); + return -1; + } + if ( ip6_hdr->daddr.s6_addr32[2] != htonl(MAPPED_PREFIX)) { + PDEBUG("ip6_ip4(): Dst addr isn't mapped addr: %x%x%x%x, packet dropped.\n", + ip6_hdr->daddr.s6_addr32[0], ip6_hdr->daddr.s6_addr32[1], + ip6_hdr->daddr.s6_addr32[2], ip6_hdr->daddr.s6_addr32[3]); + return -1; + } + } + + /* Set IPv4 Fragment Offset and ID to 0 + before process any Option Headers */ + ip_hdr->frag_off = 0; + ip_hdr->id = 0; + + /* + * We process only Fragment Header. Any other options headers + * are ignored, i.e. there is no attempt to translate them. + * However, the Total Length field and the Protocol field would + * have to be adjusted to "skip" these extension headers. + */ + + next_hdr = ip6_hdr->nexthdr; + + /* Hop_by_Hop options header (ip6_hdr->nexthdr = 0). It must + * appear only in IPv6 header's Next Header field. + */ + if (next_hdr == NEXTHDR_HOP) { + if ( (len_delta - sizeof(struct ipv6_opt_hdr)) >= 0) + { + struct ipv6_opt_hdr *ip6h = + (struct ipv6_opt_hdr *)(src+sizeof(struct ipv6hdr) + opts_len); + if ( (len_delta -= ip6h->hdrlen*8 + 8) >= 0) + { + opts_len += ip6h->hdrlen*8 + 8; /* See RFC 2460 page 11: + Hdr Ext Len 8-bit unsigned integer. Length of the Hop-by- + Hop Options header in 8-octet units, not + including the first 8 octets. + */ + next_hdr = ip6h->nexthdr; + } + else + { + PDEBUG("ip6_ip4(): hop_by_hop header error, packet droped"); + /* Generate ICMP Parameter Problem */ + return -1; + } + } + } + + if (len_delta > 0) + { + while(next_hdr != NEXTHDR_ICMP && next_hdr != NEXTHDR_TCP + && next_hdr != NEXTHDR_UDP) + { + /* Destination options header */ + if (next_hdr == NEXTHDR_DEST) + { + if ( (len_delta - sizeof(struct ipv6_opt_hdr)) >= 0) + { + struct ipv6_opt_hdr *ip6d = + (struct ipv6_opt_hdr *)(src + sizeof(struct ipv6hdr) + opts_len); + if ( (len_delta -= ip6d->hdrlen*8 + 8) >= 0) + { + opts_len += ip6d->hdrlen*8 + 8; + next_hdr = ip6d->nexthdr; + } + } + else + { + PDEBUG("ip6_ip4(): destination header error, packet droped"); + /* Generate ICMP Parameter Problem */ + return -1; + } + } + /* Routing options header */ + else if (next_hdr == NEXTHDR_ROUTING) + { + if ( (len_delta - sizeof(struct ipv6_rt_hdr)) >= 0) + { + struct ipv6_rt_hdr *ip6rt = + (struct ipv6_rt_hdr *)(src+sizeof(struct ipv6hdr) + opts_len); + /* RFC 2765 SIIT, 4.1: + If a routing header with a non-zero Segments Left field is present + then the packet MUST NOT be translated, and an ICMPv6 "parameter + problem/ erroneous header field encountered" (Type 4/Code 0) error + message, with the Pointer field indicating the first byte of the + Segments Left field, SHOULD be returned to the sender. + */ + if (ip6rt->segments_left != 0) { + /* Build ICMPv6 "Parameter Problem/Erroneous Header + Field Encountered" & drop the packet */ + /* !!! We don't send ICMPv6 "Parameter Problem" !!! */ + PDEBUG("ip6_ip4(): routing header type != 0\n"); + return -1; + } + if ( (len_delta -= ip6rt->hdrlen*8 + 8) >= 0) + { + opts_len += ip6rt->hdrlen*8 + 8; + next_hdr = ip6rt->nexthdr; + } + else + { + PDEBUG("ip6_ip4(): routing header error, packet droped"); + /* Generate ICMP Parameter Problem */ + return -1; + } + } + } + /* Fragment options header */ + else if (next_hdr == NEXTHDR_FRAGMENT) + { + if ( (len_delta -= sizeof(struct frag_hdr)) >= 0) + { + struct frag_hdr *ip6f = + (struct frag_hdr *)(src+sizeof(struct ipv6hdr)+opts_len); + + opts_len += sizeof(struct frag_hdr); /* Frag Header Length = 8 */ + ip_hdr->id = htons(ntohl(ip6f->identification)); /* ID field */ + ip_hdr->frag_off = htons((ntohs(ip6f->frag_off) & IP6F_OFF_MASK) >> 3); + /* fragment offset */ + ip_hdr->frag_off = htons(ntohs(ip_hdr->frag_off) | + ((ntohs(ip6f->frag_off) & IP6F_MORE_FRAG) << 13)); + /* more fragments flag */ + next_hdr = ip6f->nexthdr; + } + else + { + PDEBUG("ip6_ip4(): fragment header error, packet droped"); + /* Generate ICMP Parameter Problem */ + return -1; + } + } + /* No Next Header */ + else if (next_hdr == NEXTHDR_NONE) + { + /* RFC 2460 IPv6 Specification, 4.7 + 4.7 No Next Header + + The value 59 in the Next Header field of an IPv6 header or any + extension header indicates that there is nothing following that + header. If the Payload Length field of the IPv6 header indicates the + presence of octets past the end of a header whose Next Header field + contains 59, those octets must be ignored, and passed on unchanged if + the packet is forwarded. + */ + break; + } + else if (next_hdr == NEXTHDR_ESP || next_hdr == NEXTHDR_AUTH) + { + PDEBUG("ip6_ip4(): cannot translate AUTH or ESP extention header, packet dropped\n"); + return -1; + } + else if (next_hdr == NEXTHDR_IPV6) + { + PDEBUG("ip6_ip4(): cannot translate IPv6-IPv6 packet, packet dropped\n"); + return -1; + } + else if (next_hdr == 0) + { + /* As say RFC 2460 (IPv6 Spec) we should discard the packet and send an + ICMP Parameter Problem message to the source of the packet, with an + ICMP Code value of 1 ("unrecognized Next Header type encountered") + and the ICMP Pointer field containing the offset of the unrecognized + value within the original packet + */ + /* NOT IMPLEMENTED */ + PDEBUG("ip6_ip4(): NEXTHDR in extention header = 0, packet dropped\n"); + return -1; + } + else + { + PDEBUG("ip6_ip4(): cannot translate extention header = %d, packet dropped\n", next_hdr); + return -1; + } + } + } + } + else + { + PDEBUG("ip6_ip4(): error packet len, packet dropped.\n"); + return -1; + } + + /* Building ipv4 packet */ + + ip_hdr->version = IPVERSION; + ip_hdr->ihl = 5; + + /* TOS see comment about TOS in ip4_ip6() */ + if (tos_ignore_flag) + ip_hdr->tos = 0; + else { + ip_hdr->tos = ip6_hdr->priority << 4; + ip_hdr->tos = ip_hdr->tos | (ip6_hdr->flow_lbl[0] >> 4); + } + + /* IPv4 Total Len = IPv6 Payload Len + + IPv4 Header Len (without options) - Options Headers Len */ + ip6_payload_len = ntohs(ip6_hdr->payload_len); + + if (ip6_payload_len == 0) + ntot_len = 0; + else + ntot_len = ip6_payload_len + IP4_IP6_HDR_DIFF - opts_len; + + ip_hdr->tot_len = htons(ntot_len); + + /* IPv4 TTL = IPv6 Hop Limit */ + ip_hdr->ttl = ip6_hdr->hop_limit; + + /* IPv4 Protocol = Next Header that will point to upper layer protocol */ + ip_hdr->protocol = next_hdr; + + /* IPv4 Src addr = last 4 bytes from IPv6 Src addr */ + ip_hdr->saddr = ip6_hdr->saddr.s6_addr32[3]; + /* IPv4 Dst addr = last 4 bytes from IPv6 Dst addr */ + ip_hdr->daddr = ip6_hdr->daddr.s6_addr32[3]; + + /* Calculate IPv4 header checksum */ + ip_hdr->check = 0; + ip_hdr->check = ip_fast_csum((unsigned char *)ip_hdr, ip_hdr->ihl); + + if (len_delta > 0) + { + /* PROCESS ICMP */ + + if (next_hdr == NEXTHDR_ICMP) + { + struct icmp6hdr *icmp6_hdr; + struct icmphdr *icmp_hdr; + + if ((len_delta -= sizeof(struct icmp6hdr)) >= 0) + { + icmp6_hdr = (struct icmp6hdr *)(src + sizeof(struct ipv6hdr) + opts_len); + icmp_hdr = (struct icmphdr *)(dst + sizeof(struct iphdr)); + + real_len += len_delta + sizeof(struct icmphdr); + + /* There is diffirent between ICMPv4/ICMPv6 protocol codes + IPPROTO_ICMP = 1 + IPPROTO_ICMPV6 = 58 */ + ip_hdr->protocol = IPPROTO_ICMP; + + if (include_flag) { + /* !!! Warnig !!! We discard ICMP packets with any ICMP as included + in ICMP Error. But ICMP Error messages can include ICMP Query message + */ + if (icmp6_hdr->icmp6_type != ICMPV6_ECHO_REQUEST) + { + PDEBUG("ip6_ip4(): included ICMPv6 in ICMPv6 Error message, packet dropped\n"); + return -1; + } + } + + /* Translate ICMPv6 to ICMPv4 */ + switch (icmp6_hdr->icmp6_type) + { +/* ICMP Error messages */ + /* Destination Unreachable (Type 1) */ + case ICMPV6_DEST_UNREACH: /* Type 1 */ + icmp_hdr->type = ICMP_DEST_UNREACH; /* to Type 3 */ + icmp_hdr->un.echo.id = 0; + icmp_hdr->un.echo.sequence = 0; + switch (icmp6_hdr->icmp6_code) + { + case ICMPV6_NOROUTE: /* Code 0 */ + case ICMPV6_NOT_NEIGHBOUR: /* Code 2 */ + case ICMPV6_ADDR_UNREACH: /* Code 3 */ + icmp_hdr->code = ICMP_HOST_UNREACH; /* To Code 1 */ + break; + case ICMPV6_ADM_PROHIBITED: /* Code 1 */ + icmp_hdr->code = ICMP_HOST_ANO; /* To Code 10 */ + break; + case ICMPV6_PORT_UNREACH: /* Code 4 */ + icmp_hdr->code = ICMP_PORT_UNREACH; /* To Code 3 */ + + break; + default: /* discard any other codes */ + PDEBUG("ip6_ip4(): Unknown ICMPv6 Type %d Code %d - packet dropped.\n", + ICMPV6_DEST_UNREACH, icmp6_hdr->icmp6_code); + return -1; + } + break; + /* Packet Too Big (Type 2) */ + case ICMPV6_PKT_TOOBIG: /* Type 2 */ + icmp_hdr->type = ICMP_DEST_UNREACH; /* to Type 3 */ + icmp_hdr->code = ICMP_FRAG_NEEDED; /* to Code 4 */ + /* Change MTU, RFC 2765 (SIIT), 4.2: + The MTU field needs to be adjusted for the difference between + the IPv4 and IPv6 header sizes taking into account whether or + not the packet in error includes a Fragment header. + */ + /* !!! Don't implement !!! */ + icmp_hdr->un.frag.mtu = (__u16) icmp6_hdr->icmp6_mtu; + break; + /* Time Exceeded (Type 3) */ + case ICMPV6_TIME_EXCEED: + icmp_hdr->type = ICMP_TIME_EXCEEDED; /* to Type 11 */ + icmp_hdr->code = icmp6_hdr->icmp6_code; /* Code unchanged */ + break; + /* Parameter Problem (Type 4) */ + case ICMPV6_PARAMPROB: + switch (icmp6_hdr->icmp6_code) { + case ICMPV6_UNK_NEXTHDR: /* Code 1 */ + icmp_hdr->type = ICMP_DEST_UNREACH; /* to Type 3 */ + icmp_hdr->code = ICMP_PROT_UNREACH; /* to Code 2 */ + break; + default: /* if Code != 1 */ + icmp_hdr->type = ICMP_PARAMETERPROB; /* to Type 12 */ + icmp_hdr->code = 0; /* to Code 0 */ + /* Update Pointer field + RFC 2765 (SIIT), 4.2: + The Pointer needs to be updated to point to the corresponding + field in the translated include IP header. + */ + switch (ntohl(icmp6_hdr->icmp6_pointer)) + { + case 0: /* IPv6 Version -> IPv4 Version */ + icmp_hdr->un.echo.id = 0; + break; + case 4: /* IPv6 PayloadLength -> IPv4 Total Length */ + icmp_hdr->un.echo.id = 0x0002; /* 2 */ + break; + case 6: /* IPv6 Next Header-> IPv4 Protocol */ + icmp_hdr->un.echo.id = 0x0009; /* 9 */ + break; + case 7: /* IPv6 Hop Limit -> IPv4 TTL */ + icmp_hdr->un.echo.id = 0x0008; /* 8 */ + break; + case 8: /* IPv6 Src addr -> IPv4 Src addr */ + icmp_hdr->un.echo.id = 0x000c; /* 12 */ + break; + case 24: /* IPv6 Dst addr -> IPv4 Dst addr*/ + icmp_hdr->un.echo.id = 0x0010; /* 16 */ + break; + default: /* set all ones in other cases */ + icmp_hdr->un.echo.id = 0xff; + break; + } + break; + } + break; + +/* End of ICMP Error messages */ + + /* Echo Request and Echo Reply (Type 128 and 129) */ + case ICMPV6_ECHO_REQUEST: + icmperr = 0; /* not error ICMP message */ + icmp_hdr->type = ICMP_ECHO; /* to Type 8 */ + icmp_hdr->code = 0; /* to Code 0 */ + icmp_hdr->un.echo.id = icmp6_hdr->icmp6_identifier; + icmp_hdr->un.echo.sequence = icmp6_hdr->icmp6_sequence; + /* copy rest of ICMP data to result packet */ + if (len_delta > 0) + memcpy(((char *)icmp_hdr) + sizeof(struct icmphdr), + ((char *)icmp6_hdr) + sizeof(struct icmp6hdr), len_delta); + break; + case ICMPV6_ECHO_REPLY: + icmperr = 0; /* not error ICMP message */ + icmp_hdr->type = ICMP_ECHOREPLY; /* to Type 0 */ + icmp_hdr->code = 0; /* to Code 0 */ + icmp_hdr->un.echo.id = icmp6_hdr->icmp6_identifier; + icmp_hdr->un.echo.sequence = icmp6_hdr->icmp6_sequence; + /* copy rest of ICMP data */ + if (len_delta > 0) + memcpy(((char *)icmp_hdr) + sizeof(struct icmphdr), + ((char *)icmp6_hdr) + sizeof(struct icmp6hdr), len_delta); + break; + default: + /* Unknown error messages. Silently drop. */ + PDEBUG("ip6_ip4(): unknown ICMPv6 Type %d, packet dropped.\n", icmp6_hdr->icmp6_type); + return -1; + } + + if (icmperr) + { + /* If ICMP Error message, we translate IP included packet*/ + if (len_delta >= sizeof(struct ipv6hdr)) + { + if((inc_opts_len = ip6_ip4((char *)icmp6_hdr + sizeof(struct icmp6hdr), len_delta, + (char *)icmp_hdr + sizeof(struct icmphdr), 1)) == -1) { + PDEBUG("ip6_ip4(): incorrect translation of ICMPv6 Error message, packet dropped\n"); + return -1; + } + /* correct IPv4 Total Len that = old Total Len + - Options Headers Len in included IP packet + - diffirence between IPv6 Header Len and IPv4 Header Len + */ + if (ntot_len != 0) + ip_hdr->tot_len = htons(ntot_len - inc_opts_len - IP4_IP6_HDR_DIFF); + real_len = real_len - inc_opts_len - IP4_IP6_HDR_DIFF; + } + else if (len_delta > 0) + { + /* May be it need set 0x0 to rest area in result IPv4 packet, + * but we copy rest data unchanged + */ + memcpy(((char *)icmp_hdr) + sizeof(struct icmphdr), + ((char *)icmp6_hdr) + sizeof(struct icmp6hdr), len_delta); + } + } + + /* Calculate IPv4 Header checksum */ + ip_hdr->check = 0; + ip_hdr->check = ip_fast_csum((unsigned char *)ip_hdr, ip_hdr->ihl); + + /* Calculate ICMPv4 checksum */ + if (ntot_len != 0) + { + icmp_hdr->checksum = 0; + icmp_hdr->checksum = ip_compute_csum((unsigned char *)icmp_hdr, ntohs(ip_hdr->tot_len) + - sizeof(struct iphdr)); + } + } + else + { + PDEBUG("ip6_ip4(): error length ICMP packet, packet dropped.\n"); + return -1; + } + + } + /* PROCESS TCP and UDP (and rest data) */ + + else { + real_len += len_delta; + /* we copy rest data to IPv4 packet without changing */ + memcpy(dst+sizeof(struct iphdr), src + sizeof(struct ipv6hdr) + opts_len, len_delta); + } + } + + if (include_flag) /* if it's included IP packet */ + return opts_len; /* return options headers length */ + else + return real_len; /* result packet len */ +} + +/* + * ip4_fragment(skb, len, hdr_len, dev, eth_h) + * to fragment original IPv4 packet if result IPv6 packet will be > 1280 + */ + +static int ip4_fragment(struct sk_buff *skb, int len, int hdr_len, struct net_device *dev, struct ethhdr *eth_h) +{ + struct sk_buff *skb2 = NULL; /* pointer to new struct sk_buff for transleded packet */ + char buff[FRAG_BUFF_SIZE+hdr_len]; /* buffer to form new fragment packet */ + char *cur_ptr = skb->data+hdr_len; /* pointter to current packet data with len = frag_len */ + struct iphdr *ih4 = (struct iphdr *) skb->data; + struct iphdr *new_ih4 = (struct iphdr *) buff; /* point to new IPv4 hdr */ + struct ethhdr *new_eth_h; /* point to ether hdr, need to set hard header data in fragment */ + int data_len = len - hdr_len; /* origin packet data len */ + int rest_len = data_len; /* rest data to fragment */ + int frag_len = 0; /* current fragment len */ + int last_frag = 0; /* last fragment flag, if = 1, it's last fragment */ + int flag_last_mf = 0; + __u16 new_id = 0; /* to generate identification field */ + __u16 frag_offset = 0; /* fragment offset */ + unsigned int csum; + unsigned short udp_len; + +#ifdef SIIT_DEBUG + printk("siit: it's DF == 0 and result IPv6 packet will be > 1280\n"); + siit_print_dump(skb->data, hdr_len, "siit: (orig) ipv4_hdr dump"); +#endif + + if ((ntohs(ih4->frag_off) & IP_MF) == 0 ) + /* it's a case we'll clear MF flag in our last packet */ + flag_last_mf = 1; + + if (ih4->protocol == IPPROTO_UDP) { + if ( (ntohs(ih4->frag_off) & IP_OFFSET) == 0) { + struct udphdr *udp_hdr = (struct udphdr *)((char *)ih4 + hdr_len); + if (!flag_last_mf) { + if (udp_hdr->check == 0) { + /* it's a first fragment with ZERO checksum and we drop packet */ + printk("siit: First fragment of UDP with zero checksum - packet droped\n"); + printk("siit: addr: %x src port: %d dst port: %d\n", + htonl(ih4->saddr), htons(udp_hdr->source), htons(udp_hdr->dest)); + return -1; + } + } + else if (udp_hdr->check == 0) { + /* Calculate UDP checksum only if it's not fragment */ + udp_len = ntohs(udp_hdr->len); + csum = 0; + csum = csum_partial((unsigned char *)udp_hdr, udp_len, csum); + udp_hdr->check = csum_tcpudp_magic(ih4->saddr, ih4->daddr, udp_len, IPPROTO_UDP, csum); + } + } + } + + frag_offset = ntohs(ih4->frag_off) & IP_OFFSET; + + new_id = ih4->id; + + while(1) { + if (rest_len <= FRAG_BUFF_SIZE) { + /* it's last fragmen */ + frag_len = rest_len; /* rest data */ + last_frag = 1; + } + else + frag_len = FRAG_BUFF_SIZE; + + /* copy IP header to buffer */ + memcpy(buff, skb->data, hdr_len); + /* copy data to buffer with len = frag_len */ + memcpy(buff + hdr_len, cur_ptr, frag_len); + + /* set id field in new IPv4 header*/ + new_ih4->id = new_id; + + /* is it last fragmet */ + if(last_frag && flag_last_mf) + /* clear MF flag */ + new_ih4->frag_off = htons(frag_offset & (~IP_MF)); + else + /* set MF flag */ + new_ih4->frag_off = htons(frag_offset | IP_MF); + + /* change packet total length */ + new_ih4->tot_len = htons(frag_len+hdr_len); + + /* rebuild the header checksum (IP needs it) */ + new_ih4->check = 0; + new_ih4->check = ip_fast_csum((unsigned char *)new_ih4,new_ih4->ihl); + + /* Allocate new sk_buff to compose translated packet */ + skb2 = dev_alloc_skb(frag_len+hdr_len+dev->hard_header_len+IP4_IP6_HDR_DIFF+IP6_FRAGMENT_SIZE); + if (!skb2) { + printk(KERN_DEBUG "%s: alloc_skb failure - packet dropped.\n", dev->name); + dev_kfree_skb(skb2); + return -1; + } + /* allocate skb->data portion for IP header len, fragment data len and ether header len + * and copy to head ether header from origin skb + */ + memcpy(skb_put(skb2, frag_len+hdr_len+dev->hard_header_len+IP4_IP6_HDR_DIFF+IP6_FRAGMENT_SIZE), (char *) eth_h, + dev->hard_header_len); + /* correct ether header data, ether protocol field to ETH_P_IPV6 */ + new_eth_h = (struct ethhdr *)skb2->data; + new_eth_h->h_proto = htons(ETH_P_IPV6); + + /* reset the mac header */ + skb_reset_mac_header(skb2); + + /* pull ether header from new skb->data */ + skb_pull(skb2, dev->hard_header_len); + /* set skb protocol to IPV6 */ + skb2->protocol = htons(ETH_P_IPV6); + + /* call translation function */ + if ( ip4_ip6(buff, frag_len+hdr_len, skb2->data, 0) == -1) { + dev_kfree_skb(skb2); + return -1; + } + + /* + * Set needed fields in new sk_buff + */ + skb2->dev = dev; + skb2->ip_summed = CHECKSUM_UNNECESSARY; + skb2->pkt_type = PACKET_HOST; + + /* Add transmit statistic */ + siit_stats(dev)->tx_packets++; + siit_stats(dev)->tx_bytes += skb2->len; + + /* send packet to upper layer */ + netif_rx(skb2); + + /* exit if it was last fragment */ + if (last_frag) + break; + + /* correct current data pointer */ + cur_ptr += frag_len; + /* rest data len */ + rest_len -= frag_len; + /* current fragment offset */ + frag_offset = (frag_offset*8 + frag_len)/8; + } + + return 0; +} +/* + * Transmit a packet (called by the kernel) + * + * siit_xmit(skb, dev) + * + * where + * skb - pointer to struct sk_buff with incomed packet + * dev - pointer to struct device on which packet revieved + * + * Statistic: + * for all incoming packes: + * stats.rx_bytes+=skb->len + * stats.rx_packets++ + * for packets we can't transle: + * stats.tx_errors++ + * device busy: + * stats.tx_errors++ + * for packets we can't allocate sk_buff: + * stats.tx_dropped++ + * for outgoing packes: + * stats.tx_packets++ + * stats.tx_bytes+=skb2->len !!! But we don't set skb2->len !!! + */ + +static int siit_xmit(struct sk_buff *skb, struct net_device *dev) +{ + struct sk_buff *skb2 = NULL;/* pointer to new struct sk_buff for transleded packet */ + struct ethhdr *eth_h; /* pointer to incoming Ether header */ + int len; /* original packets length */ + int new_packet_len; + int skb_delta = 0; /* delta size for allocate new skb */ + char new_packet_buff[2048]; + + /* Check pointer to sk_buff and device structs */ + if (skb == NULL || dev == NULL) + return -EINVAL; + + /* Add receive statistic */ + siit_stats(dev)->rx_bytes += skb->len; + siit_stats(dev)->rx_packets++; + + dev->trans_start = jiffies; + + /* Upper layer (IP) protocol forms sk_buff for outgoing packet + * and sets IP header + Ether header too. IP layer sets outgoing + * device in sk_buff->dev. + * In function (from linux/net/core/dev.c) ther is a call to + * device transmit function (dev->hard_start_xmit): + * + * dev_queue_xmit(struct sk_buff *skb) + * { + * ... + * device *dev = skb->dev; + * ... + * dev->hard_start_xmit(skb, dev); + * ... + * } + * We save pointer to ether header in eth_h and skb_pull ether header + * from data field of skb_buff + */ + + eth_h = (struct ethhdr *)skb->data; /* point to incoming packet Ether Header */ + +#ifdef SIIT_DEBUG + siit_print_dump(skb->data, ETH_HLEN, "siit: eth_hdr dump"); +#endif + + /* Remove hardware header from origin sk_buff */ + skb_pull(skb,dev->hard_header_len); + + /* + * Process IPv4 paket + */ + if (ntohs(skb->protocol) == ETH_P_IP) { + int hdr_len; /* IPv4 header length */ + int data_len; /* IPv4 data length */ + struct iphdr *ih4; /* pointer to IPv4 header */ + struct icmphdr *icmp_hdr; /* point to current ICMPv4 header struct */ + + ih4 = (struct iphdr *)skb->data; /* point to incoming packet's IPv4 header */ + + /* Check IPv4 Total Length */ + if (skb->len != ntohs(ih4->tot_len)) { + PDEBUG("siit_xmit(): Different skb_len %x and ip4 tot_len %x - packet dropped.\n", + skb->len, ih4->tot_len); + siit_stats(dev)->tx_errors++; + dev_kfree_skb(skb); + return 0; + } + + len = skb->len; /* packet's total len */ + hdr_len = (int)(ih4->ihl * 4); /* packet's header len */ + data_len = len - hdr_len; /* packet's data len */ + + /* If DF == 0 */ + if ( (ntohs(ih4->frag_off) & IP_DF) == 0 ) { + /* If result IPv6 packet will be > 1280 + we need to fragment original IPv4 packet + */ + if ( data_len > FRAG_BUFF_SIZE ) { + /* call function that fragment packet and translate to IPv6 each fragment + * and send to upper layer + */ + if ( ip4_fragment(skb, len, hdr_len, dev, eth_h) == -1) { + siit_stats(dev)->tx_errors++; + } + /* Free incoming skb */ + dev_kfree_skb(skb); + /* Device can accept a new packet */ + + return 0; + + } + } + /* If DF == 1 && MF == 0 && Fragment Offset == 0 + * we don't include fragment header + */ + if ( ntohs(ih4->frag_off) == IP_DF ) + skb_delta = IP4_IP6_HDR_DIFF; /* delta is +20 */ + else + skb_delta = IP4_IP6_HDR_DIFF + IP6_FRAGMENT_SIZE; /* delta is +20 and +8 */ + + /* If it's ICMP, check is it included IP packet in it */ + if ( ih4->protocol == IPPROTO_ICMP) { + icmp_hdr = (struct icmphdr *) (skb->data+hdr_len); /* point to ICMPv4 header */ + if ( icmp_hdr->type != ICMP_ECHO && icmp_hdr->type != ICMP_ECHOREPLY) { + /* + * It's ICMP Error that has included IP packet + * we'll add only +20 because we don't include Fragment Header + * into translated included IP packet + */ + skb_delta += IP4_IP6_HDR_DIFF; + } + } + + /* Allocate new sk_buff to compose translated packet */ + skb2 = dev_alloc_skb(len+dev->hard_header_len+skb_delta); + if (!skb2) { + printk(KERN_DEBUG "%s: alloc_skb failure - packet dropped.\n", dev->name); + dev_kfree_skb(skb); + siit_stats(dev)->rx_dropped++; + + return 0; + } + /* allocate skb->data portion = IPv4 packet len + ether header len + * + skb_delta (max = two times (diffirence between IPv4 header and + * IPv6 header + Frag Header), second for included packet, + * and copy to head of skb->data ether header from origin skb + */ + memcpy(skb_put(skb2, len+dev->hard_header_len+skb_delta), (char *)eth_h, dev->hard_header_len); + /* correct ether header data, ether protocol field to ETH_P_IPV6 */ + eth_h = (struct ethhdr *)skb2->data; + eth_h->h_proto = htons(ETH_P_IPV6); + skb_reset_mac_header(skb2); + /* remove ether header from new skb->data, + * NOTE! data will rest, pointer to data and data len will change + */ + skb_pull(skb2,dev->hard_header_len); + /* set skb protocol to IPV6 */ + skb2->protocol = htons(ETH_P_IPV6); + + /* call translation function */ + if (ip4_ip6(skb->data, len, skb2->data, 0) == -1 ) { + dev_kfree_skb(skb); + dev_kfree_skb(skb2); + siit_stats(dev)->rx_errors++; + + return 0; + } + } + /* + * IPv6 paket + */ + else if (ntohs(skb->protocol) == ETH_P_IPV6) { + +#ifdef SIIT_DEBUG + siit_print_dump(skb->data, sizeof(struct ipv6hdr), "siit: (in) ip6_hdr dump"); +#endif + /* packet len = skb->data len*/ + len = skb->len; + + /* call translation function */ + if ((new_packet_len = ip6_ip4(skb->data, len, new_packet_buff, 0)) == -1 ) + { + PDEBUG("siit_xmit(): error translation ipv6->ipv4, packet dropped.\n"); + siit_stats(dev)->rx_dropped++; + goto end; + } + + /* Allocate new sk_buff to compose translated packet */ + skb2 = dev_alloc_skb(new_packet_len + dev->hard_header_len); + if (!skb2) { + printk(KERN_DEBUG "%s: alloc_skb failure, packet dropped.\n", dev->name); + siit_stats(dev)->rx_dropped++; + goto end; + } + memcpy(skb_put(skb2, new_packet_len + dev->hard_header_len), (char *)eth_h, dev->hard_header_len); + eth_h = (struct ethhdr *)skb2->data; + eth_h->h_proto = htons(ETH_P_IP); + skb_reset_mac_header(skb2); + skb_pull(skb2, dev->hard_header_len); + memcpy(skb2->data, new_packet_buff, new_packet_len); + skb2->protocol = htons(ETH_P_IP); + } + else { + PDEBUG("siit_xmit(): unsupported protocol family %x, packet dropped.\n", skb->protocol); + goto end; + } + + /* + * Set needed fields in new sk_buff + */ + skb2->pkt_type = PACKET_HOST; + skb2->dev = dev; + skb2->ip_summed = CHECKSUM_UNNECESSARY; + + /* Add transmit statistic */ + siit_stats(dev)->tx_packets++; + siit_stats(dev)->tx_bytes += skb2->len; + + /* Send packet to upper layer protocol */ + netif_rx(skb2); + +end: + dev_kfree_skb(skb); + + return 0; +} + +static bool header_ops_init = false; +static struct header_ops siit_header_ops ____cacheline_aligned; + +static const struct net_device_ops siit_netdev_ops = { + .ndo_open = siit_open, + .ndo_stop = siit_release, + .ndo_start_xmit = siit_xmit, +}; + +/* + * The init function initialize of the SIIT device.. + * It is invoked by register_netdev() + */ + +static void +siit_init(struct net_device *dev) +{ + ether_setup(dev); /* assign some of the fields */ + random_ether_addr(dev->dev_addr); + + /* + * Assign device function. + */ + dev->netdev_ops = &siit_netdev_ops; + dev->flags |= IFF_NOARP; /* ARP not used */ + dev->tx_queue_len = 10; + + if (!header_ops_init) { + memcpy(&siit_header_ops, dev->header_ops, sizeof(struct header_ops)); + siit_header_ops.cache = NULL; + } + dev->header_ops = &siit_header_ops; +} + +/* + * Finally, the module stuff + */ +static struct net_device *siit_dev = NULL; + +int init_module(void) +{ + int res = -ENOMEM; + int priv_size; + + priv_size = sizeof(struct header_ops); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,17,0) + siit_dev = alloc_netdev(priv_size, "siit%d", NET_NAME_UNKNOWN, siit_init); +#else + siit_dev = alloc_netdev(priv_size, "siit%d", siit_init); +#endif + if (!siit_dev) + goto err_alloc; + + res = register_netdev(siit_dev); + if (res) + goto err_register; + + return 0; + +err_register: + free_netdev(siit_dev); +err_alloc: + printk(KERN_ERR "Error creating siit device: %d\n", res); + return res; +} + +void cleanup_module(void) +{ + unregister_netdev(siit_dev); + free_netdev(siit_dev); +} + +MODULE_LICENSE("GPL"); diff --git a/net/siit/src/siit.h b/net/siit/src/siit.h new file mode 100644 index 000000000..47cf77645 --- /dev/null +++ b/net/siit/src/siit.h @@ -0,0 +1,61 @@ +/* + * siit.h -- definitions for the SIIT module + * + * + */ + +/* + * Constants + */ + +/* SIIT_ETH control the name of SIIT interface: + * 0 - interface name is siit0, + * 1 - interface name is ethX. + */ +#define SIIT_ETH 0 + +#define BUFF_SIZE 4096 +#define FRAG_BUFF_SIZE 1232 /* IPv6 max fragment size without IPv6 header + * to fragmanet IPv4 if result IPv6 packet will be > 1280 + */ + +#define TRANSLATED_PREFIX 0x0000ffff /* third byte in IPv4-translated addr prefix */ +#define MAPPED_PREFIX 0x0000ffff /* third byte in IPv4-mapped addr prefix */ + +#define IP4_IP6_HDR_DIFF 20 /* diffirence between IPv4 and IPv6 headers */ +#define IP6_FRAGMENT_SIZE 8 /* size of Fragment Header */ + +/* IPv6 header fields masks */ +#define IP6F_OFF_MASK 0xfff8 /* mask out offset from frag_off */ +#define IP6F_RESERVED_MASK 0x0006 /* reserved bits in frag_off */ +#define IP6F_MORE_FRAG 0x0001 /* more-fragments flag */ + + + +/* + * Macros to help debugging + */ + +#undef PDEBUG /* undef it, just in case */ +#ifdef SIIT_DEBUG +# ifdef __KERNEL__ + /* This one if debugging is on, and kernel space */ +# define PDEBUG(fmt, args...) printk(KERN_DEBUG "siit: " fmt, ## args) +# else + /* This one for user space */ +# define PDEBUG(fmt, args...) fprintf(stderr, fmt, ## args) +# endif +#else +# define PDEBUG(fmt, args...) /* not debugging: nothing */ +#endif + +#undef PDEBUGG +#define PDEBUGG(fmt, args...) + + + + + + + + diff --git a/net/snort/Config.in b/net/snort/Config.in new file mode 100644 index 000000000..433557c30 --- /dev/null +++ b/net/snort/Config.in @@ -0,0 +1,25 @@ +menu "Configuration" + depends on PACKAGE_snort + +config SNORT_MYSQL + bool "Enable MySQL support" + default n + help + This option enables support for logging to a MySQL database. + Disabled by default. + +config SNORT_PGSQL + bool "Enable PostgreSQL support" + default n + help + This option enables support for logging to a PostgreSQL database. + Disabled by default. + +config SNORT_LZMA + bool "Enable LZMA support" + default n + help + This option enables LZMA decompression. + Disabled by default. + +endmenu diff --git a/net/snort/Makefile b/net/snort/Makefile index 2c948665c..9886a5d92 100644 --- a/net/snort/Makefile +++ b/net/snort/Makefile @@ -8,30 +8,35 @@ include $(TOPDIR)/rules.mk PKG_NAME:=snort -PKG_VERSION:=2.9.7.0 -PKG_RELEASE:=1 +PKG_VERSION:=2.9.7.2 +PKG_RELEASE:=3 + +PKG_LICENSE:=GPL-2.0 +PKG_MAINTAINER:=Luka Perkov PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://www.snort.org/downloads/snort/ -PKG_MD5SUM:=c2a45bc56441ee9456478f219dd8d1e2 +PKG_SOURCE_URL:=https://www.snort.org/downloads/snort/ \ + @SF/$(PKG_NAME) +PKG_MD5SUM:=b01e9964827394c39194a0147bc15705 PKG_BUILD_DEPENDS:=librpc -PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/$(PKG_NAME)-$(PKG_VERSION) PKG_FIXUP:=autoreconf PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk -define Package/snort/Default +define Package/snort SUBMENU:=Firewall SECTION:=net CATEGORY:=Network - DEPENDS:=+libdaq +libdnet +libopenssl +libpcap +libpcre +libpthread +libuuid +zlib + DEPENDS:=+libdaq +libdnet +libopenssl +libpcap +libpcre +libpthread +libuuid +zlib +SNORT_MYSQL:libmysqlclient +SNORT_PGSQL:libpq +SNORT_PGSQL:libuuid +SNORT_LZMA:liblzma TITLE:=Lightweight Network Intrusion Detection System URL:=http://www.snort.org/ + MENU:=1 endef -define Package/snort/Default/description +define Package/snort/description Snort is an open source network intrusion detection and prevention system. It is capable of performing real-time traffic analysis, alerting, blocking and packet logging on IP networks. It utilizes a combination of protocol @@ -39,37 +44,8 @@ define Package/snort/Default/description attacks. endef -define Package/snort - $(call Package/snort/Default) - VARIANT:=basic -endef - -define Package/snort/description - $(call Package/snort/Default/description) -endef - -define Package/snort-mysql - $(call Package/snort/Default) - DEPENDS+= +libmysqlclient - TITLE+= (MySQL) - VARIANT:=mysql -endef - -define Package/snort-mysql/description - $(call Package/snort/Default/description) - This package contains snort with support for logging to a MySQL database. -endef - -define Package/snort-pgsql - $(call Package/snort/Default) - DEPENDS+= +libpq +libuuid - TITLE+= (PostgreSQL) - VARIANT:=pgsql -endef - -define Package/snort-pgsql/description - $(call Package/snort/Default/description) - This package contains snort with support for logging to a PostgreSQL database. +define Package/snort/config + source "$(SOURCE)/Config.in" endef CONFIGURE_ARGS += \ @@ -85,6 +61,21 @@ CONFIGURE_ARGS += \ --with-daq-libraries="$(STAGING_DIR)/usr/lib" \ --disable-static-daq +ifeq ($(CONFIG_SNORT_MYSQL),) +CONFIGURE_ARGS += \ + --without-mysql +endif + +ifeq ($(CONFIG_PGSQL),) +CONFIGURE_ARGS += \ + --without-postgresql +endif + +ifeq ($(CONFIG_SNORT_LZMA),) +CONFIGURE_ARGS += \ + --disable-lzma +endif + CONFIGURE_VARS += \ CPPFLAGS="$$$$CPPFLAGS -I$(STAGING_DIR)/usr/include/mysql" \ LDFLAGS="$$$$LDFLAGS -L$(STAGING_DIR)/usr/lib/mysql" \ @@ -93,24 +84,6 @@ CONFIGURE_VARS += \ MAKE_FLAGS += \ extra_incl="" -ifeq ($(BUILD_VARIANT),basic) - CONFIGURE_ARGS += \ - --without-mysql \ - --without-postgresql -endif -ifeq ($(BUILD_VARIANT),mysql) - CONFIGURE_VARS += \ - mysql_has_reconnect=yes - CONFIGURE_ARGS += \ - --with-mysql="$(STAGING_DIR)/usr" \ - --without-postgresql -endif -ifeq ($(BUILD_VARIANT),pgsql) - CONFIGURE_ARGS += \ - --without-mysql \ - --with-postgresql="$(STAGING_DIR)/usr" -endif - define Build/InstallDev $(INSTALL_DIR) $(STAGING_DIR)/usr/include/snort/dynamic_preproc $(CP) \ @@ -135,12 +108,6 @@ define Package/snort/conffiles /etc/snort/snort.conf endef -Package/snort-mysql/conffiles = $(Package/snort/conffiles) -Package/snort-mysql/install = $(Package/snort/install) - -Package/snort-pgsql/conffiles = $(Package/snort/conffiles) -Package/snort-pgsql/install = $(Package/snort/install) - define Package/snort/install $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) \ @@ -198,5 +165,4 @@ define Package/snort/install endef $(eval $(call BuildPackage,snort)) -$(eval $(call BuildPackage,snort-mysql)) -$(eval $(call BuildPackage,snort-pgsql)) + diff --git a/net/snort/patches/100-autoconf-fixes.patch b/net/snort/patches/100-autoconf-fixes.patch new file mode 100644 index 000000000..414c0c1cc --- /dev/null +++ b/net/snort/patches/100-autoconf-fixes.patch @@ -0,0 +1,17 @@ +--- a/configure.in ++++ b/configure.in +@@ -11,14 +11,6 @@ AM_INIT_AUTOMAKE(snort,2.9.7.2) + NO_OPTIMIZE="no" + ADD_WERROR="no" + +-# Test for -Werror and sed it out for now since some of the auto tests, +-# for example AC_CHECK_LIB, will fail because of +-# warning: conflicting types for built-in function +-if eval "echo $CFLAGS | grep -e -Werror"; then +- CFLAGS=`echo $CFLAGS | sed -e "s/-Werror//g"` +- ADD_WERROR="yes" +-fi +- + # Disable annoying practice of recursively re-running the autotools + AM_MAINTAINER_MODE + AC_PROG_CC_STDC diff --git a/net/socat/Makefile b/net/socat/Makefile index bb3fc7d64..b89ffcad2 100644 --- a/net/socat/Makefile +++ b/net/socat/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 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:=socat -PKG_VERSION:=1.7.2.4 +PKG_VERSION:=1.7.3.0 PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.dest-unreach.org/socat/download -PKG_MD5SUM:=69b8155dd442a6f24e28ef5407d868eb +PKG_MD5SUM:=b607edb65bc6c57f4a43f06247504274 PKG_MAINTAINER:= Ted Hess @@ -27,7 +27,7 @@ include $(INCLUDE_DIR)/package.mk define Package/socat SECTION:=net CATEGORY:=Network - DEPENDS:=+libpthread +SOCAT_SSL:libopenssl + DEPENDS:=+libpthread +librt +SOCAT_SSL:libopenssl TITLE:=A multipurpose relay (SOcket CAT) URL:=http://www.dest-unreach.org/socat/ endef diff --git a/net/socat/patches/010-fix_cross_compiling_error.patch b/net/socat/patches/010-fix_cross_compiling_error.patch deleted file mode 100644 index 059938b56..000000000 --- a/net/socat/patches/010-fix_cross_compiling_error.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/configure.in -+++ b/configure.in -@@ -41,7 +41,7 @@ AC_CHECK_PROG(AR, ar, ar, gar) - # fail - AC_LANG_COMPILER_REQUIRE() - --if test "$CC" = "gcc"; then -+if test "$GCC" = yes; then - CFLAGS="$CFLAGS -D_GNU_SOURCE -Wall -Wno-parentheses" - ERRONWARN="-Werror -O0" - elif test "$CC" = "clang"; then ---- a/configure -+++ b/configure -@@ -3348,7 +3348,7 @@ fi - - - --if test "$CC" = "gcc"; then -+if test "$GCC" = yes; then - CFLAGS="$CFLAGS -D_GNU_SOURCE -Wall -Wno-parentheses" - ERRONWARN="-Werror -O0" - elif test "$CC" = "clang"; then diff --git a/net/socat/patches/100-musl-compat.patch b/net/socat/patches/100-musl-compat.patch new file mode 100644 index 000000000..ae5c8d0d7 --- /dev/null +++ b/net/socat/patches/100-musl-compat.patch @@ -0,0 +1,23 @@ +--- a/sysincludes.h ++++ b/sysincludes.h +@@ -79,6 +79,9 @@ + #endif + #if HAVE_NETDB_H && (_WITH_IP4 || _WITH_IP6) + #include /* struct hostent, gethostbyname() */ ++#if !(__UCLIBC__ || __GLIBC__) ++#define NETDB_INTERNAL -1 ++#endif + #endif + #if HAVE_SYS_UN_H && WITH_UNIX + #include /* struct sockaddr_un, unix domain sockets */ +@@ -139,8 +142,10 @@ + #include + #endif + #if HAVE_NETINET_IF_ETHER_H ++#if defined(__UCLIBC__) || defined(__GLIBC__) + #include + #endif ++#endif + #if HAVE_LINUX_IF_TUN_H + #include + #endif diff --git a/net/spawn-fcgi/Makefile b/net/spawn-fcgi/Makefile new file mode 100644 index 000000000..54c9ab764 --- /dev/null +++ b/net/spawn-fcgi/Makefile @@ -0,0 +1,42 @@ +# +# Copyright (C) 2006-2015 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:=spawn-fcgi +PKG_VERSION:=1.6.4 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=http://download.lighttpd.net/spawn-fcgi/releases-1.6.x/ +PKG_MD5SUM:=a67c098a50cd625fd12adf61b5dd4c32 + +PKG_LICENSE:=BSD-3c +PKG_LICENSE_FILES:=COPYING + +PKG_MAINTAINER:=Daniel Golle + +include $(INCLUDE_DIR)/package.mk + +define Package/spawn-fcgi + SUBMENU:=Web Servers/Proxies + SECTION:=net + CATEGORY:=Network + TITLE:=Tool to spawn fastcgi applications + URL:=http://redmine.lighttpd.net/projects/spawn-fcgi +endef + +define Package/spawn-fcgi/description + spawn-fcgi is used to spawn fastcgi applications +endef + +define Package/spawn-fcgi/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/spawn-fcgi $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,spawn-fcgi)) diff --git a/net/sqm-scripts/Makefile b/net/sqm-scripts/Makefile index 298220dfa..68a599063 100644 --- a/net/sqm-scripts/Makefile +++ b/net/sqm-scripts/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sqm-scripts -PKG_VERSION:=7 -PKG_RELEASE:=3 +PKG_VERSION:=8 +PKG_RELEASE:=4 PKG_LICENSE:=GPLv2 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) @@ -20,7 +20,7 @@ define Package/sqm-scripts SECTION:=net CATEGORY:=Base system DEPENDS:=+tc +kmod-sched +kmod-ifb iptables +ip \ - +iptables-mod-filter +iptables-mod-ipopt +iptables-mod-conntrack-extra + +iptables-mod-ipopt +iptables-mod-conntrack-extra TITLE:=SQM Scripts (QoS) PKGARCH:=all MAINTAINER:=Toke Høiland-Jørgensen @@ -46,6 +46,8 @@ endef define Package/sqm-scripts/install $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/etc/init.d/sqm $(1)/etc/init.d/sqm + $(INSTALL_DIR) $(1)/etc/hotplug.d/iface + $(INSTALL_BIN) ./files/etc/hotplug.d/iface/11-sqm $(1)/etc/hotplug.d/iface/11-sqm $(INSTALL_DIR) $(1)/etc/config $(INSTALL_DATA) ./files/etc/config/sqm $(1)/etc/config/sqm $(INSTALL_DIR) $(1)/usr/lib/sqm diff --git a/net/sqm-scripts/files/etc/hotplug.d/iface/11-sqm b/net/sqm-scripts/files/etc/hotplug.d/iface/11-sqm new file mode 100755 index 000000000..38ceb25de --- /dev/null +++ b/net/sqm-scripts/files/etc/hotplug.d/iface/11-sqm @@ -0,0 +1,3 @@ +#!/bin/sh + +[ "$ACTION" = ifup ] && /etc/init.d/sqm enabled && /usr/lib/sqm/run.sh start ${DEVICE} diff --git a/net/sqm-scripts/files/etc/init.d/sqm b/net/sqm-scripts/files/etc/init.d/sqm index 70307a6e1..2a40afb5a 100755 --- a/net/sqm-scripts/files/etc/init.d/sqm +++ b/net/sqm-scripts/files/etc/init.d/sqm @@ -4,7 +4,7 @@ START=50 reload() { -/usr/lib/sqm/run.sh +/usr/lib/sqm/run.sh start } restart() diff --git a/net/sqm-scripts/files/usr/lib/sqm/functions.sh b/net/sqm-scripts/files/usr/lib/sqm/functions.sh index 3411b8f31..a0b2c6ffd 100644 --- a/net/sqm-scripts/files/usr/lib/sqm/functions.sh +++ b/net/sqm-scripts/files/usr/lib/sqm/functions.sh @@ -253,8 +253,8 @@ get_target() { # either e.g. 100ms or auto CUR_TARGET_VALUE=$( echo ${CUR_TARGET} | grep -o -e \^'[[:digit:]]\+' ) CUR_TARGET_UNIT=$( echo ${CUR_TARGET} | grep -o -e '[[:alpha:]]\+'\$ ) -# [ ! -z "$CUR_TARGET" ] && sqm_logger "CUR_TARGET_VALUE: $CUR_TARGET_VALUE" -# [ ! -z "$CUR_TARGET" ] && sqm_logger "CUR_TARGET_UNIT: $CUR_TARGET_UNIT" + #[ ! -z "$CUR_TARGET" ] && sqm_logger "CUR_TARGET_VALUE: $CUR_TARGET_VALUE" + #[ ! -z "$CUR_TARGET" ] && sqm_logger "CUR_TARGET_UNIT: $CUR_TARGET_UNIT" AUTO_TARGET= UNIT_VALID= @@ -271,14 +271,42 @@ get_target() { ;; esac fi - case ${CUR_TARGET_UNIT} in - auto|Auto|AUTO) + # empty field in GUI or undefined GUI variable now defaults to auto + if [ -z "${CUR_TARGET_VALUE}" -a -z "${CUR_TARGET_UNIT}" ]; + then if [ ! -z "${CUR_LINK_KBPS}" ]; then TMP_TARGET_US=$( adapt_target_to_slow_link $CUR_LINK_KBPS ) TMP_INTERVAL_STRING=$( adapt_interval_to_slow_link $TMP_TARGET_US ) CUR_TARGET_STRING="target ${TMP_TARGET_US}us ${TMP_INTERVAL_STRING}" AUTO_TARGET="1" + sqm_logger "get_target defaulting to auto." + else + sqm_logger "required link bandwidth in kbps not passed to get_target()." + fi + fi + # but still allow explicit use of the keyword auto for backward compatibility + case ${CUR_TARGET_UNIT} in + auto|Auto|AUTO) + if [ ! -z "${CUR_LINK_KBPS}" ]; + then + TMP_TARGET_US=$( adapt_target_to_slow_link $CUR_LINK_KBPS ) + TMP_INTERVAL_STRING=$( adapt_interval_to_slow_link $TMP_TARGET_US ) + CUR_TARGET_STRING="target ${TMP_TARGET_US}us ${TMP_INTERVAL_STRING}" + AUTO_TARGET="1" + else + sqm_logger "required link bandwidth in kbps not passed to get_target()." + fi + ;; + esac + + case ${CUR_TARGET_UNIT} in + default|Default|DEFAULT) + if [ ! -z "${CUR_LINK_KBPS}" ]; + then + CUR_TARGET_STRING="" # return nothing so the default target is not over-ridden... + AUTO_TARGET="1" + #sqm_logger "get_target using qdisc default, no explicit target string passed." else sqm_logger "required link bandwidth in kbps not passed to get_target()." fi @@ -288,7 +316,7 @@ get_target() { then if [ -z "${CUR_TARGET_VALUE}" -o -z "${UNIT_VALID}" ]; then - [ -z "$AUTO_TARGET" ] && sqm_logger "${CUR_TARGET} is not a well formed tc target specifier; e.g.: 5ms (or s, us), or the string auto." + [ -z "$AUTO_TARGET" ] && sqm_logger "${CUR_TARGET} is not a well formed tc target specifier; e.g.: 5ms (or s, us), or one of the strings auto or default." fi fi ;; diff --git a/net/sqm-scripts/files/usr/lib/sqm/run.sh b/net/sqm-scripts/files/usr/lib/sqm/run.sh index d7b86a220..7aa20ddba 100755 --- a/net/sqm-scripts/files/usr/lib/sqm/run.sh +++ b/net/sqm-scripts/files/usr/lib/sqm/run.sh @@ -9,16 +9,47 @@ . /lib/functions.sh -STOP=$1 +STOP= ACTIVE_STATE_PREFIX="SQM_active_on_" ACTIVE_STATE_FILE_DIR="/var/run/SQM" mkdir -p ${ACTIVE_STATE_FILE_DIR} + +START_ON_IF=$2 # only process this interface +# TODO if $2 is empty select all interfaces with running sqm instance +if [ -z ${START_ON_IF} ] ; +then + # find all interfaces with active sqm instance + logger -t SQM -s "Trying to start/stop SQM on all interfaces." + PROTO_STATE_FILE_LIST=$( ls ${ACTIVE_STATE_FILE_DIR}/${ACTIVE_STATE_PREFIX}* 2> /dev/null ) +else + # only try to restart the just hotplugged interface, so reduce the list of interfaces to stop to the specified one + logger -t SQM -s "Trying to start/stop SQM on interface ${START_ON_IF}" + PROTO_STATE_FILE_LIST=${ACTIVE_STATE_FILE_DIR}/${ACTIVE_STATE_PREFIX}${START_ON_IF} +fi + + + + +case ${1} in + start) + # just run through, same as passing no argument + ;; + stop) + logger -t SQM -s "run.sh stop" + STOP=$1 + ;; +esac + + + + + + # the current uci config file does not necessarily contain sections for all interfaces with active # SQM instances, so use the ACTIVE_STATE_FILES to detect the interfaces on which to stop SQM. # Currently the .qos scripts start with stopping any existing traffic shaping so this should not # effectively change anything... -PROTO_STATE_FILE_LIST=$( ls ${ACTIVE_STATE_FILE_DIR}/${ACTIVE_STATE_PREFIX}* 2> /dev/null ) for STATE_FILE in ${PROTO_STATE_FILE_LIST} ; do if [ -f ${STATE_FILE} ] ; then @@ -35,6 +66,11 @@ config_load sqm run_simple_qos() { local section="$1" export IFACE=$(config_get "$section" interface) + + # If called explicitly for one interface only , so ignore anything else + [ -n "${START_ON_IF}" -a "$START_ON_IF" != "$IFACE" ] && return + #logger -t SQM -s "marching on..." + ACTIVE_STATE_FILE_FQN="${ACTIVE_STATE_FILE_DIR}/${ACTIVE_STATE_PREFIX}${IFACE}" # this marks interfaces as active with SQM [ -f "${ACTIVE_STATE_FILE_FQN}" ] && logger -t SQM -s "Uh, oh, ${ACTIVE_STATE_FILE_FQN} should already be stopped." # Not supposed to happen @@ -82,6 +118,14 @@ run_simple_qos() { logger -t SQM -s "${0} SQM qdiscs on ${IFACE} removed" return 0 fi + # in case of spurious hotplug events, try double check whether the interface is really up + if [ ! -d /sys/class/net/${IFACE} ] ; + then + echo "${IFACE} does currently not exist, not even trying to start SQM on nothing." > /dev/kmsg + logger -t SQM -s "${IFACE} does currently not exist, not even trying to start SQM on nothing." + return 0 + fi + logger -t SQM -s "${0} Queue Setup Script: ${SCRIPT}" [ -x "$SCRIPT" ] && { $SCRIPT ; touch ${ACTIVE_STATE_FILE_FQN}; } } diff --git a/net/sqm-scripts/files/usr/lib/sqm/simple.qos b/net/sqm-scripts/files/usr/lib/sqm/simple.qos index 5df6aa7e2..6e5af4a94 100755 --- a/net/sqm-scripts/files/usr/lib/sqm/simple.qos +++ b/net/sqm-scripts/files/usr/lib/sqm/simple.qos @@ -37,6 +37,9 @@ ipt -t mangle -A QOS_MARK_${IFACE} -m tos --tos Minimize-Delay -j MARK --set-ma # Turn it on. Preserve classification if already performed +#sm: is it correct to do this in $IFACE? Should ingress not be on $DEV? since HTB acts on $DEV? +# SQUASH also does not work on $DEV (that is the IFB will still see the incoming ToS bits whether we squash or not) +# SQUASH is still useful to protect internal machines... if [ "$SQUASH_DSCP" = "1" ] then sqm_logger "Squashing differentiated services code points (DSCP) from ingress." diff --git a/net/squid/Makefile b/net/squid/Makefile index f06df6dcc..d5873c7b2 100644 --- a/net/squid/Makefile +++ b/net/squid/Makefile @@ -8,15 +8,15 @@ include $(TOPDIR)/rules.mk PKG_NAME:=squid -PKG_VERSION:=3.4.11 -PKG_RELEASE:=2 +PKG_VERSION:=3.5.2 +PKG_RELEASE:=4 PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=Luka Perkov PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=http://www.squid-cache.org/Versions/v3/3.4/ -PKG_MD5SUM:=e79ddb108d24823da8c1dbc0fc4a31fb +PKG_SOURCE_URL:=http://www.squid-cache.org/Versions/v3/3.5/ +PKG_MD5SUM:=0330ec9f69e333c2a81fa4502ba96a22 PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 @@ -33,7 +33,7 @@ endef define Package/squid $(call Package/squid/Default) MENU:=1 - DEPENDS:=+libopenssl +libpthread +librt +libltdl +libstdcpp + DEPENDS:=+libopenssl +libpthread +librt +libltdl +libstdcpp +libgnutls TITLE:=full-featured Web proxy cache endef @@ -89,16 +89,15 @@ CONFIGURE_ARGS += \ --disable-arch-native \ --with-krb5-config=no \ --without-libcap \ - --without-netfilter-conntrack \ + --without-netfilter-conntrack CONFIGURE_VARS += \ ac_cv_header_linux_netfilter_ipv4_h=yes \ - ac_cv_epoll_works=yes \ + ac_cv_epoll_works=yes define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR)/lib \ - all - $(MAKE) -C $(PKG_BUILD_DIR) \ + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR)/lib all + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \ DESTDIR="$(PKG_INSTALL_DIR)" \ install endef diff --git a/net/squid/files/squid.init b/net/squid/files/squid.init index 8b3094840..35d86c877 100644 --- a/net/squid/files/squid.init +++ b/net/squid/files/squid.init @@ -25,7 +25,9 @@ start_service() { return 1 } - mkdir -p $(dirname $CONFIGFILE) + config_dir=$(dirname $CONFIGFILE) + [ -d $config_dir ] || mkdir -p $config_dir && chown nobody:nogroup $config_dir + [ -d $coredump_dir ] || mkdir -p $coredump_dir && chown nobody:nogroup $coredump_dir cat $config_file > $CONFIGFILE echo http_port $http_port >> $CONFIGFILE diff --git a/net/squid/patches/001-cross_compile.patch b/net/squid/patches/001-cross_compile.patch index 8b1d77257..a6cc6e23c 100644 --- a/net/squid/patches/001-cross_compile.patch +++ b/net/squid/patches/001-cross_compile.patch @@ -1,17 +1,17 @@ --- a/src/Makefile.in +++ b/src/Makefile.in -@@ -7742,7 +7742,7 @@ cache_cf.o: cf_parser.cci +@@ -7759,7 +7759,7 @@ cache_cf.o: cf_parser.cci # cf_gen builds the configuration files. cf_gen$(EXEEXT): $(cf_gen_SOURCES) $(cf_gen_DEPENDENCIES) cf_gen_defines.cci -- $(HOSTCXX) -o $@ $(srcdir)/cf_gen.cc -I$(srcdir) -I$(top_builddir)/include/ -I$(top_builddir)/src +- $(BUILDCXX) $(BUILDCXXFLAGS) -o $@ $(srcdir)/cf_gen.cc -I$(srcdir) -I$(top_builddir)/include/ -I$(top_builddir)/src + g++ -o $@ $(srcdir)/cf_gen.cc -I$(srcdir) -I$(top_builddir)/include/ -I$(top_builddir)/src # squid.conf.default is built by cf_gen when making cf_parser.cci squid.conf.default squid.conf.documented: cf_parser.cci --- a/configure +++ b/configure -@@ -22226,7 +22226,7 @@ $as_echo_n "checking whether the SSL_get +@@ -22935,7 +22935,7 @@ $as_echo_n "checking whether the SSL_get if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} @@ -20,7 +20,7 @@ See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext -@@ -22274,7 +22274,7 @@ $as_echo_n "checking whether the workaro +@@ -22983,7 +22983,7 @@ $as_echo_n "checking whether the workaro if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} @@ -29,7 +29,7 @@ See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext -@@ -24924,7 +24924,7 @@ else +@@ -28201,7 +28201,7 @@ else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} @@ -38,7 +38,7 @@ See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext -@@ -24949,7 +24949,7 @@ else +@@ -28226,7 +28226,7 @@ else if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} diff --git a/net/squid/patches/100-mime.patch b/net/squid/patches/100-mime.patch index b5f3aaf8f..1138a413d 100644 --- a/net/squid/patches/100-mime.patch +++ b/net/squid/patches/100-mime.patch @@ -1,29 +1,30 @@ --- a/src/mime.conf.default +++ b/src/mime.conf.default -@@ -1,19 +1,3 @@ --# This file associates filename extensions (for servers or services --# that don't automatically include them - like ftp) with a mime type --# and a graphical icon. --# --# --# This file has the format : --# regex content-type icon content-encoding transfer-mode --#----------------------------------------------------------------------------------- +@@ -1,20 +1,3 @@ +-## Copyright (C) 1996-2015 The Squid Software Foundation and contributors +-## +-## Squid software is distributed under GPLv2+ license and includes +-## contributions from numerous individuals and organizations. +-## Please see the COPYING and CONTRIBUTORS files for details. +-## -# +-# This file associates URL patterns for servers or services +-# that don't automatically include Content-Type (like ftp) with a mime type +-# and a graphical icon. -# -# Content-Encodings are taken from section 3.1 of RFC2068 (HTTP/1.1) -# --# +-# This file has the format : -# -# regexp content-type icon encoding mode actions -#-------------------------------------------------------------------------------------------------------- \.gif$ image/gif silk/image.png - image +download \.mime$ www/mime silk/page_white_text.png - ascii +download ^internal-dirup$ - silk/arrow_up.png - - -@@ -190,6 +174,4 @@ README text/plain silk/information.pn +@@ -191,6 +174,4 @@ README text/plain silk/information.pn \.xml$ text/xml silk/page_world.png - ascii +download \.xsl$ text/xml silk/layout.png - ascii +download \.xyz$ chemical/x-xyz silk/chart_line.png - image +download -- +-# -# the default . text/plain silk/bullet_red.png - image +download +view diff --git a/net/squid/patches/200-musl-compat.patch b/net/squid/patches/200-musl-compat.patch new file mode 100644 index 000000000..7cbd9da9f --- /dev/null +++ b/net/squid/patches/200-musl-compat.patch @@ -0,0 +1,15 @@ +--- a/lib/rfcnb/rfcnb-io.c ++++ b/lib/rfcnb/rfcnb-io.c +@@ -36,11 +36,11 @@ + #include "rfcnb/rfcnb-util.h" + #include "rfcnb/std-includes.h" + ++#include + #if HAVE_STRING_H + #include + #endif + #include +-#include + + int RFCNB_Timeout = 0; /* Timeout in seconds ... */ + diff --git a/net/sshtunnel/files/sshtunnel.init b/net/sshtunnel/files/sshtunnel.init index 4ca491f67..482ec6778 100644 --- a/net/sshtunnel/files/sshtunnel.init +++ b/net/sshtunnel/files/sshtunnel.init @@ -66,7 +66,6 @@ load_tunnelD() { config_get localaddress $1 localaddress "*" config_get localport $1 localport - [ "$remoteport" -gt 0 ] || append_string "error" "[tunnelD: $1]remoteport must be a positive integer" "; " [ "$localport" -gt 0 ] || append_string "error" "[tunnelD: $1]localport must be a positive integer" "; " [ -n "$error" ] && return 1 diff --git a/net/sslh/Makefile b/net/sslh/Makefile index 9b13e7db5..e7f1c0e6b 100644 --- a/net/sslh/Makefile +++ b/net/sslh/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sslh -PKG_VERSION:=v1.16 -PKG_RELEASE:=2 +PKG_VERSION:=v1.17 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://rutschle.net/tech/ -PKG_MD5SUM:=c6e7d1cb0adb15f6efe480e36d98c560 +PKG_MD5SUM:=1fc3ada4bafaca5a9786cc1431f48ed4 PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING diff --git a/net/sslh/patches/001-no_sslh_select.patch b/net/sslh/patches/001-no_sslh_select.patch index 2ff68116f..2b461f672 100644 --- a/net/sslh/patches/001-no_sslh_select.patch +++ b/net/sslh/patches/001-no_sslh_select.patch @@ -18,7 +18,7 @@ echosrv: $(OBJS) echosrv.o $(CC) $(CFLAGS) $(LDFLAGS) -o echosrv echosrv.o probe.o common.o $(LIBS) -@@ -86,7 +82,7 @@ distclean: clean +@@ -85,7 +81,7 @@ distclean: clean rm -f tags cscope.* clean: diff --git a/net/sstp-client/Makefile b/net/sstp-client/Makefile index 185e6c06c..baea8d2be 100644 --- a/net/sstp-client/Makefile +++ b/net/sstp-client/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,16 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sstp-client -PKG_VERSION:=1.0.9 +PKG_VERSION:=1.0.10 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/sstp-client/$(PKG_VERSION) -PKG_MD5SUM:=40f1d1b1596b4f1817ec903f58b2780c +PKG_MD5SUM:=5f290355187e5ce0423fb7e388e65b9d PKG_LICENSE=GPLv2 include $(INCLUDE_DIR)/package.mk +TARGET_CPPFLAGS += -I$(PKG_BUILD_DIR)/include + define Package/sstp-client SECTION:=net CATEGORY:=Network diff --git a/net/sstp-client/patches/100-musl-compat.patch b/net/sstp-client/patches/100-musl-compat.patch new file mode 100644 index 000000000..d19b2fa17 --- /dev/null +++ b/net/sstp-client/patches/100-musl-compat.patch @@ -0,0 +1,33 @@ +--- /dev/null ++++ b/include/net/ppp_defs.h +@@ -0,0 +1,10 @@ ++#ifndef _NET_PPP_DEFS_H ++#define _NET_PPP_DEFS_H 1 ++ ++#define __need_time_t ++#include ++ ++#include ++#include ++ ++#endif /* net/ppp_defs.h */ +--- a/src/libsstp-log/sstp-log-syslog.c ++++ b/src/libsstp-log/sstp-log-syslog.c +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + #include + + #include +--- a/src/libsstp-log/sstp-log-std.c ++++ b/src/libsstp-log/sstp-log-std.c +@@ -25,6 +25,7 @@ + #include + #include + #include ++#include + #include + #include + diff --git a/net/strongswan/Makefile b/net/strongswan/Makefile index 85816dd37..840b02e11 100644 --- a/net/strongswan/Makefile +++ b/net/strongswan/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=strongswan -PKG_VERSION:=5.2.2 +PKG_VERSION:=5.3.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://download.strongswan.org/ http://download2.strongswan.org/ -PKG_MD5SUM:=7ee1a33060b2bde35be0f6d78a1d26d0 +PKG_MD5SUM:=fab014be1477ef4ebf9a765e10f8802c PKG_LICENSE:=GPL-2.0+ PKG_MAINTAINER:=Steven Barth @@ -56,7 +56,6 @@ PKG_MOD_AVAILABLE:= \ md5 \ mysql \ openssl \ - padlock \ pem \ pgp \ pkcs1 \ @@ -166,7 +165,6 @@ $(call Package/strongswan/Default) +strongswan-mod-md5 \ +strongswan-mod-mysql \ +strongswan-mod-openssl \ - +TARGET_x86:strongswan-mod-padlock \ +strongswan-mod-pem \ +strongswan-mod-pgp \ +strongswan-mod-pkcs1 \ @@ -407,7 +405,7 @@ endef define Plugin/updown/install $(INSTALL_DIR) $(1)/usr/lib/ipsec/plugins - $(CP) $(PKG_INSTALL_DIR)/usr/lib/ipsec/{_updown,_updown_espmark} $(1)/usr/lib/ipsec/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/ipsec/_updown $(1)/usr/lib/ipsec/ $(CP) $(PKG_INSTALL_DIR)/usr/lib/ipsec/plugins/libstrongswan-updown.so $(1)/usr/lib/ipsec/plugins/ $(INSTALL_DIR) $(1)/etc $(INSTALL_CONF) ./files/ipsec.user $(1)/etc/ @@ -435,7 +433,7 @@ $(eval $(call BuildPlugin,aes,AES crypto,)) $(eval $(call BuildPlugin,af-alg,AF_ALG crypto interface to Linux Crypto API,+kmod-crypto-user)) $(eval $(call BuildPlugin,agent,SSH agent signing,)) $(eval $(call BuildPlugin,attr,file based config,)) -$(eval $(call BuildPlugin,attr-sql,SQL based config,+strongswan-mod-sql)) +$(eval $(call BuildPlugin,attr-sql,SQL based config,+strongswan-charon)) $(eval $(call BuildPlugin,blowfish,Blowfish crypto,)) $(eval $(call BuildPlugin,ccm,CCM AEAD wrapper crypto,)) $(eval $(call BuildPlugin,cmac,CMAC crypto,)) @@ -468,7 +466,6 @@ $(eval $(call BuildPlugin,md4,MD4 crypto,)) $(eval $(call BuildPlugin,md5,MD5 crypto,)) $(eval $(call BuildPlugin,mysql,MySQL database interface,+strongswan-mod-sql +PACKAGE_strongswan-mod-mysql:libmysqlclient-r)) $(eval $(call BuildPlugin,openssl,OpenSSL crypto,+PACKAGE_strongswan-mod-openssl:libopenssl)) -$(eval $(call BuildPlugin,padlock,VIA PadLock crypto,@TARGET_x86)) $(eval $(call BuildPlugin,pem,PEM decoding,)) $(eval $(call BuildPlugin,pgp,PGP key decoding,)) $(eval $(call BuildPlugin,pkcs1,PKCS1 key decoding,)) diff --git a/net/strongswan/patches/101-musl-fixes.patch b/net/strongswan/patches/101-musl-fixes.patch new file mode 100644 index 000000000..3b90e6cf2 --- /dev/null +++ b/net/strongswan/patches/101-musl-fixes.patch @@ -0,0 +1,85 @@ +--- a/src/libstrongswan/library.h ++++ b/src/libstrongswan/library.h +@@ -118,6 +118,7 @@ + #include "utils/leak_detective.h" + #include "plugins/plugin_loader.h" + #include "settings/settings.h" ++#include "musl.h" + + typedef struct library_t library_t; + +--- /dev/null ++++ b/src/libstrongswan/musl.h +@@ -0,0 +1,39 @@ ++#include ++ ++#define crypt x_crypt ++#define encrypt x_encrypt ++#include ++ ++#define fd_set x_fd_set ++#define ino_t x_ino_t ++#define off_t x_off_t ++#define loff_t x_loff_t ++#define dev_t x_dev_t ++#define mode_t x_mode_t ++#define uid_t x_uid_t ++#define gid_t x_gid_t ++#define uint64_t x_uint64_t ++#define u_int64_t x_u_int64_t ++#define int64_t x_int64_t ++#define nlink_t x_nlink_t ++#define timer_t x_timer_t ++#define blkcnt_t x_blkcnt_t ++#define __kernel_nlink_t void ++ ++#include ++ ++#undef fd_set ++#undef ino_t ++#undef off_t ++#undef dev_t ++#undef mode_t ++#undef uid_t ++#undef gid_t ++#undef uint64_t ++#undef u_int64_t ++#undef int64_t ++#undef nlink_t ++#undef timer_t ++#undef blkcnt_t ++#undef crypt ++#undef encrypt +--- a/src/libhydra/plugins/kernel_netlink/kernel_netlink_ipsec.c ++++ b/src/libhydra/plugins/kernel_netlink/kernel_netlink_ipsec.c +@@ -18,6 +18,8 @@ + * for more details. + */ + ++#include ++ + #include + #include + #include +--- a/src/libhydra/plugins/kernel_netlink/kernel_netlink_net.c ++++ b/src/libhydra/plugins/kernel_netlink/kernel_netlink_net.c +@@ -37,6 +37,8 @@ + * THE SOFTWARE. + */ + ++#include "musl.h" ++ + #include + #include + #include +--- a/src/libhydra/plugins/kernel_netlink/kernel_netlink_shared.c ++++ b/src/libhydra/plugins/kernel_netlink/kernel_netlink_shared.c +@@ -15,6 +15,8 @@ + * for more details. + */ + ++#include "musl.h" ++ + #include + #include + #include diff --git a/net/strongswan/patches/300-include-ipsec-user-script.patch b/net/strongswan/patches/300-include-ipsec-user-script.patch index d96e84492..6835e02fe 100644 --- a/net/strongswan/patches/300-include-ipsec-user-script.patch +++ b/net/strongswan/patches/300-include-ipsec-user-script.patch @@ -13,5 +13,5 @@ + +[ -e /etc/ipsec.user ] && . /etc/ipsec.user "$1" - # things that this script gets (from ipsec_pluto(8) man page) - # + # PLUTO_VERSION + # indicates what version of this interface is being diff --git a/net/stunnel/Makefile b/net/stunnel/Makefile new file mode 100644 index 000000000..0b928b7f6 --- /dev/null +++ b/net/stunnel/Makefile @@ -0,0 +1,77 @@ +# +# 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:=stunnel +PKG_VERSION:=5.14 +PKG_RELEASE:=1 + +PKG_LICENSE:=GPL-2.0+ +PKG_MAINTAINER:=Michael Haas +PKG_LICENSE_FILES:=COPYING COPYRIGHT.GPL + +PKG_SOURCE_URL:=http://stunnel.cybermirror.org/archive/5.x/ +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_MD5SUM:=e716501960dc6856d80f92547298f724 + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/stunnel + SECTION:=net + CATEGORY:=Network + DEPENDS:=+libopenssl + TITLE:=SSL TCP Wrapper + URL:=http://www.stunnel.org/ +endef + +define Package/stunnel/description + Stunnel is a program that allows you to encrypt arbitrary TCP + connections inside SSL (Secure Sockets Layer) available on both Unix + and Windows. Stunnel can allow you to secure non-SSL aware daemons and + protocols (like POP, IMAP, LDAP, etc) by having Stunnel provide the + encryption, requiring no changes to the daemon's code. +endef + +define Package/stunnel/conffiles +/etc/stunnel/stunnel.conf +endef + + +CONFIGURE_ARGS+= \ + --with-random=/dev/urandom \ + --with-threads=fork \ + --with-ssl=$(STAGING_DIR)/usr \ + --disable-libwrap \ + --disable-systemd + +ifeq ($(CONFIG_IPV6),n) +CONFIGURE_ARGS+= \ + --disable-ipv6 +endif + +define Build/Compile + mkdir -p $(PKG_INSTALL_DIR)/etc/stunnel + echo '#dummy' > $(PKG_INSTALL_DIR)/etc/stunnel/stunnel.pem + $(call Build/Compile/Default) +endef + +define Package/stunnel/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/stunnel $(1)/usr/bin/ + $(INSTALL_DIR) $(1)/usr/lib/stunnel + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/stunnel/libstunnel.so $(1)/usr/lib/stunnel/ + $(INSTALL_DIR) $(1)/etc/stunnel + $(INSTALL_CONF) ./files/stunnel.conf $(1)/etc/stunnel/stunnel.conf + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/stunnel.init $(1)/etc/init.d/stunnel +endef + +$(eval $(call BuildPackage,stunnel)) diff --git a/net/stunnel/files/stunnel.conf b/net/stunnel/files/stunnel.conf new file mode 100644 index 000000000..2f10800b9 --- /dev/null +++ b/net/stunnel/files/stunnel.conf @@ -0,0 +1,45 @@ +; Drop privileges +setuid = nobody +setgid = nogroup + +; When running under procd, stay in foreground +foreground = yes + +; Don't log to stderr, use syslog +syslog = yes + +; 1-7. Use 7 for greatest verbosity +;debug = 5 + +; Starting here, enter your services or uncomment the examples + +; Example: +; If your local httpd does not support HTTPS, use stunnel in remote +; mode to forward TLS connections coming in on port 443 to non-TLS +; on port 80. +; Make sure that the cert is available. +;[httpd] +;accept = 443 +;connect = 127.0.0.1:80 +;cert = /etc/stunnel/stunnel.pem + +; Example: +; If your local email client does not support TLS, +; use stunnel in client mode to forward non-TLS connections on +; port 143 to TLS-enabled servername:993. +;[imap] +;client = yes +;accept = 143 +;connect = servername:993 +; Disable peer verification - be sure to understand the limitations of peer +; verification in stunnel when enabling. +;verify = 0 + +; Default client section: +; stunnel requires at least one section to start successfully. +; You can safely remove this section once you have configured +; your own. We use client mode here as server requires a certificate. +[dummy] +client = yes +accept = localhost:6000 +connect = localhost:6001 diff --git a/net/stunnel/files/stunnel.init b/net/stunnel/files/stunnel.init new file mode 100644 index 000000000..e622205b8 --- /dev/null +++ b/net/stunnel/files/stunnel.init @@ -0,0 +1,12 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2006-2008 OpenWrt.org + +START=90 +USE_PROCD=1 + +start_service() { + procd_open_instance + procd_set_param command /usr/bin/stunnel /etc/stunnel/stunnel.conf + procd_set_param respawn # respawn automatically if something died + procd_close_instance +} diff --git a/net/stunnel/patches/010_fix_getnameinfo.patch b/net/stunnel/patches/010_fix_getnameinfo.patch new file mode 100644 index 000000000..03acfafac --- /dev/null +++ b/net/stunnel/patches/010_fix_getnameinfo.patch @@ -0,0 +1,25 @@ +--- a/src/prototypes.h ++++ b/src/prototypes.h +@@ -590,7 +590,7 @@ extern GETNAMEINFO s_getnameinfo; + + #endif /* USE_WIN32 */ + +-int getnameinfo(const struct sockaddr *, int, char *, int, char *, int, int); ++int getnameinfo(const struct sockaddr *, socklen_t, char *, socklen_t, char *, socklen_t, unsigned int); + + #endif /* !defined HAVE_GETNAMEINFO */ + +--- a/src/resolver.c ++++ b/src/resolver.c +@@ -538,8 +538,9 @@ const char *s_gai_strerror(int err) { + /* implementation is limited to functionality needed by stunnel */ + + #ifndef HAVE_GETNAMEINFO +-int getnameinfo(const struct sockaddr *sa, int salen, +- char *host, int hostlen, char *serv, int servlen, int flags) { ++int getnameinfo(const struct sockaddr *sa, socklen_t salen, ++ char *host, socklen_t hostlen, char *serv, socklen_t servlen, ++ unsigned int flags) { + + #if defined(USE_WIN32) && !defined(_WIN32_WCE) + if(s_getnameinfo) diff --git a/net/stunnel/patches/011_disable_ssp_linking.patch b/net/stunnel/patches/011_disable_ssp_linking.patch new file mode 100644 index 000000000..459c016da --- /dev/null +++ b/net/stunnel/patches/011_disable_ssp_linking.patch @@ -0,0 +1,140 @@ +--- a/configure ++++ b/configure +@@ -5646,66 +5646,66 @@ done + + + +-for flag in -fstack-protector; do +- as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$flag" | $as_tr_sh` +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $flag" >&5 +-$as_echo_n "checking whether C compiler accepts $flag... " >&6; } +-if eval \${$as_CACHEVAR+:} false; then : +- $as_echo_n "(cached) " >&6 +-else +- +- ax_check_save_flags=$CFLAGS +- CFLAGS="$CFLAGS $flag" +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-int +-main () +-{ +- +- ; +- return 0; +-} +-_ACEOF +-if ac_fn_c_try_compile "$LINENO"; then : +- eval "$as_CACHEVAR=yes" +-else +- eval "$as_CACHEVAR=no" +-fi +-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +- CFLAGS=$ax_check_save_flags +-fi +-eval ac_res=\$$as_CACHEVAR +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +-$as_echo "$ac_res" >&6; } +-if test x"`eval 'as_val=${'$as_CACHEVAR'};$as_echo "$as_val"'`" = xyes; then : +- if ${CFLAGS+:} false; then : +- case " $CFLAGS " in +- *" $flag "*) +- { { $as_echo "$as_me:${as_lineno-$LINENO}: : CFLAGS already contains \$flag"; } >&5 +- (: CFLAGS already contains $flag) 2>&5 +- ac_status=$? +- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 +- test $ac_status = 0; } +- ;; +- *) +- { { $as_echo "$as_me:${as_lineno-$LINENO}: : CFLAGS=\"\$CFLAGS \$flag\""; } >&5 +- (: CFLAGS="$CFLAGS $flag") 2>&5 +- ac_status=$? +- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 +- test $ac_status = 0; } +- CFLAGS="$CFLAGS $flag" +- ;; +- esac +-else +- CFLAGS="$flag" +-fi +- +-else +- : +-fi +- +-done ++#for flag in -fstack-protector; do ++# as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$flag" | $as_tr_sh` ++#{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $flag" >&5 ++#$as_echo_n "checking whether C compiler accepts $flag... " >&6; } ++#if eval \${$as_CACHEVAR+:} false; then : ++# $as_echo_n "(cached) " >&6 ++#else ++# ++# ax_check_save_flags=$CFLAGS ++# CFLAGS="$CFLAGS $flag" ++# cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++#/* end confdefs.h. */ ++ ++#int ++#main () ++#{ ++# ++# ; ++# return 0; ++#} ++#_ACEOF ++#if ac_fn_c_try_compile "$LINENO"; then : ++# eval "$as_CACHEVAR=yes" ++#else ++# eval "$as_CACHEVAR=no" ++#fi ++#rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ++# CFLAGS=$ax_check_save_flags ++#fi ++#eval ac_res=\$$as_CACHEVAR ++# { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 ++#$as_echo "$ac_res" >&6; } ++#if test x"`eval 'as_val=${'$as_CACHEVAR'};$as_echo "$as_val"'`" = xyes; then : ++# if ${CFLAGS+:} false; then : ++# case " $CFLAGS " in ++# *" $flag "*) ++# { { $as_echo "$as_me:${as_lineno-$LINENO}: : CFLAGS already contains \$flag"; } >&5 ++# (: CFLAGS already contains $flag) 2>&5 ++# ac_status=$? ++# $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 ++# test $ac_status = 0; } ++# ;; ++# *) ++# { { $as_echo "$as_me:${as_lineno-$LINENO}: : CFLAGS=\"\$CFLAGS \$flag\""; } >&5 ++# (: CFLAGS="$CFLAGS $flag") 2>&5 ++# ac_status=$? ++# $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 ++# test $ac_status = 0; } ++# CFLAGS="$CFLAGS $flag" ++# ;; ++# esac ++#else ++# CFLAGS="$flag" ++#fi ++# ++#else ++# : ++#fi ++# ++#done + + + +--- a/configure.ac ++++ b/configure.ac +@@ -71,7 +71,7 @@ AX_APPEND_COMPILE_FLAGS([-Wformat=2]) + AX_APPEND_COMPILE_FLAGS([-Wconversion]) + AX_APPEND_COMPILE_FLAGS([-Wno-long-long]) + AX_APPEND_COMPILE_FLAGS([-Wno-deprecated-declarations]) +-AX_APPEND_COMPILE_FLAGS([-fstack-protector]) ++#AX_APPEND_COMPILE_FLAGS([-fstack-protector]) + AX_APPEND_COMPILE_FLAGS([-fPIE]) + AX_APPEND_COMPILE_FLAGS([-D_FORTIFY_SOURCE=2]) + AX_APPEND_LINK_FLAGS([-fPIE -pie]) diff --git a/net/tcpproxy/Makefile b/net/tcpproxy/Makefile index 2f7cb4d0f..77ef8259d 100644 --- a/net/tcpproxy/Makefile +++ b/net/tcpproxy/Makefile @@ -12,12 +12,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tcpproxy -PKG_VERSION:=1.1 +PKG_VERSION:=1.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.spreadspace.org/tcpproxy/releases/ -PKG_MD5SUM:=55126473bcde635f9ee019c6caf19bb7 +PKG_MD5SUM:=14f734a61350c52556909e2ed5bff361 PKG_MAINTAINER:=Christian Pointner PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=LICENSE @@ -56,6 +56,7 @@ define Build/Configure echo '#define TARGET "linux"' >> config.h; \ echo '#define PREFIX "/usr"' >> config.h; \ echo '#define BINDIR "/usr/bin"' >> config.h; \ + echo '#define SYSTEMDDIR "/tmp"' >> config.h; \ echo '#define ETCDIR "/etc"' >> config.h; \ echo '#define CONFFILE "/etc/tcpproxy.conf"' >> config.h; \ echo '' >> config.h; \ diff --git a/net/tcpproxy/patches/001-ragel_generated.patch b/net/tcpproxy/patches/001-ragel_generated.patch index 38d6bc77e..600e602c2 100644 --- a/net/tcpproxy/patches/001-ragel_generated.patch +++ b/net/tcpproxy/patches/001-ragel_generated.patch @@ -1,6 +1,6 @@ -diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c ---- tcpproxy-1.1.orig/src/cfg_parser.c 1970-01-01 01:00:00.000000000 +0100 -+++ tcpproxy-1.1/src/cfg_parser.c 2014-02-24 04:05:11.087171984 +0100 +diff -Nur tcpproxy-1.2.orig/src/cfg_parser.c tcpproxy-1.2/src/cfg_parser.c +--- tcpproxy-1.2.orig/src/cfg_parser.c 1970-01-01 01:00:00.000000000 +0100 ++++ tcpproxy-1.2/src/cfg_parser.c 2015-05-17 18:10:54.933307372 +0200 @@ -0,0 +1,1374 @@ + +#line 1 "cfg_parser.rl" @@ -13,7 +13,7 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c + * endpoints and vice versa. + * + * -+ * Copyright (C) 2010-2013 Christian Pointner ++ * Copyright (C) 2010-2015 Christian Pointner + * + * This file is part of tcpproxy. + * @@ -113,7 +113,7 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c +{ + int cs, ret = 0, cur_line = 1; + -+ ++ +#line 114 "cfg_parser.c" +static const int cfg_parser_start = 67; +static const int cfg_parser_first_final = 67; @@ -123,11 +123,11 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c + + +#line 170 "cfg_parser.rl" -+ ++ +#line 124 "cfg_parser.c" -+ { -+ cs = cfg_parser_start; -+ } ++ { ++ cs = cfg_parser_start; ++ } + +#line 171 "cfg_parser.rl" + @@ -136,119 +136,119 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c + init_listener_struct(&lst); + + char* eof = pe; -+ ++ +#line 137 "cfg_parser.c" -+ { -+ if ( p == pe ) -+ goto _test_eof; -+ goto _resume; ++ { ++ if ( p == pe ) ++ goto _test_eof; ++ goto _resume; + +_again: -+ switch ( cs ) { -+ case 67: goto st67; -+ case 0: goto st0; -+ case 1: goto st1; -+ case 2: goto st2; -+ case 3: goto st3; -+ case 4: goto st4; -+ case 5: goto st5; -+ case 6: goto st6; -+ case 7: goto st7; -+ case 8: goto st8; -+ case 9: goto st9; -+ case 10: goto st10; -+ case 11: goto st11; -+ case 12: goto st12; -+ case 13: goto st13; -+ case 14: goto st14; -+ case 15: goto st15; -+ case 16: goto st16; -+ case 17: goto st17; -+ case 18: goto st18; -+ case 19: goto st19; -+ case 20: goto st20; -+ case 21: goto st21; -+ case 22: goto st22; -+ case 23: goto st23; -+ case 24: goto st24; -+ case 25: goto st25; -+ case 26: goto st26; -+ case 27: goto st27; -+ case 28: goto st28; -+ case 29: goto st29; -+ case 30: goto st30; -+ case 31: goto st31; -+ case 32: goto st32; -+ case 33: goto st33; -+ case 34: goto st34; -+ case 35: goto st35; -+ case 36: goto st36; -+ case 37: goto st37; -+ case 38: goto st38; -+ case 39: goto st39; -+ case 40: goto st40; -+ case 41: goto st41; -+ case 42: goto st42; -+ case 43: goto st43; -+ case 44: goto st44; -+ case 45: goto st45; -+ case 46: goto st46; -+ case 47: goto st47; -+ case 48: goto st48; -+ case 49: goto st49; -+ case 50: goto st50; -+ case 51: goto st51; -+ case 52: goto st52; -+ case 53: goto st53; -+ case 54: goto st54; -+ case 55: goto st55; -+ case 56: goto st56; -+ case 57: goto st57; -+ case 58: goto st58; -+ case 59: goto st59; -+ case 60: goto st60; -+ case 61: goto st61; -+ case 62: goto st62; -+ case 63: goto st63; -+ case 64: goto st64; -+ case 65: goto st65; -+ case 66: goto st66; -+ default: break; -+ } ++ switch ( cs ) { ++ case 67: goto st67; ++ case 0: goto st0; ++ case 1: goto st1; ++ case 2: goto st2; ++ case 3: goto st3; ++ case 4: goto st4; ++ case 5: goto st5; ++ case 6: goto st6; ++ case 7: goto st7; ++ case 8: goto st8; ++ case 9: goto st9; ++ case 10: goto st10; ++ case 11: goto st11; ++ case 12: goto st12; ++ case 13: goto st13; ++ case 14: goto st14; ++ case 15: goto st15; ++ case 16: goto st16; ++ case 17: goto st17; ++ case 18: goto st18; ++ case 19: goto st19; ++ case 20: goto st20; ++ case 21: goto st21; ++ case 22: goto st22; ++ case 23: goto st23; ++ case 24: goto st24; ++ case 25: goto st25; ++ case 26: goto st26; ++ case 27: goto st27; ++ case 28: goto st28; ++ case 29: goto st29; ++ case 30: goto st30; ++ case 31: goto st31; ++ case 32: goto st32; ++ case 33: goto st33; ++ case 34: goto st34; ++ case 35: goto st35; ++ case 36: goto st36; ++ case 37: goto st37; ++ case 38: goto st38; ++ case 39: goto st39; ++ case 40: goto st40; ++ case 41: goto st41; ++ case 42: goto st42; ++ case 43: goto st43; ++ case 44: goto st44; ++ case 45: goto st45; ++ case 46: goto st46; ++ case 47: goto st47; ++ case 48: goto st48; ++ case 49: goto st49; ++ case 50: goto st50; ++ case 51: goto st51; ++ case 52: goto st52; ++ case 53: goto st53; ++ case 54: goto st54; ++ case 55: goto st55; ++ case 56: goto st56; ++ case 57: goto st57; ++ case 58: goto st58; ++ case 59: goto st59; ++ case 60: goto st60; ++ case 61: goto st61; ++ case 62: goto st62; ++ case 63: goto st63; ++ case 64: goto st64; ++ case 65: goto st65; ++ case 66: goto st66; ++ default: break; ++ } + -+ if ( ++p == pe ) -+ goto _test_eof; ++ if ( ++p == pe ) ++ goto _test_eof; +_resume: -+ switch ( cs ) -+ { ++ switch ( cs ) ++ { +tr1: +#line 127 "cfg_parser.rl" -+ {cur_line++;} -+ goto st67; ++ {cur_line++;} ++ goto st67; +tr90: +#line 114 "cfg_parser.rl" -+ { ++ { + ret = listeners_add(listener, lst.la_, lst.lrt_, lst.lp_, lst.ra_, lst.rrt_, lst.rp_, lst.sa_); + clear_listener_struct(&lst); + } -+ goto st67; ++ goto st67; +st67: -+ if ( ++p == pe ) -+ goto _test_eof67; ++ if ( ++p == pe ) ++ goto _test_eof67; +case 67: +#line 236 "cfg_parser.c" -+ switch( (*p) ) { -+ case 10: goto tr1; -+ case 32: goto st67; -+ case 35: goto st1; -+ case 108: goto st2; -+ } -+ if ( 9 <= (*p) && (*p) <= 13 ) -+ goto st67; -+ goto tr2; ++ switch( (*p) ) { ++ case 10: goto tr1; ++ case 32: goto st67; ++ case 35: goto st1; ++ case 108: goto st2; ++ } ++ if ( 9 <= (*p) && (*p) <= 13 ) ++ goto st67; ++ goto tr2; +tr2: +#line 118 "cfg_parser.rl" -+ { ++ { + if(p == eof) + log_printf(ERROR, "config file syntax error: unexpected end of file"); + else @@ -256,1051 +256,1051 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c + + {cs = (cfg_parser_error); goto _again;} + } -+ goto st0; ++ goto st0; +#line 257 "cfg_parser.c" +st0: +cs = 0; -+ goto _out; ++ goto _out; +st1: -+ if ( ++p == pe ) -+ goto _test_eof1; ++ if ( ++p == pe ) ++ goto _test_eof1; +case 1: -+ if ( (*p) == 10 ) -+ goto tr1; -+ goto st1; ++ if ( (*p) == 10 ) ++ goto tr1; ++ goto st1; +st2: -+ if ( ++p == pe ) -+ goto _test_eof2; ++ if ( ++p == pe ) ++ goto _test_eof2; +case 2: -+ if ( (*p) == 105 ) -+ goto st3; -+ goto tr2; ++ if ( (*p) == 105 ) ++ goto st3; ++ goto tr2; +st3: -+ if ( ++p == pe ) -+ goto _test_eof3; ++ if ( ++p == pe ) ++ goto _test_eof3; +case 3: -+ if ( (*p) == 115 ) -+ goto st4; -+ goto tr2; ++ if ( (*p) == 115 ) ++ goto st4; ++ goto tr2; +st4: -+ if ( ++p == pe ) -+ goto _test_eof4; ++ if ( ++p == pe ) ++ goto _test_eof4; +case 4: -+ if ( (*p) == 116 ) -+ goto st5; -+ goto tr2; ++ if ( (*p) == 116 ) ++ goto st5; ++ goto tr2; +st5: -+ if ( ++p == pe ) -+ goto _test_eof5; ++ if ( ++p == pe ) ++ goto _test_eof5; +case 5: -+ if ( (*p) == 101 ) -+ goto st6; -+ goto tr2; ++ if ( (*p) == 101 ) ++ goto st6; ++ goto tr2; +st6: -+ if ( ++p == pe ) -+ goto _test_eof6; ++ if ( ++p == pe ) ++ goto _test_eof6; +case 6: -+ if ( (*p) == 110 ) -+ goto st7; -+ goto tr2; ++ if ( (*p) == 110 ) ++ goto st7; ++ goto tr2; +st7: -+ if ( ++p == pe ) -+ goto _test_eof7; ++ if ( ++p == pe ) ++ goto _test_eof7; +case 7: -+ switch( (*p) ) { -+ case 9: goto st8; -+ case 32: goto st8; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st8; ++ case 32: goto st8; ++ } ++ goto tr2; +st8: -+ if ( ++p == pe ) -+ goto _test_eof8; ++ if ( ++p == pe ) ++ goto _test_eof8; +case 8: -+ switch( (*p) ) { -+ case 9: goto st8; -+ case 32: goto st8; -+ case 42: goto st9; -+ case 58: goto tr12; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto tr11; -+ } else if ( (*p) >= 45 ) -+ goto tr10; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto tr10; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto tr10; -+ } else -+ goto tr11; -+ } else -+ goto tr11; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st8; ++ case 32: goto st8; ++ case 42: goto st9; ++ case 58: goto tr12; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto tr11; ++ } else if ( (*p) >= 45 ) ++ goto tr10; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto tr10; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto tr10; ++ } else ++ goto tr11; ++ } else ++ goto tr11; ++ goto tr2; +st9: -+ if ( ++p == pe ) -+ goto _test_eof9; ++ if ( ++p == pe ) ++ goto _test_eof9; +case 9: -+ switch( (*p) ) { -+ case 9: goto st10; -+ case 32: goto st10; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st10; ++ case 32: goto st10; ++ } ++ goto tr2; +tr91: +#line 105 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.la_), cpy_start, p); cpy_start = NULL; } -+ goto st10; ++ { ret = owrt_string(&(lst.la_), cpy_start, p); cpy_start = NULL; } ++ goto st10; +st10: -+ if ( ++p == pe ) -+ goto _test_eof10; ++ if ( ++p == pe ) ++ goto _test_eof10; +case 10: +#line 357 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto st10; -+ case 32: goto st10; -+ case 45: goto tr14; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto tr14; -+ } else if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto tr14; -+ } else -+ goto tr14; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st10; ++ case 32: goto st10; ++ case 45: goto tr14; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto tr14; ++ } else if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto tr14; ++ } else ++ goto tr14; ++ goto tr2; +tr14: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st11; ++ { cpy_start = p; } ++ goto st11; +st11: -+ if ( ++p == pe ) -+ goto _test_eof11; ++ if ( ++p == pe ) ++ goto _test_eof11; +case 11: +#line 380 "cfg_parser.c" -+ switch( (*p) ) { -+ case 10: goto tr16; -+ case 32: goto tr15; -+ case 35: goto tr17; -+ case 45: goto st11; -+ case 123: goto tr19; -+ } -+ if ( (*p) < 48 ) { -+ if ( 9 <= (*p) && (*p) <= 13 ) -+ goto tr15; -+ } else if ( (*p) > 57 ) { -+ if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto st11; -+ } else if ( (*p) >= 65 ) -+ goto st11; -+ } else -+ goto st11; -+ goto tr2; ++ switch( (*p) ) { ++ case 10: goto tr16; ++ case 32: goto tr15; ++ case 35: goto tr17; ++ case 45: goto st11; ++ case 123: goto tr19; ++ } ++ if ( (*p) < 48 ) { ++ if ( 9 <= (*p) && (*p) <= 13 ) ++ goto tr15; ++ } else if ( (*p) > 57 ) { ++ if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto st11; ++ } else if ( (*p) >= 65 ) ++ goto st11; ++ } else ++ goto st11; ++ goto tr2; +tr21: +#line 127 "cfg_parser.rl" -+ {cur_line++;} -+ goto st12; ++ {cur_line++;} ++ goto st12; +tr15: +#line 106 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } -+ goto st12; ++ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } ++ goto st12; +tr16: +#line 106 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } ++ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } +#line 127 "cfg_parser.rl" -+ {cur_line++;} -+ goto st12; ++ {cur_line++;} ++ goto st12; +st12: -+ if ( ++p == pe ) -+ goto _test_eof12; ++ if ( ++p == pe ) ++ goto _test_eof12; +case 12: +#line 418 "cfg_parser.c" -+ switch( (*p) ) { -+ case 10: goto tr21; -+ case 32: goto st12; -+ case 35: goto st13; -+ case 123: goto st14; -+ } -+ if ( 9 <= (*p) && (*p) <= 13 ) -+ goto st12; -+ goto tr2; ++ switch( (*p) ) { ++ case 10: goto tr21; ++ case 32: goto st12; ++ case 35: goto st13; ++ case 123: goto st14; ++ } ++ if ( 9 <= (*p) && (*p) <= 13 ) ++ goto st12; ++ goto tr2; +tr17: +#line 106 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } -+ goto st13; ++ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } ++ goto st13; +st13: -+ if ( ++p == pe ) -+ goto _test_eof13; ++ if ( ++p == pe ) ++ goto _test_eof13; +case 13: +#line 436 "cfg_parser.c" -+ if ( (*p) == 10 ) -+ goto tr21; -+ goto st13; ++ if ( (*p) == 10 ) ++ goto tr21; ++ goto st13; +tr24: +#line 127 "cfg_parser.rl" -+ {cur_line++;} -+ goto st14; ++ {cur_line++;} ++ goto st14; +tr19: +#line 106 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } -+ goto st14; ++ { ret = owrt_string(&(lst.lp_), cpy_start, p); cpy_start = NULL; } ++ goto st14; +tr48: +#line 110 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.rp_), cpy_start, p); cpy_start = NULL; } -+ goto st14; ++ { ret = owrt_string(&(lst.rp_), cpy_start, p); cpy_start = NULL; } ++ goto st14; +tr87: +#line 113 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.sa_), cpy_start, p); cpy_start = NULL; } -+ goto st14; ++ { ret = owrt_string(&(lst.sa_), cpy_start, p); cpy_start = NULL; } ++ goto st14; +st14: -+ if ( ++p == pe ) -+ goto _test_eof14; ++ if ( ++p == pe ) ++ goto _test_eof14; +case 14: +#line 460 "cfg_parser.c" -+ switch( (*p) ) { -+ case 10: goto tr24; -+ case 32: goto st14; -+ case 35: goto st15; -+ case 114: goto st16; -+ case 115: goto st52; -+ case 125: goto st63; -+ } -+ if ( 9 <= (*p) && (*p) <= 13 ) -+ goto st14; -+ goto tr2; ++ switch( (*p) ) { ++ case 10: goto tr24; ++ case 32: goto st14; ++ case 35: goto st15; ++ case 114: goto st16; ++ case 115: goto st52; ++ case 125: goto st63; ++ } ++ if ( 9 <= (*p) && (*p) <= 13 ) ++ goto st14; ++ goto tr2; +st15: -+ if ( ++p == pe ) -+ goto _test_eof15; ++ if ( ++p == pe ) ++ goto _test_eof15; +case 15: -+ if ( (*p) == 10 ) -+ goto tr24; -+ goto st15; ++ if ( (*p) == 10 ) ++ goto tr24; ++ goto st15; +st16: -+ if ( ++p == pe ) -+ goto _test_eof16; ++ if ( ++p == pe ) ++ goto _test_eof16; +case 16: -+ if ( (*p) == 101 ) -+ goto st17; -+ goto tr2; ++ if ( (*p) == 101 ) ++ goto st17; ++ goto tr2; +st17: -+ if ( ++p == pe ) -+ goto _test_eof17; ++ if ( ++p == pe ) ++ goto _test_eof17; +case 17: -+ switch( (*p) ) { -+ case 109: goto st18; -+ case 115: goto st43; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 109: goto st18; ++ case 115: goto st43; ++ } ++ goto tr2; +st18: -+ if ( ++p == pe ) -+ goto _test_eof18; ++ if ( ++p == pe ) ++ goto _test_eof18; +case 18: -+ if ( (*p) == 111 ) -+ goto st19; -+ goto tr2; ++ if ( (*p) == 111 ) ++ goto st19; ++ goto tr2; +st19: -+ if ( ++p == pe ) -+ goto _test_eof19; ++ if ( ++p == pe ) ++ goto _test_eof19; +case 19: -+ if ( (*p) == 116 ) -+ goto st20; -+ goto tr2; ++ if ( (*p) == 116 ) ++ goto st20; ++ goto tr2; +st20: -+ if ( ++p == pe ) -+ goto _test_eof20; ++ if ( ++p == pe ) ++ goto _test_eof20; +case 20: -+ if ( (*p) == 101 ) -+ goto st21; -+ goto tr2; ++ if ( (*p) == 101 ) ++ goto st21; ++ goto tr2; +st21: -+ if ( ++p == pe ) -+ goto _test_eof21; ++ if ( ++p == pe ) ++ goto _test_eof21; +case 21: -+ switch( (*p) ) { -+ case 9: goto st22; -+ case 32: goto st22; -+ case 45: goto st31; -+ case 58: goto st23; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st22; ++ case 32: goto st22; ++ case 45: goto st31; ++ case 58: goto st23; ++ } ++ goto tr2; +st22: -+ if ( ++p == pe ) -+ goto _test_eof22; ++ if ( ++p == pe ) ++ goto _test_eof22; +case 22: -+ switch( (*p) ) { -+ case 9: goto st22; -+ case 32: goto st22; -+ case 58: goto st23; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st22; ++ case 32: goto st22; ++ case 58: goto st23; ++ } ++ goto tr2; +st23: -+ if ( ++p == pe ) -+ goto _test_eof23; ++ if ( ++p == pe ) ++ goto _test_eof23; +case 23: -+ switch( (*p) ) { -+ case 9: goto st24; -+ case 32: goto st24; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st24; ++ case 32: goto st24; ++ } ++ goto tr2; +st24: -+ if ( ++p == pe ) -+ goto _test_eof24; ++ if ( ++p == pe ) ++ goto _test_eof24; +case 24: -+ switch( (*p) ) { -+ case 9: goto st24; -+ case 32: goto st24; -+ case 58: goto tr41; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto tr40; -+ } else if ( (*p) >= 45 ) -+ goto tr39; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto tr39; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto tr39; -+ } else -+ goto tr40; -+ } else -+ goto tr40; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st24; ++ case 32: goto st24; ++ case 58: goto tr41; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto tr40; ++ } else if ( (*p) >= 45 ) ++ goto tr39; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto tr39; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto tr39; ++ } else ++ goto tr40; ++ } else ++ goto tr40; ++ goto tr2; +tr39: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st25; ++ { cpy_start = p; } ++ goto st25; +st25: -+ if ( ++p == pe ) -+ goto _test_eof25; ++ if ( ++p == pe ) ++ goto _test_eof25; +case 25: +#line 581 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr42; -+ case 32: goto tr42; -+ } -+ if ( (*p) < 48 ) { -+ if ( 45 <= (*p) && (*p) <= 46 ) -+ goto st25; -+ } else if ( (*p) > 57 ) { -+ if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto st25; -+ } else if ( (*p) >= 65 ) -+ goto st25; -+ } else -+ goto st25; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr42; ++ case 32: goto tr42; ++ } ++ if ( (*p) < 48 ) { ++ if ( 45 <= (*p) && (*p) <= 46 ) ++ goto st25; ++ } else if ( (*p) > 57 ) { ++ if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto st25; ++ } else if ( (*p) >= 65 ) ++ goto st25; ++ } else ++ goto st25; ++ goto tr2; +tr42: +#line 109 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.ra_), cpy_start, p); cpy_start = NULL; } -+ goto st26; ++ { ret = owrt_string(&(lst.ra_), cpy_start, p); cpy_start = NULL; } ++ goto st26; +st26: -+ if ( ++p == pe ) -+ goto _test_eof26; ++ if ( ++p == pe ) ++ goto _test_eof26; +case 26: +#line 606 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto st26; -+ case 32: goto st26; -+ case 45: goto tr45; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto tr45; -+ } else if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto tr45; -+ } else -+ goto tr45; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st26; ++ case 32: goto st26; ++ case 45: goto tr45; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto tr45; ++ } else if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto tr45; ++ } else ++ goto tr45; ++ goto tr2; +tr45: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st27; ++ { cpy_start = p; } ++ goto st27; +st27: -+ if ( ++p == pe ) -+ goto _test_eof27; ++ if ( ++p == pe ) ++ goto _test_eof27; +case 27: +#line 629 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr46; -+ case 32: goto tr46; -+ case 45: goto st27; -+ case 59: goto tr48; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto st27; -+ } else if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto st27; -+ } else -+ goto st27; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr46; ++ case 32: goto tr46; ++ case 45: goto st27; ++ case 59: goto tr48; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto st27; ++ } else if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto st27; ++ } else ++ goto st27; ++ goto tr2; +tr46: +#line 110 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.rp_), cpy_start, p); cpy_start = NULL; } -+ goto st28; ++ { ret = owrt_string(&(lst.rp_), cpy_start, p); cpy_start = NULL; } ++ goto st28; +tr63: +#line 111 "cfg_parser.rl" -+ { lst.rrt_ = IPV4_ONLY; } -+ goto st28; ++ { lst.rrt_ = IPV4_ONLY; } ++ goto st28; +tr64: +#line 112 "cfg_parser.rl" -+ { lst.rrt_ = IPV6_ONLY; } -+ goto st28; ++ { lst.rrt_ = IPV6_ONLY; } ++ goto st28; +tr73: +#line 107 "cfg_parser.rl" -+ { lst.lrt_ = IPV4_ONLY; } -+ goto st28; ++ { lst.lrt_ = IPV4_ONLY; } ++ goto st28; +tr74: +#line 108 "cfg_parser.rl" -+ { lst.lrt_ = IPV6_ONLY; } -+ goto st28; ++ { lst.lrt_ = IPV6_ONLY; } ++ goto st28; +tr85: +#line 113 "cfg_parser.rl" -+ { ret = owrt_string(&(lst.sa_), cpy_start, p); cpy_start = NULL; } -+ goto st28; ++ { ret = owrt_string(&(lst.sa_), cpy_start, p); cpy_start = NULL; } ++ goto st28; +st28: -+ if ( ++p == pe ) -+ goto _test_eof28; ++ if ( ++p == pe ) ++ goto _test_eof28; +case 28: +#line 673 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto st28; -+ case 32: goto st28; -+ case 59: goto st14; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st28; ++ case 32: goto st28; ++ case 59: goto st14; ++ } ++ goto tr2; +tr40: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st29; ++ { cpy_start = p; } ++ goto st29; +st29: -+ if ( ++p == pe ) -+ goto _test_eof29; ++ if ( ++p == pe ) ++ goto _test_eof29; +case 29: +#line 688 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr42; -+ case 32: goto tr42; -+ case 58: goto st30; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto st29; -+ } else if ( (*p) >= 45 ) -+ goto st25; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto st25; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto st25; -+ } else -+ goto st29; -+ } else -+ goto st29; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr42; ++ case 32: goto tr42; ++ case 58: goto st30; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto st29; ++ } else if ( (*p) >= 45 ) ++ goto st25; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto st25; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto st25; ++ } else ++ goto st29; ++ } else ++ goto st29; ++ goto tr2; +tr41: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st30; ++ { cpy_start = p; } ++ goto st30; +st30: -+ if ( ++p == pe ) -+ goto _test_eof30; ++ if ( ++p == pe ) ++ goto _test_eof30; +case 30: +#line 720 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr42; -+ case 32: goto tr42; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 58 ) -+ goto st30; -+ } else if ( (*p) > 70 ) { -+ if ( 97 <= (*p) && (*p) <= 102 ) -+ goto st30; -+ } else -+ goto st30; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr42; ++ case 32: goto tr42; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 58 ) ++ goto st30; ++ } else if ( (*p) > 70 ) { ++ if ( 97 <= (*p) && (*p) <= 102 ) ++ goto st30; ++ } else ++ goto st30; ++ goto tr2; +st31: -+ if ( ++p == pe ) -+ goto _test_eof31; ++ if ( ++p == pe ) ++ goto _test_eof31; +case 31: -+ if ( (*p) == 114 ) -+ goto st32; -+ goto tr2; ++ if ( (*p) == 114 ) ++ goto st32; ++ goto tr2; +st32: -+ if ( ++p == pe ) -+ goto _test_eof32; ++ if ( ++p == pe ) ++ goto _test_eof32; +case 32: -+ if ( (*p) == 101 ) -+ goto st33; -+ goto tr2; ++ if ( (*p) == 101 ) ++ goto st33; ++ goto tr2; +st33: -+ if ( ++p == pe ) -+ goto _test_eof33; ++ if ( ++p == pe ) ++ goto _test_eof33; +case 33: -+ if ( (*p) == 115 ) -+ goto st34; -+ goto tr2; ++ if ( (*p) == 115 ) ++ goto st34; ++ goto tr2; +st34: -+ if ( ++p == pe ) -+ goto _test_eof34; ++ if ( ++p == pe ) ++ goto _test_eof34; +case 34: -+ if ( (*p) == 111 ) -+ goto st35; -+ goto tr2; ++ if ( (*p) == 111 ) ++ goto st35; ++ goto tr2; +st35: -+ if ( ++p == pe ) -+ goto _test_eof35; ++ if ( ++p == pe ) ++ goto _test_eof35; +case 35: -+ if ( (*p) == 108 ) -+ goto st36; -+ goto tr2; ++ if ( (*p) == 108 ) ++ goto st36; ++ goto tr2; +st36: -+ if ( ++p == pe ) -+ goto _test_eof36; ++ if ( ++p == pe ) ++ goto _test_eof36; +case 36: -+ if ( (*p) == 118 ) -+ goto st37; -+ goto tr2; ++ if ( (*p) == 118 ) ++ goto st37; ++ goto tr2; +st37: -+ if ( ++p == pe ) -+ goto _test_eof37; ++ if ( ++p == pe ) ++ goto _test_eof37; +case 37: -+ switch( (*p) ) { -+ case 9: goto st37; -+ case 32: goto st37; -+ case 58: goto st38; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st37; ++ case 32: goto st37; ++ case 58: goto st38; ++ } ++ goto tr2; +st38: -+ if ( ++p == pe ) -+ goto _test_eof38; ++ if ( ++p == pe ) ++ goto _test_eof38; +case 38: -+ switch( (*p) ) { -+ case 9: goto st39; -+ case 32: goto st39; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st39; ++ case 32: goto st39; ++ } ++ goto tr2; +st39: -+ if ( ++p == pe ) -+ goto _test_eof39; ++ if ( ++p == pe ) ++ goto _test_eof39; +case 39: -+ switch( (*p) ) { -+ case 9: goto st39; -+ case 32: goto st39; -+ case 73: goto st40; -+ case 105: goto st40; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st39; ++ case 32: goto st39; ++ case 73: goto st40; ++ case 105: goto st40; ++ } ++ goto tr2; +st40: -+ if ( ++p == pe ) -+ goto _test_eof40; ++ if ( ++p == pe ) ++ goto _test_eof40; +case 40: -+ switch( (*p) ) { -+ case 80: goto st41; -+ case 112: goto st41; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 80: goto st41; ++ case 112: goto st41; ++ } ++ goto tr2; +st41: -+ if ( ++p == pe ) -+ goto _test_eof41; ++ if ( ++p == pe ) ++ goto _test_eof41; +case 41: -+ switch( (*p) ) { -+ case 86: goto st42; -+ case 118: goto st42; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 86: goto st42; ++ case 118: goto st42; ++ } ++ goto tr2; +st42: -+ if ( ++p == pe ) -+ goto _test_eof42; ++ if ( ++p == pe ) ++ goto _test_eof42; +case 42: -+ switch( (*p) ) { -+ case 52: goto tr63; -+ case 54: goto tr64; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 52: goto tr63; ++ case 54: goto tr64; ++ } ++ goto tr2; +st43: -+ if ( ++p == pe ) -+ goto _test_eof43; ++ if ( ++p == pe ) ++ goto _test_eof43; +case 43: -+ if ( (*p) == 111 ) -+ goto st44; -+ goto tr2; ++ if ( (*p) == 111 ) ++ goto st44; ++ goto tr2; +st44: -+ if ( ++p == pe ) -+ goto _test_eof44; ++ if ( ++p == pe ) ++ goto _test_eof44; +case 44: -+ if ( (*p) == 108 ) -+ goto st45; -+ goto tr2; ++ if ( (*p) == 108 ) ++ goto st45; ++ goto tr2; +st45: -+ if ( ++p == pe ) -+ goto _test_eof45; ++ if ( ++p == pe ) ++ goto _test_eof45; +case 45: -+ if ( (*p) == 118 ) -+ goto st46; -+ goto tr2; ++ if ( (*p) == 118 ) ++ goto st46; ++ goto tr2; +st46: -+ if ( ++p == pe ) -+ goto _test_eof46; ++ if ( ++p == pe ) ++ goto _test_eof46; +case 46: -+ switch( (*p) ) { -+ case 9: goto st46; -+ case 32: goto st46; -+ case 58: goto st47; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st46; ++ case 32: goto st46; ++ case 58: goto st47; ++ } ++ goto tr2; +st47: -+ if ( ++p == pe ) -+ goto _test_eof47; ++ if ( ++p == pe ) ++ goto _test_eof47; +case 47: -+ switch( (*p) ) { -+ case 9: goto st48; -+ case 32: goto st48; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st48; ++ case 32: goto st48; ++ } ++ goto tr2; +st48: -+ if ( ++p == pe ) -+ goto _test_eof48; ++ if ( ++p == pe ) ++ goto _test_eof48; +case 48: -+ switch( (*p) ) { -+ case 9: goto st48; -+ case 32: goto st48; -+ case 73: goto st49; -+ case 105: goto st49; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st48; ++ case 32: goto st48; ++ case 73: goto st49; ++ case 105: goto st49; ++ } ++ goto tr2; +st49: -+ if ( ++p == pe ) -+ goto _test_eof49; ++ if ( ++p == pe ) ++ goto _test_eof49; +case 49: -+ switch( (*p) ) { -+ case 80: goto st50; -+ case 112: goto st50; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 80: goto st50; ++ case 112: goto st50; ++ } ++ goto tr2; +st50: -+ if ( ++p == pe ) -+ goto _test_eof50; ++ if ( ++p == pe ) ++ goto _test_eof50; +case 50: -+ switch( (*p) ) { -+ case 86: goto st51; -+ case 118: goto st51; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 86: goto st51; ++ case 118: goto st51; ++ } ++ goto tr2; +st51: -+ if ( ++p == pe ) -+ goto _test_eof51; ++ if ( ++p == pe ) ++ goto _test_eof51; +case 51: -+ switch( (*p) ) { -+ case 52: goto tr73; -+ case 54: goto tr74; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 52: goto tr73; ++ case 54: goto tr74; ++ } ++ goto tr2; +st52: -+ if ( ++p == pe ) -+ goto _test_eof52; ++ if ( ++p == pe ) ++ goto _test_eof52; +case 52: -+ if ( (*p) == 111 ) -+ goto st53; -+ goto tr2; ++ if ( (*p) == 111 ) ++ goto st53; ++ goto tr2; +st53: -+ if ( ++p == pe ) -+ goto _test_eof53; ++ if ( ++p == pe ) ++ goto _test_eof53; +case 53: -+ if ( (*p) == 117 ) -+ goto st54; -+ goto tr2; ++ if ( (*p) == 117 ) ++ goto st54; ++ goto tr2; +st54: -+ if ( ++p == pe ) -+ goto _test_eof54; ++ if ( ++p == pe ) ++ goto _test_eof54; +case 54: -+ if ( (*p) == 114 ) -+ goto st55; -+ goto tr2; ++ if ( (*p) == 114 ) ++ goto st55; ++ goto tr2; +st55: -+ if ( ++p == pe ) -+ goto _test_eof55; ++ if ( ++p == pe ) ++ goto _test_eof55; +case 55: -+ if ( (*p) == 99 ) -+ goto st56; -+ goto tr2; ++ if ( (*p) == 99 ) ++ goto st56; ++ goto tr2; +st56: -+ if ( ++p == pe ) -+ goto _test_eof56; ++ if ( ++p == pe ) ++ goto _test_eof56; +case 56: -+ if ( (*p) == 101 ) -+ goto st57; -+ goto tr2; ++ if ( (*p) == 101 ) ++ goto st57; ++ goto tr2; +st57: -+ if ( ++p == pe ) -+ goto _test_eof57; ++ if ( ++p == pe ) ++ goto _test_eof57; +case 57: -+ switch( (*p) ) { -+ case 9: goto st57; -+ case 32: goto st57; -+ case 58: goto st58; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st57; ++ case 32: goto st57; ++ case 58: goto st58; ++ } ++ goto tr2; +st58: -+ if ( ++p == pe ) -+ goto _test_eof58; ++ if ( ++p == pe ) ++ goto _test_eof58; +case 58: -+ switch( (*p) ) { -+ case 9: goto st59; -+ case 32: goto st59; -+ } -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st59; ++ case 32: goto st59; ++ } ++ goto tr2; +st59: -+ if ( ++p == pe ) -+ goto _test_eof59; ++ if ( ++p == pe ) ++ goto _test_eof59; +case 59: -+ switch( (*p) ) { -+ case 9: goto st59; -+ case 32: goto st59; -+ case 58: goto tr84; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto tr83; -+ } else if ( (*p) >= 45 ) -+ goto tr82; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto tr82; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto tr82; -+ } else -+ goto tr83; -+ } else -+ goto tr83; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto st59; ++ case 32: goto st59; ++ case 58: goto tr84; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto tr83; ++ } else if ( (*p) >= 45 ) ++ goto tr82; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto tr82; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto tr82; ++ } else ++ goto tr83; ++ } else ++ goto tr83; ++ goto tr2; +tr82: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st60; ++ { cpy_start = p; } ++ goto st60; +st60: -+ if ( ++p == pe ) -+ goto _test_eof60; ++ if ( ++p == pe ) ++ goto _test_eof60; +case 60: +#line 1000 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr85; -+ case 32: goto tr85; -+ case 59: goto tr87; -+ } -+ if ( (*p) < 48 ) { -+ if ( 45 <= (*p) && (*p) <= 46 ) -+ goto st60; -+ } else if ( (*p) > 57 ) { -+ if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto st60; -+ } else if ( (*p) >= 65 ) -+ goto st60; -+ } else -+ goto st60; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr85; ++ case 32: goto tr85; ++ case 59: goto tr87; ++ } ++ if ( (*p) < 48 ) { ++ if ( 45 <= (*p) && (*p) <= 46 ) ++ goto st60; ++ } else if ( (*p) > 57 ) { ++ if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto st60; ++ } else if ( (*p) >= 65 ) ++ goto st60; ++ } else ++ goto st60; ++ goto tr2; +tr83: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st61; ++ { cpy_start = p; } ++ goto st61; +st61: -+ if ( ++p == pe ) -+ goto _test_eof61; ++ if ( ++p == pe ) ++ goto _test_eof61; +case 61: +#line 1026 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr85; -+ case 32: goto tr85; -+ case 58: goto st62; -+ case 59: goto tr87; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto st61; -+ } else if ( (*p) >= 45 ) -+ goto st60; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto st60; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto st60; -+ } else -+ goto st61; -+ } else -+ goto st61; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr85; ++ case 32: goto tr85; ++ case 58: goto st62; ++ case 59: goto tr87; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto st61; ++ } else if ( (*p) >= 45 ) ++ goto st60; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto st60; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto st60; ++ } else ++ goto st61; ++ } else ++ goto st61; ++ goto tr2; +tr84: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st62; ++ { cpy_start = p; } ++ goto st62; +st62: -+ if ( ++p == pe ) -+ goto _test_eof62; ++ if ( ++p == pe ) ++ goto _test_eof62; +case 62: +#line 1059 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr85; -+ case 32: goto tr85; -+ case 59: goto tr87; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 58 ) -+ goto st62; -+ } else if ( (*p) > 70 ) { -+ if ( 97 <= (*p) && (*p) <= 102 ) -+ goto st62; -+ } else -+ goto st62; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr85; ++ case 32: goto tr85; ++ case 59: goto tr87; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 58 ) ++ goto st62; ++ } else if ( (*p) > 70 ) { ++ if ( 97 <= (*p) && (*p) <= 102 ) ++ goto st62; ++ } else ++ goto st62; ++ goto tr2; +st63: -+ if ( ++p == pe ) -+ goto _test_eof63; ++ if ( ++p == pe ) ++ goto _test_eof63; +case 63: -+ if ( (*p) == 59 ) -+ goto tr90; -+ goto tr2; ++ if ( (*p) == 59 ) ++ goto tr90; ++ goto tr2; +tr10: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st64; ++ { cpy_start = p; } ++ goto st64; +st64: -+ if ( ++p == pe ) -+ goto _test_eof64; ++ if ( ++p == pe ) ++ goto _test_eof64; +case 64: +#line 1089 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr91; -+ case 32: goto tr91; -+ } -+ if ( (*p) < 48 ) { -+ if ( 45 <= (*p) && (*p) <= 46 ) -+ goto st64; -+ } else if ( (*p) > 57 ) { -+ if ( (*p) > 90 ) { -+ if ( 97 <= (*p) && (*p) <= 122 ) -+ goto st64; -+ } else if ( (*p) >= 65 ) -+ goto st64; -+ } else -+ goto st64; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr91; ++ case 32: goto tr91; ++ } ++ if ( (*p) < 48 ) { ++ if ( 45 <= (*p) && (*p) <= 46 ) ++ goto st64; ++ } else if ( (*p) > 57 ) { ++ if ( (*p) > 90 ) { ++ if ( 97 <= (*p) && (*p) <= 122 ) ++ goto st64; ++ } else if ( (*p) >= 65 ) ++ goto st64; ++ } else ++ goto st64; ++ goto tr2; +tr11: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st65; ++ { cpy_start = p; } ++ goto st65; +st65: -+ if ( ++p == pe ) -+ goto _test_eof65; ++ if ( ++p == pe ) ++ goto _test_eof65; +case 65: +#line 1114 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr91; -+ case 32: goto tr91; -+ case 58: goto st66; -+ } -+ if ( (*p) < 65 ) { -+ if ( (*p) > 46 ) { -+ if ( 48 <= (*p) && (*p) <= 57 ) -+ goto st65; -+ } else if ( (*p) >= 45 ) -+ goto st64; -+ } else if ( (*p) > 70 ) { -+ if ( (*p) < 97 ) { -+ if ( 71 <= (*p) && (*p) <= 90 ) -+ goto st64; -+ } else if ( (*p) > 102 ) { -+ if ( 103 <= (*p) && (*p) <= 122 ) -+ goto st64; -+ } else -+ goto st65; -+ } else -+ goto st65; -+ goto tr2; ++ switch( (*p) ) { ++ case 9: goto tr91; ++ case 32: goto tr91; ++ case 58: goto st66; ++ } ++ if ( (*p) < 65 ) { ++ if ( (*p) > 46 ) { ++ if ( 48 <= (*p) && (*p) <= 57 ) ++ goto st65; ++ } else if ( (*p) >= 45 ) ++ goto st64; ++ } else if ( (*p) > 70 ) { ++ if ( (*p) < 97 ) { ++ if ( 71 <= (*p) && (*p) <= 90 ) ++ goto st64; ++ } else if ( (*p) > 102 ) { ++ if ( 103 <= (*p) && (*p) <= 122 ) ++ goto st64; ++ } else ++ goto st65; ++ } else ++ goto st65; ++ goto tr2; +tr12: +#line 104 "cfg_parser.rl" -+ { cpy_start = p; } -+ goto st66; ++ { cpy_start = p; } ++ goto st66; +st66: -+ if ( ++p == pe ) -+ goto _test_eof66; ++ if ( ++p == pe ) ++ goto _test_eof66; +case 66: +#line 1146 "cfg_parser.c" -+ switch( (*p) ) { -+ case 9: goto tr91; -+ case 32: goto tr91; -+ } -+ if ( (*p) < 65 ) { -+ if ( 48 <= (*p) && (*p) <= 58 ) -+ goto st66; -+ } else if ( (*p) > 70 ) { -+ if ( 97 <= (*p) && (*p) <= 102 ) -+ goto st66; -+ } else -+ goto st66; -+ goto tr2; -+ } -+ _test_eof67: cs = 67; goto _test_eof; -+ _test_eof1: cs = 1; goto _test_eof; -+ _test_eof2: cs = 2; goto _test_eof; -+ _test_eof3: cs = 3; goto _test_eof; -+ _test_eof4: cs = 4; goto _test_eof; -+ _test_eof5: cs = 5; goto _test_eof; -+ _test_eof6: cs = 6; goto _test_eof; -+ _test_eof7: cs = 7; goto _test_eof; -+ _test_eof8: cs = 8; goto _test_eof; -+ _test_eof9: cs = 9; goto _test_eof; -+ _test_eof10: cs = 10; goto _test_eof; -+ _test_eof11: cs = 11; goto _test_eof; -+ _test_eof12: cs = 12; goto _test_eof; -+ _test_eof13: cs = 13; goto _test_eof; -+ _test_eof14: cs = 14; goto _test_eof; -+ _test_eof15: cs = 15; goto _test_eof; -+ _test_eof16: cs = 16; goto _test_eof; -+ _test_eof17: cs = 17; goto _test_eof; -+ _test_eof18: cs = 18; goto _test_eof; -+ _test_eof19: cs = 19; goto _test_eof; -+ _test_eof20: cs = 20; goto _test_eof; -+ _test_eof21: cs = 21; goto _test_eof; -+ _test_eof22: cs = 22; goto _test_eof; -+ _test_eof23: cs = 23; goto _test_eof; -+ _test_eof24: cs = 24; goto _test_eof; -+ _test_eof25: cs = 25; goto _test_eof; -+ _test_eof26: cs = 26; goto _test_eof; -+ _test_eof27: cs = 27; goto _test_eof; -+ _test_eof28: cs = 28; goto _test_eof; -+ _test_eof29: cs = 29; goto _test_eof; -+ _test_eof30: cs = 30; goto _test_eof; -+ _test_eof31: cs = 31; goto _test_eof; -+ _test_eof32: cs = 32; goto _test_eof; -+ _test_eof33: cs = 33; goto _test_eof; -+ _test_eof34: cs = 34; goto _test_eof; -+ _test_eof35: cs = 35; goto _test_eof; -+ _test_eof36: cs = 36; goto _test_eof; -+ _test_eof37: cs = 37; goto _test_eof; -+ _test_eof38: cs = 38; goto _test_eof; -+ _test_eof39: cs = 39; goto _test_eof; -+ _test_eof40: cs = 40; goto _test_eof; -+ _test_eof41: cs = 41; goto _test_eof; -+ _test_eof42: cs = 42; goto _test_eof; -+ _test_eof43: cs = 43; goto _test_eof; -+ _test_eof44: cs = 44; goto _test_eof; -+ _test_eof45: cs = 45; goto _test_eof; -+ _test_eof46: cs = 46; goto _test_eof; -+ _test_eof47: cs = 47; goto _test_eof; -+ _test_eof48: cs = 48; goto _test_eof; -+ _test_eof49: cs = 49; goto _test_eof; -+ _test_eof50: cs = 50; goto _test_eof; -+ _test_eof51: cs = 51; goto _test_eof; -+ _test_eof52: cs = 52; goto _test_eof; -+ _test_eof53: cs = 53; goto _test_eof; -+ _test_eof54: cs = 54; goto _test_eof; -+ _test_eof55: cs = 55; goto _test_eof; -+ _test_eof56: cs = 56; goto _test_eof; -+ _test_eof57: cs = 57; goto _test_eof; -+ _test_eof58: cs = 58; goto _test_eof; -+ _test_eof59: cs = 59; goto _test_eof; -+ _test_eof60: cs = 60; goto _test_eof; -+ _test_eof61: cs = 61; goto _test_eof; -+ _test_eof62: cs = 62; goto _test_eof; -+ _test_eof63: cs = 63; goto _test_eof; -+ _test_eof64: cs = 64; goto _test_eof; -+ _test_eof65: cs = 65; goto _test_eof; -+ _test_eof66: cs = 66; goto _test_eof; ++ switch( (*p) ) { ++ case 9: goto tr91; ++ case 32: goto tr91; ++ } ++ if ( (*p) < 65 ) { ++ if ( 48 <= (*p) && (*p) <= 58 ) ++ goto st66; ++ } else if ( (*p) > 70 ) { ++ if ( 97 <= (*p) && (*p) <= 102 ) ++ goto st66; ++ } else ++ goto st66; ++ goto tr2; ++ } ++ _test_eof67: cs = 67; goto _test_eof; ++ _test_eof1: cs = 1; goto _test_eof; ++ _test_eof2: cs = 2; goto _test_eof; ++ _test_eof3: cs = 3; goto _test_eof; ++ _test_eof4: cs = 4; goto _test_eof; ++ _test_eof5: cs = 5; goto _test_eof; ++ _test_eof6: cs = 6; goto _test_eof; ++ _test_eof7: cs = 7; goto _test_eof; ++ _test_eof8: cs = 8; goto _test_eof; ++ _test_eof9: cs = 9; goto _test_eof; ++ _test_eof10: cs = 10; goto _test_eof; ++ _test_eof11: cs = 11; goto _test_eof; ++ _test_eof12: cs = 12; goto _test_eof; ++ _test_eof13: cs = 13; goto _test_eof; ++ _test_eof14: cs = 14; goto _test_eof; ++ _test_eof15: cs = 15; goto _test_eof; ++ _test_eof16: cs = 16; goto _test_eof; ++ _test_eof17: cs = 17; goto _test_eof; ++ _test_eof18: cs = 18; goto _test_eof; ++ _test_eof19: cs = 19; goto _test_eof; ++ _test_eof20: cs = 20; goto _test_eof; ++ _test_eof21: cs = 21; goto _test_eof; ++ _test_eof22: cs = 22; goto _test_eof; ++ _test_eof23: cs = 23; goto _test_eof; ++ _test_eof24: cs = 24; goto _test_eof; ++ _test_eof25: cs = 25; goto _test_eof; ++ _test_eof26: cs = 26; goto _test_eof; ++ _test_eof27: cs = 27; goto _test_eof; ++ _test_eof28: cs = 28; goto _test_eof; ++ _test_eof29: cs = 29; goto _test_eof; ++ _test_eof30: cs = 30; goto _test_eof; ++ _test_eof31: cs = 31; goto _test_eof; ++ _test_eof32: cs = 32; goto _test_eof; ++ _test_eof33: cs = 33; goto _test_eof; ++ _test_eof34: cs = 34; goto _test_eof; ++ _test_eof35: cs = 35; goto _test_eof; ++ _test_eof36: cs = 36; goto _test_eof; ++ _test_eof37: cs = 37; goto _test_eof; ++ _test_eof38: cs = 38; goto _test_eof; ++ _test_eof39: cs = 39; goto _test_eof; ++ _test_eof40: cs = 40; goto _test_eof; ++ _test_eof41: cs = 41; goto _test_eof; ++ _test_eof42: cs = 42; goto _test_eof; ++ _test_eof43: cs = 43; goto _test_eof; ++ _test_eof44: cs = 44; goto _test_eof; ++ _test_eof45: cs = 45; goto _test_eof; ++ _test_eof46: cs = 46; goto _test_eof; ++ _test_eof47: cs = 47; goto _test_eof; ++ _test_eof48: cs = 48; goto _test_eof; ++ _test_eof49: cs = 49; goto _test_eof; ++ _test_eof50: cs = 50; goto _test_eof; ++ _test_eof51: cs = 51; goto _test_eof; ++ _test_eof52: cs = 52; goto _test_eof; ++ _test_eof53: cs = 53; goto _test_eof; ++ _test_eof54: cs = 54; goto _test_eof; ++ _test_eof55: cs = 55; goto _test_eof; ++ _test_eof56: cs = 56; goto _test_eof; ++ _test_eof57: cs = 57; goto _test_eof; ++ _test_eof58: cs = 58; goto _test_eof; ++ _test_eof59: cs = 59; goto _test_eof; ++ _test_eof60: cs = 60; goto _test_eof; ++ _test_eof61: cs = 61; goto _test_eof; ++ _test_eof62: cs = 62; goto _test_eof; ++ _test_eof63: cs = 63; goto _test_eof; ++ _test_eof64: cs = 64; goto _test_eof; ++ _test_eof65: cs = 65; goto _test_eof; ++ _test_eof66: cs = 66; goto _test_eof; + -+ _test_eof: {} -+ if ( p == eof ) -+ { -+ switch ( cs ) { -+ case 1: -+ case 2: -+ case 3: -+ case 4: -+ case 5: -+ case 6: -+ case 7: -+ case 8: -+ case 9: -+ case 10: -+ case 11: -+ case 12: -+ case 13: -+ case 14: -+ case 15: -+ case 16: -+ case 17: -+ case 18: -+ case 19: -+ case 20: -+ case 21: -+ case 22: -+ case 23: -+ case 24: -+ case 25: -+ case 26: -+ case 27: -+ case 28: -+ case 29: -+ case 30: -+ case 31: -+ case 32: -+ case 33: -+ case 34: -+ case 35: -+ case 36: -+ case 37: -+ case 38: -+ case 39: -+ case 40: -+ case 41: -+ case 42: -+ case 43: -+ case 44: -+ case 45: -+ case 46: -+ case 47: -+ case 48: -+ case 49: -+ case 50: -+ case 51: -+ case 52: -+ case 53: -+ case 54: -+ case 55: -+ case 56: -+ case 57: -+ case 58: -+ case 59: -+ case 60: -+ case 61: -+ case 62: -+ case 63: -+ case 64: -+ case 65: -+ case 66: ++ _test_eof: {} ++ if ( p == eof ) ++ { ++ switch ( cs ) { ++ case 1: ++ case 2: ++ case 3: ++ case 4: ++ case 5: ++ case 6: ++ case 7: ++ case 8: ++ case 9: ++ case 10: ++ case 11: ++ case 12: ++ case 13: ++ case 14: ++ case 15: ++ case 16: ++ case 17: ++ case 18: ++ case 19: ++ case 20: ++ case 21: ++ case 22: ++ case 23: ++ case 24: ++ case 25: ++ case 26: ++ case 27: ++ case 28: ++ case 29: ++ case 30: ++ case 31: ++ case 32: ++ case 33: ++ case 34: ++ case 35: ++ case 36: ++ case 37: ++ case 38: ++ case 39: ++ case 40: ++ case 41: ++ case 42: ++ case 43: ++ case 44: ++ case 45: ++ case 46: ++ case 47: ++ case 48: ++ case 49: ++ case 50: ++ case 51: ++ case 52: ++ case 53: ++ case 54: ++ case 55: ++ case 56: ++ case 57: ++ case 58: ++ case 59: ++ case 60: ++ case 61: ++ case 62: ++ case 63: ++ case 64: ++ case 65: ++ case 66: +#line 118 "cfg_parser.rl" -+ { ++ { + if(p == eof) + log_printf(ERROR, "config file syntax error: unexpected end of file"); + else @@ -1308,13 +1308,13 @@ diff -Nur tcpproxy-1.1.orig/src/cfg_parser.c tcpproxy-1.1/src/cfg_parser.c + + {cs = (cfg_parser_error); goto _again;} + } -+ break; ++ break; +#line 1309 "cfg_parser.c" -+ } -+ } ++ } ++ } + -+ _out: {} -+ } ++ _out: {} ++ } + +#line 178 "cfg_parser.rl" + diff --git a/net/tgt/Makefile b/net/tgt/Makefile index 874a9309c..77e518005 100644 --- a/net/tgt/Makefile +++ b/net/tgt/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2012-2014 OpenWrt.org +# Copyright (C) 2012-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tgt PKG_VERSION:=1.0.53 PKG_REV:=9764e0afd9a7115e356fc85569a780f9003c4eac -PKG_RELEASE:=3 +PKG_RELEASE:=4 PKG_USE_MIPS16:=0 PKG_SOURCE_PROTO:=git diff --git a/net/tgt/patches/100-musl-compat.patch b/net/tgt/patches/100-musl-compat.patch new file mode 100644 index 000000000..4d84955b4 --- /dev/null +++ b/net/tgt/patches/100-musl-compat.patch @@ -0,0 +1,36 @@ +--- a/usr/tgtd.h ++++ b/usr/tgtd.h +@@ -9,6 +9,10 @@ + #include + #endif + ++#ifndef __WORDSIZE ++#include ++#endif ++ + struct concat_buf; + + #define NR_SCSI_OPCODES 256 +--- a/usr/util.h ++++ b/usr/util.h +@@ -16,6 +16,10 @@ + #include + #include + ++#ifndef __WORDSIZE ++#include ++#endif ++ + #include "be_byteshift.h" + + #define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y)) +--- a/usr/libssc.c ++++ b/usr/libssc.c +@@ -23,6 +23,7 @@ + #include + #include + #include ++#include + #include "bs_ssc.h" + #include "ssc.h" + #include "be_byteshift.h" diff --git a/net/tinc/Makefile b/net/tinc/Makefile index 0656ec983..1facb1e13 100644 --- a/net/tinc/Makefile +++ b/net/tinc/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tinc PKG_VERSION:=1.0.25 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.tinc-vpn.org/packages diff --git a/net/tinc/patches/100-musl-compat.patch b/net/tinc/patches/100-musl-compat.patch new file mode 100644 index 000000000..e0910b150 --- /dev/null +++ b/net/tinc/patches/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/src/have.h ++++ b/src/have.h +@@ -196,4 +196,8 @@ + #include + #endif + ++#ifdef HAVE_LINUX_IF_TUN_H ++#include ++#endif ++ + #endif /* __TINC_SYSTEM_H__ */ diff --git a/net/tor/Makefile b/net/tor/Makefile index 6ffcf43bd..d042ffbcc 100644 --- a/net/tor/Makefile +++ b/net/tor/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tor -PKG_VERSION:=0.2.5.10 +PKG_VERSION:=0.2.5.12 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://www.torproject.org/dist \ https://archive.torproject.org/tor-package-archive -PKG_MD5SUM:=4bde375229a7a7f77c0596ae05556527 +PKG_MD5SUM:=89745069a7efb7aafd01ae263bd0fe5c PKG_MAINTAINER:=Hauke Mehrtens PKG_LICENSE_FILES:=LICENSE @@ -41,7 +41,7 @@ endef define Package/tor $(call Package/tor/Default) TITLE:=An anonymous Internet communication system - DEPENDS:=+libevent2 +libopenssl +libpthread +librt +SSP_SUPPORT:libssp + DEPENDS:=+libevent2 +libopenssl +libpthread +librt endef define Package/tor/description @@ -82,7 +82,8 @@ CONFIGURE_ARGS += \ --with-libminiupnpc-dir="$(STAGING_DIR)/usr" \ --enable-nat-pmp \ --with-libnatpmp-dir="$(STAGING_DIR)/usr" \ - --disable-asciidoc + --disable-asciidoc \ + --disable-seccomp ifneq ($(CONFIG_SSP_SUPPORT),y) CONFIGURE_ARGS += \ diff --git a/net/tor/patches/001-torrc.patch b/net/tor/patches/001-torrc.patch index 988cb8e5a..e295219f1 100644 --- a/net/tor/patches/001-torrc.patch +++ b/net/tor/patches/001-torrc.patch @@ -14,7 +14,7 @@ ## The port on which Tor will listen for local connections from Tor ## controller applications, as documented in control-spec.txt. -@@ -187,3 +187,4 @@ +@@ -190,3 +190,4 @@ ## address manually to your friends, uncomment this line: #PublishServerDescriptor 0 diff --git a/net/transmission/Makefile b/net/transmission/Makefile index df74fd566..8b50cd69c 100644 --- a/net/transmission/Makefile +++ b/net/transmission/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=transmission PKG_VERSION:=2.84 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://download-origin.transmissionbt.com/files/ http://mirrors.m0k.org/transmission/files diff --git a/net/transmission/files/transmission.config b/net/transmission/files/transmission.config index a8fd56d9b..31e2d5af4 100644 --- a/net/transmission/files/transmission.config +++ b/net/transmission/files/transmission.config @@ -2,6 +2,7 @@ config transmission option enabled 0 option config_dir '/tmp/transmission' #option user 'nobody' + option mem_percentage 50 option alt_speed_down 50 option alt_speed_enabled false option alt_speed_time_begin 540 diff --git a/net/transmission/files/transmission.init b/net/transmission/files/transmission.init index 669e710ec..535ace8bb 100644 --- a/net/transmission/files/transmission.init +++ b/net/transmission/files/transmission.init @@ -1,7 +1,9 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2010-2012 OpenWrt.org +# Copyright (C) 2010-2015 OpenWrt.org START=99 +USE_PROCD=1 + LIST_SEP=" " @@ -40,14 +42,25 @@ section_enabled() { [ $enabled -gt 0 ] } -start_instance() { - local s="$1" +transmission() { + local cfg="$1" + local USE + local user + local download_dir + local mem_percentage section_enabled "$section" || return 1 - config_get config_dir "$s" 'config_dir' '/var/etc/transmission' - config_get user "$s" 'user' + config_get config_dir "$cfg" 'config_dir' '/var/etc/transmission' + config_get user "$cfg" 'user' + config_get download_dir "$cfg" 'download_dir' '/var/etc/transmission' + config_get mem_percentage "$cfg" 'mem_percentage' '50' + + local MEM=$(sed -ne 's!^MemTotal:[[:space:]]*\([0-9]*\) kB$!\1!p' /proc/meminfo) + if test "$MEM" -gt 1;then + USE=$(expr $MEM \* $mem_percentage \* 10) + fi config_file="$config_dir/settings.json" [ -d $config_dir ] || { @@ -58,7 +71,7 @@ start_instance() { echo "{" > $config_file - append_params "$s" \ + append_params "$cfg" \ alt_speed_down alt_speed_enabled alt_speed_time_begin alt_speed_time_day \ alt_speed_time_enabled alt_speed_time_end alt_speed_up blocklist_enabled \ cache_size_mb download_queue_enabled download_queue_size \ @@ -76,7 +89,7 @@ start_instance() { umask upload_slots_per_torrent utp_enabled scrape_paused_torrents \ watch_dir_enabled - append_params_quotes "$s" \ + append_params_quotes "$cfg" \ blocklist_url bind_address_ipv4 bind_address_ipv6 download_dir incomplete_dir \ peer_congestion_algorithm peer_socket_tos rpc_bind_address rpc_password rpc_url \ rpc_username rpc_whitelist script_torrent_done_filename watch_dir @@ -84,28 +97,25 @@ start_instance() { echo "\""invalid-key"\": false" >> $config_file echo "}" >> $config_file - SERVICE_UID="$user" \ - service_start /usr/bin/transmission-daemon -g $config_dir -} - -stop_instance() { - local s="$1" - local user - - section_enabled "$section" || return 1 - - config_get user "$s" 'user' - - SERVICE_UID="$user" \ - service_stop /usr/bin/transmission-daemon + procd_open_instance + procd_set_param command /usr/bin/transmission-daemon -g $config_dir -f + procd_set_param respawn retry=60 + procd_set_param user "$user" + if test -z "$USE";then + procd_set_param limits core="0 0" + else + procd_set_param limits core="0 0" as="$USE $USE" + logger -t transmission "Starting with $USE virt mem" + fi + + procd_add_jail transmission log + procd_add_jail_mount $config_file + procd_add_jail_mount_rw $download_dir + procd_close_instance } -start() { +start_service() { config_load 'transmission' - config_foreach start_instance 'transmission' + config_foreach transmission 'transmission' } -stop() { - config_load 'transmission' - config_foreach stop_instance 'transmission' -} diff --git a/net/transmission/patches/010_libtransmission_fallocate64_eglibc.patch b/net/transmission/patches/010_libtransmission_fallocate64_eglibc.patch index d4f82fc2c..e46a1ad98 100644 --- a/net/transmission/patches/010_libtransmission_fallocate64_eglibc.patch +++ b/net/transmission/patches/010_libtransmission_fallocate64_eglibc.patch @@ -1,12 +1,14 @@ ---- a/libtransmission/fdlimit.c 2014-07-01 20:08:59.000000000 +0300 -+++ b/libtransmission/fdlimit.c 2014-07-13 13:30:17.000000000 +0300 -@@ -22,7 +22,8 @@ +--- a/libtransmission/fdlimit.c ++++ b/libtransmission/fdlimit.c +@@ -22,11 +22,6 @@ #include #endif - + -#ifdef HAVE_FALLOCATE64 -+/* no need to define fallocate64 in glibc/eglibc case */ -+#if defined(__UCLIBC__) && (HAVE_FALLOCATE64) - /* FIXME can't find the right #include voodoo to pick up the declaration.. */ - extern int fallocate64 (int fd, int mode, uint64_t offset, uint64_t len); +- /* FIXME can't find the right #include voodoo to pick up the declaration.. */ +- extern int fallocate64 (int fd, int mode, uint64_t offset, uint64_t len); +-#endif +- + #ifdef HAVE_XFS_XFS_H + #include #endif diff --git a/net/transmission/patches/030-fix-musl-build.patch b/net/transmission/patches/030-fix-musl-build.patch new file mode 100644 index 000000000..badf67317 --- /dev/null +++ b/net/transmission/patches/030-fix-musl-build.patch @@ -0,0 +1,34 @@ +Index: transmission-2.84/libtransmission/bitfield.c +=================================================================== +--- transmission-2.84.orig/libtransmission/bitfield.c ++++ transmission-2.84/libtransmission/bitfield.c +@@ -7,6 +7,8 @@ + * $Id: bitfield.c 14302 2014-06-29 01:42:38Z jordan $ + */ + ++#define __NEED_ssize_t ++ + #include + #include /* realloc () */ + #include /* memset */ +@@ -15,6 +17,7 @@ + #include "bitfield.h" + #include "utils.h" /* tr_new0 () */ + ++ + const tr_bitfield TR_BITFIELD_INIT = { NULL, 0, 0, 0, false, false }; + + /**** +Index: transmission-2.84/libtransmission/fdlimit.h +=================================================================== +--- transmission-2.84.orig/libtransmission/fdlimit.h ++++ transmission-2.84/libtransmission/fdlimit.h +@@ -11,6 +11,8 @@ + #error only libtransmission should #include this header. + #endif + ++#define __NEED_off_t ++ + #include "transmission.h" + #include "net.h" + diff --git a/net/udpxy/Makefile b/net/udpxy/Makefile index 8fc927645..7d94a99f3 100644 --- a/net/udpxy/Makefile +++ b/net/udpxy/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=udpxy -PKG_VERSION:=2014-10-27 -PKG_RELEASE:=$(PKG_SOURCE_VERSION) +PKG_SOURCE_VERSION:=c045a1e855a8033c5d70ab3e42271ba5636eb520 +PKG_VERSION:=2015-03-08-$(PKG_SOURCE_VERSION) +PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=git://github.com/pcherenkov/udpxy.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=c045a1e855a8033c5d70ab3e42271ba5636eb520 -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_MAINTAINER:=Álvaro Fernández Rojas PKG_LICENSE:=GPL-3.0 diff --git a/net/udpxy/patches/0001-fix-build-on-Mac-OS-X.patch b/net/udpxy/patches/0001-fix-build-on-Mac-OS-X.patch new file mode 100644 index 000000000..24f62e7e9 --- /dev/null +++ b/net/udpxy/patches/0001-fix-build-on-Mac-OS-X.patch @@ -0,0 +1,30 @@ +From 26f8177f799f3cf781ed89cb28f771da7ef22421 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= +Date: Thu, 5 Mar 2015 13:42:09 +0100 +Subject: [PATCH] fix build on Mac OS X +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Álvaro Fernández Rojas +--- + chipmunk/Makefile | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +--- a/chipmunk/Makefile ++++ b/chipmunk/Makefile +@@ -32,10 +32,13 @@ DEBUG_ON := -g + ALL_CFLAGS = -W -Wall -Werror --pedantic $(CFLAGS) + + SYSTEM=$(shell uname 2>/dev/null) +-ifneq (,$(filter $(SYSTEM),FreeBSD Darwin)) ++ifneq (,$(filter $(SYSTEM),FreeBSD)) + MAKE := gmake + GZIP := /usr/bin/gzip + endif ++ifneq (,$(filter $(SYSTEM),Darwin)) ++GZIP := /usr/bin/gzip ++endif + + BUILDFILE = BUILD + BUILDNO := `cat $(BUILDFILE)` diff --git a/net/ulogd/Makefile b/net/ulogd/Makefile index 0cca3e4d9..fdf3ad9ec 100644 --- a/net/ulogd/Makefile +++ b/net/ulogd/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ulogd PKG_VERSION:=2.0.4 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=ftp://ftp.netfilter.org/pub/ulogd/ \ @@ -50,6 +50,12 @@ define Package/ulogd-mod-dbi TITLE:=Output plugin for logging to a database using libdbi endef +define Package/ulogd-mod-json + $(call Package/ulogd/Default) + DEPENDS:=ulogd +jansson + TITLE:=JSON output plugin +endef + define Package/ulogd-mod-mysql $(call Package/ulogd/Default) DEPENDS:=ulogd +libmysqlclient @@ -118,6 +124,9 @@ PKG_CONFIG_DEPENDS:= \ CONFIG_PACKAGE_ulogd-mod-pgsql \ CONFIG_PACKAGE_ulogd-mod-sqlite \ +TARGET_CFLAGS += \ + -D_GNU_SOURCE \ + CONFIGURE_ARGS += \ --enable-nfacct \ --enable-nfct \ @@ -188,6 +197,7 @@ ULOGD_EXTRA_PLUGINS:= \ $(eval $(call BuildPackage,ulogd)) $(eval $(call BuildPlugin,dbi,output_DBI)) +$(eval $(call BuildPlugin,json,output_JSON)) $(eval $(call BuildPlugin,mysql,output_MYSQL)) $(eval $(call BuildPlugin,nfacct,inpflow_NFACCT)) $(eval $(call BuildPlugin,nfct,inpflow_NFCT)) diff --git a/net/ulogd/patches/100-musl-compat.patch b/net/ulogd/patches/100-musl-compat.patch new file mode 100644 index 000000000..2f1c29302 --- /dev/null +++ b/net/ulogd/patches/100-musl-compat.patch @@ -0,0 +1,57 @@ +--- a/src/ulogd.c ++++ b/src/ulogd.c +@@ -83,7 +83,7 @@ static char *ulogd_logfile = NULL; + static const char *ulogd_configfile = ULOGD_CONFIGFILE; + static const char *ulogd_pidfile = NULL; + static int ulogd_pidfile_fd = -1; +-static FILE syslog_dummy; ++static int ulogd_use_syslog = 0; + + static int info_mode = 0; + +@@ -427,7 +427,7 @@ void __ulogd_log(int level, char *file, + if (level < loglevel_ce.u.value) + return; + +- if (logfile == &syslog_dummy) { ++ if (ulogd_use_syslog) { + /* FIXME: this omits the 'file' string */ + va_start(ap, format); + vsyslog(ulogd2syslog_level(level), format, ap); +@@ -950,7 +950,7 @@ static int logfile_open(const char *name + logfile = stdout; + } else if (!strcmp(name, "syslog")) { + openlog("ulogd", LOG_PID, LOG_DAEMON); +- logfile = &syslog_dummy; ++ ulogd_use_syslog = 1; + } else { + logfile = fopen(ulogd_logfile, "a"); + if (!logfile) { +@@ -1240,7 +1240,7 @@ static void sigterm_handler(int signal) + unload_plugins(); + #endif + +- if (logfile != NULL && logfile != stdout && logfile != &syslog_dummy) { ++ if (logfile != NULL && logfile != stdout) { + fclose(logfile); + logfile = NULL; + } +@@ -1262,7 +1262,7 @@ static void signal_handler(int signal) + switch (signal) { + case SIGHUP: + /* reopen logfile */ +- if (logfile != stdout && logfile != &syslog_dummy) { ++ if (logfile != NULL && logfile != stdout) { + fclose(logfile); + logfile = fopen(ulogd_logfile, "a"); + if (!logfile) { +--- a/filter/raw2packet/ulogd_raw2packet_BASE.c ++++ b/filter/raw2packet/ulogd_raw2packet_BASE.c +@@ -42,6 +42,7 @@ + #include + #include + #include ++#include + #include + + enum input_keys { diff --git a/net/umurmur/Makefile b/net/umurmur/Makefile index d57e9e0f8..27254233e 100644 --- a/net/umurmur/Makefile +++ b/net/umurmur/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2014 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -7,16 +7,17 @@ include $(TOPDIR)/rules.mk PKG_NAME:=umurmur -PKG_VERSION:=0.2.15 +PKG_VERSION:=0.2.16 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_URL:=git://github.com/fatbob313/umurmur.git +PKG_SOURCE_URL:=git://github.com/umurmur/umurmur.git PKG_SOURCE_PROTO:=git -PKG_SOURCE_VERSION:=f66c0c3d630aaff1c4d589bc4d884067f00b6529 +PKG_SOURCE_VERSION:=0.2.16 PKG_INSTALL:=1 +PKG_FIXUP:=autoreconf PKG_MAINTAINER:=Martin Johansson PKG_LICENSE:=BSD-3-Clause @@ -70,11 +71,6 @@ define Build/Compile $(MAKE) -C $(PKG_BUILD_DIR)/src all endef -define Build/Configure - cd $(PKG_BUILD_DIR) && ./autogen.sh - $(call Build/Configure/Default) -endef - define Package/umurmur-openssl/conffiles /etc/umurmur.conf endef diff --git a/net/umurmur/patches/10-Add-compile-time-check-for-POLARSSL_VERSION_FEATURES.patch b/net/umurmur/patches/10-Add-compile-time-check-for-POLARSSL_VERSION_FEATURES.patch new file mode 100644 index 000000000..c8fcdc88a --- /dev/null +++ b/net/umurmur/patches/10-Add-compile-time-check-for-POLARSSL_VERSION_FEATURES.patch @@ -0,0 +1,17 @@ +diff --git a/src/ssli_polarssl.c b/src/ssli_polarssl.c +index a36ccb6..167637b 100644 +--- a/src/ssli_polarssl.c ++++ b/src/ssli_polarssl.c +@@ -225,8 +225,12 @@ void SSLi_init(void) + Log_fatal("Cannot open /dev/urandom"); + #endif + ++#ifdef POLARSSL_VERSION_FEATURES + version_get_string(verstring); + Log_info("PolarSSL library version %s initialized", verstring); ++#else ++ Log_info("PolarSSL library initialized"); ++#endif + } + + void SSLi_deinit(void) diff --git a/net/unbound/Makefile b/net/unbound/Makefile index a04aca633..bc54bb75f 100644 --- a/net/unbound/Makefile +++ b/net/unbound/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2010-2014 OpenWrt.org +# Copyright (C) 2010-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=unbound -PKG_VERSION:=1.5.1 +PKG_VERSION:=1.5.3 PKG_RELEASE:=1 PKG_LICENSE:=BSD-3-Clause @@ -17,7 +17,7 @@ PKG_MAINTAINER:=Michael Hanselmann PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.unbound.net/downloads -PKG_MD5SUM:=ed4c46476dcfb8a507cc08b1ba12a8f1 +PKG_MD5SUM:=1e95fdcbaaf5dc87432d898006a5eb13 PKG_BUILD_DEPENDS:=libexpat PKG_BUILD_PARALLEL:=1 diff --git a/net/unbound/patches/001-conf.patch b/net/unbound/patches/001-conf.patch index 0d53615e2..a795532c0 100644 --- a/net/unbound/patches/001-conf.patch +++ b/net/unbound/patches/001-conf.patch @@ -1,3 +1,5 @@ +diff --git a/doc/example.conf.in b/doc/example.conf.in +index 60ed5c8..abd85f9 100644 --- a/doc/example.conf.in +++ b/doc/example.conf.in @@ -38,6 +38,8 @@ server: @@ -66,7 +68,7 @@ # the time to live (TTL) value lower bound, in seconds. Default 0. # If more than an hour could easily give trouble due to stale data. -@@ -143,9 +154,11 @@ server: +@@ -146,9 +157,11 @@ server: # the number of slabs must be a power of 2. # more slabs reduce lock contention, but fragment memory usage. # infra-cache-slabs: 4 @@ -78,7 +80,7 @@ # Enable IPv4, "yes" or "no". # do-ip4: yes -@@ -178,6 +191,8 @@ server: +@@ -181,6 +194,8 @@ server: # access-control: ::0/0 refuse # access-control: ::1 allow # access-control: ::ffff:127.0.0.1 allow @@ -87,7 +89,7 @@ # if given, a chroot(2) is done to the given directory. # i.e. you can chroot to the working directory, for example, -@@ -208,6 +223,7 @@ server: +@@ -211,6 +226,7 @@ server: # and the given username is assumed. Default is user "unbound". # If you give "" no privileges are dropped. # username: "@UNBOUND_USERNAME@" @@ -95,7 +97,7 @@ # the working directory. The relative files in this config are # relative to this directory. If you give "" the working directory -@@ -230,10 +246,12 @@ server: +@@ -233,10 +249,12 @@ server: # the pid file. Can be an absolute path outside of chroot/work dir. # pidfile: "@UNBOUND_PIDFILE@" @@ -108,7 +110,7 @@ # enable to not answer id.server and hostname.bind queries. # hide-identity: no -@@ -256,12 +274,15 @@ server: +@@ -259,12 +277,15 @@ server: # positive value: fetch that many targets opportunistically. # Enclose the list of numbers between quotes (""). # target-fetch-policy: "3 2 1 0 0" @@ -124,7 +126,7 @@ # Harden against out of zone rrsets, to avoid spoofing attempts. # harden-glue: yes -@@ -342,7 +363,7 @@ server: +@@ -345,7 +366,7 @@ server: # you start unbound (i.e. in the system boot scripts). And enable: # Please note usage of unbound-anchor root anchor is at your own risk # and under the terms of our LICENSE (see that file in the source). @@ -133,7 +135,7 @@ # File with DLV trusted keys. Same format as trust-anchor-file. # There can be only one DLV configured, it is trusted from root down. -@@ -428,15 +449,18 @@ server: +@@ -431,15 +452,18 @@ server: # the amount of memory to use for the key cache. # plain value in bytes or you can append k, m or G. default is "4Mb". # key-cache-size: 4m @@ -149,6 +151,6 @@ # plain value in bytes or you can append k, m or G. default is "1Mb". # neg-cache-size: 1m + neg-cache-size: 10k - + # By default, for a number of zones a small default 'nothing here' # reply is built-in. Query traffic is thus blocked. If you diff --git a/net/usbip/Makefile b/net/usbip/Makefile new file mode 100644 index 000000000..49130574f --- /dev/null +++ b/net/usbip/Makefile @@ -0,0 +1,108 @@ +# +# Copyright (C) 2010-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk +include $(INCLUDE_DIR)/kernel.mk + +PKG_NAME:=usbip +PKG_RELEASE:=5 +PKG_LICENSE:=GPL-2.0 + +# Since kernel 2.6.39.1 userspace tools are inside the kernel tree +# Package Automatic match version in kernel +# MD5SUM is not useful kernel package already check it +PKG_VERSION:=$(shell sed -n -e '/^AC_INIT/s/.*\[\([[:digit:]\.]*\)\].*/\1/gp' $(LINUX_DIR)/tools/usb/usbip/configure.ac) +PKG_SOURCE:= +PKG_SOURCE_URL:= +PKG_MD5SUM:=unknown + +PKG_MAINTAINER:=Nuno Goncalves + +PATCH_DIR:=./patches-$(PKG_VERSION) + +define prepare_source_directory + rm -rf $(PKG_BUILD_DIR) + $(CP) $(LINUX_DIR)/tools/usb/usbip $(PKG_BUILD_DIR) +endef +Hooks/Prepare/Pre += prepare_source_directory + +PKG_BUILD_DEPENDS:=udev +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk + +define Package/usbip/Common + TITLE:=USB-over-IP + URL:=http://usbip.sourceforge.net/ + DEPENDS:=@USB_SUPPORT +endef + +define Package/usbip/Default + $(call Package/usbip/Common) + SECTION:=net + CATEGORY:=Network +endef + +define Package/usbip + $(call Package/usbip/Default) + TITLE+= (common) + DEPENDS+= +libwrap +kmod-usbip +udev +endef + +define Package/usbip-client + $(call Package/usbip/Default) + TITLE+= (client) + DEPENDS+= usbip +kmod-usbip-client +endef + +define Package/usbip-server + $(call Package/usbip/Default) + TITLE+= (server) + DEPENDS+= usbip +kmod-usbip-server +endef + +CONFIGURE_PATH:=. +MAKE_PATH:=. +LIBTOOL_PATHS:=. +MAKE_FLAGS+=CFLAGS="-Wno-implicit-function-declaration" + +define Build/Configure + (cd $(PKG_BUILD_DIR); ./autogen.sh ); + $(call Build/Configure/Default) +endef + +CFLAGS+="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" + +define Download/usb.ids + URL:=http://www.linux-usb.org/ + FILE:=usb.ids + MD5SUM:= +endef + +define Package/usbip/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libusbip.so.* $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/share/hwdata + $(CP) $(DL_DIR)/usb.ids $(1)/usr/share/hwdata/ +endef + +define Package/usbip-client/install + $(INSTALL_DIR) $(1)/usr/sbin + $(CP) $(PKG_INSTALL_DIR)/usr/sbin/usbip $(1)/usr/sbin/ +endef + +define Package/usbip-server/install + $(INSTALL_DIR) $(1)/usr/sbin + $(CP) $(PKG_INSTALL_DIR)/usr/sbin/usbipd $(1)/usr/sbin/ +endef + +$(eval $(call Download,usb.ids)) +$(eval $(call BuildPackage,usbip)) +$(eval $(call BuildPackage,usbip-client)) +$(eval $(call BuildPackage,usbip-server)) diff --git a/net/usbip/patches-2.0/100-musl-compat.patch b/net/usbip/patches-2.0/100-musl-compat.patch new file mode 100644 index 000000000..a64678cb8 --- /dev/null +++ b/net/usbip/patches-2.0/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/src/usbipd.c ++++ b/src/usbipd.c +@@ -453,7 +453,7 @@ static void set_signal(void) + sigaction(SIGTERM, &act, NULL); + sigaction(SIGINT, &act, NULL); + act.sa_handler = SIG_IGN; +- sigaction(SIGCLD, &act, NULL); ++ sigaction(SIGCHLD, &act, NULL); + } + + static const char *pid_file; diff --git a/net/usbip/patches/001-upstream_svn_r99.diff b/net/usbip/patches/001-upstream_svn_r99.diff new file mode 100644 index 000000000..aa193e136 --- /dev/null +++ b/net/usbip/patches/001-upstream_svn_r99.diff @@ -0,0 +1,11 @@ +Index: trunk/src/cmd/Makefile.am +=================================================================== +--- trunk/src/cmd/Makefile.am (revision 98) ++++ trunk/src/cmd/Makefile.am (revision 99) +@@ -17,5 +17,5 @@ + INCLUDES = -I$(top_srcdir)/lib + LDADD = ../lib/libusbip.la @PACKAGE_LIBS@ + EXTRA_CFLAGS = @EXTRA_CFLAGS@ +-AM_CFLAGS = -Wall -W -Wstrict-prototypes -std=gnu99 $(EXTRA_CFLAGS) @PACKAGE_CFLAGS@ ++AM_CFLAGS = -Wall -W -Wstrict-prototypes -std=gnu99 $(EXTRA_CFLAGS) @PACKAGE_CFLAGS@ -DUSBIDS_FILE='"@USBIDS_DIR@/usb.ids"' + diff --git a/net/usbip/patches/002-upstream_svn_r152.patch b/net/usbip/patches/002-upstream_svn_r152.patch new file mode 100644 index 000000000..e7135a66c --- /dev/null +++ b/net/usbip/patches/002-upstream_svn_r152.patch @@ -0,0 +1,229 @@ +--- a/drivers/head/stub_dev.c ++++ b/drivers/head/stub_dev.c +@@ -398,7 +398,11 @@ static int stub_probe(struct usb_interfa + { + struct usb_device *udev = interface_to_usbdev(interface); + struct stub_device *sdev = NULL; ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30) + char *udev_busid = interface->dev.parent->bus_id; ++#else ++ char *udev_busid = dev_name(interface->dev.parent); ++#endif + int err = 0; + + udbg("Enter\n"); +--- a/drivers/head/stub_main.c ++++ b/drivers/head/stub_main.c +@@ -252,18 +252,17 @@ static int __init usb_stub_init(void) + return -ENOMEM; + } + ++ info(DRIVER_DESC "" DRIVER_VERSION); ++ ++ memset(busid_table, 0, sizeof(busid_table)); ++ spin_lock_init(&busid_table_lock); ++ + ret = usb_register(&stub_driver); + if (ret) { + uerr("usb_register failed %d\n", ret); + return ret; + } + +- +- info(DRIVER_DESC "" DRIVER_VERSION); +- +- memset(busid_table, 0, sizeof(busid_table)); +- spin_lock_init(&busid_table_lock); +- + ret = driver_create_file(&stub_driver.drvwrap.driver, &driver_attr_match_busid); + + if (ret) { +--- a/drivers/head/stub_rx.c ++++ b/drivers/head/stub_rx.c +@@ -159,7 +159,11 @@ static int tweak_set_configuration_cmd(s + * A user may need to set a special configuration value before + * exporting the device. + */ ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30) + uinfo("set_configuration (%d) to %s\n", config, urb->dev->dev.bus_id); ++#else ++ uinfo("set_configuration (%d) to %s\n", config, dev_name(&urb->dev->dev)); ++#endif + uinfo("but, skip!\n"); + + return 0; +@@ -177,7 +181,11 @@ static int tweak_reset_device_cmd(struct + value = le16_to_cpu(req->wValue); + index = le16_to_cpu(req->wIndex); + ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30) + uinfo("reset_device (port %d) to %s\n", index, urb->dev->dev.bus_id); ++#else ++ uinfo("reset_device (port %d) to %s\n", index, dev_name(&urb->dev->dev)); ++#endif + + /* all interfaces should be owned by usbip driver, so just reset it. */ + ret = usb_lock_device_for_reset(urb->dev, NULL); +@@ -187,7 +195,11 @@ static int tweak_reset_device_cmd(struct + } + + /* try to reset the device */ +- ret = usb_reset_composite_device(urb->dev, NULL); ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27) ++ ret = usb_reset_composite_device(urb->dev, NULL); ++#else ++ ret = usb_reset_device(urb->dev); ++#endif + if (ret < 0) + uerr("device reset\n"); + +--- a/drivers/head/usbip_common.c ++++ b/drivers/head/usbip_common.c +@@ -55,10 +55,7 @@ static ssize_t show_flag(struct device * + static ssize_t store_flag(struct device *dev, struct device_attribute *attr, + const char *buf, size_t count) + { +- unsigned long flag; +- +- sscanf(buf, "%lx", &flag); +- usbip_debug_flag = flag; ++ sscanf(buf, "%lx", &usbip_debug_flag); + + return count; + } +@@ -390,7 +387,7 @@ int usbip_thread(void *param) + unlock_kernel(); + + /* srv.rb must wait for rx_thread starting */ +- complete(&ut->thread_done); ++ complete(&ut->thread_started); + + /* start of while loop */ + ut->loop_ops(ut); +@@ -403,15 +400,21 @@ int usbip_thread(void *param) + + void usbip_start_threads(struct usbip_device *ud) + { ++ + /* + * threads are invoked per one device (per one connection). + */ ++ INIT_COMPLETION(ud->tcp_rx.thread_started); ++ INIT_COMPLETION(ud->tcp_tx.thread_started); ++ INIT_COMPLETION(ud->tcp_rx.thread_done); ++ INIT_COMPLETION(ud->tcp_tx.thread_done); ++ + kernel_thread((int(*)(void *))usbip_thread, (void *)&ud->tcp_rx, 0); + kernel_thread((int(*)(void *))usbip_thread, (void *)&ud->tcp_tx, 0); + + /* confirm threads are starting */ +- wait_for_completion(&ud->tcp_rx.thread_done); +- wait_for_completion(&ud->tcp_tx.thread_done); ++ wait_for_completion(&ud->tcp_rx.thread_started); ++ wait_for_completion(&ud->tcp_tx.thread_started); + } + EXPORT_SYMBOL(usbip_start_threads); + +@@ -436,6 +439,7 @@ void usbip_task_init(struct usbip_task * + void (*loop_ops)(struct usbip_task *)) + { + ut->thread = NULL; ++ init_completion(&ut->thread_started); + init_completion(&ut->thread_done); + ut->name = name; + ut->loop_ops = loop_ops; +--- a/drivers/head/usbip_event.c ++++ b/drivers/head/usbip_event.c +@@ -38,7 +38,7 @@ void usbip_start_eh(struct usbip_device + + kernel_thread((int(*)(void *)) usbip_thread, (void *) eh, 0); + +- wait_for_completion(&eh->thread_done); ++ wait_for_completion(&eh->thread_started); + } + EXPORT_SYMBOL(usbip_start_eh); + +--- a/drivers/head/vhci_hcd.c ++++ b/drivers/head/vhci_hcd.c +@@ -58,7 +58,7 @@ static void vhci_stop(struct usb_hcd *hc + static int vhci_get_frame_number(struct usb_hcd *hcd); + + static const char driver_name[] = "vhci_hcd"; +-static const char driver_desc[] = "USB/IP Virtual Host Contoroller"; ++static const char driver_desc[] = "USB/IP Virtual Host Controller"; + + + +@@ -416,14 +416,6 @@ static int vhci_hub_control(struct usb_h + case USB_PORT_FEAT_SUSPEND: + dbg_vhci_rh(" SetPortFeature: USB_PORT_FEAT_SUSPEND\n"); + uerr(" not yet\n"); +-#if 0 +- dum->port_status[rhport] |= (1 << USB_PORT_FEAT_SUSPEND); +- if (dum->driver->suspend) { +- spin_unlock (&dum->lock); +- dum->driver->suspend (&dum->gadget); +- spin_lock (&dum->lock); +- } +-#endif + break; + case USB_PORT_FEAT_RESET: + dbg_vhci_rh(" SetPortFeature: USB_PORT_FEAT_RESET\n"); +@@ -432,12 +424,6 @@ static int vhci_hub_control(struct usb_h + dum->port_status[rhport] &= ~(USB_PORT_STAT_ENABLE + | USB_PORT_STAT_LOW_SPEED + | USB_PORT_STAT_HIGH_SPEED); +-#if 0 +- if (dum->driver) { +- dev_dbg (hardware, "disconnect\n"); +- stop_activity (dum, dum->driver); +- } +-#endif + + /* FIXME test that code path! */ + } +@@ -1060,7 +1046,7 @@ static int vhci_hcd_probe(struct platfor + struct usb_hcd *hcd; + int ret; + +- uinfo("proving...\n"); ++ uinfo("probing...\n"); + + dbg_vhci_hc("name %s id %d\n", pdev->name, pdev->id); + +@@ -1076,7 +1062,11 @@ static int vhci_hcd_probe(struct platfor + * Allocate and initialize hcd. + * Our private data is also allocated automatically. + */ ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30) + hcd = usb_create_hcd(&vhci_hc_driver, &pdev->dev, pdev->dev.bus_id); ++#else ++ hcd = usb_create_hcd(&vhci_hc_driver, &pdev->dev, dev_name(&pdev->dev)); ++#endif + if (!hcd) { + uerr("create hcd failed\n"); + return -ENOMEM; +--- a/drivers/head/vhci_sysfs.c ++++ b/drivers/head/vhci_sysfs.c +@@ -123,7 +123,11 @@ static ssize_t show_status(struct device + out += sprintf(out, "%03u %08x ", + vdev->speed, vdev->devid); + out += sprintf(out, "%16p ", vdev->ud.tcp_socket); ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30) + out += sprintf(out, "%s", vdev->udev->dev.bus_id); ++#else ++ out += sprintf(out, "%s", dev_name(&vdev->udev->dev)); ++#endif + + } else + out += sprintf(out, "000 000 000 0000000000000000 0-0"); +--- a/drivers/head/usbip_common.h ++++ b/drivers/head/usbip_common.h +@@ -300,6 +300,7 @@ struct usbip_device; + + struct usbip_task { + struct task_struct *thread; ++ struct completion thread_started; + struct completion thread_done; + char *name; + void (*loop_ops)(struct usbip_task *); diff --git a/net/vnstat/patches/100-musl-compat.patch b/net/vnstat/patches/100-musl-compat.patch new file mode 100644 index 000000000..05123899b --- /dev/null +++ b/net/vnstat/patches/100-musl-compat.patch @@ -0,0 +1,10 @@ +--- a/src/common.h ++++ b/src/common.h +@@ -22,6 +22,7 @@ + #include + #include + #include ++#include + + #if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) || defined(__FreeBSD_kernel__) + #include diff --git a/net/vpnc-scripts/Makefile b/net/vpnc-scripts/Makefile index 95948cfdd..3af3695ae 100644 --- a/net/vpnc-scripts/Makefile +++ b/net/vpnc-scripts/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vpnc-scripts PKG_VERSION:=20150116 -PKG_RELEASE:=1 +PKG_RELEASE:=2 include $(INCLUDE_DIR)/package.mk diff --git a/net/vpnc-scripts/files/vpnc-script b/net/vpnc-scripts/files/vpnc-script index c6007ab85..48c8ed04b 100755 --- a/net/vpnc-scripts/files/vpnc-script +++ b/net/vpnc-scripts/files/vpnc-script @@ -87,16 +87,29 @@ do_connect() { rm -f $DNSMASQ_FILE echo "$SDNS" | while read i; do if [ -n "$INTERNAL_IP4_DNS" ];then - echo "server=/$i/$INTERNAL_IP4_DNS" >> $DNSMASQ_FILE + for dns in "$INTERNAL_IP4_DNS";do + echo "server=/$i/$dns" >> $DNSMASQ_FILE + done fi if [ -n "$INTERNAL_IP6_DNS" ];then - echo "server=/$i/$INTERNAL_IP6_DNS" >> $DNSMASQ_FILE + for dns in "$INTERNAL_IP6_DNS";do + echo "server=/$i/$dns" >> $DNSMASQ_FILE + done fi echo "rebind-domain-ok=$i" >> $DNSMASQ_FILE done /etc/init.d/dnsmasq restart else - [ -n "$INTERNAL_IP4_DNS" ] && proto_add_dns_server "$INTERNAL_IP4_DNS" + if [ -n "$INTERNAL_IP4_DNS" ];then + for dns in "$INTERNAL_IP4_DNS";do + proto_add_dns_server "$dns" + done + fi + if [ -n "$INTERNAL_IP6_DNS" ];then + for dns in "$INTERNAL_IP6_DNS";do + proto_add_dns_server "$dns" + done + fi [ -n "$CISCO_DEF_DOMAIN" ] && proto_add_dns_search "$CISCO_DEF_DOMAIN" fi diff --git a/net/vpnc/Makefile b/net/vpnc/Makefile index 16a45a4b4..95995e10c 100644 --- a/net/vpnc/Makefile +++ b/net/vpnc/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vpnc PKG_REV:=550 PKG_VERSION:=0.5.3.r$(PKG_REV) -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://svn.unix-ag.uni-kl.de/vpnc/trunk/ diff --git a/net/vpnc/patches/001-cross.patch b/net/vpnc/patches/001-cross.patch index 94b382c3d..33bcfee3b 100644 --- a/net/vpnc/patches/001-cross.patch +++ b/net/vpnc/patches/001-cross.patch @@ -1,7 +1,7 @@ --- a/Makefile +++ b/Makefile @@ -20,7 +20,7 @@ - # $Id$ + # $Id: Makefile 539 2013-12-04 13:41:04Z Antonio Borneo $ DESTDIR= -PREFIX=/usr/local @@ -9,7 +9,7 @@ ETCDIR=/etc/vpnc BINDIR=$(PREFIX)/bin SBINDIR=$(PREFIX)/sbin -@@ -57,18 +57,15 @@ +@@ -57,18 +57,15 @@ OBJS = $(addsuffix .o,$(basename $(SRCS) CRYPTO_OBJS = $(addsuffix .o,$(basename $(CRYPTO_SRCS))) BINOBJS = $(addsuffix .o,$(BINS)) BINSRCS = $(addsuffix .c,$(BINS)) @@ -31,7 +31,7 @@ LIBS += -lnsl -lresolv -lsocket endif ifneq (,$(findstring Apple,$(shell $(CC) --version))) -@@ -82,7 +79,7 @@ +@@ -82,7 +79,7 @@ vpnc : $(OBJS) vpnc.o $(CC) $(LDFLAGS) -o $@ $^ $(LIBS) vpnc.8 : vpnc.8.template makeman.pl vpnc diff --git a/net/vpnc/patches/100-musl-compat.patch b/net/vpnc/patches/100-musl-compat.patch new file mode 100644 index 000000000..1186428af --- /dev/null +++ b/net/vpnc/patches/100-musl-compat.patch @@ -0,0 +1,42 @@ +--- a/sysdep.h ++++ b/sysdep.h +@@ -37,12 +37,14 @@ int tun_read(int fd, unsigned char *buf, + int tun_get_hwaddr(int fd, char *dev, uint8_t *hwaddr); + + /***************************************************************************/ +-#if defined(__linux__) || defined(__GLIBC__) ++#if defined(__GLIBC__) || defined(__UCLIBC__) + #include ++#define HAVE_ERROR 1 ++#endif + ++#if defined(__linux__) || defined(__GLIBC__) + #define HAVE_VASPRINTF 1 + #define HAVE_ASPRINTF 1 +-#define HAVE_ERROR 1 + #define HAVE_UNSETENV 1 + #define HAVE_SETENV 1 + #endif +--- a/sysdep.c ++++ b/sysdep.c +@@ -59,7 +59,9 @@ + #if defined(__DragonFly__) + #include + #elif defined(__linux__) +-#include ++# if defined(__GLIBC__) || defined(__UCLIBC__) ++# include ++# endif + #elif defined(__APPLE__) + /* no header for tun */ + #elif defined(__CYGWIN__) +--- a/config.c ++++ b/config.c +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include + #include + #include + #include diff --git a/net/vsftpd/Makefile b/net/vsftpd/Makefile index a5c55ad06..f24a79b8b 100644 --- a/net/vsftpd/Makefile +++ b/net/vsftpd/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vsftpd PKG_VERSION:=3.0.2 -PKG_RELEASE:=4 +PKG_RELEASE:=5 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://security.appspot.com/downloads/ @@ -49,8 +49,15 @@ endef Package/vsftpd-tls/conffiles=$(Package/vsftpd/conffiles) +ifneq ($(CONFIG_USE_MUSL),) + NLSSTRING:=-lcrypt +else + NLSSTRING:=-lcrypt -lnsl +endif + ifeq ($(BUILD_VARIANT),notls) define Build/Compile + $(SED) 's/-lcrypt -lnsl/$(NLSSTRING)/' $(PKG_BUILD_DIR)/Makefile $(MAKE) -C $(PKG_BUILD_DIR) \ CC="$(TARGET_CC)" \ CFLAGS="$(TARGET_CFLAGS)" \ @@ -63,6 +70,7 @@ 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 + $(SED) 's/-lcrypt -lnsl/$(NLSSTRING)/' $(PKG_BUILD_DIR)/Makefile $(MAKE) -C $(PKG_BUILD_DIR) \ CC="$(TARGET_CC)" \ CFLAGS="$(TARGET_CFLAGS)" \ diff --git a/net/vsftpd/patches/006-musl-compatibility.patch b/net/vsftpd/patches/006-musl-compatibility.patch new file mode 100644 index 000000000..9eefec79d --- /dev/null +++ b/net/vsftpd/patches/006-musl-compatibility.patch @@ -0,0 +1,13 @@ +--- a/sysdeputil.c ++++ b/sysdeputil.c +@@ -58,7 +58,9 @@ + #define VSF_SYSDEP_HAVE_SHADOW + #define VSF_SYSDEP_HAVE_USERSHELL + #define VSF_SYSDEP_HAVE_LIBCAP +-#define VSF_SYSDEP_HAVE_UTMPX ++#if defined(__GLIBC__) || defined(__UCLIBC__) ++ #define VSF_SYSDEP_HAVE_UTMPX ++#endif + + #define __USE_GNU + #include diff --git a/net/wavemon/Makefile b/net/wavemon/Makefile index c13262201..f843db834 100644 --- a/net/wavemon/Makefile +++ b/net/wavemon/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2008-2014 OpenWrt.org +# Copyright (C) 2008-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,14 +9,19 @@ include $(TOPDIR)/rules.mk PKG_NAME:=wavemon PKG_VERSION:=0.7.6 -PKG_RELEASE:=1 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_PROTO:=git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_URL:=https://github.com/uoaerg/wavemon.git +PKG_SOURCE_VERSION:=v$(PKG_VERSION) -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=http://eden-feed.erg.abdn.ac.uk/wavemon/stable-releases -PKG_MD5SUM:=c60e25feb8b1785cf14371556f0613f4 PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Jonathan McCrohan +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk @@ -24,11 +29,10 @@ include $(INCLUDE_DIR)/package.mk define Package/wavemon SECTION:=net CATEGORY:=Network - PKG_MAINTAINER:=Jonathan McCrohan TITLE:=N-curses based wireless network devices monitor DEPENDS:=+libncurses +libpthread SUBMENU:=wireless - URL:=http://eden-feed.erg.abdn.ac.uk/wavemon/ + URL:=https://github.com/uoaerg/wavemon/releases endef define Package/wavemon/description @@ -48,7 +52,7 @@ MAKE_FLAGS += \ define Package/wavemon/install $(INSTALL_DIR) $(1)/usr/bin - $(CP) $(PKG_INSTALL_DIR)/usr/bin/wavemon $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wavemon $(1)/usr/bin/ endef $(eval $(call BuildPackage,wavemon)) diff --git a/net/wget/Makefile b/net/wget/Makefile index a1682b357..a146a01ef 100644 --- a/net/wget/Makefile +++ b/net/wget/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 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:=wget -PKG_VERSION:=1.16.1 +PKG_VERSION:=1.16.3 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@GNU/$(PKG_NAME) -PKG_MD5SUM:=78942cc0cce0a23e18114d982789e360 +PKG_MD5SUM:=d2e4455781a70140ae83b54ca594ce21 PKG_MAINTAINER:=Maxim Storchak PKG_LICENSE:=GPL-3.0+ PKG_LICENSE_FILES:=COPYING diff --git a/net/wifidog/Makefile b/net/wifidog/Makefile new file mode 100644 index 000000000..ddc2bb1fa --- /dev/null +++ b/net/wifidog/Makefile @@ -0,0 +1,103 @@ +# +# Copyright (C) 2006,2015 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:=wifidog +PKG_VERSION:=1.2.1 +PKG_RELEASE=2 + + +PKG_LICENSE:=GPL-2.0 +# Note: Packaging is maintained upstream at +# https://github.com/wifidog/packages +PKG_MAINTAINER:=Michael Haas +PKG_LICENSE_FILES:=COPYING + + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=git://github.com/wifidog/wifidog-gateway.git +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE_VERSION:=1.2.1 +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz + +PKG_FIXUP:=autoreconf +# do not run make install +PKG_INSTALL:=0 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/wifidog/Default + SUBMENU:=Captive Portals + SECTION:=net + CATEGORY:=Network + DEPENDS:=+iptables-mod-extra +iptables-mod-ipopt +iptables-mod-nat-extra +libpthread + TITLE:=A wireless captive portal solution + URL:=http://www.wifidog.org +endef + +define Package/wifidog +$(call Package/wifidog/Default) + VARIANT:=normal +endef + +define Package/wifidog-tls +$(call Package/wifidog/Default) + DEPENDS+= +libcyassl + VARIANT:=tls +endef + + +define Package/wifidog/description + The Wifidog project is a complete and embeddable captive + portal solution for wireless community groups or individuals + who wish to open a free Hotspot while still preventing abuse + of their Internet connection. +endef + +define Package/wifidog-tls/description +$(call Package/wifidog/description) + +This variant can talk TLS to the auth server. +endef + +define Package/wifidog/conffiles +/etc/wifidog.conf +endef + +Package/wifidog-tls/conffiles = $(Package/wifidog/conffiles) + + +define Package/wifidog/configure + $(call Build/Configure/Default) +endef + +ifeq ($(BUILD_VARIANT),tls) + +CONFIGURE_ARGS += \ + --enable-cyassl + +endif + +define Package/wifidog/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wifidog $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wdctl $(1)/usr/bin/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libhttpd.so* $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/etc + $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog.conf $(1)/etc/ + $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog-msg.html $(1)/etc/ + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/wifidog.init $(1)/etc/init.d/wifidog +endef + +Package/wifidog-tls/install = $(Package/wifidog/install) + +$(eval $(call BuildPackage,wifidog)) +$(eval $(call BuildPackage,wifidog-tls)) diff --git a/net/wifidog/files/wifidog.init b/net/wifidog/files/wifidog.init new file mode 100644 index 000000000..6ebf64fbc --- /dev/null +++ b/net/wifidog/files/wifidog.init @@ -0,0 +1,22 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2006 OpenWrt.org +START=65 + +USE_PROCD=1 + +EXTRA_COMMANDS="status" +EXTRA_HELP=" status Print the status of the service" + +start_service() { + procd_open_instance + # -s: log to syslog + # -f: run in foreground + procd_set_param command /usr/bin/wifidog -s -f + procd_set_param respawn # respawn automatically if something died + procd_set_param file /etc/wifidog.conf + procd_close_instance +} + +status() { + /usr/bin/wdctl status +} diff --git a/net/wifidog/patches/100-musl-compat.patch b/net/wifidog/patches/100-musl-compat.patch new file mode 100644 index 000000000..599c1fefd --- /dev/null +++ b/net/wifidog/patches/100-musl-compat.patch @@ -0,0 +1,47 @@ +--- a/libhttpd/protocol.c ++++ b/libhttpd/protocol.c +@@ -28,6 +28,7 @@ + + #if defined(_WIN32) + #else ++#include + #include + #include + #endif +--- a/src/firewall.c ++++ b/src/firewall.c +@@ -35,7 +35,6 @@ + #include + #include + #include +-#include + + #include + +--- a/src/client_list.c ++++ b/src/client_list.c +@@ -31,9 +31,9 @@ + #include + #include + #include ++#include + #include + #include +-#include + + #include + +--- a/src/util.c ++++ b/src/util.c +@@ -33,10 +33,10 @@ + #include + #include + #include ++#include + #include + #include + #include +-#include + #include + #include + #include diff --git a/net/wshaper/Makefile b/net/wshaper/Makefile index 5007a8735..65b4045be 100644 --- a/net/wshaper/Makefile +++ b/net/wshaper/Makefile @@ -44,9 +44,10 @@ define Build/Compile endef define Package/wshaper/install - $(INSTALL_DIR) $(1)/usr/sbin/ $(1)/etc/init.d $(1)/etc/config + $(INSTALL_DIR) $(1)/usr/sbin/ $(1)/etc/init.d $(1)/etc/config $(1)/etc/hotplug.d/iface $(INSTALL_BIN) ./files/wshaper.htb $(1)/usr/sbin/ $(INSTALL_BIN) ./files/wshaper.init $(1)/etc/init.d/wshaper + $(INSTALL_BIN) ./files/wshaper.iface $(1)/etc/hotplug.d/iface/10-wshaper $(INSTALL_DATA) ./files/wshaper.config $(1)/etc/config/wshaper endef diff --git a/net/wshaper/files/wshaper.iface b/net/wshaper/files/wshaper.iface new file mode 100644 index 000000000..2964005df --- /dev/null +++ b/net/wshaper/files/wshaper.iface @@ -0,0 +1,3 @@ +#!/bin/sh + +[ "$ACTION" = ifup ] && /etc/init.d/wshaper enabled && /etc/init.d/wshaper start || exit 0 diff --git a/net/xinetd/Makefile b/net/xinetd/Makefile index 65c5368c9..c1586b725 100644 --- a/net/xinetd/Makefile +++ b/net/xinetd/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=xinetd PKG_VERSION:=2.3.15 -PKG_RELEASE:=3 +PKG_RELEASE:=4 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.xinetd.org @@ -42,6 +42,7 @@ define Package/xinetd/conffiles endef TARGET_CFLAGS += -DNO_RPC +TARGET_CPPFLAGS += -DHAVE_RLIM_T CONFIGURE_ARGS += \ --without-libwrap \ diff --git a/net/xinetd/patches/004-ident-bind.patch b/net/xinetd/patches/004-ident-bind.patch index ddabab8a1..0da01484d 100644 --- a/net/xinetd/patches/004-ident-bind.patch +++ b/net/xinetd/patches/004-ident-bind.patch @@ -10,7 +10,7 @@ Reviewed-By: Adam Tkac #diff -up xinetd-2.3.14/xinetd/ident.c.orig xinetd-2.3.14/xinetd/ident.c --- a/xinetd/ident.c +++ b/xinetd/ident.c -@@ -97,7 +98,13 @@ idresult_e log_remote_user( const struct +@@ -97,7 +97,13 @@ idresult_e log_remote_user( const struct } CLEAR( sin_contact ); @@ -25,7 +25,7 @@ Reviewed-By: Adam Tkac sin_contact = sin_remote; memcpy( &sin_bind, &sin_local, sizeof(sin_bind) ) ; local_port = 0; -@@ -121,7 +128,13 @@ idresult_e log_remote_user( const struct +@@ -127,7 +133,13 @@ idresult_e log_remote_user( const struct msg( LOG_ERR, func, "socket creation: %m" ) ; return( IDR_ERROR ) ; } diff --git a/net/xl2tpd/Makefile b/net/xl2tpd/Makefile index 2a1c4a5df..13d510fb5 100644 --- a/net/xl2tpd/Makefile +++ b/net/xl2tpd/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,18 +8,16 @@ include $(TOPDIR)/rules.mk PKG_NAME:=xl2tpd -PKG_VERSION:=1.3.6 -PKG_RELEASE:=1 +PKG_VERSION:=1.3.7pre20150524 +PKG_RELEASE:=3 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=LICENSE -PKG_RELEASE=$(PKG_SOURCE_VERSION) - PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/xelerance/xl2tpd.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=5619e1771048e74b729804e8602f409af0f3faea +PKG_SOURCE_VERSION:=1cda2a266e2e957b81019d63a8902b28304a0ac4 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_INSTALL:=1 @@ -32,7 +30,7 @@ define Package/xl2tpd TITLE:=An L2TP (Layer 2 Tunneling Protocol) daemon URL:=http://www.xelerance.com/software/xl2tpd/ SUBMENU:=VPN - DEPENDS:=+ppp-mod-pppol2tp +ip +resolveip + DEPENDS:=+ppp-mod-pppol2tp +resolveip endef define Package/xl2tpd/description diff --git a/net/xl2tpd/files/l2tp.sh b/net/xl2tpd/files/l2tp.sh index 867234dbe..afb3a51c1 100644 --- a/net/xl2tpd/files/l2tp.sh +++ b/net/xl2tpd/files/l2tp.sh @@ -18,31 +18,43 @@ proto_l2tp_init_config() { proto_config_add_string "server" available=1 no_device=1 + no_proto_task=1 } proto_l2tp_setup() { - local config="$1" - local iface="$2" - local optfile="/tmp/l2tp/options.${config}" + local interface="$1" + local optfile="/tmp/l2tp/options.${interface}" local ip serv_addr server json_get_var server server && { for ip in $(resolveip -t 5 "$server"); do - ( proto_add_host_dependency "$config" "$ip" ) + ( proto_add_host_dependency "$interface" "$ip" ) serv_addr=1 done } [ -n "$serv_addr" ] || { - echo "Could not resolve server address" + echo "Could not resolve server address" >&2 sleep 5 - proto_setup_failed "$config" + proto_setup_failed "$interface" exit 1 } if [ ! -p /var/run/xl2tpd/l2tp-control ]; then /etc/init.d/xl2tpd start + + local wait_timeout=0 + while [ ! -p /var/run/xl2tpd/l2tp-control ]; do + wait_timeout=$(($wait_timeout + 1)) + [ "$wait_timeout" -gt 5 ] && { + echo "Cannot find xl2tpd control file." >&2 + proto_setup_failed "$interface" + exit 1 + } + sleep 1 + done fi + local ipv6 demand keepalive username password pppd_options json_get_vars ipv6 demand keepalive username password pppd_options [ "$ipv6" = 1 ] || ipv6="" if [ "${demand:-0}" -gt 0 ]; then @@ -51,6 +63,7 @@ proto_l2tp_setup() { demand="persist" fi + local mtu [ -n "$mtu" ] || json_get_var mtu mtu local interval="${keepalive##*[, ]}" @@ -62,8 +75,8 @@ proto_l2tp_setup() { echo "usepeerdns" >> "${optfile}" echo "nodefaultroute" >> "${optfile}" echo "${username:+user \"$username\" password \"$password\"}" >> "${optfile}" - echo "ipparam \"$config\"" >> "${optfile}" - echo "ifname \"l2tp-$config\"" >> "${optfile}" + echo "ipparam \"$interface\"" >> "${optfile}" + echo "ifname \"l2tp-$interface\"" >> "${optfile}" echo "ip-up-script /lib/netifd/ppp-up" >> "${optfile}" echo "ipv6-up-script /lib/netifd/ppp-up" >> "${optfile}" echo "ip-down-script /lib/netifd/ppp-down" >> "${optfile}" @@ -73,14 +86,23 @@ proto_l2tp_setup() { echo "${ipv6:++ipv6} ${pppd_options}" >> "${optfile}" echo "${mtu:+mtu $mtu mru $mtu}" >> "${optfile}" - xl2tpd-control add l2tp-${config} pppoptfile=${optfile} lns=${server} redial=yes redial timeout=20 - xl2tpd-control connect l2tp-${config} + xl2tpd-control add l2tp-${interface} pppoptfile=${optfile} lns=${server} || { + echo "xl2tpd-control: Add l2tp-$interface failed" >&2 + proto_setup_failed "$interface" + exit 1 + } + xl2tpd-control connect l2tp-${interface} || { + echo "xl2tpd-control: Connect l2tp-$interface failed" >&2 + proto_setup_failed "$interface" + exit 1 + } } proto_l2tp_teardown() { local interface="$1" local optfile="/tmp/l2tp/options.${interface}" + rm -f ${optfile} case "$ERROR" in 11|19) proto_notify_error "$interface" AUTH_FAILED @@ -92,14 +114,15 @@ proto_l2tp_teardown() { ;; esac - xl2tpd-control disconnect l2tp-${interface} + if [ -p /var/run/xl2tpd/l2tp-control ]; then + xl2tpd-control remove l2tp-${interface} || { + echo "xl2tpd-control: Remove l2tp-$interface failed" >&2 + } + fi # Wait for interface to go down while [ -d /sys/class/net/l2tp-${interface} ]; do sleep 1 done - - xl2tpd-control remove l2tp-${interface} - rm -f ${optfile} } [ -n "$INCLUDE_ONLY" ] || { diff --git a/net/xl2tpd/files/xl2tpd.init b/net/xl2tpd/files/xl2tpd.init index 22e845901..7d2e9ea30 100644 --- a/net/xl2tpd/files/xl2tpd.init +++ b/net/xl2tpd/files/xl2tpd.init @@ -1,18 +1,24 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2006-2010 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org START=60 +USE_PROCD=1 + BIN=xl2tpd -DEFAULT=/etc/default/$BIN -RUN_D=/var/run -PID_F=$RUN_D/$BIN.pid +RUN_D="/var/run/xl2tpd" +PID_F="/var/run/xl2tpd.pid" + +start_service() { + rm -rf "$RUN_D" + mkdir -p "$RUN_D" -start() { - mkdir -p $RUN_D/$BIN - [ -f $DEFAULT ] && . $DEFAULT - $BIN $OPTIONS + procd_open_instance + procd_set_param command $BIN -D -l -p "$PID_F" + procd_set_param respawn + procd_close_instance } -stop() { - [ -f $PID_F ] && kill $(cat $PID_F) +stop_service() { + rm -rf "$RUN_D" + rm -rf "$PID_F" } diff --git a/net/xl2tpd/patches/100-makefile_opt_flags.patch b/net/xl2tpd/patches/100-makefile_opt_flags.patch index 82e875d70..1af416f96 100644 --- a/net/xl2tpd/patches/100-makefile_opt_flags.patch +++ b/net/xl2tpd/patches/100-makefile_opt_flags.patch @@ -1,6 +1,6 @@ --- a/Makefile +++ b/Makefile -@@ -91,7 +91,8 @@ OSFLAGS+= -DUSE_KERNEL +@@ -97,7 +97,8 @@ OSFLAGS+= -DUSE_KERNEL IPFLAGS?= -DIP_ALLOCATION diff --git a/net/xl2tpd/patches/110-makefile_dont_build_pfc.patch b/net/xl2tpd/patches/110-makefile_dont_build_pfc.patch index 460a0f15d..f76364fa8 100644 --- a/net/xl2tpd/patches/110-makefile_dont_build_pfc.patch +++ b/net/xl2tpd/patches/110-makefile_dont_build_pfc.patch @@ -1,6 +1,6 @@ --- a/Makefile +++ b/Makefile -@@ -107,10 +107,10 @@ BINDIR?=$(DESTDIR)${PREFIX}/bin +@@ -113,10 +113,10 @@ BINDIR?=$(DESTDIR)${PREFIX}/bin MANDIR?=$(DESTDIR)${PREFIX}/share/man @@ -13,7 +13,7 @@ $(EXEC): $(OBJS) $(HDRS) $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LDLIBS) -@@ -118,14 +118,10 @@ $(EXEC): $(OBJS) $(HDRS) +@@ -124,14 +124,10 @@ $(EXEC): $(OBJS) $(HDRS) $(CONTROL_EXEC): $(CONTROL_SRCS) $(CC) $(CFLAGS) $(LDFLAGS) $(CONTROL_SRCS) -o $@ @@ -29,7 +29,7 @@ install -d -m 0755 ${SBINDIR} install -m 0755 $(EXEC) ${SBINDIR}/$(EXEC) install -d -m 0755 ${MANDIR}/man5 -@@ -133,11 +129,6 @@ install: ${EXEC} pfc ${CONTROL_EXEC} +@@ -139,11 +135,6 @@ install: ${EXEC} pfc ${CONTROL_EXEC} install -m 0644 doc/xl2tpd.8 ${MANDIR}/man8/ install -m 0644 doc/xl2tpd.conf.5 doc/l2tp-secrets.5 \ ${MANDIR}/man5/ diff --git a/net/xl2tpd/patches/120-no-bsd-signal-in-musl.patch b/net/xl2tpd/patches/120-no-bsd-signal-in-musl.patch new file mode 100644 index 000000000..c8c4a7dd6 --- /dev/null +++ b/net/xl2tpd/patches/120-no-bsd-signal-in-musl.patch @@ -0,0 +1,11 @@ +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -30,7 +30,7 @@ + #include + #include + #include +-#if (__GLIBC__ < 2) ++#if defined (__GLIBC__) && (__GLIBC__ < 2) + # if defined(FREEBSD) || defined(OPENBSD) + # include + # elif defined(LINUX) diff --git a/net/xl2tpd/patches/200-xl2tpd-control-check-end-of-file-when-reading-pipe-t.patch b/net/xl2tpd/patches/200-xl2tpd-control-check-end-of-file-when-reading-pipe-t.patch new file mode 100644 index 000000000..811f9affe --- /dev/null +++ b/net/xl2tpd/patches/200-xl2tpd-control-check-end-of-file-when-reading-pipe-t.patch @@ -0,0 +1,42 @@ +From 7973d45a0e1716ddc6bfb6caf600f826f59a7932 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Tue, 28 Apr 2015 21:26:15 +0800 +Subject: [PATCH 200/210] xl2tpd-control: check end-of-file when reading pipe + to avoid dead loop. + +--- + xl2tpd-control.c | 11 +++++++---- + 1 file changed, 7 insertions(+), 4 deletions(-) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index feafe10..e5904d8 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -306,17 +306,20 @@ int read_result(int result_fd, char* buf, ssize_t size) + /*FIXME: there is a chance to hang up reading. + Should I create watching thread with timeout? + */ +- ssize_t readed; ++ ssize_t readed = 0; ++ ssize_t len; ++ + do + { +- readed = read (result_fd, buf, size); +- if (readed < 0) ++ len = read (result_fd, buf + readed, size - readed); ++ if (len < 0) + { + print_error (ERROR_LEVEL, + "error: can't read command result: %s\n", strerror (errno)); + break; + } +- } while (readed == 0); ++ readed += len; ++ } while (len > 0 && (size - readed) > 0); + buf[readed] = '\0'; + + /* scan result code */ +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/201-xl2tpd-control-define-_GNU_SOURCE-to-use-fmemopen-an.patch b/net/xl2tpd/patches/201-xl2tpd-control-define-_GNU_SOURCE-to-use-fmemopen-an.patch new file mode 100644 index 000000000..a4f704aa3 --- /dev/null +++ b/net/xl2tpd/patches/201-xl2tpd-control-define-_GNU_SOURCE-to-use-fmemopen-an.patch @@ -0,0 +1,26 @@ +From efa0a18b5dfd827792b07acdcb35101229ccf612 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 29 Apr 2015 10:32:37 +0800 +Subject: [PATCH 201/210] xl2tpd-control: define _GNU_SOURCE to use fmemopen() + and friends. + +--- + xl2tpd-control.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index e5904d8..9b6235d 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -10,6 +10,8 @@ + * + */ + ++#define _GNU_SOURCE ++ + #include + #include + #include +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/202-xl2tpd-control-open-control-file-with-O_NONBLOCK.patch b/net/xl2tpd/patches/202-xl2tpd-control-open-control-file-with-O_NONBLOCK.patch new file mode 100644 index 000000000..17721f278 --- /dev/null +++ b/net/xl2tpd/patches/202-xl2tpd-control-open-control-file-with-O_NONBLOCK.patch @@ -0,0 +1,42 @@ +From fedfd6685e5f81f0460beb4c448a30e7a6cfbd31 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 29 Apr 2015 14:21:12 +0800 +Subject: [PATCH 202/210] xl2tpd-control: open control file with O_NONBLOCK. + +Otherwise xl2tpd-control would block indefinitely in case xl2tpd is +not running. +--- + xl2tpd-control.c | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index 9b6235d..973ee87 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -246,7 +246,7 @@ int main (int argc, char *argv[]) + print_error (DEBUG_LEVEL, "command to be passed:\n%s\n", buf); + + /* try to open control file for writing */ +- int control_fd = open (control_filename, O_WRONLY, 0600); ++ int control_fd = open (control_filename, O_WRONLY | O_NONBLOCK, 0600); + if (control_fd < 0) + { + int errorno = errno; +@@ -265,6 +265,14 @@ int main (int argc, char *argv[]) + } + return -1; + } ++ ++ /* turn off O_NONBLOCK */ ++ if (fcntl (control_fd, F_SETFL, O_WRONLY) == -1) { ++ print_error (ERROR_LEVEL, ++ "Can not turn off nonblocking mode for control_fd: %s\n", ++ strerror(errno)); ++ return -2; ++ } + + /* pass command to control pipe */ + if (write (control_fd, buf, ftell (mesf)) < 0) +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/203-xl2tpd-control-cleaup-result-file-atexit.patch b/net/xl2tpd/patches/203-xl2tpd-control-cleaup-result-file-atexit.patch new file mode 100644 index 000000000..66eee642f --- /dev/null +++ b/net/xl2tpd/patches/203-xl2tpd-control-cleaup-result-file-atexit.patch @@ -0,0 +1,75 @@ +From 07e522cd7e223517389582a8eb647a4a6a8a5cf8 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Thu, 30 Apr 2015 13:53:11 +0800 +Subject: [PATCH 203/210] xl2tpd-control: cleaup result file atexit(). + +--- + xl2tpd-control.c | 21 ++++++++++++++------- + 1 file changed, 14 insertions(+), 7 deletions(-) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index 973ee87..abc0324 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -12,6 +12,7 @@ + + #define _GNU_SOURCE + ++#include + #include + #include + #include +@@ -35,6 +36,9 @@ + #define TUNNEL_REQUIRED 1 + #define TUNNEL_NOT_REQUIRED 0 + ++char result_filename[128]; ++int result_fd = -1; ++ + int log_level = ERROR_LEVEL; + + void print_error (int level, const char *fmt, ...); +@@ -117,6 +121,14 @@ void help() + ); + } + ++void cleanup(void) ++{ ++ /* cleaning up */ ++ if (result_fd >= 0) ++ close (result_fd); ++ unlink (result_filename); ++} ++ + int main (int argc, char *argv[]) + { + char* control_filename = NULL; +@@ -195,11 +207,11 @@ int main (int argc, char *argv[]) + FILE* mesf = fmemopen (buf, CONTROL_PIPE_MESSAGE_SIZE, "w"); + + /* create result pipe for reading */ +- char result_filename[128]; + snprintf (result_filename, 128, RESULT_FILENAME_FORMAT, getpid()); + unlink (result_filename); + mkfifo (result_filename, 0600); +- int result_fd = open (result_filename, O_RDONLY | O_NONBLOCK, 0600); ++ atexit(cleanup); ++ result_fd = open (result_filename, O_RDONLY | O_NONBLOCK, 0600); + if (result_fd < 0) + { + print_error (ERROR_LEVEL, +@@ -293,11 +305,6 @@ int main (int argc, char *argv[]) + ); + printf ("%s", rbuf); + +- /* cleaning up */ +- +- close (result_fd); +- unlink (result_filename); +- + return command_result_code; + } + +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/204-xl2tpd-control-enhance-output-of-print_error.patch b/net/xl2tpd/patches/204-xl2tpd-control-enhance-output-of-print_error.patch new file mode 100644 index 000000000..4e575078a --- /dev/null +++ b/net/xl2tpd/patches/204-xl2tpd-control-enhance-output-of-print_error.patch @@ -0,0 +1,58 @@ +From f6eaaabb0b2fab12cf597b8c1d12d470a13e581f Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Thu, 14 May 2015 14:58:10 +0800 +Subject: [PATCH 204/210] xl2tpd-control: enhance output of print_error(). + + - Add prefix "xl2tpd-control: " to print_error() output. + - Output response from xl2tpd only when -d is enabled as result of + control command can be retrieved from exit code. + - Remove some redundant and not that useful verbose output. +--- + xl2tpd-control.c | 10 ++++------ + 1 file changed, 4 insertions(+), 6 deletions(-) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index abc0324..6b08850 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -164,7 +164,6 @@ int main (int argc, char *argv[]) + { + control_filename = strdup (CONTROL_PIPE); + } +- print_error (DEBUG_LEVEL, "set control filename to %s\n", control_filename); + + /* parse command name */ + for (command = commands; command->name; command++) +@@ -176,10 +175,7 @@ int main (int argc, char *argv[]) + } + } + +- if (command->name) +- { +- print_error (DEBUG_LEVEL, "get command %s\n", command->name); +- } else { ++ if (!command->name) { + print_error (ERROR_LEVEL, "error: no such command %s\n", argv[i]); + return -1; + } +@@ -303,7 +299,8 @@ int main (int argc, char *argv[]) + int command_result_code = read_result ( + result_fd, rbuf, CONTROL_PIPE_MESSAGE_SIZE + ); +- printf ("%s", rbuf); ++ /* rbuf contains a newline, make it double to form a boundary. */ ++ print_error (DEBUG_LEVEL, "command response: \n%s\n", rbuf); + + return command_result_code; + } +@@ -313,6 +310,7 @@ void print_error (int level, const char *fmt, ...) + if (level > log_level) return; + va_list args; + va_start (args, fmt); ++ fprintf (stderr, "xl2tpd-control: "); + vfprintf (stderr, fmt, args); + va_end (args); + } +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/205-xl2tpd-fix-typo-in-reporting-available-lns-count.patch b/net/xl2tpd/patches/205-xl2tpd-fix-typo-in-reporting-available-lns-count.patch new file mode 100644 index 000000000..b25e82be4 --- /dev/null +++ b/net/xl2tpd/patches/205-xl2tpd-fix-typo-in-reporting-available-lns-count.patch @@ -0,0 +1,34 @@ +From 1c148f6645f43bf5abd8a9b8f0708a598b357d97 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Thu, 14 May 2015 19:56:39 +0800 +Subject: [PATCH 205/210] xl2tpd: fix typo in reporting available lns count. + +--- + xl2tpd.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/xl2tpd.c b/xl2tpd.c +index c9b7579..6c945fc 100644 +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -1039,7 +1039,7 @@ int control_handle_available(FILE* resf, char* bufp){ + lns_count++; + } + +- write_res (resf, "%02i AVAILABLE lns.cout=%d\n", 0, lns_count); ++ write_res (resf, "%02i AVAILABLE lns.count=%d\n", 0, lns_count); + + lac = laclist; + int lac_count = 0; +@@ -1053,7 +1053,7 @@ int control_handle_available(FILE* resf, char* bufp){ + if(deflac){ + write_res (resf, "%02i AVAILABLE lac.%d.name=%s\n", 0, lac_count, deflac->entname); + lac_count++; +- } ++ } + + write_res (resf, "%02i AVAILABLE lac.count=%d\n", 0, lac_count); + return 1; +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/206-xl2tpd-start_pppd-place-opts-after-plugin-pppol2tp.s.patch b/net/xl2tpd/patches/206-xl2tpd-start_pppd-place-opts-after-plugin-pppol2tp.s.patch new file mode 100644 index 000000000..60d8b84db --- /dev/null +++ b/net/xl2tpd/patches/206-xl2tpd-start_pppd-place-opts-after-plugin-pppol2tp.s.patch @@ -0,0 +1,71 @@ +From 18fdf802d31354c62a27cc5a63b196780a0d486e Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Wed, 29 Apr 2015 16:30:17 +0800 +Subject: [PATCH 206/210] xl2tpd: start_pppd: place opts after "plugin + pppol2tp.so". + +so that plugin options like pppol2tp_debug_mark can be recognized by +pppd. While doing this also add bound check to prevent potential buffer +overflow problem. +--- + xl2tpd.c | 22 +++++++++++----------- + 1 file changed, 11 insertions(+), 11 deletions(-) + +diff --git a/xl2tpd.c b/xl2tpd.c +index 6c945fc..017adfd 100644 +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -382,7 +382,6 @@ int start_pppd (struct call *c, struct ppp_opts *opts) + /* char a, b; */ + char tty[512]; + char *stropt[80]; +- struct ppp_opts *p; + #ifdef USE_KERNEL + struct sockaddr_pppol2tp sax; + int flags; +@@ -396,16 +395,7 @@ int start_pppd (struct call *c, struct ppp_opts *opts) + struct call *sc; + struct tunnel *st; + +- p = opts; + stropt[0] = strdup (PPPD); +- while (p) +- { +- stropt[pos] = (char *) malloc (strlen (p->option) + 1); +- strncpy (stropt[pos], p->option, strlen (p->option) + 1); +- pos++; +- p = p->next; +- } +- stropt[pos] = NULL; + if (c->pppd > 0) + { + l2tp_log(LOG_WARNING, "%s: PPP already started on call!\n", __FUNCTION__); +@@ -467,7 +457,6 @@ int start_pppd (struct call *c, struct ppp_opts *opts) + snprintf (stropt[pos], 10, "%d", c->ourcid); + pos++; + } +- stropt[pos] = NULL; + } + else + #endif +@@ -497,6 +486,17 @@ int start_pppd (struct call *c, struct ppp_opts *opts) + return -EINVAL; + } + stropt[pos++] = strdup(tty); ++ } ++ ++ { ++ struct ppp_opts *p = opts; ++ int maxn_opts = sizeof(stropt) / sizeof(stropt[0]) - 1; ++ while (p && pos < maxn_opts) ++ { ++ stropt[pos] = strdup (p->option); ++ pos++; ++ p = p->next; ++ } + stropt[pos] = NULL; + } + +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/207-xl2tpd-introduce-new-option-l-for-using-syslog-as-th.patch b/net/xl2tpd/patches/207-xl2tpd-introduce-new-option-l-for-using-syslog-as-th.patch new file mode 100644 index 000000000..5ab94cb05 --- /dev/null +++ b/net/xl2tpd/patches/207-xl2tpd-introduce-new-option-l-for-using-syslog-as-th.patch @@ -0,0 +1,104 @@ +From b3402a68a4d29e9b1ae4e012e39a7bcb14fea3cf Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Thu, 30 Apr 2015 13:57:36 +0800 +Subject: [PATCH 207/210] xl2tpd: introduce new option -l for using syslog as + the logging facility. + +Defaults to old behaviour if no -l option was specified. Also update +manual doc to reflect this change. +--- + doc/xl2tpd.8 | 5 +++++ + file.h | 1 + + misc.c | 2 +- + xl2tpd.c | 13 ++++++++++++- + 4 files changed, 19 insertions(+), 2 deletions(-) + +diff --git a/doc/xl2tpd.8 b/doc/xl2tpd.8 +index 915b247..7afccac 100644 +--- a/doc/xl2tpd.8 ++++ b/doc/xl2tpd.8 +@@ -20,6 +20,11 @@ This option prevents xl2tpd from detaching from the terminal and + daemonizing. + + .TP ++.B -l ++This option tells xl2tpd to use syslog for logging even when \fB\-D\fR ++was specified. ++ ++.TP + .B -c + Tells xl2tpd to use an alternate config file. Default is + /etc/xl2tpd/xl2tpd.conf. Fallback configuration file is +diff --git a/file.h b/file.h +index 89987ae..92df046 100644 +--- a/file.h ++++ b/file.h +@@ -151,6 +151,7 @@ struct global + char pidfile[STRLEN]; /* File containing the pid number*/ + char controlfile[STRLEN]; /* Control file name (named pipe) */ + int daemon; /* Use daemon mode? */ ++ int syslog; /* Use syslog for logging? */ + int accesscontrol; /* Use access control? */ + int forceuserspace; /* Force userspace? */ + int packet_dump; /* Dump (print) all packets? */ +diff --git a/misc.c b/misc.c +index 3092401..cccf4ca 100644 +--- a/misc.c ++++ b/misc.c +@@ -57,7 +57,7 @@ void l2tp_log (int level, const char *fmt, ...) + vsnprintf (buf, sizeof (buf), fmt, args); + va_end (args); + +- if(gconfig.daemon) { ++ if(gconfig.syslog) { + init_log(); + SYSLOG_CALL( syslog (level, "%s", buf) ); + } else { +diff --git a/xl2tpd.c b/xl2tpd.c +index 017adfd..1937690 100644 +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -1594,7 +1594,7 @@ void do_control () + void usage(void) { + printf("\nxl2tpd version: %s\n", SERVER_VERSION); + printf("Usage: xl2tpd [-c ] [-s ] [-p ]\n" +- " [-C ] [-D]\n" ++ " [-C ] [-D] [-l]\n" + " [-v, --version]\n"); + printf("\n"); + exit(1); +@@ -1605,6 +1605,7 @@ void init_args(int argc, char *argv[]) + int i=0; + + gconfig.daemon=1; ++ gconfig.syslog=-1; + memset(gconfig.altauthfile,0,STRLEN); + memset(gconfig.altconfigfile,0,STRLEN); + memset(gconfig.authfile,0,STRLEN); +@@ -1642,6 +1643,9 @@ void init_args(int argc, char *argv[]) + else if (! strncmp(argv[i],"-D",2)) { + gconfig.daemon=0; + } ++ else if (! strncmp(argv[i],"-l",2)) { ++ gconfig.syslog=1; ++ } + else if (! strncmp(argv[i],"-s",2)) { + if(++i == argc) + usage(); +@@ -1667,6 +1671,13 @@ void init_args(int argc, char *argv[]) + usage(); + } + } ++ ++ /* ++ * defaults to syslog if no log facility was explicitly ++ * specified and we are about to daemonize ++ */ ++ if (gconfig.syslog < 0) ++ gconfig.syslog = gconfig.daemon; + } + + +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/208-xl2tpd-unlink-result-file-to-prevent-leftover-a-regu.patch b/net/xl2tpd/patches/208-xl2tpd-unlink-result-file-to-prevent-leftover-a-regu.patch new file mode 100644 index 000000000..90694f228 --- /dev/null +++ b/net/xl2tpd/patches/208-xl2tpd-unlink-result-file-to-prevent-leftover-a-regu.patch @@ -0,0 +1,26 @@ +From a2b163a65a2d4fbca57c3aa82b526cf8fbc8e449 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Fri, 15 May 2015 10:56:23 +0800 +Subject: [PATCH 208/210] xl2tpd: unlink result file to prevent leftover a + regular file. + +--- + xl2tpd.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xl2tpd.c b/xl2tpd.c +index 1937690..c11fe66 100644 +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -1582,6 +1582,8 @@ void do_control () + if (resf) + { + fclose (resf); ++ /* unlink it anyway to prevent leftover a regular file. */ ++ unlink(res_filename); + } + } + +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/209-xl2tpd-ignore-SIGPIPE-signal.patch b/net/xl2tpd/patches/209-xl2tpd-ignore-SIGPIPE-signal.patch new file mode 100644 index 000000000..a0d88bd34 --- /dev/null +++ b/net/xl2tpd/patches/209-xl2tpd-ignore-SIGPIPE-signal.patch @@ -0,0 +1,32 @@ +From 2d0eff7f56936823d784425d2171be295ba11027 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Fri, 15 May 2015 15:55:10 +0800 +Subject: [PATCH 209/210] xl2tpd: ignore SIGPIPE signal. + +--- + xl2tpd.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xl2tpd.c b/xl2tpd.c +index c11fe66..58ed868 100644 +--- a/xl2tpd.c ++++ b/xl2tpd.c +@@ -1551,7 +1551,6 @@ void do_control () + /*FIXME: check quotes to allow filenames with spaces? + (do not forget quotes escaping to allow filenames with quotes)*/ + +- /*FIXME: write to res_filename may cause SIGPIPE, need to catch it*/ + resf = fopen (res_filename, "w"); + if (!resf) { + l2tp_log (LOG_DEBUG, "%s: Can't open result file %s\n", +@@ -1811,6 +1810,7 @@ void init (int argc,char *argv[]) + signal (SIGCHLD, &sigchld_handler); + signal (SIGUSR1, &sigusr1_handler); + signal (SIGHUP, &sighup_handler); ++ signal (SIGPIPE, SIG_IGN); + init_scheduler (); + + unlink(gconfig.controlfile); +-- +1.7.10.4 + diff --git a/net/xl2tpd/patches/210-xl2tpd-control-show-all-available-commands-in-help.patch b/net/xl2tpd/patches/210-xl2tpd-control-show-all-available-commands-in-help.patch new file mode 100644 index 000000000..8eccffa58 --- /dev/null +++ b/net/xl2tpd/patches/210-xl2tpd-control-show-all-available-commands-in-help.patch @@ -0,0 +1,119 @@ +From 26b77b7cdc70beddc68507f74372a4e2815720f0 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Sun, 17 May 2015 10:53:44 +0800 +Subject: [PATCH 210/210] xl2tpd-control: show all available commands in + --help. + +--- + xl2tpd-control.c | 63 ++++++++++++++++++++++++++++++++++++++---------------- + 1 file changed, 44 insertions(+), 19 deletions(-) + +diff --git a/xl2tpd-control.c b/xl2tpd-control.c +index 6b08850..b98ff24 100644 +--- a/xl2tpd-control.c ++++ b/xl2tpd-control.c +@@ -51,6 +51,7 @@ struct command_t + char *name; + int (*handler) (FILE*, char* tunnel, int optc, char *optv[]); + int requires_tunnel; ++ char *help; + }; + + int command_add_lac (FILE*, char* tunnel, int optc, char *optv[]); +@@ -65,13 +66,29 @@ int command_available (FILE*, char* tunnel, int optc, char *optv[]); + + struct command_t commands[] = { + /* Keep this command mapping for backwards compat */ +- {"add", &command_add_lac, TUNNEL_REQUIRED}, +- {"connect", &command_connect_lac, TUNNEL_REQUIRED}, +- {"disconnect", &command_disconnect_lac, TUNNEL_REQUIRED}, +- {"remove", &command_remove_lac, TUNNEL_REQUIRED}, ++ {"add", &command_add_lac, TUNNEL_REQUIRED, ++ "\tadd\tadds new or modify existing lac configuration.\n" ++ "\t\tConfiguration must be specified as command options in\n" ++ "\t\t= pairs format.\n" ++ "\t\tSee available options in xl2tpd.conf(5)\n" ++ }, ++ {"connect", &command_connect_lac, TUNNEL_REQUIRED, ++ "\tconnect\ttries to activate the tunnel.\n" ++ "\t\tUsername and secret for the tunnel can be passed as\n" ++ "\t\tcommand options.\n" ++ }, ++ {"disconnect", &command_disconnect_lac, TUNNEL_REQUIRED, ++ "\tdisconnect\tdisconnects the tunnel.\n" ++ }, ++ {"remove", &command_remove_lac, TUNNEL_REQUIRED, ++ "\tremove\tremoves lac configuration from xl2tpd.\n" ++ "\t\txl2tpd disconnects the tunnel before removing.\n" ++ }, + + /* LAC commands */ +- {"add-lac", &command_add_lac, TUNNEL_REQUIRED}, ++ {"add-lac", &command_add_lac, TUNNEL_REQUIRED, ++ "\tadd-lns\tadds new or modify existing lns configuration.\n" ++ }, + {"connect-lac", &command_connect_lac, TUNNEL_REQUIRED}, + {"disconnect-lac", &command_disconnect_lac, TUNNEL_REQUIRED}, + {"remove-lac", &command_remove_lac, TUNNEL_REQUIRED}, +@@ -89,36 +106,44 @@ struct command_t commands[] = { + + void usage() + { ++ int i; ++ + printf ("\nxl2tpd server version %s\n", SERVER_VERSION); + printf ("Usage: xl2tpd-control [-c ] []\n" + "\n" + " -c\tspecifies xl2tpd control file\n" + " -d\tspecify xl2tpd-control to run in debug mode\n" + "--help\tshows extended help\n" +- "Available commands: add, connect, disconnect, remove, add-lns\n" + ); ++ ++ printf ("Available commands: "); ++ for (i = 0; commands[i].name; i++) { ++ struct command_t *command = &commands[i]; ++ int last = command[1].name == NULL; ++ ++ printf ("%s%s", command->name, !last ? ", " : "\n"); ++ } + } + + void help() + { ++ int i; ++ + usage(); + printf ( + "\n" + "Commands help:\n" +- "\tadd\tadds new or modify existing lac configuration.\n" +- "\t\tConfiguration must be specified as command options in\n" +- "\t\t= pairs format.\n" +- "\t\tSee available options in xl2tpd.conf(5)\n" +- "\tconnect\ttries to activate the tunnel.\n" +- "\t\tUsername and secret for the tunnel can be passed as\n" +- "\t\tcommand options.\n" +- "\tdisconnect\tdisconnects the tunnel.\n" +- "\tremove\tremoves lac configuration from xl2tpd.\n" +- "\t\txl2tpd disconnects the tunnel before removing.\n" +- "\n" +- "\tadd-lns\tadds new or modify existing lns configuration.\n" +- "See xl2tpd-control man page for more help\n" + ); ++ ++ for (i = 0; commands[i].name; i++) { ++ struct command_t *command = &commands[i]; ++ ++ if (!command->help) ++ continue; ++ printf ("%s", command->help); ++ } ++ /*FIXME Ha! there is currently no manpage for xl2tpd-control */ ++ printf ("See xl2tpd-control man page for more help\n"); + } + + void cleanup(void) +-- +1.7.10.4 + diff --git a/net/znc/Makefile b/net/znc/Makefile index 9681c4733..f0cba304f 100644 --- a/net/znc/Makefile +++ b/net/znc/Makefile @@ -8,18 +8,19 @@ include $(TOPDIR)/rules.mk PKG_NAME:=znc -PKG_VERSION:=1.4 -PKG_RELEASE:=2 +PKG_VERSION:=1.6.0 +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:=630cb74db34d2d5451ba30b47869f6bb +PKG_MD5SUM:=674d8c1277752dcc627b96e33a63376e PKG_MAINTAINER:=Jonas Gorski PKG_LICENSE:=Apache-2.0 PKG_LICENSE_FILES:=LICENSE +PKG_USE_MIPS16:=0 PKG_BUILD_PARALLEL:=1 @@ -33,7 +34,7 @@ endef define Package/znc $(Package/znc/default) - DEPENDS:=+libopenssl +libpthread +libstdcpp + DEPENDS:=+libopenssl +libpthread +libstdcpp @GCC_VERSION_4_8||GCC_VERSION_4_9 MENU:=1 endef @@ -135,6 +136,8 @@ endef $(eval $(call module,adminlog,Log user connects and disconnects and failed \ logins to file or syslog.)) +$(eval $(call module,alias,Provides bouncer-side command alias support.)) + $(eval $(call module,autoattach,Reattaches you to channels on activity.)) $(eval $(call module,autocycle,Cycles a channel when you are the only one in \ @@ -197,6 +200,8 @@ $(eval $(call module,flooddetach,This module detaches you from channels which \ $(eval $(call module,identfile,Places the ident of a user to a file when they \ are trying to connect.)) +$(eval $(call module,imapauth,Allow users to authenticate via IMAP.)) + $(eval $(call module,keepnick,Tries to get you your primary nick.)) $(eval $(call module,kickrejoin,Implements auto-rejoin-on-kick.)) @@ -208,6 +213,8 @@ $(eval $(call module,listsockets,This module displays a list of all open \ $(eval $(call module,log,Log conversations to file.)) +$(eval $(call module,missingmotd,Sends 422 to clients when they login.)) + $(eval $(call module,modules_online,This module fakes the online status of \ ZNC-*users.)) diff --git a/net/znc/patches/001-fix-savebuff-timer-initialization.patch b/net/znc/patches/001-fix-savebuff-timer-initialization.patch new file mode 100644 index 000000000..5299ca859 --- /dev/null +++ b/net/znc/patches/001-fix-savebuff-timer-initialization.patch @@ -0,0 +1,28 @@ +From d6feb6f574933753371687ee42fa19d0b0d8d777 Mon Sep 17 00:00:00 2001 +From: Thomas Kriechbaumer +Date: Tue, 17 Feb 2015 10:08:30 +0000 +Subject: [PATCH] fix savebuff timer initialization + +closes #868 +--- + modules/savebuff.cpp | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/modules/savebuff.cpp ++++ b/modules/savebuff.cpp +@@ -93,13 +93,13 @@ public: + else + m_sPassword = CBlowfish::MD5(sArgs); + ++ AddTimer(new CSaveBuffJob(this, 60, 0, "SaveBuff", "Saves the current buffer to disk every 1 minute")); ++ + return( !m_bBootError ); + } + + virtual bool OnBoot() override + { +- AddTimer(new CSaveBuffJob(this, 60, 0, "SaveBuff", "Saves the current buffer to disk every 1 minute")); +- + CDir saveDir(GetSavePath()); + for (CFile* pFile : saveDir) { + CString sName; diff --git a/net/znc/patches/002-CThreadPool-Handle-spurious-wakeups.patch b/net/znc/patches/002-CThreadPool-Handle-spurious-wakeups.patch new file mode 100644 index 000000000..1377307a1 --- /dev/null +++ b/net/znc/patches/002-CThreadPool-Handle-spurious-wakeups.patch @@ -0,0 +1,33 @@ +From 2f4488c2a4f2d6b130ded560efa06680bfd8a185 Mon Sep 17 00:00:00 2001 +From: Uli Schlachter +Date: Sat, 14 Feb 2015 19:41:26 +0100 +Subject: [PATCH] ~CThreadPool(): Handle spurious wakeups + +From pthread_cond_wait()'s man page: + + When using condition variables there is always a boolean predicate involving + shared variables associated with each condition wait that is true if the + thread should proceed. Spurious wakeups from the pthread_cond_wait() or + pthread_cond_timedwait() functions may occur. Since the return from + pthread_cond_wait() or pthread_cond_timedwait() does not imply anything about + the value of this predicate, the predicate should be re-evaluated upon such + return. + +Fix ~CThreadPool() to account for this possibility. + +Signed-off-by: Uli Schlachter +--- + src/Threads.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/src/Threads.cpp ++++ b/src/Threads.cpp +@@ -87,7 +87,7 @@ CThreadPool::~CThreadPool() { + CMutexLocker guard(m_mutex); + m_done = true; + +- if (m_num_threads > 0) { ++ while (m_num_threads > 0) { + m_cond.broadcast(); + m_exit_cond.wait(m_mutex); + } diff --git a/net/znc/patches/003-Fix-CIRCNetwork-FindChans-and-FindQueries-to-be-case.patch b/net/znc/patches/003-Fix-CIRCNetwork-FindChans-and-FindQueries-to-be-case.patch new file mode 100644 index 000000000..d5ad3df75 --- /dev/null +++ b/net/znc/patches/003-Fix-CIRCNetwork-FindChans-and-FindQueries-to-be-case.patch @@ -0,0 +1,149 @@ +From e10b53b87bb7ce87d1a31473e03a02ccafa78787 Mon Sep 17 00:00:00 2001 +From: J-P Nurmi +Date: Tue, 3 Feb 2015 10:11:47 +0100 +Subject: [PATCH] Fix CIRCNetwork::FindChans() and FindQueries() to be + case-insensitive + +The playback module failed to clear a buffer, because it tried to +clear "NickServ" whereas ZNC had internally stored it has "nickserv". +--- + Makefile.in | 2 +- + src/IRCNetwork.cpp | 6 ++-- + test/NetworkTest.cpp | 96 ++++++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 101 insertions(+), 3 deletions(-) + create mode 100644 test/NetworkTest.cpp + +--- a/Makefile.in ++++ b/Makefile.in +@@ -48,7 +48,7 @@ LIB_SRCS := $(addprefix src/,$(LIB_SRCS + BIN_SRCS := src/main.cpp + LIB_OBJS := $(patsubst %cpp,%o,$(LIB_SRCS)) + BIN_OBJS := $(patsubst %cpp,%o,$(BIN_SRCS)) +-TESTS := StringTest ConfigTest UtilsTest ThreadTest NickTest ClientTest ++TESTS := StringTest ConfigTest UtilsTest ThreadTest NickTest ClientTest NetworkTest + TESTS := $(addprefix test/,$(addsuffix .o,$(TESTS))) + CLEAN := znc src/*.o test/*.o core core.* .version_extra .depend modules/.depend unittest + DISTCLEAN := Makefile config.log config.status znc-buildmod \ +--- a/src/IRCNetwork.cpp ++++ b/src/IRCNetwork.cpp +@@ -787,8 +787,9 @@ CChan* CIRCNetwork::FindChan(CString sNa + std::vector CIRCNetwork::FindChans(const CString& sWild) const { + std::vector vChans; + vChans.reserve(m_vChans.size()); ++ const CString sLower = sWild.AsLower(); + for (std::vector::const_iterator it = m_vChans.begin(); it != m_vChans.end(); ++it) { +- if ((*it)->GetName().WildCmp(sWild)) ++ if ((*it)->GetName().AsLower().WildCmp(sLower)) + vChans.push_back(*it); + } + return vChans; +@@ -946,8 +947,9 @@ CQuery* CIRCNetwork::FindQuery(const CSt + std::vector CIRCNetwork::FindQueries(const CString& sWild) const { + std::vector vQueries; + vQueries.reserve(m_vQueries.size()); ++ const CString sLower = sWild.AsLower(); + for (std::vector::const_iterator it = m_vQueries.begin(); it != m_vQueries.end(); ++it) { +- if ((*it)->GetName().WildCmp(sWild)) ++ if ((*it)->GetName().AsLower().WildCmp(sLower)) + vQueries.push_back(*it); + } + return vQueries; +--- /dev/null ++++ b/test/NetworkTest.cpp +@@ -0,0 +1,96 @@ ++/* ++ * Copyright (C) 2004-2015 ZNC, see the NOTICE file for details. ++ * ++ * Licensed under the Apache License, Version 2.0 (the "License"); ++ * you may not use this file except in compliance with the License. ++ * You may obtain a copy of the License at ++ * ++ * http://www.apache.org/licenses/LICENSE-2.0 ++ * ++ * Unless required by applicable law or agreed to in writing, software ++ * distributed under the License is distributed on an "AS IS" BASIS, ++ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ++ * See the License for the specific language governing permissions and ++ * limitations under the License. ++ */ ++ ++#include ++#include ++#include ++#include ++ ++class NetworkTest : public ::testing::Test { ++protected: ++ void SetUp() { CZNC::CreateInstance(); } ++ void TearDown() { CZNC::DestroyInstance(); } ++}; ++ ++TEST_F(NetworkTest, FindChan) { ++ CUser user("user"); ++ CIRCNetwork network(&user, "network"); ++ ++ EXPECT_TRUE(network.AddChan("#foo", false)); ++ EXPECT_TRUE(network.AddChan("#Bar", false)); ++ EXPECT_TRUE(network.AddChan("#BAZ", false)); ++ ++ EXPECT_TRUE(network.FindChan("#foo")); ++ EXPECT_TRUE(network.FindChan("#Bar")); ++ EXPECT_TRUE(network.FindChan("#BAZ")); ++ ++ EXPECT_TRUE(network.FindChan("#Foo")); ++ EXPECT_TRUE(network.FindChan("#BAR")); ++ EXPECT_TRUE(network.FindChan("#baz")); ++ ++ EXPECT_FALSE(network.FindChan("#f")); ++ EXPECT_FALSE(network.FindChan("&foo")); ++ EXPECT_FALSE(network.FindChan("##foo")); ++} ++ ++TEST_F(NetworkTest, FindChans) { ++ CUser user("user"); ++ CIRCNetwork network(&user, "network"); ++ ++ EXPECT_TRUE(network.AddChan("#foo", false)); ++ EXPECT_TRUE(network.AddChan("#Bar", false)); ++ EXPECT_TRUE(network.AddChan("#BAZ", false)); ++ ++ EXPECT_EQ(network.FindChans("#f*").size(), 1); ++ EXPECT_EQ(network.FindChans("#b*").size(), 2); ++ EXPECT_EQ(network.FindChans("#?A*").size(), 2); ++ EXPECT_EQ(network.FindChans("*z").size(), 1); ++} ++ ++TEST_F(NetworkTest, FindQuery) { ++ CUser user("user"); ++ CIRCNetwork network(&user, "network"); ++ ++ EXPECT_TRUE(network.AddQuery("foo")); ++ EXPECT_TRUE(network.AddQuery("Bar")); ++ EXPECT_TRUE(network.AddQuery("BAZ")); ++ ++ EXPECT_TRUE(network.FindQuery("foo")); ++ EXPECT_TRUE(network.FindQuery("Bar")); ++ EXPECT_TRUE(network.FindQuery("BAZ")); ++ ++ EXPECT_TRUE(network.FindQuery("Foo")); ++ EXPECT_TRUE(network.FindQuery("BAR")); ++ EXPECT_TRUE(network.FindQuery("baz")); ++ ++ EXPECT_FALSE(network.FindQuery("f")); ++ EXPECT_FALSE(network.FindQuery("fo")); ++ EXPECT_FALSE(network.FindQuery("FF")); ++} ++ ++TEST_F(NetworkTest, FindQueries) { ++ CUser user("user"); ++ CIRCNetwork network(&user, "network"); ++ ++ EXPECT_TRUE(network.AddQuery("foo")); ++ EXPECT_TRUE(network.AddQuery("Bar")); ++ EXPECT_TRUE(network.AddQuery("BAZ")); ++ ++ EXPECT_EQ(network.FindQueries("f*").size(), 1); ++ EXPECT_EQ(network.FindQueries("b*").size(), 2); ++ EXPECT_EQ(network.FindQueries("?A*").size(), 2); ++ EXPECT_EQ(network.FindQueries("*z").size(), 1); ++} diff --git a/net/znc/patches/004-Fix-chansaver-loading.patch b/net/znc/patches/004-Fix-chansaver-loading.patch new file mode 100644 index 000000000..b0f2690af --- /dev/null +++ b/net/znc/patches/004-Fix-chansaver-loading.patch @@ -0,0 +1,38 @@ +From 7e75018ba60a9f50ea9e936eb1b6eb6b44dbc668 Mon Sep 17 00:00:00 2001 +From: J-P Nurmi +Date: Sat, 28 Feb 2015 21:15:23 +0100 +Subject: [PATCH] Fix chansaver loading + +CModules::LoadModule() sets the module type _after_ construction. +The constructor cannot therefore do actions based on the module +type. Move loading to OnLoad(). +--- + modules/chansaver.cpp | 10 +++++++--- + 1 file changed, 7 insertions(+), 3 deletions(-) + +--- a/modules/chansaver.cpp ++++ b/modules/chansaver.cpp +@@ -21,6 +21,12 @@ + class CChanSaverMod : public CModule { + public: + MODCONSTRUCTOR(CChanSaverMod) { ++ } ++ ++ virtual ~CChanSaverMod() { ++ } ++ ++ bool OnLoad(const CString& sArgsi, CString& sMessage) override { + switch (GetType()) { + case CModInfo::GlobalModule: + LoadUsers(); +@@ -32,9 +38,7 @@ public: + LoadNetwork(GetNetwork()); + break; + } +- } +- +- virtual ~CChanSaverMod() { ++ return true; + } + + void LoadUsers() { diff --git a/net/znc/patches/005-Fix-rare-conflict-of-HTTP-Basic-auth-and-cookies.patch b/net/znc/patches/005-Fix-rare-conflict-of-HTTP-Basic-auth-and-cookies.patch new file mode 100644 index 000000000..d635e78bb --- /dev/null +++ b/net/znc/patches/005-Fix-rare-conflict-of-HTTP-Basic-auth-and-cookies.patch @@ -0,0 +1,36 @@ +From 13c2dc126d8bb4c57273178fc455dab6f02e1efc Mon Sep 17 00:00:00 2001 +From: Alexey Sokolov +Date: Thu, 16 Apr 2015 01:21:57 +0100 +Subject: [PATCH] Fix rare conflict of HTTP-Basic auth and cookies. + +Fix #946 +--- + src/HTTPSock.cpp | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +--- a/src/HTTPSock.cpp ++++ b/src/HTTPSock.cpp +@@ -122,7 +122,7 @@ void CHTTPSock::ReadLine(const CString& + sLine.Token(2).Base64Decode(sUnhashed); + m_sUser = sUnhashed.Token(0, false, ":"); + m_sPass = sUnhashed.Token(1, true, ":"); +- m_bLoggedIn = OnLogin(m_sUser, m_sPass, true); ++ // Postpone authorization attempt until end of headers, because cookies should be read before that, otherwise session id will be overwritten in GetSession() + } else if (sName.Equals("Content-Length:")) { + m_uPostLen = sLine.Token(1).ToULong(); + if (m_uPostLen > MAX_POST_SIZE) +@@ -170,6 +170,14 @@ void CHTTPSock::ReadLine(const CString& + } else if (sLine.empty()) { + m_bGotHeader = true; + ++ if (!m_sUser.empty()) { ++ m_bLoggedIn = OnLogin(m_sUser, m_sPass, true); ++ if (!m_bLoggedIn) { ++ // Error message already was sent ++ return; ++ } ++ } ++ + if (m_bPost) { + m_sPostData = GetInternalReadBuffer(); + CheckPost(); diff --git a/net/znc/patches/006-Fix-954-Startup-failure-when-simple_away-is-loaded-a.patch b/net/znc/patches/006-Fix-954-Startup-failure-when-simple_away-is-loaded-a.patch new file mode 100644 index 000000000..ab0429357 --- /dev/null +++ b/net/znc/patches/006-Fix-954-Startup-failure-when-simple_away-is-loaded-a.patch @@ -0,0 +1,24 @@ +From 703a244b9b8c1b4af02a6132c5c70a748d98e3f8 Mon Sep 17 00:00:00 2001 +From: J-P Nurmi +Date: Tue, 28 Apr 2015 10:00:55 +0200 +Subject: [PATCH] Fix #954: Startup failure when simple_away is loaded + after awaynick + +--- + src/User.cpp | 5 +++++ + 1 file changed, 5 insertions(+) + +--- a/src/User.cpp ++++ b/src/User.cpp +@@ -1101,6 +1101,11 @@ bool CUser::LoadModule(const CString& sM + CFile fNVFile = CFile(GetUserPath() + "/moddata/" + sModName + "/.registry"); + + for (vector::iterator it = m_vIRCNetworks.begin(); it != m_vIRCNetworks.end(); ++it) { ++ // Check whether the network already has this module loaded (#954) ++ if ((*it)->GetModules().FindModule(sModName)) { ++ continue; ++ } ++ + if (fNVFile.Exists()) { + CString sNetworkModPath = (*it)->GetNetworkPath() + "/moddata/" + sModName; + if (!CFile::Exists(sNetworkModPath)) { diff --git a/net/znc/patches/001-move_rootcheck_after_config.patch b/net/znc/patches/100-move_rootcheck_after_config.patch similarity index 78% rename from net/znc/patches/001-move_rootcheck_after_config.patch rename to net/znc/patches/100-move_rootcheck_after_config.patch index 8b3e3e703..84ee6aa6f 100644 --- a/net/znc/patches/001-move_rootcheck_after_config.patch +++ b/net/znc/patches/100-move_rootcheck_after_config.patch @@ -1,15 +1,15 @@ -From 5f655f9a25a377c01cb15517859eb514628a43d4 Mon Sep 17 00:00:00 2001 +From adf42357c9043c38d9a9b47544a1b46445bdae19 Mon Sep 17 00:00:00 2001 From: Jonas Gorski 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(-) + src/main.cpp | 27 ++++++++++++++------------- + 1 file changed, 14 insertions(+), 13 deletions(-) --- a/src/main.cpp +++ b/src/main.cpp -@@ -243,19 +243,6 @@ int main(int argc, char** argv) { +@@ -303,19 +303,6 @@ int main(int argc, char** argv) { CUtils::PrintStatus(true, ""); } @@ -17,7 +17,7 @@ Subject: [PATCH] Move the root check to after config parsing - 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; +- CZNC::DestroyInstance(); - return 1; - } - CUtils::PrintError("You have been warned."); @@ -28,8 +28,8 @@ Subject: [PATCH] Move the root check to after config parsing - if (bMakeConf) { if (!pZNC->WriteNewConfig(sConfig)) { - delete pZNC; -@@ -276,6 +263,20 @@ int main(int argc, char** argv) { + CZNC::DestroyInstance(); +@@ -337,6 +324,20 @@ int main(int argc, char** argv) { return 1; } @@ -37,7 +37,7 @@ Subject: [PATCH] Move the root check to after config parsing + 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; ++ CZNC::DestroyInstance(); + return 1; + } + CUtils::PrintError("You have been warned."); diff --git a/net/znc/patches/003-Reduce_rebuild_time.patch b/net/znc/patches/101-Reduce_rebuild_time.patch similarity index 70% rename from net/znc/patches/003-Reduce_rebuild_time.patch rename to net/znc/patches/101-Reduce_rebuild_time.patch index 25c08e5b3..60d335c74 100644 --- a/net/znc/patches/003-Reduce_rebuild_time.patch +++ b/net/znc/patches/101-Reduce_rebuild_time.patch @@ -1,27 +1,28 @@ -From 94aff4c3389111fc85054eb06b40bea26a216d0c Mon Sep 17 00:00:00 2001 +From 0527869a72c27bfb25b5f92fdd77a04c39d939db Mon Sep 17 00:00:00 2001 From: Jonas Gorski Date: Sat, 16 Apr 2011 05:51:04 +0200 -Subject: [PATCH] Don't rebuild everything when the Makefile's timestamp changed +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(-) + Makefile.in | 2 +- + modules/Makefile.in | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) --- a/Makefile.in +++ b/Makefile.in -@@ -104,7 +104,7 @@ clean: +@@ -112,7 +112,7 @@ clean: distclean: clean rm -rf $(DISTCLEAN) --src/%.o: src/%.cpp Makefile -+src/%.o: src/%.cpp +-src/%.o: src/%.cpp Makefile include/znc/Csocket.h ++src/%.o: src/%.cpp include/znc/Csocket.h @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: +@@ -112,12 +112,12 @@ install_datadir: clean: rm -rf $(CLEAN) diff --git a/net/znc/patches/004-restore_droproot.patch b/net/znc/patches/102-restore_droproot.patch similarity index 100% rename from net/znc/patches/004-restore_droproot.patch rename to net/znc/patches/102-restore_droproot.patch diff --git a/sound/forked-daapd/Makefile b/sound/forked-daapd/Makefile index 8599c3831..51f459f0f 100644 --- a/sound/forked-daapd/Makefile +++ b/sound/forked-daapd/Makefile @@ -8,9 +8,9 @@ include $(TOPDIR)/rules.mk PKG_NAME:=forked-daapd -PKG_VERSION:=22.3 -PKG_RELEASE:=20150222 -PKG_REV:=81b0d330691ce22879514af04c7d831bca8a6e19 +PKG_VERSION:=23.2 +PKG_RELEASE:=20150622 +PKG_REV:=227017ef5ba8df921b2f1db681a46494ec296b8b PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) @@ -35,29 +35,36 @@ CATEGORY:=Sound TITLE:=iTunes (DAAP) server for Apple Remote and AirPlay URL:=https://github.com/ejurgensen/forked-daapd DEPENDS:=+libgpg-error +libgcrypt +libgdbm +zlib +libexpat +libunistring \ - +libevent2 +libdaemon +libantlr3c +confuse +glib2 +alsa-lib +libffmpeg-full \ + +libevent2 +libdaemon +libantlr3c +confuse +alsa-lib +libffmpeg-full \ +mxml +libavahi-client +sqlite3-cli +libplist +libcurl endef +define Package/forked-daapd/description + forked-daapd is a Linux/FreeBSD DAAP (iTunes), MPD (Music Player Daemon) and + RSP (Roku) media server. It has support for AirPlay devices/speakers, Apple + Remote (and compatibles), MPD clients, internet radio and LastFM. It does not + support AirPlay video. +endef + define Package/forked-daapd/conffiles /etc/forked-daapd.conf endef CONFIGURE_ARGS += \ --enable-itunes \ - --enable-lastfm + --enable-lastfm \ + --enable-mpd TARGET_CFLAGS += $(FPIC) TARGET_LDFLAGS += -Wl,-rpath-link,$(STAGING_DIR)/usr/lib define Package/forked-daapd/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/forked-daapd $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/etc - $(INSTALL_DATA) ./files/forked-daapd.conf $(1)/etc/ - $(INSTALL_DIR) $(1)/usr/lib + $(INSTALL_CONF) ./files/forked-daapd.conf $(1)/etc/forked-daapd.conf $(INSTALL_DIR) $(1)/usr/lib/forked-daapd $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/forked-daapd/* $(1)/usr/lib/forked-daapd/ - $(INSTALL_DIR) $(1)/usr/sbin - $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/forked-daapd $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/forked-daapd.init $(1)/etc/init.d/forked-daapd endef diff --git a/sound/forked-daapd/files/forked-daapd.conf b/sound/forked-daapd/files/forked-daapd.conf index 63c0ac3db..0f756e0f8 100644 --- a/sound/forked-daapd/files/forked-daapd.conf +++ b/sound/forked-daapd/files/forked-daapd.conf @@ -14,7 +14,7 @@ general { uid = "daapd" # Database location -# db_path = "/var/cache/forked-daapd/songs3.db" + db_path = "/var/cache/forked-daapd/songs3.db" # Log file and level # Available levels: fatal, log, warning, info, debug, spam @@ -28,7 +28,7 @@ general { ipv6 = no # Location of cache database -# cache_path = "/var/cache/forked-daapd/cache.db" + cache_path = "/var/cache/forked-daapd/cache.db" # DAAP requests that take longer than this threshold (in msec) get their # replies cached for next time. Set to 0 to disable caching. @@ -78,6 +78,12 @@ library { # (changing this setting only takes effect after rescan, see the README) compilation_artist = "Various artists" + # Internet streams in your playlists will by default be shown in the + # "Radio" library, like iTunes does. However, some clients (like + # TunesRemote+) won't show the "Radio" library. If you would also like + # to have them shown like normal playlists, you can enable this option. +# radio_playlists = false + # There are 5 default playlists: "Library", "Music", "Movies", "TV Shows" # and "Podcasts". Here you can change the names of these playlists. # name_library = "Library" @@ -86,6 +92,7 @@ library { # name_tvshows = "TV Shows" # name_podcasts = "Podcasts" # name_audiobooks = "Audiobooks" +# name_radio = "Radio" # Artwork file names (without file type extension) # forked-daapd will look for jpg and png files with these base names @@ -152,19 +159,6 @@ audio { # password = "s1kr3t" #} -# Spotify settings (only have effect if Spotify enabled - see README/INSTALL) -spotify { - # Directory where user settings should be stored (credentials) -# settings_dir = "/var/cache/forked-daapd/libspotify" - - # Cache directory -# cache_dir = "/tmp" - - # Set preferred bitrate for music streaming - # 0: No preference (default), 1: 96kbps, 2: 160kbps, 3: 320kbps -# bitrate = 0 -} - # SQLite configuration (allows to modify the operation of the SQLite databases) # Make sure to read the SQLite documentation for the corresponding PRAGMA statements as # changing them from the defaults may increase the possibility of database corruptions! diff --git a/sound/mocp/Makefile b/sound/mocp/Makefile index 5552ec962..d1917bfbe 100644 --- a/sound/mocp/Makefile +++ b/sound/mocp/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=moc PKG_VERSION:=2.5.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://ftp.daper.net/pub/soft/moc/stable/ @@ -38,6 +38,8 @@ define Package/moc/description MOC (music on console) is a console audio player for LINUX/UNIX designed to be powerful and easy to use. endef +TARGET_CFLAGS+=-D_GNU_SOURCE + define Build/Configure $(call Build/Configure/Default, \ $(if $(CONFIG_BUILD_PATENTED),,--without-mp3) \ diff --git a/sound/mpc/Makefile b/sound/mpc/Makefile index e6b62633a..3109b1c08 100644 --- a/sound/mpc/Makefile +++ b/sound/mpc/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mpc -PKG_VERSION:=0.26 -PKG_RELEASE:=2 +PKG_VERSION:=0.27 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://www.musicpd.org/download/mpc/0 -PKG_MD5SUM:=d4f37e7e6b32c804a870192d1eb86199 +PKG_MD5SUM:=d9430db9b9d7fb1eadbe4d13e8d97c66 PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING PKG_MAINTAINER:=Ted Hess diff --git a/sound/mpd/Makefile b/sound/mpd/Makefile index 1b1e8686e..845360301 100644 --- a/sound/mpd/Makefile +++ b/sound/mpd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mpd -PKG_VERSION:=0.18.21 +PKG_VERSION:=0.19.10 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.18/ -PKG_MD5SUM:=945879f55acc256d30a5f69787338ceb +PKG_SOURCE_URL:=http://www.musicpd.org/download/mpd/0.19/ +PKG_MD5SUM:=da4bc3e47afd0faf9e7a67168e012102 PKG_MAINTAINER:=Ted Hess PKG_LICENSE:=GPL-2.0 @@ -28,15 +28,15 @@ PKG_CONFIG_DEPENDS:= \ PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk -include $(INCLUDE_DIR)/nls.mk define Package/mpd/Default SECTION:=sound CATEGORY:=Sound TITLE:=Music Player Daemon URL:=http://www.musicpd.org/ - DEPENDS:= +glib2 +libcurl +libpthread +libmpdclient $(ICONV_DEPENDS) +libstdcpp \ - +libflac +BUILD_PATENTED:libmad +libvorbisidec +AUDIO_SUPPORT:alsa-lib + DEPENDS:= +glib2 +libcurl +libpthread +libmpdclient +libstdcpp \ + +libflac +BUILD_PATENTED:libmad +libvorbisidec +AUDIO_SUPPORT:alsa-lib \ + +boost +boost-container +libexpat endef define Package/mpd/Default/description @@ -51,7 +51,7 @@ $(call Package/mpd/Default) TITLE+= (full) DEPENDS+= \ +libaudiofile +BUILD_PATENTED:libfaad2 +libffmpeg +libid3tag \ - +libmms +libogg +libsndfile +libvorbis + +libmms +libogg +libsndfile +libvorbis +libupnp PROVIDES:=mpd VARIANT:=full endef @@ -105,17 +105,15 @@ CONFIGURE_ARGS += \ $(call autoconf_bool,CONFIG_IPV6,ipv6) \ --disable-debug \ --disable-documentation \ - --disable-gprof \ --disable-test \ --disable-werror \ \ --disable-ao \ --disable-bzip2 \ - --enable-cue \ - --disable-ffado \ --disable-fluidsynth \ --disable-gme \ --enable-inotify \ + --disable-icu \ --disable-eventfd \ --disable-iso9660 \ --disable-jack \ @@ -126,13 +124,11 @@ CONFIGURE_ARGS += \ --disable-modplug \ --disable-mpc \ --disable-mpg123 \ - --disable-mvp \ --disable-openal \ --disable-opus \ --disable-pulse \ --disable-sidplay \ --disable-solaris-output \ - --disable-soup \ --disable-sqlite \ --disable-twolame-encoder \ --enable-wave-encoder \ @@ -155,13 +151,13 @@ CONFIGURE_VARS += \ $(if $(CONFIG_BUILD_PATENTED),MAD_CFLAGS="$(TARGET_CFLAGS)") \ $(if $(CONFIG_BUILD_PATENTED),MAD_LIBS="$(TARGET_LDFLAGS) -lmad") \ -TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib $(if $(ICONV_FULL),-liconv) +TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib ifeq ($(BUILD_VARIANT),full) CONFIGURE_ARGS += \ + --enable-upnp \ $(call autoconf_bool,CONFIG_BUILD_PATENTED,aac) \ - $(call autoconf_bool,CONFIG_AUDIO_SUPPORT,alsa) \ --enable-audiofile \ --enable-fifo \ --enable-ffmpeg \ @@ -184,15 +180,13 @@ ifeq ($(BUILD_VARIANT),mini) # oggflac is not compatible with tremor CONFIGURE_ARGS += \ + --disable-upnp \ --disable-aac \ - --disable-alsa \ --disable-audiofile \ --disable-fifo \ --disable-ffmpeg \ --disable-id3 \ - --disable-lastfm \ --disable-mms \ - --disable-oggflac \ --disable-pipe-output \ --disable-recorder-output \ --disable-shout \ diff --git a/sound/mpd/patches/210-support_raw_pcm_streams.patch b/sound/mpd/patches/210-support_raw_pcm_streams.patch index 2fe086bab..2c94c262c 100644 --- a/sound/mpd/patches/210-support_raw_pcm_streams.patch +++ b/sound/mpd/patches/210-support_raw_pcm_streams.patch @@ -1,6 +1,6 @@ ---- a/src/decoder/FfmpegDecoderPlugin.cxx -+++ b/src/decoder/FfmpegDecoderPlugin.cxx -@@ -634,6 +634,7 @@ static const char *const ffmpeg_mime_typ +--- a/src/decoder/plugins/FfmpegDecoderPlugin.cxx ++++ b/src/decoder/plugins/FfmpegDecoderPlugin.cxx +@@ -765,6 +765,7 @@ static const char *const ffmpeg_mime_typ "audio/qcelp", "audio/vorbis", "audio/vorbis+ogg", diff --git a/sound/mpd/patches/220-handle_slow_server_stream_startup.patch b/sound/mpd/patches/220-handle_slow_server_stream_startup.patch index 2c25c33e6..15c51f898 100644 --- a/sound/mpd/patches/220-handle_slow_server_stream_startup.patch +++ b/sound/mpd/patches/220-handle_slow_server_stream_startup.patch @@ -1,6 +1,6 @@ ---- a/src/decoder/FfmpegDecoderPlugin.cxx -+++ b/src/decoder/FfmpegDecoderPlugin.cxx -@@ -373,6 +373,13 @@ ffmpeg_probe(Decoder *decoder, InputStre +--- a/src/decoder/plugins/FfmpegDecoderPlugin.cxx ++++ b/src/decoder/plugins/FfmpegDecoderPlugin.cxx +@@ -458,6 +458,13 @@ ffmpeg_probe(Decoder *decoder, InputStre unsigned char buffer[BUFFER_SIZE]; size_t nbytes = decoder_read(decoder, is, buffer, BUFFER_SIZE); diff --git a/sound/pianod/Makefile b/sound/pianod/Makefile new file mode 100644 index 000000000..0c6689454 --- /dev/null +++ b/sound/pianod/Makefile @@ -0,0 +1,110 @@ +# +# Copyright (C) 2015 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:=pianod +PKG_VERSION:=173 +PKG_RELEASE:=3 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://deviousfish.com/Downloads/pianod/ +PKG_MD5SUM:=be0cec19ea6df1c4bc6c1cac8e253445 + +PKG_MAINTAINER:=Ted Hess + +PKG_LICENSE:=MIT VARIOUS +PKG_LICENSE_FILES:=COPYING + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/pianod + SECTION:=sound + CATEGORY:=Sound + DEPENDS:=+libao +libfaad2 +libmad +libpolarssl +libjson-c +libgcrypt +libpthread + TITLE:=Pandora radio daemon + USERID:=pianod=88:pianod=88 + URL:=http://deviousfish.com/pianod/ +endef + +define Package/pianod/description + pianod is a Pandora music player client with line-oriented and Websocket control interfaces. + A simple protocol makes for easy clients, mix scripting, integration with a + home automation system, use as multiple-user music system for home or office. + Documentation and configuration information can be found at: + http://deviousfish.com/pianod/ +endef + +define Package/pianod-client + SECTION:=sound + CATEGORY:=Sound + DEPENDS:=+pianod + TITLE:=Pandora radio daemon WebUI + URL:=http://deviousfish.com/pianod/ +endef + +define Package/pianod-client/description + Web client UI and remote player viewer for pianod + Examples --- (Note: The viewer.* files need not be on the pianod host) + Main interface: http://pianod-host:4446/pianod + Remote viewer: file:////viewer.html?server=pianod-host:4446 --or-- + http://pianod-host:4446/pianod/viewer.html?server=pianod-host:4446 +endef + +CONFIGURE_ARGS+= --with-polarssl + +PIANOD_CLIENT:=pianod-client-compiled-51.tar.gz + +define Download/pianod-client + URL:=$(PKG_SOURCE_URL) + FILE:=$(PIANOD_CLIENT) + MD5SUM:=abbdee5627bcee6a00c8304da8b4e2e7 +endef + +define Package/pianod/conffiles +/etc/pianod/startscript +/etc/pianod/users +endef + +define Build/Prepare + $(call Build/Prepare/Default) + ifneq ($(CONFIG_PACKAGE_pianod-client),) + $(eval $(call Download,pianod-client)) + mkdir -p $(PKG_BUILD_DIR)/pianod-client + $(TAR) -xf $(DL_DIR)/$(PIANOD_CLIENT) --strip=1 -C $(PKG_BUILD_DIR)/pianod-client + endif +endef + +define Package/pianod-client/Configure +endef + +define Package/pianod-client/Compile +endef + +define Package/pianod/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/pianod $(1)/usr/bin/ +# These scripts need ksh (install mksh and link) +# $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/piano $(1)/usr/bin/ +# $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/runmix $(1)/usr/bin/ + + $(INSTALL_DIR) $(1)/etc/pianod + $(INSTALL_DATA) $(PKG_BUILD_DIR)/contrib/startscript-example $(1)/etc/pianod/startscript + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/pianod.init $(1)/etc/init.d/pianod +endef + +define Package/pianod-client/install + $(INSTALL_DIR) $(1)/www/pianod + $(INSTALL_DATA) $(PKG_BUILD_DIR)/pianod-client/*.{html,js,gif,jpeg,css} $(1)/www/pianod/ +endef + +$(eval $(call BuildPackage,pianod)) +$(eval $(call BuildPackage,pianod-client)) diff --git a/sound/pianod/files/pianod.init b/sound/pianod/files/pianod.init new file mode 100644 index 000000000..b232944e5 --- /dev/null +++ b/sound/pianod/files/pianod.init @@ -0,0 +1,42 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2015 OpenWrt.org + +NAME=pianod +START=95 + +USE_PROCD=1 + +PD_USER=$NAME +PD_STARTSCRIPT=/etc/$NAME/startscript +PD_PASSWDFILE=/etc/$NAME/users +PD_WEBUI=/www/$NAME + +start_service() { + # Take group ownership of audio devices + chown root:$NAME /dev/snd/* /dev/mixer /dev/dsp + chmod 664 /dev/snd/* /dev/mixer /dev/dsp + + procd_open_instance + + procd_set_param command "/usr/bin/$NAME" + + procd_append_param command -n $PD_USER + procd_append_param command -i "$PD_STARTSCRIPT" + procd_append_param command -u "$PD_PASSWDFILE" + [ -d "$PD_WEBUI" ] && procd_append_param command -c "$PD_WEBUI" + # No HTTPS support without certificates + procd_append_param command -s 0 + + procd_close_instance +} + +# Wait for service to exit and release sockets +reload_service() { + stop + sleep 2 + start +} + +restart() { + reload_service +} diff --git a/sound/pianod/patches/005-Fix_IPV6_socket_handling.patch b/sound/pianod/patches/005-Fix_IPV6_socket_handling.patch new file mode 100644 index 000000000..883495a1a --- /dev/null +++ b/sound/pianod/patches/005-Fix_IPV6_socket_handling.patch @@ -0,0 +1,75 @@ +--- a/src/libwaitress/waitress.c ++++ b/src/libwaitress/waitress.c +@@ -805,34 +805,37 @@ static WaitressReturn_t WaitressConnect + int pollres; + + /* we need shorter timeouts for connect() */ +- fcntl (sock, F_SETFL, O_NONBLOCK); ++ pollres = fcntl (sock, F_SETFL, O_NONBLOCK); ++ assert (pollres != -1); + +- /* increase socket receive buffer */ +- const int sockopt = 256*1024; +- setsockopt (sock, SOL_SOCKET, SO_RCVBUF, &sockopt, +- sizeof (sockopt)); +- +- /* non-blocking connect will return immediately */ +- connect (sock, gacurr->ai_addr, gacurr->ai_addrlen); +- +- pollres = WaitressPollLoop (sock, POLLOUT, waith->timeout); +- if (pollres == 0) { +- ret = WAITRESS_RET_TIMEOUT; +- } else if (pollres == -1) { +- ret = WAITRESS_RET_ERR; +- } else { +- /* check connect () return value */ +- socklen_t pollresSize = sizeof (pollres); +- getsockopt (sock, SOL_SOCKET, SO_ERROR, &pollres, +- &pollresSize); +- if (pollres != 0) { +- ret = WAITRESS_RET_CONNECT_REFUSED; ++ if (connect (sock, gacurr->ai_addr, gacurr->ai_addrlen) != -1) { ++ /* working */ ++ waith->request.sockfd = sock; ++ break; ++ } else if (errno == EINPROGRESS) { ++ /* wait for connect to succeed */ ++ pollres = WaitressPollLoop (sock, POLLOUT, waith->timeout); ++ if (pollres == 0) { ++ ret = WAITRESS_RET_TIMEOUT; ++ } else if (pollres == -1) { ++ ret = WAITRESS_RET_ERR; + } else { +- /* this one is working */ +- waith->request.sockfd = sock; +- break; ++ /* check connect () return value */ ++ socklen_t pollresSize = sizeof (pollres); ++ getsockopt (sock, SOL_SOCKET, SO_ERROR, &pollres, ++ &pollresSize); ++ if (pollres != 0) { ++ ret = WAITRESS_RET_CONNECT_REFUSED; ++ } else { ++ /* this one is working */ ++ waith->request.sockfd = sock; ++ break; ++ } + } ++ } else { ++ ret = WAITRESS_RET_ERR; + } ++ + close (sock); + } + } +--- a/src/libfootball/fb_service.c ++++ b/src/libfootball/fb_service.c +@@ -111,6 +111,8 @@ static bool fb_setup_socket (FB_SERVICE + service->socket [which] = 0; + } else { + fb_perror ("socket"); ++ // Element must be zero (not -1) ++ service->socket [which] = 0; + }; + return false; + } diff --git a/sound/pianod/patches/010-Configure_add_SSL_options.patch b/sound/pianod/patches/010-Configure_add_SSL_options.patch new file mode 100644 index 000000000..2c2677965 --- /dev/null +++ b/sound/pianod/patches/010-Configure_add_SSL_options.patch @@ -0,0 +1,42 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -31,8 +31,6 @@ AC_CHECK_LIB([pthread], [pthread_create] + # with it, but don't consider it an error. + # PKG_CHECK_MODULES only validates that pkg-config returns stuff; it doesn't + # validate that these are correct, so check lib to make sure they're right. +-PKG_CHECK_MODULES([gnutls], [gnutls],, +- [AC_MSG_WARN([No pkg-config for libgnutls])]) + PKG_CHECK_MODULES([ao], [ao],, + [AC_MSG_WARN([No pkg-config for libao])]) + PKG_CHECK_MODULES([mad], [mad],, +@@ -42,12 +40,28 @@ PKG_CHECK_MODULES([json], [json-c],, + [PKG_CHECK_MODULES([json], [json0],, + [AC_MSG_WARN([No pkg-config for json-c (aka libjson0, libjson)])])])]) + ++ + # Network communication stuff: + AC_CHECK_LIB([gcrypt], [gcry_cipher_open],, + [AC_MSG_ERROR([Cannot find required library: libgcrypt],1)]) +-AC_CHECK_LIB([gnutls], [gnutls_record_recv],, ++# Check for SSL option ++AC_ARG_WITH(polarssl, [ --with-polarssl Build waitress with PolarSSL (default GNUTLS)], [ ++ AC_MSG_RESULT(>>Using PolarSSL) ++ HAS_POLARSSL=1 ++ AC_DEFINE([USE_POLARSSL], 1, [Build for PolarSSL]) ++ PKG_CHECK_MODULES([polarssl], [polarssl],, ++ [AC_MSG_WARN([No pkg-config for libpolarssl])]) ++ AC_CHECK_LIB([polarssl], [ssl_set_session],, ++ [AC_MSG_ERROR([Cannot find required library: libpolarssl (aka polarssl)],1)])] ) ++AM_CONDITIONAL([USE_POLARSSL],[test "x$HAS_POLARSSL" = "x1"]) ++ ++if test "x$HAS_POLARSSL" != x1 ; then ++ PKG_CHECK_MODULES([gnutls], [gnutls],, ++ [AC_MSG_WARN([No pkg-config for libgnutls])]) ++ AC_CHECK_LIB([gnutls], [gnutls_record_recv],, + [AC_MSG_ERROR([Cannot find required library: libgnutls (aka gnutls)],1)]) +-AC_CHECK_FUNCS(gnutls_transport_set_int2 gnutls_sec_param_to_pk_bits) ++ AC_CHECK_FUNCS(gnutls_transport_set_int2 gnutls_sec_param_to_pk_bits) ++fi + + # Bloody json library may be linked via -ljson, or -ljson-c depending on + # the platform. Try both. diff --git a/sound/pianod/patches/020-Use_package_config_h_for_all_modules.patch b/sound/pianod/patches/020-Use_package_config_h_for_all_modules.patch new file mode 100644 index 000000000..228710b05 --- /dev/null +++ b/sound/pianod/patches/020-Use_package_config_h_for_all_modules.patch @@ -0,0 +1,59 @@ +--- a/src/libpiano/config.h ++++ /dev/null +@@ -1 +0,0 @@ +-#define PACKAGE "libpiano" +--- a/src/libwaitress/config.h ++++ /dev/null +@@ -1 +0,0 @@ +-#define PACKAGE "libwaitress" +--- a/src/libpiano/piano.h ++++ b/src/libpiano/piano.h +@@ -39,6 +39,8 @@ THE SOFTWARE. + * http://pan-do-ra-api.wikia.com + */ + ++#define LIBPIANO_NAME "libpiano" ++ + #define PIANO_RPC_HOST "tuner.pandora.com" + #define PIANO_RPC_PATH "/services/json/?" + +--- a/src/libwaitress/waitress.c ++++ b/src/libwaitress/waitress.c +@@ -918,14 +918,14 @@ static WaitressReturn_t WaitressSendRequ + if (WaitressProxyEnabled (waith) && !waith->url.tls) { + snprintf (buf, WAITRESS_BUFFER_SIZE, + "%s http://%s:%s/%s HTTP/" WAITRESS_HTTP_VERSION "\r\n" +- "Host: %s\r\nUser-Agent: " PACKAGE "\r\nConnection: Close\r\n", ++ "Host: %s\r\nUser-Agent: " LIBWAITRESS_NAME "\r\nConnection: Close\r\n", + (waith->method == WAITRESS_METHOD_GET ? "GET" : "POST"), + waith->url.host, + WaitressDefaultPort (&waith->url), path, waith->url.host); + } else { + snprintf (buf, WAITRESS_BUFFER_SIZE, + "%s /%s HTTP/" WAITRESS_HTTP_VERSION "\r\n" +- "Host: %s\r\nUser-Agent: " PACKAGE "\r\nConnection: Close\r\n", ++ "Host: %s\r\nUser-Agent: " LIBWAITRESS_NAME "\r\nConnection: Close\r\n", + (waith->method == WAITRESS_METHOD_GET ? "GET" : "POST"), + path, waith->url.host); + } +--- a/src/libwaitress/waitress.h ++++ b/src/libwaitress/waitress.h +@@ -29,6 +29,8 @@ THE SOFTWARE. + #include + #include + ++#define LIBWAITRESS_NAME "libwaitress" ++ + #define WAITRESS_BUFFER_SIZE 10*1024 + + typedef enum { +--- a/src/libpiano/request.c ++++ b/src/libpiano/request.c +@@ -40,6 +40,7 @@ THE SOFTWARE. + #include + #include + /* needed for urlencode */ ++#include + #include + + #include "piano.h" diff --git a/sound/pianod/patches/030-Waitress_add_polarssl_variant.patch b/sound/pianod/patches/030-Waitress_add_polarssl_variant.patch new file mode 100644 index 000000000..b2a657645 --- /dev/null +++ b/sound/pianod/patches/030-Waitress_add_polarssl_variant.patch @@ -0,0 +1,333 @@ +--- a/src/libwaitress/waitress.h ++++ b/src/libwaitress/waitress.h +@@ -27,7 +27,12 @@ THE SOFTWARE. + #include + #include + #include ++ ++#if defined(USE_POLARSSL) ++typedef struct _polarssl_ctx polarssl_ctx; ++#else + #include ++#endif + + #define LIBWAITRESS_NAME "libwaitress" + +@@ -102,8 +107,9 @@ typedef struct { + WaitressUrl_t url; + WaitressUrl_t proxy; + ++#if !defined(USE_POLARSSL) + gnutls_certificate_credentials_t tlsCred; +- ++#endif + /* per-request data */ + struct { + int sockfd; +@@ -121,7 +127,11 @@ typedef struct { + WaitressReturn_t (*read) (void *, char *, const size_t, size_t *); + WaitressReturn_t (*write) (void *, const char *, const size_t); + ++#if defined(USE_POLARSSL) ++ polarssl_ctx* sslCtx; ++#else + gnutls_session_t tlsSession; ++#endif + } request; + } WaitressHandle_t; + +--- a/src/pianod.c ++++ b/src/pianod.c +@@ -531,8 +531,11 @@ static bool initialize_libraries (APPSTA + gcry_check_version (NULL); + gcry_control (GCRYCTL_DISABLE_SECMEM, 0); + gcry_control (GCRYCTL_INITIALIZATION_FINISHED, 0); ++ ++#if !defined(USE_POLARSSL) + int crystatus = gnutls_global_init (); + if (crystatus == GNUTLS_E_SUCCESS) { ++#endif + PianoReturn_t status = PianoInit (&app->ph, app->settings.partnerUser, app->settings.partnerPassword, + app->settings.device, app->settings.inkey, app->settings.outkey); + if (status == PIANO_RET_OK) { +@@ -545,11 +548,13 @@ static bool initialize_libraries (APPSTA + } else { + flog (LOG_ERROR, "initialize_libraries: PianoInit: %s", PianoErrorToStr (status)); + } ++#if !defined(USE_POLARSSL) + gnutls_global_deinit (); + } else { + flog (LOG_ERROR, "initialize_libraries: gnutls_global_init: %s", gcry_strerror (crystatus)); + + } ++#endif + return false; + } + +@@ -728,7 +733,9 @@ int main (int argc, char **argv) { + PianoDestroyPlaylist (app.song_history); + PianoDestroyPlaylist (app.playlist); + WaitressFree (&app.waith); ++#if !defined(USE_POLARSSL) + gnutls_global_deinit (); ++#endif + settings_destroy (&app.settings); + } + +--- a/src/libwaitress/waitress.c ++++ b/src/libwaitress/waitress.c +@@ -41,11 +41,33 @@ THE SOFTWARE. + #include + #include + +-#include + + #include "config.h" + #include "waitress.h" + ++#if defined(USE_POLARSSL) ++ ++#include ++#include ++#include ++#include ++#include ++ ++struct _polarssl_ctx ++{ ++ ssl_context ssl; ++ ssl_session session; ++ entropy_context entrophy; ++ ctr_drbg_context rnd; ++}; ++ ++#else ++ ++// Use gnutls by default (USE_POLARSSL not defined) ++#include ++ ++#endif ++ + #define strcaseeq(a,b) (strcasecmp(a,b) == 0) + #define WAITRESS_HTTP_VERSION "1.1" + +@@ -56,6 +78,13 @@ typedef struct { + + static WaitressReturn_t WaitressReceiveHeaders (WaitressHandle_t *, size_t *); + ++// gnutls wants (void *) and polarssl want (unsigned char *) ++#if defined(USE_POLARSSL) ++#define BUFFER_CAST unsigned char ++#else ++#define BUFFER_CAST void ++#endif ++ + #define READ_RET(buf, count, size) \ + if ((wRet = waith->request.read (waith, buf, count, size)) != \ + WAITRESS_RET_OK) { \ +@@ -444,7 +473,7 @@ static int WaitressPollLoop (int fd, sho + * @param write count bytes + * @return number of written bytes or -1 on error + */ +-static ssize_t WaitressPollWrite (void *data, const void *buf, size_t count) { ++static ssize_t WaitressPollWrite (void *data, const BUFFER_CAST *buf, size_t count) { + int pollres = -1; + ssize_t retSize; + WaitressHandle_t *waith = data; +@@ -478,13 +507,20 @@ static WaitressReturn_t WaitressOrdinary + return waith->request.readWriteRet; + } + +-static WaitressReturn_t WaitressGnutlsWrite (void *data, const char *buf, ++static WaitressReturn_t WaitressTlsWrite (void *data, const char *buf, + const size_t size) { + WaitressHandle_t *waith = data; ++#if defined(USE_POLARSSL) ++ ++ if (ssl_write (&waith->request.sslCtx->ssl, buf, size) < 0) { ++ return WAITRESS_RET_TLS_WRITE_ERR; ++ } ++#else + + if (gnutls_record_send (waith->request.tlsSession, buf, size) < 0) { + return WAITRESS_RET_TLS_WRITE_ERR; + } ++#endif + return waith->request.readWriteRet; + } + +@@ -494,7 +530,7 @@ static WaitressReturn_t WaitressGnutlsWr + * @param buffer size + * @return number of read bytes or -1 on error + */ +-static ssize_t WaitressPollRead (void *data, void *buf, size_t count) { ++static ssize_t WaitressPollRead (void *data, BUFFER_CAST *buf, size_t count) { + int pollres = -1; + ssize_t retSize; + WaitressHandle_t *waith = data; +@@ -531,16 +567,34 @@ static WaitressReturn_t WaitressOrdinary + return waith->request.readWriteRet; + } + +-static WaitressReturn_t WaitressGnutlsRead (void *data, char *buf, ++static WaitressReturn_t WaitressTlsRead (void *data, char *buf, + const size_t size, size_t *retSize) { + WaitressHandle_t *waith = data; + ++#if defined(USE_POLARSSL) ++ int ret; ++ ++ *retSize = 0; ++ waith->request.readWriteRet = WAITRESS_RET_OK; ++ ret = ssl_read (&waith->request.sslCtx->ssl, buf, size); ++ ++ if (ret < 0) { ++ if (ret != POLARSSL_ERR_SSL_PEER_CLOSE_NOTIFY) { ++ waith->request.readWriteRet = WAITRESS_RET_TLS_READ_ERR; ++ } ++ ++ return waith->request.readWriteRet; ++ } ++ ++ *retSize = ret; ++#else + ssize_t ret = gnutls_record_recv (waith->request.tlsSession, buf, size); + if (ret < 0) { + return WAITRESS_RET_TLS_READ_ERR; + } else { + *retSize = ret; + } ++#endif + return waith->request.readWriteRet; + } + +@@ -727,10 +781,28 @@ static int WaitressParseStatusline (cons + /* verify server certificate + */ + static WaitressReturn_t WaitressTlsVerify (const WaitressHandle_t *waith) { ++ ++#if defined(USE_POLARSSL) ++ unsigned char fingerprint[20]; ++ ++ const x509_crt* cert = ssl_get_peer_cert (&waith->request.sslCtx->ssl); ++ ++ if (NULL == cert) { ++ return WAITRESS_RET_TLS_HANDSHAKE_ERR; ++ } ++ ++ sha1 (cert->raw.p, cert->raw.len, fingerprint); ++ ++ if (memcmp (fingerprint, waith->tlsFingerprint, sizeof (fingerprint)) != 0) { ++ return WAITRESS_RET_TLS_FINGERPRINT_MISMATCH; ++ } ++ ++#else + gnutls_session_t session = waith->request.tlsSession; + unsigned int certListSize; + const gnutls_datum_t *certList; + gnutls_x509_crt_t cert; ++ char fingerprint[20]; + + if (gnutls_certificate_type_get (session) != GNUTLS_CRT_X509) { + return WAITRESS_RET_TLS_HANDSHAKE_ERR; +@@ -750,7 +822,6 @@ static WaitressReturn_t WaitressTlsVerif + return WAITRESS_RET_TLS_HANDSHAKE_ERR; + } + +- char fingerprint[20]; + size_t fingerprintSize = sizeof (fingerprint); + if (gnutls_x509_crt_get_fingerprint (cert, GNUTLS_DIG_SHA1, fingerprint, + &fingerprintSize) != 0) { +@@ -763,7 +834,7 @@ static WaitressReturn_t WaitressTlsVerif + } + + gnutls_x509_crt_deinit (cert); +- ++#endif + return WAITRESS_RET_OK; + } + +@@ -876,6 +947,12 @@ static WaitressReturn_t WaitressConnect + } + } + ++#if defined(USE_POLARSSL) ++ ssl_set_hostname (&waith->request.sslCtx->ssl, waith->url.host); ++ if (ssl_handshake (&waith->request.sslCtx->ssl) != 0) { ++ return WAITRESS_RET_TLS_HANDSHAKE_ERR; ++ } ++#else + /* Ignore return code as connection will likely still succeed */ + gnutls_server_name_set (waith->request.tlsSession, GNUTLS_NAME_DNS, + waith->url.host, strlen (waith->url.host)); +@@ -883,14 +960,15 @@ static WaitressReturn_t WaitressConnect + if (gnutls_handshake (waith->request.tlsSession) != GNUTLS_E_SUCCESS) { + return WAITRESS_RET_TLS_HANDSHAKE_ERR; + } ++#endif + + if ((wRet = WaitressTlsVerify (waith)) != WAITRESS_RET_OK) { + return wRet; + } + + /* now we can talk encrypted */ +- waith->request.read = WaitressGnutlsRead; +- waith->request.write = WaitressGnutlsWrite; ++ waith->request.read = WaitressTlsRead; ++ waith->request.write = WaitressTlsWrite; + } + + return WAITRESS_RET_OK; +@@ -1116,6 +1194,21 @@ WaitressReturn_t WaitressFetchCall (Wait + waith->request.contentLengthKnown = false; + + if (waith->url.tls) { ++#if defined(USE_POLARSSL) ++ waith->request.sslCtx = calloc (1, sizeof(polarssl_ctx)); ++ ++ entropy_init (&waith->request.sslCtx->entrophy); ++ ctr_drbg_init (&waith->request.sslCtx->rnd, entropy_func, &waith->request.sslCtx->entrophy, "libwaitress", 11); ++ ssl_init (&waith->request.sslCtx->ssl); ++ ++ ssl_set_endpoint (&waith->request.sslCtx->ssl, SSL_IS_CLIENT); ++ ssl_set_authmode (&waith->request.sslCtx->ssl, SSL_VERIFY_NONE); ++ ssl_set_rng (&waith->request.sslCtx->ssl, ctr_drbg_random, &waith->request.sslCtx->rnd); ++ ssl_set_session (&waith->request.sslCtx->ssl, &waith->request.sslCtx->session); ++ ssl_set_bio (&waith->request.sslCtx->ssl, ++ WaitressPollRead, waith, ++ WaitressPollWrite, waith); ++#else + gnutls_init (&waith->request.tlsSession, GNUTLS_CLIENT); + gnutls_set_default_priority (waith->request.tlsSession); + +@@ -1133,6 +1226,7 @@ WaitressReturn_t WaitressFetchCall (Wait + WaitressPollRead); + gnutls_transport_set_push_function (waith->request.tlsSession, + WaitressPollWrite); ++#endif + } + + /* buffer is required for connect already */ +@@ -1144,15 +1238,22 @@ WaitressReturn_t WaitressFetchCall (Wait + if ((wRet = WaitressSendRequest (waith)) == WAITRESS_RET_OK) { + wRet = WaitressReceiveResponse (waith); + } ++#if !defined(USE_POLARSSL) + if (waith->url.tls) { + gnutls_bye (waith->request.tlsSession, GNUTLS_SHUT_RDWR); + } ++#endif + } + + /* cleanup */ + if (waith->url.tls) { ++#if defined(USE_POLARSSL) ++ ssl_free (&waith->request.sslCtx->ssl); ++ free (waith->request.sslCtx); ++#else + gnutls_deinit (waith->request.tlsSession); + gnutls_certificate_free_credentials (waith->tlsCred); ++#endif + } + if (waith->request.sockfd != -1) { + close (waith->request.sockfd); diff --git a/sound/pulseaudio/Makefile b/sound/pulseaudio/Makefile index e75e2c80c..a4a449b7c 100644 --- a/sound/pulseaudio/Makefile +++ b/sound/pulseaudio/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=pulseaudio PKG_VERSION:=6.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://freedesktop.org/software/pulseaudio/releases/ @@ -27,12 +27,11 @@ PKG_INSTALL = 1 include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/nls.mk -#TODO: split pulse into executable and library (or even better into several libraries since they're used as loadable modules, so not linked into) define Package/pulseaudio/Default SECTION:=sound CATEGORY:=Sound DEPENDS:=+libspeexdsp +libsndfile +libltdl +libpthread \ - +librt +alsa-lib +libjson +libopenssl +libwrap +libcap $(ICONV_DEPENDS) $(INTL_DEPENDS) + +librt +alsa-lib +libopenssl +libwrap +libcap $(ICONV_DEPENDS) $(INTL_DEPENDS) TITLE:=Network sound server MAINTAINER:=Peter Wagner URL:=http://www.pulseaudio.org @@ -42,6 +41,7 @@ endef define Package/pulseaudio-daemon $(call Package/pulseaudio/Default) + DEPENDS+= +libjson-c endef define Package/pulseaudio/Default/description @@ -62,7 +62,7 @@ endef define Package/pulseaudio-tools SECTION:=sound CATEGORY:=Sound - DEPENDS:=+libsndfile pulseaudio + DEPENDS:=+libsndfile +pulseaudio TITLE:=Tools for Pulseaudio URL:=http://www.pulseaudio.org endef diff --git a/sound/upmpdcli/Config.in b/sound/upmpdcli/Config.in new file mode 100644 index 000000000..fe3272296 --- /dev/null +++ b/sound/upmpdcli/Config.in @@ -0,0 +1,17 @@ +config PACKAGE_UPMPDCLI_SCCTL + bool "scctl command for configuring SongCast receivers" + default no + depends on PACKAGE_upmpdcli + help + Installs the scctl command. See the following link for more info: + http://www.lesbonscomptes.com/upmpdcli/scmulti.html + +config PACKAGE_UPMPDCLI_SC_WEB_INTERFACE + bool "SongCast web server and associated files (depends on python)" + default no + depends on PACKAGE_upmpdcli + select PACKAGE_python + select PACKAGE_UPMPDCLI_SCCTL + help + Installs the SongCast web interface and web server. See the following + link for more info: http://www.lesbonscomptes.com/upmpdcli/scmulti.html diff --git a/sound/upmpdcli/Makefile b/sound/upmpdcli/Makefile index 385a96bee..42b98fa73 100644 --- a/sound/upmpdcli/Makefile +++ b/sound/upmpdcli/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=upmpdcli -PKG_VERSION:=0.9.0 -PKG_RELEASE:=2 +PKG_VERSION:=0.11.0 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.lesbonscomptes.com/upmpdcli/downloads -PKG_MD5SUM:=0e7b86037f19ea3a08067409af6f6902 +PKG_MD5SUM:=40eb2a1988ca367a690fb2506e0f73c1 PKG_MAINTAINER:=Petko Bordjukov PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING @@ -29,12 +29,17 @@ define Package/upmpdcli DEPENDS+= +libupnpp +libmpdclient TITLE:=A UPnP front-end to MPD, the Music Player Daemon USERID:=upmpdcli=89:upmpdcli=89 + MENU:=1 endef define Package/upmpdcli/description upmpdcli implements an UPnP Media Renderer, using MPD to perform the real work. endef +define Package/upmpdcli/config + source "$(SOURCE)/Config.in" +endef + define Package/upmpdcli/install $(INSTALL_DIR) $(1)/etc $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/upmpdcli.conf $(1)/etc/ @@ -42,8 +47,14 @@ define Package/upmpdcli/install $(INSTALL_CONF) ./files/upmpdcli.config $(1)/etc/config/upmpdcli $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/upmpdcli $(1)/usr/bin/ +ifeq ($(CONFIG_PACKAGE_UPMPDCLI_SCCTL),y) + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/scctl $(1)/usr/bin/ +endif $(INSTALL_DIR) $(1)/usr/share/upmpdcli - $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/upmpdcli/* $(1)/usr/share/upmpdcli/ +ifneq ($(CONFIG_PACKAGE_UPMPDCLI_SC_WEB_INTERFACE),y) + $(RM) -rf $(PKG_INSTALL_DIR)/usr/share/upmpdcli/web +endif + $(CP) -r $(PKG_INSTALL_DIR)/usr/share/upmpdcli $(1)/usr/share/ $(INSTALL_DATA) ./files/upmpdcli.png $(1)/usr/share/upmpdcli/ $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/upmpdcli.init $(1)/etc/init.d/upmpdcli diff --git a/utils/acpid/Makefile b/utils/acpid/Makefile new file mode 100644 index 000000000..657ff70be --- /dev/null +++ b/utils/acpid/Makefile @@ -0,0 +1,68 @@ +# +# Copyright (C) 2012-2015 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:=acpid +PKG_VERSION:=2.0.23 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=@SF/acpid2 +PKG_MD5SUM:=d7bcdcdefcd53b03730e50ba842554ea +PKG_MAINTAINER:=Thomas Heil +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=COPYING + +include $(INCLUDE_DIR)/package.mk + +define Package/acpid + SECTION:=utils + CATEGORY:=Utilities + TITLE:=The ACPI Daemon (acpid) With Netlink Support + URL:=http://tedfelix.com/linux/acpid-netlink.html + DEPENDS:=@(TARGET_x86||TARGET_x86_64) +kmod-input-evdev +endef + +define Package/acpid/description + The ACPI Daemon (acpid) With Netlink Support +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + CC="$(TARGET_CC)" \ + LD="$(TARGET_CC)" \ + LDFLAGS="$(TARGET_LDFLAGS)" \ + all +endef + +define Package/acpid/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/acpid $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_BUILD_DIR)/acpi_listen $(1)/usr/sbin/ + $(INSTALL_DIR) $(1)/etc/acpi/events + $(INSTALL_CONF) ./files/default $(1)/etc/acpi/events/default + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_CONF) ./files/acpid.init $(1)/etc/init.d/acpid + chmod 0750 $(1)/etc/init.d/acpid + $(INSTALL_DIR) $(1)/etc/hotplug.d/input/ + $(INSTALL_CONF) ./files/acpid.hotplug $(1)/etc/hotplug.d/input/ +endef + +define Package/acpid/postinst +#!/bin/sh +[ -n "$${IPKG_INSTROOT}" ] || { + echo "waiting for input devices to come up" + /etc/init.d/acpid enable + sleep 5 + /etc/init.d/acpid start + echo "please try the power button" + exit 0 +} +endef + +$(eval $(call BuildPackage,acpid)) diff --git a/utils/acpid/files/acpid.hotplug b/utils/acpid/files/acpid.hotplug new file mode 100644 index 000000000..6e08d01a2 --- /dev/null +++ b/utils/acpid/files/acpid.hotplug @@ -0,0 +1,7 @@ +#!/bin/sh + +. /lib/functions.sh + +if [ "$ACTION" = add ] && [ "$DEVICENAME" = event0 ]; then + ( /etc/init.d/acpid/stop; sleep 3; /usr/sbin/acpid )& +fi diff --git a/utils/acpid/files/acpid.init b/utils/acpid/files/acpid.init new file mode 100644 index 000000000..3365aa022 --- /dev/null +++ b/utils/acpid/files/acpid.init @@ -0,0 +1,25 @@ +#!/bin/ash /etc/rc.common +# Copyright (C) 2009-2010 OpenWrt.org + +START=99 +STOP=80 + +ACPID_BIN="/usr/sbin/acpid" +ACPID_PID="/var/run/acpid.pid" + +start() { + [ -x "$ACPID_BIN" ] || return 1 + start-stop-daemon -S -x $ACPID_BIN -p $ACPID_PID +} + +boot() { + # Do nothing on boot + [ -x "$ACPID_BIN" ] || return 1 + start-stop-daemon -S -x $ACPID_BIN -p $ACPID_PID + exit 0 +} + +stop() { + service_kill ${ACPID_BIN##*/} $ACPID_PID + rm -f $ACPID_PID +} diff --git a/utils/acpid/files/default b/utils/acpid/files/default new file mode 100644 index 000000000..cf8d9a3f2 --- /dev/null +++ b/utils/acpid/files/default @@ -0,0 +1,5 @@ +# This is a sample ACPID configuration + +event=button/power.* +action=/sbin/poweroff + diff --git a/utils/acpid/patches/001-musl-compat.patch b/utils/acpid/patches/001-musl-compat.patch new file mode 100644 index 000000000..086361fea --- /dev/null +++ b/utils/acpid/patches/001-musl-compat.patch @@ -0,0 +1,129 @@ +Index: acpid-2.0.23/tempfailure.h +=================================================================== +--- /dev/null ++++ acpid-2.0.23/tempfailure.h +@@ -0,0 +1,8 @@ ++#ifndef TEMP_FAILURE_RETRY ++#define TEMP_FAILURE_RETRY(expression) \ ++ (__extension__ \ ++ ({ long int __result; \ ++ do __result = (long int) (expression); \ ++ while (__result == -1L && errno == EINTR); \ ++ __result; })) ++#endif +Index: acpid-2.0.23/acpi_listen.c +=================================================================== +--- acpid-2.0.23.orig/acpi_listen.c ++++ acpid-2.0.23/acpi_listen.c +@@ -39,6 +39,8 @@ + #include "acpid.h" + #include "ud_socket.h" + ++#include "tempfailure.h" ++ + static int handle_cmdline(int *argc, char ***argv); + static char *read_line(int fd); + +Index: acpid-2.0.23/acpid.c +=================================================================== +--- acpid-2.0.23.orig/acpid.c ++++ acpid-2.0.23/acpid.c +@@ -41,6 +41,7 @@ + #include "input_layer.h" + #include "inotify_handler.h" + #include "netlink.h" ++#include "tempfailure.h" + + static int handle_cmdline(int *argc, char ***argv); + static void close_fds(void); +Index: acpid-2.0.23/event.c +=================================================================== +--- acpid-2.0.23.orig/event.c ++++ acpid-2.0.23/event.c +@@ -40,6 +40,9 @@ + #include "sock.h" + #include "ud_socket.h" + #include "event.h" ++ ++#include "tempfailure.h" ++ + /* + * What is a rule? It's polymorphic, pretty much. + */ +Index: acpid-2.0.23/input_layer.c +=================================================================== +--- acpid-2.0.23.orig/input_layer.c ++++ acpid-2.0.23/input_layer.c +@@ -47,6 +47,8 @@ + + #define DIM(a) (sizeof(a) / sizeof(a[0])) + ++#include "tempfailure.h" ++ + struct evtab_entry { + struct input_event event; + const char *str; +Index: acpid-2.0.23/kacpimon/libnetlink.c +=================================================================== +--- acpid-2.0.23.orig/kacpimon/libnetlink.c ++++ acpid-2.0.23/kacpimon/libnetlink.c +@@ -26,6 +26,8 @@ + + #include "libnetlink.h" + ++#include "../tempfailure.h" ++ + void rtnl_close(struct rtnl_handle *rth) + { + if (rth->fd >= 0) { +Index: acpid-2.0.23/netlink.c +=================================================================== +--- acpid-2.0.23.orig/netlink.c ++++ acpid-2.0.23/netlink.c +@@ -46,6 +46,7 @@ + #include "connection_list.h" + + #include "netlink.h" ++#include "tempfailure.h" + + static void + format_netlink(struct nlmsghdr *msg) +Index: acpid-2.0.23/proc.c +=================================================================== +--- acpid-2.0.23.orig/proc.c ++++ acpid-2.0.23/proc.c +@@ -34,6 +34,8 @@ + + #include "proc.h" + ++#include "tempfailure.h" ++ + const char *eventfile = ACPID_EVENTFILE; + + static char *read_line(int fd); +Index: acpid-2.0.23/ud_socket.c +=================================================================== +--- acpid-2.0.23.orig/ud_socket.c ++++ acpid-2.0.23/ud_socket.c +@@ -22,6 +22,8 @@ + #include "log.h" + #include "ud_socket.h" + ++#include "tempfailure.h" ++ + int + ud_create_socket(const char *name, mode_t socketmode) + { +Index: acpid-2.0.23/libnetlink.c +=================================================================== +--- acpid-2.0.23.orig/libnetlink.c ++++ acpid-2.0.23/libnetlink.c +@@ -26,6 +26,8 @@ + + #include "libnetlink.h" + ++#include "tempfailure.h" ++ + void rtnl_close(struct rtnl_handle *rth) + { + if (rth->fd >= 0) { diff --git a/utils/acpid/patches/002-dont-use-isfdtype.patch b/utils/acpid/patches/002-dont-use-isfdtype.patch new file mode 100644 index 000000000..cd4e062c8 --- /dev/null +++ b/utils/acpid/patches/002-dont-use-isfdtype.patch @@ -0,0 +1,21 @@ +Partially roll back upstream commit 4711119089e1ad08dad206f4fded68f1972fdeed +since released versions of uClibc don't support isfdtype(). + +Signed-off-by: Gustavo Zaarias + +Index: acpid-2.0.23/sock.c +=================================================================== +--- acpid-2.0.23.orig/sock.c ++++ acpid-2.0.23/sock.c +@@ -53,7 +53,10 @@ int non_root_clients; + int + is_socket(int fd) + { +- return (isfdtype(fd, S_IFSOCK) == 1); ++ int v; ++ socklen_t l = sizeof(int); ++ ++ return (getsockopt(fd, SOL_SOCKET, SO_TYPE, (char *)&v, &l) == 0); + } + + /* accept a new client connection */ diff --git a/utils/attr/Makefile b/utils/attr/Makefile index b32c5e924..80da9ccd4 100644 --- a/utils/attr/Makefile +++ b/utils/attr/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=attr -PKG_REV:=c4a7fdbcc109d6e8b465a427c714926fcb85c750 -PKG_VERSION:=20141020 +PKG_REV:=c252ef434219891f616d891b46aad6b06efdd185 +PKG_VERSION:=20150220 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz diff --git a/utils/avrdude/Makefile b/utils/avrdude/Makefile new file mode 100644 index 000000000..c3750c061 --- /dev/null +++ b/utils/avrdude/Makefile @@ -0,0 +1,57 @@ +# +# Copyright (C) 2008-2015 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:=avrdude +PKG_VERSION:=6.1 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://download.savannah.gnu.org/releases/avrdude +PKG_MD5SUM:=9db8c25b935d34234b9b1ba16ad55fd5 + +PKG_MAINTAINER:=Ted Hess +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=COPYING + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/avrdude + SECTION:=utils + CATEGORY:=Utilities + TITLE:=AVR Downloader/UploaDEr + URL:=http://www.nongnu.org/avrdude/ + DEPENDS:=+libncurses +libreadline +libusb-compat +libftdi1 +libelf1 +endef + +define Package/avrdude/description + AVRDUDE is a full featured program for programming Atmel's AVR CPU's. +endef + +CONFIGURE_ARGS+= \ + --disable-doc \ + --disable-parport \ + +TARGET_CFLAGS+= \ + -D_GNU_SOURCE \ + +define Package/avrdude/conffiles +/etc/avrdude.conf +endef + +define Package/avrdude/install + $(INSTALL_DIR) $(1)/etc + $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/avrdude.conf $(1)/etc/ + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/avrdude $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,avrdude)) diff --git a/utils/avrdude/patches/010-configure-fixups.patch b/utils/avrdude/patches/010-configure-fixups.patch new file mode 100644 index 000000000..b945ecbeb --- /dev/null +++ b/utils/avrdude/patches/010-configure-fixups.patch @@ -0,0 +1,18 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -35,6 +35,7 @@ AC_CONFIG_HEADERS(ac_cfg.h) + + # Checks for programs. + AC_PROG_CC ++AC_PROG_CPP + AC_PROG_INSTALL + AC_PROG_SED + AC_PROG_YACC +@@ -183,6 +184,7 @@ fi + AC_SUBST(LIBPTHREAD, $LIBPTHREAD) + # Checks for header files. + AC_CHECK_HEADERS([limits.h stdlib.h string.h]) ++AC_CHECK_HEADERS([inttypes.h stdint.h]) + AC_CHECK_HEADERS([fcntl.h sys/ioctl.h sys/time.h termios.h unistd.h]) + AC_CHECK_HEADERS([ddk/hidsdi.h],,,[#include + #include ]) diff --git a/utils/avrdude/patches/100-musl-compat.patch b/utils/avrdude/patches/100-musl-compat.patch new file mode 100644 index 000000000..6baedc09e --- /dev/null +++ b/utils/avrdude/patches/100-musl-compat.patch @@ -0,0 +1,60 @@ +--- a/dfu.h ++++ b/dfu.h +@@ -25,6 +25,7 @@ + + #ifdef HAVE_LIBUSB + #if defined(HAVE_USB_H) ++# include + # include + #elif defined(HAVE_LUSB0_USB_H) + # include +--- a/pickit2.c ++++ b/pickit2.c +@@ -50,6 +50,7 @@ + #include + #include + #include ++#include + + #include "avrdude.h" + #include "avr.h" +--- a/ser_avrdoper.c ++++ b/ser_avrdoper.c +@@ -248,6 +248,7 @@ static int usbGetReport(union filedescri + /* ------------------------------------------------------------------------ */ + + #if defined(HAVE_USB_H) ++# include + # include + #elif defined(HAVE_LUSB0_USB_H) + # include +--- a/usbtiny.c ++++ b/usbtiny.c +@@ -41,6 +41,7 @@ + + #if defined(HAVE_LIBUSB) // we use LIBUSB to talk to the board + #if defined(HAVE_USB_H) ++# include + # include + #elif defined(HAVE_LUSB0_USB_H) + # include +--- a/usbasp.c ++++ b/usbasp.c +@@ -54,6 +54,7 @@ + # endif + #else + # if defined(HAVE_USB_H) ++# include + # include + # elif defined(HAVE_LUSB0_USB_H) + # include +--- a/usb_libusb.c ++++ b/usb_libusb.c +@@ -36,6 +36,7 @@ + #include + + #if defined(HAVE_USB_H) ++# include + # include + #elif defined(HAVE_LUSB0_USB_H) + # include diff --git a/utils/bash/Makefile b/utils/bash/Makefile index df97e097f..9586da5c5 100644 --- a/utils/bash/Makefile +++ b/utils/bash/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk BASE_VERSION:=4.3 PKG_NAME:=bash -PKG_VERSION:=$(BASE_VERSION).33 +PKG_VERSION:=$(BASE_VERSION).39 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(BASE_VERSION).tar.gz diff --git a/utils/bash/patches/122-upstream-bash43-022.patch b/utils/bash/patches/122-upstream-bash43-022.patch index 4762be2a9..1ee8f13a1 100644 --- a/utils/bash/patches/122-upstream-bash43-022.patch +++ b/utils/bash/patches/122-upstream-bash43-022.patch @@ -17,7 +17,7 @@ Patch (apply with `patch -p0'): --- a/execute_cmd.c +++ b/execute_cmd.c -@@ -2409,7 +2409,16 @@ execute_pipeline (command, asynchronous, +@@ -2413,7 +2413,16 @@ execute_pipeline (command, asynchronous, #endif lstdin = wait_for (lastpid); #if defined (JOB_CONTROL) diff --git a/utils/bash/patches/134-upstream-bash43-034.patch b/utils/bash/patches/134-upstream-bash43-034.patch new file mode 100644 index 000000000..d3c4f8f1d --- /dev/null +++ b/utils/bash/patches/134-upstream-bash43-034.patch @@ -0,0 +1,74 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-034 + +Bug-Reported-by: Dreamcat4 +Bug-Reference-ID: +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2015-05/msg00001.html + +Bug-Description: + +If neither the -f nor -v options is supplied to unset, and a name argument is +found to be a function and unset, subsequent name arguments are not treated as +variables before attempting to unset a function by that name. + +Patch (apply with `patch -p0'): + +--- a/builtins/set.def ++++ b/builtins/set.def +@@ -751,9 +751,11 @@ unset_builtin (list) + WORD_LIST *list; + { + int unset_function, unset_variable, unset_array, opt, nameref, any_failed; ++ int global_unset_func, global_unset_var; + char *name; + + unset_function = unset_variable = unset_array = nameref = any_failed = 0; ++ global_unset_func = global_unset_var = 0; + + reset_internal_getopt (); + while ((opt = internal_getopt (list, "fnv")) != -1) +@@ -761,10 +763,10 @@ unset_builtin (list) + switch (opt) + { + case 'f': +- unset_function = 1; ++ global_unset_func = 1; + break; + case 'v': +- unset_variable = 1; ++ global_unset_var = 1; + break; + case 'n': + nameref = 1; +@@ -777,7 +779,7 @@ unset_builtin (list) + + list = loptend; + +- if (unset_function && unset_variable) ++ if (global_unset_func && global_unset_var) + { + builtin_error (_("cannot simultaneously unset a function and a variable")); + return (EXECUTION_FAILURE); +@@ -795,6 +797,9 @@ unset_builtin (list) + + name = list->word->word; + ++ unset_function = global_unset_func; ++ unset_variable = global_unset_var; ++ + #if defined (ARRAY_VARS) + unset_array = 0; + if (!unset_function && valid_array_reference (name)) +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 33 ++#define PATCHLEVEL 34 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bash/patches/135-upstream-bash43-035.patch b/utils/bash/patches/135-upstream-bash43-035.patch new file mode 100644 index 000000000..4e614ce11 --- /dev/null +++ b/utils/bash/patches/135-upstream-bash43-035.patch @@ -0,0 +1,48 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-035 + +Bug-Reported-by: +Bug-Reference-ID: +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2014-08/msg00045.html + +Bug-Description: + +A locale with a long name can trigger a buffer overflow and core dump. This +applies on systems that do not have locale_charset in libc, are not using +GNU libiconv, and are not using the libintl that ships with bash in lib/intl. + +Patch (apply with `patch -p0'): + +--- a/lib/sh/unicode.c ++++ b/lib/sh/unicode.c +@@ -78,13 +78,15 @@ stub_charset () + s = strrchr (locale, '.'); + if (s) + { +- strcpy (charsetbuf, s+1); ++ strncpy (charsetbuf, s+1, sizeof (charsetbuf) - 1); ++ charsetbuf[sizeof (charsetbuf) - 1] = '\0'; + t = strchr (charsetbuf, '@'); + if (t) + *t = 0; + return charsetbuf; + } +- strcpy (charsetbuf, locale); ++ strncpy (charsetbuf, locale, sizeof (charsetbuf) - 1); ++ charsetbuf[sizeof (charsetbuf) - 1] = '\0'; + return charsetbuf; + } + #endif +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 34 ++#define PATCHLEVEL 35 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bash/patches/136-upstream-bash43-036.patch b/utils/bash/patches/136-upstream-bash43-036.patch new file mode 100644 index 000000000..198b662c3 --- /dev/null +++ b/utils/bash/patches/136-upstream-bash43-036.patch @@ -0,0 +1,48 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-036 + +Bug-Reported-by: emanuelczirai@cryptolab.net +Bug-Reference-ID: +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2015-02/msg00071.html + +Bug-Description: + +When evaluating and setting integer variables, and the assignment fails to +create a variable (for example, when performing an operation on an array +variable with an invalid subscript), bash attempts to dereference a null +pointer, causing a segmentation violation. + +Patch (apply with `patch -p0'): + +--- a/variables.c ++++ b/variables.c +@@ -2833,10 +2833,12 @@ bind_int_variable (lhs, rhs) + #endif + v = bind_variable (lhs, rhs, 0); + +- if (v && isint) +- VSETATTR (v, att_integer); +- +- VUNSETATTR (v, att_invisible); ++ if (v) ++ { ++ if (isint) ++ VSETATTR (v, att_integer); ++ VUNSETATTR (v, att_invisible); ++ } + + return (v); + } +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 35 ++#define PATCHLEVEL 36 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bash/patches/137-upstream-bash43-037.patch b/utils/bash/patches/137-upstream-bash43-037.patch new file mode 100644 index 000000000..946e9fe14 --- /dev/null +++ b/utils/bash/patches/137-upstream-bash43-037.patch @@ -0,0 +1,38 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-037 + +Bug-Reported-by: Greg Wooledge +Bug-Reference-ID: <20150204144240.GN13956@eeg.ccf.org> +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2015-02/msg00007.html + +Bug-Description: + +If an associative array uses `@' or `*' as a subscript, `declare -p' produces +output that cannot be reused as input. + +Patch (apply with `patch -p0'): + +--- a/assoc.c ++++ b/assoc.c +@@ -436,6 +436,8 @@ assoc_to_assign (hash, quoted) + #if 1 + if (sh_contains_shell_metas (tlist->key)) + istr = sh_double_quote (tlist->key); ++ else if (ALL_ELEMENT_SUB (tlist->key[0]) && tlist->key[1] == '\0') ++ istr = sh_double_quote (tlist->key); + else + istr = tlist->key; + #else +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 36 ++#define PATCHLEVEL 37 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bash/patches/138-upstream-bash43-038.patch b/utils/bash/patches/138-upstream-bash43-038.patch new file mode 100644 index 000000000..985784759 --- /dev/null +++ b/utils/bash/patches/138-upstream-bash43-038.patch @@ -0,0 +1,67 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-038 + +Bug-Reported-by: worley@alum.mit.edu (Dale R. Worley) +Bug-Reference-ID: <201406100051.s5A0pCeB014978@hobgoblin.ariadne.com> +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2014-06/msg00028.html + +Bug-Description: + +There are a number of instances where `time' is not recognized as a reserved +word when the shell grammar says it should be. + +Patch (apply with `patch -p0'): + +--- a/parse.y ++++ b/parse.y +@@ -2818,11 +2818,16 @@ time_command_acceptable () + case AND_AND: + case OR_OR: + case '&': ++ case WHILE: + case DO: ++ case UNTIL: ++ case IF: + case THEN: ++ case ELIF: + case ELSE: + case '{': /* } */ +- case '(': /* ) */ ++ case '(': /* )( */ ++ case ')': /* only valid in case statement */ + case BANG: /* ! time pipeline */ + case TIME: /* time time pipeline */ + case TIMEOPT: /* time -p time pipeline */ +--- a/y.tab.c ++++ b/y.tab.c +@@ -5130,11 +5130,16 @@ time_command_acceptable () + case AND_AND: + case OR_OR: + case '&': ++ case WHILE: + case DO: ++ case UNTIL: ++ case IF: + case THEN: ++ case ELIF: + case ELSE: + case '{': /* } */ +- case '(': /* ) */ ++ case '(': /* )( */ ++ case ')': /* only valid in case statement */ + case BANG: /* ! time pipeline */ + case TIME: /* time time pipeline */ + case TIMEOPT: /* time -p time pipeline */ +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 37 ++#define PATCHLEVEL 38 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bash/patches/139-upstream-bash43-039.patch b/utils/bash/patches/139-upstream-bash43-039.patch new file mode 100644 index 000000000..f8ad363f3 --- /dev/null +++ b/utils/bash/patches/139-upstream-bash43-039.patch @@ -0,0 +1,52 @@ + BASH PATCH REPORT + ================= + +Bash-Release: 4.3 +Patch-ID: bash43-039 + +Bug-Reported-by: SN +Bug-Reference-ID: <54E2554C.205@gazeta.pl> +Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2015-02/msg00060.html + +Bug-Description: + +Using the output of `declare -p' when run in a function can result in variables +that are invisible to `declare -p'. This problem occurs when an assignment +builtin such as `declare' receives a quoted compound array assignment as one of +its arguments. + +Patch (apply with `patch -p0'): + +--- a/arrayfunc.c ++++ b/arrayfunc.c +@@ -404,6 +404,9 @@ assign_array_var_from_word_list (var, li + (*var->assign_func) (var, l->word->word, i, 0); + else + array_insert (a, i, l->word->word); ++ ++ VUNSETATTR (var, att_invisible); /* no longer invisible */ ++ + return var; + } + +@@ -634,6 +637,10 @@ assign_array_var_from_string (var, value + + if (nlist) + dispose_words (nlist); ++ ++ if (var) ++ VUNSETATTR (var, att_invisible); /* no longer invisible */ ++ + return (var); + } + +--- a/patchlevel.h ++++ b/patchlevel.h +@@ -25,6 +25,6 @@ + regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh + looks for to find the patch level (for the sccs version string). */ + +-#define PATCHLEVEL 38 ++#define PATCHLEVEL 39 + + #endif /* _PATCHLEVEL_H_ */ diff --git a/utils/bc/Makefile b/utils/bc/Makefile new file mode 100644 index 000000000..900fd3e2b --- /dev/null +++ b/utils/bc/Makefile @@ -0,0 +1,65 @@ +# +# Copyright (C) 2006-2015 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:=bc +PKG_VERSION:=1.06.95 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).orig.tar.gz +PKG_SOURCE_URL:=ftp://ftp.debian.org/debian/pool/main/b/bc +PKG_MD5SUM:=24d0831812d8262b6cac8316b0bac483 + +PKG_MAINTAINER:=Bruno Randolf +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:=COPYING + +include $(INCLUDE_DIR)/package.mk + +define Package/bc/Default + SECTION:=utils + CATEGORY:=Utilities + URL:=http://packages.debian.org/bc +endef + +define Package/bc + $(call Package/bc/Default) + TITLE:=Arbitrary precision calculator language + DEPENDS:=+libreadline +libncurses +endef + +define Package/bc/description + bc is a language that supports arbitrary precision numbers with + interactive execution of statements. +endef + +define Package/dc + $(call Package/bc/Default) + TITLE:=Arbitrary precision reverse-polish calculator + DEPENDS:=bc +endef + +define Package/dc/description + dc is a reverse-polish desk calculator which supports unlimited + precision arithmetic. +endef + +CONFIGURE_ARGS += --with-readline + +define Package/bc/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/bc/bc $(1)/usr/bin/ +endef + +define Package/dc/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/dc/dc $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,bc)) +$(eval $(call BuildPackage,dc)) diff --git a/utils/bc/patches/001-disable-doc.patch b/utils/bc/patches/001-disable-doc.patch new file mode 100644 index 000000000..a6ecd6e9f --- /dev/null +++ b/utils/bc/patches/001-disable-doc.patch @@ -0,0 +1,21 @@ +--- bc-1.06.95/Makefile.in 2010-07-03 10:48:13.422725147 +0000 ++++ bc-1.06.95/Makefile.in 2010-07-03 10:50:09.714725197 +0000 +@@ -149,7 +149,7 @@ + sharedstatedir = @sharedstatedir@ + sysconfdir = @sysconfdir@ + target_alias = @target_alias@ +-SUBDIRS = lib bc dc doc ++SUBDIRS = lib bc dc + MAINTAINERCLEANFILES = aclocal.m4 config.h.in configure Makefile.in \ + stamp-h $(distdir).tar.gz h/number.h depcomp missing + +--- bc-1.06.95/Makefile.am 2010-07-03 10:48:32.522725037 +0000 ++++ bc-1.06.95/Makefile.am 2010-07-03 10:48:38.114725024 +0000 +@@ -1,6 +1,6 @@ + ## Process this file with automake to produce Makefile.in + +-SUBDIRS = lib bc dc doc ++SUBDIRS = lib bc dc + + MAINTAINERCLEANFILES = aclocal.m4 config.h.in configure Makefile.in \ + stamp-h $(distdir).tar.gz h/number.h depcomp missing diff --git a/utils/bluez/Makefile b/utils/bluez/Makefile index 550df30c1..ebc164639 100644 --- a/utils/bluez/Makefile +++ b/utils/bluez/Makefile @@ -8,17 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=bluez -PKG_VERSION:=5.28 -PKG_RELEASE:=1 +PKG_VERSION:=5.30 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://www.kernel.org/pub/linux/bluetooth/ -PKG_MD5SUM:=bc20a8285530758c68f6a60e4ca62a15 +PKG_MD5SUM:=24ba1d1e8e7ef5b8f4033a3059d7600e PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING PKG_MAINTAINER:=Nicolas Thill +PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk @@ -29,12 +30,24 @@ define Package/bluez/Default URL:=http://www.bluez.org/ endef +define Package/bluez-examples +$(call Package/bluez/Default) + SECTION:=utils + CATEGORY:=Utilities + TITLE+= python example apps + DEPENDS:=+python +endef + +define Package/bluez-examples/description + contains many examples apps for bluetooth, requiring python +endef + define Package/bluez-libs $(call Package/bluez/Default) SECTION:=libs CATEGORY:=Libraries TITLE+= library - DEPENDS:=+libpthread + DEPENDS:=+libpthread +kmod-bluetooth endef define Package/bluez-utils @@ -42,12 +55,22 @@ $(call Package/bluez/Default) SECTION:=utils CATEGORY:=Utilities TITLE+= utilities - DEPENDS:=+bluez-libs +libpthread +dbus +glib2 +libical +libncurses +libreadline $(INTL_DEPENDS) $(ICONV_DEPENDS) + DEPENDS:=+bluez-libs +libpthread +librt +glib2 +libncurses +libreadline $(INTL_DEPENDS) $(ICONV_DEPENDS) endef -define Package/bluez-utils/conffiles -/etc/bluetooth/hcid.conf -/etc/bluetooth/rfcomm.conf +define Package/bluez-daemon +$(call Package/bluez/Default) + SECTION:=utils + CATEGORY:=Utilities + TITLE+= daemon + DEPENDS:=+bluez-libs +bluez-utils +dbus +libical $(INTL_DEPENDS) $(ICONV_DEPENDS) +endef + +define Package/bluez-daemon/conffiles +/etc/bluetooth/main.conf +/etc/bluetooth/network.conf +/etc/bluetooth/input.conf +/etc/bluetooth/proximity.conf /etc/config/bluetooth endef @@ -82,6 +105,11 @@ define Build/InstallDev $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/bluez.pc $(1)/usr/lib/pkgconfig/ endef +define Package/bluez-examples/install + $(INSTALL_DIR) $(1)/usr/bin/bluez + $(INSTALL_DATA) $(PKG_BUILD_DIR)/test/* $(1)/usr/bin/bluez/ +endef + define Package/bluez-libs/install $(INSTALL_DIR) $(1)/usr/lib $(CP) $(PKG_INSTALL_DIR)/usr/lib/libbluetooth.so.* $(1)/usr/lib/ @@ -89,14 +117,42 @@ endef define Package/bluez-utils/install $(INSTALL_DIR) $(1)/usr/bin - $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/bccmd $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/bluemoon $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/btmon $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/ciptool $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/hciattach $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/hciconfig $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/hcidump $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/hcitool $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/hex2hcd $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/l2ping $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/l2test $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/rctest $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/rfcomm $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/sdptool $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_BUILD_DIR)/attrib/gatttool $(1)/usr/bin/ +endef + +define Package/bluez-daemon/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/lib/bluetooth/bluetoothd $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/bin/bluetoothctl $(1)/usr/bin/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/bluetooth/obexd $(1)/usr/bin/ $(INSTALL_DIR) $(1)/etc/config $(INSTALL_DATA) ./files/bluetooth.config $(1)/etc/config/bluetooth $(INSTALL_DIR) $(1)/etc/dbus-1/system.d/ $(INSTALL_DATA) ./files/bluetooth.dbus $(1)/etc/dbus-1/system.d/bluetooth.conf + $(INSTALL_DIR) $(1)/etc/bluetooth + $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/main.conf $(1)/etc/bluetooth/main.conf + $(INSTALL_DATA) $(PKG_BUILD_DIR)/profiles/network/network.conf $(1)/etc/bluetooth/network.conf + $(INSTALL_DATA) $(PKG_BUILD_DIR)/profiles/input/input.conf $(1)/etc/bluetooth/input.conf + $(INSTALL_DATA) $(PKG_BUILD_DIR)/profiles/proximity/proximity.conf $(1)/etc/bluetooth/proximity.conf $(INSTALL_DIR) $(1)/etc/init.d - $(INSTALL_BIN) ./files/bluez-utils.init $(1)/etc/init.d/bluez-utils + $(INSTALL_BIN) ./files/bluetoothd.init $(1)/etc/init.d/bluetoothd endef +$(eval $(call BuildPackage,bluez-examples)) $(eval $(call BuildPackage,bluez-libs)) $(eval $(call BuildPackage,bluez-utils)) +$(eval $(call BuildPackage,bluez-daemon)) diff --git a/utils/bluez/files/bluetooth.config b/utils/bluez/files/bluetooth.config index 42f390c67..6f23617a4 100644 --- a/utils/bluez/files/bluetooth.config +++ b/utils/bluez/files/bluetooth.config @@ -1,5 +1,5 @@ -config hcid -# option config /etc/bluetooth/hcid.conf +config bluetoothd +# option config /etc/bluetooth/main.conf option enabled 1 config hciattach @@ -13,20 +13,3 @@ config hciattach config rfcomm # option config /etc/bluetooth/rfcomm.conf option enabled 0 - -config dund - option listen true - option persist true - option msdun true - option interface dund - option unit 1 - option pppdopts "ktune proxyarp 192.168.1.1:192.168.1.2 ms-dns 192.168.1.1" - option enabled 0 - -config pand - option listen true - option autozap true - option role "NAP" - option master true - option persist true - option enabled 0 diff --git a/utils/bluez/files/bluetoothd.init b/utils/bluez/files/bluetoothd.init new file mode 100644 index 000000000..75f4d9664 --- /dev/null +++ b/utils/bluez/files/bluetoothd.init @@ -0,0 +1,13 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2007 OpenWrt.org + +#start after dbus (60) +START=62 +USE_PROCD=1 +PROG=/usr/bin/bluetoothd + +start_service() { + procd_open_instance + procd_set_param command "$PROG" -n + procd_close_instance +} diff --git a/utils/bluez/files/bluez-utils.init b/utils/bluez/files/bluez-utils.init deleted file mode 100644 index e9320aed2..000000000 --- a/utils/bluez/files/bluez-utils.init +++ /dev/null @@ -1,131 +0,0 @@ -#!/bin/sh /etc/rc.common -# Copyright (C) 2007 OpenWrt.org - -#start after dbus (60) -START=62 - -append_bool() { - local section="$1" - local option="$2" - local value="$3" - local _val - config_get_bool _val "$section" "$option" '0' - [ $_val -gt 0 ] && append args "$3" -} - -append_string() { - local section="$1" - local option="$2" - local value="$3" - local default="$4" - local _val - config_get _val "$section" "$option" "$default" - [ -n "$_val" ] && append args "$3 $_val" -} - -hcid_config() { - local cfg="$1" - config_get_bool enabled "$cfg" "enabled" '1' - [ $enabled -gt 0 ] || return 1 - args="" - append_bool "$cfg" nodaemon "-n" - append_string "$cfg" config "-f" - service_start /usr/sbin/hcid $args -} - -hciattach_config() { - local cfg="$1" - config_get_bool enabled "$cfg" "enabled" '1' - [ $enabled -gt 0 ] || return 1 - args="" - append_string "$cfg" initspeed "-s" "115200" - append_string "$cfg" tty " " "ttyS1" - append_string "$cfg" type " " "csr" - append_string "$cfg" speed " " "115200" - append_string "$cfg" flow " " "noflow" - service_start /usr/sbin/hciattach $args -} - -rfcomm_config() { - local cfg="$1" - config_get_bool enabled "$cfg" "enabled" '1' - [ $enabled -gt 0 ] || return 1 - args="" - append_string "$cfg" config "-f" - /usr/bin/rfcomm $args bind all -} - -dund_config() { - local cfg="$1" - config_get_bool enabled "$cfg" "enabled" '1' - [ $enabled -gt 0 ] || return 1 - args="" - append_bool "$cfg" listen "--listen" - append_string "$cfg" connect "--connect" - append_string "$cfg" mrouter "--mrouter" - append_bool "$cfg" search "--search" - append_string "$cfg" channel "--channel" - append_string "$cfg" device "--device" - append_bool "$cfg" nosdp "--nosdp" - append_bool "$cfg" auth "--auth" - append_bool "$cfg" encrypt "--encrypt" - append_bool "$cfg" secure "--secure" - append_bool "$cfg" master "--master" - append_bool "$cfg" nodetach "--nodetach" - append_bool "$cfg" persist "--persist" - append_string "$cfg" pppd "--pppd" - append_bool "$cfg" msdun "--msdun" - append_bool "$cfg" activesync "--activesync" - append_bool "$cfg" cache "--cache" - - append_string "$cfg" pppdopts "" - config_get ifn "$cfg" interface - if [ -n "$ifn" ]; then - config_get unit "$cfg" unit - [ -z "$unit" ] || append args "unit $unit ipparam $ifn linkname $ifn" - fi - - service_start /usr/bin/dund $args -} - -pand_config() { - local cfg="$1" - config_get_bool enabled "$cfg" "enabled" '1' - [ $enabled -gt 0 ] || return 1 - args="" - append_bool "$cfg" listen "--listen" - append_string "$cfg" connect "--connect" - append_bool "$cfg" autozap "--autozap" - append_bool "$cfg" search "--search" - append_string "$cfg" role "--role" - append_string "$cfg" service "--service" - append_string "$cfg" ethernet "--ethernet" - append_string "$cfg" device "--device" - append_bool "$cfg" nosdp "-D" - append_bool "$cfg" auth "-A" - append_bool "$cfg" encrypt "-E" - append_bool "$cfg" secure "-S" - append_bool "$cfg" master "-M" - append_bool "$cfg" nodetach "-n" - append_bool "$cfg" persist "--persist" - append_bool "$cfg" cache "--cache" - append_string "$cfg" pidfile "--pidfile" - service_start /usr/bin/pand $args -} - -start() { - config_load bluetooth - config_foreach hcid_config hcid - config_foreach hciattach_config hciattach - config_foreach rfcomm_config rfcomm - config_foreach dund_config dund - config_foreach pand_config pand -} - -stop() { - service_stop /usr/bin/dund - service_stop /usr/bin/pand - /usr/bin/rfcomm release all - service_stop /usr/sbin/hciattach - service_stop /usr/sbin/hcid -} diff --git a/utils/bluez/patches/201-readline.patch b/utils/bluez/patches/201-readline.patch index 9d5bec016..58396dcb0 100644 --- a/utils/bluez/patches/201-readline.patch +++ b/utils/bluez/patches/201-readline.patch @@ -1,6 +1,6 @@ --- a/Makefile.in +++ b/Makefile.in -@@ -2038,7 +2038,7 @@ unit_tests = $(am__append_32) unit/test- +@@ -2055,7 +2055,7 @@ unit_tests = $(am__append_32) unit/test- @CLIENT_TRUE@ monitor/uuid.h monitor/uuid.c @CLIENT_TRUE@client_bluetoothctl_LDADD = gdbus/libgdbus-internal.la @GLIB_LIBS@ @DBUS_LIBS@ \ @@ -9,7 +9,16 @@ @MONITOR_TRUE@monitor_btmon_SOURCES = monitor/main.c monitor/bt.h \ @MONITOR_TRUE@ monitor/display.h monitor/display.c \ -@@ -2245,13 +2245,13 @@ unit_tests = $(am__append_32) unit/test- +@@ -2226,7 +2226,7 @@ unit_tests = $(am__append_32) unit/test- + @EXPERIMENTAL_TRUE@tools_hcieventmask_LDADD = lib/libbluetooth-internal.la + @EXPERIMENTAL_TRUE@tools_btmgmt_SOURCES = tools/btmgmt.c src/uuid-helper.c client/display.c + @EXPERIMENTAL_TRUE@tools_btmgmt_LDADD = lib/libbluetooth-internal.la src/libshared-mainloop.la \ +-@EXPERIMENTAL_TRUE@ -lreadline ++@EXPERIMENTAL_TRUE@ -lreadline -lncurses + + @EXPERIMENTAL_TRUE@tools_btinfo_SOURCES = tools/btinfo.c monitor/bt.h + @EXPERIMENTAL_TRUE@tools_btinfo_LDADD = src/libshared-mainloop.la +@@ -2266,13 +2266,13 @@ unit_tests = $(am__append_32) unit/test- @READLINE_TRUE@ client/display.h @READLINE_TRUE@attrib_gatttool_LDADD = lib/libbluetooth-internal.la \ @@ -25,7 +34,7 @@ @READLINE_TRUE@tools_obex_server_tool_SOURCES = $(gobex_sources) $(btio_sources) \ @READLINE_TRUE@ tools/obex-server-tool.c -@@ -2261,13 +2261,13 @@ unit_tests = $(am__append_32) unit/test- +@@ -2282,13 +2282,13 @@ unit_tests = $(am__append_32) unit/test- @READLINE_TRUE@ client/display.h client/display.c @READLINE_TRUE@tools_bluetooth_player_LDADD = gdbus/libgdbus-internal.la \ diff --git a/utils/btrfs-progs/Makefile b/utils/btrfs-progs/Makefile index ea486b9a4..12513e15d 100644 --- a/utils/btrfs-progs/Makefile +++ b/utils/btrfs-progs/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=btrfs-progs -PKG_VERSION:=3.17.3 -PKG_RELEASE:=2 +PKG_VERSION:=3.19.1 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-v$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@KERNEL/linux/kernel/people/kdave/btrfs-progs/ -PKG_MD5SUM:=6716b4b109dd909af63ab3becbad67a6 +PKG_MD5SUM:=ec3b3c99df18633ddc9e41f0680c5a51 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-v$(PKG_VERSION) PKG_MAINTAINER:=Daniel Golle @@ -24,13 +24,15 @@ PKG_INSTALL:=1 PKG_BUILD_PARALLEL:=1 PKG_BUILD_DEPENDS:=libacl +PKG_FIXUP:=autoreconf + include $(INCLUDE_DIR)/package.mk define Package/btrfs-progs SECTION:=utils CATEGORY:=Utilities SUBMENU:=Filesystem - DEPENDS:=+libattr +libuuid +zlib +libext2fs +libblkid +liblzo +libpthread + DEPENDS:=+libattr +libuuid +zlib +libblkid +liblzo +libpthread TITLE:=Btrfs filesystems utilities URL:=http://btrfs.wiki.kernel.org/ endef @@ -42,25 +44,20 @@ define Package/btrfs-progs/description GPL and open for contribution from anyone. endef -progs = btrfs btrfsck btrfs-convert btrfs-debug-tree btrfs-find-root \ - btrfs-image btrfs-map-logical btrfs-show-super btrfstune \ - btrfs-zero-log fsck.btrfs mkfs.btrfs - +progs = btrfs btrfs-debug-tree btrfs-find-root btrfs-image btrfs-map-logical \ + btrfs-show-super btrfstune btrfs-zero-log fsck.btrfs mkfs.btrfs -MAKE_FLAGS+=\ - CC="$(TARGET_CC)" \ - CFLAGS="$(TARGET_CPPFLAGS) $(TARGET_CFLAGS)" \ - LDFLAGS="$(TARGET_LDFLAGS)" \ - prefix=/usr \ - DESTDIR=$(PKG_INSTALL_DIR) \ - DISABLE_BACKTRACE=1 \ - DISABLE_DOCUMENTATION=1 +CONFIGURE_ARGS += \ + --disable-backtrace \ + --disable-convert \ + --disable-documentation define Package/btrfs-progs/install $(INSTALL_DIR) $(1)/usr/lib $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/libbtrfs.so* $(1)/usr/lib $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) $(addprefix $(PKG_INSTALL_DIR)/usr/bin/, $(progs)) $(1)/usr/bin/ + $(LN) btrfs $(1)/usr/bin/btrfsck $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_BIN) ./files/btrfs-scan.init $(1)/etc/init.d/btrfs-scan endef diff --git a/utils/btrfs-progs/patches/001-fix-xattr-h-include-location.patch b/utils/btrfs-progs/patches/001-fix-xattr-h-include-location.patch index 0e3216952..aff55855b 100644 --- a/utils/btrfs-progs/patches/001-fix-xattr-h-include-location.patch +++ b/utils/btrfs-progs/patches/001-fix-xattr-h-include-location.patch @@ -1,16 +1,20 @@ ---- a/mkfs.c -+++ b/mkfs.c -@@ -34,7 +34,7 @@ +Index: btrfs-progs-v3.19.1/mkfs.c +=================================================================== +--- btrfs-progs-v3.19.1.orig/mkfs.c ++++ btrfs-progs-v3.19.1/mkfs.c +@@ -31,7 +31,7 @@ #include #include #include -#include +#include + #include + #include #include - #include - #include "ctree.h" ---- a/props.c -+++ b/props.c +Index: btrfs-progs-v3.19.1/props.c +=================================================================== +--- btrfs-progs-v3.19.1.orig/props.c ++++ btrfs-progs-v3.19.1/props.c @@ -17,7 +17,7 @@ #include #include @@ -20,9 +24,11 @@ #include #include ---- a/cmds-receive.c -+++ b/cmds-receive.c -@@ -39,7 +39,7 @@ +Index: btrfs-progs-v3.19.1/cmds-receive.c +=================================================================== +--- btrfs-progs-v3.19.1.orig/cmds-receive.c ++++ btrfs-progs-v3.19.1/cmds-receive.c +@@ -34,7 +34,7 @@ #include #include #include @@ -31,9 +37,11 @@ #include #include "ctree.h" ---- a/cmds-restore.c -+++ b/cmds-restore.c -@@ -34,7 +34,7 @@ +Index: btrfs-progs-v3.19.1/cmds-restore.c +=================================================================== +--- btrfs-progs-v3.19.1.orig/cmds-restore.c ++++ btrfs-progs-v3.19.1/cmds-restore.c +@@ -32,7 +32,7 @@ #include #include #include @@ -42,14 +50,30 @@ #include "ctree.h" #include "disk-io.h" ---- a/Makefile -+++ b/Makefile -@@ -26,7 +26,7 @@ TESTS = fsck-tests.sh convert-tests.sh - INSTALL = install - prefix ?= /usr/local - bindir = $(prefix)/bin --lib_LIBS = -luuid -lblkid -lm -lz -llzo2 -L. -+lib_LIBS = -lattr -luuid -lblkid -lm -lz -llzo2 -L. - libdir ?= $(prefix)/lib - incdir = $(prefix)/include/btrfs - LIBS = $(lib_LIBS) $(libs_static) +Index: btrfs-progs-v3.19.1/Makefile.in +=================================================================== +--- btrfs-progs-v3.19.1.orig/Makefile.in ++++ btrfs-progs-v3.19.1/Makefile.in +@@ -21,7 +21,7 @@ CFLAGS = @CFLAGS@ \ + LDFLAGS = @LDFLAGS@ \ + -rdynamic + +-LIBS = @UUID_LIBS@ @BLKID_LIBS@ @ZLIB_LIBS@ @LZO2_LIBS@ -L. -pthread ++LIBS = @ATTR_LIBS@ @UUID_LIBS@ @BLKID_LIBS@ @ZLIB_LIBS@ @LZO2_LIBS@ -L. -pthread + LIBBTRFS_LIBS = $(LIBS) + + # Static compilation flags +Index: btrfs-progs-v3.19.1/configure.ac +=================================================================== +--- btrfs-progs-v3.19.1.orig/configure.ac ++++ btrfs-progs-v3.19.1/configure.ac +@@ -115,6 +115,9 @@ dnl + dnl The default PKG_CHECK_MODULES() action-if-not-found is end the + dnl execution with error. The static libs are optional. + ++PKG_CHECK_MODULES(ATTR, [libattr]) ++PKG_STATIC(BLKID_LIBS_STATIC, [libattr]) ++ + PKG_CHECK_MODULES(BLKID, [blkid]) + PKG_STATIC(BLKID_LIBS_STATIC, [blkid]) + diff --git a/utils/bzip2/Makefile b/utils/bzip2/Makefile deleted file mode 100644 index c633344cf..000000000 --- a/utils/bzip2/Makefile +++ /dev/null @@ -1,80 +0,0 @@ -# -# Copyright (C) 2007-2008 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:=bzip2 -PKG_VERSION:=1.0.6 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=http://www.bzip.org/$(PKG_VERSION) -PKG_MD5SUM:=00b516f4704d4a7cb50a1d97e6e8e15b -PKG_MAINTAINER:=Steven Barth - -PKG_LICENSE:=BZIP2 -PKG_LICENSE_FILES:=LICENSE - -include $(INCLUDE_DIR)/package.mk - -define Package/libbz2 - SECTION:=libs - CATEGORY:=Libraries - DEPENDS:= - TITLE:=bzip2 library. - URL:=http://www.bzip.org/ -endef - -define Package/libbz2/description - bzip2 is a freely available, patent free, high-quality - data compressor. This packages provides libbz2 library. -endef - -define Package/bzip2 - SECTION:=utils - CATEGORY:=Utilities - DEPENDS:=+libbz2 - TITLE:=bzip2 is a compression utility. - URL:=http://www.bzip.org/ -endef - -define Package/bzip2/description - bzip2 is a freely available, patent free, high-quality - data compressor. This package provides the binary. -endef - -TARGET_CFLAGS += $(FPIC) -CONFIGURE_ARGS += --prefix=/usr - -MAKE_FLAGS += \ - -f Makefile-libbz2_so \ - CFLAGS="$(TARGET_CFLAGS)" \ - LDFLAGS="$(TARGET_LDLAGS)" \ - all - -define Build/InstallDev - $(INSTALL_DIR) $(1)/usr/include - $(CP) $(PKG_BUILD_DIR)/bzlib.h $(1)/usr/include/ - $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/ - $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0 - $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so -endef - -define Package/libbz2/install - $(INSTALL_DIR) $(1)/usr/lib/ - $(CP) $(PKG_BUILD_DIR)/libbz2.so.$(PKG_VERSION) $(1)/usr/lib/ - $(LN) libbz2.so.$(PKG_VERSION) $(1)/usr/lib/libbz2.so.1.0 -endef - -define Package/bzip2/install - $(INSTALL_DIR) $(1)/usr/bin/ - $(INSTALL_BIN) $(PKG_BUILD_DIR)/bzip2-shared $(1)/usr/bin/bzip2 -endef - -$(eval $(call BuildPackage,libbz2)) -$(eval $(call BuildPackage,bzip2)) diff --git a/utils/ccid/Makefile b/utils/ccid/Makefile index ce059cbb4..f79f3ad77 100644 --- a/utils/ccid/Makefile +++ b/utils/ccid/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ccid -PKG_VERSION:=1.4.18 +PKG_VERSION:=1.4.19 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:=https://alioth.debian.org/frs/download.php/file/4111 -PKG_MD5SUM:=8d57342bda53aaee706ef2d02409c4f4 +PKG_SOURCE_URL:=https://alioth.debian.org/frs/download.php/file/4132 +PKG_MD5SUM:=d1eed995ba9a2eb395a65a8a78090f52 PKG_MAINTAINER:=Daniel Golle PKG_LICENSE:=LGPL-2.1+ PKG_LICENSE_FILES:=COPYING diff --git a/utils/collectd/Makefile b/utils/collectd/Makefile index 33af152a7..61b05a884 100644 --- a/utils/collectd/Makefile +++ b/utils/collectd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=collectd -PKG_VERSION:=5.4.1 +PKG_VERSION:=5.4.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://collectd.org/files/ -PKG_MD5SUM:=6f56c71c96573a7f4f7fb3bfab185974 +PKG_MD5SUM:=feff9fd0ed89e956d7cf12ba18cfc248 PKG_FIXUP:=autoreconf PKG_REMOVE_FILES:=aclocal.m4 libltdl/aclocal.m4 @@ -298,7 +298,7 @@ $(eval $(call BuildPlugin,logfile,log files output,logfile,)) $(eval $(call BuildPlugin,madwifi,MadWifi status input,madwifi,)) #$(eval $(call BuildPlugin,mysql,MySQL status input,mysql,+PACKAGE_collectd-mod-mysql:libmysqlclient-r)) $(eval $(call BuildPlugin,memory,physical memory usage input,memory,)) -$(eval $(call BuildPlugin,modbus,read variables through libmodbus,modbus,+PACKAGE_collectd-mod-modbus:libmodbus @BROKEN)) +$(eval $(call BuildPlugin,modbus,read variables through libmodbus,modbus,+PACKAGE_collectd-mod-modbus:libmodbus)) $(eval $(call BuildPlugin,netlink,netlink input,netlink,+PACKAGE_collectd-mod-netlink:ip @BROKEN)) $(eval $(call BuildPlugin,network,network input/output,network)) $(eval $(call BuildPlugin,nginx,nginx status input,nginx,+PACKAGE_collectd-mod-nginx:libcurl)) diff --git a/utils/collectd/patches/100-rrdtool-add-rrasingle-option.patch b/utils/collectd/patches/100-rrdtool-add-rrasingle-option.patch index d5aafa287..30a71e8d6 100644 --- a/utils/collectd/patches/100-rrdtool-add-rrasingle-option.patch +++ b/utils/collectd/patches/100-rrdtool-add-rrasingle-option.patch @@ -34,7 +34,7 @@ double tmp = atof (value); --- a/src/utils_rrdcreate.c +++ b/src/utils_rrdcreate.c -@@ -211,6 +211,9 @@ static int rra_get (char ***ret, const v +@@ -212,6 +212,9 @@ static int rra_get (char ***ret, const v rts_num = rra_timespans_num; } diff --git a/utils/collectd/patches/200-fix-git-describe-error.patch b/utils/collectd/patches/200-fix-git-describe-error.patch index 0d4120ebf..ac0a32512 100644 --- a/utils/collectd/patches/200-fix-git-describe-error.patch +++ b/utils/collectd/patches/200-fix-git-describe-error.patch @@ -2,7 +2,7 @@ +++ b/version-gen.sh @@ -2,7 +2,7 @@ - DEFAULT_VERSION="5.4.1.git" + DEFAULT_VERSION="5.4.2.git" -VERSION="`git describe 2> /dev/null | sed -e 's/^collectd-//'`" +#VERSION="`git describe 2> /dev/null | sed -e 's/^collectd-//'`" diff --git a/utils/collectd/patches/900-add-iwinfo-plugin.patch b/utils/collectd/patches/900-add-iwinfo-plugin.patch index 1b358d01e..cc95c0c75 100644 --- a/utils/collectd/patches/900-add-iwinfo-plugin.patch +++ b/utils/collectd/patches/900-add-iwinfo-plugin.patch @@ -1,6 +1,6 @@ --- a/configure.ac +++ b/configure.ac -@@ -568,6 +568,9 @@ AC_CHECK_HEADERS(net/pfvar.h, +@@ -580,6 +580,9 @@ AC_CHECK_HEADERS(net/pfvar.h, have_termios_h="no" AC_CHECK_HEADERS(termios.h, [have_termios_h="yes"]) @@ -10,7 +10,7 @@ # # Checks for typedefs, structures, and compiler characteristics. # -@@ -4819,6 +4822,7 @@ plugin_interface="no" +@@ -4841,6 +4844,7 @@ plugin_interface="no" plugin_ipmi="no" plugin_ipvs="no" plugin_irq="no" @@ -18,7 +18,7 @@ plugin_libvirt="no" plugin_load="no" plugin_memory="no" -@@ -5157,6 +5161,7 @@ AC_PLUGIN([ipmi], [$plugin_ipmi], +@@ -5179,6 +5183,7 @@ AC_PLUGIN([ipmi], [$plugin_ipmi], AC_PLUGIN([iptables], [$with_libiptc], [IPTables rule counters]) AC_PLUGIN([ipvs], [$plugin_ipvs], [IPVS connection statistics]) AC_PLUGIN([irq], [$plugin_irq], [IRQ statistics]) @@ -26,7 +26,7 @@ AC_PLUGIN([java], [$with_java], [Embed the Java Virtual Machine]) AC_PLUGIN([libvirt], [$plugin_libvirt], [Virtual machine statistics]) AC_PLUGIN([load], [$plugin_load], [System load]) -@@ -5458,6 +5463,7 @@ Configuration: +@@ -5480,6 +5485,7 @@ Configuration: protobuf-c . . . . . $have_protoc_c oracle . . . . . . . $with_oracle python . . . . . . . $with_python @@ -34,7 +34,7 @@ Features: daemon mode . . . . . $enable_daemon -@@ -5502,6 +5508,7 @@ Configuration: +@@ -5524,6 +5530,7 @@ Configuration: iptables . . . . . . $enable_iptables ipvs . . . . . . . . $enable_ipvs irq . . . . . . . . . $enable_irq @@ -52,7 +52,7 @@ #@BUILD_PLUGIN_JAVA_TRUE@LoadPlugin java #@BUILD_PLUGIN_LIBVIRT_TRUE@LoadPlugin libvirt @BUILD_PLUGIN_LOAD_TRUE@@BUILD_PLUGIN_LOAD_TRUE@LoadPlugin load -@@ -467,6 +468,12 @@ +@@ -502,6 +503,12 @@ # IgnoreSelected true # @@ -67,7 +67,7 @@ # JVMArg "-Djava.class.path=@prefix@/share/collectd/java/collectd-api.jar" --- a/src/collectd.conf.pod +++ b/src/collectd.conf.pod -@@ -2056,6 +2056,27 @@ and all other interrupts are collected. +@@ -2077,6 +2077,27 @@ and all other interrupts are collected. =back diff --git a/utils/collectd/patches/905-fix-sigrok-upstream-patch-post-541 b/utils/collectd/patches/905-fix-sigrok-upstream-patch-post-541 deleted file mode 100644 index 2b614cc8e..000000000 --- a/utils/collectd/patches/905-fix-sigrok-upstream-patch-post-541 +++ /dev/null @@ -1,31 +0,0 @@ ---- a/configure.ac -+++ b/configure.ac -@@ -3825,18 +3825,20 @@ AC_ARG_WITH(libsigrok, [AS_HELP_STRING([--with-libsigrok@<:@=PREFIX@:>@], [Path - with_libsigrok_ldflags="-L$withval/lib" - fi - fi --],[]) -+],[with_libsigrok="yes"]) - - # libsigrok has a glib dependency - if test "x$with_libsigrok" = "xyes" - then -- if test -z "m4_ifdef([AM_PATH_GLIB_2_0], [yes], [])" -- then -- with_libsigrok="no (glib not available)" -- else -- AM_PATH_GLIB_2_0([2.28.0], -- [with_libsigrok_cflags="$with_libsigrok_cflags $GLIB_CFLAGS"; with_libsigrok_ldflags="$with_libsigrok_ldflags $GLIB_LIBS"]) -- fi -+m4_ifdef([AM_PATH_GLIB_2_0], -+ [ -+ AM_PATH_GLIB_2_0([2.28.0], -+ [with_libsigrok_cflags="$with_libsigrok_cflags $GLIB_CFLAGS"; with_libsigrok_ldflags="$with_libsigrok_ldflags $GLIB_LIBS"]) -+ ], -+ [ -+ with_libsigrok="no (glib not available)" -+ ] -+) - fi - - # libsigrok headers diff --git a/utils/cryptodev-linux/Makefile b/utils/cryptodev-linux/Makefile index e9af4ca91..507cf4f5f 100644 --- a/utils/cryptodev-linux/Makefile +++ b/utils/cryptodev-linux/Makefile @@ -11,7 +11,7 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=cryptodev-linux PKG_VERSION:=1.7 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://download.gna.org/cryptodev-linux/ diff --git a/utils/cryptodev-linux/patches/001-no-get-unused-fd.patch b/utils/cryptodev-linux/patches/001-no-get-unused-fd.patch new file mode 100644 index 000000000..e3308bbe6 --- /dev/null +++ b/utils/cryptodev-linux/patches/001-no-get-unused-fd.patch @@ -0,0 +1,13 @@ +Index: cryptodev-linux-1.7/ioctl.c +=================================================================== +--- cryptodev-linux-1.7.orig/ioctl.c ++++ cryptodev-linux-1.7/ioctl.c +@@ -546,7 +546,7 @@ static int + clonefd(struct file *filp) + { + int ret; +- ret = get_unused_fd(); ++ ret = get_unused_fd_flags(0); + if (ret >= 0) { + get_file(filp); + fd_install(ret, filp); diff --git a/utils/cryptsetup/Makefile b/utils/cryptsetup/Makefile index 330c4ecb6..fb7fc1211 100644 --- a/utils/cryptsetup/Makefile +++ b/utils/cryptsetup/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=cryptsetup -PKG_VERSION:=1.6.6 +PKG_VERSION:=1.6.7 PKG_RELEASE:=1 PKG_LICENSE:=GPL-2.0+ LGPL-2.1+ PKG_LICENSE_FILES:=COPYING COPYING.LGPL PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@KERNEL/linux/utils/cryptsetup/v1.6 -PKG_MD5SUM:=179c0781de59838a4e39f61b2df5ea48 +PKG_MD5SUM:=918406eb5d2e2f5a7348c432ea9b1473 PKG_MAINTAINER:=Daniel Golle PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) diff --git a/utils/dbus/Makefile b/utils/dbus/Makefile index b47d40be4..2b5081ea2 100644 --- a/utils/dbus/Makefile +++ b/utils/dbus/Makefile @@ -9,15 +9,16 @@ include $(TOPDIR)/rules.mk # Make sure to also update the dbus-x package PKG_NAME:=dbus -PKG_VERSION:=1.9.10 +PKG_VERSION:=1.9.14 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://dbus.freedesktop.org/releases/dbus/ -PKG_MD5SUM:=72390a741009017258c00a3268daa728 +PKG_MD5SUM:=32cd0d16067422bfd691e2f647b432b0 PKG_MAINTAINER:=Steven Barth PKG_LICENSE:=AFL-2.1 +PKG_BUILD_PARALLEL:=1 PKG_FIXUP:=autoreconf PKG_INSTALL:=1 diff --git a/utils/dosfstools/Makefile b/utils/dosfstools/Makefile index f5b2f94d7..41483f2ef 100644 --- a/utils/dosfstools/Makefile +++ b/utils/dosfstools/Makefile @@ -71,7 +71,7 @@ endef define Build/Compile $(MAKE) -C $(PKG_BUILD_DIR) \ $(TARGET_CONFIGURE_OPTS) \ - OPTFLAGS="$(TARGET_CFLAGS) -D_FILE_OFFSET_BITS=64" \ + OPTFLAGS="$(TARGET_CFLAGS) -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE" \ PREFIX="/usr" \ SBINDIR="/usr/sbin" \ LDFLAGS="$(LDFLAGS)" \ diff --git a/utils/f2fs-tools/patches/010-include-byteswap-h.patch b/utils/f2fs-tools/patches/010-include-byteswap-h.patch new file mode 100644 index 000000000..b8c9ff30e --- /dev/null +++ b/utils/f2fs-tools/patches/010-include-byteswap-h.patch @@ -0,0 +1,10 @@ +--- a/include/f2fs_fs.h ++++ b/include/f2fs_fs.h +@@ -12,6 +12,7 @@ + #include + #include + #include ++#include + + #ifdef HAVE_CONFIG_H + #include diff --git a/utils/flashrom/Config.in b/utils/flashrom/Config.in new file mode 100644 index 000000000..552001afc --- /dev/null +++ b/utils/flashrom/Config.in @@ -0,0 +1,279 @@ +menu "Flashrom configuration" + depends on PACKAGE_flashrom + + choice + prompt "Default Programmer" + default DEFPROG_INTERNAL if FLASHROM_PCI + default DEFPROG_LINUX_SPI + + config DEFPROG_INTERNAL + depends on FRPROG_INTERNAL + bool "Internal" + + config DEFPROG_LINUX_SPI + depends on FRPROG_LINUX_SPI + bool "Linux SPI" + + config DEFPROG_SERPROG + depends on FRPROG_SERPROG + bool "Serial" + + config DEFPROG_RAYER_SPI + depends on FRPROG_RAYER_SPI + bool "Rayer SPI" + + config DEFPROG_PONY_SPI + depends on FRPROG_PONY_SPI + bool "Pony SPI" + + config DEFPROG_NIC3COM + depends on FRPROG_NIC3COM + bool "NIC3Com" + + config DEFPROG_GFXNVIDIA + depends on FRPROG_GFXNVIDIA + bool "GFX Nvidia" + + config DEFPROG_SATASII + depends on FRPROG_SATASII + bool "SATASII" + +# config DEFPROG_ATAHPT +# depends on FRPROG_ATAHPT +# bool "Highpoint (HPT) ATA/RAID" + + config DEFPROG_ATAVIA + depends on FRPROG_ATAVIA + bool "ATAVIA" + + config DEFPROG_FT2232_SPI + depends on FRPROG_FT2232_SPI + bool "FT2232 SPI" + + config DEFPROG_USBBLASTER_SPI + depends on FRPROG_USBBLASTER_SPI + bool "USBBlaster SPI" + +# config DEFPROG_MSTARDDC_SPI +# depends on FRPROG_MSTARDDC_SPI +# bool "MSTAR DDC SPI" + + config DEFPROG_PICKIT2_SPI + depends on FRPROG_PICKIT2_SPI + bool "PICkit2 SPI" + + config DEFPROG_DUMMY + depends on FRPROG_DUMMY + bool "Dummy" + + config DEFPROG_DRKAISER + depends on FRPROG_DRKAISER + bool "Dr. Kaiser" + + config DEFPROG_NICREALTEK + depends on FRPROG_NICREALTEK + bool "Realtek NICs" + +# config DEFPROG_NICNATSEMI +# depends on FRPROG_NICNATSEMI +# bool "National Semiconductor NICs" + + config DEFPROG_NICINTEL + depends on FRPROG_NICINTEL + bool "Intel NICs" + + config DEFPROG_NICINTEL_SPI + depends on FRPROG_NICINTEL_SPI + bool "Intel NICs SPI" + + config DEFPROG_NICINTEL_EEPROM + depends on FRPROG_NICINTEL_EEPROM + bool "Intel NICs EEPROM" + + config DEFPROG_OGP_SPI + depends on FRPROG_OGP_SPI + bool "OGP SPI" + + config DEFPROG_BUSPIRATE_SPI + depends on FRPROG_BUSPIRATE_SPI + bool "SPI BUS Pirate" + +# config DEFPROG_DEDIPROG +# depends on FRPROG_DEDIPROG +# bool "Dediprog SF100" + + config DEFPROG_SATAMV + depends on FRPROG_SATAMV + bool "Marvell SATA" + + config DEFPROG_IT8212 + depends on FRPROG_IT8212 + bool "ITE IT8212F PATA" + endchoice + + + menu "Misc Programmers" + config FRPROG_LINUX_SPI + bool "Linux SPI" + default y + +# config FRPROG_MSTARDDC_SPI +# bool "MSTAR DDC" +# default n + + config FRPROG_DUMMY + bool "Dummy" + default y + endmenu + + + config FLASHROM_FTDI + bool "FTDI Support" + default y + + menu "FTDI Programmers" + depends on FLASHROM_FTDI + + config FRPROG_FT2232_SPI + depends on FLASHROM_FTDI + bool "FT2232 SPI" + default y + + config FRPROG_USBBLASTER_SPI + depends on FLASHROM_FTDI + bool "USBBlaster SPI" + default y + endmenu + + + config FLASHROM_PCI + bool "PCI Support" + default y if (TARGET_x86||TARGET_x86_64) + + menu "PCI Programmers" + depends on FLASHROM_PCI + + config FRPROG_INTERNAL + depends on FLASHROM_PCI + bool "Internal" + default y + + config FRPROG_RAYER_SPI + depends on FLASHROM_PCI + bool "Rayer SPI" + default y + + config FRPROG_NIC3COM + depends on FLASHROM_PCI + bool "NIC3Com" + default y + + config FRPROG_GFXNVIDIA + depends on FLASHROM_PCI + bool "GFX Nvidia" + default y + + config FRPROG_SATASII + depends on FLASHROM_PCI + bool "SATASII" + default y + +# config FRPROG_ATAHPT +# depends on FLASHROM_PCI +# bool "Highpoint (HPT) ATA/RAID" +# default n + + config FRPROG_ATAVIA + depends on FLASHROM_PCI + bool "ATAVIA" + default y + + config FRPROG_IT8212 + depends on FLASHROM_PCI + bool "ITE IT8212F PATA" + default y + + config FRPROG_DRKAISER + depends on FLASHROM_PCI + bool "Dr. Kaiser" + default y + + config FRPROG_NICREALTEK + depends on FLASHROM_PCI + bool "Realtek NICs" + default y + +# config FRPROG_NICNATSEMI +# depends on FLASHROM_PCI +# bool "National Semiconductor NICs" +# default n + + config FRPROG_NICINTEL + depends on FLASHROM_PCI + bool "Intel NICs" + default y + + config FRPROG_NICINTEL_SPI + depends on FLASHROM_PCI + bool "Intel NICs SPI" + default y + + config FRPROG_NICINTEL_EEPROM + depends on FLASHROM_PCI + bool "Intel NICs EEPROM" + default y + + config FRPROG_OGP_SPI + depends on FLASHROM_PCI + bool "OGP SPI" + default y + + config FRPROG_SATAMV + depends on FLASHROM_PCI + bool "Marvell SATA" + default y + endmenu + + + config FLASHROM_SERIAL + bool "Serial Support" + default y + + menu "Serial Programmers" + depends on FLASHROM_SERIAL + + config FRPROG_SERPROG + depends on FLASHROM_SERIAL + bool "Serial" + default y + + config FRPROG_PONY_SPI + depends on FLASHROM_SERIAL + bool "Pony SPI" + default y + + config FRPROG_BUSPIRATE_SPI + depends on FLASHROM_SERIAL + bool "SPI BUS Pirate" + default y + endmenu + + + config FLASHROM_USB + bool "USB Support" + default y + + menu "USB Programmers" + depends on FLASHROM_USB + + config FRPROG_PICKIT2_SPI + depends on FLASHROM_USB + bool "PICkit2 SPI" + default y + +# config FRPROG_DEDIPROG +# depends on FLASHROM_USB +# bool "Dediprog SF100" +# default n + endmenu +endmenu diff --git a/utils/flashrom/Makefile b/utils/flashrom/Makefile index 45e20caf9..af7b5e1dd 100644 --- a/utils/flashrom/Makefile +++ b/utils/flashrom/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2010-2014 OpenWrt.org +# Copyright (C) 2010-2015 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:=flashrom -PKG_VERSION:=0.9.7 -PKG_RELEASE:=2 +PKG_VERSION:=0.9.8 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://download.flashrom.org/releases -PKG_MD5SUM:=d239bafa1b46619d851f70f84a5b122a +PKG_MD5SUM:=ac513076b63ab7eb411a7694bb8f6fda PKG_MAINTAINER:=Álvaro Fernández Rojas PKG_LICENSE:=GPL-2.0 @@ -22,13 +22,22 @@ PKG_LICENSE_FILES:=COPYING PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk +include flashrom.mk define Package/flashrom SECTION:=utils CATEGORY:=Utilities TITLE:=FlashROM Utility URL:=http://www.flashrom.org/ - DEPENDS:=+zlib +pciutils +(TARGET_x86||TARGET_x86_64):dmidecode +libftdi + DEPENDS:=\ + +(TARGET_x86||TARGET_x86_64):dmidecode \ + +FLASHROM_FTDI:libftdi \ + +FLASHROM_PCI:pciutils \ + +FLASHROM_USB:libusb-compat +endef + +define Package/flashrom/config + source "$(SOURCE)/Config.in" endef define Package/flashrom/description diff --git a/utils/flashrom/flashrom.mk b/utils/flashrom/flashrom.mk new file mode 100644 index 000000000..14fc5d88d --- /dev/null +++ b/utils/flashrom/flashrom.mk @@ -0,0 +1,54 @@ +# Flashrom configuration +define DefineConfig + ifeq ($(CONFIG_FLASHROM_$(1)),) + MAKE_FLAGS += NEED_$(1)=0 + endif +endef +define DefineProgrammer + ifeq ($(CONFIG_FRPROG_$(1)),) + MAKE_FLAGS += CONFIG_$(1)=0 + endif + ifneq ($(CONFIG_DEFPROG_$(1)),) + MAKE_FLAGS += CONFIG_DEFAULT_PROGRAMMER=CONFIG_$(1) + endif +endef + +# Misc +$(eval $(call DefineProgrammer,LINUX_SPI)) +#$(eval $(call DefineProgrammer,MSTARDDC_SPI)) +$(eval $(call DefineProgrammer,DUMMY)) + +# FTDI +$(eval $(call DefineConfig,FTDI)) +$(eval $(call DefineProgrammer,FT2232_SPI)) +$(eval $(call DefineProgrammer,USBBLASTER_SPI)) + +# PCI +$(eval $(call DefineConfig,PCI)) +$(eval $(call DefineProgrammer,INTERNAL)) +$(eval $(call DefineProgrammer,RAYER_SPI)) +$(eval $(call DefineProgrammer,NIC3COM)) +$(eval $(call DefineProgrammer,GFXNVIDIA)) +$(eval $(call DefineProgrammer,SATASII)) +#$(eval $(call DefineProgrammer,ATAHPT)) +$(eval $(call DefineProgrammer,ATAVIA)) +$(eval $(call DefineProgrammer,IT8212)) +$(eval $(call DefineProgrammer,DRKAISER)) +$(eval $(call DefineProgrammer,NICREALTEK)) +#$(eval $(call DefineProgrammer,NICNATSEMI)) +$(eval $(call DefineProgrammer,NICINTEL)) +$(eval $(call DefineProgrammer,NICINTEL_SPI)) +$(eval $(call DefineProgrammer,NICINTEL_EEPROM)) +$(eval $(call DefineProgrammer,OGP_SPI)) +$(eval $(call DefineProgrammer,SATAMV)) + +# Serial +$(eval $(call DefineConfig,SERIAL)) +$(eval $(call DefineProgrammer,SERPROG)) +$(eval $(call DefineProgrammer,PONY_SPI)) +$(eval $(call DefineProgrammer,BUSPIRATE_SPI)) + +# USB +$(eval $(call DefineConfig,USB)) +$(eval $(call DefineProgrammer,PICKIT2_SPI)) +#$(eval $(call DefineProgrammer,DEDIPROG)) diff --git a/utils/flashrom/patches/0001-fix_internal_bitbang.patch b/utils/flashrom/patches/0001-fix_internal_bitbang.patch new file mode 100644 index 000000000..376d6b285 --- /dev/null +++ b/utils/flashrom/patches/0001-fix_internal_bitbang.patch @@ -0,0 +1,11 @@ +--- a/programmer.h ++++ b/programmer.h +@@ -557,7 +557,7 @@ enum spi_controller { + #if CONFIG_DEDIPROG == 1 + SPI_CONTROLLER_DEDIPROG, + #endif +-#if CONFIG_OGP_SPI == 1 || CONFIG_NICINTEL_SPI == 1 || CONFIG_RAYER_SPI == 1 || CONFIG_PONY_SPI == 1 || (CONFIG_INTERNAL == 1 && (defined(__i386__) || defined(__x86_64__))) ++#if CONFIG_OGP_SPI == 1 || CONFIG_NICINTEL_SPI == 1 || CONFIG_RAYER_SPI == 1 || CONFIG_PONY_SPI == 1 || CONFIG_INTERNAL == 1 + SPI_CONTROLLER_BITBANG, + #endif + #if CONFIG_LINUX_SPI == 1 diff --git a/utils/flashrom/patches/0002-fix-musl-compatibility.patch b/utils/flashrom/patches/0002-fix-musl-compatibility.patch new file mode 100644 index 000000000..b52f8b2f9 --- /dev/null +++ b/utils/flashrom/patches/0002-fix-musl-compatibility.patch @@ -0,0 +1,12 @@ +diff -uprN a/linux_spi.c b/linux_spi.c +--- a/linux_spi.c 2015-06-17 20:50:36.492963100 +0200 ++++ b/linux_spi.c 2015-06-17 20:50:00.444860800 +0200 +@@ -22,7 +22,7 @@ + #include + #include + #include +-#include ++#include + #include + #include + #include diff --git a/utils/flashrom/patches/100-mipsel_fix.patch b/utils/flashrom/patches/100-mipsel_fix.patch deleted file mode 100755 index 3e34aeec4..000000000 --- a/utils/flashrom/patches/100-mipsel_fix.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff -uprN a/internal.c b/internal.c ---- a/internal.c 2014-06-13 16:44:14.263689579 +0200 -+++ b/internal.c 2014-06-13 16:46:04.229020785 +0200 -@@ -337,10 +337,12 @@ int internal_init(void) - init_superio_ite(); - #endif - -+#if defined(__i386__) || defined(__x86_64__) || defined (__arm__) - if (board_flash_enable(board_vendor, board_model, cb_vendor, cb_model)) { - msg_perr("Aborting to be safe.\n"); - return 1; - } -+#endif - - #if defined(__i386__) || defined(__x86_64__) || defined (__mips) - register_par_programmer(&par_programmer_internal, internal_buses_supported); diff --git a/utils/gammu/Makefile b/utils/gammu/Makefile index 11a5885a7..6b19c9dcc 100644 --- a/utils/gammu/Makefile +++ b/utils/gammu/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gammu PKG_VERSION:=1.34.0 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE_URL:=http://dl.cihar.com/gammu/releases/ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz @@ -18,8 +18,11 @@ PKG_MD5SUM:=5bc2508389d9b291ca0b8d4f210d0012 PKG_MAINTAINER:=Vitaly Protsko PKG_LICENCE:=GPL-2.0 +PKG_INSTALL:=1 + include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/nls.mk +include $(INCLUDE_DIR)/cmake.mk define Package/gammu SECTION:=utils @@ -28,34 +31,18 @@ define Package/gammu URL:=http://dl.cihar.com/gammu/releases/ DEPENDS:=+libpthread +libcurl +glib2 $(ICONV_DEPENDS) $(INTL_DEPENDS) DEPENDS+=+PACKAGE_python:python +PACKAGE_bluez-libs:bluez-libs - DEPENDS+=+PACKAGE_libmysqlclient:libmysqlclient +PACKAGE_unixodbc:unixodbc + DEPENDS+=+PACKAGE_libmysqlclient:libmysqlclient +PACKAGE_unixodbc:unixodbc +PACKAGE_libpq:libpq DEPENDS+=+PACKAGE_libusb-1.0:libusb-1.0 endef -CONFIGURE_ARGS:= \ - --prefix=/usr \ - --cross-root="$(STAGING_DIR) $(TOOLCHAIN_DIR)" \ - --enable-shared \ - --without-libdbi - -define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - $(TARGET_CONFIGURE_OPTS) \ - LDSHARED="$(TARGET_CROSS)ld -shared" \ - CFLAGS="$(TARGET_CFLAGS) $(FPIC)" -endef +CMAKE_OPTIONS += -DWITH_LibDBI:BOOL=OFF -define Build/Install - $(MAKE) -C $(PKG_BUILD_DIR) \ - DESTDIR="$(PKG_INSTALL_DIR)" \ - install -endef define Build/InstallDev mkdir -p $(1)/usr/include $(CP) -r $(PKG_INSTALL_DIR)/usr/include/gammu $(1)/usr/include/ mkdir -p $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{Gammu*,gsmsd*} $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib$(LIB_SUFFIX)/lib{Gammu*,gsmsd*} $(1)/usr/lib/ endef define Package/gammu/install @@ -63,7 +50,7 @@ define Package/gammu/install $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu $(1)/usr/bin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu-{smsd,smsd-inject,smsd-monitor} $(1)/usr/bin $(INSTALL_DIR) $(1)/usr/lib - $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/lib{Gammu*,gsmsd*} $(1)/usr/lib + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib$(LIB_SUFFIX)/lib{Gammu*,gsmsd*} $(1)/usr/lib $(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_DIR) $(1)/etc/config $(INSTALL_CONF) ./files/gammu $(1)/etc/config/gammu diff --git a/utils/gnupg/Makefile b/utils/gnupg/Makefile index 0bec41d8b..c96fbc3a6 100644 --- a/utils/gnupg/Makefile +++ b/utils/gnupg/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=gnupg -PKG_VERSION:=1.4.18 +PKG_VERSION:=1.4.19 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=ftp://ftp.franken.de/pub/crypt/mirror/ftp.gnupg.org/gcrypt/gnupg \ ftp://ftp.gnupg.org/gcrypt/gnupg -PKG_MD5SUM:=54db1be9588b11afbbdd8b82d4ea883a +PKG_MD5SUM:=3af4ab5b3113b3e28d3551ecf9600785 PKG_LICENSE:=GPL-3.0 PKG_LICENSE_FILES:=COPYING diff --git a/utils/haserl/Makefile b/utils/haserl/Makefile index 90bfd24fd..1d58625e1 100644 --- a/utils/haserl/Makefile +++ b/utils/haserl/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2009 OpenWrt.org +# Copyright (C) 2006-2015 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:=haserl -PKG_VERSION:=0.9.33 +PKG_VERSION:=0.9.35 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/haserl -PKG_MD5SUM:=a9decddb508944d56f71dd2f821e2ec5 +PKG_MD5SUM:=918f0b4f6cec0b438c8b5c78f2989010 PKG_MAINTAINER:=Maxim Storchak PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING diff --git a/utils/haserl/patches/100-replace-lua2c-with-sed.patch b/utils/haserl/patches/100-replace-lua2c-with-sed.patch index 5b19fc1ec..4626a0289 100644 --- a/utils/haserl/patches/100-replace-lua2c-with-sed.patch +++ b/utils/haserl/patches/100-replace-lua2c-with-sed.patch @@ -1,6 +1,8 @@ ---- a/src/Makefile.in 2013-09-20 23:52:15.000000000 +0300 -+++ b/src/Makefile.in 2014-05-03 23:06:17.000000000 +0300 -@@ -76,7 +76,6 @@ +diff --git a/src/Makefile.in b/src/Makefile.in +index 31d45f7..d249f67 100644 +--- a/src/Makefile.in ++++ b/src/Makefile.in +@@ -86,7 +86,6 @@ POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : @@ -8,7 +10,7 @@ @INCLUDE_LUASHELL_TRUE@@USE_LUA_TRUE@am__append_1 = h_lua.c h_lua.h @INCLUDE_LUACSHELL_TRUE@@USE_LUA_TRUE@am__append_2 = h_luac.c h_luac.h bin_PROGRAMS = haserl$(EXEEXT) -@@ -115,9 +114,6 @@ +@@ -124,9 +123,6 @@ am__DEPENDENCIES_1 = haserl_DEPENDENCIES = $(am__DEPENDENCIES_1) haserl_LINK = $(CCLD) $(haserl_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ @@ -18,7 +20,7 @@ AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false -@@ -150,8 +146,8 @@ +@@ -159,8 +155,8 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = @@ -29,7 +31,7 @@ am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ -@@ -273,7 +269,7 @@ +@@ -284,7 +280,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -38,7 +40,7 @@ # Not strictly required, but we explicitly do not distribute the generated inc file nodist_haserl_SOURCES = haserl_lualib.inc -@@ -386,10 +382,6 @@ +@@ -396,10 +392,6 @@ haserl$(EXEEXT): $(haserl_OBJECTS) $(haserl_DEPENDENCIES) $(EXTRA_haserl_DEPENDE @rm -f haserl$(EXEEXT) $(AM_V_CCLD)$(haserl_LINK) $(haserl_OBJECTS) $(haserl_LDADD) $(LIBS) @@ -49,7 +51,7 @@ mostlyclean-compile: -rm -f *.$(OBJEXT) -@@ -406,7 +398,6 @@ +@@ -416,7 +408,6 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/haserl-haserl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/haserl-rfc2388.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/haserl-sliding_buffer.Po@am__quote@ @@ -57,8 +59,8 @@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@@ -758,17 +749,13 @@ - tags tags-am uninstall uninstall-am uninstall-binPROGRAMS +@@ -770,17 +761,13 @@ uninstall-am: uninstall-binPROGRAMS + .PRECIOUS: Makefile -# lua2c_LIBS ?= -llua -ldl -lm diff --git a/utils/hdparm/Makefile b/utils/hdparm/Makefile index 8841213e3..fabc46439 100644 --- a/utils/hdparm/Makefile +++ b/utils/hdparm/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=hdparm -PKG_VERSION:=9.45 +PKG_VERSION:=9.48 PKG_RELEASE:=1 PKG_USE_MIPS16:=0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/$(PKG_NAME) -PKG_MD5SUM:=1c75d0751a44928b6c4bc81fb16d7fe8 +PKG_MD5SUM:=213efdbe7471fad3408198918e164354 PKG_MAINTAINER:=Richard Kunze PKG_LICENSE:=BSD-Style Open Source License diff --git a/utils/hdparm/patches/001-fix-includes.patch b/utils/hdparm/patches/001-fix-includes.patch deleted file mode 100644 index 44343fb39..000000000 --- a/utils/hdparm/patches/001-fix-includes.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- a/hdparm.h -+++ b/hdparm.h -@@ -2,6 +2,7 @@ - - //#undef __KERNEL_STRICT_NAMES - #include -+#include - - #if !defined(__GNUC__) && !defined(__attribute__) - #define __attribute__(x) ---- a/sysfs.c -+++ b/sysfs.c -@@ -12,6 +12,7 @@ - #include - #include - #include -+#include - #include - #include - #include diff --git a/utils/hfsprogs/Makefile b/utils/hfsprogs/Makefile new file mode 100644 index 000000000..9c44a3558 --- /dev/null +++ b/utils/hfsprogs/Makefile @@ -0,0 +1,81 @@ +# +# Copyright (C) 2015 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:=hfsprogs +PKG_VERSION:=332.25 +PKG_RELEASE:=1 + +PKG_LICENSE:=GPL-3.0+ +PKG_LICENSE_FILES:=COPYING + +PKG_MAINTAINER:=Florian Fainelli + +PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).orig.tar.gz +PKG_SOURCE_URL:=http://archive.ubuntu.com/ubuntu/pool/universe/h/$(PKG_NAME) +PKG_BUILD_DIR:=$(BUILD_DIR)/diskdev_cmds-$(PKG_VERSION) +PKG_MD5SUM:=261c3de5ec0dcf5244e3f60d79c1d6f1 +PKG_LICENSE:=APSL 2.0 + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/nls.mk + +define Package/hfsprogs/Default + SECTION:=utils + CATEGORY:=Utilities + SUBMENU:=Filesystem + DEPENDS:=+libopenssl +endef + +define Package/hfsfsck + $(call Package/hfsprogs/Default) + TITLE:=fsck (fsck.hfs) utility from hfsprogs +endef + +define Package/mkhfs + $(call Package/hfsprogs/Default) + TITLE:=mkfs (mkfs.hfs) utility from hfsprogs +endef + +define Package/hfsfsck/description + Utilities to create and check HFS/HFS+ filesystems. + (fsck.hfs and fsck.hfsplus for checking integrity of HFS/HFS+ volumes) +endef + +define Package/mkhfs/description + Utilities to create and check HFS/HFS+ filesystems. + (mkfs.hfs and mkfs.hfsplus for creating HFS/HFS+ volumes) +endef + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + -f Makefile.lnx \ + $(TARGET_CONFIGURE_OPTS) \ + CFLAGS+="$(TARGET_CFLAGS) -I$(PKG_BUILD_DIR)/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1" \ + all +endef + +define Package/hfsfsck/install + $(INSTALL_DIR) $(1)/lib/functions/fsck + $(INSTALL_DATA) ./files/hfsfsck.sh $(1)/lib/functions/fsck/ + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/fsck_hfs.tproj/fsck_hfs $(1)/usr/sbin/fsck.hfsplus + (cd $(1)/usr/sbin; ln -sf fsck.hfsplus fsck.hfs;) +endef + +define Package/mkhfs/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/newfs_hfs.tproj/newfs_hfs $(1)/usr/sbin/mkfs.hfsplus + (cd $(1)/usr/sbin; ln -sf mkfs.hfsplus mkfs.hfs;) +endef + +$(eval $(call BuildPackage,hfsfsck)) +$(eval $(call BuildPackage,mkhfs)) diff --git a/utils/hfsprogs/files/hfsfsck.sh b/utils/hfsprogs/files/hfsfsck.sh new file mode 100644 index 000000000..8bcd2c1fd --- /dev/null +++ b/utils/hfsprogs/files/hfsfsck.sh @@ -0,0 +1,30 @@ +#!/bin/sh +# Copyright 2015 OpenWrt.org +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +fsck_hfsfsck() { + hfsfsck "$device" 2>&1 | logger -t "fstab: hfsfsck ($device)" + local status="$?" + case "$status" in + 0) ;; #success + 4) reboot;; + 8) echo "hfsfsck ($device): Warning! Uncorrected errors."| logger -t fstab + return 1 + ;; + *) echo "hfsfsck ($device): Error $status. Check not complete."| logger -t fstab;; + esac + return 0 +} + +fsck_hfs() { + fsck_hfsfsck "$@" +} + +fsck_hfsplus() { + fsck_hfsfsck "$@" +} + +append libmount_known_fsck "hfs" +append libmount_known_fsck "hfsplus" diff --git a/utils/hfsprogs/patches/0001-Create-short-Makefiles-for-Debian.patch b/utils/hfsprogs/patches/0001-Create-short-Makefiles-for-Debian.patch new file mode 100644 index 000000000..a8c419369 --- /dev/null +++ b/utils/hfsprogs/patches/0001-Create-short-Makefiles-for-Debian.patch @@ -0,0 +1,93 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Create short Makefiles for Debian + +Create short Makefiles for compiling just the necessary parts for a +Debian-based (and possibly other distributions) HFS+ filesystem +utilities. +--- + Makefile.lnx | 8 ++++++++ + fsck_hfs.tproj/Makefile.lnx | 16 ++++++++++++++++ + fsck_hfs.tproj/dfalib/Makefile.lnx | 15 +++++++++++++++ + newfs_hfs.tproj/Makefile.lnx | 12 ++++++++++++ + 4 files changed, 51 insertions(+) + create mode 100644 Makefile.lnx + create mode 100644 fsck_hfs.tproj/Makefile.lnx + create mode 100644 fsck_hfs.tproj/dfalib/Makefile.lnx + create mode 100644 newfs_hfs.tproj/Makefile.lnx + +diff --git a/Makefile.lnx b/Makefile.lnx +new file mode 100644 +index 0000000..687d1e7 +--- /dev/null ++++ b/Makefile.lnx +@@ -0,0 +1,8 @@ ++CC := gcc ++CFLAGS += -I$(PWD)/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1 ++SUBDIRS := newfs_hfs.tproj fsck_hfs.tproj ++ ++all clean: ++ for d in $(SUBDIRS); do $(MAKE) -C $$d -f Makefile.lnx $@; done ++ ++export CC CFLAGS +diff --git a/fsck_hfs.tproj/Makefile.lnx b/fsck_hfs.tproj/Makefile.lnx +new file mode 100644 +index 0000000..977d7e8 +--- /dev/null ++++ b/fsck_hfs.tproj/Makefile.lnx +@@ -0,0 +1,16 @@ ++CFILES = fsck_hfs.c strings.c utilities.c cache.c fsck_debug.c ++OFILES = $(CFILES:.c=.o) ++ ++all: fsck_hfs ++ ++fsck_hfs: $(OFILES) dfalib/libdfa.a ++ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OFILES) dfalib/libdfa.a ++ ++dfalib/libdfa.a: FORCE ++ $(MAKE) -C dfalib -f Makefile.lnx CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" libdfa.a ++ ++clean: ++ $(RM) fsck_hfs $(OFILES) ++ $(MAKE) -C dfalib -f Makefile.lnx clean ++ ++.PHONY : FORCE clean +diff --git a/fsck_hfs.tproj/dfalib/Makefile.lnx b/fsck_hfs.tproj/dfalib/Makefile.lnx +new file mode 100644 +index 0000000..8c07196 +--- /dev/null ++++ b/fsck_hfs.tproj/dfalib/Makefile.lnx +@@ -0,0 +1,15 @@ ++CFILES = hfs_endian.c BlockCache.c\ ++ BTree.c BTreeAllocate.c BTreeMiscOps.c \ ++ BTreeNodeOps.c BTreeScanner.c BTreeTreeOps.c\ ++ CatalogCheck.c HardLinkCheck.c\ ++ SBTree.c SControl.c SVerify1.c SVerify2.c\ ++ SRepair.c SRebuildCatalogBTree.c\ ++ SUtils.c SKeyCompare.c SDevice.c SExtents.c SAllocate.c\ ++ SCatalog.c SStubs.c VolumeBitmapCheck.c ++OFILES = $(CFILES:.c=.o) ++ ++libdfa.a: $(OFILES) ++ ar rc $@ $? ++ ++clean: ++ $(RM) $(OFILES) libdfa.a +diff --git a/newfs_hfs.tproj/Makefile.lnx b/newfs_hfs.tproj/Makefile.lnx +new file mode 100644 +index 0000000..58e6700 +--- /dev/null ++++ b/newfs_hfs.tproj/Makefile.lnx +@@ -0,0 +1,12 @@ ++CFILES = hfs_endian.c makehfs.c newfs_hfs.c ++OFILES = $(CFILES:.c=.o) ++ ++all: newfs_hfs ++ ++newfs_hfs: $(OFILES) ++ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OFILES) -lcrypto ++ ++clean: ++ $(RM) newfs_hfs $(OFILES) ++ ++.PHONY : FORCE clean diff --git a/utils/hfsprogs/patches/0002-Add-exclude-Darwin-specific-code.patch b/utils/hfsprogs/patches/0002-Add-exclude-Darwin-specific-code.patch new file mode 100644 index 000000000..0046c364f --- /dev/null +++ b/utils/hfsprogs/patches/0002-Add-exclude-Darwin-specific-code.patch @@ -0,0 +1,1407 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Add/exclude Darwin-specific code + +Modify some of the files so that they can be compiled without the +Apple owned frameworks in a Debian system (and possibly others). +--- + fsck_hfs.tproj/cache.c | 4 ++ + fsck_hfs.tproj/dfalib/BTree.c | 2 + + fsck_hfs.tproj/dfalib/BlockCache.c | 3 + + fsck_hfs.tproj/dfalib/SBTree.c | 2 + + fsck_hfs.tproj/dfalib/SDevice.c | 92 ++++++++++++++++++++--------- + fsck_hfs.tproj/dfalib/SKeyCompare.c | 2 + + fsck_hfs.tproj/dfalib/SRepair.c | 2 + + fsck_hfs.tproj/dfalib/SRuntime.h | 7 ++- + fsck_hfs.tproj/dfalib/SUtils.c | 5 +- + fsck_hfs.tproj/dfalib/SVerify2.c | 7 +++ + fsck_hfs.tproj/dfalib/Scavenger.h | 11 +++- + fsck_hfs.tproj/dfalib/hfs_endian.c | 4 ++ + fsck_hfs.tproj/dfalib/hfs_endian.h | 7 ++- + fsck_hfs.tproj/fsck_hfs.c | 61 +++++++++++++++---- + fsck_hfs.tproj/utilities.c | 8 ++- + include/missing.h | 115 ++++++++++++++++++++++++++++++++++++ + newfs_hfs.tproj/hfs_endian.c | 5 ++ + newfs_hfs.tproj/hfs_endian.h | 5 ++ + newfs_hfs.tproj/makehfs.c | 72 ++++++++++++++++------ + newfs_hfs.tproj/newfs_hfs.c | 74 ++++++++++++++++++++--- + newfs_hfs.tproj/newfs_hfs.h | 26 ++++---- + 21 files changed, 429 insertions(+), 85 deletions(-) + create mode 100644 include/missing.h + +diff --git a/fsck_hfs.tproj/cache.c b/fsck_hfs.tproj/cache.c +index be46195..527088a 100644 +--- a/fsck_hfs.tproj/cache.c ++++ b/fsck_hfs.tproj/cache.c +@@ -26,7 +26,11 @@ + #include + #include + #include ++#if LINUX ++#include "missing.h" ++#else + #include ++#endif /* __LINUX__ */ + #include + #include + #include +diff --git a/fsck_hfs.tproj/dfalib/BTree.c b/fsck_hfs.tproj/dfalib/BTree.c +index edd8301..7ad9fe0 100644 +--- a/fsck_hfs.tproj/dfalib/BTree.c ++++ b/fsck_hfs.tproj/dfalib/BTree.c +@@ -1705,7 +1705,9 @@ OSStatus BTGetInformation (SFCB *filePtr, + UInt16 version, + BTreeInfoRec *info ) + { ++#if !LINUX + #pragma unused (version) ++#endif + + BTreeControlBlockPtr btreePtr; + +diff --git a/fsck_hfs.tproj/dfalib/BlockCache.c b/fsck_hfs.tproj/dfalib/BlockCache.c +index 1bb952f..e3a28a2 100644 +--- a/fsck_hfs.tproj/dfalib/BlockCache.c ++++ b/fsck_hfs.tproj/dfalib/BlockCache.c +@@ -20,6 +20,9 @@ + * @APPLE_LICENSE_HEADER_END@ + */ + ++#if LINUX ++#include "missing.h" ++#endif + #include "SRuntime.h" + #include "Scavenger.h" + #include "../cache.h" +diff --git a/fsck_hfs.tproj/dfalib/SBTree.c b/fsck_hfs.tproj/dfalib/SBTree.c +index 2fbcd1d..cd81b13 100644 +--- a/fsck_hfs.tproj/dfalib/SBTree.c ++++ b/fsck_hfs.tproj/dfalib/SBTree.c +@@ -322,7 +322,9 @@ ErrorExit: + OSStatus + SetEndOfForkProc ( SFCB *filePtr, FSSize minEOF, FSSize maxEOF ) + { ++#if !LINUX + #pragma unused (maxEOF) ++#endif + + OSStatus result; + UInt32 actualSectorsAdded; +diff --git a/fsck_hfs.tproj/dfalib/SDevice.c b/fsck_hfs.tproj/dfalib/SDevice.c +index bf6f61c..9a46023 100644 +--- a/fsck_hfs.tproj/dfalib/SDevice.c ++++ b/fsck_hfs.tproj/dfalib/SDevice.c +@@ -2,7 +2,7 @@ + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ +- * ++ * + * "Portions Copyright (c) 1999 Apple Computer, Inc. All Rights + * Reserved. This file contains Original Code and/or Modifications of + * Original Code as defined in and that are subject to the Apple Public +@@ -10,7 +10,7 @@ + * except in compliance with the License. Please obtain a copy of the + * License at http://www.apple.com/publicsource and read it before using + * this file. +- * ++ * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, +@@ -18,7 +18,7 @@ + * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the + * License for the specific language governing rights and limitations + * under the License." +- * ++ * + * @APPLE_LICENSE_HEADER_END@ + */ + #include "SRuntime.h" +@@ -28,33 +28,71 @@ + #include + #include + #include +- ++#if LINUX ++#include ++#include ++#else + #include +- ++#endif /* LINUX */ + #else +- + #include + #include + #include + + #endif + +- + OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + { + #if BSD + UInt64 devBlockCount = 0; + int devBlockSize = 0; ++#if LINUX ++ struct stat stbuf; ++ ++ devBlockSize = 512; + ++#ifndef BLKGETSIZE ++#define BLKGETSIZE _IO(0x12,96) ++#endif ++#ifndef BLKGETSIZE64 ++#define BLKGETSIZE64 _IOR(0x12,114,size_t) ++#endif ++ if (fstat(driveRefNum, &stbuf) < 0){ ++ printf("Error: %s\n", strerror(errno)); ++ return(-1); ++ } ++ ++ if (S_ISREG(stbuf.st_mode)) { ++ devBlockCount = stbuf.st_size / 512; ++ } ++ else if (S_ISBLK(stbuf.st_mode)) { ++ unsigned long size; ++ u_int64_t size64; ++ if (!ioctl(driveRefNum, BLKGETSIZE64, &size64)) ++ devBlockCount = size64 / 512; ++ else if (!ioctl(driveRefNum, BLKGETSIZE, &size)) ++ devBlockCount = size; ++ else{ ++ printf("Error: %s\n", strerror(errno)); ++ return(-1); ++ } ++ ++ } ++ else{ ++ printf("Device is not a block device"); ++ return(-1); ++ } ++#elif BSD + if (ioctl(driveRefNum, DKIOCGETBLOCKCOUNT, &devBlockCount) < 0) { + printf("ioctl(DKIOCGETBLOCKCOUNT) for fd %d: %s\n", driveRefNum, strerror(errno)); + return (-1); + } +- ++ + if (ioctl(driveRefNum, DKIOCGETBLOCKSIZE, &devBlockSize) < 0) { + printf("ioctl(DKIOCGETBLOCKSIZE) for fd %d: %s\n", driveRefNum, strerror(errno)); + return (-1); + } ++#endif /* BSD */ + + if (devBlockSize != 512) { + *numBlocks = (devBlockCount * (UInt64)devBlockSize) / 512; +@@ -70,24 +108,24 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + { + /* return format list status code */ + kFmtLstCode = 6, +- ++ + /* reference number of .SONY driver */ + kSonyRefNum = 0xfffb, +- ++ + /* values returned by DriveStatus in DrvSts.twoSideFmt */ + kSingleSided = 0, + kDoubleSided = -1, + kSingleSidedSize = 800, /* 400K */ + kDoubleSidedSize = 1600, /* 800K */ +- ++ + /* values in DrvQEl.qType */ + kWordDrvSiz = 0, + kLongDrvSiz = 1, +- ++ + /* more than enough formatListRecords */ + kMaxFormatListRecs = 16 + }; +- ++ + ParamBlockRec pb; + FormatListRec formatListRecords[kMaxFormatListRecs]; + DrvSts status; +@@ -95,22 +133,22 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + OSErr result; + unsigned long blocks = 0; + +- ++ + /* Attempt to get the drive's format list. */ + /* (see the Technical Note "What Your Sony Drives For You") */ +- ++ + pb.cntrlParam.ioVRefNum = driveQElementPtr->dQDrive; + pb.cntrlParam.ioCRefNum = driveQElementPtr->dQRefNum; + pb.cntrlParam.csCode = kFmtLstCode; + pb.cntrlParam.csParam[0] = kMaxFormatListRecs; + *(long *)&pb.cntrlParam.csParam[1] = (long)&formatListRecords[0]; +- ++ + result = PBStatusSync(&pb); +- ++ + if ( result == noErr ) + { + /* The drive supports ReturnFormatList status call. */ +- ++ + /* Get the current disk's size. */ + for( formatListRecIndex = 0; + formatListRecIndex < pb.cntrlParam.csParam[0]; +@@ -131,7 +169,7 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + else if ( driveQElementPtr->dQRefNum == (short)kSonyRefNum ) + { + /* The drive is a non-SuperDrive floppy which only supports 400K and 800K disks */ +- ++ + result = DriveStatus(driveQElementPtr->dQDrive, &status); + if ( result == noErr ) + { +@@ -140,11 +178,11 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + case kSingleSided: + blocks = kSingleSidedSize; + break; +- ++ + case kDoubleSided: + blocks = kDoubleSidedSize; + break; +- ++ + default: // This should never happen + result = paramErr; + break; +@@ -155,20 +193,20 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + { + /* The drive is not a floppy and it doesn't support ReturnFormatList */ + /* so use the dQDrvSz field(s) */ +- ++ + result = noErr; /* reset result */ +- ++ + switch ( driveQElementPtr->qType ) + { + case kWordDrvSiz: + blocks = driveQElementPtr->dQDrvSz; + break; +- ++ + case kLongDrvSiz: + blocks = ((unsigned long)driveQElementPtr->dQDrvSz2 << 16) + + driveQElementPtr->dQDrvSz; + break; +- ++ + default: // This should never happen + result = paramErr; + break; +@@ -177,7 +215,7 @@ OSErr GetDeviceSize(int driveRefNum, UInt64 *numBlocks, UInt32 *blockSize) + + *numBlocks = blocks; + *blockSize = 512; +- ++ + return( result ); + #endif + } +@@ -188,7 +226,7 @@ OSErr DeviceRead(int device, int drive, void* buffer, SInt64 offset, UInt32 reqB + #if BSD + off_t seek_off; + ssize_t nbytes; +- ++ + *actBytes = 0; + + seek_off = lseek(device, offset, SEEK_SET); +diff --git a/fsck_hfs.tproj/dfalib/SKeyCompare.c b/fsck_hfs.tproj/dfalib/SKeyCompare.c +index 46e145f..18d99c5 100644 +--- a/fsck_hfs.tproj/dfalib/SKeyCompare.c ++++ b/fsck_hfs.tproj/dfalib/SKeyCompare.c +@@ -454,7 +454,9 @@ SInt32 CompareExtentKeysPlus( const HFSPlusExtentKey *searchKey, const HFSPlusEx + * The name portion of the key is compared using a 16-bit binary comparison. + * This is called from the b-tree code. + */ ++#if !LINUX + __private_extern__ ++#endif + SInt32 + CompareAttributeKeys(const AttributeKey *searchKey, const AttributeKey *trialKey) + { +diff --git a/fsck_hfs.tproj/dfalib/SRepair.c b/fsck_hfs.tproj/dfalib/SRepair.c +index 01c1a10..8eb759c 100644 +--- a/fsck_hfs.tproj/dfalib/SRepair.c ++++ b/fsck_hfs.tproj/dfalib/SRepair.c +@@ -1617,7 +1617,9 @@ Output: + + static OSErr FixWrapperExtents( SGlobPtr GPtr, RepairOrderPtr p ) + { ++#if !LINUX + #pragma unused (p) ++#endif + + OSErr err; + HFSMasterDirectoryBlock *mdb; +diff --git a/fsck_hfs.tproj/dfalib/SRuntime.h b/fsck_hfs.tproj/dfalib/SRuntime.h +index 646917b..770e3ef 100644 +--- a/fsck_hfs.tproj/dfalib/SRuntime.h ++++ b/fsck_hfs.tproj/dfalib/SRuntime.h +@@ -27,8 +27,11 @@ + #define __SRUNTIME__ + + #if BSD +- ++#if LINUX ++#include "missing.h" ++#else + #include ++#endif + #include + #include + #include +@@ -91,10 +94,12 @@ typedef const unsigned char * ConstStr255Param; + + typedef u_int32_t HFSCatalogNodeID; + ++#if !LINUX + enum { + false = 0, + true = 1 + }; ++#endif + + /* OS error codes */ + enum { +diff --git a/fsck_hfs.tproj/dfalib/SUtils.c b/fsck_hfs.tproj/dfalib/SUtils.c +index 72035f0..6e9253e 100644 +--- a/fsck_hfs.tproj/dfalib/SUtils.c ++++ b/fsck_hfs.tproj/dfalib/SUtils.c +@@ -380,7 +380,8 @@ void InvalidateCalculatedVolumeBitMap( SGlobPtr GPtr ) + // GPtr->realVCB Real in-memory vcb + //------------------------------------------------------------------------------ + +-#if !BSD ++#if BSD ++#if !LINUX + OSErr GetVolumeFeatures( SGlobPtr GPtr ) + { + OSErr err; +@@ -418,7 +419,7 @@ OSErr GetVolumeFeatures( SGlobPtr GPtr ) + return( noErr ); + } + #endif +- ++#endif + + + /*------------------------------------------------------------------------------- +diff --git a/fsck_hfs.tproj/dfalib/SVerify2.c b/fsck_hfs.tproj/dfalib/SVerify2.c +index 6a47935..c68f3d8 100644 +--- a/fsck_hfs.tproj/dfalib/SVerify2.c ++++ b/fsck_hfs.tproj/dfalib/SVerify2.c +@@ -32,7 +32,9 @@ + */ + + #include ++#if !LINUX + #include ++#endif + + #include "BTree.h" + #include "BTreePrivate.h" +@@ -1354,8 +1356,13 @@ OSErr CompareVolumeHeader( SGlobPtr GPtr, HFSPlusVolumeHeader *volumeHeader ) + * clump size for read-only media is irrelevant we skip the clump size + * check to avoid non useful warnings. + */ ++#if LINUX ++ // FIXME ++ isWriteable = 1; ++#else + isWriteable = 0; + ioctl( GPtr->DrvNum, DKIOCISWRITABLE, &isWriteable ); ++#endif + if ( isWriteable != 0 && + volumeHeader->catalogFile.clumpSize != vcb->vcbCatalogFile->fcbClumpSize ) { + PrintError(GPtr, E_InvalidClumpSize, 0); +diff --git a/fsck_hfs.tproj/dfalib/Scavenger.h b/fsck_hfs.tproj/dfalib/Scavenger.h +index cf53970..edb3a80 100644 +--- a/fsck_hfs.tproj/dfalib/Scavenger.h ++++ b/fsck_hfs.tproj/dfalib/Scavenger.h +@@ -37,11 +37,16 @@ + #include "../fsck_debug.h" + + #include ++#if LINUX ++#define XATTR_MAXNAMELEN 127 ++#include ++#else + #include + #include + #include +-#include + #include ++#endif ++#include + + #ifdef __cplusplus + extern "C" { +@@ -1465,4 +1470,8 @@ extern int AllocateContigBitmapBits (SVCB *vcb, UInt32 numBlocks, UInt32 *actua + }; + #endif + ++/* #if LINUX ++#undef XATTR_MAXNAMELEN ++#endif */ ++ + #endif /* __SCAVENGER__ */ +diff --git a/fsck_hfs.tproj/dfalib/hfs_endian.c b/fsck_hfs.tproj/dfalib/hfs_endian.c +index 7fa5385..69500c1 100755 +--- a/fsck_hfs.tproj/dfalib/hfs_endian.c ++++ b/fsck_hfs.tproj/dfalib/hfs_endian.c +@@ -31,7 +31,11 @@ + #include + #include + ++#if LINUX ++#include "missing.h" ++#else + #include ++#endif + #include + + #include "Scavenger.h" +diff --git a/fsck_hfs.tproj/dfalib/hfs_endian.h b/fsck_hfs.tproj/dfalib/hfs_endian.h +index 52d0c3a..0763d9d 100755 +--- a/fsck_hfs.tproj/dfalib/hfs_endian.h ++++ b/fsck_hfs.tproj/dfalib/hfs_endian.h +@@ -27,9 +27,14 @@ + * + * This file prototypes endian swapping routines for the HFS/HFS Plus + * volume format. +- */ ++*/ + #include ++#if LINUX ++#include ++#include ++#else + #include ++#endif + #include "SRuntime.h" + + /*********************/ +diff --git a/fsck_hfs.tproj/fsck_hfs.c b/fsck_hfs.tproj/fsck_hfs.c +index 90532fd..f1a18bd 100644 +--- a/fsck_hfs.tproj/fsck_hfs.c ++++ b/fsck_hfs.tproj/fsck_hfs.c +@@ -24,10 +24,14 @@ + #include + #include + #include ++#if !LINUX + #include ++#endif + #include + #include ++#if !LINUX + #include ++#endif + + #include + +@@ -195,8 +199,12 @@ main(argc, argv) + if (guiControl) + debug = 0; /* debugging is for command line only */ + ++#if LINUX ++// FIXME ++#else + if (signal(SIGINT, SIG_IGN) != SIG_IGN) + (void)signal(SIGINT, catch); ++#endif + + if (argc < 1) { + (void) fprintf(stderr, "%s: missing special-device\n", progname); +@@ -218,7 +226,9 @@ checkfilesys(char * filesys) + int chkLev, repLev, logLev; + int blockDevice_fd, canWrite; + char *unraw, *mntonname; ++#if !LINUX + struct statfs *fsinfo; ++#endif + int fs_fd=-1; // fd to the root-dir of the fs we're checking (only w/lfag == 1) + + flags = 0; +@@ -227,7 +237,9 @@ checkfilesys(char * filesys) + canWrite = 0; + unraw = NULL; + mntonname = NULL; +- ++#if LINUX ++ // FIXME ++#else + if (lflag) { + result = getmntinfo(&fsinfo, MNT_NOWAIT); + +@@ -257,10 +269,10 @@ checkfilesys(char * filesys) + } + } + } +- ++#endif + if (debug && preen) + pwarn("starting\n"); +- ++ + if (setup( filesys, &blockDevice_fd, &canWrite ) == 0) { + if (preen) + pfatal("CAN'T CHECK FILE SYSTEM."); +@@ -278,7 +290,7 @@ checkfilesys(char * filesys) + repLev = kMajorRepairs; + logLev = kVerboseLog; + +- if (yflag) ++ if (yflag) + repLev = kMajorRepairs; + + if (quick) { +@@ -298,16 +310,16 @@ checkfilesys(char * filesys) + + if (nflag) + repLev = kNeverRepair; +- ++ + if ( rebuildCatalogBtree ) { + chkLev = kPartialCheck; + repLev = kForceRepairs; // this will force rebuild of catalog B-Tree file + } +- ++ + /* + * go check HFS volume... + */ +- result = CheckHFS( fsreadfd, fswritefd, chkLev, repLev, logLev, ++ result = CheckHFS( fsreadfd, fswritefd, chkLev, repLev, logLev, + guiControl, lostAndFoundMode, canWrite, &fsmodified ); + if (!hotroot) { + ckfini(1); +@@ -330,6 +342,9 @@ checkfilesys(char * filesys) + } + } + } else { ++#if LINUX ++ // FIXME ++#else + struct statfs stfs_buf; + /* + * Check to see if root is mounted read-write. +@@ -339,19 +354,25 @@ checkfilesys(char * filesys) + else + flags = 0; + ckfini(flags & MNT_RDONLY); ++#endif + } + + /* XXX free any allocated memory here */ + + if (hotroot && fsmodified) { ++#if !LINUX + struct hfs_mount_args args; ++#endif + /* + * We modified the root. Do a mount update on + * it, unless it is read-write, so we can continue. + */ + if (!preen) + printf("\n***** FILE SYSTEM WAS MODIFIED *****\n"); +- if (flags & MNT_RDONLY) { ++#if LINUX ++ // FIXME ++#else ++ if (flags & MNT_RDONLY) { + bzero(&args, sizeof(args)); + flags |= MNT_UPDATE | MNT_RELOAD; + if (mount("hfs", "/", flags, &args) == 0) { +@@ -359,6 +380,7 @@ checkfilesys(char * filesys) + goto ExitThisRoutine; + } + } ++#endif + if (!preen) + printf("\n***** REBOOT NOW *****\n"); + sync(); +@@ -367,7 +389,7 @@ checkfilesys(char * filesys) + } + + result = (result == 0) ? 0 : EEXIT; +- ++ + ExitThisRoutine: + if (lflag) { + fcntl(fs_fd, F_THAW_FS, NULL); +@@ -401,16 +423,18 @@ setup( char *dev, int *blockDevice_fdPtr, int *canWritePtr ) + fswritefd = -1; + *blockDevice_fdPtr = -1; + *canWritePtr = 0; +- ++ + if (stat(dev, &statb) < 0) { + printf("Can't stat %s: %s\n", dev, strerror(errno)); + return (0); + } ++#if !LINUX + if ((statb.st_mode & S_IFMT) != S_IFCHR) { + pfatal("%s is not a character device", dev); + if (reply("CONTINUE") == 0) + return (0); + } ++#endif + if ((fsreadfd = open(dev, O_RDONLY)) < 0) { + printf("Can't open %s: %s\n", dev, strerror(errno)); + return (0); +@@ -419,7 +443,7 @@ setup( char *dev, int *blockDevice_fdPtr, int *canWritePtr ) + /* attempt to get write access to the block device and if not check if volume is */ + /* mounted read-only. */ + getWriteAccess( dev, blockDevice_fdPtr, canWritePtr ); +- ++ + if (preen == 0 && !guiControl) + printf("** %s", dev); + if (nflag || (fswritefd = open(dev, O_WRONLY)) < 0) { +@@ -433,10 +457,14 @@ setup( char *dev, int *blockDevice_fdPtr, int *canWritePtr ) + printf("\n"); + + /* Get device block size to initialize cache */ ++#if LINUX ++ devBlockSize = 512; ++#else + if (ioctl(fsreadfd, DKIOCGETBLOCKSIZE, &devBlockSize) < 0) { + pfatal ("Can't get device block size\n"); + return (0); + } ++#endif + + /* calculate the cache block size and total blocks */ + if (CalculateCacheSize(userCacheSize, &cacheBlockSize, &cacheTotalBlocks, debug) != 0) { +@@ -463,11 +491,15 @@ setup( char *dev, int *blockDevice_fdPtr, int *canWritePtr ) + + static void getWriteAccess( char *dev, int *blockDevice_fdPtr, int *canWritePtr ) + { ++#if !LINUX + int i; + int myMountsCount; ++#endif + void * myPtr; + char * myCharPtr; ++#if !LINUX + struct statfs * myBufPtr; ++#endif + void * myNamePtr; + + myPtr = NULL; +@@ -490,6 +522,9 @@ static void getWriteAccess( char *dev, int *blockDevice_fdPtr, int *canWritePtr + } + + // get count of mounts then get the info for each ++#if LINUX ++ // FIXME ++#else + myMountsCount = getfsstat( NULL, 0, MNT_NOWAIT ); + if ( myMountsCount < 0 ) + goto ExitThisRoutine; +@@ -513,8 +548,8 @@ static void getWriteAccess( char *dev, int *blockDevice_fdPtr, int *canWritePtr + } + myBufPtr++; + } +- *canWritePtr = 1; // single user will get us here, f_mntfromname is not /dev/diskXXXX +- ++#endif ++ *canWritePtr = 1; // single user will get us here, f_mntfromname is not /dev/diskXXXX + ExitThisRoutine: + if ( myPtr != NULL ) + free( myPtr ); +diff --git a/fsck_hfs.tproj/utilities.c b/fsck_hfs.tproj/utilities.c +index ee41bef..8e1cd77 100644 +--- a/fsck_hfs.tproj/utilities.c ++++ b/fsck_hfs.tproj/utilities.c +@@ -183,12 +183,14 @@ retry: + printf("Can't stat %s\n", raw); + return (origname); + } ++#if !LINUX + if ((stchar.st_mode & S_IFMT) == S_IFCHR) { + return (raw); + } else { + printf("%s is not a character device\n", raw); + return (origname); + } ++#endif + } else if ((stblock.st_mode & S_IFMT) == S_IFCHR && !retried) { + newname = unrawname(newname); + retried++; +@@ -214,7 +216,11 @@ rawname(char *name) + *dp = 0; + (void)strcpy(rawbuf, name); + *dp = '/'; +- (void)strcat(rawbuf, "/r"); ++#if LINUX ++ (void)strcat(rawbuf, "/"); ++#else ++ (void)strcat(rawbuf,"/r"); ++#endif + (void)strcat(rawbuf, &dp[1]); + + return (rawbuf); +diff --git a/include/missing.h b/include/missing.h +new file mode 100644 +index 0000000..0a859c4 +--- /dev/null ++++ b/include/missing.h +@@ -0,0 +1,114 @@ ++#ifndef _MISSING_H_ ++#define _MISSING_H_ ++ ++#include ++#include ++#include ++#include ++#include ++ ++#define MAXBSIZE (256 * 4096) ++ ++#ifndef true ++#define true 1 ++#endif ++#ifndef false ++#define false 0 ++#endif ++ ++/* Mac types */ ++ ++/* 8 Bit */ ++#ifndef UInt8 ++#define UInt8 uint8_t ++#endif ++#ifndef u_int8_t ++#define u_int8_t UInt8 ++#endif ++#ifndef SInt8 ++#define SInt8 int8_t ++#endif ++ ++/* 16 Bit */ ++#ifndef UInt16 ++#define UInt16 uint16_t ++#endif ++#ifndef u_int16_t ++#define u_int16_t UInt16 ++#endif ++#ifndef SInt16 ++#define SInt16 int16_t ++#endif ++ ++/* 32 Bit */ ++#ifndef UInt32 ++#define UInt32 uint32_t ++#endif ++#ifndef u_int32_t ++#define u_int32_t UInt32 ++#endif ++#ifndef SInt32 ++#define SInt32 int32_t ++#endif ++ ++/* 64 Bit */ ++#ifndef UInt64 ++#define UInt64 uint64_t ++#endif ++#ifndef u_int64_t ++#define u_int64_t UInt64 ++#endif ++#ifndef SInt64 ++#define SInt64 int64_t ++#endif ++ ++#define UniChar u_int16_t ++#define Boolean u_int8_t ++ ++#define UF_NODUMP 0x00000001 ++ ++/* syslimits.h */ ++#define NAME_MAX 255 ++ ++/* Byteswap stuff */ ++#define NXSwapHostLongToBig(x) cpu_to_be64(x) ++#define NXSwapBigShortToHost(x) be16_to_cpu(x) ++#define OSSwapBigToHostInt16(x) be16_to_cpu(x) ++#define NXSwapBigLongToHost(x) be32_to_cpu(x) ++#define OSSwapBigToHostInt32(x) be32_to_cpu(x) ++#define NXSwapBigLongLongToHost(x) be64_to_cpu(x) ++#define OSSwapBigToHostInt64(x) be64_to_cpu(x) ++ ++#if __BYTE_ORDER == __LITTLE_ENDIAN ++/* Big Endian Swaps */ ++#ifndef be16_to_cpu ++#define be16_to_cpu(x) bswap_16(x) ++#endif ++#ifndef be32_to_cpu ++#define be32_to_cpu(x) bswap_32(x) ++#endif ++#ifndef be64_to_cpu ++#define be64_to_cpu(x) bswap_64(x) ++#endif ++#ifndef cpu_to_be64 ++#define cpu_to_be64(x) bswap_64(x) ++#endif ++#elif __BYTE_ORDER == __BIG_ENDIAN ++/* Big endian doesn't swap */ ++#ifndef be16_to_cpu ++#define be16_to_cpu(x) (x) ++#endif ++#ifndef be32_to_cpu ++#define be32_to_cpu(x) (x) ++#endif ++#ifndef be64_to_cpu ++#define be64_to_cpu(x) (x) ++#endif ++#ifndef cpu_to_be64 ++#define cpu_to_be64(x) (x) ++#endif ++#endif ++ ++#define KAUTH_FILESEC_XATTR "com.apple.system.Security" ++ ++#endif +diff --git a/newfs_hfs.tproj/hfs_endian.c b/newfs_hfs.tproj/hfs_endian.c +index 117b7f8..fdf7353 100644 +--- a/newfs_hfs.tproj/hfs_endian.c ++++ b/newfs_hfs.tproj/hfs_endian.c +@@ -30,7 +30,12 @@ + #include + #include + ++#if LINUX ++#include "missing.h" ++#else + #include ++#endif ++ + #include + + #include "hfs_endian.h" +diff --git a/newfs_hfs.tproj/hfs_endian.h b/newfs_hfs.tproj/hfs_endian.h +index 8d9d01d..5c7ff57 100644 +--- a/newfs_hfs.tproj/hfs_endian.h ++++ b/newfs_hfs.tproj/hfs_endian.h +@@ -29,7 +29,12 @@ + * volume format. + */ + #include ++#if LINUX ++#include ++#include ++#else + #include ++#endif + + /*********************/ + /* BIG ENDIAN Macros */ +diff --git a/newfs_hfs.tproj/makehfs.c b/newfs_hfs.tproj/makehfs.c +index 085222f..7609779 100644 +--- a/newfs_hfs.tproj/makehfs.c ++++ b/newfs_hfs.tproj/makehfs.c +@@ -31,10 +31,16 @@ + #include + #include + #include ++#if LINUX ++#include ++#include "missing.h" ++#endif + #include + #include + #include ++#if !LINUX + #include ++#endif + + #include + #include +@@ -47,13 +53,14 @@ + + #include + ++#if !LINUX + #include + + #include + #include + + extern Boolean _CFStringGetFileSystemRepresentation(CFStringRef string, UInt8 *buffer, CFIndex maxBufLen); +- ++#endif + + #include + #include +@@ -129,7 +136,9 @@ static UInt32 Largest __P((UInt32 a, UInt32 b, UInt32 c, UInt32 d )); + static void MarkBitInAllocationBuffer __P((HFSPlusVolumeHeader *header, + UInt32 allocationBlock, void* sectorBuffer, UInt32 *sector)); + ++#if !LINUX + static UInt32 GetDefaultEncoding(); ++#endif + + static UInt32 UTCToLocal __P((UInt32 utcTime)); + +@@ -158,11 +167,14 @@ void SETOFFSET (void *buffer, UInt16 btNodeSize, SInt16 recOffset, SInt16 vecOff + + #define ROUNDUP(x, u) (((x) % (u) == 0) ? (x) : ((x)/(u) + 1) * (u)) + +-#define ENCODING_TO_BIT(e) \ ++#if LINUX ++#define ENCODING_TO_BIT(e) (e) ++#else ++#define ENCODING_TO_BIT(e) + ((e) < 48 ? (e) : \ + ((e) == kCFStringEncodingMacUkrainian ? 48 : \ + ((e) == kCFStringEncodingMacFarsi ? 49 : 0))) +- ++#endif + /* + * make_hfs + * +@@ -528,6 +540,7 @@ InitMDB(hfsparams_t *defaults, UInt32 driveBlocks, HFS_MDB *mdbp) + * Map UTF-8 input into a Mac encoding. + * On conversion errors "untitled" is used as a fallback. + */ ++#if !LINUX + { + UniChar unibuf[kHFSMaxVolumeNameChars]; + CFStringRef cfstr; +@@ -553,7 +566,11 @@ InitMDB(hfsparams_t *defaults, UInt32 driveBlocks, HFS_MDB *mdbp) + bcopy(&mdbp->drVN[1], defaults->volumeName, mdbp->drVN[0]); + defaults->volumeName[mdbp->drVN[0]] = '\0'; + } ++#endif + /* Save the encoding hint in the Finder Info (field 4). */ ++ mdbp->drVN[0] = strlen(defaults->volumeName); ++ bcopy(defaults->volumeName,&mdbp->drVN[1],mdbp->drVN[0]); ++ + mdbp->drFndrInfo[4] = SET_HFS_TEXT_ENCODING(defaults->encodingHint); + + mdbp->drWrCnt = kWriteSeqNum; +@@ -1100,9 +1117,11 @@ InitCatalogRoot_HFSPlus(const hfsparams_t *dp, const HFSPlusVolumeHeader *header + UInt16 nodeSize; + SInt16 offset; + UInt32 unicodeBytes; ++#if !LINUX + UInt8 canonicalName[256]; + CFStringRef cfstr; + Boolean cfOK; ++#endif + int index = 0; + + nodeSize = dp->catalogNodeSize; +@@ -1122,7 +1141,9 @@ InitCatalogRoot_HFSPlus(const hfsparams_t *dp, const HFSPlusVolumeHeader *header + * First record is always the root directory... + */ + ckp = (HFSPlusCatalogKey *)((UInt8 *)buffer + offset); +- ++#if LINUX ++ ConvertUTF8toUnicode(dp->volumeName, sizeof(ckp->nodeName.unicode), ckp->nodeName.unicode, &ckp->nodeName.length); ++#else + /* Use CFString functions to get a HFSPlus Canonical name */ + cfstr = CFStringCreateWithCString(kCFAllocatorDefault, (char *)dp->volumeName, kCFStringEncodingUTF8); + cfOK = _CFStringGetFileSystemRepresentation(cfstr, canonicalName, sizeof(canonicalName)); +@@ -1139,6 +1160,7 @@ InitCatalogRoot_HFSPlus(const hfsparams_t *dp, const HFSPlusVolumeHeader *header + dp->volumeName, kDefaultVolumeNameStr); + } + CFRelease(cfstr); ++#endif + ckp->nodeName.length = SWAP_BE16 (ckp->nodeName.length); + + unicodeBytes = sizeof(UniChar) * SWAP_BE16 (ckp->nodeName.length); +@@ -1821,15 +1843,15 @@ WriteBuffer(const DriveInfo *driveInfo, UInt64 startingSector, UInt32 byteCount, + off_t sector; + + if ((byteCount % driveInfo->sectorSize) != 0) +- errx(1, "WriteBuffer: byte count %ld is not sector size multiple", byteCount); ++ errx(1, "WriteBuffer: byte count %i is not sector size multiple", byteCount); + + sector = driveInfo->sectorOffset + startingSector; + + if (lseek(driveInfo->fd, sector * driveInfo->sectorSize, SEEK_SET) < 0) +- err(1, "seek (sector %qd)", sector); ++ err(1, "seek (sector %lld)", sector); + + if (write(driveInfo->fd, buffer, byteCount) != byteCount) +- err(1, "write (sector %qd, %ld bytes)", sector, byteCount); ++ err(1, "write (sector %lld, %i bytes)", sector, byteCount); + } + + +@@ -1913,7 +1935,7 @@ DivideAndRoundUp(UInt32 numerator, UInt32 denominator) + return quotient; + } + +- ++#if !LINUX + #define __kCFUserEncodingFileName ("/.CFUserTextEncoding") + + static UInt32 +@@ -1939,7 +1961,7 @@ GetDefaultEncoding() + } + return 0; + } +- ++#endif + + static int + ConvertUTF8toUnicode(const UInt8* source, UInt32 bufsize, UniChar* unibuf, +@@ -2006,6 +2028,9 @@ ConvertUTF8toUnicode(const UInt8* source, UInt32 bufsize, UniChar* unibuf, + static int + getencodinghint(unsigned char *name) + { ++#if LINUX ++ return(0); ++#else + int mib[3]; + size_t buflen = sizeof(int); + struct vfsconf vfc; +@@ -2023,7 +2048,8 @@ getencodinghint(unsigned char *name) + return (hint); + error: + hint = GetDefaultEncoding(); +- return (hint); ++ return (0); ++#endif + } + + +@@ -2034,12 +2060,14 @@ void GenerateVolumeUUID(VolumeUUID *newVolumeID) { + unsigned char digest[20]; + time_t now; + clock_t uptime; +- int mib[2]; +- int sysdata; +- char sysctlstring[128]; + size_t datalen; + double sysloadavg[3]; ++#if !LINUX ++ int sysdata; ++ int mib[2]; ++ char sysctlstring[128]; + struct vmtotal sysvmtotal; ++#endif + + do { + /* Initialize the SHA-1 context for processing: */ +@@ -2052,52 +2080,58 @@ void GenerateVolumeUUID(VolumeUUID *newVolumeID) { + SHA1_Update(&context, &uptime, sizeof(uptime)); + + /* The kernel's boot time: */ ++#if !LINUX + mib[0] = CTL_KERN; + mib[1] = KERN_BOOTTIME; + datalen = sizeof(sysdata); + sysctl(mib, 2, &sysdata, &datalen, NULL, 0); + SHA1_Update(&context, &sysdata, datalen); +- ++#endif + /* The system's host id: */ ++#if !LINUX + mib[0] = CTL_KERN; + mib[1] = KERN_HOSTID; + datalen = sizeof(sysdata); + sysctl(mib, 2, &sysdata, &datalen, NULL, 0); + SHA1_Update(&context, &sysdata, datalen); +- ++#endif + /* The system's host name: */ ++#if !LINUX + mib[0] = CTL_KERN; + mib[1] = KERN_HOSTNAME; + datalen = sizeof(sysctlstring); + sysctl(mib, 2, sysctlstring, &datalen, NULL, 0); + SHA1_Update(&context, sysctlstring, datalen); +- ++#endif + /* The running kernel's OS release string: */ ++#if !LINUX + mib[0] = CTL_KERN; + mib[1] = KERN_OSRELEASE; + datalen = sizeof(sysctlstring); + sysctl(mib, 2, sysctlstring, &datalen, NULL, 0); + SHA1_Update(&context, sysctlstring, datalen); +- ++#endif + /* The running kernel's version string: */ ++#if !LINUX + mib[0] = CTL_KERN; + mib[1] = KERN_VERSION; + datalen = sizeof(sysctlstring); + sysctl(mib, 2, sysctlstring, &datalen, NULL, 0); + SHA1_Update(&context, sysctlstring, datalen); +- ++#endif + /* The system's load average: */ + datalen = sizeof(sysloadavg); + getloadavg(sysloadavg, 3); + SHA1_Update(&context, &sysloadavg, datalen); + + /* The system's VM statistics: */ ++#if !LINUX + mib[0] = CTL_VM; + mib[1] = VM_METER; + datalen = sizeof(sysvmtotal); + sysctl(mib, 2, &sysvmtotal, &datalen, NULL, 0); + SHA1_Update(&context, &sysvmtotal, datalen); +- ++#endif + /* The current GMT (26 ASCII characters): */ + time(&now); + strncpy(randomInputBuffer, asctime(gmtime(&now)), 26); /* "Mon Mar 27 13:46:26 2000" */ +diff --git a/newfs_hfs.tproj/newfs_hfs.c b/newfs_hfs.tproj/newfs_hfs.c +index c4176a9..bf2ed21 100644 +--- a/newfs_hfs.tproj/newfs_hfs.c ++++ b/newfs_hfs.tproj/newfs_hfs.c +@@ -38,8 +38,13 @@ + #include + #include + #include ++#if LINUX ++#include ++#endif + ++#if !LINUX + #include ++#endif + + #include + #include "newfs_hfs.h" +@@ -73,7 +78,9 @@ static void usage __P((void)); + + char *progname; + char gVolumeName[kHFSPlusMaxFileNameChars + 1] = {kDefaultVolumeNameStr}; ++#if !LINUX + char rawdevice[MAXPATHLEN]; ++#endif + char blkdevice[MAXPATHLEN]; + UInt32 gBlockSize = 0; + UInt32 gNextCNID = kHFSFirstUserCatalogNodeID; +@@ -158,8 +165,10 @@ main(argc, argv) + extern int optind; + int ch; + int forceHFS; ++#if !LINUX + char *cp, *special; + struct statfs *mp; ++#endif + int n; + + if ((progname = strrchr(*argv, '/'))) +@@ -260,16 +269,19 @@ main(argc, argv) + usage(); + } + +- argc -= optind; +- argv += optind; ++ argc -= optind; ++ argv += optind; + +- if (gPartitionSize != 0) { +- if (argc != 0) +- usage(); +- } else { +- if (argc != 1) +- usage(); ++ if (gPartitionSize != 0) { ++ if (argc != 0) ++ usage(); ++ } else { ++ if (argc != 1) ++ usage(); + ++#if LINUX ++ (void) sprintf(blkdevice, "%s", argv[0]); ++#else + special = argv[0]; + cp = strrchr(special, '/'); + if (cp != 0) +@@ -278,6 +290,7 @@ main(argc, argv) + special++; + (void) sprintf(rawdevice, "%sr%s", _PATH_DEV, special); + (void) sprintf(blkdevice, "%s%s", _PATH_DEV, special); ++#endif + } + + if (forceHFS && gJournaled) { +@@ -301,6 +314,9 @@ main(argc, argv) + /* + * Check if target device is aready mounted + */ ++#if LINUX ++ // FIXME ++#else + n = getmntinfo(&mp, MNT_NOWAIT); + if (n == 0) + fatal("%s: getmntinfo: %s", blkdevice, strerror(errno)); +@@ -310,15 +326,20 @@ main(argc, argv) + fatal("%s is mounted on %s", blkdevice, mp->f_mntonname); + ++mp; + } ++#endif + } + +- if (hfs_newfs(rawdevice, forceHFS, true) < 0) { ++ if (hfs_newfs(blkdevice, forceHFS, true) < 0) { ++#if LINUX ++ err(1, NULL); ++#else + /* On ENXIO error use the block device (to get de-blocking) */ + if (errno == ENXIO) { + if (hfs_newfs(blkdevice, forceHFS, false) < 0) + err(1, NULL); + } else + err(1, NULL); ++#endif + } + + exit(0); +@@ -506,7 +527,9 @@ hfs_newfs(char *device, int forceHFS, int isRaw) + int fso = 0; + int retval = 0; + hfsparams_t defaults = {0}; ++#if !LINUX + u_int64_t maxSectorsPerIO; ++#endif + + if (gPartitionSize) { + dip.sectorSize = kBytesPerSector; +@@ -526,6 +549,34 @@ hfs_newfs(char *device, int forceHFS, int isRaw) + + if (fstat( fso, &stbuf) < 0) + fatal("%s: %s", device, strerror(errno)); ++#if LINUX ++ dip.sectorSize = 512; ++ dip.sectorsPerIO = 256; ++ ++# ifndef BLKGETSIZE ++# define BLKGETSIZE _IO(0x12,96) ++# endif ++ ++# ifndef BLKGETSIZE64 ++# define BLKGETSIZE64 _IOR(0x12,114,size_t) ++# endif ++ ++ if (S_ISREG(stbuf.st_mode)) { ++ dip.totalSectors = stbuf.st_size / 512; ++ } ++ else if (S_ISBLK(stbuf.st_mode)) { ++ unsigned long size; ++ u_int64_t size64; ++ if (!ioctl(fso, BLKGETSIZE64, &size64)) ++ dip.totalSectors = size64 / 512; ++ else if (!ioctl(fso, BLKGETSIZE, &size)) ++ dip.totalSectors = size; ++ else ++ fatal("%s: %s", device, strerror(errno)); ++ } ++ else ++ fatal("%s: is not a block device", device); ++#else + + if (ioctl(fso, DKIOCGETBLOCKCOUNT, &dip.totalSectors) < 0) + fatal("%s: %s", device, strerror(errno)); +@@ -537,11 +588,14 @@ hfs_newfs(char *device, int forceHFS, int isRaw) + dip.sectorsPerIO = (128 * 1024) / dip.sectorSize; /* use 128K as default */ + else + dip.sectorsPerIO = MIN(maxSectorsPerIO, (1024 * 1024) / dip.sectorSize); ++#endif ++ + /* + * The make_hfs code currentlydoes 512 byte sized I/O. + * If the sector size is bigger than 512, start over + * using the block device (to get de-blocking). + */ ++#if !LINUX + if (dip.sectorSize != kBytesPerSector) { + if (isRaw) { + close(fso); +@@ -556,7 +610,9 @@ hfs_newfs(char *device, int forceHFS, int isRaw) + dip.sectorSize = kBytesPerSector; + } + } ++#endif + } ++ + dip.sectorOffset = 0; + time(&createtime); + +diff --git a/newfs_hfs.tproj/newfs_hfs.h b/newfs_hfs.tproj/newfs_hfs.h +index 968ff10..5680a34 100644 +--- a/newfs_hfs.tproj/newfs_hfs.h ++++ b/newfs_hfs.tproj/newfs_hfs.h +@@ -19,8 +19,12 @@ + * + * @APPLE_LICENSE_HEADER_END@ + */ +- ++ ++#if LINUX ++#include "missing.h" ++#else + #include ++#endif + + /* + * Mac OS Finder flags +@@ -122,33 +126,33 @@ enum { + #define kDTDF_FileID 16 + #define kDTDF_Name "Desktop DF" + #define kDTDF_Chars 10 +-#define kDTDF_Type 'DTFL' +-#define kDTDF_Creator 'DMGR' ++#define kDTDF_Type 0x4454464C /* 'DTFL' */ ++#define kDTDF_Creator 0x444D4752 /* 'DMGR' */ + + #define kDTDB_FileID 17 + #define kDTDB_Name "Desktop DB" + #define kDTDB_Chars 10 +-#define kDTDB_Type 'BTFL' +-#define kDTDB_Creator 'DMGR' ++#define kDTDB_Type 0x4254464C /* 'BTFL' */ ++#define kDTDB_Creator 0x444D4752 /* 'DMGR' */ + #define kDTDB_Size 1024 + + #define kReadMe_FileID 18 + #define kReadMe_Name "ReadMe" + #define kReadMe_Chars 6 +-#define kReadMe_Type 'ttro' +-#define kReadMe_Creator 'ttxt' ++#define kReadMe_Type 0x7474726F /* 'ttro' */ ++#define kReadMe_Creator 0x74747974 /* 'ttxt' */ + + #define kFinder_FileID 19 + #define kFinder_Name "Finder" + #define kFinder_Chars 6 +-#define kFinder_Type 'FNDR' +-#define kFinder_Creator 'MACS' ++#define kFinder_Type 0x464E4452 /* 'FNDR' */ ++#define kFinder_Creator 0x4D414353 /* 'MACS' */ + + #define kSystem_FileID 20 + #define kSystem_Name "System" + #define kSystem_Chars 6 +-#define kSystem_Type 'zsys' +-#define kSystem_Creator 'MACS' ++#define kSystem_Type 0x7A737973 /* 'zsys' */ ++#define kSystem_Creator 0x4D414353 /* 'MACS' */ + + + diff --git a/utils/hfsprogs/patches/0003-Add-helper-include-files-absent-from-the-upstream-pa.patch b/utils/hfsprogs/patches/0003-Add-helper-include-files-absent-from-the-upstream-pa.patch new file mode 100644 index 000000000..003f8440b --- /dev/null +++ b/utils/hfsprogs/patches/0003-Add-helper-include-files-absent-from-the-upstream-pa.patch @@ -0,0 +1,1024 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Add helper include files absent from the upstream package + +Add some include files from an Apple system that contain the definition of +the data structures used by the programs that manipulate the filesystems. +--- + include/bitstring.h | 164 +++++++++++ + include/hfs/hfs_format.h | 689 +++++++++++++++++++++++++++++++++++++++++++++ + include/hfs/hfs_mount.h | 78 +++++ + include/sys/appleapiopts.h | 52 ++++ + 4 files changed, 983 insertions(+) + create mode 100644 include/bitstring.h + create mode 100644 include/hfs/hfs_format.h + create mode 100644 include/hfs/hfs_mount.h + create mode 100644 include/sys/appleapiopts.h + +diff --git a/include/bitstring.h b/include/bitstring.h +new file mode 100644 +index 0000000..fbecfbe +--- /dev/null ++++ b/include/bitstring.h +@@ -0,0 +1,164 @@ ++/* ++ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved. ++ * ++ * @APPLE_LICENSE_HEADER_START@ ++ * ++ * The contents of this file constitute Original Code as defined in and ++ * are subject to the Apple Public Source License Version 1.1 (the ++ * "License"). You may not use this file except in compliance with the ++ * License. Please obtain a copy of the License at ++ * http://www.apple.com/publicsource and read it before using this file. ++ * ++ * This Original Code and all software distributed under the License are ++ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER ++ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, ++ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the ++ * License for the specific language governing rights and limitations ++ * under the License. ++ * ++ * @APPLE_LICENSE_HEADER_END@ ++ */ ++/* ++ * Copyright (c) 1989, 1993 ++ * The Regents of the University of California. All rights reserved. ++ * ++ * This code is derived from software contributed to Berkeley by ++ * Paul Vixie. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * 1. Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * 2. Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * 3. All advertising materials mentioning features or use of this software ++ * must display the following acknowledgement: ++ * This product includes software developed by the University of ++ * California, Berkeley and its contributors. ++ * 4. Neither the name of the University nor the names of its contributors ++ * may be used to endorse or promote products derived from this software ++ * without specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ++ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ++ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ++ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ++ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ++ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ++ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ++ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ++ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ++ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++ * SUCH DAMAGE. ++ * ++ * @(#)bitstring.h 8.1 (Berkeley) 7/19/93 ++ */ ++ ++#ifndef _BITSTRING_H_ ++#define _BITSTRING_H_ ++ ++typedef unsigned char bitstr_t; ++ ++/* internal macros */ ++ /* byte of the bitstring bit is in */ ++#define _bit_byte(bit) \ ++ ((bit) >> 3) ++ ++ /* mask for the bit within its byte */ ++#define _bit_mask(bit) \ ++ (1 << ((bit)&0x7)) ++ ++/* external macros */ ++ /* bytes in a bitstring of nbits bits */ ++#define bitstr_size(nbits) \ ++ ((((nbits) - 1) >> 3) + 1) ++ ++ /* allocate a bitstring */ ++#define bit_alloc(nbits) \ ++ (bitstr_t *)calloc(1, \ ++ (unsigned int)bitstr_size(nbits) * sizeof(bitstr_t)) ++ ++ /* allocate a bitstring on the stack */ ++#define bit_decl(name, nbits) \ ++ (name)[bitstr_size(nbits)] ++ ++ /* is bit N of bitstring name set? */ ++#define bit_test(name, bit) \ ++ ((name)[_bit_byte(bit)] & _bit_mask(bit)) ++ ++ /* set bit N of bitstring name */ ++#define bit_set(name, bit) \ ++ (name)[_bit_byte(bit)] |= _bit_mask(bit) ++ ++ /* clear bit N of bitstring name */ ++#define bit_clear(name, bit) \ ++ (name)[_bit_byte(bit)] &= ~_bit_mask(bit) ++ ++ /* clear bits start ... stop in bitstring */ ++#define bit_nclear(name, start, stop) { \ ++ register bitstr_t *_name = name; \ ++ register int _start = start, _stop = stop; \ ++ register int _startbyte = _bit_byte(_start); \ ++ register int _stopbyte = _bit_byte(_stop); \ ++ if (_startbyte == _stopbyte) { \ ++ _name[_startbyte] &= ((0xff >> (8 - (_start&0x7))) | \ ++ (0xff << ((_stop&0x7) + 1))); \ ++ } else { \ ++ _name[_startbyte] &= 0xff >> (8 - (_start&0x7)); \ ++ while (++_startbyte < _stopbyte) \ ++ _name[_startbyte] = 0; \ ++ _name[_stopbyte] &= 0xff << ((_stop&0x7) + 1); \ ++ } \ ++} ++ ++ /* set bits start ... stop in bitstring */ ++#define bit_nset(name, start, stop) { \ ++ register bitstr_t *_name = name; \ ++ register int _start = start, _stop = stop; \ ++ register int _startbyte = _bit_byte(_start); \ ++ register int _stopbyte = _bit_byte(_stop); \ ++ if (_startbyte == _stopbyte) { \ ++ _name[_startbyte] |= ((0xff << (_start&0x7)) & \ ++ (0xff >> (7 - (_stop&0x7)))); \ ++ } else { \ ++ _name[_startbyte] |= 0xff << ((_start)&0x7); \ ++ while (++_startbyte < _stopbyte) \ ++ _name[_startbyte] = 0xff; \ ++ _name[_stopbyte] |= 0xff >> (7 - (_stop&0x7)); \ ++ } \ ++} ++ ++ /* find first bit clear in name */ ++#define bit_ffc(name, nbits, value) { \ ++ register bitstr_t *_name = name; \ ++ register int _byte, _nbits = nbits; \ ++ register int _stopbyte = _bit_byte(_nbits), _value = -1; \ ++ for (_byte = 0; _byte <= _stopbyte; ++_byte) \ ++ if (_name[_byte] != 0xff) { \ ++ _value = _byte << 3; \ ++ for (_stopbyte = _name[_byte]; (_stopbyte&0x1); \ ++ ++_value, _stopbyte >>= 1); \ ++ break; \ ++ } \ ++ *(value) = _value; \ ++} ++ ++ /* find first bit set in name */ ++#define bit_ffs(name, nbits, value) { \ ++ register bitstr_t *_name = name; \ ++ register int _byte, _nbits = nbits; \ ++ register int _stopbyte = _bit_byte(_nbits), _value = -1; \ ++ for (_byte = 0; _byte <= _stopbyte; ++_byte) \ ++ if (_name[_byte]) { \ ++ _value = _byte << 3; \ ++ for (_stopbyte = _name[_byte]; !(_stopbyte&0x1); \ ++ ++_value, _stopbyte >>= 1); \ ++ break; \ ++ } \ ++ *(value) = _value; \ ++} ++ ++#endif /* !_BITSTRING_H_ */ +diff --git a/include/hfs/hfs_format.h b/include/hfs/hfs_format.h +new file mode 100644 +index 0000000..d820329 +--- /dev/null ++++ b/include/hfs/hfs_format.h +@@ -0,0 +1,689 @@ ++/* ++ * Copyright (c) 2000-2004 Apple Computer, Inc. All rights reserved. ++ * ++ * @APPLE_LICENSE_HEADER_START@ ++ * ++ * The contents of this file constitute Original Code as defined in and ++ * are subject to the Apple Public Source License Version 1.1 (the ++ * "License"). You may not use this file except in compliance with the ++ * License. Please obtain a copy of the License at ++ * http://www.apple.com/publicsource and read it before using this file. ++ * ++ * This Original Code and all software distributed under the License are ++ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER ++ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, ++ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the ++ * License for the specific language governing rights and limitations ++ * under the License. ++ * ++ * @APPLE_LICENSE_HEADER_END@ ++ */ ++#ifndef __HFS_FORMAT__ ++#define __HFS_FORMAT__ ++ ++#include "missing.h" ++ ++#include ++ ++/* ++ * hfs_format.c ++ * ++ * This file describes the on-disk format for HFS and HFS Plus volumes. ++ * The HFS Plus volume format is desciibed in detail in Apple Technote 1150. ++ * ++ * http://developer.apple.com/technotes/tn/tn1150.html ++ * ++ */ ++ ++#ifdef __cplusplus ++extern "C" { ++#endif ++ ++/* some on-disk hfs structures have 68K alignment (misaligned) */ ++ ++#define PACKED_S __attribute__((packed)) ++ ++/* Signatures used to differentiate between HFS and HFS Plus volumes */ ++enum { ++ kHFSSigWord = 0x4244, /* 'BD' in ASCII */ ++ kHFSPlusSigWord = 0x482B, /* 'H+' in ASCII */ ++ kHFSXSigWord = 0x4858, /* 'HX' in ASCII */ ++ ++ kHFSPlusVersion = 0x0004, /* 'H+' volumes are version 4 only */ ++ kHFSXVersion = 0x0005, /* 'HX' volumes start with version 5 */ ++ ++ kHFSPlusMountVersion = 0x31302E30, /* '10.0' for Mac OS X */ ++ kHFSJMountVersion = 0x4846534a, /* 'HFSJ' for journaled HFS+ on OS X */ ++ kFSKMountVersion = 0x46534b21 /* 'FSK!' for failed journal replay */ ++}PACKED_S; ++ ++ ++#if 1 ++/* ++ * Mac OS X has a special directory for linked and unlinked files (HFS Plus only). ++ * This directory and its contents are never exported from the filesystem under ++ * Mac OS X. ++ * ++ * To make this folder name sort last, it has embedded null prefix. ++ * (0xC0, 0x80 in UTF-8) ++ */ ++#define HFSPLUSMETADATAFOLDER "\xC0\x80\xC0\x80\xC0\x80\xC0\x80HFS+ Private Data" ++ ++/* ++ * Files in the HFS Private Data folder have one of the following prefixes ++ * followed by a decimal number (no leading zeros). For indirect nodes this ++ * number is a 32 bit random number. For unlinked (deleted) files that are ++ * still open, the number is the file ID for that file. ++ * ++ * e.g. iNode7182000 and temp3296 ++ */ ++#define HFS_INODE_PREFIX "iNode" ++#define HFS_DELETE_PREFIX "temp" ++ ++#endif /* __APPLE_API_PRIVATE */ ++ ++/* ++ * Indirect link files (hard links) have the following type/creator. ++ */ ++enum { ++ kHardLinkFileType = 0x686C6E6B, /* 'hlnk' */ ++ kHFSPlusCreator = 0x6866732B /* 'hfs+' */ ++}PACKED_S; ++ ++ ++#ifndef _HFSUNISTR255_DEFINED_ ++#define _HFSUNISTR255_DEFINED_ ++/* Unicode strings are used for HFS Plus file and folder names */ ++struct HFSUniStr255 { ++ u_int16_t length; /* number of unicode characters */ ++ u_int16_t unicode[255]; /* unicode characters */ ++} PACKED_S; ++typedef struct HFSUniStr255 HFSUniStr255; ++typedef const HFSUniStr255 *ConstHFSUniStr255Param; ++#endif /* _HFSUNISTR255_DEFINED_ */ ++ ++enum { ++ kHFSMaxVolumeNameChars = 27, ++ kHFSMaxFileNameChars = 31, ++ kHFSPlusMaxFileNameChars = 255 ++}PACKED_S; ++ ++ ++/* Extent overflow file data structures */ ++ ++/* HFS Extent key */ ++struct HFSExtentKey { ++ u_int8_t keyLength; /* length of key, excluding this field */ ++ u_int8_t forkType; /* 0 = data fork, FF = resource fork */ ++ u_int32_t fileID; /* file ID */ ++ u_int16_t startBlock; /* first file allocation block number in this extent */ ++}PACKED_S; ++typedef struct HFSExtentKey HFSExtentKey; ++ ++/* HFS Plus Extent key */ ++struct HFSPlusExtentKey { ++ u_int16_t keyLength; /* length of key, excluding this field */ ++ u_int8_t forkType; /* 0 = data fork, FF = resource fork */ ++ u_int8_t pad; /* make the other fields align on 32-bit boundary */ ++ u_int32_t fileID; /* file ID */ ++ u_int32_t startBlock; /* first file allocation block number in this extent */ ++}PACKED_S; ++typedef struct HFSPlusExtentKey HFSPlusExtentKey; ++ ++/* Number of extent descriptors per extent record */ ++enum { ++ kHFSExtentDensity = 3, ++ kHFSPlusExtentDensity = 8 ++}PACKED_S; ++ ++/* HFS extent descriptor */ ++struct HFSExtentDescriptor { ++ u_int16_t startBlock; /* first allocation block */ ++ u_int16_t blockCount; /* number of allocation blocks */ ++}PACKED_S; ++typedef struct HFSExtentDescriptor HFSExtentDescriptor; ++ ++/* HFS Plus extent descriptor */ ++struct HFSPlusExtentDescriptor { ++ u_int32_t startBlock; /* first allocation block */ ++ u_int32_t blockCount; /* number of allocation blocks */ ++}PACKED_S; ++typedef struct HFSPlusExtentDescriptor HFSPlusExtentDescriptor; ++ ++/* HFS extent record */ ++typedef HFSExtentDescriptor HFSExtentRecord[3]; ++ ++/* HFS Plus extent record */ ++typedef HFSPlusExtentDescriptor HFSPlusExtentRecord[8]; ++ ++ ++/* Finder information */ ++struct FndrFileInfo { ++ u_int32_t fdType; /* file type */ ++ u_int32_t fdCreator; /* file creator */ ++ u_int16_t fdFlags; /* Finder flags */ ++ struct { ++ int16_t v; /* file's location */ ++ int16_t h; ++ } PACKED_S fdLocation; ++ int16_t opaque; ++}PACKED_S; ++typedef struct FndrFileInfo FndrFileInfo; ++ ++struct FndrDirInfo { ++ struct { /* folder's window rectangle */ ++ int16_t top; ++ int16_t left; ++ int16_t bottom; ++ int16_t right; ++ }PACKED_S frRect; ++ unsigned short frFlags; /* Finder flags */ ++ struct { ++ u_int16_t v; /* folder's location */ ++ u_int16_t h; ++ }PACKED_S frLocation; ++ int16_t opaque; ++}PACKED_S; ++typedef struct FndrDirInfo FndrDirInfo; ++ ++struct FndrOpaqueInfo { ++ int8_t opaque[16]; ++}PACKED_S; ++typedef struct FndrOpaqueInfo FndrOpaqueInfo; ++ ++ ++/* HFS Plus Fork data info - 80 bytes */ ++struct HFSPlusForkData { ++ u_int64_t logicalSize; /* fork's logical size in bytes */ ++ u_int32_t clumpSize; /* fork's clump size in bytes */ ++ u_int32_t totalBlocks; /* total blocks used by this fork */ ++ HFSPlusExtentRecord extents; /* initial set of extents */ ++}PACKED_S; ++typedef struct HFSPlusForkData HFSPlusForkData; ++ ++ ++/* Mac OS X has 16 bytes worth of "BSD" info. ++ * ++ * Note: Mac OS 9 implementations and applications ++ * should preserve, but not change, this information. ++ */ ++struct HFSPlusBSDInfo { ++ u_int32_t ownerID; /* user or group ID of file/folder owner */ ++ u_int32_t groupID; /* additional user of group ID */ ++ u_int8_t adminFlags; /* super-user changeable flags */ ++ u_int8_t ownerFlags; /* owner changeable flags */ ++ u_int16_t fileMode; /* file type and permission bits */ ++ union { ++ u_int32_t iNodeNum; /* indirect node number (hard links only) */ ++ u_int32_t linkCount; /* links that refer to this indirect node */ ++ u_int32_t rawDevice; /* special file device (FBLK and FCHR only) */ ++ }PACKED_S special; ++}PACKED_S; ++typedef struct HFSPlusBSDInfo HFSPlusBSDInfo; ++ ++ ++/* Catalog file data structures */ ++ ++enum { ++ kHFSRootParentID = 1, /* Parent ID of the root folder */ ++ kHFSRootFolderID = 2, /* Folder ID of the root folder */ ++ kHFSExtentsFileID = 3, /* File ID of the extents file */ ++ kHFSCatalogFileID = 4, /* File ID of the catalog file */ ++ kHFSBadBlockFileID = 5, /* File ID of the bad allocation block file */ ++ kHFSAllocationFileID = 6, /* File ID of the allocation file (HFS Plus only) */ ++ kHFSStartupFileID = 7, /* File ID of the startup file (HFS Plus only) */ ++ kHFSAttributesFileID = 8, /* File ID of the attribute file (HFS Plus only) */ ++ kHFSRepairCatalogFileID = 14, /* Used when rebuilding Catalog B-tree */ ++ kHFSBogusExtentFileID = 15, /* Used for exchanging extents in extents file */ ++ kHFSFirstUserCatalogNodeID = 16 ++}PACKED_S; ++ ++/* HFS catalog key */ ++struct HFSCatalogKey { ++ u_int8_t keyLength; /* key length (in bytes) */ ++ u_int8_t reserved; /* reserved (set to zero) */ ++ u_int32_t parentID; /* parent folder ID */ ++ u_int8_t nodeName[kHFSMaxFileNameChars + 1]; /* catalog node name */ ++}PACKED_S; ++typedef struct HFSCatalogKey HFSCatalogKey; ++ ++/* HFS Plus catalog key */ ++struct HFSPlusCatalogKey { ++ u_int16_t keyLength; /* key length (in bytes) */ ++ u_int32_t parentID; /* parent folder ID */ ++ HFSUniStr255 nodeName; /* catalog node name */ ++}PACKED_S; ++typedef struct HFSPlusCatalogKey HFSPlusCatalogKey; ++ ++/* Catalog record types */ ++enum { ++ /* HFS Catalog Records */ ++ kHFSFolderRecord = 0x0100, /* Folder record */ ++ kHFSFileRecord = 0x0200, /* File record */ ++ kHFSFolderThreadRecord = 0x0300, /* Folder thread record */ ++ kHFSFileThreadRecord = 0x0400, /* File thread record */ ++ ++ /* HFS Plus Catalog Records */ ++ kHFSPlusFolderRecord = 1, /* Folder record */ ++ kHFSPlusFileRecord = 2, /* File record */ ++ kHFSPlusFolderThreadRecord = 3, /* Folder thread record */ ++ kHFSPlusFileThreadRecord = 4 /* File thread record */ ++}PACKED_S; ++ ++ ++/* Catalog file record flags */ ++enum { ++ kHFSFileLockedBit = 0x0000, /* file is locked and cannot be written to */ ++ kHFSFileLockedMask = 0x0001, ++ ++ kHFSThreadExistsBit = 0x0001, /* a file thread record exists for this file */ ++ kHFSThreadExistsMask = 0x0002, ++ ++ kHFSHasAttributesBit = 0x0002, /* object has extended attributes */ ++ kHFSHasAttributesMask = 0x0004, ++ ++ kHFSHasSecurityBit = 0x0003, /* object has security data (ACLs) */ ++ kHFSHasSecurityMask = 0x0008 ++}PACKED_S; ++ ++ ++/* HFS catalog folder record - 70 bytes */ ++struct HFSCatalogFolder { ++ int16_t recordType; /* == kHFSFolderRecord */ ++ u_int16_t flags; /* folder flags */ ++ u_int16_t valence; /* folder valence */ ++ u_int32_t folderID; /* folder ID */ ++ u_int32_t createDate; /* date and time of creation */ ++ u_int32_t modifyDate; /* date and time of last modification */ ++ u_int32_t backupDate; /* date and time of last backup */ ++ FndrDirInfo userInfo; /* Finder information */ ++ FndrOpaqueInfo finderInfo; /* additional Finder information */ ++ u_int32_t reserved[4]; /* reserved - initialized as zero */ ++}PACKED_S; ++typedef struct HFSCatalogFolder HFSCatalogFolder; ++ ++/* HFS Plus catalog folder record - 88 bytes */ ++struct HFSPlusCatalogFolder { ++ int16_t recordType; /* == kHFSPlusFolderRecord */ ++ u_int16_t flags; /* file flags */ ++ u_int32_t valence; /* folder's valence (limited to 2^16 in Mac OS) */ ++ u_int32_t folderID; /* folder ID */ ++ u_int32_t createDate; /* date and time of creation */ ++ u_int32_t contentModDate; /* date and time of last content modification */ ++ u_int32_t attributeModDate; /* date and time of last attribute modification */ ++ u_int32_t accessDate; /* date and time of last access (MacOS X only) */ ++ u_int32_t backupDate; /* date and time of last backup */ ++ HFSPlusBSDInfo bsdInfo; /* permissions (for MacOS X) */ ++ FndrDirInfo userInfo; /* Finder information */ ++ FndrOpaqueInfo finderInfo; /* additional Finder information */ ++ u_int32_t textEncoding; /* hint for name conversions */ ++ u_int32_t attrBlocks; /* cached count of attribute data blocks */ ++}PACKED_S; ++typedef struct HFSPlusCatalogFolder HFSPlusCatalogFolder; ++ ++/* HFS catalog file record - 102 bytes */ ++struct HFSCatalogFile { ++ int16_t recordType; /* == kHFSFileRecord */ ++ u_int8_t flags; /* file flags */ ++ int8_t fileType; /* file type (unused ?) */ ++ FndrFileInfo userInfo; /* Finder information */ ++ u_int32_t fileID; /* file ID */ ++ u_int16_t dataStartBlock; /* not used - set to zero */ ++ int32_t dataLogicalSize; /* logical EOF of data fork */ ++ int32_t dataPhysicalSize; /* physical EOF of data fork */ ++ u_int16_t rsrcStartBlock; /* not used - set to zero */ ++ int32_t rsrcLogicalSize; /* logical EOF of resource fork */ ++ int32_t rsrcPhysicalSize; /* physical EOF of resource fork */ ++ u_int32_t createDate; /* date and time of creation */ ++ u_int32_t modifyDate; /* date and time of last modification */ ++ u_int32_t backupDate; /* date and time of last backup */ ++ FndrOpaqueInfo finderInfo; /* additional Finder information */ ++ u_int16_t clumpSize; /* file clump size (not used) */ ++ HFSExtentRecord dataExtents; /* first data fork extent record */ ++ HFSExtentRecord rsrcExtents; /* first resource fork extent record */ ++ u_int32_t reserved; /* reserved - initialized as zero */ ++}PACKED_S; ++typedef struct HFSCatalogFile HFSCatalogFile; ++ ++/* HFS Plus catalog file record - 248 bytes */ ++struct HFSPlusCatalogFile { ++ int16_t recordType; /* == kHFSPlusFileRecord */ ++ u_int16_t flags; /* file flags */ ++ u_int32_t reserved1; /* reserved - initialized as zero */ ++ u_int32_t fileID; /* file ID */ ++ u_int32_t createDate; /* date and time of creation */ ++ u_int32_t contentModDate; /* date and time of last content modification */ ++ u_int32_t attributeModDate; /* date and time of last attribute modification */ ++ u_int32_t accessDate; /* date and time of last access (MacOS X only) */ ++ u_int32_t backupDate; /* date and time of last backup */ ++ HFSPlusBSDInfo bsdInfo; /* permissions (for MacOS X) */ ++ FndrFileInfo userInfo; /* Finder information */ ++ FndrOpaqueInfo finderInfo; /* additional Finder information */ ++ u_int32_t textEncoding; /* hint for name conversions */ ++ u_int32_t attrBlocks; /* cached count of attribute data blocks */ ++ ++ /* Note: these start on double long (64 bit) boundry */ ++ HFSPlusForkData dataFork; /* size and block data for data fork */ ++ HFSPlusForkData resourceFork; /* size and block data for resource fork */ ++}PACKED_S; ++typedef struct HFSPlusCatalogFile HFSPlusCatalogFile; ++ ++/* HFS catalog thread record - 46 bytes */ ++struct HFSCatalogThread { ++ int16_t recordType; /* == kHFSFolderThreadRecord or kHFSFileThreadRecord */ ++ int32_t reserved[2]; /* reserved - initialized as zero */ ++ u_int32_t parentID; /* parent ID for this catalog node */ ++ u_int8_t nodeName[kHFSMaxFileNameChars + 1]; /* name of this catalog node */ ++}PACKED_S; ++typedef struct HFSCatalogThread HFSCatalogThread; ++ ++/* HFS Plus catalog thread record -- 264 bytes */ ++struct HFSPlusCatalogThread { ++ int16_t recordType; /* == kHFSPlusFolderThreadRecord or kHFSPlusFileThreadRecord */ ++ int16_t reserved; /* reserved - initialized as zero */ ++ u_int32_t parentID; /* parent ID for this catalog node */ ++ HFSUniStr255 nodeName; /* name of this catalog node (variable length) */ ++}PACKED_S; ++typedef struct HFSPlusCatalogThread HFSPlusCatalogThread; ++ ++#ifdef __APPLE_API_UNSTABLE ++/* ++ These are the types of records in the attribute B-tree. The values were ++ chosen so that they wouldn't conflict with the catalog record types. ++*/ ++enum { ++ kHFSPlusAttrInlineData = 0x10, /* if size < kAttrOverflowSize */ ++ kHFSPlusAttrForkData = 0x20, /* if size >= kAttrOverflowSize */ ++ kHFSPlusAttrExtents = 0x30 /* overflow extents for large attributes */ ++}PACKED_S; ++ ++ ++/* ++ HFSPlusAttrForkData ++ For larger attributes, whose value is stored in allocation blocks. ++ If the attribute has more than 8 extents, there will be additonal ++ records (of type HFSPlusAttrExtents) for this attribute. ++*/ ++struct HFSPlusAttrForkData { ++ u_int32_t recordType; /* == kHFSPlusAttrForkData*/ ++ u_int32_t reserved; ++ HFSPlusForkData theFork; /* size and first extents of value*/ ++}PACKED_S; ++typedef struct HFSPlusAttrForkData HFSPlusAttrForkData; ++ ++/* ++ HFSPlusAttrExtents ++ This record contains information about overflow extents for large, ++ fragmented attributes. ++*/ ++struct HFSPlusAttrExtents { ++ u_int32_t recordType; /* == kHFSPlusAttrExtents*/ ++ u_int32_t reserved; ++ HFSPlusExtentRecord extents; /* additional extents*/ ++}PACKED_S; ++typedef struct HFSPlusAttrExtents HFSPlusAttrExtents; ++ ++/* ++ * Atrributes B-tree Data Record ++ * ++ * For small attributes, whose entire value is stored ++ * within a single B-tree record. ++ */ ++struct HFSPlusAttrData { ++ u_int32_t recordType; /* == kHFSPlusAttrInlineData */ ++ u_int32_t reserved[2]; ++ u_int32_t attrSize; /* size of attribute data in bytes */ ++ u_int8_t attrData[2]; /* variable length */ ++}PACKED_S; ++typedef struct HFSPlusAttrData HFSPlusAttrData; ++ ++ ++/* HFSPlusAttrInlineData is obsolete use HFSPlusAttrData instead */ ++struct HFSPlusAttrInlineData { ++ u_int32_t recordType; ++ u_int32_t reserved; ++ u_int32_t logicalSize; ++ u_int8_t userData[2]; ++}PACKED_S; ++typedef struct HFSPlusAttrInlineData HFSPlusAttrInlineData; ++ ++ ++/* A generic Attribute Record*/ ++union HFSPlusAttrRecord { ++ u_int32_t recordType; ++ HFSPlusAttrInlineData inlineData; /* NOT USED */ ++ HFSPlusAttrData attrData; ++ HFSPlusAttrForkData forkData; ++ HFSPlusAttrExtents overflowExtents; ++}PACKED_S; ++typedef union HFSPlusAttrRecord HFSPlusAttrRecord; ++ ++/* Attribute key */ ++enum { kHFSMaxAttrNameLen = 127 }; ++struct HFSPlusAttrKey { ++ u_int16_t keyLength; /* key length (in bytes) */ ++ u_int16_t pad; /* set to zero */ ++ u_int32_t fileID; /* file associated with attribute */ ++ u_int32_t startBlock; /* first attribue allocation block number for extents */ ++ u_int16_t attrNameLen; /* number of unicode characters */ ++ u_int16_t attrName[127]; /* attribute name (Unicode) */ ++}PACKED_S; ++typedef struct HFSPlusAttrKey HFSPlusAttrKey; ++ ++#define kHFSPlusAttrKeyMaximumLength (sizeof(HFSPlusAttrKey) - sizeof(u_int16_t)) ++#define kHFSPlusAttrKeyMinimumLength (kHFSPlusAttrKeyMaximumLength - (127 * sizeof(u_int16_t))) ++ ++#endif /* __APPLE_API_UNSTABLE */ ++ ++ ++/* Key and node lengths */ ++enum { ++ kHFSPlusExtentKeyMaximumLength = sizeof(HFSPlusExtentKey) - sizeof(u_int16_t), ++ kHFSExtentKeyMaximumLength = sizeof(HFSExtentKey) - sizeof(u_int8_t), ++ kHFSPlusCatalogKeyMaximumLength = sizeof(HFSPlusCatalogKey) - sizeof(u_int16_t), ++ kHFSPlusCatalogKeyMinimumLength = kHFSPlusCatalogKeyMaximumLength - sizeof(HFSUniStr255) + sizeof(u_int16_t), ++ kHFSCatalogKeyMaximumLength = sizeof(HFSCatalogKey) - sizeof(u_int8_t), ++ kHFSCatalogKeyMinimumLength = kHFSCatalogKeyMaximumLength - (kHFSMaxFileNameChars + 1) + sizeof(u_int8_t), ++ kHFSPlusCatalogMinNodeSize = 4096, ++ kHFSPlusExtentMinNodeSize = 512, ++ kHFSPlusAttrMinNodeSize = 4096 ++}PACKED_S; ++ ++/* HFS and HFS Plus volume attribute bits */ ++enum { ++ /* Bits 0-6 are reserved (always cleared by MountVol call) */ ++ kHFSVolumeHardwareLockBit = 7, /* volume is locked by hardware */ ++ kHFSVolumeUnmountedBit = 8, /* volume was successfully unmounted */ ++ kHFSVolumeSparedBlocksBit = 9, /* volume has bad blocks spared */ ++ kHFSVolumeNoCacheRequiredBit = 10, /* don't cache volume blocks (i.e. RAM or ROM disk) */ ++ kHFSBootVolumeInconsistentBit = 11, /* boot volume is inconsistent (System 7.6 and later) */ ++ kHFSCatalogNodeIDsReusedBit = 12, ++ kHFSVolumeJournaledBit = 13, /* this volume has a journal on it */ ++ kHFSVolumeInconsistentBit = 14, /* serious inconsistencies detected at runtime */ ++ kHFSVolumeSoftwareLockBit = 15, /* volume is locked by software */ ++ ++ kHFSVolumeHardwareLockMask = 1 << kHFSVolumeHardwareLockBit, ++ kHFSVolumeUnmountedMask = 1 << kHFSVolumeUnmountedBit, ++ kHFSVolumeSparedBlocksMask = 1 << kHFSVolumeSparedBlocksBit, ++ kHFSVolumeNoCacheRequiredMask = 1 << kHFSVolumeNoCacheRequiredBit, ++ kHFSBootVolumeInconsistentMask = 1 << kHFSBootVolumeInconsistentBit, ++ kHFSCatalogNodeIDsReusedMask = 1 << kHFSCatalogNodeIDsReusedBit, ++ kHFSVolumeJournaledMask = 1 << kHFSVolumeJournaledBit, ++ kHFSVolumeInconsistentMask = 1 << kHFSVolumeInconsistentBit, ++ kHFSVolumeSoftwareLockMask = 1 << kHFSVolumeSoftwareLockBit, ++ kHFSMDBAttributesMask = 0x8380 ++}PACKED_S; ++ ++ ++/* HFS Master Directory Block - 162 bytes */ ++/* Stored at sector #2 (3rd sector) and second-to-last sector. */ ++struct HFSMasterDirectoryBlock { ++ u_int16_t drSigWord; /* == kHFSSigWord */ ++ u_int32_t drCrDate; /* date and time of volume creation */ ++ u_int32_t drLsMod; /* date and time of last modification */ ++ u_int16_t drAtrb; /* volume attributes */ ++ u_int16_t drNmFls; /* number of files in root folder */ ++ u_int16_t drVBMSt; /* first block of volume bitmap */ ++ u_int16_t drAllocPtr; /* start of next allocation search */ ++ u_int16_t drNmAlBlks; /* number of allocation blocks in volume */ ++ u_int32_t drAlBlkSiz; /* size (in bytes) of allocation blocks */ ++ u_int32_t drClpSiz; /* default clump size */ ++ u_int16_t drAlBlSt; /* first allocation block in volume */ ++ u_int32_t drNxtCNID; /* next unused catalog node ID */ ++ u_int16_t drFreeBks; /* number of unused allocation blocks */ ++ u_int8_t drVN[kHFSMaxVolumeNameChars + 1]; /* volume name */ ++ u_int32_t drVolBkUp; /* date and time of last backup */ ++ u_int16_t drVSeqNum; /* volume backup sequence number */ ++ u_int32_t drWrCnt; /* volume write count */ ++ u_int32_t drXTClpSiz; /* clump size for extents overflow file */ ++ u_int32_t drCTClpSiz; /* clump size for catalog file */ ++ u_int16_t drNmRtDirs; /* number of directories in root folder */ ++ u_int32_t drFilCnt; /* number of files in volume */ ++ u_int32_t drDirCnt; /* number of directories in volume */ ++ u_int32_t drFndrInfo[8]; /* information used by the Finder */ ++ u_int16_t drEmbedSigWord; /* embedded volume signature (formerly drVCSize) */ ++ HFSExtentDescriptor drEmbedExtent; /* embedded volume location and size (formerly drVBMCSize and drCtlCSize) */ ++ u_int32_t drXTFlSize; /* size of extents overflow file */ ++ HFSExtentRecord drXTExtRec; /* extent record for extents overflow file */ ++ u_int32_t drCTFlSize; /* size of catalog file */ ++ HFSExtentRecord drCTExtRec; /* extent record for catalog file */ ++}PACKED_S; ++typedef struct HFSMasterDirectoryBlock HFSMasterDirectoryBlock; ++ ++ ++#ifdef __APPLE_API_UNSTABLE ++#define SET_HFS_TEXT_ENCODING(hint) \ ++ (0x656e6300 | ((hint) & 0xff)) ++#define GET_HFS_TEXT_ENCODING(hint) \ ++ (((hint) & 0xffffff00) == 0x656e6300 ? (hint) & 0x000000ff : 0xffffffffU) ++#endif /* __APPLE_API_UNSTABLE */ ++ ++ ++/* HFS Plus Volume Header - 512 bytes */ ++/* Stored at sector #2 (3rd sector) and second-to-last sector. */ ++struct HFSPlusVolumeHeader { ++ u_int16_t signature; /* == kHFSPlusSigWord */ ++ u_int16_t version; /* == kHFSPlusVersion */ ++ u_int32_t attributes; /* volume attributes */ ++ u_int32_t lastMountedVersion; /* implementation version which last mounted volume */ ++ u_int32_t journalInfoBlock; /* block addr of journal info (if volume is journaled, zero otherwise) */ ++ ++ u_int32_t createDate; /* date and time of volume creation */ ++ u_int32_t modifyDate; /* date and time of last modification */ ++ u_int32_t backupDate; /* date and time of last backup */ ++ u_int32_t checkedDate; /* date and time of last disk check */ ++ ++ u_int32_t fileCount; /* number of files in volume */ ++ u_int32_t folderCount; /* number of directories in volume */ ++ ++ u_int32_t blockSize; /* size (in bytes) of allocation blocks */ ++ u_int32_t totalBlocks; /* number of allocation blocks in volume (includes this header and VBM*/ ++ u_int32_t freeBlocks; /* number of unused allocation blocks */ ++ ++ u_int32_t nextAllocation; /* start of next allocation search */ ++ u_int32_t rsrcClumpSize; /* default resource fork clump size */ ++ u_int32_t dataClumpSize; /* default data fork clump size */ ++ u_int32_t nextCatalogID; /* next unused catalog node ID */ ++ ++ u_int32_t writeCount; /* volume write count */ ++ u_int64_t encodingsBitmap; /* which encodings have been use on this volume */ ++ ++ u_int8_t finderInfo[32]; /* information used by the Finder */ ++ ++ HFSPlusForkData allocationFile; /* allocation bitmap file */ ++ HFSPlusForkData extentsFile; /* extents B-tree file */ ++ HFSPlusForkData catalogFile; /* catalog B-tree file */ ++ HFSPlusForkData attributesFile; /* extended attributes B-tree file */ ++ HFSPlusForkData startupFile; /* boot file (secondary loader) */ ++}PACKED_S; ++typedef struct HFSPlusVolumeHeader HFSPlusVolumeHeader; ++ ++ ++/* B-tree structures */ ++ ++enum BTreeKeyLimits{ ++ kMaxKeyLength = 520 ++}PACKED_S; ++ ++union BTreeKey{ ++ u_int8_t length8; ++ u_int16_t length16; ++ u_int8_t rawData [kMaxKeyLength+2]; ++}PACKED_S; ++typedef union BTreeKey BTreeKey; ++ ++/* BTNodeDescriptor -- Every B-tree node starts with these fields. */ ++struct BTNodeDescriptor { ++ u_int32_t fLink; /* next node at this level*/ ++ u_int32_t bLink; /* previous node at this level*/ ++ int8_t kind; /* kind of node (leaf, index, header, map)*/ ++ u_int8_t height; /* zero for header, map; child is one more than parent*/ ++ u_int16_t numRecords; /* number of records in this node*/ ++ u_int16_t reserved; /* reserved - initialized as zero */ ++}PACKED_S; ++typedef struct BTNodeDescriptor BTNodeDescriptor; ++ ++/* Constants for BTNodeDescriptor kind */ ++enum { ++ kBTLeafNode = -1, ++ kBTIndexNode = 0, ++ kBTHeaderNode = 1, ++ kBTMapNode = 2 ++}PACKED_S; ++ ++/* BTHeaderRec -- The first record of a B-tree header node */ ++struct BTHeaderRec { ++ u_int16_t treeDepth; /* maximum height (usually leaf nodes) */ ++ u_int32_t rootNode; /* node number of root node */ ++ u_int32_t leafRecords; /* number of leaf records in all leaf nodes */ ++ u_int32_t firstLeafNode; /* node number of first leaf node */ ++ u_int32_t lastLeafNode; /* node number of last leaf node */ ++ u_int16_t nodeSize; /* size of a node, in bytes */ ++ u_int16_t maxKeyLength; /* reserved */ ++ u_int32_t totalNodes; /* total number of nodes in tree */ ++ u_int32_t freeNodes; /* number of unused (free) nodes in tree */ ++ u_int16_t reserved1; /* unused */ ++ u_int32_t clumpSize; /* reserved */ ++ u_int8_t btreeType; /* reserved */ ++ u_int8_t keyCompareType; /* Key string Comparison Type */ ++ u_int32_t attributes; /* persistent attributes about the tree */ ++ u_int32_t reserved3[16]; /* reserved */ ++}PACKED_S; ++typedef struct BTHeaderRec BTHeaderRec; ++ ++/* Constants for BTHeaderRec attributes */ ++enum { ++ kBTBadCloseMask = 0x00000001, /* reserved */ ++ kBTBigKeysMask = 0x00000002, /* key length field is 16 bits */ ++ kBTVariableIndexKeysMask = 0x00000004 /* keys in index nodes are variable length */ ++}PACKED_S; ++ ++ ++/* Catalog Key Name Comparison Type */ ++enum { ++ kHFSCaseFolding = 0xCF, /* case folding (case-insensitive) */ ++ kHFSBinaryCompare = 0xBC /* binary compare (case-sensitive) */ ++}PACKED_S; ++ ++/* JournalInfoBlock - Structure that describes where our journal lives */ ++struct JournalInfoBlock { ++ u_int32_t flags; ++ u_int32_t device_signature[8]; // signature used to locate our device. ++ u_int64_t offset; // byte offset to the journal on the device ++ u_int64_t size; // size in bytes of the journal ++ u_int32_t reserved[32]; ++}PACKED_S; ++typedef struct JournalInfoBlock JournalInfoBlock; ++ ++enum { ++ kJIJournalInFSMask = 0x00000001, ++ kJIJournalOnOtherDeviceMask = 0x00000002, ++ kJIJournalNeedInitMask = 0x00000004 ++}PACKED_S; ++ ++#ifdef __cplusplus ++} ++#endif ++ ++#endif /* __HFS_FORMAT__ */ +diff --git a/include/hfs/hfs_mount.h b/include/hfs/hfs_mount.h +new file mode 100644 +index 0000000..ad729f2 +--- /dev/null ++++ b/include/hfs/hfs_mount.h +@@ -0,0 +1,78 @@ ++/* ++ * Copyright (c) 2000-2003 Apple Computer, Inc. All rights reserved. ++ * ++ * @APPLE_LICENSE_HEADER_START@ ++ * ++ * The contents of this file constitute Original Code as defined in and ++ * are subject to the Apple Public Source License Version 1.1 (the ++ * "License"). You may not use this file except in compliance with the ++ * License. Please obtain a copy of the License at ++ * http://www.apple.com/publicsource and read it before using this file. ++ * ++ * This Original Code and all software distributed under the License are ++ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER ++ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, ++ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the ++ * License for the specific language governing rights and limitations ++ * under the License. ++ * ++ * @APPLE_LICENSE_HEADER_END@ ++ */ ++/* ++ * Copyright (c) 1997-2002 Apple Computer, Inc. All Rights Reserved ++ * ++ */ ++ ++#ifndef _HFS_MOUNT_H_ ++#define _HFS_MOUNT_H_ ++ ++#include ++ ++#include ++#include ++ ++/* ++ * Arguments to mount HFS-based filesystems ++ */ ++ ++#define OVERRIDE_UNKNOWN_PERMISSIONS 0 ++ ++#define UNKNOWNUID ((uid_t)99) ++#define UNKNOWNGID ((gid_t)99) ++#define UNKNOWNPERMISSIONS (S_IRWXU | S_IROTH | S_IXOTH) /* 705 */ ++ ++#ifdef __APPLE_API_UNSTABLE ++struct hfs_mount_args { ++#ifndef KERNEL ++ char *fspec; /* block special device to mount */ ++#endif ++ uid_t hfs_uid; /* uid that owns hfs files (standard HFS only) */ ++ gid_t hfs_gid; /* gid that owns hfs files (standard HFS only) */ ++ mode_t hfs_mask; /* mask to be applied for hfs perms (standard HFS only) */ ++ u_int32_t hfs_encoding; /* encoding for this volume (standard HFS only) */ ++ struct timezone hfs_timezone; /* user time zone info (standard HFS only) */ ++ int flags; /* mounting flags, see below */ ++ int journal_tbuffer_size; /* size in bytes of the journal transaction buffer */ ++ int journal_flags; /* flags to pass to journal_open/create */ ++ int journal_disable; /* don't use journaling (potentially dangerous) */ ++}; ++ ++#define HFSFSMNT_NOXONFILES 0x1 /* disable execute permissions for files */ ++#define HFSFSMNT_WRAPPER 0x2 /* mount HFS wrapper (if it exists) */ ++#define HFSFSMNT_EXTENDED_ARGS 0x4 /* indicates new fields after "flags" are valid */ ++ ++/* ++ * Sysctl values for HFS ++ */ ++#define HFS_ENCODINGBIAS 1 /* encoding matching CJK bias */ ++#define HFS_EXTEND_FS 2 ++#define HFS_ENCODINGHINT 3 /* guess encoding for string */ ++#define HFS_ENABLE_JOURNALING 0x082969 ++#define HFS_DISABLE_JOURNALING 0x031272 ++#define HFS_GET_JOURNAL_INFO 0x6a6e6c69 ++#define HFS_SET_PKG_EXTENSIONS 0x121031 ++ ++#endif /* __APPLE_API_UNSTABLE */ ++ ++#endif /* ! _HFS_MOUNT_H_ */ +diff --git a/include/sys/appleapiopts.h b/include/sys/appleapiopts.h +new file mode 100644 +index 0000000..4d2061f +--- /dev/null ++++ b/include/sys/appleapiopts.h +@@ -0,0 +1,52 @@ ++/* ++ * Copyright (c) 2002 Apple Computer, Inc. All rights reserved. ++ * ++ * @APPLE_LICENSE_HEADER_START@ ++ * ++ * The contents of this file constitute Original Code as defined in and ++ * are subject to the Apple Public Source License Version 1.1 (the ++ * "License"). You may not use this file except in compliance with the ++ * License. Please obtain a copy of the License at ++ * http://www.apple.com/publicsource and read it before using this file. ++ * ++ * This Original Code and all software distributed under the License are ++ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER ++ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, ++ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the ++ * License for the specific language governing rights and limitations ++ * under the License. ++ * ++ * @APPLE_LICENSE_HEADER_END@ ++ */ ++ ++#ifndef __SYS_APPLEAPIOPTS_H__ ++#define __SYS_APPLEAPIOPTS_H__ ++ ++ ++#ifndef __APPLE_API_STANDARD ++#define __APPLE_API_STANDARD ++#endif /* __APPLE_API_STANDARD */ ++ ++#ifndef __APPLE_API_STABLE ++#define __APPLE_API_STABLE ++#endif /* __APPLE_API_STABLE */ ++ ++#ifndef __APPLE_API_STRICT_CONFORMANCE ++ ++#ifndef __APPLE_API_EVOLVING ++#define __APPLE_API_EVOLVING ++#endif /* __APPLE_API_EVOLVING */ ++ ++#ifndef __APPLE_API_UNSTABLE ++#define __APPLE_API_UNSTABLE ++#endif /* __APPLE_API_UNSTABLE */ ++ ++#ifndef __APPLE_API_OBSOLETE ++#define __APPLE_API_OBSOLETE ++#endif /* __APPLE_API_OBSOLETE */ ++ ++#endif /* __APPLE_API_STRICT_CONFORMANCE */ ++ ++#endif /* __SYS_APPLEAPIOPTS_H__ */ ++ diff --git a/utils/hfsprogs/patches/0004-Fix-compilation-on-64-bit-arches.patch b/utils/hfsprogs/patches/0004-Fix-compilation-on-64-bit-arches.patch new file mode 100644 index 000000000..57f601108 --- /dev/null +++ b/utils/hfsprogs/patches/0004-Fix-compilation-on-64-bit-arches.patch @@ -0,0 +1,131 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Fix compilation on 64-bit arches + +--- + fsck_hfs.tproj/dfalib/BTreePrivate.h | 5 ++++- + fsck_hfs.tproj/dfalib/SControl.c | 8 ++++---- + fsck_hfs.tproj/dfalib/SVerify1.c | 14 +++++++------- + fsck_hfs.tproj/dfalib/hfs_endian.c | 2 +- + 4 files changed, 16 insertions(+), 13 deletions(-) + +diff --git a/fsck_hfs.tproj/dfalib/BTreePrivate.h b/fsck_hfs.tproj/dfalib/BTreePrivate.h +index 058c75b..2fc2f28 100644 +--- a/fsck_hfs.tproj/dfalib/BTreePrivate.h ++++ b/fsck_hfs.tproj/dfalib/BTreePrivate.h +@@ -104,6 +104,9 @@ typedef enum { + + ///////////////////////////////////// Types ///////////////////////////////////// + ++// Forward declaration from Scavenger.h ++struct BTreeExtensionsRec; ++ + typedef struct BTreeControlBlock { // fields specific to BTree CBs + + UInt8 keyCompareType; /* Key string Comparison Type */ +@@ -144,7 +147,7 @@ typedef struct BTreeControlBlock { // fields specific to BTree CBs + UInt32 numPossibleHints; // Looks like a formated hint + UInt32 numValidHints; // Hint used to find correct record. + +- UInt32 refCon; // Used by DFA to point to private data. ++ struct BTreeExtensionsRec *refCon; // Used by DFA to point to private data. + SFCB *fcbPtr; // fcb of btree file + + } BTreeControlBlock, *BTreeControlBlockPtr; +diff --git a/fsck_hfs.tproj/dfalib/SControl.c b/fsck_hfs.tproj/dfalib/SControl.c +index 37eb242..4ce9e16 100644 +--- a/fsck_hfs.tproj/dfalib/SControl.c ++++ b/fsck_hfs.tproj/dfalib/SControl.c +@@ -1034,7 +1034,7 @@ static int ScavTerm( SGlobPtr GPtr ) + btcbP = (BTreeControlBlock*)fcbP->fcbBtree; + if ( btcbP != nil) + { +- if( btcbP->refCon != (UInt32)nil ) ++ if( btcbP->refCon != nil ) + { + if(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != nil) + { +@@ -1043,13 +1043,13 @@ static int ScavTerm( SGlobPtr GPtr ) + } + DisposeMemory( (Ptr)btcbP->refCon ); + err = MemError(); +- btcbP->refCon = (UInt32)nil; ++ btcbP->refCon = nil; + } + + fcbP = GPtr->calculatedCatalogFCB; // release catalog BTree bit map + btcbP = (BTreeControlBlock*)fcbP->fcbBtree; + +- if( btcbP->refCon != (UInt32)nil ) ++ if( btcbP->refCon != nil ) + { + if(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != nil) + { +@@ -1058,7 +1058,7 @@ static int ScavTerm( SGlobPtr GPtr ) + } + DisposeMemory( (Ptr)btcbP->refCon ); + err = MemError(); +- btcbP->refCon = (UInt32)nil; ++ btcbP->refCon = nil; + } + } + } +diff --git a/fsck_hfs.tproj/dfalib/SVerify1.c b/fsck_hfs.tproj/dfalib/SVerify1.c +index c272d4d..a273bf3 100644 +--- a/fsck_hfs.tproj/dfalib/SVerify1.c ++++ b/fsck_hfs.tproj/dfalib/SVerify1.c +@@ -789,8 +789,8 @@ OSErr CreateExtentsBTreeControlBlock( SGlobPtr GPtr ) + // + // set up our DFA extended BTCB area. Will we have enough memory on all HFS+ volumes. + // +- btcb->refCon = (UInt32) AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == (UInt32) nil ) { ++ btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions ++ if ( btcb->refCon == nil ) { + err = R_NoMem; + goto exit; + } +@@ -1144,8 +1144,8 @@ OSErr CreateCatalogBTreeControlBlock( SGlobPtr GPtr ) + // set up our DFA extended BTCB area. Will we have enough memory on all HFS+ volumes. + // + +- btcb->refCon = (UInt32) AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == (UInt32)nil ) { ++ btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions ++ if ( btcb->refCon == nil ) { + err = R_NoMem; + goto exit; + } +@@ -1779,8 +1779,8 @@ OSErr CreateAttributesBTreeControlBlock( SGlobPtr GPtr ) + // + // set up our DFA extended BTCB area. Will we have enough memory on all HFS+ volumes. + // +- btcb->refCon = (UInt32) AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == (UInt32)nil ) { ++ btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions ++ if ( btcb->refCon == nil ) { + err = R_NoMem; + goto exit; + } +@@ -1793,7 +1793,7 @@ OSErr CreateAttributesBTreeControlBlock( SGlobPtr GPtr ) + } + else + { +- if ( btcb->refCon == (UInt32)nil ) { ++ if ( btcb->refCon == nil ) { + err = R_NoMem; + goto exit; + } +diff --git a/fsck_hfs.tproj/dfalib/hfs_endian.c b/fsck_hfs.tproj/dfalib/hfs_endian.c +index 69500c1..3cc9eb4 100755 +--- a/fsck_hfs.tproj/dfalib/hfs_endian.c ++++ b/fsck_hfs.tproj/dfalib/hfs_endian.c +@@ -437,7 +437,7 @@ hfs_swap_HFSPlusBTInternalNode ( + BTNodeDescriptor *srcDesc = src->buffer; + UInt16 *srcOffs = (UInt16 *)((char *)src->buffer + (src->blockSize - (srcDesc->numRecords * sizeof (UInt16)))); + char *nextRecord; /* Points to start of record following current one */ +- UInt32 i; ++ int i; + UInt32 j; + + if (fileID == kHFSExtentsFileID) { diff --git a/utils/hfsprogs/patches/0005-Remove-Apple-specific-p-from-strings.patch b/utils/hfsprogs/patches/0005-Remove-Apple-specific-p-from-strings.patch new file mode 100644 index 000000000..318fd603a --- /dev/null +++ b/utils/hfsprogs/patches/0005-Remove-Apple-specific-p-from-strings.patch @@ -0,0 +1,291 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Remove (Apple-specific?) \p from strings + +Modify the way that debug messages are sent to the user, by eliminating one +character of them. +--- + fsck_hfs.tproj/dfalib/BTreeTreeOps.c | 48 ++++++++++++++++++------------------ + fsck_hfs.tproj/dfalib/SBTree.c | 14 +++++------ + 2 files changed, 31 insertions(+), 31 deletions(-) + +diff --git a/fsck_hfs.tproj/dfalib/BTreeTreeOps.c b/fsck_hfs.tproj/dfalib/BTreeTreeOps.c +index b812b14..37fb170 100644 +--- a/fsck_hfs.tproj/dfalib/BTreeTreeOps.c ++++ b/fsck_hfs.tproj/dfalib/BTreeTreeOps.c +@@ -223,7 +223,7 @@ OSStatus SearchTree (BTreeControlBlockPtr btreePtr, + // + if (curNodeNum == 0) + { +-// Panic("\pSearchTree: curNodeNum is zero!"); ++ Panic("SearchTree: curNodeNum is zero!"); + err = fsBTInvalidNodeErr; + goto ErrorExit; + } +@@ -433,7 +433,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + M_ExitOnError (err); + + if ( DEBUG_BUILD && updateParent && newRoot ) +- DebugStr("\p InsertLevel: New root from primary key, update from secondary key..."); ++ DebugStr("InsertLevel: New root from primary key, update from secondary key..."); + } + + //////////////////////// Update Parent(s) /////////////////////////////// +@@ -448,7 +448,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + + secondaryKey = nil; + +- PanicIf ( (level == btreePtr->treeDepth), "\p InsertLevel: unfinished insert!?"); ++ PanicIf ( (level == btreePtr->treeDepth), "InsertLevel: unfinished insert!?"); + + ++level; + +@@ -456,7 +456,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + index = treePathTable [level].index; + parentNodeNum = treePathTable [level].node; + +- PanicIf ( parentNodeNum == 0, "\p InsertLevel: parent node is zero!?"); ++ PanicIf ( parentNodeNum == 0, "InsertLevel: parent node is zero!?"); + + err = GetNode (btreePtr, parentNodeNum, &parentNode); // released as target node in next level up + M_ExitOnError (err); +@@ -470,7 +470,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + { + //debug: check if ptr == targetNodeNum + GetRecordByIndex (btreePtr, parentNode.buffer, index, &keyPtr, &recPtr, &recSize); +- PanicIf( (*(UInt32 *) recPtr) != targetNodeNum, "\p InsertLevel: parent ptr doesn't match target node!"); ++ PanicIf( (*(UInt32 *) recPtr) != targetNodeNum, "InsertLevel: parent ptr doesn't match target node!"); + + // need to delete and re-insert this parent key/ptr + // we delete it here and it gets re-inserted in the +@@ -532,7 +532,7 @@ ErrorExit: + (void) ReleaseNode (btreePtr, targetNode); + (void) ReleaseNode (btreePtr, &siblingNode); + +- Panic ("\p InsertLevel: an error occured!"); ++ Panic ("InsertLevel: an error occured!"); + + return err; + +@@ -566,7 +566,7 @@ static OSErr InsertNode (BTreeControlBlockPtr btreePtr, + + *rootSplit = false; + +- PanicIf ( targetNode->buffer == siblingNode->buffer, "\p InsertNode: targetNode == siblingNode, huh?"); ++ PanicIf ( targetNode->buffer == siblingNode->buffer, "InsertNode: targetNode == siblingNode, huh?"); + + leftNodeNum = ((NodeDescPtr) targetNode->buffer)->bLink; + rightNodeNum = ((NodeDescPtr) targetNode->buffer)->fLink; +@@ -606,7 +606,7 @@ static OSErr InsertNode (BTreeControlBlockPtr btreePtr, + + if ( leftNodeNum > 0 ) + { +- PanicIf ( siblingNode->buffer != nil, "\p InsertNode: siblingNode already aquired!"); ++ PanicIf ( siblingNode->buffer != nil, "InsertNode: siblingNode already aquired!"); + + if ( siblingNode->buffer == nil ) + { +@@ -614,7 +614,7 @@ static OSErr InsertNode (BTreeControlBlockPtr btreePtr, + M_ExitOnError (err); + } + +- PanicIf ( ((NodeDescPtr) siblingNode->buffer)->fLink != nodeNum, "\p InsertNode, RotateLeft: invalid sibling link!" ); ++ PanicIf ( ((NodeDescPtr) siblingNode->buffer)->fLink != nodeNum, "InsertNode, RotateLeft: invalid sibling link!" ); + + if ( !key->skipRotate ) // are rotates allowed? + { +@@ -703,7 +703,7 @@ OSStatus DeleteTree (BTreeControlBlockPtr btreePtr, + + targetNodeNum = treePathTable[level].node; + targetNodePtr = targetNode->buffer; +- PanicIf (targetNodePtr == nil, "\pDeleteTree: targetNode has nil buffer!"); ++ PanicIf (targetNodePtr == nil, "DeleteTree: targetNode has nil buffer!"); + + DeleteRecord (btreePtr, targetNodePtr, index); + +@@ -797,7 +797,7 @@ OSStatus DeleteTree (BTreeControlBlockPtr btreePtr, + + //debug: check if ptr == targetNodeNum + GetRecordByIndex (btreePtr, parentNode.buffer, index, &keyPtr, &recPtr, &recSize); +- PanicIf( (*(UInt32 *) recPtr) != targetNodeNum, "\p DeleteTree: parent ptr doesn't match targetNodeNum!!"); ++ PanicIf( (*(UInt32 *) recPtr) != targetNodeNum, " DeleteTree: parent ptr doesn't match targetNodeNum!!"); + + // need to delete and re-insert this parent key/ptr + DeleteRecord (btreePtr, parentNode.buffer, index); +@@ -1018,7 +1018,7 @@ static OSStatus RotateLeft (BTreeControlBlockPtr btreePtr, + keyPtr, keyLength, recPtr, recSize); + if ( !didItFit ) + { +- Panic ("\pRotateLeft: InsertKeyRecord (left) returned false!"); ++ Panic ("RotateLeft: InsertKeyRecord (left) returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1031,7 +1031,7 @@ static OSStatus RotateLeft (BTreeControlBlockPtr btreePtr, + didItFit = RotateRecordLeft (btreePtr, leftNode, rightNode); + if ( !didItFit ) + { +- Panic ("\pRotateLeft: RotateRecordLeft returned false!"); ++ Panic ("RotateLeft: RotateRecordLeft returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1048,7 +1048,7 @@ static OSStatus RotateLeft (BTreeControlBlockPtr btreePtr, + keyPtr, keyLength, recPtr, recSize); + if ( !didItFit ) + { +- Panic ("\pRotateLeft: InsertKeyRecord (right) returned false!"); ++ Panic ("RotateLeft: InsertKeyRecord (right) returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1117,7 +1117,7 @@ static OSStatus SplitLeft (BTreeControlBlockPtr btreePtr, + right = rightNode->buffer; + left = leftNode->buffer; + +- PanicIf ( right->bLink != 0 && left == 0, "\p SplitLeft: left sibling missing!?" ); ++ PanicIf ( right->bLink != 0 && left == 0, " SplitLeft: left sibling missing!?" ); + + // type should be kLeafNode or kIndexNode + +@@ -1240,8 +1240,8 @@ static OSStatus AddNewRootNode (BTreeControlBlockPtr btreePtr, + Boolean didItFit; + UInt16 keyLength; + +- PanicIf (leftNode == nil, "\pAddNewRootNode: leftNode == nil"); +- PanicIf (rightNode == nil, "\pAddNewRootNode: rightNode == nil"); ++ PanicIf (leftNode == nil, "AddNewRootNode: leftNode == nil"); ++ PanicIf (rightNode == nil, "AddNewRootNode: rightNode == nil"); + + + /////////////////////// Initialize New Root Node //////////////////////////// +@@ -1264,7 +1264,7 @@ static OSStatus AddNewRootNode (BTreeControlBlockPtr btreePtr, + didItFit = InsertKeyRecord ( btreePtr, rootNode.buffer, 0, keyPtr, keyLength, + (UInt8 *) &rightNode->bLink, 4 ); + +- PanicIf ( !didItFit, "\pAddNewRootNode:InsertKeyRecord failed for left index record"); ++ PanicIf ( !didItFit, "AddNewRootNode:InsertKeyRecord failed for left index record"); + + + //////////////////// Insert Right Node Index Record ///////////////////////// +@@ -1275,7 +1275,7 @@ static OSStatus AddNewRootNode (BTreeControlBlockPtr btreePtr, + didItFit = InsertKeyRecord ( btreePtr, rootNode.buffer, 1, keyPtr, keyLength, + (UInt8 *) &leftNode->fLink, 4 ); + +- PanicIf ( !didItFit, "\pAddNewRootNode:InsertKeyRecord failed for right index record"); ++ PanicIf ( !didItFit, "AddNewRootNode:InsertKeyRecord failed for right index record"); + + + #if DEBUG_TREEOPS +@@ -1355,7 +1355,7 @@ static OSStatus SplitRight (BTreeControlBlockPtr btreePtr, + } + rightPtr = rightNodePtr->buffer; + +- PanicIf ( leftPtr->fLink != 0 && rightPtr == 0, "\p SplitRight: right sibling missing!?" ); ++ PanicIf ( leftPtr->fLink != 0 && rightPtr == 0, "SplitRight: right sibling missing!?" ); + + // type should be kLeafNode or kIndexNode + +@@ -1557,7 +1557,7 @@ static OSStatus RotateRight (BTreeControlBlockPtr btreePtr, + keyPtr, keyLength, recPtr, recSize); + if ( !didItFit ) + { +- Panic ("\pRotateRight: InsertKeyRecord (left) returned false!"); ++ Panic ("RotateRight: InsertKeyRecord (left) returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1572,7 +1572,7 @@ static OSStatus RotateRight (BTreeControlBlockPtr btreePtr, + didItFit = RotateRecordRight( btreePtr, leftNodePtr, rightNodePtr ); + if ( !didItFit ) + { +- Panic ("\pRotateRight: RotateRecordRight returned false!"); ++ Panic ("RotateRight: RotateRecordRight returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1583,7 +1583,7 @@ static OSStatus RotateRight (BTreeControlBlockPtr btreePtr, + keyPtr, keyLength, recPtr, recSize); + if ( !didItFit ) + { +- Panic ("\pRotateRight: InsertKeyRecord (left) returned false!"); ++ Panic ("RotateRight: InsertKeyRecord (left) returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +@@ -1607,7 +1607,7 @@ static OSStatus RotateRight (BTreeControlBlockPtr btreePtr, + keyPtr, keyLength, recPtr, recSize); + if ( !didItFit ) + { +- Panic ("\pRotateRight: InsertKeyRecord (right) returned false!"); ++ Panic ("RotateRight: InsertKeyRecord (right) returned false!"); + err = fsBTBadRotateErr; + goto ErrorExit; + } +diff --git a/fsck_hfs.tproj/dfalib/SBTree.c b/fsck_hfs.tproj/dfalib/SBTree.c +index cd81b13..eeb4e8c 100644 +--- a/fsck_hfs.tproj/dfalib/SBTree.c ++++ b/fsck_hfs.tproj/dfalib/SBTree.c +@@ -103,7 +103,7 @@ OSErr SearchBTreeRecord(SFCB *fcb, const void* key, UInt32 hint, void* foundKey, + CopyMemory(&resultIterator->key, foundKey, CalcKeySize(btcb, &resultIterator->key)); // warning, this could overflow user's buffer!!! + + if ( DEBUG_BUILD && !ValidHFSRecord(data, btcb, *dataSize) ) +- DebugStr("\pSearchBTreeRecord: bad record?"); ++ DebugStr("SearchBTreeRecord: bad record?"); + } + + ErrorExit: +@@ -211,7 +211,7 @@ OSErr GetBTreeRecord(SFCB *fcb, SInt16 selectionIndex, void* key, void* data, UI + CopyMemory(&iterator->key, key, CalcKeySize(btcb, &iterator->key)); // warning, this could overflow user's buffer!!! + + if ( DEBUG_BUILD && !ValidHFSRecord(data, btcb, *dataSize) ) +- DebugStr("\pGetBTreeRecord: bad record?"); ++ DebugStr("GetBTreeRecord: bad record?"); + + } + +@@ -243,7 +243,7 @@ OSErr InsertBTreeRecord(SFCB *fcb, const void* key, const void* data, UInt16 dat + CopyMemory(key, &iterator.key, CalcKeySize(btcb, (BTreeKey *) key)); // should we range check against maxkeylen? + + if ( DEBUG_BUILD && !ValidHFSRecord(data, btcb, dataSize) ) +- DebugStr("\pInsertBTreeRecord: bad record?"); ++ DebugStr("InsertBTreeRecord: bad record?"); + + result = BTInsertRecord( fcb, &iterator, &btRecord, dataSize ); + +@@ -305,7 +305,7 @@ OSErr ReplaceBTreeRecord(SFCB *fcb, const void* key, UInt32 hint, void *newData, + CopyMemory(key, &iterator.key, CalcKeySize(btcb, (BTreeKey *) key)); // should we range check against maxkeylen? + + if ( DEBUG_BUILD && !ValidHFSRecord(newData, btcb, dataSize) ) +- DebugStr("\pReplaceBTreeRecord: bad record?"); ++ DebugStr("ReplaceBTreeRecord: bad record?"); + + result = BTReplaceRecord( fcb, &iterator, &btRecord, dataSize ); + +@@ -344,7 +344,7 @@ SetEndOfForkProc ( SFCB *filePtr, FSSize minEOF, FSSize maxEOF ) + else + { + if ( DEBUG_BUILD ) +- DebugStr("\pSetEndOfForkProc: minEOF is smaller than current size!"); ++ DebugStr("SetEndOfForkProc: minEOF is smaller than current size!"); + return -1; + } + +@@ -370,7 +370,7 @@ SetEndOfForkProc ( SFCB *filePtr, FSSize minEOF, FSSize maxEOF ) + // Make sure we got at least as much space as we needed + // + if (filePtr->fcbLogicalSize < minEOF) { +- Panic("\pSetEndOfForkProc: disk too full to extend B-tree file"); ++ Panic("SetEndOfForkProc: disk too full to extend B-tree file"); + return dskFulErr; + } + +@@ -442,7 +442,7 @@ static OSErr CheckBTreeKey(const BTreeKey *key, const BTreeControlBlock *btcb) + if ( (keyLen < 6) || (keyLen > btcb->maxKeyLength) ) + { + if ( DEBUG_BUILD ) +- DebugStr("\pCheckBTreeKey: bad key length!"); ++ DebugStr("CheckBTreeKey: bad key length!"); + return fsBTInvalidKeyLengthErr; + } + diff --git a/utils/hfsprogs/patches/0006-Adjust-types-for-printing.patch b/utils/hfsprogs/patches/0006-Adjust-types-for-printing.patch new file mode 100644 index 000000000..09efbb6ef --- /dev/null +++ b/utils/hfsprogs/patches/0006-Adjust-types-for-printing.patch @@ -0,0 +1,37 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Adjust types for printing + +Try to address the issues of a given integral type having different sizes +in 32 and 64-bit architectures. +--- + fsck_hfs.tproj/dfalib/SControl.c | 2 +- + fsck_hfs.tproj/dfalib/hfs_endian.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/fsck_hfs.tproj/dfalib/SControl.c b/fsck_hfs.tproj/dfalib/SControl.c +index 4ce9e16..8b03ece 100644 +--- a/fsck_hfs.tproj/dfalib/SControl.c ++++ b/fsck_hfs.tproj/dfalib/SControl.c +@@ -776,7 +776,7 @@ static int ScavSetUp( SGlob *GPtr) + pointer = (ScavStaticStructures *) AllocateClearMemory( sizeof(ScavStaticStructures) ); + if ( pointer == nil ) { + if ( GPtr->logLevel >= kDebugLog ) { +- printf( "\t error %d - could not allocate %ld bytes of memory \n", ++ printf( "\t error %d - could not allocate %i bytes of memory \n", + R_NoMem, sizeof(ScavStaticStructures) ); + } + return( R_NoMem ); +diff --git a/fsck_hfs.tproj/dfalib/hfs_endian.c b/fsck_hfs.tproj/dfalib/hfs_endian.c +index 3cc9eb4..6ca2ac1 100755 +--- a/fsck_hfs.tproj/dfalib/hfs_endian.c ++++ b/fsck_hfs.tproj/dfalib/hfs_endian.c +@@ -563,7 +563,7 @@ hfs_swap_HFSPlusBTInternalNode ( + /* Make sure name length is consistent with key length */ + if (keyLength < sizeof(srcKey->parentID) + sizeof(srcKey->nodeName.length) + + srcKey->nodeName.length*sizeof(srcKey->nodeName.unicode[0])) { +- if (debug) printf("hfs_swap_HFSPlusBTInternalNode: catalog record #%d keyLength=%d expected=%lu\n", ++ if (debug) printf("hfs_swap_HFSPlusBTInternalNode: catalog record #%d keyLength=%d expected=%i\n", + srcDesc->numRecords-i, keyLength, sizeof(srcKey->parentID) + sizeof(srcKey->nodeName.length) + + srcKey->nodeName.length*sizeof(srcKey->nodeName.unicode[0])); + WriteError(fcb->fcbVolume->vcbGPtr, E_KeyLen, fcb->fcbFileID, src->blockNum); diff --git a/utils/hfsprogs/patches/0007-Fix-path-for-HFS-wrapper-block.patch b/utils/hfsprogs/patches/0007-Fix-path-for-HFS-wrapper-block.patch new file mode 100644 index 000000000..f92bb228a --- /dev/null +++ b/utils/hfsprogs/patches/0007-Fix-path-for-HFS-wrapper-block.patch @@ -0,0 +1,23 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Fix path for HFS wrapper block + +Fix the installation of the HFS wrapper block to be compliant in Linux +systems (since it is arch independent). +--- + newfs_hfs.tproj/makehfs.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/newfs_hfs.tproj/makehfs.c b/newfs_hfs.tproj/makehfs.c +index 7609779..2233ef7 100644 +--- a/newfs_hfs.tproj/makehfs.c ++++ b/newfs_hfs.tproj/makehfs.c +@@ -70,7 +70,7 @@ extern Boolean _CFStringGetFileSystemRepresentation(CFStringRef string, UInt8 *b + #include "readme.h" + + +-#define HFS_BOOT_DATA "/usr/share/misc/hfsbootdata" ++#define HFS_BOOT_DATA "/usr/share/hfsprogs/hfsbootdata" + + #define HFS_JOURNAL_FILE ".journal" + #define HFS_JOURNAL_INFO ".journal_info_block" diff --git a/utils/hfsprogs/patches/0008-Provide-command-line-option-a.patch b/utils/hfsprogs/patches/0008-Provide-command-line-option-a.patch new file mode 100644 index 000000000..366dbbc0d --- /dev/null +++ b/utils/hfsprogs/patches/0008-Provide-command-line-option-a.patch @@ -0,0 +1,40 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Provide command line option -a + +Create a new command line option (-a) for the fsck.hfsplus that has the same +behavior that the -p option has, for greater compatibility with other tools. +--- + fsck_hfs.tproj/fsck_hfs.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/fsck_hfs.tproj/fsck_hfs.c b/fsck_hfs.tproj/fsck_hfs.c +index f1a18bd..6117698 100644 +--- a/fsck_hfs.tproj/fsck_hfs.c ++++ b/fsck_hfs.tproj/fsck_hfs.c +@@ -104,7 +104,7 @@ main(argc, argv) + else + progname = *argv; + +- while ((ch = getopt(argc, argv, "c:D:dfglm:npqruy")) != EOF) { ++ while ((ch = getopt(argc, argv, "c:D:dfglm:napqruy")) != EOF) { + switch (ch) { + case 'c': + /* Cache size to use in fsck_hfs */ +@@ -169,6 +169,7 @@ main(argc, argv) + yflag = 0; + break; + ++ case 'a': + case 'p': + preen++; + break; +@@ -572,7 +573,7 @@ usage() + (void) fprintf(stderr, " l = live fsck (lock down and test-only)\n"); + (void) fprintf(stderr, " m arg = octal mode used when creating lost+found directory \n"); + (void) fprintf(stderr, " n = assume a no response \n"); +- (void) fprintf(stderr, " p = just fix normal inconsistencies \n"); ++ (void) fprintf(stderr, " p, a = just fix normal inconsistencies \n"); + (void) fprintf(stderr, " q = quick check returns clean, dirty, or failure \n"); + (void) fprintf(stderr, " r = rebuild catalog btree \n"); + (void) fprintf(stderr, " u = usage \n"); diff --git a/utils/hfsprogs/patches/0009-Rename-dprintf-to-dbg_printf.patch b/utils/hfsprogs/patches/0009-Rename-dprintf-to-dbg_printf.patch new file mode 100644 index 000000000..23f85183c --- /dev/null +++ b/utils/hfsprogs/patches/0009-Rename-dprintf-to-dbg_printf.patch @@ -0,0 +1,187 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Rename dprintf to dbg_printf + +--- + fsck_hfs.tproj/dfalib/SRepair.c | 18 +++++++++--------- + fsck_hfs.tproj/dfalib/SVerify1.c | 6 +++--- + fsck_hfs.tproj/fsck_debug.c | 10 +++++----- + fsck_hfs.tproj/fsck_debug.h | 10 +++++----- + 4 files changed, 22 insertions(+), 22 deletions(-) + +diff --git a/fsck_hfs.tproj/dfalib/SRepair.c b/fsck_hfs.tproj/dfalib/SRepair.c +index 8eb759c..89c12d6 100644 +--- a/fsck_hfs.tproj/dfalib/SRepair.c ++++ b/fsck_hfs.tproj/dfalib/SRepair.c +@@ -1825,13 +1825,13 @@ static OSErr FixAttrSize(SGlobPtr GPtr, RepairOrderPtr p) + result = BTSearchRecord(GPtr->calculatedAttributesFCB, &iterator, + kInvalidMRUCacheKey, &btRecord, &recSize, &iterator); + if (result) { +- dprintf (d_error|d_xattr, "%s: Cannot find attribute record (err = %d)\n", __FUNCTION__, result); ++ dbg_printf (d_error|d_xattr, "%s: Cannot find attribute record (err = %d)\n", __FUNCTION__, result); + goto out; + } + + /* We should only get record of type kHFSPlusAttrForkData */ + if (record.recordType != kHFSPlusAttrForkData) { +- dprintf (d_error|d_xattr, "%s: Record found is not attribute fork data\n", __FUNCTION__); ++ dbg_printf (d_error|d_xattr, "%s: Record found is not attribute fork data\n", __FUNCTION__); + result = btNotFound; + goto out; + } +@@ -1862,7 +1862,7 @@ static OSErr FixAttrSize(SGlobPtr GPtr, RepairOrderPtr p) + result = BTReplaceRecord(GPtr->calculatedAttributesFCB, &iterator, + &btRecord, recSize); + if (result) { +- dprintf (d_error|d_xattr, "%s: Cannot replace attribute record (err=%d)\n", __FUNCTION__, result); ++ dbg_printf (d_error|d_xattr, "%s: Cannot replace attribute record (err=%d)\n", __FUNCTION__, result); + goto out; + } + } +@@ -2058,7 +2058,7 @@ del_overflow_extents: + + /* Delete the extent record */ + err = DeleteBTreeRecord(GPtr->calculatedExtentsFCB, &extentKey); +- dprintf (d_info, "%s: Deleting extent overflow for fileID=%u, forkType=%u, startBlock=%u\n", __FUNCTION__, fileID, forkType, foundStartBlock); ++ dbg_printf (d_info, "%s: Deleting extent overflow for fileID=%u, forkType=%u, startBlock=%u\n", __FUNCTION__, fileID, forkType, foundStartBlock); + if (err) { + goto create_symlink; + } +@@ -3227,12 +3227,12 @@ static OSErr MoveExtent(SGlobPtr GPtr, ExtentInfo *extentInfo) + &extentData, &recordSize, &foundExtentIndex); + foundLocation = extentsBTree; + if (err != noErr) { +- dprintf (d_error|d_overlap, "%s: No matching extent record found in extents btree for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); ++ dbg_printf (d_error|d_overlap, "%s: No matching extent record found in extents btree for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); + goto out; + } + } else { + /* No more extents exist for this file */ +- dprintf (d_error|d_overlap, "%s: No matching extent record found for fileID = %d\n", __FUNCTION__, extentInfo->fileID); ++ dbg_printf (d_error|d_overlap, "%s: No matching extent record found for fileID = %d\n", __FUNCTION__, extentInfo->fileID); + goto out; + } + } +@@ -3241,7 +3241,7 @@ static OSErr MoveExtent(SGlobPtr GPtr, ExtentInfo *extentInfo) + err = CopyDiskBlocks(GPtr, extentInfo->startBlock, extentInfo->blockCount, + extentInfo->newStartBlock); + if (err != noErr) { +- dprintf (d_error|d_overlap, "%s: Error in copying disk blocks for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); ++ dbg_printf (d_error|d_overlap, "%s: Error in copying disk blocks for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); + goto out; + } + +@@ -3260,7 +3260,7 @@ static OSErr MoveExtent(SGlobPtr GPtr, ExtentInfo *extentInfo) + + } + if (err != noErr) { +- dprintf (d_error|d_overlap, "%s: Error in updating extent record for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); ++ dbg_printf (d_error|d_overlap, "%s: Error in updating extent record for fileID = %d (err=%d)\n", __FUNCTION__, extentInfo->fileID, err); + goto out; + } + +@@ -3491,7 +3491,7 @@ static OSErr SearchExtentInAttributeBT(SGlobPtr GPtr, ExtentInfo *extentInfo, + result = BTSearchRecord(GPtr->calculatedAttributesFCB, &iterator, + kInvalidMRUCacheKey, &btRecord, recordSize, &iterator); + if (result) { +- dprintf (d_error|d_overlap, "%s: Error finding attribute record (err=%d) for fileID = %d, attrname = %d\n", __FUNCTION__, result, extentInfo->fileID, extentInfo->attrname); ++ dbg_printf (d_error|d_overlap, "%s: Error finding attribute record (err=%d) for fileID = %d, attrname = %d\n", __FUNCTION__, result, extentInfo->fileID, extentInfo->attrname); + goto out; + } + +diff --git a/fsck_hfs.tproj/dfalib/SVerify1.c b/fsck_hfs.tproj/dfalib/SVerify1.c +index a273bf3..39bda5c 100644 +--- a/fsck_hfs.tproj/dfalib/SVerify1.c ++++ b/fsck_hfs.tproj/dfalib/SVerify1.c +@@ -2157,9 +2157,9 @@ CheckAttributeRecord(SGlobPtr GPtr, const HFSPlusAttrKey *key, const HFSPlusAttr + + if (doDelete == true) { + result = DeleteBTreeRecord(GPtr->calculatedAttributesFCB, key); +- dprintf (d_info|d_xattr, "%s: Deleting attribute %s for fileID %d, type = %d\n", __FUNCTION__, attrname, key->fileID, rec->recordType); ++ dbg_printf (d_info|d_xattr, "%s: Deleting attribute %s for fileID %d, type = %d\n", __FUNCTION__, attrname, key->fileID, rec->recordType); + if (result) { +- dprintf (d_error|d_xattr, "%s: Error in deleting record for %s for fileID %d, type = %d\n", __FUNCTION__, attrname, key->fileID, rec->recordType); ++ dbg_printf (d_error|d_xattr, "%s: Error in deleting record for %s for fileID %d, type = %d\n", __FUNCTION__, attrname, key->fileID, rec->recordType); + } + + /* Set flags to mark header and map dirty */ +@@ -3034,7 +3034,7 @@ OSErr CheckFileExtents( SGlobPtr GPtr, UInt32 fileNumber, UInt8 forkType, + // checkout the extent record first + err = ChkExtRec( GPtr, extents, &lastExtentIndex ); + if (err != noErr) { +- dprintf (d_info, "%s: Bad extent for fileID %u in extent %u for startblock %u\n", __FUNCTION__, fileNumber, lastExtentIndex, blockCount); ++ dbg_printf (d_info, "%s: Bad extent for fileID %u in extent %u for startblock %u\n", __FUNCTION__, fileNumber, lastExtentIndex, blockCount); + + /* Stop verification if bad extent is found for system file or EA */ + if ((fileNumber < kHFSFirstUserCatalogNodeID) || +diff --git a/fsck_hfs.tproj/fsck_debug.c b/fsck_hfs.tproj/fsck_debug.c +index 1be3fc5..77e8e51 100644 +--- a/fsck_hfs.tproj/fsck_debug.c ++++ b/fsck_hfs.tproj/fsck_debug.c +@@ -25,18 +25,18 @@ + #include + #include + +-/* Current debug level of fsck_hfs for printing messages via dprintf */ ++/* Current debug level of fsck_hfs for printing messages via dbg_printf */ + unsigned long cur_debug_level; + +-/* Function: dprintf ++/* Function: dbg_printf + * + * Description: Debug function similar to printf except the first parameter +- * which indicates the type of message to be printed by dprintf. Based on ++ * which indicates the type of message to be printed by dbg_printf. Based on + * current debug level and the type of message, the function decides + * whether to print the message or not. + * + * Each unique message type has a bit assigned to it. The message type +- * passed to dprintf can be one or combination (OR-ed value) of pre-defined ++ * passed to dbg_printf can be one or combination (OR-ed value) of pre-defined + * debug message types. Only the messages whose type have one or more similar + * bits set in comparison with current global debug level are printed. + * +@@ -56,7 +56,7 @@ unsigned long cur_debug_level; + * Output: + * Nothing + */ +-void dprintf (unsigned long type, char *fmt, ...) ++void dbg_printf (unsigned long type, char *fmt, ...) + { + if (cur_debug_level & type) { + va_list ap; +diff --git a/fsck_hfs.tproj/fsck_debug.h b/fsck_hfs.tproj/fsck_debug.h +index 81e3932..cb1b9be 100644 +--- a/fsck_hfs.tproj/fsck_debug.h ++++ b/fsck_hfs.tproj/fsck_debug.h +@@ -36,18 +36,18 @@ enum debug_message_type { + d_overlap = 0x0020 /* Overlap extents related messages */ + }; + +-/* Current debug level of fsck_hfs for printing messages via dprintf */ ++/* Current debug level of fsck_hfs for printing messages via dbg_printf */ + extern unsigned long cur_debug_level; + +-/* Function: dprintf ++/* Function: dbg_printf + * + * Description: Debug function similar to printf except the first parameter +- * which indicates the type of message to be printed by dprintf. Based on ++ * which indicates the type of message to be printed by dbg_printf. Based on + * current debug level and the type of message, the function decides + * whether to print the message or not. + * + * Each unique message type has a bit assigned to it. The message type +- * passed to dprintf can be one or combination (OR-ed value) of pre-defined ++ * passed to dbg_printf can be one or combination (OR-ed value) of pre-defined + * debug message types. Only the messages whose type have one or more similar + * bits set in comparison with current global debug level are printed. + * +@@ -67,6 +67,6 @@ extern unsigned long cur_debug_level; + * Output: + * Nothing + */ +-extern void dprintf (unsigned long message_type, char *format, ...); ++extern void dbg_printf (unsigned long message_type, char *format, ...); + + #endif /* __FSCK_DEBUG__ */ diff --git a/utils/hfsprogs/patches/0010-Rename-custom-macro-nil-with-NULL.patch b/utils/hfsprogs/patches/0010-Rename-custom-macro-nil-with-NULL.patch new file mode 100644 index 000000000..354b4ffc0 --- /dev/null +++ b/utils/hfsprogs/patches/0010-Rename-custom-macro-nil-with-NULL.patch @@ -0,0 +1,1319 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:21 -0200 +Subject: Rename custom macro nil with NULL + +--- + fsck_hfs.tproj/dfalib/BTree.c | 142 +++++++++++++++++----------------- + fsck_hfs.tproj/dfalib/BTreeAllocate.c | 14 ++-- + fsck_hfs.tproj/dfalib/BTreeMiscOps.c | 26 +++---- + fsck_hfs.tproj/dfalib/BTreeNodeOps.c | 30 +++---- + fsck_hfs.tproj/dfalib/BTreeTreeOps.c | 38 ++++----- + fsck_hfs.tproj/dfalib/SControl.c | 56 +++++++------- + fsck_hfs.tproj/dfalib/SRepair.c | 6 +- + fsck_hfs.tproj/dfalib/SUtils.c | 6 +- + fsck_hfs.tproj/dfalib/SVerify1.c | 32 ++++---- + fsck_hfs.tproj/dfalib/SVerify2.c | 4 +- + 10 files changed, 177 insertions(+), 177 deletions(-) + +diff --git a/fsck_hfs.tproj/dfalib/BTree.c b/fsck_hfs.tproj/dfalib/BTree.c +index 7ad9fe0..c0c8744 100644 +--- a/fsck_hfs.tproj/dfalib/BTree.c ++++ b/fsck_hfs.tproj/dfalib/BTree.c +@@ -163,21 +163,21 @@ OSStatus BTInitialize (FCB *filePtr, + + ////////////////////// Preliminary Error Checking /////////////////////////// + +- headerNode.buffer = nil; ++ headerNode.buffer = NULL; + +- if (pathPtr == nil) return paramErr; ++ if (pathPtr == NULL) return paramErr; + + setEndOfForkProc = pathPtr->agentPtr->agent.setEndOfForkProc; + setBlockSizeProc = pathPtr->agentPtr->agent.setBlockSizeProc; + +- if (pathPtr->agentPtr->agent.getBlockProc == nil) return E_NoGetBlockProc; +- if (pathPtr->agentPtr->agent.releaseBlockProc == nil) return E_NoReleaseBlockProc; +- if (setEndOfForkProc == nil) return E_NoSetEndOfForkProc; +- if (setBlockSizeProc == nil) return E_NoSetBlockSizeProc; ++ if (pathPtr->agentPtr->agent.getBlockProc == NULL) return E_NoGetBlockProc; ++ if (pathPtr->agentPtr->agent.releaseBlockProc == NULL) return E_NoReleaseBlockProc; ++ if (setEndOfForkProc == NULL) return E_NoSetEndOfForkProc; ++ if (setBlockSizeProc == NULL) return E_NoSetBlockSizeProc; + + forkPtr = pathPtr->path.forkPtr; + +- if (forkPtr->fork.btreePtr != nil) return fsBTrFileAlreadyOpenErr; ++ if (forkPtr->fork.btreePtr != NULL) return fsBTrFileAlreadyOpenErr; + + if ((maxKeyLength == 0) || + (maxKeyLength > kMaxKeyLength)) return fsBTInvalidKeyLengthErr; +@@ -209,7 +209,7 @@ OSStatus BTInitialize (FCB *filePtr, + //////////////////////// Allocate Control Block ///////////////////////////// + + M_RESIDENT_ALLOCATE_FIXED_CLEAR( &btreePtr, sizeof( BTreeControlBlock ), kFSBTreeControlBlockType ); +- if (btreePtr == nil) ++ if (btreePtr == NULL) + { + err = memFullErr; + goto ErrorExit; +@@ -220,7 +220,7 @@ OSStatus BTInitialize (FCB *filePtr, + btreePtr->flags = 0; + btreePtr->attributes = 0; + btreePtr->forkPtr = forkPtr; +- btreePtr->keyCompareProc = nil; ++ btreePtr->keyCompareProc = NULL; + btreePtr->keyDescPtr = keyDescPtr; + btreePtr->btreeType = btreeType; + btreePtr->treeDepth = 0; +@@ -282,7 +282,7 @@ OSStatus BTInitialize (FCB *filePtr, + + ///////////////////// Copy Key Descriptor To Header ///////////////////////// + #if SupportsKeyDescriptors +- if (keyDescPtr != nil) ++ if (keyDescPtr != NULL) + { + err = CheckKeyDescriptor (keyDescPtr, maxKeyLength); + M_ExitOnError (err); +@@ -309,7 +309,7 @@ OSStatus BTInitialize (FCB *filePtr, + err = UpdateHeader (btreePtr); + M_ExitOnError (err); + +- pathPtr->path.forkPtr->fork.btreePtr = nil; ++ pathPtr->path.forkPtr->fork.btreePtr = NULL; + M_RESIDENT_DEALLOCATE_FIXED( btreePtr, sizeof( BTreeControlBlock ), kFSBTreeControlBlockType ); + + return noErr; +@@ -320,7 +320,7 @@ OSStatus BTInitialize (FCB *filePtr, + ErrorExit: + + (void) ReleaseNode (btreePtr, &headerNode); +- if (btreePtr != nil) ++ if (btreePtr != NULL) + M_RESIDENT_DEALLOCATE_FIXED( btreePtr, sizeof( BTreeControlBlock ), kFSBTreeControlBlockType ); + + return err; +@@ -342,7 +342,7 @@ Input: filePtr - pointer to file to open as a B-tree + setEndOfForkProc - pointer to client's SetEOF function + + Result: noErr - success +- paramErr - required ptr was nil ++ paramErr - required ptr was NULL + fsBTInvalidFileErr - + memFullErr - + != noErr - failure +@@ -364,16 +364,16 @@ OSStatus BTOpenPath (SFCB *filePtr, + + ////////////////////// Preliminary Error Checking /////////////////////////// + +- if ( filePtr == nil || +- getBlockProc == nil || +- releaseBlockProc == nil || +- setEndOfForkProc == nil || +- setBlockSizeProc == nil ) ++ if (filePtr == NULL || ++ getBlockProc == NULL || ++ releaseBlockProc == NULL || ++ setEndOfForkProc == NULL || ++ setBlockSizeProc == NULL) + { + return paramErr; + } + +- if ( filePtr->fcbBtree != nil ) // already has a BTreeCB ++ if (filePtr->fcbBtree != NULL) // already has a BTreeCB + return noErr; + + // is file large enough to contain header node? +@@ -384,7 +384,7 @@ OSStatus BTOpenPath (SFCB *filePtr, + //////////////////////// Allocate Control Block ///////////////////////////// + + btreePtr = (BTreeControlBlock*) AllocateClearMemory( sizeof( BTreeControlBlock ) ); +- if (btreePtr == nil) ++ if (btreePtr == NULL) + { + Panic ("\pBTOpen: no memory for btreePtr."); + return memFullErr; +@@ -397,7 +397,7 @@ OSStatus BTOpenPath (SFCB *filePtr, + + /////////////////////////// Read Header Node //////////////////////////////// + +- nodeRec.buffer = nil; // so we can call ReleaseNode ++ nodeRec.buffer = NULL; // so we can call ReleaseNode + + btreePtr->fcbPtr = filePtr; + filePtr->fcbBtree = (void *) btreePtr; // attach btree cb to file +@@ -487,7 +487,7 @@ OSStatus BTOpenPath (SFCB *filePtr, + + ////////////////////////// Get Key Descriptor /////////////////////////////// + #if SupportsKeyDescriptors +- if ( keyCompareProc == nil ) // if no key compare proc then get key descriptor ++ if (keyCompareProc == NULL) // if no key compare proc then get key descriptor + { + err = GetKeyDescriptor (btreePtr, nodeRec.buffer); // it should check amount of memory allocated... + M_ExitOnError (err); +@@ -499,7 +499,7 @@ OSStatus BTOpenPath (SFCB *filePtr, + else + #endif + { +- btreePtr->keyDescPtr = nil; // clear it so we don't dispose garbage later ++ btreePtr->keyDescPtr = NULL; // clear it so we don't dispose garbage later + } + + err = ReleaseNode (btreePtr, &nodeRec); +@@ -528,7 +528,7 @@ OSStatus BTOpenPath (SFCB *filePtr, + + ErrorExit: + +- filePtr->fcbBtree = nil; ++ filePtr->fcbBtree = NULL; + (void) ReleaseNode (btreePtr, &nodeRec); + DisposeMemory( btreePtr ); + +@@ -567,7 +567,7 @@ OSStatus BTClosePath (SFCB *filePtr) + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; + +- if (btreePtr == nil) ++ if (btreePtr == NULL) + return fsBTInvalidFileErr; + + ////////////////////// Check for other BTree Paths ////////////////////////// +@@ -603,14 +603,14 @@ OSStatus BTClosePath (SFCB *filePtr) + M_ExitOnError (err); + + #if SupportsKeyDescriptors +- if (btreePtr->keyDescPtr != nil) // deallocate keyDescriptor, if any ++ if (btreePtr->keyDescPtr != NULL) // deallocate keyDescriptor, if any + { + DisposeMemory( btreePtr->keyDescPtr ); + } + #endif + + DisposeMemory( btreePtr ); +- filePtr->fcbBtree = nil; ++ filePtr->fcbBtree = NULL; + + // LogEndTime(kTraceCloseBTree, noErr); + +@@ -643,7 +643,7 @@ Function: Search for position in B*Tree indicated by searchKey. If a valid node + + Input: pathPtr - pointer to path for BTree file. + searchKey - pointer to search key to match. +- hintPtr - pointer to hint (may be nil) ++ hintPtr - pointer to hint (may be NULL) + + Output: record - pointer to BufferDescriptor containing record + recordLen - length of data at recordPtr +@@ -678,14 +678,14 @@ OSStatus BTSearchRecord (SFCB *filePtr, + + // LogStartTime(kTraceSearchBTree); + +- if (filePtr == nil) return paramErr; +- if (searchIterator == nil) return paramErr; ++ if (filePtr == NULL) return paramErr; ++ if (searchIterator == NULL) return paramErr; + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; +- if (btreePtr == nil) return fsBTInvalidFileErr; ++ if (btreePtr == NULL) return fsBTInvalidFileErr; + + #if SupportsKeyDescriptors +- if (btreePtr->keyCompareProc == nil) // CheckKey if we using Key Descriptor ++ if (btreePtr->keyCompareProc == NULL) // CheckKey if we using Key Descriptor + { + err = CheckKey (&searchIterator->key, btreePtr->keyDescPtr, btreePtr->maxKeyLength); + M_ExitOnError (err); +@@ -775,9 +775,9 @@ OSStatus BTSearchRecord (SFCB *filePtr, + // Should check for errors! Or BlockMove could choke on recordPtr!!! + GetRecordByIndex (btreePtr, node.buffer, index, &keyPtr, &recordPtr, &len); + +- if (recordLen != nil) *recordLen = len; ++ if (recordLen != NULL) *recordLen = len; + +- if (record != nil) ++ if (record != NULL) + { + ByteCount recordSize; + +@@ -794,7 +794,7 @@ OSStatus BTSearchRecord (SFCB *filePtr, + + /////////////////////// Success - Update Iterator /////////////////////////// + +- if (resultIterator != nil) ++ if (resultIterator != NULL) + { + resultIterator->hint.writeCount = btreePtr->writeCount; + resultIterator->hint.nodeNum = nodeNum; +@@ -825,10 +825,10 @@ OSStatus BTSearchRecord (SFCB *filePtr, + + ErrorExit: + +- if (recordLen != nil) ++ if (recordLen != NULL) + *recordLen = 0; + +- if (resultIterator != nil) ++ if (resultIterator != NULL) + { + resultIterator->hint.writeCount = 0; + resultIterator->hint.nodeNum = 0; +@@ -892,18 +892,18 @@ OSStatus BTIterateRecord (SFCB *filePtr, + + ////////////////////////// Priliminary Checks /////////////////////////////// + +- left.buffer = nil; +- right.buffer = nil; +- node.buffer = nil; ++ left.buffer = NULL; ++ right.buffer = NULL; ++ node.buffer = NULL; + + +- if (filePtr == nil) ++ if (filePtr == NULL) + { + return paramErr; + } + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; +- if (btreePtr == nil) ++ if (btreePtr == NULL) + { + return fsBTInvalidFileErr; // handle properly + } +@@ -968,7 +968,7 @@ OSStatus BTIterateRecord (SFCB *filePtr, + } + else + { +- if (left.buffer == nil) ++ if (left.buffer == NULL) + { + nodeNum = ((NodeDescPtr) node.buffer)->bLink; + if ( nodeNum > 0) +@@ -981,13 +981,13 @@ OSStatus BTIterateRecord (SFCB *filePtr, + } + } + // Before we stomp on "right", we'd better release it if needed +- if (right.buffer != nil) { ++ if (right.buffer != NULL) { + err = ReleaseNode(btreePtr, &right); + M_ExitOnError(err); + } + right = node; + node = left; +- left.buffer = nil; ++ left.buffer = NULL; + index = ((NodeDescPtr) node.buffer)->numRecords -1; + } + } +@@ -1012,7 +1012,7 @@ OSStatus BTIterateRecord (SFCB *filePtr, + } + else + { +- if (right.buffer == nil) ++ if (right.buffer == NULL) + { + nodeNum = ((NodeDescPtr) node.buffer)->fLink; + if ( nodeNum > 0) +@@ -1025,13 +1025,13 @@ OSStatus BTIterateRecord (SFCB *filePtr, + } + } + // Before we stomp on "left", we'd better release it if needed +- if (left.buffer != nil) { ++ if (left.buffer != NULL) { + err = ReleaseNode(btreePtr, &left); + M_ExitOnError(err); + } + left = node; + node = right; +- right.buffer = nil; ++ right.buffer = NULL; + index = 0; + } + } +@@ -1054,9 +1054,9 @@ CopyData: + err = GetRecordByIndex (btreePtr, node.buffer, index, &keyPtr, &recordPtr, &len); + M_ExitOnError (err); + +- if (recordLen != nil) *recordLen = len; ++ if (recordLen != NULL) *recordLen = len; + +- if (record != nil) ++ if (record != NULL) + { + ByteCount recordSize; + +@@ -1069,7 +1069,7 @@ CopyData: + CopyMemory (recordPtr, record->bufferAddress, len); + } + +- if (iterator != nil) // first & last do not require iterator ++ if (iterator != NULL) // first & last do not require iterator + { + iterator->hint.writeCount = btreePtr->writeCount; + iterator->hint.nodeNum = nodeNum; +@@ -1089,13 +1089,13 @@ CopyData: + err = ReleaseNode (btreePtr, &node); + M_ExitOnError (err); + +- if (left.buffer != nil) ++ if (left.buffer != NULL) + { + err = ReleaseNode (btreePtr, &left); + M_ExitOnError (err); + } + +- if (right.buffer != nil) ++ if (right.buffer != NULL) + { + err = ReleaseNode (btreePtr, &right); + M_ExitOnError (err); +@@ -1113,10 +1113,10 @@ ErrorExit: + (void) ReleaseNode (btreePtr, &node); + (void) ReleaseNode (btreePtr, &right); + +- if (recordLen != nil) ++ if (recordLen != NULL) + *recordLen = 0; + +- if (iterator != nil) ++ if (iterator != NULL) + { + iterator->hint.writeCount = 0; + iterator->hint.nodeNum = 0; +@@ -1157,7 +1157,7 @@ OSStatus BTInsertRecord (SFCB *filePtr, + + ////////////////////////// Priliminary Checks /////////////////////////////// + +- nodeRec.buffer = nil; // so we can call ReleaseNode ++ nodeRec.buffer = NULL; // so we can call ReleaseNode + + err = CheckInsertParams (filePtr, iterator, record, recordLen); + if (err != noErr) +@@ -1317,7 +1317,7 @@ OSStatus BTSetRecord (SFCB *filePtr, + + ////////////////////////// Priliminary Checks /////////////////////////////// + +- nodeRec.buffer = nil; // so we can call ReleaseNode ++ nodeRec.buffer = NULL; // so we can call ReleaseNode + + err = CheckInsertParams (filePtr, iterator, record, recordLen); + if (err != noErr) +@@ -1506,7 +1506,7 @@ OSStatus BTReplaceRecord (SFCB *filePtr, + + ////////////////////////// Priliminary Checks /////////////////////////////// + +- nodeRec.buffer = nil; // so we can call ReleaseNode ++ nodeRec.buffer = NULL; // so we can call ReleaseNode + + err = CheckInsertParams (filePtr, iterator, record, recordLen); + if (err != noErr) +@@ -1645,20 +1645,20 @@ OSStatus BTDeleteRecord (SFCB *filePtr, + + ////////////////////////// Priliminary Checks /////////////////////////////// + +- nodeRec.buffer = nil; // so we can call ReleaseNode ++ nodeRec.buffer = NULL; // so we can call ReleaseNode + +- M_ReturnErrorIf (filePtr == nil, paramErr); +- M_ReturnErrorIf (iterator == nil, paramErr); ++ M_ReturnErrorIf (filePtr == NULL, paramErr); ++ M_ReturnErrorIf (iterator == NULL, paramErr); + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; +- if (btreePtr == nil) ++ if (btreePtr == NULL) + { + err = fsBTInvalidFileErr; + goto ErrorExit; + } + + #if SupportsKeyDescriptors +- if (btreePtr->keyDescPtr != nil) ++ if (btreePtr->keyDescPtr != NULL) + { + err = CheckKey (&iterator->key, btreePtr->keyDescPtr, btreePtr->maxKeyLength); + M_ExitOnError (err); +@@ -1712,12 +1712,12 @@ OSStatus BTGetInformation (SFCB *filePtr, + BTreeControlBlockPtr btreePtr; + + +- M_ReturnErrorIf (filePtr == nil, paramErr); ++ M_ReturnErrorIf (filePtr == NULL, paramErr); + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; + +- M_ReturnErrorIf (btreePtr == nil, fsBTInvalidFileErr); +- M_ReturnErrorIf (info == nil, paramErr); ++ M_ReturnErrorIf (btreePtr == NULL, fsBTInvalidFileErr); ++ M_ReturnErrorIf (info == NULL, paramErr); + + // check version? + +@@ -1730,7 +1730,7 @@ OSStatus BTGetInformation (SFCB *filePtr, + info->keyDescriptor = btreePtr->keyDescPtr; // this won't do at all... + info->reserved = 0; + +- if (btreePtr->keyDescPtr == nil) ++ if (btreePtr->keyDescPtr == NULL) + info->keyDescLength = 0; + else + info->keyDescLength = (UInt32) btreePtr->keyDescPtr->length; +@@ -1762,11 +1762,11 @@ OSStatus BTFlushPath (SFCB *filePtr) + + // LogStartTime(kTraceFlushBTree); + +- M_ReturnErrorIf (filePtr == nil, paramErr); ++ M_ReturnErrorIf (filePtr == NULL, paramErr); + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; + +- M_ReturnErrorIf (btreePtr == nil, fsBTInvalidFileErr); ++ M_ReturnErrorIf (btreePtr == NULL, fsBTInvalidFileErr); + + err = UpdateHeader (btreePtr); + +@@ -1788,13 +1788,13 @@ Input: iterator - pointer to BTreeIterator + Output: iterator - iterator with the hint.nodeNum cleared + + Result: noErr - success +- paramErr - iterator == nil ++ paramErr - iterator == NULL + -------------------------------------------------------------------------------*/ + + + OSStatus BTInvalidateHint (BTreeIterator *iterator ) + { +- if (iterator == nil) ++ if (iterator == NULL) + return paramErr; + + iterator->hint.nodeNum = 0; +diff --git a/fsck_hfs.tproj/dfalib/BTreeAllocate.c b/fsck_hfs.tproj/dfalib/BTreeAllocate.c +index 485d867..02bdd8d 100644 +--- a/fsck_hfs.tproj/dfalib/BTreeAllocate.c ++++ b/fsck_hfs.tproj/dfalib/BTreeAllocate.c +@@ -83,7 +83,7 @@ OSStatus AllocateNode (BTreeControlBlockPtr btreePtr, UInt32 *nodeNum) + + + nodeNumber = 0; // first node number of header map record +- node.buffer = nil; // clear node.buffer to get header node ++ node.buffer = NULL; // clear node.buffer to get header node + // - and for ErrorExit + + while (true) +@@ -192,7 +192,7 @@ OSStatus FreeNode (BTreeControlBlockPtr btreePtr, UInt32 nodeNum) + + //////////////////////////// Find Map Record //////////////////////////////// + nodeIndex = 0; // first node number of header map record +- node.buffer = nil; // invalidate node.buffer to get header node ++ node.buffer = NULL; // invalidate node.buffer to get header node + + while (nodeNum >= nodeIndex) + { +@@ -278,8 +278,8 @@ OSStatus ExtendBTree (BTreeControlBlockPtr btreePtr, + nodeSize = btreePtr->nodeSize; + filePtr = btreePtr->fcbPtr; + +- mapNode.buffer = nil; +- newNode.buffer = nil; ++ mapNode.buffer = NULL; ++ newNode.buffer = NULL; + + mapNodeRecSize = nodeSize - sizeof(BTNodeDescriptor) - 6; // 2 bytes of free space (see note) + +@@ -448,7 +448,7 @@ ErrorExit: + Routine: GetMapNode - Get the next map node and pointer to the map record. + + Function: Given a BlockDescriptor to a map node in nodePtr, GetMapNode releases +- it and gets the next node. If nodePtr->buffer is nil, then the header ++ it and gets the next node. If nodePtr->buffer is NULL, then the header + node is retrieved. + + +@@ -474,7 +474,7 @@ OSStatus GetMapNode (BTreeControlBlockPtr btreePtr, + UInt16 mapIndex; + UInt32 nextNodeNum; + +- if (nodePtr->buffer != nil) // if iterator is valid... ++ if (nodePtr->buffer != NULL) // if iterator is valid... + { + nextNodeNum = ((NodeDescPtr)nodePtr->buffer)->fLink; + if (nextNodeNum == 0) +@@ -521,7 +521,7 @@ ErrorExit: + + (void) ReleaseNode (btreePtr, nodePtr); + +- *mapPtr = nil; ++ *mapPtr = NULL; + *mapSize = 0; + + return err; +diff --git a/fsck_hfs.tproj/dfalib/BTreeMiscOps.c b/fsck_hfs.tproj/dfalib/BTreeMiscOps.c +index 7c9edca..997f34b 100644 +--- a/fsck_hfs.tproj/dfalib/BTreeMiscOps.c ++++ b/fsck_hfs.tproj/dfalib/BTreeMiscOps.c +@@ -236,13 +236,13 @@ OSStatus FindIteratorPosition (BTreeControlBlockPtr btreePtr, + // assume index points to UInt16 + // assume foundRecord points to Boolean + +- left->buffer = nil; +- middle->buffer = nil; +- right->buffer = nil; ++ left->buffer = NULL; ++ middle->buffer = NULL; ++ right->buffer = NULL; + + foundIt = false; + +- if (iterator == nil) // do we have an iterator? ++ if (iterator == NULL) // do we have an iterator? + { + err = fsBTInvalidIteratorErr; + goto ErrorExit; +@@ -250,7 +250,7 @@ OSStatus FindIteratorPosition (BTreeControlBlockPtr btreePtr, + + #if SupportsKeyDescriptors + // verify iterator key (change CheckKey to take btreePtr instead of keyDescPtr?) +- if (btreePtr->keyDescPtr != nil) ++ if (btreePtr->keyDescPtr != NULL) + { + err = CheckKey (&iterator->key, btreePtr->keyDescPtr, btreePtr->maxKeyLength ); + M_ExitOnError (err); +@@ -309,7 +309,7 @@ OSStatus FindIteratorPosition (BTreeControlBlockPtr btreePtr, + { + *right = *middle; + *middle = *left; +- left->buffer = nil; ++ left->buffer = NULL; + index = leftIndex; + + goto SuccessfulExit; +@@ -330,7 +330,7 @@ OSStatus FindIteratorPosition (BTreeControlBlockPtr btreePtr, + { + *right = *middle; + *middle = *left; +- left->buffer = nil; ++ left->buffer = NULL; + index = leftIndex; + + goto SuccessfulExit; +@@ -363,7 +363,7 @@ OSStatus FindIteratorPosition (BTreeControlBlockPtr btreePtr, + { + *left = *middle; + *middle = *right; +- right->buffer = nil; ++ right->buffer = NULL; + index = rightIndex; + + goto SuccessfulExit; +@@ -427,15 +427,15 @@ OSStatus CheckInsertParams (SFCB *filePtr, + { + BTreeControlBlockPtr btreePtr; + +- if (filePtr == nil) return paramErr; ++ if (filePtr == NULL) return paramErr; + + btreePtr = (BTreeControlBlockPtr) filePtr->fcbBtree; +- if (btreePtr == nil) return fsBTInvalidFileErr; +- if (iterator == nil) return paramErr; +- if (record == nil) return paramErr; ++ if (btreePtr == NULL) return fsBTInvalidFileErr; ++ if (iterator == NULL) return paramErr; ++ if (record == NULL) return paramErr; + + #if SupportsKeyDescriptors +- if (btreePtr->keyDescPtr != nil) ++ if (btreePtr->keyDescPtr != NULL) + { + OSStatus err; + +diff --git a/fsck_hfs.tproj/dfalib/BTreeNodeOps.c b/fsck_hfs.tproj/dfalib/BTreeNodeOps.c +index da07cc7..ef2bd7b 100644 +--- a/fsck_hfs.tproj/dfalib/BTreeNodeOps.c ++++ b/fsck_hfs.tproj/dfalib/BTreeNodeOps.c +@@ -105,7 +105,7 @@ Function: Gets an existing BTree node from FS Agent and verifies it. + Input: btreePtr - pointer to BTree control block + nodeNum - number of node to request + +-Output: nodePtr - pointer to beginning of node (nil if error) ++Output: nodePtr - pointer to beginning of node (NULL if error) + + Result: + noErr - success +@@ -139,7 +139,7 @@ OSStatus GetNode (BTreeControlBlockPtr btreePtr, + if (err != noErr) + { + Panic ("\pGetNode: getNodeProc returned error."); +- nodePtr->buffer = nil; ++ nodePtr->buffer = NULL; + goto ErrorExit; + } + ++btreePtr->numGetNodes; +@@ -156,8 +156,8 @@ OSStatus GetNode (BTreeControlBlockPtr btreePtr, + return noErr; + + ErrorExit: +- nodePtr->buffer = nil; +- nodePtr->blockHeader = nil; ++ nodePtr->buffer = NULL; ++ nodePtr->blockHeader = NULL; + + // LogEndTime(kTraceGetNode, err); + +@@ -176,7 +176,7 @@ Function: Gets a new BTree node from FS Agent and initializes it to an empty + Input: btreePtr - pointer to BTree control block + nodeNum - number of node to request + +-Output: returnNodePtr - pointer to beginning of node (nil if error) ++Output: returnNodePtr - pointer to beginning of node (NULL if error) + + Result: noErr - success + != noErr - failure +@@ -203,7 +203,7 @@ OSStatus GetNewNode (BTreeControlBlockPtr btreePtr, + if (err != noErr) + { + Panic ("\pGetNewNode: getNodeProc returned error."); +- returnNodePtr->buffer = nil; ++ returnNodePtr->buffer = NULL; + return err; + } + ++btreePtr->numGetNewNodes; +@@ -248,7 +248,7 @@ OSStatus ReleaseNode (BTreeControlBlockPtr btreePtr, + + err = noErr; + +- if (nodePtr->buffer != nil) ++ if (nodePtr->buffer != NULL) + { + /* + * The nodes must remain in the cache as big endian! +@@ -267,8 +267,8 @@ OSStatus ReleaseNode (BTreeControlBlockPtr btreePtr, + ++btreePtr->numReleaseNodes; + } + +- nodePtr->buffer = nil; +- nodePtr->blockHeader = nil; ++ nodePtr->buffer = NULL; ++ nodePtr->blockHeader = NULL; + + // LogEndTime(kTraceReleaseNode, err); + +@@ -299,7 +299,7 @@ OSStatus TrashNode (BTreeControlBlockPtr btreePtr, + + err = noErr; + +- if (nodePtr->buffer != nil) ++ if (nodePtr->buffer != NULL) + { + releaseNodeProc = btreePtr->releaseBlockProc; + err = releaseNodeProc (btreePtr->fcbPtr, +@@ -309,8 +309,8 @@ OSStatus TrashNode (BTreeControlBlockPtr btreePtr, + ++btreePtr->numReleaseNodes; + } + +- nodePtr->buffer = nil; +- nodePtr->blockHeader = nil; ++ nodePtr->buffer = NULL; ++ nodePtr->blockHeader = NULL; + + return err; + } +@@ -338,7 +338,7 @@ OSStatus UpdateNode (BTreeControlBlockPtr btreePtr, + + err = noErr; + +- if (nodePtr->buffer != nil) // why call UpdateNode if nil ?!? ++ if (nodePtr->buffer != NULL) // why call UpdateNode if NULL ?!? + { + // LogStartTime(kTraceReleaseNode); + err = hfs_swap_BTNode(nodePtr, btreePtr->fcbPtr, kSwapBTNodeHostToBig); +@@ -358,8 +358,8 @@ OSStatus UpdateNode (BTreeControlBlockPtr btreePtr, + ++btreePtr->numUpdateNodes; + } + +- nodePtr->buffer = nil; +- nodePtr->blockHeader = nil; ++ nodePtr->buffer = NULL; ++ nodePtr->blockHeader = NULL; + + return noErr; + +diff --git a/fsck_hfs.tproj/dfalib/BTreeTreeOps.c b/fsck_hfs.tproj/dfalib/BTreeTreeOps.c +index 37fb170..73e1fda 100644 +--- a/fsck_hfs.tproj/dfalib/BTreeTreeOps.c ++++ b/fsck_hfs.tproj/dfalib/BTreeTreeOps.c +@@ -177,7 +177,7 @@ Output: nodeNum - number of the node containing the key position + + Result: noErr - key found, index is record index + fsBTRecordNotFoundErr - key not found, index is insert index +- fsBTEmptyErr - key not found, return params are nil ++ fsBTEmptyErr - key not found, return params are NULL + otherwise - catastrophic failure (GetNode/ReleaseNode failed) + -------------------------------------------------------------------------------*/ + +@@ -321,8 +321,8 @@ ReleaseAndExit: + ErrorExit: + + *nodeNum = 0; +- nodePtr->buffer = nil; +- nodePtr->blockHeader = nil; ++ nodePtr->buffer = NULL; ++ nodePtr->blockHeader = NULL; + *returnIndex = 0; + + return err; +@@ -354,7 +354,7 @@ OSStatus InsertTree ( BTreeControlBlockPtr btreePtr, + primaryKey.replacingKey = replacingKey; + primaryKey.skipRotate = false; + +- err = InsertLevel (btreePtr, treePathTable, &primaryKey, nil, ++ err = InsertLevel (btreePtr, treePathTable, &primaryKey, NULL, + targetNode, index, level, insertNode ); + + return err; +@@ -385,7 +385,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + #if defined(applec) && !defined(__SC__) + PanicIf ((level == 1) && (((NodeDescPtr)targetNode->buffer)->kind != kBTLeafNode), "\P InsertLevel: non-leaf at level 1! "); + #endif +- siblingNode.buffer = nil; ++ siblingNode.buffer = NULL; + targetNodeNum = treePathTable [level].node; + + insertParent = false; +@@ -420,7 +420,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + + ////// process second insert (if any) ////// + +- if ( secondaryKey != nil ) ++ if (secondaryKey != NULL) + { + Boolean temp; + +@@ -446,7 +446,7 @@ OSStatus InsertLevel (BTreeControlBlockPtr btreePtr, + UInt8 * recPtr; + UInt16 recSize; + +- secondaryKey = nil; ++ secondaryKey = NULL; + + PanicIf ( (level == btreePtr->treeDepth), "InsertLevel: unfinished insert!?"); + +@@ -606,9 +606,9 @@ static OSErr InsertNode (BTreeControlBlockPtr btreePtr, + + if ( leftNodeNum > 0 ) + { +- PanicIf ( siblingNode->buffer != nil, "InsertNode: siblingNode already aquired!"); ++ PanicIf(siblingNode->buffer != NULL, "InsertNode: siblingNode already aquired!"); + +- if ( siblingNode->buffer == nil ) ++ if (siblingNode->buffer == NULL) + { + err = GetNode (btreePtr, leftNodeNum, siblingNode); // will be released by caller or a split below + M_ExitOnError (err); +@@ -703,7 +703,7 @@ OSStatus DeleteTree (BTreeControlBlockPtr btreePtr, + + targetNodeNum = treePathTable[level].node; + targetNodePtr = targetNode->buffer; +- PanicIf (targetNodePtr == nil, "DeleteTree: targetNode has nil buffer!"); ++ PanicIf (targetNodePtr == NULL, "DeleteTree: targetNode has NULL buffer!"); + + DeleteRecord (btreePtr, targetNodePtr, index); + +@@ -766,7 +766,7 @@ OSStatus DeleteTree (BTreeControlBlockPtr btreePtr, + deleteRequired = false; + updateRequired = false; + +- if ( targetNode->buffer == nil ) // then root was freed and the btree is empty ++ if (targetNode->buffer == NULL) // then root was freed and the btree is empty + { + btreePtr->rootNode = 0; + btreePtr->treeDepth = 0; +@@ -1124,7 +1124,7 @@ static OSStatus SplitLeft (BTreeControlBlockPtr btreePtr, + if ( (right->height == 1) && (right->kind != kBTLeafNode) ) + return fsBTInvalidNodeErr; + +- if ( left != nil ) ++ if (left != NULL) + { + if ( left->fLink != rightNodeNum ) + return fsBTInvalidNodeErr; // E_BadSibling ? +@@ -1145,7 +1145,7 @@ static OSStatus SplitLeft (BTreeControlBlockPtr btreePtr, + + /////////////// Update Forward Link In Original Left Node /////////////////// + +- if ( left != nil ) ++ if (left != NULL) + { + left->fLink = newNodeNum; + err = UpdateNode (btreePtr, leftNode); +@@ -1240,8 +1240,8 @@ static OSStatus AddNewRootNode (BTreeControlBlockPtr btreePtr, + Boolean didItFit; + UInt16 keyLength; + +- PanicIf (leftNode == nil, "AddNewRootNode: leftNode == nil"); +- PanicIf (rightNode == nil, "AddNewRootNode: rightNode == nil"); ++ PanicIf (leftNode == NULL, "AddNewRootNode: leftNode == NULL"); ++ PanicIf (rightNode == NULL, "AddNewRootNode: rightNode == NULL"); + + + /////////////////////// Initialize New Root Node //////////////////////////// +@@ -1362,7 +1362,7 @@ static OSStatus SplitRight (BTreeControlBlockPtr btreePtr, + if ( (leftPtr->height == 1) && (leftPtr->kind != kBTLeafNode) ) + return fsBTInvalidNodeErr; + +- if ( rightPtr != nil ) ++ if (rightPtr != NULL) + { + if ( rightPtr->bLink != nodeNum ) + return fsBTInvalidNodeErr; // E_BadSibling ? +@@ -1382,7 +1382,7 @@ static OSStatus SplitRight (BTreeControlBlockPtr btreePtr, + + /////////////// Update backward Link In Original Right Node /////////////////// + +- if ( rightPtr != nil ) ++ if (rightPtr != NULL) + { + rightPtr->bLink = newNodeNum; + err = UpdateNode (btreePtr, rightNodePtr); +@@ -1739,7 +1739,7 @@ static int DoKeyCheck( NodeDescPtr nodeP, BTreeControlBlock *btcb ) + UInt16 keyLength; + KeyPtr keyPtr; + UInt8 *dataPtr; +- KeyPtr prevkeyP = nil; ++ KeyPtr prevkeyP = NULL; + + + if ( nodeP->numRecords == 0 ) +@@ -1766,7 +1766,7 @@ static int DoKeyCheck( NodeDescPtr nodeP, BTreeControlBlock *btcb ) + return( -1 ); + } + +- if ( prevkeyP != nil ) ++ if (prevkeyP != NULL) + { + if ( CompareKeys( (BTreeControlBlockPtr)btcb, prevkeyP, keyPtr ) >= 0 ) + { +diff --git a/fsck_hfs.tproj/dfalib/SControl.c b/fsck_hfs.tproj/dfalib/SControl.c +index 8b03ece..d3145e0 100644 +--- a/fsck_hfs.tproj/dfalib/SControl.c ++++ b/fsck_hfs.tproj/dfalib/SControl.c +@@ -82,7 +82,7 @@ CheckHFS( int fsReadRef, int fsWriteRef, int checkLevel, int repairLevel, + { + SGlob dataArea; // Allocate the scav globals + short temp; +- FileIdentifierTable *fileIdentifierTable = nil; ++ FileIdentifierTable *fileIdentifierTable = NULL; + OSErr err = noErr; + OSErr scavError = 0; + int scanCount = 0; +@@ -228,7 +228,7 @@ DoAgain: + } + + // Set up structures for post processing +- if ( (autoRepair == true) && (dataArea.fileIdentifierTable != nil) ) ++ if ((autoRepair == true) && (dataArea.fileIdentifierTable != NULL)) + { + // *repairInfo = *repairInfo | kVolumeHadOverlappingExtents; // Report back that volume has overlapping extents + fileIdentifierTable = (FileIdentifierTable *) AllocateMemory( GetHandleSize( (Handle) dataArea.fileIdentifierTable ) ); +@@ -239,7 +239,7 @@ DoAgain: + // + // Post processing + // +- if ( fileIdentifierTable != nil ) ++ if (fileIdentifierTable != NULL) + { + DisposeMemory( fileIdentifierTable ); + } +@@ -682,7 +682,7 @@ short CheckForStop( SGlob *GPtr ) + + //if ( ((ticks - 10) > GPtr->lastTickCount) || (dfaStage == kAboutToRepairStage) ) // To reduce cursor flicker on fast machines, call through on a timed interval + //{ +- if ( GPtr->userCancelProc != nil ) ++ if (GPtr->userCancelProc != NULL) + { + UInt64 progress = 0; + Boolean progressChanged; +@@ -761,7 +761,7 @@ static int ScavSetUp( SGlob *GPtr) + short ioRefNum; + #endif + +- GPtr->MinorRepairsP = nil; ++ GPtr->MinorRepairsP = NULL; + + GPtr->itemsProcessed = 0; + GPtr->lastProgress = 0; +@@ -774,7 +774,7 @@ static int ScavSetUp( SGlob *GPtr) + ScavStaticStructures *pointer; + + pointer = (ScavStaticStructures *) AllocateClearMemory( sizeof(ScavStaticStructures) ); +- if ( pointer == nil ) { ++ if (pointer == NULL) { + if ( GPtr->logLevel >= kDebugLog ) { + printf( "\t error %d - could not allocate %i bytes of memory \n", + R_NoMem, sizeof(ScavStaticStructures) ); +@@ -831,7 +831,7 @@ static int ScavSetUp( SGlob *GPtr) + // Save current value of vcbWrCnt, to detect modifications to volume by other apps etc + if ( GPtr->volumeFeatures & volumeIsMountedMask ) + { +- FlushVol( nil, GPtr->realVCB->vcbVRefNum ); // Ask HFS to update all changes to disk ++ FlushVol(NULL, GPtr->realVCB->vcbVRefNum); // Ask HFS to update all changes to disk + GPtr->wrCnt = GPtr->realVCB->vcbWrCnt; // Remember write count after writing changes + } + #endif +@@ -949,7 +949,7 @@ static int ScavSetUp( SGlob *GPtr) + + // Keep a valid file id list for HFS volumes + GPtr->validFilesList = (UInt32**)NewHandle( 0 ); +- if ( GPtr->validFilesList == nil ) { ++ if (GPtr->validFilesList == NULL) { + if ( GPtr->logLevel >= kDebugLog ) { + printf( "\t error %d - could not allocate file ID list \n", R_NoMem ); + } +@@ -995,17 +995,17 @@ static int ScavTerm( SGlobPtr GPtr ) + + (void) BitMapCheckEnd(); + +- while( (rP = GPtr->MinorRepairsP) != nil ) // loop freeing leftover (undone) repair orders ++ while((rP = GPtr->MinorRepairsP) != NULL) // loop freeing leftover (undone) repair orders + { + GPtr->MinorRepairsP = rP->link; // (in case repairs were not made) + DisposeMemory(rP); + err = MemError(); + } + +- if( GPtr->validFilesList != nil ) ++ if (GPtr->validFilesList != NULL) + DisposeHandle( (Handle) GPtr->validFilesList ); + +- if( GPtr->overlappedExtents != nil ) { ++ if (GPtr->overlappedExtents != NULL) { + extentsTableH = GPtr->overlappedExtents; + + /* Overlapped extents list also allocated memory for attribute name */ +@@ -1021,44 +1021,44 @@ static int ScavTerm( SGlobPtr GPtr ) + DisposeHandle( (Handle) GPtr->overlappedExtents ); + } + +- if( GPtr->fileIdentifierTable != nil ) ++ if (GPtr->fileIdentifierTable != NULL) + DisposeHandle( (Handle) GPtr->fileIdentifierTable ); + +- if( GPtr->calculatedVCB == nil ) // already freed? ++ if (GPtr->calculatedVCB == NULL) // already freed? + return( noErr ); + + // If the FCB's and BTCB's have been set up, dispose of them + fcbP = GPtr->calculatedExtentsFCB; // release extent file BTree bit map +- if ( fcbP != nil ) ++ if (fcbP != NULL) + { + btcbP = (BTreeControlBlock*)fcbP->fcbBtree; +- if ( btcbP != nil) ++ if (btcbP != NULL) + { +- if( btcbP->refCon != nil ) ++ if (btcbP->refCon != NULL) + { +- if(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != nil) ++ if (((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != NULL) + { + DisposeMemory(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr); + err = MemError(); + } + DisposeMemory( (Ptr)btcbP->refCon ); + err = MemError(); +- btcbP->refCon = nil; ++ btcbP->refCon = NULL; + } + + fcbP = GPtr->calculatedCatalogFCB; // release catalog BTree bit map + btcbP = (BTreeControlBlock*)fcbP->fcbBtree; + +- if( btcbP->refCon != nil ) ++ if (btcbP->refCon != NULL) + { +- if(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != nil) ++ if (((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr != NULL) + { + DisposeMemory(((BTreeExtensionsRec*)btcbP->refCon)->BTCBMPtr); + err = MemError(); + } + DisposeMemory( (Ptr)btcbP->refCon ); + err = MemError(); +- btcbP->refCon = nil; ++ btcbP->refCon = NULL; + } + } + } +@@ -1066,7 +1066,7 @@ static int ScavTerm( SGlobPtr GPtr ) + DisposeMemory( GPtr->calculatedVCB ); // Release our block of data structures + err = MemError(); + +- GPtr->calculatedVCB = nil; ++ GPtr->calculatedVCB = NULL; + + return( noErr ); + } +@@ -1113,7 +1113,7 @@ Boolean IsBlueBoxSharedDrive ( DrvQElPtr dqPtr ) + // Now look at the name of the Driver name. If it is .BlueBoxShared keep it out of the list of available disks. + driverDCtlHandle = GetDCtlEntry(dqPtr->dQRefNum); + driverDCtlPtr = *driverDCtlHandle; +- if((((driverDCtlPtr->dCtlFlags) & Is_Native_Mask) == 0) && (driverDCtlPtr->dCtlDriver != nil)) ++ if((((driverDCtlPtr->dCtlFlags) & Is_Native_Mask) == 0) && (driverDCtlPtr->dCtlDriver != NULL)) + { + if (((driverDCtlPtr->dCtlFlags) & Is_Ram_Based_Mask) == 0) + { +@@ -1127,19 +1127,19 @@ Boolean IsBlueBoxSharedDrive ( DrvQElPtr dqPtr ) + + } + driverName = (StringPtr)&(drvrHeaderPtr->drvrName); +- if (!(IdenticalString(driverName,blueBoxSharedDriverName,nil))) ++ if (!(IdenticalString(driverName,blueBoxSharedDriverName,NULL))) + { + return( true ); + } + + // Special case for the ".Sony" floppy driver which might be accessed in Shared mode inside the Blue Box + // Test its "where" string instead of the driver name. +- if (!(IdenticalString(driverName,sonyDriverName,nil))) ++ if (!(IdenticalString(driverName,sonyDriverName,NULL))) + { + CntrlParam paramBlock; + +- paramBlock.ioCompletion = nil; +- paramBlock.ioNamePtr = nil; ++ paramBlock.ioCompletion = NULL; ++ paramBlock.ioNamePtr = NULL; + paramBlock.ioVRefNum = dqPtr->dQDrive; + paramBlock.ioCRefNum = dqPtr->dQRefNum; + paramBlock.csCode = kDriveIcon; // return physical icon +@@ -1152,7 +1152,7 @@ Boolean IsBlueBoxSharedDrive ( DrvQElPtr dqPtr ) + + iconAndStringRecPtr = * (IconAndStringRecPtr*) & paramBlock.csParam; + whereStringPtr = (StringPtr) & iconAndStringRecPtr->string; +- if (!(IdenticalString(whereStringPtr,blueBoxFloppyWhereString,nil))) ++ if (!(IdenticalString(whereStringPtr,blueBoxFloppyWhereString,NULL))) + { + return( true ); + } +diff --git a/fsck_hfs.tproj/dfalib/SRepair.c b/fsck_hfs.tproj/dfalib/SRepair.c +index 89c12d6..b261c37 100644 +--- a/fsck_hfs.tproj/dfalib/SRepair.c ++++ b/fsck_hfs.tproj/dfalib/SRepair.c +@@ -844,7 +844,7 @@ static int DelFThd( SGlobPtr GPtr, UInt32 fid ) // the file ID + + isHFSPlus = VolumeObjectIsHFSPlus( ); + +- BuildCatalogKey( fid, (const CatalogName*) nil, isHFSPlus, &key ); ++ BuildCatalogKey(fid, NULL, isHFSPlus, &key); + result = SearchBTreeRecord( GPtr->calculatedCatalogFCB, &key, kNoHint, &foundKey, &record, &recSize, &hint ); + + if ( result ) return ( IntError( GPtr, result ) ); +@@ -910,7 +910,7 @@ static OSErr FixDirThread( SGlobPtr GPtr, UInt32 did ) // the dir ID + + isHFSPlus = VolumeObjectIsHFSPlus( ); + +- BuildCatalogKey( did, (const CatalogName*) nil, isHFSPlus, &key ); ++ BuildCatalogKey(did, NULL, isHFSPlus, &key); + result = SearchBTreeRecord( GPtr->calculatedCatalogFCB, &key, kNoHint, &foundKey, &record, &recSize, &hint ); + + if ( result ) +@@ -2171,7 +2171,7 @@ static OSErr FixOrphanedFiles ( SGlobPtr GPtr ) + } + + //-- Build the key for the file thread +- BuildCatalogKey( cNodeID, nil, isHFSPlus, &key ); ++ BuildCatalogKey(cNodeID, NULL, isHFSPlus, &key); + + err = SearchBTreeRecord( GPtr->calculatedCatalogFCB, &key, kNoHint, + &tempKey, &threadRecord, &recordSize, &hint2 ); +diff --git a/fsck_hfs.tproj/dfalib/SUtils.c b/fsck_hfs.tproj/dfalib/SUtils.c +index 6e9253e..491afbf 100644 +--- a/fsck_hfs.tproj/dfalib/SUtils.c ++++ b/fsck_hfs.tproj/dfalib/SUtils.c +@@ -395,11 +395,11 @@ OSErr GetVolumeFeatures( SGlobPtr GPtr ) + err = GetVCBDriveNum( &GPtr->realVCB, GPtr->DrvNum ); + ReturnIfError( err ); + +- if ( GPtr->realVCB != nil ) ++ if (GPtr->realVCB != NULL) + { + GPtr->volumeFeatures |= volumeIsMountedMask; + +- pb.ioParam.ioNamePtr = nil; ++ pb.ioParam.ioNamePtr = NULL; + pb.ioParam.ioVRefNum = GPtr->realVCB->vcbVRefNum; + pb.ioParam.ioBuffer = (Ptr) &buffer; + pb.ioParam.ioReqCount = sizeof( buffer ); +@@ -2282,7 +2282,7 @@ void print_prime_buckets(PrimeBuckets *cur); + * 4. btreetye - can be kHFSPlusCatalogRecord or kHFSPlusAttributeRecord + * indicates which btree prime number bucket should be incremented + * +- * Output: nil ++ * Output: NULL + */ + void RecordXAttrBits(SGlobPtr GPtr, UInt16 flags, HFSCatalogNodeID fileid, UInt16 btreetype) + { +diff --git a/fsck_hfs.tproj/dfalib/SVerify1.c b/fsck_hfs.tproj/dfalib/SVerify1.c +index 39bda5c..c33155f 100644 +--- a/fsck_hfs.tproj/dfalib/SVerify1.c ++++ b/fsck_hfs.tproj/dfalib/SVerify1.c +@@ -790,13 +790,13 @@ OSErr CreateExtentsBTreeControlBlock( SGlobPtr GPtr ) + // set up our DFA extended BTCB area. Will we have enough memory on all HFS+ volumes. + // + btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == nil ) { ++ if (btcb->refCon == NULL) { + err = R_NoMem; + goto exit; + } + size = (btcb->totalNodes + 7) / 8; // size of BTree bit map + ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr = AllocateClearMemory(size); // get precleared bitmap +- if ( ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == nil ) ++ if (((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == NULL) + { + err = R_NoMem; + goto exit; +@@ -1145,13 +1145,13 @@ OSErr CreateCatalogBTreeControlBlock( SGlobPtr GPtr ) + // + + btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == nil ) { ++ if (btcb->refCon == NULL) { + err = R_NoMem; + goto exit; + } + size = (btcb->totalNodes + 7) / 8; // size of BTree bit map + ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr = AllocateClearMemory(size); // get precleared bitmap +- if ( ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == nil ) ++ if (((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == NULL) + { + err = R_NoMem; + goto exit; +@@ -1339,7 +1339,7 @@ OSErr CatHChk( SGlobPtr GPtr ) + + // Can we ignore this part by just taking advantage of setting the selCode = 0x8001; + { +- BuildCatalogKey( 1, (const CatalogName *)nil, isHFSPlus, &key ); ++ BuildCatalogKey(1, NULL, isHFSPlus, &key); + result = SearchBTreeRecord( GPtr->calculatedCatalogFCB, &key, kNoHint, &foundKey, &threadRecord, &recSize, &hint ); + + GPtr->TarBlock = hint; /* set target block */ +@@ -1443,7 +1443,7 @@ OSErr CatHChk( SGlobPtr GPtr ) + /* + * Find thread record + */ +- BuildCatalogKey( dprP->directoryID, (const CatalogName *) nil, isHFSPlus, &key ); ++ BuildCatalogKey(dprP->directoryID, NULL, isHFSPlus, &key); + result = SearchBTreeRecord( GPtr->calculatedCatalogFCB, &key, kNoHint, &foundKey, &threadRecord, &recSize, &hint ); + if ( result != noErr ) { + char idStr[16]; +@@ -1780,26 +1780,26 @@ OSErr CreateAttributesBTreeControlBlock( SGlobPtr GPtr ) + // set up our DFA extended BTCB area. Will we have enough memory on all HFS+ volumes. + // + btcb->refCon = AllocateClearMemory( sizeof(BTreeExtensionsRec) ); // allocate space for our BTCB extensions +- if ( btcb->refCon == nil ) { ++ if (btcb->refCon == NULL) { + err = R_NoMem; + goto exit; + } + + if (btcb->totalNodes == 0) + { +- ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr = nil; ++ ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr = NULL; + ((BTreeExtensionsRec*)btcb->refCon)->BTCBMSize = 0; + ((BTreeExtensionsRec*)btcb->refCon)->realFreeNodeCount = 0; + } + else + { +- if ( btcb->refCon == nil ) { ++ if (btcb->refCon == NULL) { + err = R_NoMem; + goto exit; + } + size = (btcb->totalNodes + 7) / 8; // size of BTree bit map + ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr = AllocateClearMemory(size); // get precleared bitmap +- if ( ((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == nil ) ++ if (((BTreeExtensionsRec*)btcb->refCon)->BTCBMPtr == NULL) + { + err = R_NoMem; + goto exit; +@@ -2358,7 +2358,7 @@ static OSErr RcdMDBEmbededVolDescriptionErr( SGlobPtr GPtr, OSErr type, HFSMaste + RcdError( GPtr, type ); // first, record the error + + p = AllocMinorRepairOrder( GPtr, sizeof(EmbededVolDescription) ); // get the node +- if ( p == nil ) return( R_NoMem ); ++ if (p == NULL) return( R_NoMem ); + + p->type = type; // save error info + desc = (EmbededVolDescription *) &(p->name); +@@ -2397,7 +2397,7 @@ static OSErr RcdInvalidWrapperExtents( SGlobPtr GPtr, OSErr type ) + RcdError( GPtr, type ); // first, record the error + + p = AllocMinorRepairOrder( GPtr, 0 ); // get the node +- if ( p == nil ) return( R_NoMem ); ++ if (p == NULL) return( R_NoMem ); + + p->type = type; // save error info + +@@ -3029,7 +3029,7 @@ OSErr CheckFileExtents( SGlobPtr GPtr, UInt32 fileNumber, UInt8 forkType, + foundBadExtent = false; + lastExtentIndex = GPtr->numExtents; + +- while ( (extents != nil) && (err == noErr) ) ++ while ((extents != NULL) && (err == noErr)) + { + // checkout the extent record first + err = ChkExtRec( GPtr, extents, &lastExtentIndex ); +@@ -3105,7 +3105,7 @@ OSErr CheckFileExtents( SGlobPtr GPtr, UInt32 fileNumber, UInt8 forkType, + if ( err == btNotFound ) + { + err = noErr; // no more extent records +- extents = nil; ++ extents = NULL; + break; + } + else if ( err != noErr ) +@@ -3121,7 +3121,7 @@ OSErr CheckFileExtents( SGlobPtr GPtr, UInt32 fileNumber, UInt8 forkType, + if ( err == btNotFound ) + { + err = noErr; // no more extent records +- extents = nil; ++ extents = NULL; + break; + } + else if ( err != noErr ) +@@ -3205,7 +3205,7 @@ static OSErr AddExtentToOverlapList( SGlobPtr GPtr, HFSCatalogNodeID fileNumber, + } + + // If it's uninitialized +- if ( GPtr->overlappedExtents == nil ) ++ if (GPtr->overlappedExtents == NULL) + { + GPtr->overlappedExtents = (ExtentsTable **) NewHandleClear( sizeof(ExtentsTable) ); + extentsTableH = GPtr->overlappedExtents; +diff --git a/fsck_hfs.tproj/dfalib/SVerify2.c b/fsck_hfs.tproj/dfalib/SVerify2.c +index c68f3d8..da1a982 100644 +--- a/fsck_hfs.tproj/dfalib/SVerify2.c ++++ b/fsck_hfs.tproj/dfalib/SVerify2.c +@@ -1013,7 +1013,7 @@ static int BTKeyChk( SGlobPtr GPtr, NodeDescPtr nodeP, BTreeControlBlock *btcb ) + UInt16 keyLength; + KeyPtr keyPtr; + UInt8 *dataPtr; +- KeyPtr prevkeyP = nil; ++ KeyPtr prevkeyP = NULL; + + + if ( nodeP->numRecords == 0 ) +@@ -1044,7 +1044,7 @@ static int BTKeyChk( SGlobPtr GPtr, NodeDescPtr nodeP, BTreeControlBlock *btcb ) + return( E_KeyLen ); + } + +- if ( prevkeyP != nil ) ++ if (prevkeyP != NULL) + { + if ( CompareKeys( (BTreeControlBlockPtr)btcb, prevkeyP, keyPtr ) >= 0 ) + { diff --git a/utils/hfsprogs/patches/0011-Fix-types.patch b/utils/hfsprogs/patches/0011-Fix-types.patch new file mode 100644 index 000000000..88c049fcd --- /dev/null +++ b/utils/hfsprogs/patches/0011-Fix-types.patch @@ -0,0 +1,71 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= +Date: Thu, 24 Oct 2013 01:11:22 -0200 +Subject: Fix types + +--- + fsck_hfs.tproj/cache.c | 30 ++++++++++++++++-------------- + 1 file changed, 16 insertions(+), 14 deletions(-) + +diff --git a/fsck_hfs.tproj/cache.c b/fsck_hfs.tproj/cache.c +index 527088a..540fa0b 100644 +--- a/fsck_hfs.tproj/cache.c ++++ b/fsck_hfs.tproj/cache.c +@@ -961,20 +961,21 @@ int CacheLookup (Cache_t *cache, uint64_t off, Tag_t **tag) + */ + int CacheRawRead (Cache_t *cache, uint64_t off, uint32_t len, void *buf) + { +- uint64_t result; ++ off_t result1; ++ ssize_t result2; + + /* Both offset and length must be multiples of the device block size */ + if (off % cache->DevBlockSize) return (EINVAL); + if (len % cache->DevBlockSize) return (EINVAL); + + /* Seek to the position */ +- result = lseek (cache->FD_R, off, SEEK_SET); +- if (result < 0) return (errno); +- if (result != off) return (ENXIO); ++ result1 = lseek(cache->FD_R, off, SEEK_SET); ++ if (result1 < 0) return (errno); ++ if (result1 != off) return (ENXIO); + /* Read into the buffer */ +- result = read (cache->FD_R, buf, len); +- if (result < 0) return (errno); +- if (result == 0) return (ENXIO); ++ result2 = read(cache->FD_R, buf, len); ++ if (result2 < 0) return (errno); ++ if (result2 == 0) return (ENXIO); + + /* Update counters */ + cache->DiskRead++; +@@ -989,21 +990,22 @@ int CacheRawRead (Cache_t *cache, uint64_t off, uint32_t len, void *buf) + */ + int CacheRawWrite (Cache_t *cache, uint64_t off, uint32_t len, void *buf) + { +- uint64_t result; ++ off_t result1; ++ ssize_t result2; + + /* Both offset and length must be multiples of the device block size */ + if (off % cache->DevBlockSize) return (EINVAL); + if (len % cache->DevBlockSize) return (EINVAL); + + /* Seek to the position */ +- result = lseek (cache->FD_W, off, SEEK_SET); +- if (result < 0) return (errno); +- if (result != off) return (ENXIO); ++ result1 = lseek (cache->FD_W, off, SEEK_SET); ++ if (result1 < 0) return (errno); ++ if (result1 != off) return (ENXIO); + + /* Write into the buffer */ +- result = write (cache->FD_W, buf, len); +- if (result < 0) return (errno); +- if (result == 0) return (ENXIO); ++ result2 = write (cache->FD_W, buf, len); ++ if (result2 < 0) return (errno); ++ if (result2 == 0) return (ENXIO); + + /* Update counters */ + cache->DiskWrite++; diff --git a/utils/hfsprogs/patches/0012-Fix-mkfs-not-creating-UUIDs-for-new-filesystems.patch b/utils/hfsprogs/patches/0012-Fix-mkfs-not-creating-UUIDs-for-new-filesystems.patch new file mode 100644 index 000000000..883a7b74f --- /dev/null +++ b/utils/hfsprogs/patches/0012-Fix-mkfs-not-creating-UUIDs-for-new-filesystems.patch @@ -0,0 +1,50 @@ +From: Matthew Garrett +Date: Thu, 24 Oct 2013 01:11:22 -0200 +Subject: Fix mkfs not creating UUIDs for new filesystems. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Fix mkfs not creating UUIDs for new filesystems. + +Thanks to Lars Noodén for reporting the bug at + . + +This closes LP: #737002. +--- + include/missing.h | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/include/missing.h b/include/missing.h +index 0a859c4..f50e8fb 100644 +--- a/include/missing.h ++++ b/include/missing.h +@@ -72,7 +72,7 @@ + #define NAME_MAX 255 + + /* Byteswap stuff */ +-#define NXSwapHostLongToBig(x) cpu_to_be64(x) ++#define NXSwapHostLongToBig(x) cpu_to_be32(x) + #define NXSwapBigShortToHost(x) be16_to_cpu(x) + #define OSSwapBigToHostInt16(x) be16_to_cpu(x) + #define NXSwapBigLongToHost(x) be32_to_cpu(x) +@@ -88,6 +88,9 @@ + #ifndef be32_to_cpu + #define be32_to_cpu(x) bswap_32(x) + #endif ++#ifndef cpu_to_be32 ++#define cpu_to_be32(x) bswap_32(x) ++#endif + #ifndef be64_to_cpu + #define be64_to_cpu(x) bswap_64(x) + #endif +@@ -102,6 +105,9 @@ + #ifndef be32_to_cpu + #define be32_to_cpu(x) (x) + #endif ++#ifndef cpu_to_be32 ++#define cpu_to_be32(x) (x) ++#endif + #ifndef be64_to_cpu + #define be64_to_cpu(x) (x) + #endif diff --git a/utils/hfsprogs/patches/0013-Fix-manpages.patch b/utils/hfsprogs/patches/0013-Fix-manpages.patch new file mode 100644 index 000000000..d78083bd0 --- /dev/null +++ b/utils/hfsprogs/patches/0013-Fix-manpages.patch @@ -0,0 +1,157 @@ +From: =?UTF-8?q?Rog=C3=A9rio=20Theodoro=20de=20Brito?= +Date: Thu, 25 Nov 2010 00:00:00 -0200 +Subject: Fix manpages +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Remove typos, references in the "See also" sections of the manpages to +commands that are not available in Debian systems (and, quite probably, +other systems too) and non-Linux specific comments. + +Authored also by Christoph Hellwig and "A. Costa" + +Bug-Debian: http://bugs.debian.org/598714 +Bug-Debian: http://bugs.debian.org/575201 +Forwarded: no +Reviewed-by: Rogério Theodoro de Brito +--- + fsck_hfs.tproj/fsck_hfs.8 | 18 +++++++----------- + newfs_hfs.tproj/newfs_hfs.8 | 23 ++++++++--------------- + 2 files changed, 15 insertions(+), 26 deletions(-) + +diff --git a/fsck_hfs.tproj/fsck_hfs.8 b/fsck_hfs.tproj/fsck_hfs.8 +index aec9949..0bc804d 100644 +--- a/fsck_hfs.tproj/fsck_hfs.8 ++++ b/fsck_hfs.tproj/fsck_hfs.8 +@@ -19,18 +19,18 @@ + .Dt FSCK_HFS 8 + .Os "Mac OS X" + .Sh NAME +-.Nm fsck_hfs ++.Nm fsck.hfs + .Nd HFS file system consistency check + .Sh SYNOPSIS +-.Nm fsck_hfs ++.Nm fsck.hfs + .Fl q + .Op Fl df + .Ar special ... +-.Nm fsck_hfs ++.Nm fsck.hfs + .Fl p + .Op Fl df + .Ar special ... +-.Nm fsck_hfs ++.Nm fsck.hfs + .Op Fl n | y | r + .Op Fl dfgl + .Op Fl m Ar mode +@@ -52,9 +52,7 @@ The second form of + preens the specified file systems. + It is normally started by + .Xr fsck 8 +-run from +-.Pa /etc/rc.boot +-during automatic reboot, when a HFS file system is detected. ++during systen boot, when a HFS file system is detected. + When preening file systems, + .Nm + will fix common inconsistencies for file systems that were not +@@ -105,9 +103,9 @@ to check and repair journaled HFS+ file systems. + .It Fl g + Causes + .Nm +-to generate it's output strings in GUI format. ++to generate its output strings in GUI format. + This option is used when another application with a graphical user interface +-(like Mac OS X Disk Utility) is envoking the ++(like Mac OS X Disk Utility) is invoking the + .Nm + tool. + .It Fl l +@@ -144,8 +142,6 @@ specified file system for a new catalog file and if there is no damage + to the leaf nodes in the existing catalog file. + .El + .Pp +-Because of inconsistencies between the block device and the buffer cache, +-the raw device should always be used. + .Sh SEE ALSO + .Xr fsck 8 + .Sh BUGS +diff --git a/newfs_hfs.tproj/newfs_hfs.8 b/newfs_hfs.tproj/newfs_hfs.8 +index d002cc9..fe91962 100644 +--- a/newfs_hfs.tproj/newfs_hfs.8 ++++ b/newfs_hfs.tproj/newfs_hfs.8 +@@ -19,10 +19,10 @@ + .Dt NEWFS_HFS 8 + .Os "Mac OS X" + .Sh NAME +-.Nm newfs_hfs ++.Nm mkfs.hfs + .Nd construct a new HFS Plus file system + .Sh SYNOPSIS +-.Nm newfs_hfs ++.Nm mkfs.hfs + .Op Fl N Ar [partition-size] + .Op Fl U Ar uid + .Op Fl G Ar gid +@@ -37,19 +37,13 @@ + .Op Fl v Ar volume-name + .Ar special + .Sh DESCRIPTION +-.Nm Newfs_hfs ++.Nm mkfs.hfs + builds an HFS Plus file system on the specified special device. +-Before running +-.Nm newfs_hfs +-the disk should be partitioned using the +-.Em Disk Utility +-application or +-.Xr pdisk 8 . + .Pp + The file system default parameters are calculated based on + the size of the disk partition. Typically the defaults are + reasonable, however +-.Nm newfs_hfs ++.Nm mkfs.hfs + has several options to allow the defaults to be selectively overridden. + The options are as follows: + .Bl -tag -width Fl +@@ -66,7 +60,7 @@ Set the group of the file system's root directory to + Specify the access permissions mask for the file system's root directory. + .It Fl h + Creates a legacy HFS format filesystem. This option +-is not recomended for file systems that will be ++is not recommended for file systems that will be + primarily used with Mac OS X or Darwin. + .It Fl s + Creates a case-sensitive HFS Plus filesystem. By +@@ -93,7 +87,7 @@ sizes are specified with the + option followed by a comma + separated list of the form arg=blocks. + .Pp +-Example: -c c=5000,e=500 ++Example: \-c c=5000,e=500 + .Bl -tag -width Fl + .It Em a=blocks + Set the attribute file clump size. +@@ -126,7 +120,7 @@ the form arg=bytes. The + size must be a power of two and no larger than + 32768 bytes. + .Pp +-Example: -n c=8192,e=4096 ++Example: \-n c=8192,e=4096 + .Bl -tag -width Fl + .It Em a=bytes + Set the attribute b-tree node size. +@@ -139,8 +133,7 @@ Set the extent overflow b-tree node size. + Volume name (file system name) in ascii or UTF-8 format. + .El + .Sh SEE ALSO +-.Xr mount 8 , +-.Xr pdisk 8 ++.Xr mount 8 + .Sh HISTORY + The + .Nm diff --git a/utils/hfsprogs/patches/0014-uClibc_no_loadavg.patch b/utils/hfsprogs/patches/0014-uClibc_no_loadavg.patch new file mode 100644 index 000000000..48649ba59 --- /dev/null +++ b/utils/hfsprogs/patches/0014-uClibc_no_loadavg.patch @@ -0,0 +1,15 @@ +--- diskdev_cmds-332.25/newfs_hfs.tproj/makehfs.c 2015-03-27 21:58:04.163171675 -0700 ++++ hfsprogs-332.25/newfs_hfs.tproj/makehfs.c 2015-03-27 21:56:03.687175020 -0700 +@@ -2119,10 +2119,12 @@ + sysctl(mib, 2, sysctlstring, &datalen, NULL, 0); + SHA1_Update(&context, sysctlstring, datalen); + #endif ++#ifndef __UCLIBC__ + /* The system's load average: */ + datalen = sizeof(sysloadavg); + getloadavg(sysloadavg, 3); + SHA1_Update(&context, &sysloadavg, datalen); ++#endif + + /* The system's VM statistics: */ + #if !LINUX diff --git a/utils/i2c-tools/Makefile b/utils/i2c-tools/Makefile new file mode 100644 index 000000000..8c36ca9da --- /dev/null +++ b/utils/i2c-tools/Makefile @@ -0,0 +1,94 @@ +# +# Copyright (C) 2007-2015 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:=i2c-tools +PKG_VERSION:=3.1.1 +PKG_RELEASE:=1 + +PKG_SOURCE_URL:=http://dl.lm-sensors.org/i2c-tools/releases/ \ + http://web.archive.org/web/20150326044243/http://dl.lm-sensors.org/i2c-tools/releases/ +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_MD5SUM:=0fdbff53ebd0b8d9249256d6c56480b1 + +PKG_BUILD_PARALLEL:=1 +PKG_BUILD_DEPENDS:=PACKAGE_python-smbus:python + +PKG_MAINTAINER:=Daniel Golle +PKG_LICENSE:=GPLv2 +PKG_LICENSE_FILES:=COPYING + +include $(INCLUDE_DIR)/package.mk +$(call include_mk, python-package.mk) + +define Package/i2c/Default + URL:=http://lm-sensors.org/wiki/I2CTools + TITLE:=I2C +endef + +define Package/i2c-tools + $(call Package/i2c/Default) + SECTION:=utils + CATEGORY:=Utilities + TITLE+=tools for Linux +endef + +define Package/python-smbus + $(call Package/i2c/Default) + SUBMENU:=Python + SECTION:=lang + CATEGORY:=Languages + TITLE:=Python bindings for the SMBUS + DEPENDS:=+python-light +endef + +define Package/i2c-tools/description + This package contains an heterogeneous set of I2C tools for Linux. These tools + were originally part of the lm-sensors package. +endef + +define Package/python-smbus/description + This package contain the python bindings for Linux SMBus access through i2c-dev. +endef + +TARGET_CPPFLAGS += -I$(PKG_BUILD_DIR)/include + +ifdef CONFIG_PACKAGE_python-smbus + define Build/Compile/python-smbus + $(if $(Build/Compile/PyMod),,@echo Python packaging code not found.; false) + $(call Build/Compile/PyMod,./py-smbus/, \ + install --prefix="$(PKG_INSTALL_DIR)/usr", \ + ) + endef +endif + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + LINUX="$(LINUX_DIR)" \ + CC="$(TARGET_CC)" \ + STAGING_DIR="$(STAGING_DIR)" \ + LDFLAGS="$(TARGET_LDFLAGS)" \ + CFLAGS="$(TARGET_CFLAGS)" + $(Build/Compile/python-smbus) +endef + +define Package/i2c-tools/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/i2cdetect $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/i2cdump $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/i2cset $(1)/usr/sbin/ + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/i2cget $(1)/usr/sbin/ +endef + +define PyPackage/python-smbus/filespec ++|$(PYTHON_PKG_DIR)/smbus.so +endef + +$(eval $(call BuildPackage,i2c-tools)) +$(eval $(call PyPackage,python-smbus)) +$(eval $(call BuildPackage,python-smbus)) diff --git a/utils/kmod/Makefile b/utils/kmod/Makefile index e59c0315f..96769aae5 100644 --- a/utils/kmod/Makefile +++ b/utils/kmod/Makefile @@ -8,16 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=kmod -PKG_VERSION:=19 +PKG_VERSION:=20 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=https://www.kernel.org/pub/linux/utils/kernel/kmod/ -PKG_MD5SUM:=a08643f814aa4efc12211c6e5909f4d9 +PKG_MD5SUM:=d6f4fef718a50bd88080de6a43bc64d8 PKG_MAINTAINER:=Jeff Waugh PKG_LICENSE:=LGPL-2.1+ PKG_LICENSE_FILES:=COPYING +PKG_FIXUP:=autoreconf +PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk diff --git a/utils/kmod/patches/001-fix_pkgconfig_file.patch b/utils/kmod/patches/001-fix_pkgconfig_file.patch new file mode 100644 index 000000000..1891078d7 --- /dev/null +++ b/utils/kmod/patches/001-fix_pkgconfig_file.patch @@ -0,0 +1,22 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -35,9 +35,6 @@ SED_PROCESS = \ + -e 's,@zlib_LIBS\@,${zlib_LIBS},g' \ + < $< > $@ || rm $@ + +-%.pc: %.pc.in Makefile +- $(SED_PROCESS) +- + LIBKMOD_CURRENT=4 + LIBKMOD_REVISION=9 + LIBKMOD_AGE=2 +--- a/configure.ac ++++ b/configure.ac +@@ -221,6 +221,7 @@ AC_CONFIG_HEADERS(config.h) + AC_CONFIG_FILES([ + Makefile + man/Makefile ++ libkmod/libkmod.pc + libkmod/docs/Makefile + libkmod/docs/version.xml + ]) diff --git a/utils/lm-sensors/Makefile b/utils/lm-sensors/Makefile index 02faccb15..4dcea0caf 100644 --- a/utils/lm-sensors/Makefile +++ b/utils/lm-sensors/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lm-sensors PKG_VERSION:=3.3.5 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=lm_sensors-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://dl.lm-sensors.org/lm-sensors/releases diff --git a/utils/lm-sensors/patches/100-musl-compat.patch b/utils/lm-sensors/patches/100-musl-compat.patch new file mode 100644 index 000000000..1cd82aba9 --- /dev/null +++ b/utils/lm-sensors/patches/100-musl-compat.patch @@ -0,0 +1,44 @@ +--- a/prog/dump/isadump.c ++++ b/prog/dump/isadump.c +@@ -38,7 +38,7 @@ + + + /* To keep glibc2 happy */ +-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0 ++#if !defined(__UCLIBC__) + #include + #else + #include +--- a/prog/dump/isaset.c ++++ b/prog/dump/isaset.c +@@ -34,7 +34,7 @@ + + + /* To keep glibc2 happy */ +-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0 ++#if !defined(__UCLIBC__) + #include + #else + #include +--- a/prog/dump/superio.c ++++ b/prog/dump/superio.c +@@ -21,7 +21,7 @@ + + #include + +-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0 ++#if !defined(__UCLIBC__) + #include + #else + #include +--- a/prog/dump/util.c ++++ b/prog/dump/util.c +@@ -12,7 +12,7 @@ + #include "util.h" + + /* To keep glibc2 happy */ +-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0 ++#if !defined(__UCLIBC__) + #include + #else + #include diff --git a/utils/lsof/Makefile b/utils/lsof/Makefile index 75b2c5479..adf0d0478 100644 --- a/utils/lsof/Makefile +++ b/utils/lsof/Makefile @@ -10,7 +10,7 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=lsof PKG_VERSION:=4.86 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION)+dfsg.orig.tar.gz PKG_SOURCE_URL:=http://ftp2.de.debian.org/debian/pool/main/l/lsof @@ -32,9 +32,15 @@ define Package/lsof URL:=http://people.freebsd.org/~abe/ endef +ifeq ($(CONFIG_IPV6),y) + LINUX_CLIB_IPV6="-DHASIPv6" +else + LINUX_CLIB_IPV6= +endif + define Build/Configure cd $(PKG_BUILD_DIR); \ - LINUX_CLIB="-DGLIBCV=2" \ + LINUX_CLIB="-DGLIBCV=2 $(LINUX_CLIB_IPV6)" \ LSOF_CC="$(TARGET_CC)" \ LSOF_INCLUDE="-I$(STAGING_DIR)/usr/include" \ LSOF_VSTR="$(LINUX_VERSION)" \ diff --git a/utils/lvm2/Makefile b/utils/lvm2/Makefile index 803a279fd..2bc8c9231 100644 --- a/utils/lvm2/Makefile +++ b/utils/lvm2/Makefile @@ -9,13 +9,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=LVM2 -PKG_VERSION:=2.02.116 -PKG_RELEASE:=2 +PKG_VERSION:=2.02.122 +PKG_RELEASE:=1 PKG_LICENSE:=GPL-2.0 LGPL-2.1 PKG_SOURCE:=$(PKG_NAME).$(PKG_VERSION).tgz PKG_SOURCE_URL:=ftp://sources.redhat.com/pub/lvm2 -PKG_MD5SUM:=3a1104e3d1dc4d5e92a40228161cd660 +PKG_MD5SUM:=a88bf7d68955635d009a5aec1ffecc48 PKG_MAINTAINER:=Daniel Golle PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME).$(PKG_VERSION) diff --git a/utils/lvm2/patches/001-include_fix.patch b/utils/lvm2/patches/001-include_fix.patch index dc159c552..09d2db962 100644 --- a/utils/lvm2/patches/001-include_fix.patch +++ b/utils/lvm2/patches/001-include_fix.patch @@ -8,4 +8,4 @@ +#include #endif - #include "device-types.h" + #ifdef UDEV_SYNC_SUPPORT diff --git a/utils/lvm2/patches/002-const-stdio.patch b/utils/lvm2/patches/002-const-stdio.patch new file mode 100644 index 000000000..e7625b6c6 --- /dev/null +++ b/utils/lvm2/patches/002-const-stdio.patch @@ -0,0 +1,54 @@ +--- a/lib/commands/toolcontext.c ++++ b/lib/commands/toolcontext.c +@@ -1637,8 +1637,10 @@ struct cmd_context *create_toolcontext(u + unsigned threaded) + { + struct cmd_context *cmd; ++#if defined(__GLIBC__) && !defined(VALGRIND_POOL) + FILE *new_stream; + int flags; ++#endif + + #ifdef M_MMAP_MAX + mallopt(M_MMAP_MAX, 0); +@@ -1674,7 +1676,7 @@ struct cmd_context *create_toolcontext(u + /* FIXME Make this configurable? */ + reset_lvm_errno(1); + +-#ifndef VALGRIND_POOL ++#if defined(__GLIBC__) && !defined(VALGRIND_POOL) + /* Set in/out stream buffering before glibc */ + if (set_buffering) { + /* Allocate 2 buffers */ +@@ -2047,7 +2049,7 @@ void destroy_toolcontext(struct cmd_cont + if (cmd->libmem) + dm_pool_destroy(cmd->libmem); + +-#ifndef VALGRIND_POOL ++#if defined(__GLIBC__) && !defined(VALGRIND_POOL) + if (cmd->linebuffer) { + /* Reset stream buffering to defaults */ + if (is_valid_fd(STDIN_FILENO) && +--- a/tools/lvmcmdline.c ++++ b/tools/lvmcmdline.c +@@ -1635,6 +1635,7 @@ int lvm_split(char *str, int *argc, char + /* Make sure we have always valid filedescriptors 0,1,2 */ + static int _check_standard_fds(void) + { ++#ifdef __GLIBC__ + int err = is_valid_fd(STDERR_FILENO); + + if (!is_valid_fd(STDIN_FILENO) && +@@ -1661,6 +1662,12 @@ static int _check_standard_fds(void) + strerror(errno)); + return 0; + } ++#else ++ if (!is_valid_fd(STDERR_FILENO) || ++ !is_valid_fd(STDOUT_FILENO) || ++ !is_valid_fd(STDIN_FILENO)) ++ return 0; ++#endif + + return 1; + } diff --git a/utils/lvm2/patches/003-no-mallinfo.patch b/utils/lvm2/patches/003-no-mallinfo.patch new file mode 100644 index 000000000..be9a6625d --- /dev/null +++ b/utils/lvm2/patches/003-no-mallinfo.patch @@ -0,0 +1,45 @@ +--- a/lib/mm/memlock.c ++++ b/lib/mm/memlock.c +@@ -161,12 +161,15 @@ static void _allocate_memory(void) + * memory on free(), this is good enough for our purposes. + */ + while (missing > 0) { ++#ifdef __GLIBC__ + struct mallinfo inf = mallinfo(); + hblks = inf.hblks; ++#endif + + if ((areas[area] = malloc(_size_malloc_tmp))) + _touch_memory(areas[area], _size_malloc_tmp); + ++#ifdef __GLIBC__ + inf = mallinfo(); + + if (hblks < inf.hblks) { +@@ -176,9 +179,12 @@ static void _allocate_memory(void) + free(areas[area]); + _size_malloc_tmp /= 2; + } else { ++#endif + ++ area; + missing -= _size_malloc_tmp; ++#ifdef __GLIBC__ + } ++#endif + + if (area == max_areas && missing > 0) { + /* Too bad. Warn the user and proceed, as things are +@@ -467,8 +473,13 @@ static void _lock_mem(struct cmd_context + * will not block memory locked thread + * Note: assuming _memlock_count_daemon is updated before _memlock_count + */ ++#ifdef __GLIBC__ + _use_mlockall = _memlock_count_daemon ? 1 : + find_config_tree_bool(cmd, activation_use_mlockall_CFG, NULL); ++#else ++ /* always use mlockall on musl */ ++ _use_mlockall = 1; ++#endif + + if (!_use_mlockall) { + if (!*_procselfmaps && diff --git a/utils/lxc/Config.in b/utils/lxc/Config.in index 37286bfab..618fde0a0 100644 --- a/utils/lxc/Config.in +++ b/utils/lxc/Config.in @@ -27,4 +27,11 @@ config LXC_BUSYBOX_OPTIONS Select needed busybox options for lxc-create utility. This include XZ tar compression, long option support for tar and built-in getopt support. +config LXC_SECCOMP + bool "Enable support for seccomp in LXC" + default KERNEL_SECCOMP + help + Build LXC with support for seccomp filters. + Select libseccomp which also pulls-in the needed kernel features. + endmenu diff --git a/utils/lxc/Makefile b/utils/lxc/Makefile index 77f98a686..868e10066 100644 --- a/utils/lxc/Makefile +++ b/utils/lxc/Makefile @@ -8,25 +8,28 @@ include $(TOPDIR)/rules.mk PKG_NAME:=lxc -PKG_VERSION:=1.1.0 -PKG_RELEASE:=1 +PKG_VERSION:=1.1.2 +PKG_RELEASE:=2 PKG_LICENSE:=LGPL-2.1+ BSD-2-Clause GPL-2.0 PKG_MAINTAINER:=Luka Perkov PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://linuxcontainers.org/downloads/lxc/ -PKG_MD5SUM:=ab1cbabf859abc15165050c854979c5c +PKG_MD5SUM:=3ebadacf5fe8bfe689fd7a09812b682c PKG_BUILD_DEPENDS:=lua PKG_BUILD_PARALLEL:=1 + PKG_INSTALL:=1 +PKG_FIXUP:=autoreconf include $(INCLUDE_DIR)/package.mk LXC_APPLETS_BIN += \ - attach autostart cgroup clone config console create destroy execute \ - freeze info monitor snapshot start stop unfreeze unshare usernsexec wait + attach autostart cgroup clone config console create destroy device \ + execute freeze info monitor snapshot start stop unfreeze unshare \ + usernsexec wait LXC_APPLETS_LIB += \ monitord user-nic @@ -91,7 +94,7 @@ define Package/liblxc SECTION:=libs CATEGORY:=Libraries TITLE:=LXC userspace library - DEPENDS:= lxc +libcap +libpthread + DEPENDS:= lxc +libcap +libpthread +LXC_SECCOMP:libseccomp endef define Package/lxc-lua @@ -110,19 +113,19 @@ CONFIGURE_ARGS += \ --disable-apparmor \ --disable-doc \ --disable-examples \ - --disable-seccomp --enable-lua=yes \ - --with-lua-pc="$(STAGING_DIR)/usr/lib/pkgconfig/lua.pc" \ + --with-lua-pc="$(STAGING_DIR)/usr/lib/pkgconfig/lua.pc" + +ifeq ($(CONFIG_LXC_SECCOMP),y) +CONFIGURE_ARGS += --enable-seccomp +else +CONFIGURE_ARGS += --disable-seccomp +endif MAKE_FLAGS += \ LUA_INSTALL_CMOD="/usr/lib/lua" \ LUA_INSTALL_LMOD="/usr/lib/lua" -define Build/Configure - ( cd $(PKG_BUILD_DIR); ./autogen.sh ); - $(call Build/Configure/Default) -endef - define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include/lxc/ diff --git a/utils/lxc/patches/016-uninitialized-ret-in-monitor.patch b/utils/lxc/patches/016-uninitialized-ret-in-monitor.patch new file mode 100644 index 000000000..7eca2eaeb --- /dev/null +++ b/utils/lxc/patches/016-uninitialized-ret-in-monitor.patch @@ -0,0 +1,11 @@ +--- a/src/lxc/monitor.c ++++ b/src/lxc/monitor.c +@@ -181,7 +181,7 @@ int lxc_monitor_sock_name(const char *lx + int lxc_monitor_open(const char *lxcpath) + { + struct sockaddr_un addr; +- int fd,ret; ++ int fd,ret = 0; + int retry,backoff_ms[] = {10, 50, 100}; + size_t len; + diff --git a/utils/lxc/patches/030-lxc-download.patch b/utils/lxc/patches/030-lxc-download.patch new file mode 100644 index 000000000..295bae0aa --- /dev/null +++ b/utils/lxc/patches/030-lxc-download.patch @@ -0,0 +1,43 @@ +--- a/templates/lxc-download.in ++++ b/templates/lxc-download.in +@@ -39,7 +39,7 @@ DOWNLOAD_LIST_IMAGES="false" + DOWNLOAD_MODE="system" + DOWNLOAD_READY_GPG="false" + DOWNLOAD_RELEASE= +-DOWNLOAD_SERVER="images.linuxcontainers.org" ++DOWNLOAD_SERVER="virtualwrt.org/containers/" + DOWNLOAD_SHOW_GPG_WARNING="true" + DOWNLOAD_SHOW_HTTP_WARNING="true" + DOWNLOAD_TARGET="system" +@@ -257,14 +257,6 @@ for bin in tar xz wget; do + fi + done + +-# Check for GPG +-if [ "$DOWNLOAD_VALIDATE" = "true" ]; then +- if ! type gpg >/dev/null 2>&1; then +- echo "ERROR: Missing recommended tool: gpg" 1>&2 +- echo "You can workaround this by using --no-validate." 1>&2 +- exit 1 +- fi +-fi + + # Check that we have all variables we need + if [ -z "$LXC_NAME" ] || [ -z "$LXC_PATH" ] || [ -z "$LXC_ROOTFS" ]; then +@@ -456,16 +448,9 @@ if [ "$DOWNLOAD_USE_CACHE" = "false" ]; + echo "Downloading the rootfs" + download_file $DOWNLOAD_URL/rootfs.tar.xz \ + ${DOWNLOAD_TEMP}/rootfs.tar.xz normal +- download_sig $DOWNLOAD_URL/rootfs.tar.xz.asc \ +- ${DOWNLOAD_TEMP}/rootfs.tar.xz.asc normal +- gpg_validate ${DOWNLOAD_TEMP}/rootfs.tar.xz.asc +- + echo "Downloading the metadata" + download_file $DOWNLOAD_URL/meta.tar.xz \ + ${DOWNLOAD_TEMP}/meta.tar.xz normal +- download_sig $DOWNLOAD_URL/meta.tar.xz.asc \ +- ${DOWNLOAD_TEMP}/meta.tar.xz.asc normal +- gpg_validate ${DOWNLOAD_TEMP}/meta.tar.xz.asc + + if [ -d $LXC_CACHE_PATH ]; then + rm -Rf $LXC_CACHE_PATH diff --git a/utils/lxc/patches/300-fix-lxc-destroy.patch b/utils/lxc/patches/300-fix-lxc-destroy.patch deleted file mode 100644 index 241f38713..000000000 --- a/utils/lxc/patches/300-fix-lxc-destroy.patch +++ /dev/null @@ -1,48 +0,0 @@ -From bdeafb7bc4857e80dbca5192a751eedcf7b69abd Mon Sep 17 00:00:00 2001 -From: Luka Perkov -Date: Mon, 27 Oct 2014 21:49:46 +0100 -Subject: [PATCH] utils: remove unnecessary check of mystat.st_dev - -The check is not needed and it breaks lxc-destroy when container is installed -on top of overlayfs. More information why this is a problem on overlayfs can be -found here: - -https://kernel.googlesource.com/pub/scm/linux/kernel/git/mszeredi/vfs/+/overlayfs.current/Documentation/filesystems/overlayfs.txt - -Signed-off-by: Luka Perkov ---- - src/lxc/utils.c | 10 ++++------ - 1 file changed, 4 insertions(+), 6 deletions(-) - ---- a/src/lxc/utils.c -+++ b/src/lxc/utils.c -@@ -47,7 +47,7 @@ - - lxc_log_define(lxc_utils, lxc); - --static int _recursive_rmdir_onedev(char *dirname, dev_t pdev, -+static int _recursive_rmdir_onedev(char *dirname, - const char *exclude, int level) - { - struct dirent dirent, *direntp; -@@ -108,10 +108,8 @@ static int _recursive_rmdir_onedev(char - failed=1; - continue; - } -- if (mystat.st_dev != pdev) -- continue; - if (S_ISDIR(mystat.st_mode)) { -- if (_recursive_rmdir_onedev(pathname, pdev, exclude, level+1) < 0) -+ if (_recursive_rmdir_onedev(pathname, exclude, level+1) < 0) - failed=1; - } else { - if (unlink(pathname) < 0) { -@@ -147,7 +145,7 @@ extern int lxc_rmdir_onedev(char *path, - return -1; - } - -- return _recursive_rmdir_onedev(path, mystat.st_dev, exclude, 0); -+ return _recursive_rmdir_onedev(path, exclude, 0); - } - - static int mount_fs(const char *source, const char *target, const char *type) diff --git a/utils/macchanger/Makefile b/utils/macchanger/Makefile index 667f1d1cb..2bfcbbf2d 100644 --- a/utils/macchanger/Makefile +++ b/utils/macchanger/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=macchanger PKG_VERSION:=1.7.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/alobbs/macchanger/releases/download/$(PKG_VERSION)/ diff --git a/utils/macchanger/patches/0001-fix-build-with-musl.patch b/utils/macchanger/patches/0001-fix-build-with-musl.patch new file mode 100644 index 000000000..4a30d5510 --- /dev/null +++ b/utils/macchanger/patches/0001-fix-build-with-musl.patch @@ -0,0 +1,13 @@ +Index: macchanger-1.7.0/src/netinfo.c +=================================================================== +--- macchanger-1.7.0.orig/src/netinfo.c ++++ macchanger-1.7.0/src/netinfo.c +@@ -113,7 +113,7 @@ mc_net_info_get_permanent_mac (const net + epa->size = IFHWADDRLEN; + + memcpy(&req, &(net->dev), sizeof(struct ifreq)); +- req.ifr_data = (caddr_t)epa; ++ req.ifr_data = (char *)epa; + + if (ioctl(net->sock, SIOCETHTOOL, &req) < 0) { + perror ("[ERROR] Could not read permanent MAC"); diff --git a/utils/mc/Makefile b/utils/mc/Makefile index 1fb7beccc..ab8cd1b03 100644 --- a/utils/mc/Makefile +++ b/utils/mc/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=mc -PKG_VERSION:=4.8.13 -PKG_RELEASE:=1.2 +PKG_VERSION:=4.8.14 +PKG_RELEASE:=1.3 PKG_MAINTAINER:=Dirk Brenken PKG_LICENSE:=GPL-3.0+ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=http://ftp.midnight-commander.org/ -PKG_MD5SUM:=d967caa12765eb86e52a6a63ca202500 +PKG_MD5SUM:=fbdaddb9edcf8925dcf3231331a8720b PKG_BUILD_PARALLEL:=1 PKG_FIXUP:=autoreconf @@ -36,7 +36,7 @@ include $(INCLUDE_DIR)/nls.mk define Package/mc SECTION:=utils CATEGORY:=Utilities - DEPENDS:=+glib2 +libncurses +MC_VFS:libssh2 $(LIBRPC_DEPENDS) $(ICONV_DEPENDS) + DEPENDS:=+glib2 +libncurses +libmount +MC_VFS:libssh2 $(LIBRPC_DEPENDS) $(ICONV_DEPENDS) TITLE:=Midnight Commander - a powerful visual file manager URL:=http://www.midnight-commander.org/ MENU:=1 diff --git a/utils/minicom/Makefile b/utils/minicom/Makefile index cf60e53ec..b588993e2 100644 --- a/utils/minicom/Makefile +++ b/utils/minicom/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=minicom PKG_VERSION:=2.7 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://alioth.debian.org/frs/download.php/file/3977/ @@ -21,12 +21,13 @@ PKG_LICENSE_FILES:=COPYING PKG_FIXUP:=autoreconf +include $(INCLUDE_DIR)/nls.mk include $(INCLUDE_DIR)/package.mk define Package/minicom SECTION:=utils CATEGORY:=Utilities - DEPENDS:=+libncurses + DEPENDS:=$(ICONV_DEPENDS) $(INTL_DEPENDS) +libncurses TITLE:=Terminal emulation program URL:=http://alioth.debian.org/projects/minicom/ SUBMENU:=Terminal diff --git a/utils/minicom/patches/101-fix_music_includes.patch b/utils/minicom/patches/101-fix_music_includes.patch new file mode 100644 index 000000000..a74d1233d --- /dev/null +++ b/utils/minicom/patches/101-fix_music_includes.patch @@ -0,0 +1,14 @@ +--- a/src/dial.c ++++ b/src/dial.c +@@ -39,11 +39,9 @@ + #include "intl.h" + + #ifdef VC_MUSIC +-# if defined(__GLIBC__) + # include + # include + # include +-# endif + #endif + + enum { CURRENT_VERSION = 6 }; diff --git a/utils/minicom/patches/102-fix_musl_compatibility.patch b/utils/minicom/patches/102-fix_musl_compatibility.patch new file mode 100644 index 000000000..4524b22d8 --- /dev/null +++ b/utils/minicom/patches/102-fix_musl_compatibility.patch @@ -0,0 +1,13 @@ +--- a/src/getsdir.h ++++ b/src/getsdir.h +@@ -24,6 +24,10 @@ + + #include + ++#ifndef MAXNAMLEN ++#define MAXNAMLEN 255 ++#endif ++ + typedef struct dirEntry { /* structure of data item */ + char fname[MAXNAMLEN + 1]; /* filename + terminating null */ + time_t time; /* last modification date */ diff --git a/utils/mmc-utils/Makefile b/utils/mmc-utils/Makefile new file mode 100644 index 000000000..a089b2f4c --- /dev/null +++ b/utils/mmc-utils/Makefile @@ -0,0 +1,56 @@ +# +# Copyright (C) 2015 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:=mmc-utils +PKG_VERSION=2015-05-01-$(PKG_SOURCE_VERSION) +PKG_RELEASE:=1 + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=https://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc-utils.git +PKG_SOURCE_VERSION:=d0b46442b50794217e53b2455c1344c548d9d088 +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_SOURCE_VERSION) +PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz + +PKG_LICENSE:=GPL-2.0 +PKG_LICENSE_FILES:= + +PKG_MAINTAINER:=Michael Heimpold + +PKG_BUILD_PARALLEL:=1 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_SOURCE_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/mmc-utils + SECTION:=utils + CATEGORY:=Utilities + TITLE:=Userspace tools for MMC/SD devices + URL:=http://git.kernel.org/cgit/linux/kernel/git/cjb/mmc-utils.git +endef + +define Package/mmc-utils/description + This package contains the userspace mmc utils, the userspace + counterpart to the Linux MMC/SD subsystem. +endef + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + $(TARGET_CONFIGURE_OPTS) CFLAGS="$(TARGET_CFLAGS)" \ + mmc +endef + +define Package/mmc-utils/install + $(INSTALL_DIR) $(1)/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/mmc $(1)/sbin +endef + +$(eval $(call BuildPackage,mmc-utils)) diff --git a/utils/mmc-utils/patches/001-properly-set-fortify-source-in-makefile.patch b/utils/mmc-utils/patches/001-properly-set-fortify-source-in-makefile.patch new file mode 100644 index 000000000..4a35b959b --- /dev/null +++ b/utils/mmc-utils/patches/001-properly-set-fortify-source-in-makefile.patch @@ -0,0 +1,11 @@ +Index: mmc-utils-f4eb241519f8d500ce6068a70d2389be39ac5189/Makefile +=================================================================== +--- mmc-utils-f4eb241519f8d500ce6068a70d2389be39ac5189.orig/Makefile ++++ mmc-utils-f4eb241519f8d500ce6068a70d2389be39ac5189/Makefile +@@ -1,5 +1,5 @@ + CC ?= gcc +-AM_CFLAGS = -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2 ++AM_CFLAGS = -D_FILE_OFFSET_BITS=64 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 + CFLAGS ?= -g -O2 + objects = \ + mmc.o \ diff --git a/utils/mysql/Makefile b/utils/mysql/Makefile index 16312b3f1..f0553a9d7 100644 --- a/utils/mysql/Makefile +++ b/utils/mysql/Makefile @@ -58,7 +58,9 @@ define Package/libmysqlclient-r DEPENDS+= +libpthread endef -TARGET_CXX=g++-uc +ifneq ($(CONFIG_USE_UCLIBCXX),) + TARGET_CXX=g++-uc +endif TARGET_CFLAGS += $(FPIC) diff --git a/utils/nano/Makefile b/utils/nano/Makefile index 49f0b9bb9..e1600c03b 100644 --- a/utils/nano/Makefile +++ b/utils/nano/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,12 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=nano -PKG_VERSION:=2.3.6 +PKG_VERSION:=2.4.1 PKG_RELEASE:=1 +PKG_LICENSE:=GPL-3.0+ +PKG_LICENSE_FILES:=COPYING PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=http://www.nano-editor.org/dist/v2.3 -PKG_MD5SUM:=df3d201aecb3155a80633990cc467831 +PKG_SOURCE_URL:=http://www.nano-editor.org/dist/v2.4 +PKG_MD5SUM:=1c612b478f976abf8ef926480c7a3684 PKG_INSTALL:=1 PKG_BUILD_PARALLEL:=1 diff --git a/utils/ncdu/Makefile b/utils/ncdu/Makefile index edd852758..39f6b78ef 100644 --- a/utils/ncdu/Makefile +++ b/utils/ncdu/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2014 OpenWrt.org +# Copyright (C) 2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,14 +8,15 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ncdu -PKG_VERSION:=1.10 +PKG_VERSION:=1.11 PKG_RELEASE=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://dev.yorhel.nl/download -PKG_MD5SUM:=7535decc8d54eca811493e82d4bfab2d +PKG_MD5SUM:=9e44240a5356b029f05f0e70a63c4d12 PKG_INSTALL:=1 +PKG_BUILD_PARALLEL:=1 PKG_LICENSE:=MIT PKG_LICENSE_FILES:=COPYING @@ -26,7 +27,7 @@ define Package/ncdu SUBMENU:=Filesystem SECTION:=utils CATEGORY:=Utilities - DEPENDS:=+libncursesw + DEPENDS:=+libncurses TITLE:=ncurses disk usage viewer MAINTAINER:=Charles Lehner URL:=http://dev.yorhel.nl/ncdu @@ -38,6 +39,8 @@ define Package/ncdu/description directories and show percentages of disk usage with ncurses library. endef +CONFIGURE_ARGS += --with-ncurses + define Package/ncdu/install $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ncdu $(1)/usr/bin/ diff --git a/utils/ncdu/patches/010-add_sys_wait.patch b/utils/ncdu/patches/010-add_sys_wait.patch new file mode 100644 index 000000000..dfc06117e --- /dev/null +++ b/utils/ncdu/patches/010-add_sys_wait.patch @@ -0,0 +1,10 @@ +--- a/src/shell.c ++++ b/src/shell.c +@@ -33,6 +33,7 @@ + #include + #include ++#include + + void shell_draw() { + char *full_path; + int res; diff --git a/utils/ntfs-3g/patches/001-fuseint-fix-path-mounted-on-musl.patch b/utils/ntfs-3g/patches/001-fuseint-fix-path-mounted-on-musl.patch new file mode 100644 index 000000000..577c89bf2 --- /dev/null +++ b/utils/ntfs-3g/patches/001-fuseint-fix-path-mounted-on-musl.patch @@ -0,0 +1,30 @@ +Index: ntfs-3g-2014.2.15-1-fuseint/libfuse-lite/fusermount.c +=================================================================== +--- ntfs-3g-2014.2.15-1-fuseint.orig/libfuse-lite/fusermount.c ++++ ntfs-3g-2014.2.15-1-fuseint/libfuse-lite/fusermount.c +@@ -36,6 +36,10 @@ + + #define FUSE_DEV_NEW "/dev/fuse" + ++#ifndef _PATH_MOUNTED ++#define _PATH_MOUNTED "/proc/mounts" ++#endif ++ + #ifndef MS_DIRSYNC + #define MS_DIRSYNC 128 + #endif +Index: ntfs-3g-2014.2.15-1-fuseint/libfuse-lite/mount_util.c +=================================================================== +--- ntfs-3g-2014.2.15-1-fuseint.orig/libfuse-lite/mount_util.c ++++ ntfs-3g-2014.2.15-1-fuseint/libfuse-lite/mount_util.c +@@ -255,6 +255,10 @@ int fuse_mnt_check_fuseblk(void) + + #else /* __SOLARIS__ */ + ++#ifndef _PATH_MOUNTED ++#define _PATH_MOUNTED "/proc/mounts" ++#endif /* _PATH_MOUNTED */ ++ + static int mtab_needs_update(const char *mnt) + { + int res; diff --git a/utils/open-plc-utils/Makefile b/utils/open-plc-utils/Makefile index c7e19f18b..480711a74 100644 --- a/utils/open-plc-utils/Makefile +++ b/utils/open-plc-utils/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2013-2014 OpenWrt.org +# Copyright (C) 2013-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=open-plc-utils -PKG_VERSION:=2013-01-29 +PKG_VERSION:=2015-06-26 PKG_RELEASE:=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=git://github.com/qca/open-plc-utils.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=6beeb6fe6ce2b16b14284c26e1b9220b68044591 +PKG_SOURCE_VERSION:=1f6e7e372b313cf570aa63314037588ed01ec0de PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_MAINTAINER:=Florian Fainelli diff --git a/utils/open-plc-utils/patches/100-musl-compat.patch b/utils/open-plc-utils/patches/100-musl-compat.patch new file mode 100644 index 000000000..c20c0a1fe --- /dev/null +++ b/utils/open-plc-utils/patches/100-musl-compat.patch @@ -0,0 +1,33 @@ +--- a/ether/readpacket.c ++++ b/ether/readpacket.c +@@ -70,6 +70,10 @@ + #include + #include + ++#if defined (__linux__) ++#include ++#endif ++ + #include "../ether/channel.h" + #include "../tools/memory.h" + #include "../tools/error.h" +@@ -95,8 +99,6 @@ ssize_t readpacket (struct channel const + + #elif defined (__linux__) + +-#include +- + struct pollfd pollfd = + { + channel->fd, +--- a/serial/serial.c ++++ b/serial/serial.c +@@ -69,6 +69,8 @@ + + #if defined (WIN32) + #include ++#else ++#include + #endif + + /*====================================================================* diff --git a/utils/openocd/Makefile b/utils/openocd/Makefile index aadd3e2f3..2d22e4d36 100644 --- a/utils/openocd/Makefile +++ b/utils/openocd/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openocd -PKG_VERSION:=v0.8.0-258-gd537cfa -PKG_RELEASE:=2 +PKG_VERSION:=v0.9.0 +PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=git://git.code.sf.net/p/openocd/code @@ -56,6 +56,7 @@ endef CONFIGURE_ARGS += \ --prefix="/usr" \ --disable-werror \ + MAKEINFO=true \ --enable-dummy \ --enable-sysfsgpio \ --enable-usb_blaster_libftdi \ diff --git a/utils/opensc/Makefile b/utils/opensc/Makefile index a7b830149..adb249f82 100644 --- a/utils/opensc/Makefile +++ b/utils/opensc/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=opensc -PKG_VERSION:=20141126 +PKG_VERSION:=20150513 PKG_RELEASE:=1 PKG_LICENSE:=LGPL-2.1+ PKG_LICENSE_FILES:=COPYING @@ -19,7 +19,7 @@ PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/OpenSC/OpenSC.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=8aadbbd678730dbafb819382da553439887499fd +PKG_SOURCE_VERSION:=a09ca246a797230c14bc33a34f2dddc4a4dbff40 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_BUILD_DEPENDS:=+libpcsclite PKG_FIXUP:=libtool diff --git a/utils/opensc/patches/0001-OpenPGP-Detect-and-support-Gnuk-Token.patch b/utils/opensc/patches/0001-OpenPGP-Detect-and-support-Gnuk-Token.patch index 08b2a8324..3bd03a6f2 100644 --- a/utils/opensc/patches/0001-OpenPGP-Detect-and-support-Gnuk-Token.patch +++ b/utils/opensc/patches/0001-OpenPGP-Detect-and-support-Gnuk-Token.patch @@ -11,11 +11,11 @@ http://www.fsij.org/gnuk/ src/tools/openpgp-tool.c | 7 ++++- 3 files changed, 55 insertions(+), 14 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 6774fe1..c785a55 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -43,6 +43,7 @@ +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -45,6 +45,7 @@ static struct sc_atr_table pgp_atrs[] = { { "3b:fa:13:00:ff:81:31:80:45:00:31:c1:73:c0:01:00:00:90:00:b1", NULL, "OpenPGP card v1.0/1.1", SC_CARD_TYPE_OPENPGP_V1, 0, NULL }, { "3b:da:18:ff:81:b1:fe:75:1f:03:00:31:c5:73:c0:01:40:00:90:00:0c", NULL, "CryptoStick v1.2 (OpenPGP v2.0)", SC_CARD_TYPE_OPENPGP_V2, 0, NULL }, @@ -23,16 +23,16 @@ index 6774fe1..c785a55 100644 { NULL, NULL, NULL, 0, 0, NULL } }; -@@ -307,6 +308,8 @@ pgp_init(sc_card_t *card) +@@ -309,6 +310,8 @@ pgp_init(sc_card_t *card) int r; - struct blob *child = NULL; + struct blob *child = NULL; + LOG_FUNC_CALLED(card->ctx); + priv = calloc (1, sizeof *priv); if (!priv) return SC_ERROR_OUT_OF_MEMORY; -@@ -315,11 +318,11 @@ pgp_init(sc_card_t *card) +@@ -317,11 +320,11 @@ pgp_init(sc_card_t *card) card->cla = 0x00; /* set pointer to correct list of card objects */ @@ -46,7 +46,7 @@ index 6774fe1..c785a55 100644 ? OPENPGP_CARD_2_0 : OPENPGP_CARD_1_1; /* select application "OpenPGP" */ -@@ -428,7 +431,8 @@ pgp_get_card_features(sc_card_t *card) +@@ -436,7 +439,8 @@ pgp_get_card_features(sc_card_t *card) if ((pgp_get_blob(card, blob73, 0x00c0, &blob) >= 0) && (blob->data != NULL) && (blob->len > 0)) { /* in v2.0 bit 0x04 in first byte means "algorithm attributes changeable */ @@ -56,7 +56,7 @@ index 6774fe1..c785a55 100644 priv->ext_caps |= EXT_CAP_ALG_ATTR_CHANGEABLE; /* bit 0x08 in first byte means "support for private use DOs" */ if (blob->data[0] & 0x08) -@@ -445,7 +449,8 @@ pgp_get_card_features(sc_card_t *card) +@@ -453,7 +457,8 @@ pgp_get_card_features(sc_card_t *card) priv->ext_caps |= EXT_CAP_GET_CHALLENGE; } /* in v2.0 bit 0x80 in first byte means "support Secure Messaging" */ @@ -66,7 +66,7 @@ index 6774fe1..c785a55 100644 priv->ext_caps |= EXT_CAP_SM; if ((priv->bcd_version >= OPENPGP_CARD_2_0) && (blob->len >= 10)) { -@@ -1057,12 +1062,18 @@ static int +@@ -1065,12 +1070,18 @@ static int pgp_get_pubkey(sc_card_t *card, unsigned int tag, u8 *buf, size_t buf_len) { sc_apdu_t apdu; @@ -86,7 +86,7 @@ index 6774fe1..c785a55 100644 apdu.lc = 2; apdu.data = ushort2bebytes(idbuf, tag); apdu.datalen = 2; -@@ -1154,6 +1165,7 @@ pgp_put_data(sc_card_t *card, unsigned int tag, const u8 *buf, size_t buf_len) +@@ -1162,6 +1173,7 @@ pgp_put_data(sc_card_t *card, unsigned i u8 ins = 0xDA; u8 p1 = tag >> 8; u8 p2 = tag & 0xFF; @@ -94,7 +94,7 @@ index 6774fe1..c785a55 100644 int r; LOG_FUNC_CALLED(card->ctx); -@@ -1195,13 +1207,17 @@ pgp_put_data(sc_card_t *card, unsigned int tag, const u8 *buf, size_t buf_len) +@@ -1203,13 +1215,17 @@ pgp_put_data(sc_card_t *card, unsigned i /* Build APDU */ if (buf != NULL && buf_len > 0) { @@ -114,7 +114,7 @@ index 6774fe1..c785a55 100644 apdu.datalen = buf_len; apdu.lc = buf_len; } -@@ -1328,6 +1344,7 @@ pgp_compute_signature(sc_card_t *card, const u8 *data, +@@ -1336,6 +1352,7 @@ pgp_compute_signature(sc_card_t *card, c struct pgp_priv_data *priv = DRVDATA(card); sc_security_env_t *env = &priv->sec_env; sc_apdu_t apdu; @@ -122,7 +122,7 @@ index 6774fe1..c785a55 100644 int r; LOG_FUNC_CALLED(card->ctx); -@@ -1336,14 +1353,19 @@ pgp_compute_signature(sc_card_t *card, const u8 *data, +@@ -1344,14 +1361,19 @@ pgp_compute_signature(sc_card_t *card, c LOG_TEST_RET(card->ctx, SC_ERROR_INVALID_ARGUMENTS, "invalid operation"); @@ -144,7 +144,7 @@ index 6774fe1..c785a55 100644 break; case 0x01: default: -@@ -1352,7 +1374,7 @@ pgp_compute_signature(sc_card_t *card, const u8 *data, +@@ -1360,7 +1382,7 @@ pgp_compute_signature(sc_card_t *card, c } apdu.lc = data_len; @@ -153,7 +153,7 @@ index 6774fe1..c785a55 100644 apdu.datalen = data_len; apdu.le = ((outlen >= 256) && !(card->caps & SC_CARD_CAP_APDU_EXT)) ? 256 : outlen; apdu.resp = out; -@@ -1376,6 +1398,7 @@ pgp_decipher(sc_card_t *card, const u8 *in, size_t inlen, +@@ -1384,6 +1406,7 @@ pgp_decipher(sc_card_t *card, const u8 * struct pgp_priv_data *priv = DRVDATA(card); sc_security_env_t *env = &priv->sec_env; sc_apdu_t apdu; @@ -161,7 +161,7 @@ index 6774fe1..c785a55 100644 u8 *temp = NULL; int r; -@@ -1400,7 +1423,7 @@ pgp_decipher(sc_card_t *card, const u8 *in, size_t inlen, +@@ -1408,7 +1431,7 @@ pgp_decipher(sc_card_t *card, const u8 * case 0x01: /* Decryption key */ case 0x02: /* authentication key */ /* PSO DECIPHER */ @@ -170,7 +170,7 @@ index 6774fe1..c785a55 100644 break; case 0x00: /* signature key */ default: -@@ -1409,8 +1432,13 @@ pgp_decipher(sc_card_t *card, const u8 *in, size_t inlen, +@@ -1417,8 +1440,13 @@ pgp_decipher(sc_card_t *card, const u8 * "invalid key reference"); } @@ -185,7 +185,7 @@ index 6774fe1..c785a55 100644 apdu.datalen = inlen; apdu.le = ((outlen >= 256) && !(card->caps & SC_CARD_CAP_APDU_EXT)) ? 256 : outlen; apdu.resp = out; -@@ -1794,6 +1822,11 @@ static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_in +@@ -1802,6 +1830,11 @@ static int pgp_gen_key(sc_card_t *card, LOG_FUNC_RETURN(card->ctx, SC_ERROR_INVALID_ARGUMENTS); } @@ -197,7 +197,7 @@ index 6774fe1..c785a55 100644 /* Set attributes for new-generated key */ r = pgp_update_new_algo_attr(card, key_info); LOG_TEST_RET(card->ctx, r, "Cannot set attributes for new-generated key"); -@@ -1801,7 +1834,9 @@ static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_in +@@ -1809,7 +1842,9 @@ static int pgp_gen_key(sc_card_t *card, /* Test whether we will need extended APDU. 1900 is an * arbitrary modulus length which for sure fits into a short APDU. * This idea is borrowed from GnuPG code. */ @@ -208,10 +208,10 @@ index 6774fe1..c785a55 100644 /* We won't store to apdu variable yet, because it will be reset in * sc_format_apdu() */ apdu_le = card->max_recv_size; -diff --git a/src/libopensc/cards.h b/src/libopensc/cards.h -index 7be6667..a3f3634 100644 ---- a/src/libopensc/cards.h -+++ b/src/libopensc/cards.h +Index: opensc-20150513/src/libopensc/cards.h +=================================================================== +--- opensc-20150513.orig/src/libopensc/cards.h ++++ opensc-20150513/src/libopensc/cards.h @@ -105,6 +105,7 @@ enum { SC_CARD_TYPE_OPENPGP_BASE = 9000, SC_CARD_TYPE_OPENPGP_V1, @@ -220,10 +220,10 @@ index 7be6667..a3f3634 100644 /* jcop driver */ SC_CARD_TYPE_JCOP_BASE = 10000, -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index f42e6d6..a24a395 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c @@ -33,6 +33,7 @@ #include "libopensc/cards.h" #include "libopensc/cardctl.h" @@ -232,7 +232,7 @@ index f42e6d6..a24a395 100644 #include "util.h" #include "libopensc/log.h" -@@ -396,6 +397,8 @@ int do_genkey(sc_card_t *card, u8 key_id, unsigned int key_len) +@@ -396,6 +397,8 @@ int do_genkey(sc_card_t *card, u8 key_id sc_path_t path; sc_file_t *file; @@ -253,6 +253,3 @@ index f42e6d6..a24a395 100644 exit_status = EXIT_FAILURE; goto out; } --- -2.1.3 - diff --git a/utils/opensc/patches/0002-OpenPGP-Add-Gnuk-in-pkcs15-emulation-layer.patch b/utils/opensc/patches/0002-OpenPGP-Add-Gnuk-in-pkcs15-emulation-layer.patch index c08a6e0a3..2514c16df 100644 --- a/utils/opensc/patches/0002-OpenPGP-Add-Gnuk-in-pkcs15-emulation-layer.patch +++ b/utils/opensc/patches/0002-OpenPGP-Add-Gnuk-in-pkcs15-emulation-layer.patch @@ -9,11 +9,11 @@ Subject: [PATCH 02/26] OpenPGP: Add Gnuk in pkcs15 emulation layer. src/libopensc/pkcs15-syn.c | 1 + 2 files changed, 5 insertions(+), 2 deletions(-) -diff --git a/src/libopensc/pkcs15-openpgp.c b/src/libopensc/pkcs15-openpgp.c -index 4daaa98..fdf720a 100644 ---- a/src/libopensc/pkcs15-openpgp.c -+++ b/src/libopensc/pkcs15-openpgp.c -@@ -151,7 +151,8 @@ sc_pkcs15emu_openpgp_init(sc_pkcs15_card_t *p15card) +Index: opensc-20150513/src/libopensc/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/pkcs15-openpgp.c ++++ opensc-20150513/src/libopensc/pkcs15-openpgp.c +@@ -153,7 +153,8 @@ sc_pkcs15emu_openpgp_init(sc_pkcs15_card u8 c4data[10]; u8 c5data[70]; int r, i; @@ -23,7 +23,7 @@ index 4daaa98..fdf720a 100644 sc_path_t path; sc_file_t *file; -@@ -363,7 +364,8 @@ failed: sc_debug(card->ctx, SC_LOG_DEBUG_NORMAL, "Failed to initialize OpenPGP e +@@ -365,7 +366,8 @@ failed: sc_debug(card->ctx, SC_LOG_DEBUG static int openpgp_detect_card(sc_pkcs15_card_t *p15card) { @@ -33,11 +33,11 @@ index 4daaa98..fdf720a 100644 return SC_SUCCESS; else return SC_ERROR_WRONG_CARD; -diff --git a/src/libopensc/pkcs15-syn.c b/src/libopensc/pkcs15-syn.c -index ffbf642..d2c086c 100644 ---- a/src/libopensc/pkcs15-syn.c -+++ b/src/libopensc/pkcs15-syn.c -@@ -115,6 +115,7 @@ int sc_pkcs15_is_emulation_only(sc_card_t *card) +Index: opensc-20150513/src/libopensc/pkcs15-syn.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/pkcs15-syn.c ++++ opensc-20150513/src/libopensc/pkcs15-syn.c +@@ -117,6 +117,7 @@ int sc_pkcs15_is_emulation_only(sc_card_ case SC_CARD_TYPE_GEMSAFEV1_PTEID: case SC_CARD_TYPE_OPENPGP_V1: case SC_CARD_TYPE_OPENPGP_V2: @@ -45,6 +45,3 @@ index ffbf642..d2c086c 100644 case SC_CARD_TYPE_SC_HSM: case SC_CARD_TYPE_DNIE_BASE: case SC_CARD_TYPE_DNIE_BLANK: --- -2.1.3 - diff --git a/utils/opensc/patches/0003-OpenPGP-Include-private-DO-to-filesystem-at-driver-i.patch b/utils/opensc/patches/0003-OpenPGP-Include-private-DO-to-filesystem-at-driver-i.patch index 9e96cfef6..49fce825b 100644 --- a/utils/opensc/patches/0003-OpenPGP-Include-private-DO-to-filesystem-at-driver-i.patch +++ b/utils/opensc/patches/0003-OpenPGP-Include-private-DO-to-filesystem-at-driver-i.patch @@ -12,11 +12,11 @@ leading to that we cannot read their data later, even if we verified PIN. src/libopensc/card-openpgp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index c785a55..1cc3923 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -357,7 +357,7 @@ pgp_init(sc_card_t *card) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -365,7 +365,7 @@ pgp_init(sc_card_t *card) /* Populate MF - add matching blobs listed in the pgp_objects table. */ for (info = priv->pgp_objects; (info != NULL) && (info->id > 0); info++) { @@ -25,6 +25,3 @@ index c785a55..1cc3923 100644 (info->get_fn != NULL)) { child = pgp_new_blob(card, priv->mf, info->id, sc_file_new()); --- -2.1.3 - diff --git a/utils/opensc/patches/0004-PKCS15-OpenPGP-Declare-DATA-objects.patch b/utils/opensc/patches/0004-PKCS15-OpenPGP-Declare-DATA-objects.patch index b6408de7f..619ea8cc4 100644 --- a/utils/opensc/patches/0004-PKCS15-OpenPGP-Declare-DATA-objects.patch +++ b/utils/opensc/patches/0004-PKCS15-OpenPGP-Declare-DATA-objects.patch @@ -10,11 +10,11 @@ This object is used by TrueCrypt. src/libopensc/pkcs15-openpgp.c | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) -diff --git a/src/libopensc/pkcs15-openpgp.c b/src/libopensc/pkcs15-openpgp.c -index fdf720a..fea2805 100644 ---- a/src/libopensc/pkcs15-openpgp.c -+++ b/src/libopensc/pkcs15-openpgp.c -@@ -32,6 +32,7 @@ +Index: opensc-20150513/src/libopensc/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/pkcs15-openpgp.c ++++ opensc-20150513/src/libopensc/pkcs15-openpgp.c +@@ -34,6 +34,7 @@ #include "log.h" int sc_pkcs15emu_openpgp_init_ex(sc_pkcs15_card_t *, sc_pkcs15emu_opt_t *); @@ -22,7 +22,7 @@ index fdf720a..fea2805 100644 #define PGP_USER_PIN_FLAGS (SC_PKCS15_PIN_FLAG_CASE_SENSITIVE \ -@@ -41,6 +42,8 @@ int sc_pkcs15emu_openpgp_init_ex(sc_pkcs15_card_t *, sc_pkcs15emu_opt_t *); +@@ -43,6 +44,8 @@ int sc_pkcs15emu_openpgp_init_ex(sc_pkcs | SC_PKCS15_PIN_FLAG_UNBLOCK_DISABLED \ | SC_PKCS15_PIN_FLAG_SO_PIN) @@ -31,7 +31,7 @@ index fdf720a..fea2805 100644 typedef struct _pgp_pin_cfg { const char *label; int reference; -@@ -355,6 +358,9 @@ sc_pkcs15emu_openpgp_init(sc_pkcs15_card_t *p15card) +@@ -357,6 +360,9 @@ sc_pkcs15emu_openpgp_init(sc_pkcs15_card goto failed; } @@ -41,7 +41,7 @@ index fdf720a..fea2805 100644 return 0; failed: sc_debug(card->ctx, SC_LOG_DEBUG_NORMAL, "Failed to initialize OpenPGP emulation: %s\n", -@@ -362,6 +368,35 @@ failed: sc_debug(card->ctx, SC_LOG_DEBUG_NORMAL, "Failed to initialize OpenPGP e +@@ -364,6 +370,35 @@ failed: sc_debug(card->ctx, SC_LOG_DEBUG return r; } @@ -77,6 +77,3 @@ index fdf720a..fea2805 100644 static int openpgp_detect_card(sc_pkcs15_card_t *p15card) { if (p15card->card->type == SC_CARD_TYPE_OPENPGP_V1 || p15card->card->type == SC_CARD_TYPE_OPENPGP_V2 --- -2.1.3 - diff --git a/utils/opensc/patches/0005-OpenPGP-Support-erasing-reset-card.patch b/utils/opensc/patches/0005-OpenPGP-Support-erasing-reset-card.patch index 0dc495462..aa3c9d38b 100644 --- a/utils/opensc/patches/0005-OpenPGP-Support-erasing-reset-card.patch +++ b/utils/opensc/patches/0005-OpenPGP-Support-erasing-reset-card.patch @@ -10,11 +10,11 @@ Command: openpgp-tool --erase src/tools/openpgp-tool.c | 22 ++++++++++++++- 2 files changed, 85 insertions(+), 1 deletion(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 1cc3923..7349876 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -2195,6 +2195,66 @@ out: +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -2206,6 +2206,66 @@ out: #endif /* ENABLE_OPENSSL */ @@ -81,7 +81,7 @@ index 1cc3923..7349876 100644 /* ABI: card ctl: perform special card-specific operations */ static int pgp_card_ctl(sc_card_t *card, unsigned long cmd, void *ptr) { -@@ -2219,6 +2279,10 @@ static int pgp_card_ctl(sc_card_t *card, unsigned long cmd, void *ptr) +@@ -2232,6 +2292,10 @@ static int pgp_card_ctl(sc_card_t *card, LOG_FUNC_RETURN(card->ctx, r); break; #endif /* ENABLE_OPENSSL */ @@ -92,12 +92,12 @@ index 1cc3923..7349876 100644 } LOG_FUNC_RETURN(card->ctx, SC_ERROR_NOT_SUPPORTED); -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index a24a395..de1c9d4 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c @@ -78,6 +78,7 @@ static int opt_pin = 0; - static char *pin = NULL; + static const char *pin = NULL; static int opt_dump_do = 0; static u8 do_dump_idx; +static int opt_erase = 0; @@ -120,7 +120,7 @@ index a24a395..de1c9d4 100644 "Verify PIN (CHV1, CHV2, CHV3...)", "PIN string", /* d */ "Dump private data object number (i.e. PRIVATE-DO-)" -@@ -232,7 +235,7 @@ static int decode_options(int argc, char **argv) +@@ -232,7 +235,7 @@ static int decode_options(int argc, char { int c; @@ -129,7 +129,7 @@ index a24a395..de1c9d4 100644 switch (c) { case 'r': opt_reader = optarg; -@@ -296,6 +299,8 @@ static int decode_options(int argc, char **argv) +@@ -294,6 +297,8 @@ static int decode_options(int argc, char do_dump_idx = optarg[0] - '0'; opt_dump_do++; actions++; @@ -138,7 +138,7 @@ index a24a395..de1c9d4 100644 break; default: util_print_usage_and_die(app_name, options, option_help, NULL); -@@ -452,6 +457,18 @@ int do_verify(sc_card_t *card, char *type, char *pin) +@@ -452,6 +457,18 @@ int do_verify(sc_card_t *card, char *typ return r; } @@ -167,6 +167,3 @@ index a24a395..de1c9d4 100644 out: sc_unlock(card); sc_disconnect_card(card); --- -2.1.3 - diff --git a/utils/opensc/patches/0006-openpgp-tool-Support-deleting-key-in-Gnuk.patch b/utils/opensc/patches/0006-openpgp-tool-Support-deleting-key-in-Gnuk.patch index 915f6842c..4286e4604 100644 --- a/utils/opensc/patches/0006-openpgp-tool-Support-deleting-key-in-Gnuk.patch +++ b/utils/opensc/patches/0006-openpgp-tool-Support-deleting-key-in-Gnuk.patch @@ -8,10 +8,10 @@ Subject: [PATCH 06/26] openpgp-tool: Support deleting key in Gnuk. src/tools/openpgp-tool.c | 142 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 142 insertions(+) -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index de1c9d4..374819a 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c @@ -41,6 +41,7 @@ #define OPT_PRETTY 257 #define OPT_VERIFY 258 @@ -20,7 +20,7 @@ index de1c9d4..374819a 100644 /* define structures */ struct ef_name_map { -@@ -79,6 +80,7 @@ static char *pin = NULL; +@@ -79,6 +80,7 @@ static const char *pin = NULL; static int opt_dump_do = 0; static u8 do_dump_idx; static int opt_erase = 0; @@ -44,7 +44,7 @@ index de1c9d4..374819a 100644 /* d */ "Dump private data object number (i.e. PRIVATE-DO-)" }; -@@ -302,6 +306,14 @@ static int decode_options(int argc, char **argv) +@@ -300,6 +304,14 @@ static int decode_options(int argc, char case 'E': opt_erase++; break; @@ -59,7 +59,7 @@ index de1c9d4..374819a 100644 default: util_print_usage_and_die(app_name, options, option_help, NULL); } -@@ -457,6 +469,133 @@ int do_verify(sc_card_t *card, char *type, char *pin) +@@ -457,6 +469,133 @@ int do_verify(sc_card_t *card, char *typ return r; } @@ -203,6 +203,3 @@ index de1c9d4..374819a 100644 if (opt_erase) exit_status != do_erase(card); --- -2.1.3 - diff --git a/utils/opensc/patches/0007-OpenPGP-Correct-building-Extended-Header-List-when-i.patch b/utils/opensc/patches/0007-OpenPGP-Correct-building-Extended-Header-List-when-i.patch index 7d8045679..f5b2cc045 100644 --- a/utils/opensc/patches/0007-OpenPGP-Correct-building-Extended-Header-List-when-i.patch +++ b/utils/opensc/patches/0007-OpenPGP-Correct-building-Extended-Header-List-when-i.patch @@ -9,11 +9,11 @@ Subject: [PATCH 07/26] OpenPGP: Correct building Extended Header List when src/libopensc/card-openpgp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 7349876..91c311b 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -1977,7 +1977,7 @@ pgp_build_extended_header_list(sc_card_t *card, sc_cardctl_openpgp_keystore_info +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -1988,7 +1988,7 @@ pgp_build_extended_header_list(sc_card_t u8 *p = NULL; u8 *components[] = {key_info->e, key_info->p, key_info->q, key_info->n}; size_t componentlens[] = {key_info->e_len, key_info->p_len, key_info->q_len, key_info->n_len}; @@ -22,6 +22,3 @@ index 7349876..91c311b 100644 char *componentnames[] = { "public exponent", "prime p", --- -2.1.3 - diff --git a/utils/opensc/patches/0008-OpenPGP-Read-some-empty-DOs-from-Gnuk.patch b/utils/opensc/patches/0008-OpenPGP-Read-some-empty-DOs-from-Gnuk.patch index 17aaf92ca..9d942d0f5 100644 --- a/utils/opensc/patches/0008-OpenPGP-Read-some-empty-DOs-from-Gnuk.patch +++ b/utils/opensc/patches/0008-OpenPGP-Read-some-empty-DOs-from-Gnuk.patch @@ -10,11 +10,11 @@ So, we will consider them exist in driver. src/libopensc/card-openpgp.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 91c311b..e7b25c0 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -815,6 +815,23 @@ pgp_get_blob(sc_card_t *card, struct blob *blob, unsigned int id, +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -823,6 +823,23 @@ pgp_get_blob(sc_card_t *card, struct blo } } @@ -38,7 +38,7 @@ index 91c311b..e7b25c0 100644 return SC_ERROR_FILE_NOT_FOUND; } -@@ -1149,6 +1166,14 @@ pgp_get_data(sc_card_t *card, unsigned int tag, u8 *buf, size_t buf_len) +@@ -1157,6 +1174,14 @@ pgp_get_data(sc_card_t *card, unsigned i LOG_TEST_RET(card->ctx, r, "APDU transmit failed"); r = sc_check_sw(card, apdu.sw1, apdu.sw2); @@ -53,6 +53,3 @@ index 91c311b..e7b25c0 100644 LOG_TEST_RET(card->ctx, r, "Card returned error"); LOG_FUNC_RETURN(card->ctx, apdu.resplen); --- -2.1.3 - diff --git a/utils/opensc/patches/0009-PKCS15-OpenPGP-Do-not-show-empty-DO-in-pkcs15-emu_in.patch b/utils/opensc/patches/0009-PKCS15-OpenPGP-Do-not-show-empty-DO-in-pkcs15-emu_in.patch index a75a2c2ce..16431a4d9 100644 --- a/utils/opensc/patches/0009-PKCS15-OpenPGP-Do-not-show-empty-DO-in-pkcs15-emu_in.patch +++ b/utils/opensc/patches/0009-PKCS15-OpenPGP-Do-not-show-empty-DO-in-pkcs15-emu_in.patch @@ -9,11 +9,11 @@ Subject: [PATCH 09/26] PKCS15-OpenPGP: Do not show empty DO in pkcs15 src/libopensc/pkcs15-openpgp.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) -diff --git a/src/libopensc/pkcs15-openpgp.c b/src/libopensc/pkcs15-openpgp.c -index fea2805..51a2032 100644 ---- a/src/libopensc/pkcs15-openpgp.c -+++ b/src/libopensc/pkcs15-openpgp.c -@@ -381,16 +381,34 @@ sc_pkcs15emu_openpgp_add_data(sc_pkcs15_card_t *p15card) +Index: opensc-20150513/src/libopensc/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/pkcs15-openpgp.c ++++ opensc-20150513/src/libopensc/pkcs15-openpgp.c +@@ -383,16 +383,34 @@ sc_pkcs15emu_openpgp_add_data(sc_pkcs15_ sc_pkcs15_object_t dat_obj; char name[8]; char path[9]; @@ -48,6 +48,3 @@ index fea2805..51a2032 100644 sc_log(ctx, "Add %s data object", name); r = sc_pkcs15emu_add_data_object(p15card, &dat_obj, &dat_info); } --- -2.1.3 - diff --git a/utils/opensc/patches/0010-PKCS15-OpenPGP-Allow-to-store-data-to-pkcs15-data-ob.patch b/utils/opensc/patches/0010-PKCS15-OpenPGP-Allow-to-store-data-to-pkcs15-data-ob.patch index 7b0f493cc..afcf9d598 100644 --- a/utils/opensc/patches/0010-PKCS15-OpenPGP-Allow-to-store-data-to-pkcs15-data-ob.patch +++ b/utils/opensc/patches/0010-PKCS15-OpenPGP-Allow-to-store-data-to-pkcs15-data-ob.patch @@ -11,11 +11,11 @@ Only one DO is supported now. src/pkcs15init/pkcs15-openpgp.c | 38 +++++++++++++++++++++++++++++++++++++- 2 files changed, 38 insertions(+), 2 deletions(-) -diff --git a/src/libopensc/pkcs15-openpgp.c b/src/libopensc/pkcs15-openpgp.c -index 51a2032..4cc1c39 100644 ---- a/src/libopensc/pkcs15-openpgp.c -+++ b/src/libopensc/pkcs15-openpgp.c -@@ -393,7 +393,7 @@ sc_pkcs15emu_openpgp_add_data(sc_pkcs15_card_t *p15card) +Index: opensc-20150513/src/libopensc/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/pkcs15-openpgp.c ++++ opensc-20150513/src/libopensc/pkcs15-openpgp.c +@@ -395,7 +395,7 @@ sc_pkcs15emu_openpgp_add_data(sc_pkcs15_ */ r = read_file(p15card->card, path, content, sizeof(content)); if (r <= 0 ) { @@ -24,11 +24,11 @@ index 51a2032..4cc1c39 100644 /* Skip */ continue; } -diff --git a/src/pkcs15init/pkcs15-openpgp.c b/src/pkcs15init/pkcs15-openpgp.c -index f3a4962..1455580 100755 ---- a/src/pkcs15init/pkcs15-openpgp.c -+++ b/src/pkcs15init/pkcs15-openpgp.c -@@ -236,13 +236,16 @@ static int openpgp_emu_update_tokeninfo(sc_profile_t *profile, sc_pkcs15_card_t +Index: opensc-20150513/src/pkcs15init/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/pkcs15init/pkcs15-openpgp.c ++++ opensc-20150513/src/pkcs15init/pkcs15-openpgp.c +@@ -236,13 +236,16 @@ static int openpgp_emu_update_tokeninfo( } static int openpgp_store_data(struct sc_pkcs15_card *p15card, struct sc_profile *profile, @@ -46,7 +46,7 @@ index f3a4962..1455580 100755 int r; LOG_FUNC_CALLED(card->ctx); -@@ -282,6 +285,39 @@ static int openpgp_store_data(struct sc_pkcs15_card *p15card, struct sc_profile +@@ -282,6 +285,39 @@ static int openpgp_store_data(struct sc_ content->len, 0); break; @@ -86,6 +86,3 @@ index f3a4962..1455580 100755 default: r = SC_ERROR_NOT_IMPLEMENTED; } --- -2.1.3 - diff --git a/utils/opensc/patches/0011-OpenPGP-Provide-enough-buffer-to-read-pubkey-from-Gn.patch b/utils/opensc/patches/0011-OpenPGP-Provide-enough-buffer-to-read-pubkey-from-Gn.patch index d133e8059..a4c52621a 100644 --- a/utils/opensc/patches/0011-OpenPGP-Provide-enough-buffer-to-read-pubkey-from-Gn.patch +++ b/utils/opensc/patches/0011-OpenPGP-Provide-enough-buffer-to-read-pubkey-from-Gn.patch @@ -9,11 +9,11 @@ Subject: [PATCH 11/26] OpenPGP: Provide enough buffer to read pubkey from src/libopensc/card-openpgp.c | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index e7b25c0..1913eca 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -263,7 +263,12 @@ static struct do_info pgp2_objects[] = { /* OpenPGP card spec 2.0 */ +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -265,7 +265,12 @@ static struct do_info pgp2_objects[] = /* The DO holding X.509 certificate is constructed but does not contain child DO. * We should notice this when building fake file system later. */ @@ -27,7 +27,7 @@ index e7b25c0..1913eca 100644 #define DRVDATA(card) ((struct pgp_priv_data *) ((card)->drv_data)) struct pgp_priv_data { -@@ -731,6 +736,14 @@ pgp_read_blob(sc_card_t *card, struct blob *blob) +@@ -739,6 +744,14 @@ pgp_read_blob(sc_card_t *card, struct bl u8 buffer[2048]; size_t buf_len = (card->caps & SC_CARD_CAP_APDU_EXT) ? sizeof(buffer) : 256; @@ -42,7 +42,7 @@ index e7b25c0..1913eca 100644 int r = blob->info->get_fn(card, blob->id, buffer, buf_len); if (r < 0) { /* an error occurred */ -@@ -1828,6 +1841,7 @@ static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_in +@@ -1836,6 +1849,7 @@ static int pgp_gen_key(sc_card_t *card, u8 apdu_case; u8 *apdu_data; size_t apdu_le; @@ -50,7 +50,7 @@ index e7b25c0..1913eca 100644 int r = SC_SUCCESS; LOG_FUNC_CALLED(card->ctx); -@@ -1868,23 +1882,27 @@ static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_in +@@ -1876,23 +1890,27 @@ static int pgp_gen_key(sc_card_t *card, apdu_case = SC_APDU_CASE_4_EXT; } else { @@ -82,6 +82,3 @@ index e7b25c0..1913eca 100644 /* Send */ sc_log(card->ctx, "Waiting for the card to generate key..."); --- -2.1.3 - diff --git a/utils/opensc/patches/0012-OpenPGP-Support-write-certificate-for-Gnuk.patch b/utils/opensc/patches/0012-OpenPGP-Support-write-certificate-for-Gnuk.patch index 3a2526f4e..40c0c8541 100644 --- a/utils/opensc/patches/0012-OpenPGP-Support-write-certificate-for-Gnuk.patch +++ b/utils/opensc/patches/0012-OpenPGP-Support-write-certificate-for-Gnuk.patch @@ -8,11 +8,11 @@ Subject: [PATCH 12/26] OpenPGP: Support write certificate for Gnuk. src/libopensc/card-openpgp.c | 158 +++++++++++++++++++++++++++++++++---------- 1 file changed, 123 insertions(+), 35 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 1913eca..7cea84f 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -727,6 +727,8 @@ pgp_iterate_blobs(struct blob *blob, int level, void (*func)()) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -735,6 +735,8 @@ pgp_iterate_blobs(struct blob *blob, int static int pgp_read_blob(sc_card_t *card, struct blob *blob) { @@ -21,7 +21,7 @@ index 1913eca..7cea84f 100644 if (blob->data != NULL) return SC_SUCCESS; if (blob->info == NULL) -@@ -737,6 +739,11 @@ pgp_read_blob(sc_card_t *card, struct blob *blob) +@@ -745,6 +747,11 @@ pgp_read_blob(sc_card_t *card, struct bl size_t buf_len = (card->caps & SC_CARD_CAP_APDU_EXT) ? sizeof(buffer) : 256; @@ -33,7 +33,7 @@ index 1913eca..7cea84f 100644 /* Buffer length for Gnuk pubkey */ if (card->type == SC_CARD_TYPE_OPENPGP_GNUK && (blob->id == 0xa400 || blob->id == 0xb600 || blob->id == 0xb800 -@@ -1192,49 +1199,75 @@ pgp_get_data(sc_card_t *card, unsigned int tag, u8 *buf, size_t buf_len) +@@ -1200,49 +1207,75 @@ pgp_get_data(sc_card_t *card, unsigned i LOG_FUNC_RETURN(card->ctx, apdu.resplen); } @@ -143,7 +143,7 @@ index 1913eca..7cea84f 100644 /* Extended Header list (004D DO) needs a variant of PUT DATA command */ if (tag == 0x004D) { -@@ -1260,15 +1293,70 @@ pgp_put_data(sc_card_t *card, unsigned int tag, const u8 *buf, size_t buf_len) +@@ -1268,15 +1301,70 @@ pgp_put_data(sc_card_t *card, unsigned i apdu.lc = buf_len; } else { @@ -215,6 +215,3 @@ index 1913eca..7cea84f 100644 /* Instruct more in case of error */ if (r == SC_ERROR_SECURITY_STATUS_NOT_SATISFIED) { sc_debug(card->ctx, SC_LOG_DEBUG_VERBOSE, "Please verify PIN first."); --- -2.1.3 - diff --git a/utils/opensc/patches/0013-pkcs15-openpgp-Change-to-sc_put_data-instead-of-sc_u.patch b/utils/opensc/patches/0013-pkcs15-openpgp-Change-to-sc_put_data-instead-of-sc_u.patch index 48afb3739..c785a0dd5 100644 --- a/utils/opensc/patches/0013-pkcs15-openpgp-Change-to-sc_put_data-instead-of-sc_u.patch +++ b/utils/opensc/patches/0013-pkcs15-openpgp-Change-to-sc_put_data-instead-of-sc_u.patch @@ -9,11 +9,11 @@ Subject: [PATCH 13/26] pkcs15-openpgp: Change to sc_put_data instead of src/pkcs15init/pkcs15-openpgp.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) -diff --git a/src/pkcs15init/pkcs15-openpgp.c b/src/pkcs15init/pkcs15-openpgp.c -index 1455580..be1291e 100755 ---- a/src/pkcs15init/pkcs15-openpgp.c -+++ b/src/pkcs15init/pkcs15-openpgp.c -@@ -279,10 +279,9 @@ static int openpgp_store_data(struct sc_pkcs15_card *p15card, struct sc_profile +Index: opensc-20150513/src/pkcs15init/pkcs15-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/pkcs15init/pkcs15-openpgp.c ++++ opensc-20150513/src/pkcs15init/pkcs15-openpgp.c +@@ -279,10 +279,9 @@ static int openpgp_store_data(struct sc_ r = sc_select_file(card, path, &file); LOG_TEST_RET(card->ctx, r, "Cannot select cert file"); r = sc_pkcs15init_authenticate(profile, p15card, file, SC_AC_OP_UPDATE); @@ -26,6 +26,3 @@ index 1455580..be1291e 100755 break; case SC_PKCS15_TYPE_DATA_OBJECT: --- -2.1.3 - diff --git a/utils/opensc/patches/0014-OpenPGP-Overcome-the-restriction-of-even-data-length.patch b/utils/opensc/patches/0014-OpenPGP-Overcome-the-restriction-of-even-data-length.patch index 0fa8f2c3d..884e4fa7d 100644 --- a/utils/opensc/patches/0014-OpenPGP-Overcome-the-restriction-of-even-data-length.patch +++ b/utils/opensc/patches/0014-OpenPGP-Overcome-the-restriction-of-even-data-length.patch @@ -10,11 +10,11 @@ When write certificate with odd length to Gnuk, we add zero padding to make it e src/libopensc/card-openpgp.c | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 7cea84f..7a77a71 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -1208,6 +1208,10 @@ static int gnuk_write_certificate(sc_card_t *card, const u8 *buf, size_t length) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -1216,6 +1216,10 @@ static int gnuk_write_certificate(sc_car sc_apdu_t apdu; u8 *part; size_t plen; @@ -25,7 +25,7 @@ index 7cea84f..7a77a71 100644 int r = SC_SUCCESS; LOG_FUNC_CALLED(ctx); -@@ -1238,8 +1242,20 @@ static int gnuk_write_certificate(sc_card_t *card, const u8 *buf, size_t length) +@@ -1246,8 +1250,20 @@ static int gnuk_write_certificate(sc_car sc_format_apdu(card, &apdu, SC_APDU_CASE_3_SHORT, 0xD6, i, 0); } apdu.flags |= SC_APDU_FLAGS_CHAINING; @@ -48,6 +48,3 @@ index 7cea84f..7a77a71 100644 r = sc_transmit_apdu(card, &apdu); LOG_TEST_RET(card->ctx, r, "APDU transmit failed"); --- -2.1.3 - diff --git a/utils/opensc/patches/0015-OpenPGP-Delete-key-as-file-for-Gnuk.patch b/utils/opensc/patches/0015-OpenPGP-Delete-key-as-file-for-Gnuk.patch index 2389cd109..e9ac9d343 100644 --- a/utils/opensc/patches/0015-OpenPGP-Delete-key-as-file-for-Gnuk.patch +++ b/utils/opensc/patches/0015-OpenPGP-Delete-key-as-file-for-Gnuk.patch @@ -8,11 +8,11 @@ Subject: [PATCH 15/26] OpenPGP: Delete key as file, for Gnuk. src/libopensc/card-openpgp.c | 51 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 7a77a71..4d0500d 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -2435,6 +2435,44 @@ static int pgp_card_ctl(sc_card_t *card, unsigned long cmd, void *ptr) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -2448,6 +2448,44 @@ static int pgp_card_ctl(sc_card_t *card, LOG_FUNC_RETURN(card->ctx, SC_ERROR_NOT_SUPPORTED); } @@ -57,7 +57,7 @@ index 7a77a71..4d0500d 100644 /* ABI: DELETE FILE */ static int pgp_delete_file(sc_card_t *card, const sc_path_t *path) -@@ -2442,6 +2480,7 @@ pgp_delete_file(sc_card_t *card, const sc_path_t *path) +@@ -2455,6 +2493,7 @@ pgp_delete_file(sc_card_t *card, const s struct pgp_priv_data *priv = DRVDATA(card); struct blob *blob; sc_file_t *file; @@ -65,7 +65,7 @@ index 7a77a71..4d0500d 100644 int r; LOG_FUNC_CALLED(card->ctx); -@@ -2457,10 +2496,20 @@ pgp_delete_file(sc_card_t *card, const sc_path_t *path) +@@ -2470,10 +2509,20 @@ pgp_delete_file(sc_card_t *card, const s if (blob == priv->mf) LOG_FUNC_RETURN(card->ctx, SC_ERROR_NOT_SUPPORTED); @@ -87,6 +87,3 @@ index 7a77a71..4d0500d 100644 else { /* call pgp_put_data() with zero-sized NULL-buffer to zap the DO contents */ r = pgp_put_data(card, file->id, NULL, 0); --- -2.1.3 - diff --git a/utils/opensc/patches/0016-OpenPGP-Correct-parameter-checking.patch b/utils/opensc/patches/0016-OpenPGP-Correct-parameter-checking.patch index 76c8624e3..3f80a0602 100644 --- a/utils/opensc/patches/0016-OpenPGP-Correct-parameter-checking.patch +++ b/utils/opensc/patches/0016-OpenPGP-Correct-parameter-checking.patch @@ -8,11 +8,11 @@ Subject: [PATCH 16/26] OpenPGP: Correct parameter checking. src/libopensc/card-openpgp.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 4d0500d..beeee83 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -1223,6 +1223,8 @@ static int gnuk_write_certificate(sc_card_t *card, const u8 *buf, size_t length) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -1231,6 +1231,8 @@ static int gnuk_write_certificate(sc_car LOG_TEST_RET(card->ctx, r, "APDU transmit failed"); /* Check response */ r = sc_check_sw(card, apdu.sw1, apdu.sw2); @@ -21,7 +21,7 @@ index 4d0500d..beeee83 100644 LOG_FUNC_RETURN(card->ctx, length); } -@@ -2446,6 +2448,11 @@ gnuk_delete_key(sc_card_t *card, u8 key_id) +@@ -2459,6 +2461,11 @@ gnuk_delete_key(sc_card_t *card, u8 key_ LOG_FUNC_CALLED(ctx); @@ -33,7 +33,7 @@ index 4d0500d..beeee83 100644 /* Delete fingerprint */ sc_log(ctx, "Delete fingerprints"); r = pgp_put_data(card, 0xC6 + key_id, NULL, 0); -@@ -2464,8 +2471,6 @@ gnuk_delete_key(sc_card_t *card, u8 key_id) +@@ -2477,8 +2484,6 @@ gnuk_delete_key(sc_card_t *card, u8 key_ data = "\x4D\x02\xB8"; else if (key_id == 3) data = "\x4D\x02\xA4"; @@ -42,6 +42,3 @@ index 4d0500d..beeee83 100644 r = pgp_put_data(card, 0x4D, data, strlen(data) + 1); --- -2.1.3 - diff --git a/utils/opensc/patches/0017-OpenPGP-Make-code-neater.patch b/utils/opensc/patches/0017-OpenPGP-Make-code-neater.patch index 2bb6fccaf..25a23e235 100644 --- a/utils/opensc/patches/0017-OpenPGP-Make-code-neater.patch +++ b/utils/opensc/patches/0017-OpenPGP-Make-code-neater.patch @@ -8,11 +8,11 @@ Subject: [PATCH 17/26] OpenPGP: Make code neater src/libopensc/card-openpgp.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index beeee83..ca0d01b 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -1222,10 +1222,7 @@ static int gnuk_write_certificate(sc_card_t *card, const u8 *buf, size_t length) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -1230,10 +1230,7 @@ static int gnuk_write_certificate(sc_car r = sc_transmit_apdu(card, &apdu); LOG_TEST_RET(card->ctx, r, "APDU transmit failed"); /* Check response */ @@ -24,7 +24,7 @@ index beeee83..ca0d01b 100644 } /* Ref: gnuk_put_binary_libusb.py and gnuk_token.py in Gnuk source tree */ -@@ -1262,8 +1259,7 @@ static int gnuk_write_certificate(sc_card_t *card, const u8 *buf, size_t length) +@@ -1270,8 +1267,7 @@ static int gnuk_write_certificate(sc_car r = sc_transmit_apdu(card, &apdu); LOG_TEST_RET(card->ctx, r, "APDU transmit failed"); /* Check response */ @@ -34,6 +34,3 @@ index beeee83..ca0d01b 100644 /* To next part */ i++; --- -2.1.3 - diff --git a/utils/opensc/patches/0018-Move-declaration-to-top-of-block.patch b/utils/opensc/patches/0018-Move-declaration-to-top-of-block.patch index 774ed58a1..2d617b597 100644 --- a/utils/opensc/patches/0018-Move-declaration-to-top-of-block.patch +++ b/utils/opensc/patches/0018-Move-declaration-to-top-of-block.patch @@ -8,11 +8,11 @@ Subject: [PATCH 18/26] Move declaration to top of block. src/libopensc/card-openpgp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index ca0d01b..037ef73 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -738,6 +738,7 @@ pgp_read_blob(sc_card_t *card, struct blob *blob) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -746,6 +746,7 @@ pgp_read_blob(sc_card_t *card, struct bl u8 buffer[2048]; size_t buf_len = (card->caps & SC_CARD_CAP_APDU_EXT) ? sizeof(buffer) : 256; @@ -20,7 +20,7 @@ index ca0d01b..037ef73 100644 /* Buffer length for certificate */ if (blob->id == DO_CERT && priv->max_cert_size > 0) { -@@ -751,7 +752,7 @@ pgp_read_blob(sc_card_t *card, struct blob *blob) +@@ -759,7 +760,7 @@ pgp_read_blob(sc_card_t *card, struct bl buf_len = MAXLEN_RESP_PUBKEY_GNUK; } @@ -29,6 +29,3 @@ index ca0d01b..037ef73 100644 if (r < 0) { /* an error occurred */ blob->status = r; --- -2.1.3 - diff --git a/utils/opensc/patches/0019-OpenPGP-Make-indentation-consistent-space-tab.patch b/utils/opensc/patches/0019-OpenPGP-Make-indentation-consistent-space-tab.patch index 3702d61be..6130fa451 100644 --- a/utils/opensc/patches/0019-OpenPGP-Make-indentation-consistent-space-tab.patch +++ b/utils/opensc/patches/0019-OpenPGP-Make-indentation-consistent-space-tab.patch @@ -9,11 +9,11 @@ Subject: [PATCH 19/26] OpenPGP: Make indentation consistent (space -> tab). src/tools/openpgp-tool.c | 56 ++++++++++++++++++++++---------------------- 2 files changed, 39 insertions(+), 39 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 037ef73..ae40940 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -192,12 +192,12 @@ static struct do_info pgp1_objects[] = { /* OpenPGP card spec 1.1 */ +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -194,12 +194,12 @@ static struct do_info pgp1_objects[] = { 0x5f35, SIMPLE, READ_ALWAYS | WRITE_PIN3, NULL, sc_put_data }, { 0x5f50, SIMPLE, READ_ALWAYS | WRITE_PIN3, sc_get_data, sc_put_data }, { 0x7f49, CONSTRUCTED, READ_ALWAYS | WRITE_NEVER, NULL, NULL }, @@ -32,7 +32,7 @@ index 037ef73..ae40940 100644 { 0, 0, 0, NULL, NULL }, }; -@@ -253,11 +253,11 @@ static struct do_info pgp2_objects[] = { /* OpenPGP card spec 2.0 */ +@@ -255,11 +255,11 @@ static struct do_info pgp2_objects[] = /* The 0xA401, 0xB601, 0xB801 are just symbolic, it does not represent any real DO. * However, their R/W access condition may block the process of importing key in pkcs15init. * So we set their accesses condition as WRITE_PIN3 (writable). */ @@ -49,10 +49,10 @@ index 037ef73..ae40940 100644 { 0, 0, 0, NULL, NULL }, }; -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index 374819a..a0334ca 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c @@ -37,11 +37,11 @@ #include "util.h" #include "libopensc/log.h" @@ -70,7 +70,7 @@ index 374819a..a0334ca 100644 /* define structures */ struct ef_name_map { -@@ -142,10 +142,10 @@ static const struct ef_name_map openpgp_data[] = { +@@ -142,10 +142,10 @@ static const struct ef_name_map openpgp_ static void show_version(void) { fprintf(stderr, @@ -85,7 +85,7 @@ index 374819a..a0334ca 100644 } -@@ -176,16 +176,16 @@ static char *prettify_language(char *str) +@@ -176,16 +176,16 @@ static char *prettify_language(char *str { if (str != NULL) { switch (strlen(str)) { @@ -121,7 +121,7 @@ index 374819a..a0334ca 100644 } } return NULL; -@@ -218,7 +218,7 @@ static void display_data(const struct ef_name_map *mapping, char *value) +@@ -218,7 +218,7 @@ static void display_data(const struct ef char *envvar; envvar = malloc(strlen(mapping->env_name) + @@ -130,7 +130,7 @@ index 374819a..a0334ca 100644 if (envvar != NULL) { strcpy(envvar, mapping->env_name); strcat(envvar, "="); -@@ -346,20 +346,20 @@ static int do_userinfo(sc_card_t *card) +@@ -344,20 +344,20 @@ static int do_userinfo(sc_card_t *card) if (!count) continue; @@ -177,6 +177,3 @@ index 374819a..a0334ca 100644 return EXIT_FAILURE; } --- -2.1.3 - diff --git a/utils/opensc/patches/0020-OpenPGP-Don-t-use-sc_log-in-openpgp-tool.patch b/utils/opensc/patches/0020-OpenPGP-Don-t-use-sc_log-in-openpgp-tool.patch index b73826fa2..dbd7bc0dc 100644 --- a/utils/opensc/patches/0020-OpenPGP-Don-t-use-sc_log-in-openpgp-tool.patch +++ b/utils/opensc/patches/0020-OpenPGP-Don-t-use-sc_log-in-openpgp-tool.patch @@ -8,11 +8,11 @@ Subject: [PATCH 20/26] OpenPGP: Don't use sc_log in openpgp-tool. src/tools/openpgp-tool.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index a0334ca..505abd9 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c -@@ -414,8 +414,6 @@ int do_genkey(sc_card_t *card, u8 key_id, unsigned int key_len) +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c +@@ -414,8 +414,6 @@ int do_genkey(sc_card_t *card, u8 key_id sc_path_t path; sc_file_t *file; @@ -21,7 +21,7 @@ index a0334ca..505abd9 100644 if (key_id < 1 || key_id > 3) { printf("Unknown key ID %d.\n", key_id); return 1; -@@ -479,14 +477,14 @@ int delete_key_gnuk(sc_card_t *card, u8 key_id) +@@ -479,14 +477,14 @@ int delete_key_gnuk(sc_card_t *card, u8 u8 *data = NULL; /* Delete fingerprint */ @@ -39,7 +39,7 @@ index a0334ca..505abd9 100644 if (key_id == 1) data = "\x4D\x02\xB6"; -@@ -534,15 +532,18 @@ int delete_key_openpgp(sc_card_t *card, u8 key_id) +@@ -534,15 +532,18 @@ int delete_key_openpgp(sc_card_t *card, /* Build APDU from binary array */ r = sc_bytes2apdu(card->ctx, buf, len0, &apdu); if (r) { @@ -61,7 +61,7 @@ index a0334ca..505abd9 100644 } /* TODO: Rewrite Extended Header List. * Not support by OpenGPG v2 yet */ -@@ -557,7 +558,7 @@ int delete_key(sc_card_t *card, u8 key_id) +@@ -557,7 +558,7 @@ int delete_key(sc_card_t *card, u8 key_i LOG_FUNC_CALLED(ctx); /* Check key ID */ if (key_id < 1 || key_id > 3) { @@ -79,6 +79,3 @@ index a0334ca..505abd9 100644 exit_status = EXIT_FAILURE; goto out; } --- -2.1.3 - diff --git a/utils/opensc/patches/0021-OpenPGP-Don-t-reimplement-gnuk_delete_key-in-openpgp.patch b/utils/opensc/patches/0021-OpenPGP-Don-t-reimplement-gnuk_delete_key-in-openpgp.patch index dc8fe8499..c84ef8e97 100644 --- a/utils/opensc/patches/0021-OpenPGP-Don-t-reimplement-gnuk_delete_key-in-openpgp.patch +++ b/utils/opensc/patches/0021-OpenPGP-Don-t-reimplement-gnuk_delete_key-in-openpgp.patch @@ -9,11 +9,11 @@ Subject: [PATCH 21/26] OpenPGP: Don't reimplement gnuk_delete_key in src/tools/openpgp-tool.c | 64 ++++++------------------------------------------ 1 file changed, 8 insertions(+), 56 deletions(-) -diff --git a/src/tools/openpgp-tool.c b/src/tools/openpgp-tool.c -index 505abd9..a7796e7 100644 ---- a/src/tools/openpgp-tool.c -+++ b/src/tools/openpgp-tool.c -@@ -468,38 +468,6 @@ int do_verify(sc_card_t *card, char *type, char *pin) +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c +@@ -468,38 +468,6 @@ int do_verify(sc_card_t *card, char *typ } /** @@ -52,7 +52,7 @@ index 505abd9..a7796e7 100644 * Delete key, for OpenPGP card. * This function is not complete and is reserved for future version (> 2) of OpenPGP card. **/ -@@ -547,32 +515,13 @@ int delete_key_openpgp(sc_card_t *card, u8 key_id) +@@ -547,32 +515,13 @@ int delete_key_openpgp(sc_card_t *card, } /* TODO: Rewrite Extended Header List. * Not support by OpenGPG v2 yet */ @@ -87,7 +87,7 @@ index 505abd9..a7796e7 100644 int r = SC_SUCCESS; /* Currently, only Gnuk supports deleting keys */ -@@ -586,13 +535,16 @@ int do_delete_key(sc_card_t *card, u8 key_id) +@@ -586,13 +535,16 @@ int do_delete_key(sc_card_t *card, u8 ke return SC_ERROR_INVALID_ARGUMENTS; } if (key_id == 1 || key_id == 'a') { @@ -107,6 +107,3 @@ index 505abd9..a7796e7 100644 } return r; } --- -2.1.3 - diff --git a/utils/opensc/patches/0022-OpenPGP-Use-directly-binary-array-of-APDUs-for-ERASE.patch b/utils/opensc/patches/0022-OpenPGP-Use-directly-binary-array-of-APDUs-for-ERASE.patch index 6297783ec..20c66effe 100644 --- a/utils/opensc/patches/0022-OpenPGP-Use-directly-binary-array-of-APDUs-for-ERASE.patch +++ b/utils/opensc/patches/0022-OpenPGP-Use-directly-binary-array-of-APDUs-for-ERASE.patch @@ -10,11 +10,11 @@ I used a string presentation before and it needed an extra conversion step. src/libopensc/card-openpgp.c | 47 +++++++++++++++++++++++--------------------- 1 file changed, 25 insertions(+), 22 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index ae40940..724fe73 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -2347,24 +2347,27 @@ out: +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -2358,24 +2358,27 @@ out: static int pgp_erase_card(sc_card_t *card) { sc_context_t *ctx = card->ctx; @@ -56,7 +56,7 @@ index ae40940..724fe73 100644 LOG_FUNC_CALLED(ctx); -@@ -2376,17 +2379,17 @@ static int pgp_erase_card(sc_card_t *card) +@@ -2387,17 +2390,17 @@ static int pgp_erase_card(sc_card_t *car sc_log(ctx, "Card is OpenPGP v2. Erase card."); /* Iterate over 10 commands above */ @@ -82,6 +82,3 @@ index ae40940..724fe73 100644 if (r) { sc_log(ctx, "Failed to build APDU"); LOG_FUNC_RETURN(ctx, SC_ERROR_INTERNAL); --- -2.1.3 - diff --git a/utils/opensc/patches/0023-OpenPGP-Rename-private-blob-type-to-avoid-confusing-.patch b/utils/opensc/patches/0023-OpenPGP-Rename-private-blob-type-to-avoid-confusing-.patch index f859f7cf1..1eedf5fd6 100644 --- a/utils/opensc/patches/0023-OpenPGP-Rename-private-blob-type-to-avoid-confusing-.patch +++ b/utils/opensc/patches/0023-OpenPGP-Rename-private-blob-type-to-avoid-confusing-.patch @@ -11,11 +11,11 @@ type. src/libopensc/card-openpgp.c | 96 ++++++++++++++++++++++---------------------- 1 file changed, 49 insertions(+), 47 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 724fe73..ca3173c 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -111,9 +111,9 @@ enum _card_state { +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -113,9 +113,9 @@ enum _card_state { CARD_STATE_ACTIVATED = 0x05 }; @@ -28,7 +28,7 @@ index 724fe73..ca3173c 100644 struct do_info *info; sc_file_t * file; -@@ -122,8 +122,8 @@ struct blob { +@@ -124,8 +124,8 @@ struct blob { unsigned char * data; unsigned int len; @@ -39,7 +39,7 @@ index 724fe73..ca3173c 100644 struct do_info { unsigned int id; /* ID of the DO in question */ -@@ -141,12 +141,12 @@ struct do_info { +@@ -143,12 +143,12 @@ struct do_info { static int pgp_get_card_features(sc_card_t *card); static int pgp_finish(sc_card_t *card); @@ -57,7 +57,7 @@ index 724fe73..ca3173c 100644 static int pgp_get_pubkey(sc_card_t *, unsigned int, u8 *, size_t); static int pgp_get_pubkey_pem(sc_card_t *, unsigned int, -@@ -272,8 +272,8 @@ static struct do_info pgp2_objects[] = { /* OpenPGP card spec 2.0 */ +@@ -274,8 +274,8 @@ static struct do_info pgp2_objects[] = #define DRVDATA(card) ((struct pgp_priv_data *) ((card)->drv_data)) struct pgp_priv_data { @@ -68,16 +68,16 @@ index 724fe73..ca3173c 100644 enum _version bcd_version; struct do_info *pgp_objects; -@@ -311,7 +311,7 @@ pgp_init(sc_card_t *card) +@@ -313,7 +313,7 @@ pgp_init(sc_card_t *card) sc_file_t *file = NULL; struct do_info *info; int r; -- struct blob *child = NULL; -+ pgp_blob_t *child = NULL; +- struct blob *child = NULL; ++ pgp_blob_t *child = NULL; LOG_FUNC_CALLED(card->ctx); -@@ -389,7 +389,7 @@ pgp_get_card_features(sc_card_t *card) +@@ -397,7 +397,7 @@ pgp_get_card_features(sc_card_t *card) unsigned char *hist_bytes = card->atr.value; size_t atr_len = card->atr.len; size_t i = 0; @@ -86,7 +86,7 @@ index 724fe73..ca3173c 100644 /* parse card capabilities from historical bytes */ while ((i < atr_len) && (hist_bytes[i] != 0x73)) -@@ -526,7 +526,7 @@ pgp_finish(sc_card_t *card) +@@ -534,7 +534,7 @@ pgp_finish(sc_card_t *card) /* internal: fill a blob's data */ static int @@ -95,7 +95,7 @@ index 724fe73..ca3173c 100644 { if (blob->data) free(blob->data); -@@ -620,16 +620,16 @@ pgp_attach_acl(sc_card_t *card, sc_file_t *file, struct do_info *info) +@@ -628,16 +628,16 @@ pgp_attach_acl(sc_card_t *card, sc_file_ } /* internal: append a blob to the list of children of a given parent blob */ @@ -116,7 +116,7 @@ index 724fe73..ca3173c 100644 struct pgp_priv_data *priv = DRVDATA (card); struct do_info *info; -@@ -643,7 +643,7 @@ pgp_new_blob(sc_card_t *card, struct blob *parent, unsigned int file_id, +@@ -651,7 +651,7 @@ pgp_new_blob(sc_card_t *card, struct blo blob->parent = parent; if (parent != NULL) { @@ -125,7 +125,7 @@ index 724fe73..ca3173c 100644 /* set file's path = parent's path + file's id */ blob->file->path = parent->file->path; -@@ -681,11 +681,11 @@ pgp_new_blob(sc_card_t *card, struct blob *parent, unsigned int file_id, +@@ -689,11 +689,11 @@ pgp_new_blob(sc_card_t *card, struct blo /* internal: free a blob including its content */ static void @@ -139,7 +139,7 @@ index 724fe73..ca3173c 100644 /* remove blob from list of parent's children */ for (p = &blob->parent->files; *p != NULL && *p != blob; p = &(*p)->next) -@@ -705,14 +705,14 @@ pgp_free_blob(struct blob *blob) +@@ -713,14 +713,14 @@ pgp_free_blob(struct blob *blob) /* internal: iterate through the blob tree, calling a function for each blob */ static void @@ -157,7 +157,7 @@ index 724fe73..ca3173c 100644 pgp_iterate_blobs(child, level-1, func); child = next; -@@ -725,7 +725,7 @@ pgp_iterate_blobs(struct blob *blob, int level, void (*func)()) +@@ -733,7 +733,7 @@ pgp_iterate_blobs(struct blob *blob, int /* internal: read a blob's contents from card */ static int @@ -166,7 +166,7 @@ index 724fe73..ca3173c 100644 { struct pgp_priv_data *priv = DRVDATA (card); -@@ -772,7 +772,7 @@ pgp_read_blob(sc_card_t *card, struct blob *blob) +@@ -780,7 +780,7 @@ pgp_read_blob(sc_card_t *card, struct bl * The OpenPGP card has a TLV encoding according ASN.1 BER-encoding rules. */ static int @@ -175,7 +175,7 @@ index 724fe73..ca3173c 100644 { const u8 *in; int r; -@@ -789,7 +789,7 @@ pgp_enumerate_blob(sc_card_t *card, struct blob *blob) +@@ -797,7 +797,7 @@ pgp_enumerate_blob(sc_card_t *card, stru unsigned int cla, tag, tmptag; size_t len; const u8 *data = in; @@ -184,7 +184,7 @@ index 724fe73..ca3173c 100644 r = sc_asn1_read_tag(&data, blob->len - (in - blob->data), &cla, &tag, &len); -@@ -819,10 +819,10 @@ pgp_enumerate_blob(sc_card_t *card, struct blob *blob) +@@ -827,10 +827,10 @@ pgp_enumerate_blob(sc_card_t *card, stru /* internal: find a blob by ID below a given parent, filling its contents when necessary */ static int @@ -198,7 +198,7 @@ index 724fe73..ca3173c 100644 int r; if ((r = pgp_enumerate_blob(card, blob)) < 0) -@@ -858,10 +858,10 @@ pgp_get_blob(sc_card_t *card, struct blob *blob, unsigned int id, +@@ -866,10 +866,10 @@ pgp_get_blob(sc_card_t *card, struct blo /* Internal: search recursively for a blob by ID below a given root */ static int @@ -212,7 +212,7 @@ index 724fe73..ca3173c 100644 int r; if ((r = pgp_get_blob(card, root, id, ret)) == 0) -@@ -883,11 +883,11 @@ pgp_seek_blob(sc_card_t *card, struct blob *root, unsigned int id, +@@ -891,11 +891,11 @@ pgp_seek_blob(sc_card_t *card, struct bl } /* internal: find a blob by tag - pgp_seek_blob with optimizations */ @@ -226,7 +226,7 @@ index 724fe73..ca3173c 100644 int r; /* Check if current selected blob is which we want to test*/ -@@ -941,7 +941,7 @@ static int +@@ -949,7 +949,7 @@ static int pgp_select_file(sc_card_t *card, const sc_path_t *path, sc_file_t **ret) { struct pgp_priv_data *priv = DRVDATA(card); @@ -235,7 +235,7 @@ index 724fe73..ca3173c 100644 unsigned int path_start = 0; unsigned int n; sc_path_t dummy_path; -@@ -1022,7 +1022,7 @@ static int +@@ -1030,7 +1030,7 @@ static int pgp_list_files(sc_card_t *card, u8 *buf, size_t buflen) { struct pgp_priv_data *priv = DRVDATA(card); @@ -244,7 +244,7 @@ index 724fe73..ca3173c 100644 unsigned int k; int r; -@@ -1058,7 +1058,7 @@ pgp_read_binary(sc_card_t *card, unsigned int idx, +@@ -1066,7 +1066,7 @@ pgp_read_binary(sc_card_t *card, unsigne u8 *buf, size_t count, unsigned long flags) { struct pgp_priv_data *priv = DRVDATA(card); @@ -253,7 +253,7 @@ index 724fe73..ca3173c 100644 int r; LOG_FUNC_CALLED(card->ctx); -@@ -1134,7 +1134,7 @@ static int +@@ -1142,7 +1142,7 @@ static int pgp_get_pubkey_pem(sc_card_t *card, unsigned int tag, u8 *buf, size_t buf_len) { struct pgp_priv_data *priv = DRVDATA(card); @@ -262,7 +262,7 @@ index 724fe73..ca3173c 100644 sc_pkcs15_pubkey_t pubkey; u8 *data; size_t len; -@@ -1329,7 +1329,7 @@ static int +@@ -1337,7 +1337,7 @@ static int pgp_put_data(sc_card_t *card, unsigned int tag, const u8 *buf, size_t buf_len) { struct pgp_priv_data *priv = DRVDATA(card); @@ -271,7 +271,7 @@ index 724fe73..ca3173c 100644 struct do_info *dinfo = NULL; int r; -@@ -1603,7 +1603,7 @@ static int +@@ -1611,7 +1611,7 @@ static int pgp_update_new_algo_attr(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_info) { struct pgp_priv_data *priv = DRVDATA(card); @@ -280,7 +280,7 @@ index 724fe73..ca3173c 100644 unsigned int old_modulus_len; /* Measured in bit */ unsigned int old_exponent_len; const unsigned int tag = 0x00C0 | key_info->keytype; -@@ -1708,7 +1708,7 @@ pgp_calculate_and_store_fingerprint(sc_card_t *card, time_t ctime, +@@ -1716,7 +1716,7 @@ pgp_calculate_and_store_fingerprint(sc_c u8 *p; /* Use this pointer to set fp_buffer content */ size_t pk_packet_len; unsigned int tag; @@ -289,7 +289,7 @@ index 724fe73..ca3173c 100644 u8 *newdata; int r; -@@ -1797,7 +1797,7 @@ pgp_update_pubkey_blob(sc_card_t *card, u8* modulus, size_t modulus_len, +@@ -1805,7 +1805,7 @@ pgp_update_pubkey_blob(sc_card_t *card, u8* exponent, size_t exponent_len, u8 key_id) { struct pgp_priv_data *priv = DRVDATA(card); @@ -298,7 +298,7 @@ index 724fe73..ca3173c 100644 unsigned int blob_id; sc_pkcs15_pubkey_t pubkey; u8 *data = NULL; -@@ -1939,6 +1939,8 @@ static int pgp_update_card_algorithms(sc_card_t *card, sc_cardctl_openpgp_keygen +@@ -1947,6 +1947,8 @@ static int pgp_update_card_algorithms(sc **/ static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_info) { @@ -307,7 +307,7 @@ index 724fe73..ca3173c 100644 sc_apdu_t apdu; /* Temporary variables to hold APDU params */ u8 apdu_case; -@@ -2132,7 +2134,7 @@ pgp_build_extended_header_list(sc_card_t *card, sc_cardctl_openpgp_keystore_info +@@ -2143,7 +2145,7 @@ pgp_build_extended_header_list(sc_card_t }; size_t comp_to_add = 3; size_t req_e_len = 0; /* The exponent length specified in Algorithm Attributes */ @@ -316,7 +316,7 @@ index 724fe73..ca3173c 100644 u8 i; int r; -@@ -2483,7 +2485,7 @@ static int +@@ -2496,7 +2498,7 @@ static int pgp_delete_file(sc_card_t *card, const sc_path_t *path) { struct pgp_priv_data *priv = DRVDATA(card); @@ -325,7 +325,7 @@ index 724fe73..ca3173c 100644 sc_file_t *file; u8 key_id; int r; -@@ -2533,7 +2535,7 @@ pgp_update_binary(sc_card_t *card, unsigned int idx, +@@ -2546,7 +2548,7 @@ pgp_update_binary(sc_card_t *card, unsig const u8 *buf, size_t count, unsigned long flags) { struct pgp_priv_data *priv = DRVDATA(card); @@ -334,6 +334,3 @@ index 724fe73..ca3173c 100644 int r = SC_SUCCESS; LOG_FUNC_CALLED(card->ctx); --- -2.1.3 - diff --git a/utils/opensc/patches/0024-OpenPGP-Fix-crash-after-accessing-inexistent-file.patch b/utils/opensc/patches/0024-OpenPGP-Fix-crash-after-accessing-inexistent-file.patch index 7d8a0ffc1..22ae5f43f 100644 --- a/utils/opensc/patches/0024-OpenPGP-Fix-crash-after-accessing-inexistent-file.patch +++ b/utils/opensc/patches/0024-OpenPGP-Fix-crash-after-accessing-inexistent-file.patch @@ -8,11 +8,11 @@ Subject: [PATCH 24/26] OpenPGP: Fix crash after accessing inexistent file. src/libopensc/card-openpgp.c | 3 --- 1 file changed, 3 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index ca3173c..94c69ae 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -973,7 +973,6 @@ pgp_select_file(sc_card_t *card, const sc_path_t *path, sc_file_t **ret) +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -981,7 +981,6 @@ pgp_select_file(sc_card_t *card, const s * So we set its size to be the same as max certificate size the card supports. */ (*ret)->size = priv->max_cert_size; } @@ -20,7 +20,7 @@ index ca3173c..94c69ae 100644 LOG_FUNC_RETURN(card->ctx, SC_SUCCESS); } -@@ -990,7 +989,6 @@ pgp_select_file(sc_card_t *card, const sc_path_t *path, sc_file_t **ret) +@@ -998,7 +997,6 @@ pgp_select_file(sc_card_t *card, const s /* This file ID is refered when importing key&certificate via pkcs15init, like above. * We pretend to successfully find this inexistent file. */ if (id == 0x4402 || id == 0x5f48) { @@ -28,7 +28,7 @@ index ca3173c..94c69ae 100644 if (ret == NULL) /* No need to return file */ LOG_FUNC_RETURN(card->ctx, SC_SUCCESS); -@@ -1002,7 +1000,6 @@ pgp_select_file(sc_card_t *card, const sc_path_t *path, sc_file_t **ret) +@@ -1010,7 +1008,6 @@ pgp_select_file(sc_card_t *card, const s } if (r < 0) { /* failure */ @@ -36,6 +36,3 @@ index ca3173c..94c69ae 100644 LOG_FUNC_RETURN(card->ctx, r); } } --- -2.1.3 - diff --git a/utils/opensc/patches/0025-Replace-hardcode.patch b/utils/opensc/patches/0025-Replace-hardcode.patch index 0eb750c34..002bec3d9 100644 --- a/utils/opensc/patches/0025-Replace-hardcode.patch +++ b/utils/opensc/patches/0025-Replace-hardcode.patch @@ -8,11 +8,11 @@ Subject: [PATCH 25/26] Replace hardcode. src/libopensc/card-openpgp.c | 72 +++++++++++++++++++++++++------------------- 1 file changed, 41 insertions(+), 31 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 94c69ae..1e6e338 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -152,6 +152,24 @@ static int pgp_get_pubkey(sc_card_t *, unsigned int, +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -154,6 +154,24 @@ static int pgp_get_pubkey(sc_card_t *, static int pgp_get_pubkey_pem(sc_card_t *, unsigned int, u8 *, size_t); @@ -37,7 +37,7 @@ index 94c69ae..1e6e338 100644 static struct do_info pgp1_objects[] = { /* OpenPGP card spec 1.1 */ { 0x004f, SIMPLE, READ_ALWAYS | WRITE_NEVER, NULL, NULL }, { 0x005b, SIMPLE, READ_ALWAYS | WRITE_PIN3, NULL, sc_put_data }, -@@ -192,12 +210,12 @@ static struct do_info pgp1_objects[] = { /* OpenPGP card spec 1.1 */ +@@ -194,12 +212,12 @@ static struct do_info pgp1_objects[] = { 0x5f35, SIMPLE, READ_ALWAYS | WRITE_PIN3, NULL, sc_put_data }, { 0x5f50, SIMPLE, READ_ALWAYS | WRITE_PIN3, sc_get_data, sc_put_data }, { 0x7f49, CONSTRUCTED, READ_ALWAYS | WRITE_NEVER, NULL, NULL }, @@ -56,7 +56,7 @@ index 94c69ae..1e6e338 100644 { 0, 0, 0, NULL, NULL }, }; -@@ -246,30 +264,21 @@ static struct do_info pgp2_objects[] = { /* OpenPGP card spec 2.0 */ +@@ -248,30 +266,21 @@ static struct do_info pgp2_objects[] = { 0x5f52, SIMPLE, READ_ALWAYS | WRITE_NEVER, sc_get_data, NULL }, /* The 7F21 is constructed DO in spec, but in practice, its content can be retrieved * as simple DO (no need to parse TLV). */ @@ -94,7 +94,7 @@ index 94c69ae..1e6e338 100644 #define DRVDATA(card) ((struct pgp_priv_data *) ((card)->drv_data)) struct pgp_priv_data { pgp_blob_t * mf; -@@ -747,8 +756,9 @@ pgp_read_blob(sc_card_t *card, pgp_blob_t *blob) +@@ -755,8 +764,9 @@ pgp_read_blob(sc_card_t *card, pgp_blob_ /* Buffer length for Gnuk pubkey */ if (card->type == SC_CARD_TYPE_OPENPGP_GNUK && @@ -106,7 +106,7 @@ index 94c69ae..1e6e338 100644 buf_len = MAXLEN_RESP_PUBKEY_GNUK; } -@@ -1804,11 +1814,11 @@ pgp_update_pubkey_blob(sc_card_t *card, u8* modulus, size_t modulus_len, +@@ -1812,11 +1822,11 @@ pgp_update_pubkey_blob(sc_card_t *card, LOG_FUNC_CALLED(card->ctx); if (key_id == SC_OPENPGP_KEY_SIGN) @@ -121,7 +121,7 @@ index 94c69ae..1e6e338 100644 else { sc_log(card->ctx, "Unknown key id %X.", key_id); LOG_FUNC_RETURN(card->ctx, SC_ERROR_INVALID_ARGUMENTS); -@@ -2501,17 +2511,17 @@ pgp_delete_file(sc_card_t *card, const sc_path_t *path) +@@ -2514,17 +2524,17 @@ pgp_delete_file(sc_card_t *card, const s LOG_FUNC_RETURN(card->ctx, SC_ERROR_NOT_SUPPORTED); if (card->type != SC_CARD_TYPE_OPENPGP_GNUK && @@ -143,6 +143,3 @@ index 94c69ae..1e6e338 100644 r = gnuk_delete_key(card, 3); } else { --- -2.1.3 - diff --git a/utils/opensc/patches/0026-hardcode-defines-for-DO-s.patch b/utils/opensc/patches/0026-hardcode-defines-for-DO-s.patch index d106e868c..6931aa64a 100644 --- a/utils/opensc/patches/0026-hardcode-defines-for-DO-s.patch +++ b/utils/opensc/patches/0026-hardcode-defines-for-DO-s.patch @@ -7,11 +7,11 @@ Subject: [PATCH 26/26] hardcode->defines for DO's src/libopensc/card-openpgp.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) -diff --git a/src/libopensc/card-openpgp.c b/src/libopensc/card-openpgp.c -index 1e6e338..8464914 100644 ---- a/src/libopensc/card-openpgp.c -+++ b/src/libopensc/card-openpgp.c -@@ -164,6 +164,18 @@ static int pgp_get_pubkey_pem(sc_card_t *, unsigned int, +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -166,6 +166,18 @@ static int pgp_get_pubkey_pem(sc_card_t #define DO_SIGN_SYM 0xb601 #define DO_ENCR_SYM 0xb801 #define DO_AUTH_SYM 0xa401 @@ -30,7 +30,7 @@ index 1e6e338..8464914 100644 /* Maximum length for response buffer when reading pubkey. This value is calculated with * 4096-bit key length */ #define MAXLEN_RESP_PUBKEY 527 -@@ -851,7 +863,7 @@ pgp_get_blob(sc_card_t *card, pgp_blob_t *blob, unsigned int id, +@@ -859,7 +871,7 @@ pgp_get_blob(sc_card_t *card, pgp_blob_t /* Special case: * Gnuk does not have default value for children of DO 65 (DOs 5B, 5F2D, 5F35) * So, if these blob was not found, we create it. */ @@ -39,7 +39,7 @@ index 1e6e338..8464914 100644 sc_log(card->ctx, "Create blob %X under %X", id, blob->id); child = pgp_new_blob(card, blob, id, sc_file_new()); if (child) { -@@ -1198,7 +1210,7 @@ pgp_get_data(sc_card_t *card, unsigned int tag, u8 *buf, size_t buf_len) +@@ -1206,7 +1218,7 @@ pgp_get_data(sc_card_t *card, unsigned i /* For Gnuk card, if there is no certificate, it returns error instead of empty data. * So, for this case, we ignore error and consider success */ if (r == SC_ERROR_DATA_OBJECT_NOT_FOUND && card->type == SC_CARD_TYPE_OPENPGP_GNUK @@ -48,6 +48,3 @@ index 1e6e338..8464914 100644 r = SC_SUCCESS; apdu.resplen = 0; } --- -2.1.3 - diff --git a/utils/opensc/patches/0027-OpenPGP-Remove-unused-variables-and-fix-type-cast.patch b/utils/opensc/patches/0027-OpenPGP-Remove-unused-variables-and-fix-type-cast.patch new file mode 100644 index 000000000..742f76ac9 --- /dev/null +++ b/utils/opensc/patches/0027-OpenPGP-Remove-unused-variables-and-fix-type-cast.patch @@ -0,0 +1,82 @@ +From 99b5cb53e1da2f0d7692f28dceff8485d4b74daf Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Nguy=E1=BB=85n=20H=E1=BB=93ng=20Qu=C3=A2n?= + +Date: Wed, 10 Dec 2014 03:59:54 +0800 +Subject: [PATCH 1/2] OpenPGP: Remove unused variables and fix type cast. + +--- + src/libopensc/card-openpgp.c | 10 +++------- + src/tools/openpgp-tool.c | 4 +--- + 2 files changed, 4 insertions(+), 10 deletions(-) + +Index: opensc-20150513/src/libopensc/card-openpgp.c +=================================================================== +--- opensc-20150513.orig/src/libopensc/card-openpgp.c ++++ opensc-20150513/src/libopensc/card-openpgp.c +@@ -1966,8 +1966,6 @@ static int pgp_update_card_algorithms(sc + **/ + static int pgp_gen_key(sc_card_t *card, sc_cardctl_openpgp_keygen_info_t *key_info) + { +- struct pgp_priv_data *priv = DRVDATA(card); +- pgp_blob_t *algo_blob; + sc_apdu_t apdu; + /* Temporary variables to hold APDU params */ + u8 apdu_case; +@@ -2396,10 +2394,9 @@ static int pgp_erase_card(sc_card_t *car + {0, 0x44, 0, 0} + }; + u8 apdu_lens[10] = {13, 13, 13, 13, 13, 13, 13, 13, 4, 4}; +- u8 buf[SC_MAX_APDU_BUFFER_SIZE]; + u8 rbuf[SC_MAX_APDU_BUFFER_SIZE]; + sc_apdu_t apdu; +- int i, l, r; ++ u8 i, l, r; + + LOG_FUNC_CALLED(ctx); + +@@ -2478,7 +2475,7 @@ gnuk_delete_key(sc_card_t *card, u8 key_ + { + sc_context_t *ctx = card->ctx; + int r = SC_SUCCESS; +- u8 *data = NULL; ++ char *data = NULL; + + LOG_FUNC_CALLED(ctx); + +@@ -2506,7 +2503,7 @@ gnuk_delete_key(sc_card_t *card, u8 key_ + else if (key_id == 3) + data = "\x4D\x02\xA4"; + +- r = pgp_put_data(card, 0x4D, data, strlen(data) + 1); ++ r = pgp_put_data(card, 0x4D, (const u8 *)data, strlen((const char *)data) + 1); + + LOG_FUNC_RETURN(ctx, r); + } +@@ -2519,7 +2516,6 @@ pgp_delete_file(sc_card_t *card, const s + struct pgp_priv_data *priv = DRVDATA(card); + pgp_blob_t *blob; + sc_file_t *file; +- u8 key_id; + int r; + + LOG_FUNC_CALLED(card->ctx); +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c +@@ -473,7 +473,6 @@ int do_verify(sc_card_t *card, char *typ + **/ + int delete_key_openpgp(sc_card_t *card, u8 key_id) + { +- sc_context_t *ctx = card->ctx; + char *del_fingerprint = "00:DA:00:C6:14:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00"; + char *del_creationtime = "00:DA:00:CD:04:00:00:00:00"; + /* We need to replace the 4th byte later */ +@@ -520,7 +519,6 @@ int delete_key_openpgp(sc_card_t *card, + + int do_delete_key(sc_card_t *card, u8 key_id) + { +- sc_context_t *ctx = card->ctx; + sc_path_t path; + int r = SC_SUCCESS; + diff --git a/utils/opensc/patches/0028-openpgp-tool-Fix-wrong-operator.patch b/utils/opensc/patches/0028-openpgp-tool-Fix-wrong-operator.patch new file mode 100644 index 000000000..e423e1703 --- /dev/null +++ b/utils/opensc/patches/0028-openpgp-tool-Fix-wrong-operator.patch @@ -0,0 +1,28 @@ +From c71a453ff1e19721a9245b8a2d637eabd9f12e54 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Nguy=E1=BB=85n=20H=E1=BB=93ng=20Qu=C3=A2n?= + +Date: Thu, 11 Dec 2014 12:51:15 +0800 +Subject: [PATCH 2/2] openpgp-tool: Fix wrong operator + +Used "!=" instead of "|=" +--- + src/tools/openpgp-tool.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +Index: opensc-20150513/src/tools/openpgp-tool.c +=================================================================== +--- opensc-20150513.orig/src/tools/openpgp-tool.c ++++ opensc-20150513/src/tools/openpgp-tool.c +@@ -639,10 +639,10 @@ int main(int argc, char **argv) + } + + if (opt_delkey) +- exit_status != do_delete_key(card, key_id); ++ exit_status |= do_delete_key(card, key_id); + + if (opt_erase) +- exit_status != do_erase(card); ++ exit_status |= do_erase(card); + + out: + sc_unlock(card); diff --git a/utils/pciutils/Makefile b/utils/pciutils/Makefile index d3b0765f8..e9879f601 100644 --- a/utils/pciutils/Makefile +++ b/utils/pciutils/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,18 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=pciutils -PKG_VERSION:=3.3.0 +PKG_VERSION:=3.3.1 PKG_RELEASE:=1 -PKG_USE_MIPS16:=0 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@KERNEL/software/utils/pciutils -PKG_MD5SUM:=bf6ce5c50b273ffc2d27f659e929a37e +PKG_MD5SUM:=86d5462e5cfc2a4341a2b91ce3ed0f09 PKG_MAINTAINER:=Álvaro Fernández Rojas PKG_LICENSE:=GPL-2.0 PKG_LICENSE_FILES:=COPYING +PKG_USE_MIPS16:=0 PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk @@ -29,7 +29,7 @@ define Package/pciutils CATEGORY:=Utilities TITLE:=Linux PCI Utilities URL:=http://mj.ucw.cz/pciutils.shtml - DEPENDS:=+zlib + DEPENDS:=+libkmod +zlib endef define Package/pciutils/description @@ -50,7 +50,7 @@ MAKE_FLAGS += \ HOST="$(GNU_TARGET_NAME)" \ ZLIB="yes" \ -ifneq ($(CONFIG_USE_EGLIBC),) +ifneq ($(CONFIG_USE_GLIBC),) TARGET_LDFLAGS += -lresolv endif diff --git a/utils/picocom/Makefile b/utils/picocom/Makefile index b5251b412..31a1ad644 100644 --- a/utils/picocom/Makefile +++ b/utils/picocom/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=picocom PKG_VERSION:=1.7 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://picocom.googlecode.com/files diff --git a/utils/picocom/patches/100-musl-compat.patch b/utils/picocom/patches/100-musl-compat.patch new file mode 100644 index 000000000..5f7d75034 --- /dev/null +++ b/utils/picocom/patches/100-musl-compat.patch @@ -0,0 +1,17 @@ +Index: picocom-1.7/term.c +=================================================================== +--- picocom-1.7.orig/term.c ++++ picocom-1.7/term.c +@@ -33,10 +33,11 @@ + #include + #include + #include +-#ifdef __linux__ ++#if defined(__linux__) && (defined(__GLIBC__) || defined(__UCLIBC__)) + #include + #else + #include ++#include + #endif /* of __linux__ */ + + #include "term.h" diff --git a/utils/pps-tools/Makefile b/utils/pps-tools/Makefile index 93d0578dc..653f90fbc 100644 --- a/utils/pps-tools/Makefile +++ b/utils/pps-tools/Makefile @@ -26,7 +26,7 @@ define Package/pps-tools SECTION:=utils CATEGORY:=Utilities TITLE:=PPS-tools - DEPENDS:=@LINUX_3_10||@LINUX_3_13||@LINUX_3_14 + DEPENDS:=@LINUX_3_10||@LINUX_3_13||@LINUX_3_14||@LINUX_3_18 endef define Package/pps-tools/description diff --git a/utils/procps/patches/040-musl-compatibility.patch b/utils/procps/patches/040-musl-compatibility.patch new file mode 100644 index 000000000..71dc3f07e --- /dev/null +++ b/utils/procps/patches/040-musl-compatibility.patch @@ -0,0 +1,29 @@ +From 6f2fd55ef7621fd7ab7897aee2c2651b6faf9e6a Mon Sep 17 00:00:00 2001 +From: Paul Barker +Date: Wed, 20 Aug 2014 11:56:11 +0200 +Subject: [PATCH] Fix musl build failure + +Include for PATH_MAX. + +Signed-off-by: Paul Barker + +Upstream-status: Pending +--- + proc/readproc.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/proc/readproc.c b/proc/readproc.c +index 4fad11d..c5b1869 100644 +--- a/proc/readproc.c ++++ b/proc/readproc.c +@@ -26,6 +26,7 @@ + #include + #include + #include ++#include + + // sometimes it's easier to do this manually, w/o gcc helping + #ifdef PROF +-- +1.9.1 + diff --git a/utils/rng-tools/Makefile b/utils/rng-tools/Makefile index d45a197c4..8ec18c2ce 100644 --- a/utils/rng-tools/Makefile +++ b/utils/rng-tools/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2011-2014 OpenWrt.org +# Copyright (C) 2011-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=rng-tools PKG_VERSION:=5 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/gkernel/rng-tools/$(PKG_VERSION)/ @@ -19,7 +19,7 @@ PKG_MAINTAINER:=Hannu Nyman PKG_FIXUP:=autoreconf -PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone +PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone USE_MUSL:argp-standalone include $(INCLUDE_DIR)/package.mk @@ -35,6 +35,11 @@ CONFIGURE_VARS += \ LIBS="-largp" endif +ifdef CONFIG_USE_MUSL +CONFIGURE_VARS += \ + LIBS="-largp" +endif + CONFIGURE_ARGS += \ --without-libgcrypt diff --git a/utils/screen/Makefile b/utils/screen/Makefile index 3adfb0ab3..c7449bcd8 100644 --- a/utils/screen/Makefile +++ b/utils/screen/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2014 OpenWrt.org +# Copyright (C) 2006-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=screen PKG_VERSION:=4.2.1 -PKG_RELEASE:=2 +PKG_RELEASE:=4 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@GNU/screen diff --git a/utils/screen/patches/200-musl-compat.patch b/utils/screen/patches/200-musl-compat.patch new file mode 100644 index 000000000..5bbc9d0ea --- /dev/null +++ b/utils/screen/patches/200-musl-compat.patch @@ -0,0 +1,57 @@ +--- a/configure ++++ b/configure +@@ -4154,44 +4154,6 @@ fi + rm -f conftest* + + +-oldlibs="$LIBS" +-LIBS="$LIBS -lelf" +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SVR4..." >&5 +-$as_echo "$as_me: checking SVR4..." >&6;} +-cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +-#include +- +-int +-main () +-{ +- +- ; +- return 0; +-} +-_ACEOF +-if ac_fn_c_try_link "$LINENO"; then : +- ac_fn_c_check_header_mongrel "$LINENO" "dwarf.h" "ac_cv_header_dwarf_h" "$ac_includes_default" +-if test "x$ac_cv_header_dwarf_h" = xyes; then : +- $as_echo "#define SVR4 1" >>confdefs.h +- $as_echo "#define BUGGYGETLOGIN 1" >>confdefs.h +- +-else +- ac_fn_c_check_header_mongrel "$LINENO" "elf.h" "ac_cv_header_elf_h" "$ac_includes_default" +-if test "x$ac_cv_header_elf_h" = xyes; then : +- $as_echo "#define SVR4 1" >>confdefs.h +- $as_echo "#define BUGGYGETLOGIN 1" >>confdefs.h +- +-fi +- +- +-fi +- +- +- +-else +- LIBS="$oldlibs" +-fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + for ac_header in stropts.h string.h strings.h +--- a/utmp.c ++++ b/utmp.c +@@ -33,6 +33,7 @@ + #include "config.h" + #include "screen.h" + #include "extern.h" ++#include "os.h" + + #ifdef HAVE_UTEMPTER + #include diff --git a/utils/smartmontools/Makefile b/utils/smartmontools/Makefile index b09165a09..3632fca9b 100644 --- a/utils/smartmontools/Makefile +++ b/utils/smartmontools/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/uclibc++.mk PKG_NAME:=smartmontools -PKG_VERSION:=6.3 +PKG_VERSION:=6.4 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/smartmontools -PKG_MD5SUM:=2ea0c62206e110192a97b59291b17f54 +PKG_MD5SUM:=56812c8312fd123ed40ef65afde1049e PKG_MAINTAINER:=Maxim Storchak PKG_LICENSE:=GPL-2.0+ PKG_LICENSE_FILES:=COPYING diff --git a/utils/smstools3/Makefile b/utils/smstools3/Makefile index 12d4ecf8a..0c7dd2cf5 100644 --- a/utils/smstools3/Makefile +++ b/utils/smstools3/Makefile @@ -22,7 +22,7 @@ PKG_SOURCE_URL:=http://smstools3.kekekasvi.com/packages/ PKG_MD5SUM:=0241ef60e646fac1a06254a848e61ed7 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) -PKG_BUILD_DEPENDS:=libiconv-full iconv socket nsl +PKG_BUILD_DEPENDS:=libiconv-full iconv include $(INCLUDE_DIR)/package.mk diff --git a/utils/sumo/Makefile b/utils/sumo/Makefile index 02b8fa01e..83aa40d42 100644 --- a/utils/sumo/Makefile +++ b/utils/sumo/Makefile @@ -8,23 +8,25 @@ include $(TOPDIR)/rules.mk PKG_NAME:=sumo -PKG_VERSION:=0.22.0 +PKG_VERSION:=0.23.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-src-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/sumo -PKG_MD5SUM:=d239a3f94fdb905fdaf1648f2b71fd42 +PKG_MD5SUM:=0df95a449d44808b8d3677af086e1af1 PKG_MAINTAINER:=Álvaro Fernández Rojas PKG_LICENSE:=GPL-3.0 PKG_LICENSE_FILES:=COPYING +PKG_BUILD_PARALLEL:=1 +PKG_FIXUP:=autoreconf PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk CONFIGURE_ARGS += \ - --with-xerces-includes=$(STAGING_DIR)/usr/include/xercesc \ + --with-xerces=$(STAGING_DIR)/usr \ --disable-debug \ --disable-dependency-tracking \ --disable-silent-rules diff --git a/utils/sumo/files/sumo.sh b/utils/sumo/files/sumo.sh index 2ae8df8c2..0f0af4db4 100644 --- a/utils/sumo/files/sumo.sh +++ b/utils/sumo/files/sumo.sh @@ -3,4 +3,4 @@ SUMO_HOME=/usr/share/sumo sumo-bin $@ -exit 0 +exit $? diff --git a/utils/sumo/patches/100-configure_fix.patch b/utils/sumo/patches/100-configure_fix.patch new file mode 100644 index 000000000..6fff18ca7 --- /dev/null +++ b/utils/sumo/patches/100-configure_fix.patch @@ -0,0 +1,14 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -13,11 +13,6 @@ AC_LANG([C++]) + + dnl the debug check has to be made before the program checks + dnl because it modifies CXXFLAGS +-if test x$CXX = xclang++; then +- CXXFLAGS="-msse2 $CXXFLAGS" +-else +- CXXFLAGS="-msse2 -mfpmath=sse $CXXFLAGS" +-fi + AC_ARG_ENABLE([debug], [AS_HELP_STRING([--enable-debug],[enable sumo debugging code [default=no].])]) + if test x$enable_debug = xyes; then + AC_DEFINE(_DEBUG, 1, [Define to 1 in order to enable sumo debugging code.]) diff --git a/utils/sysstat/Makefile b/utils/sysstat/Makefile new file mode 100644 index 000000000..3e9457b25 --- /dev/null +++ b/utils/sysstat/Makefile @@ -0,0 +1,66 @@ +# +# Copyright (C) 2015 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:=sysstat +PKG_VERSION:=11.0.4 +PKG_RELEASE:=2 + +PKG_LICENSE:=GPL-2.0 +PKG_MAINTAINER:=Marko Ratkaj + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz +PKG_SOURCE_URL:=http://perso.orange.fr/sebastien.godard/ +PKG_MD5SUM:=df1ed75656eb06320088d54247f0e803 + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/sysstat + SECTION:=utils + CATEGORY:=Utilities + TITLE:=Sysstat performance monitoring tools + URL:=http://pagesperso-orange.fr/sebastien.godard/index.html +endef + +define Package/sysstat/description + The sysstat utilities are a collection of performance monitoring tools for + Linux. These include sar, sadf, mpstat, iostat, pidstat and sa tools. +endef + +define Package/sysstat/conffiles +/etc/sysstat/sysstat.ioconf +/etc/sysstat/sysstat +endef + +CONFIGURE_VARS+= \ + sa_lib_dir="/usr/lib/sysstat" \ + sa_dir="/var/log/sysstat" \ + conf_dir="/etc/sysstat" + +CONFIGURE_ARGS+= \ + --disable-documentation \ + --disable-largefile \ + --disable-sensors \ + --disable-nls + +define Package/sysstat/install + $(INSTALL_DIR) $(1)/usr/lib/sysstat + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/sysstat/{sadc,sa1,sa2} $(1)/usr/lib/sysstat/ + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{sar,sadf,iostat,mpstat,pidstat} $(1)/usr/bin/ + $(INSTALL_DIR) $(1)/etc/sysstat + $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/sysstat/sysstat.ioconf $(1)/etc/sysstat/ + $(INSTALL_DIR) $(1)/etc/config + $(INSTALL_CONF) ./files/sysstat.config $(1)/etc/config/sysstat + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/sysstat.init $(1)/etc/init.d/sysstat +endef + +$(eval $(call BuildPackage,sysstat)) diff --git a/utils/sysstat/files/sysstat.config b/utils/sysstat/files/sysstat.config new file mode 100644 index 000000000..638b3798c --- /dev/null +++ b/utils/sysstat/files/sysstat.config @@ -0,0 +1,7 @@ +config sysstat 'sysstat' + option log_history '7' + option compressafter '10' + option sadc_options '' + option sa_dir '/var/log/sysstat' + option zip 'xz' + option enabled 'true' diff --git a/utils/sysstat/files/sysstat.init b/utils/sysstat/files/sysstat.init new file mode 100755 index 000000000..a8190008d --- /dev/null +++ b/utils/sysstat/files/sysstat.init @@ -0,0 +1,49 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2015 OpenWrt.org + +START=90 +STOP=10 + +USE_PROCD=1 +PROG=/usr/lib/sysstat/sadc +SYSSTAT_CFG="/etc/sysstat/sysstat" + +validate_sysstat_section() { + uci_validate_section sysstat sysstat "${1}" \ + 'log_history:uinteger' \ + 'compressafter:uinteger' \ + 'sadc_options:string' \ + 'sa_dir:string' \ + 'zip:string' \ + 'enabled:string' +} + +start_service() { + + local log_history compressafter sadc_options sa_dir zip enabled + + validate_sysstat_section sysstat || { + echo "validation failed" + return 1 + } + + [ -d /var/log/sysstat ] || mkdir -p /var/log/sysstat + + echo "HISTORY=$log_history" > $SYSSTAT_CFG + echo "COMPRESSAFTER=$compressafter" >> $SYSSTAT_CFG + echo "SADC_OPTIONS=\"$sadc_options\"" >> $SYSSTAT_CFG + echo "SA_DIR=\"$sa_dir\"" >> $SYSSTAT_CFG + echo "ZIP=\"$zip\"" >> $SYSSTAT_CFG + echo "ENABLED=\"$enabled\"" >> $SYSSTAT_CFG + + procd_open_instance + procd_set_param command $PROG -S DISK -F -L - + procd_set_param file $SYSSTAT_CFG + procd_close_instance +} + +service_triggers() +{ + procd_add_reload_trigger "sysstat" + procd_add_validation validate_sysstat_section +} diff --git a/utils/sysstat/patches/100-musl-compat.patch b/utils/sysstat/patches/100-musl-compat.patch new file mode 100644 index 000000000..06c781327 --- /dev/null +++ b/utils/sysstat/patches/100-musl-compat.patch @@ -0,0 +1,30 @@ +--- a/sa_common.c ++++ b/sa_common.c +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include + #include + #include + +--- a/common.c ++++ b/common.c +@@ -30,6 +30,7 @@ + #include + #include + #include ++#include + + #include "version.h" + #include "common.h" +--- a/ioconf.c ++++ b/ioconf.c +@@ -27,6 +27,7 @@ + #include + #include + #include ++#include + + #include "ioconf.h" + #include "common.h" diff --git a/utils/tar/Makefile b/utils/tar/Makefile new file mode 100644 index 000000000..02d796b32 --- /dev/null +++ b/utils/tar/Makefile @@ -0,0 +1,64 @@ +# +# Copyright (C) 2008-2015 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:=tar +PKG_VERSION:=1.28 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=@GNU/$(PKG_NAME) +PKG_MD5SUM:=8f32b2bc1ed7ddf4cf4e4a39711341b0 +PKG_MAINTAINER:=Álvaro Fernández Rojas + +PKG_LICENSE:=GPL-3.0 +PKG_LICENSE_FILES:=COPYING + +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/tar + SECTION:=utils + CATEGORY:=Utilities + DEPENDS:=+bzip2 +libacl +libattr + TITLE:=GNU tar + URL:=http://www.gnu.org/software/tar/ +endef + +define Package/tar/description + Tar is a program for packaging a set of files as a + single archive in tar format. +endef + +define Package/tar/postinst +#!/bin/sh +if [ -e $${IPKG_INSTROOT}/bin/tar ]; then + rm -r $${IPKG_INSTROOT}/bin/tar; +fi +ln -sf /usr/bin/tar $${IPKG_INSTROOT}/bin/tar +endef + +define Package/tar/postrm +#!/bin/sh +rm $${IPKG_INSTROOT}/bin/tar +ln -s busybox $${IPKG_INSTROOT}/bin/tar +$${IPKG_INSTROOT}/bin/tar 2>&1 | grep 'applet not found' > /dev/null 2>&1 && rm $${IPKG_INSTROOT}/bin/tar +exit 0 +endef + +MAKE_FLAGS += \ + CFLAGS="$(TARGET_CFLAGS)" \ + LDFLAGS="$(TARGET_LDLAGS)" + +define Package/tar/install + $(INSTALL_DIR) $(1)/usr/bin/ + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/$(PKG_NAME) $(1)/usr/bin/ +endef + +$(eval $(call BuildPackage,tar)) diff --git a/utils/taskwarrior/Makefile b/utils/taskwarrior/Makefile index d42e9ab57..a417a45b0 100644 --- a/utils/taskwarrior/Makefile +++ b/utils/taskwarrior/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=taskwarrior -PKG_VERSION:=2.4.0 +PKG_VERSION:=2.4.4 PKG_RELEASE:=1 PKG_LICENSE:=MIT PKG_SOURCE:=task-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.taskwarrior.org/download/ -PKG_MD5SUM:=de4b64b3d28bb9636af219a486552cd0 +PKG_MD5SUM:=517450c4a23a5842df3e9905b38801b3 PKG_MAINTAINER:=Luka Perkov PKG_BUILD_DIR:=$(BUILD_DIR)/task-$(PKG_VERSION) diff --git a/utils/tcsh/Makefile b/utils/tcsh/Makefile index a50f18200..2c68a4a0d 100644 --- a/utils/tcsh/Makefile +++ b/utils/tcsh/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2011-2014 OpenWrt.org +# Copyright (C) 2011-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -7,12 +7,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tcsh -PKG_VERSION:=6.18.01 -PKG_RELEASE:=1 +PKG_VERSION:=6.19.00 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=ftp://ftp.astron.com/pub/tcsh/ -PKG_MD5SUM:=6eed09dbd4223ab5b6955378450d228a +PKG_SOURCE_URL:=http://ftp.funet.fi/pub/mirrors/ftp.astron.com/pub/tcsh/ +PKG_MD5SUM:=f5f854833578647795bc906dd4bcb5d5 PKG_LICENSE:=BSD-4-Clause-UC PKG_LICENSE_FILES:=Copyright diff --git a/utils/tcsh/patches/001-gethost b/utils/tcsh/patches/001-gethost new file mode 100644 index 000000000..b05e155de --- /dev/null +++ b/utils/tcsh/patches/001-gethost @@ -0,0 +1,11 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -449,7 +449,7 @@ pure:$(P) ${OBJS} + + gethost: gethost.c sh.err.h tc.const.h sh.h + rm -f gethost +- ${CC_FOR_GETHOST} -o gethost ${CPPFLAGS} ${CFLAGS} $(srcdir)/gethost.c ++ ${CC_FOR_GETHOST} -o gethost ${CPPFLAGS} $(srcdir)/gethost.c + + tc.defs.c: gethost host.defs + @rm -f $@.tmp diff --git a/utils/tcsh/patches/100-musl-compat.patch b/utils/tcsh/patches/100-musl-compat.patch new file mode 100644 index 000000000..29ebcfc0e --- /dev/null +++ b/utils/tcsh/patches/100-musl-compat.patch @@ -0,0 +1,11 @@ +--- a/sh.proc.c ++++ b/sh.proc.c +@@ -48,7 +48,7 @@ RCSID("$tcsh: sh.proc.c,v 3.127 2015/02/ + #endif /* aiws */ + + #if defined(_BSD) || (defined(IRIS4D) && __STDC__) || defined(__lucid) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__) +-# if !defined(__ANDROID__) ++# if !(defined(__ANDROID__) || (defined(__linux__) && !defined(__GLIBC__))) + # define BSDWAIT + # endif + #endif /* _BSD || (IRIS4D && __STDC__) || __lucid || glibc */ diff --git a/utils/tmux/Makefile b/utils/tmux/Makefile index 1a7e6d147..db13ff5b9 100644 --- a/utils/tmux/Makefile +++ b/utils/tmux/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2009-2012 OpenWrt.org +# Copyright (C) 2009-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -8,16 +8,18 @@ include $(TOPDIR)/rules.mk PKG_NAME:=tmux -PKG_VERSION:=1.9a +PKG_VERSION:=2.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/tmux -PKG_MD5SUM:=b07601711f96f1d260b390513b509a2d +PKG_MD5SUM:=9fb6b443392c3978da5d599f1e814eaa PKG_MAINTAINER:=Maxim Storchak + PKG_LICENSE:=ISC PKG_LICENSE_FILES:=COPYING +PKG_BUILD_PARALLEL:=1 PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk diff --git a/utils/tmux/patches/100-b64_ntop-conflict.patch b/utils/tmux/patches/100-b64_ntop-conflict.patch new file mode 100644 index 000000000..6350f5b71 --- /dev/null +++ b/utils/tmux/patches/100-b64_ntop-conflict.patch @@ -0,0 +1,35 @@ +--- a/compat.h ++++ b/compat.h +@@ -230,7 +230,9 @@ int daemon(int, int); + #ifndef HAVE_B64_NTOP + /* b64_ntop.c */ + #undef b64_ntop /* for Cygwin */ +-int b64_ntop(const char *, size_t, char *, size_t); ++int local_b64_ntop(const char *, size_t, char *, size_t); ++#else ++#define local_b64_ntop b64_ntop + #endif + + #ifndef HAVE_FORKPTY +--- a/tty.c ++++ b/tty.c +@@ -1070,7 +1070,7 @@ tty_cmd_setselection(struct tty *tty, co + off = 4 * ((ctx->num + 2) / 3) + 1; /* storage for base64 */ + buf = xmalloc(off); + +- b64_ntop(ctx->ptr, ctx->num, buf, off); ++ local_b64_ntop(ctx->ptr, ctx->num, buf, off); + tty_putcode_ptr2(tty, TTYC_MS, "", buf); + + free(buf); +--- a/compat/b64_ntop.c ++++ b/compat/b64_ntop.c +@@ -122,7 +122,7 @@ static const char Pad64 = '='; + */ + + int +-b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) { ++local_b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) { + size_t datalength = 0; + uint8_t input[3]; + uint8_t output[4]; diff --git a/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch b/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch deleted file mode 100644 index 3b216698c..000000000 --- a/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/compat.h b/compat.h -index 65d6ec7..7fc3aa7 100644 ---- a/compat.h -+++ b/compat.h -@@ -219,7 +219,9 @@ int daemon(int, int); - #ifndef HAVE_B64_NTOP - /* b64_ntop.c */ - #undef b64_ntop /* for Cygwin */ --int b64_ntop(const char *, size_t, char *, size_t); -+int local_b64_ntop(const char *, size_t, char *, size_t); -+#else -+#define local_b64_ntop b64_ntop - #endif - - #ifndef HAVE_FORKPTY diff --git a/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch b/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch deleted file mode 100644 index a03d18fab..000000000 --- a/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/compat/b64_ntop.c b/compat/b64_ntop.c -index 2b4dc2d..a1314ca 100644 ---- a/compat/b64_ntop.c -+++ b/compat/b64_ntop.c -@@ -122,7 +122,7 @@ static const char Pad64 = '='; - */ - - int --b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) { -+local_b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) { - size_t datalength = 0; - uint8_t input[3]; - uint8_t output[4]; diff --git a/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch b/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch deleted file mode 100644 index 72e0a0789..000000000 --- a/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/tty.c b/tty.c -index eb2511c..576edbc 100644 ---- a/tty.c -+++ b/tty.c -@@ -1067,7 +1067,7 @@ tty_cmd_setselection(struct tty *tty, const struct tty_ctx *ctx) - off = 4 * ((ctx->num + 2) / 3) + 1; /* storage for base64 */ - buf = xmalloc(off); - -- b64_ntop(ctx->ptr, ctx->num, buf, off); -+ local_b64_ntop(ctx->ptr, ctx->num, buf, off); - tty_putcode_ptr2(tty, TTYC_MS, "", buf); - - free(buf); diff --git a/utils/unrar/Makefile b/utils/unrar/Makefile index f74f7ad29..bcabfc567 100644 --- a/utils/unrar/Makefile +++ b/utils/unrar/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=unrar -PKG_VERSION:=5.2.5 +PKG_VERSION:=5.2.7 PKG_RELEASE:=1 PKG_SOURCE:=unrarsrc-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://www.rarlab.com/rar -PKG_MD5SUM:=ba69acb6c17fb4829ea7440079001c36 +PKG_MD5SUM:=0c145e1ac47d428553123462c0740279 PKG_MAINTAINER:=Álvaro Fernández Rojas PKG_LICENSE:=UnRAR diff --git a/utils/usbmuxd/Makefile b/utils/usbmuxd/Makefile index 65ab01667..239c84b72 100644 --- a/utils/usbmuxd/Makefile +++ b/utils/usbmuxd/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=usbmuxd PKG_VERSION:=1.1.1 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE_PROTO:=git PKG_MAINTAINER:=Lukasz Baj @@ -31,7 +31,7 @@ define Package/usbmuxd CATEGORY:=Utilities TITLE:=USB multiplexing daemon URL:=http://www.libimobiledevice.org/ - DEPENDS:=+librt +libusb-1.0 +libusbmuxd +libcrypto +libopenssl +libimobiledevice + DEPENDS:=+librt +libusb-1.0 +libusbmuxd +libopenssl +libimobiledevice endef define Package/usbmuxd/description diff --git a/utils/vim/Makefile b/utils/vim/Makefile new file mode 100644 index 000000000..2e9f96a8b --- /dev/null +++ b/utils/vim/Makefile @@ -0,0 +1,194 @@ +# +# Copyright (C) 2015 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:=vim +PKG_VERSION:=7.4 +PKG_RELEASE:=3 +VIMVER:=74 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=ftp://ftp.vim.org/pub/vim/unix/ +PKG_MD5SUM:=607e135c559be642f210094ad023dc65 +PKG_MAINTAINER:=Marko Ratkaj + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)$(VIMVER) +PKG_BUILD_PARALLEL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/vim/Default + SECTION:=utils + CATEGORY:=Utilities + DEPENDS:=+libncurses + TITLE:=Vi IMproved - enhanced vi editor + URL:=http://www.vim.org/ + SUBMENU:=Editors +endef + +define Package/vim + $(call Package/vim/Default) + TITLE+= (Tiny) +endef + +define Package/vim-full + $(call Package/vim/Default) + TITLE+= (Normal) +endef + +define Package/vim-runtime + $(call Package/vim/Default) + TITLE+= (runtime files) +endef + +define Package/vim-help + $(call Package/vim/Default) + TITLE+= (help files) +endef + +define Package/xxd + SECTION:=utils + CATEGORY:=Utilities + TITLE:=make a hexdump or do the reverse + URL:=http://www.vim.org/ +endef + +define Package/vim-full/conffiles +/usr/share/vim/vimrc +/root/.vimrc +endef + +define Package/vim/conffiles +/usr/share/vim/vimrc +/root/.vimrc +endef + +define Package/vim/description + Vim is an almost compatible version of the UNIX editor Vi. + (Tiny build) +endef + +define Package/vim-full/description + Vim is an almost compatible version of the UNIX editor Vi. + (Normal build) +endef + +define Package/vim-runtime/description + Vim is an almost compatible version of the UNIX editor Vi. + (Runtime files) +endef + +define Package/vim-help/description + Vim is an almost compatible version of the UNIX editor Vi. + (Help files) +endef + +define Package/xxd/description + xxd creates a hex dump of a given file or standard input, it can also convert + a hex dump back to its original binary form. +endef + +CONFIGURE_ARGS += \ + --disable-gui \ + --disable-gtktest \ + --disable-xim \ + --without-x \ + --disable-netbeans \ + --disable-cscope \ + --disable-gpm \ + --disable-acl \ + --with-tlib=ncurses + +CONFIGURE_VARS += \ + vim_cv_getcwd_broken=no \ + vim_cv_memmove_handles_overlap=yes \ + vim_cv_stat_ignores_slash=yes \ + vim_cv_tgetent=zero \ + vim_cv_terminfo=yes \ + vim_cv_toupper_broken=no \ + vim_cv_tty_group=root \ + vim_cv_tty_mode=0620 + +ifneq ($(CONFIG_PACKAGE_vim),) +define Build/Compile/vim + $(call Build/Configure/Default, \ + --with-features=tiny \ + --disable-multibyte \ + ) + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" all + $(CP) $(PKG_BUILD_DIR)/src/$(PKG_NAME) $(PKG_BUILD_DIR)/vim_tiny +endef +endif + +ifneq ($(CONFIG_PACKAGE_vim-full),) +define Build/Compile/vim-full + $(call Build/Configure/Default, \ + --with-features=normal \ + --enable-multibyte \ + ) + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" all + $(CP) $(PKG_BUILD_DIR)/src/$(PKG_NAME) $(PKG_BUILD_DIR)/vim_normal +endef +endif + +ifneq ($(CONFIG_PACKAGE_xxd),) +define Build/Compile/xxd + +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" all +endef +endif + +define Build/Compile/vim-runtime + $(MAKE) -C $(PKG_BUILD_DIR)/src DESTDIR="$(PKG_INSTALL_DIR)" installrtbase + (cd $(PKG_INSTALL_DIR) && tar -cf $(PKG_BUILD_DIR)/docs.tar ./usr/share/vim/vim$(VIMVER)/doc) + rm -rf $(PKG_INSTALL_DIR)/usr/share/vim/vim$(VIMVER)/doc + rm -rf $(PKG_INSTALL_DIR)/usr/man +endef + +define Build/Compile +$(call Build/Compile/vim) +$(call Build/Compile/vim-full) +$(call Build/Compile/vim-runtime) +$(call Build/Compile/xxd) +endef + +define Package/vim/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/vim_tiny $(1)/usr/bin/vim + $(INSTALL_DIR) $(1)/usr/share/vim + $(INSTALL_CONF) ./files/vimrc $(1)/usr/share/vim/ +endef + +define Package/vim-full/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/vim_normal $(1)/usr/bin/vim + $(INSTALL_DIR) $(1)/usr/share/vim + $(INSTALL_CONF) ./files/vimrc.full $(1)/usr/share/vim/vimrc +endef + +define Package/vim-runtime/install + $(CP) $(PKG_INSTALL_DIR)/* $(1) + rm -rf $(1)/usr/share/vim/vim$(VIMVER)/doc +endef + +define Package/vim-help/install + tar -C $(1) -xf $(PKG_BUILD_DIR)/docs.tar +endef + +define Package/xxd/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/xxd/xxd $(1)/usr/bin +endef + +$(eval $(call BuildPackage,vim)) +$(eval $(call BuildPackage,vim-full)) +$(eval $(call BuildPackage,vim-runtime)) +$(eval $(call BuildPackage,vim-help)) +$(eval $(call BuildPackage,xxd)) diff --git a/utils/vim/files/vimrc b/utils/vim/files/vimrc new file mode 100644 index 000000000..b8cea2938 --- /dev/null +++ b/utils/vim/files/vimrc @@ -0,0 +1,12 @@ +set showcmd " show (partial) command in status line +set showmatch " show matching brackets +set incsearch " incremental search +set autowrite " automatically save before commands like :next and :make +set nocompatible " use vim defaults instead of 100% vi compatibility +set backspace=indent,eol,start " more powerful backspacing +set autoindent " always set autoindenting on +set linebreak " don't wrap words by default +set textwidth=0 " don't wrap lines by default +set ruler " show the cursor position all the time + +set backupskip+=/etc/crontabs.* " fix crontab -e diff --git a/utils/vim/files/vimrc.full b/utils/vim/files/vimrc.full new file mode 100644 index 000000000..99f737e84 --- /dev/null +++ b/utils/vim/files/vimrc.full @@ -0,0 +1,30 @@ +set showcmd " show (partial) command in status line +set showmatch " show matching brackets +set incsearch " incremental search +set autowrite " automatically save before commands like :next and :make +set nocompatible " use Vim defaults instead of 100% vi compatibility +set backspace=indent,eol,start " more powerful backspacing +set autoindent " always set autoindenting on +set linebreak " don't wrap words by default +set textwidth=0 " don't wrap lines by default +set ruler " show the cursor position all the time + +set backupskip+=/etc/crontabs.* " fix crontab -e + +if filereadable(expand("$VIMRUNTIME/syntax/synload.vim")) + syntax on +endif +if has("syntax") && &term =~ "xterm" + set t_Co=8 + if has("terminfo") + set t_Sf=[3%p1%dm + set t_Sb=[4%p1%dm + else + set t_Sf=[3%dm + set t_Sb=[4%dm + endif +endif + +" Uncomment out for line and/or relative numberig +" set number +" set rnu diff --git a/utils/vim/patches/001-compile.patch b/utils/vim/patches/001-compile.patch new file mode 100644 index 000000000..6740f1a8e --- /dev/null +++ b/utils/vim/patches/001-compile.patch @@ -0,0 +1,41 @@ +--- a/src/auto/configure ++++ b/src/auto/configure +@@ -12294,37 +12294,8 @@ _ACEOF + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking uint32_t is 32 bits" >&5 + $as_echo_n "checking uint32_t is 32 bits... " >&6; } +-if test "$cross_compiling" = yes; then : +- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check uint32_t when cross-compiling." >&5 +-$as_echo "$as_me: WARNING: cannot check uint32_t when cross-compiling." >&2;} +-else +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#ifdef HAVE_STDINT_H +-# include +-#endif +-#ifdef HAVE_INTTYPES_H +-# include +-#endif +-main() { +- uint32_t nr1 = (uint32_t)-1; +- uint32_t nr2 = (uint32_t)0xffffffffUL; +- if (sizeof(uint32_t) != 4 || nr1 != 0xffffffffUL || nr2 + 1 != 0) exit(1); +- exit(0); +-} +-_ACEOF +-if ac_fn_c_try_run "$LINENO"; then : +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: assuming ok" >&5 + $as_echo "ok" >&6; } +-else +- as_fn_error "WRONG! uint32_t not defined correctly." "$LINENO" 5 +-fi +-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ +- conftest.$ac_objext conftest.beam conftest.$ac_ext +-fi +- +- + + bcopy_test_prog=' + #include "confdefs.h" diff --git a/utils/vim/patches/002-remove_helptags_generation.patch b/utils/vim/patches/002-remove_helptags_generation.patch new file mode 100644 index 000000000..051c8dac8 --- /dev/null +++ b/utils/vim/patches/002-remove_helptags_generation.patch @@ -0,0 +1,10 @@ +--- a/runtime/doc/Makefile ++++ b/runtime/doc/Makefile +@@ -310,7 +310,6 @@ all: tags vim.man evim.man vimdiff.man v + # Use Vim to generate the tags file. Can only be used when Vim has been + # compiled and installed. Supports multiple languages. + vimtags: $(DOCS) +- $(VIMEXE) -u NONE -esX -c "helptags ++t ." -c quit + + # Use "doctags" to generate the tags file. Only works for English! + tags: doctags $(DOCS) diff --git a/utils/xz/Makefile b/utils/xz/Makefile new file mode 100644 index 000000000..373140da2 --- /dev/null +++ b/utils/xz/Makefile @@ -0,0 +1,116 @@ +# +# Copyright (C) 2013-2015 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:=xz +PKG_VERSION:=5.2.1 +PKG_RELEASE:=2 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:=http://tukaani.org/xz +PKG_MD5SUM:=d484910b26fec5aff99ee66350589e29 + +PKG_LICENSE:=Public-Domain LGPL-2.1+ GPL-2.0+ GPL-3.0+ +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Nicolas Thill + +PKG_BUILD_PARALLEL:=1 +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/xz/Default + SUBMENU:=Compression + SECTION:=utils + CATEGORY:=Utilities + URL:=http://tukaani.org/xz +endef + +define Package/xz-utils +$(call Package/xz/Default) + TITLE:=XZ Utils (meta) + MENU:=1 +endef + +define Package/liblzma +$(call Package/xz/Default) + SECTION:=libs + CATEGORY:=Libraries + DEPENDS:=+libpthread + TITLE:=liblzma library from XZ Utils +endef + +# $(1): package name & command in /usr/bin/ +# $(2): package dependencies +# $(3): symbolic links to $(1) in /usr/bin/ +define BuildSubPackage + + define Package/$(1) + $(call Package/xz/Default) + DEPENDS:=xz-utils $(2) + TITLE:=$(1) utility from XZ Utils + endef + + define Package/$(1)/description + Contains: $(1) $(3) + endef + + define Package/$(1)/install + $(INSTALL_DIR) $$(1)/usr/bin + $(CP) $(foreach f,$(1) $(3),$(PKG_INSTALL_DIR)/usr/bin/$(f)) $$(1)/usr/bin/ + endef + + $$(eval $$(call BuildPackage,$(1))) +endef + + +CONFIGURE_ARGS += \ + --enable-small \ + --enable-assume-ram=4 \ + --disable-assembler \ + --disable-werror \ + +# API uses "restrict" keyword introduced in C99 standard +TARGET_CFLAGS += \ + -std=c99 \ + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/lzma{,.h} \ + $(1)/usr/include/ + $(INSTALL_DIR) $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/liblzma.{a,so*} \ + $(1)/usr/lib/ + $(INSTALL_DIR) $(1)/usr/lib/pkgconfig + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/liblzma.pc \ + $(1)/usr/lib/pkgconfig/ +endef + +define Package/xz-utils/install + true +endef + +define Package/liblzma/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/liblzma.so.* $(1)/usr/lib/ +endef + + +$(eval $(call BuildPackage,xz-utils)) +$(eval $(call BuildPackage,liblzma)) +$(eval $(call BuildSubPackage,lzmadec, +liblzma,)) +$(eval $(call BuildSubPackage,lzmainfo, +liblzma,)) +$(eval $(call BuildSubPackage,xz, +liblzma, lzcat lzma unlzma unxz xzcat)) +$(eval $(call BuildSubPackage,xzdec, +liblzma,)) +$(eval $(call BuildSubPackage,xzdiff, +bash +xz, lzcmp lzdiff xzcmp)) +$(eval $(call BuildSubPackage,xzgrep, +bash +xz, lzegrep lzfgrep lzgrep xzegrep xzfgrep)) +$(eval $(call BuildSubPackage,xzless, +bash +xz, lzless)) +$(eval $(call BuildSubPackage,xzmore, +bash +xz, lzmore)) diff --git a/utils/zoneinfo/Makefile b/utils/zoneinfo/Makefile index 6f1b6ef8f..8b39dc48f 100644 --- a/utils/zoneinfo/Makefile +++ b/utils/zoneinfo/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,8 +9,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=zoneinfo -PKG_VERSION:=2015a -PKG_VERSION_CODE:=2015a +PKG_VERSION:=2015e +PKG_VERSION_CODE:=2015e PKG_RELEASE:=1 #As i couldn't find real license used "Public Domain" @@ -20,14 +20,14 @@ PKG_LICENSE:=Public Domain PKG_SOURCE:=tzdata$(PKG_VERSION).tar.gz PKG_SOURCE_CODE:=tzcode$(PKG_VERSION_CODE).tar.gz PKG_SOURCE_URL:=http://www.iana.org/time-zones/repository/releases -PKG_MD5SUM:=4ed11c894a74a5ea64201b1c6dbb8831 +PKG_MD5SUM:=36f9056efb432ca945c73397acfce0d4 include $(INCLUDE_DIR)/package.mk define Download/tzcode FILE=$(PKG_SOURCE_CODE) URL=$(PKG_SOURCE_URL) - MD5SUM:=8f375ede46ae137fbac047ac431bda37 + MD5SUM:=fb62eb6daf3ddb8c41fd40be05ec657e endef $(eval $(call Download,tzcode))