Pārlūkot izejas kodu

Merge branch 'master' of git+ssh://openadk.org/git/openadk

Waldemar Brodkorb 11 gadi atpakaļ
vecāks
revīzija
850ed0a79f
100 mainītis faili ar 1686 papildinājumiem un 127 dzēšanām
  1. 1 1
      BUGS
  2. 2 0
      TODO
  3. 10 9
      mk/build.mk
  4. 1 1
      mk/image.mk
  5. 2 2
      mk/rootfs.mk
  6. 1 1
      mk/vars.mk
  7. 1 1
      package/adk-test-tools/Makefile
  8. 4 0
      package/adk-test-tools/files/test.init
  9. 1 1
      package/asterisk/Makefile
  10. 12 13
      package/base-files/Makefile
  11. 1 1
      package/base-files/files/inittab.shell
  12. 1 1
      package/base-files/src/etc/ipkg.conf
  13. 0 4
      package/base-files/src/usr/share/udhcpc/default.script
  14. 26 0
      package/check/Makefile
  15. 2 0
      package/dbus-python/Makefile
  16. 1 1
      package/ebtables/Makefile
  17. 3 3
      package/ebtables/patches/patch-Makefile
  18. 10 0
      package/ebtables/patches/patch-extensions_ebt_among_c
  19. 10 0
      package/ebtables/patches/patch-extensions_ebt_arpreply_c
  20. 10 0
      package/ebtables/patches/patch-extensions_ebt_ip6_c
  21. 10 0
      package/ebtables/patches/patch-extensions_ebt_limit_c
  22. 10 0
      package/ebtables/patches/patch-extensions_ebt_nat_c
  23. 29 0
      package/ebtables/patches/patch-include_ethernetdb_h
  24. 10 0
      package/ebtables/patches/patch-useful_functions_c
  25. 7 5
      package/ethtool/Makefile
  26. 33 0
      package/ethtool/patches/patch-internal_h
  27. 11 13
      package/eudev/Makefile
  28. 2 2
      package/feh/Makefile
  29. 2 2
      package/fetchmail/Makefile
  30. 17 8
      package/findutils/Makefile
  31. 11 0
      package/findutils/patches/patch-configure_ac
  32. 15 0
      package/findutils/patches/patch-gnulib_lib_freadahead_c
  33. 24 0
      package/findutils/patches/patch-gnulib_lib_freadahead_h
  34. 18 0
      package/findutils/patches/patch-gnulib_lib_fseeko_c
  35. 25 0
      package/findutils/patches/patch-gnulib_m4_fflush_m4
  36. 3 3
      package/gkrellm/Makefile
  37. 0 30
      package/gkrellm/patches/patch-server_Makefile
  38. 24 0
      package/gkrellm/patches/patch-server_main_c
  39. 10 0
      package/gkrellm/patches/patch-server_sysdeps-unix_c
  40. 4 4
      package/glib/Makefile
  41. 1 1
      package/gpsd/Makefile
  42. 1 1
      package/ipcad/Makefile
  43. 169 0
      package/ipcad/patches/patch-Makefile
  44. 10 1
      package/ipcad/patches/patch-Makefile_in
  45. 60 0
      package/ipcad/patches/patch-cfg_y
  46. 2 0
      package/iptables-snmp/Makefile
  47. 8 3
      package/kbd/Makefile
  48. 46 0
      package/kbd/patches/patch-src_kbdinfo_c
  49. 10 0
      package/kbd/patches/patch-src_kbdrate_c
  50. 11 0
      package/kbd/patches/patch-src_libkeymap_dump_c
  51. 7 0
      package/kbd/patches/patch-src_libkeymap_kmap_c
  52. 11 0
      package/kbd/patches/patch-src_libkeymap_summary_c
  53. 8 0
      package/kbd/patches/patch-src_openvt_c
  54. 70 0
      package/kbd/patches/patch-src_setvtrgb_c
  55. 4 4
      package/libmodplug/Makefile
  56. 1 3
      package/libtirpc/Makefile
  57. 18 0
      package/libtirpc/patches/patch-src_auth_des_c
  58. 10 0
      package/libtirpc/patches/patch-src_auth_none_c
  59. 13 5
      package/libtirpc/patches/patch-src_auth_time_c
  60. 10 0
      package/libtirpc/patches/patch-src_auth_unix_c
  61. 7 0
      package/libtirpc/patches/patch-src_authdes_prot_c
  62. 10 0
      package/libtirpc/patches/patch-src_authunix_prot_c
  63. 18 0
      package/libtirpc/patches/patch-src_bindresvport_c
  64. 22 0
      package/libtirpc/patches/patch-src_clnt_bcast_c
  65. 10 0
      package/libtirpc/patches/patch-src_clnt_perror_c
  66. 10 0
      package/libtirpc/patches/patch-src_clnt_simple_c
  67. 10 0
      package/libtirpc/patches/patch-src_crypt_client_c
  68. 7 3
      package/libtirpc/patches/patch-src_des_crypt_c
  69. 9 0
      package/libtirpc/patches/patch-src_des_soft_c
  70. 10 0
      package/libtirpc/patches/patch-src_getnetconfig_c
  71. 16 0
      package/libtirpc/patches/patch-src_getnetpath_c
  72. 10 0
      package/libtirpc/patches/patch-src_getpeereid_c
  73. 10 0
      package/libtirpc/patches/patch-src_getpublickey_c
  74. 10 0
      package/libtirpc/patches/patch-src_key_call_c
  75. 10 0
      package/libtirpc/patches/patch-src_key_prot_xdr_c
  76. 8 0
      package/libtirpc/patches/patch-src_mt_misc_c
  77. 10 0
      package/libtirpc/patches/patch-src_pmap_clnt_c
  78. 10 0
      package/libtirpc/patches/patch-src_pmap_getmaps_c
  79. 31 0
      package/libtirpc/patches/patch-src_rpc_com_h
  80. 10 0
      package/libtirpc/patches/patch-src_rpc_generic_c
  81. 10 0
      package/libtirpc/patches/patch-src_rpcb_st_xdr_c
  82. 10 0
      package/libtirpc/patches/patch-src_rpcdname_c
  83. 10 0
      package/libtirpc/patches/patch-src_svc_dg_c
  84. 10 0
      package/libtirpc/patches/patch-src_svc_simple_c
  85. 10 0
      package/libtirpc/patches/patch-src_svc_vc_c
  86. 10 0
      package/libtirpc/patches/patch-src_xdr_array_c
  87. 10 0
      package/libtirpc/patches/patch-src_xdr_c
  88. 10 0
      package/libtirpc/patches/patch-src_xdr_float_c
  89. 10 0
      package/libtirpc/patches/patch-src_xdr_mem_c
  90. 11 0
      package/libtirpc/patches/patch-src_xdr_rec_c
  91. 11 0
      package/libtirpc/patches/patch-src_xdr_reference_c
  92. 10 0
      package/libtirpc/patches/patch-src_xdr_sizeof_c
  93. 10 0
      package/libtirpc/patches/patch-src_xdr_stdio_c
  94. 24 0
      package/libtirpc/patches/patch-tirpc_misc_event_h
  95. 23 0
      package/libtirpc/patches/patch-tirpc_netconfig_h
  96. 32 0
      package/libtirpc/patches/patch-tirpc_rpc_auth_des_h
  97. 53 0
      package/libtirpc/patches/patch-tirpc_rpc_auth_gss_h
  98. 192 0
      package/libtirpc/patches/patch-tirpc_rpc_auth_h
  99. 26 0
      package/libtirpc/patches/patch-tirpc_rpc_auth_unix_h
  100. 132 0
      package/libtirpc/patches/patch-tirpc_rpc_clnt_h

+ 1 - 1
BUGS

@@ -2,4 +2,4 @@
 - qemu-sh4: usb keyboard is broken
 - qemu-arm: thumb mode with glibc does not boot
 - qemu-sparc64: ide driver not working, only virtio (but unstable)
-- qemu-microblaze: network card emulation fails, little endian works
+- qemu-microblaze: ml605 early printk and network card emulation fails, little endian works

+ 2 - 0
TODO

@@ -1,4 +1,5 @@
 - hash-style=gnu for non-mips and non-musl
+- fix libiberty.a mess
 - check gold for mozilla compile
 - check for gcc and SSP again
 - add daemon() function to functions.sh
@@ -16,5 +17,6 @@
 - microblaze: add cfgfs partition to dts, add partition to spartan dts
 - evaluate libguestfs for image creation
 - port w3m
+- port msmtp
 - rutorrent porting
 - lms perl 

+ 10 - 9
mk/build.mk

@@ -79,6 +79,7 @@ DEFCONFIG=		ADK_DEBUG=n \
 			BUSYBOX_FEATURE_VI_REGEX_SEARCH=n \
 			ADK_KERNEL_RT2X00_DEBUG=n \
 			ADK_KERNEL_ATH5K_DEBUG=n \
+			ADK_KERNEL_BUG=n \
 			ADK_KERNEL_DEBUG_WITH_KGDB=n
 
 noconfig_targets:=	menuconfig \
@@ -98,7 +99,7 @@ POSTCONFIG=		-@\
 			touch .rebuild.busybox;\
 			rebuild=1;\
 		fi; \
-		for i in ADK_RUNTIME_PASSWORD ADK_RUNTIME_TMPFS_SIZE ADK_RUNTIME_HOSTNAME ADK_TARGET_ROOTFS ADK_RUNTIME_GETTY ADK_RUNTIME_SHELL;do \
+		for i in ADK_RUNTIME_PASSWORD ADK_RUNTIME_TMPFS_SIZE ADK_RUNTIME_HOSTNAME ADK_TARGET_ROOTFS ADK_RUNTIME_CONSOLE ADK_RUNTIME_GETTY ADK_RUNTIME_SHELL;do \
 			if [ "$$(grep ^$$i .config|md5sum)" != "$$(grep ^$$i .config.old|md5sum)" ];then \
 				touch .rebuild.base-files;\
 				rebuild=1;\
@@ -169,7 +170,7 @@ endif
 
 ${STAGING_TARGET_DIR} ${STAGING_TARGET_DIR}/etc ${STAGING_HOST_DIR}:
 	mkdir -p ${STAGING_TARGET_DIR}/{bin,etc,lib,usr/bin,usr/include,usr/lib/pkgconfig} \
-		${STAGING_HOST_DIR}/{bin,lib,usr/bin,usr/lib,usr/include}
+		${STAGING_HOST_DIR}/{usr/bin,usr/lib,usr/include}
 	for i in lib64 lib32 libx32;do \
 		cd ${STAGING_TARGET_DIR}/; ln -sf lib $$i; \
 		cd ${STAGING_TARGET_DIR}/usr; ln -sf lib $$i; \
@@ -476,17 +477,18 @@ bulktoolchain:
 		    ( \
 			echo === building $$arch $$libc toolchain-$$arch on $$(date); \
 			tarch=$$(echo $$arch|sed -e "s#el##" -e "s#eb##" -e "s#mips64.*#mips#" -e "s#hf##"); \
-			if [ -f ${TOPDIR}/firmware/toolchain_$${arch}_$${libc}.tar.xz ];then exit;fi; \
+			carch=$$(echo $$arch|sed -e "s#sh#sh4#" -e "s#hf##" -e "s#mips64n.*#mips64#" -e "s#mips64el.*#mips64el#" ); \
 			$(GMAKE) prereq && \
 				$(GMAKE) ARCH=$$tarch SYSTEM=toolchain-$$arch LIBC=$$libc defconfig; \
-				$(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit; break;fi; \
-				if [ $$arch = "armhf" ];then arch=arm; else arch=$$arch;fi; \
 				tabi=$$(grep ^ADK_TARGET_ABI= .config|cut -d \" -f 2);\
+				if [ $$arch = "armhf" ];then arch=arm; else arch=$$arch;fi; \
 				if [ -z $$tabi ];then abi="";else abi=_$$tabi;fi; \
-				tar -cvJf ${TOPDIR}/firmware/toolchain_$${arch}_$${libc}$${abi}.tar.xz toolchain_${GNU_HOST_NAME} target_$${arch}_$${libc}$${abi}; \
+				if [ -f ${TOPDIR}/firmware/toolchain_$${carch}_$${libc}$${abi}.tar.xz ];then exit;fi; \
+				$(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit; break;fi; \
+				tar -cvJf ${TOPDIR}/firmware/toolchain_$${carch}_$${libc}$${abi}.tar.xz toolchain_${GNU_HOST_NAME} target_$${carch}_$${libc}$${abi}; \
 				$(GMAKE) cleantoolchain; \
 			rm .config; \
-		    ) 2>&1 | tee $(TOPDIR)/firmware/toolchain_build.log; \
+		    ) 2>&1 | tee -a $(TOPDIR)/firmware/toolchain_build.log; \
 		    if [ -f .exit ];then break;fi \
 		done <${TOPDIR}/target/tarch.lst ;\
 		if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
@@ -525,14 +527,13 @@ test-framework:
 
 release:
 	for libc in uclibc glibc musl;do \
-		mkdir -p $(TOPDIR)/firmware/$(SYSTEM)_$(ARCH)_$$libc; \
 		( \
 			echo === building $$libc on $$(date); \
 			$(GMAKE) prereq && \
 			$(GMAKE) ARCH=$(ARCH) SYSTEM=$(SYSTEM) LIBC=$$libc FS=archive allmodconfig; \
 			$(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit; exit 1;fi; \
 			rm .config; \
-		) 2>&1 | tee $(TOPDIR)/firmware/$(SYSTEM)_$(ARCH)_$$libc/build.log; \
+		) 2>&1 | tee $(TOPDIR)/firmware/release-build.log; \
 		if [ -f .exit ];then echo "Bulk build failed!"; break;fi \
 	done
 	if [ -f .exit ];then rm .exit;exit 1;fi

+ 1 - 1
mk/image.mk

@@ -157,7 +157,7 @@ ${BUILD_DIR}/root.squashfs: ${TARGET_DIR}
 		-nopad -noappend -root-owned $(MAKE_TRACE)
 
 ${FW_DIR}/${ROOTFSJFFS2}: ${TARGET_DIR}
-	${STAGING_HOST_DIR}/usr/bin/mkfs.jffs2 $(ADK_JFFS2_OPTS) -q -r ${TARGET_DIR} \
+	${STAGING_HOST_DIR}/usr/bin/mkfs.jffs2 $(ADK_JFFS2_OPTS) -q -X zlib -r ${TARGET_DIR} \
 		--pad=$(ADK_TARGET_MTD_SIZE) -o ${FW_DIR}/${ROOTFSJFFS2} $(MAKE_TRACE)
 
 createinitramfs: ${STAGING_TARGET_DIR}/${INITRAMFS}_list

+ 2 - 2
mk/rootfs.mk

@@ -50,10 +50,10 @@ $(eval $(call rootfs_template,archive,ARCHIVE,$(ROOTFS)))
 $(eval $(call rootfs_template,initramfsarchive,INITRAMFSARCHIVE))
 $(eval $(call rootfs_template,initramfs,INITRAMFS))
 $(eval $(call rootfs_template,initramfs-piggyback,INITRAMFS_PIGGYBACK))
-$(eval $(call rootfs_template,squashfs,SQUASHFS,$(ROOTFS)))
+$(eval $(call rootfs_template,squashfs,SQUASHFS,$(MTDDEV) rootfstype=squashfs))
 $(eval $(call rootfs_template,yaffs,YAFFS,$(MTDDEV) panic=3))
 $(eval $(call rootfs_template,jffs2,JFFS2,$(MTDDEV) rootfstype=jffs2))
-$(eval $(call rootfs_template,nfsroot,NFSROOT,root=/dev/nfs ip=dhcp init=/init))
+$(eval $(call rootfs_template,nfsroot,NFSROOT,root=/dev/nfs ip=dhcp))
 $(eval $(call rootfs_template,encrypted,ENCRYPTED))
 $(eval $(call rootfs_template,iso,ISO))
 

+ 1 - 1
mk/vars.mk

@@ -127,7 +127,7 @@ ifneq ($(ADK_DEBUG),)
 TARGET_CFLAGS+=		-g3 -fno-omit-frame-pointer
 else
 TARGET_CPPFLAGS+=	-DNDEBUG
-TARGET_CFLAGS+=		-fomit-frame-pointer $(TARGET_OPTIMIZATION)
+TARGET_CFLAGS+=		-fomit-frame-pointer $(ADK_TARGET_CFLAGS_OPT)
 # stop generating eh_frame stuff
 TARGET_CFLAGS+=		-fno-unwind-tables -fno-asynchronous-unwind-tables
 # always add debug information

+ 1 - 1
package/adk-test-tools/Makefile

@@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		adk-test-tools
 PKG_VERSION:=		0.1
-PKG_RELEASE:=		3
+PKG_RELEASE:=		5
 PKG_DESCR:=		helper tools and scripts for adk-test-framework
 PKG_SECTION:=		misc
 PKG_URL:=		http://openadk.org/

+ 4 - 0
package/adk-test-tools/files/test.init

@@ -3,6 +3,10 @@
 #INIT 90
 [[ $1 = autostart ]] || exit 0
 echo "Starting test script ..."
+grep shell /proc/cmdline > /dev/null 2&>1
+if [ $? -eq 0 ];then
+	exit 0
+fi
 if [ -x /run.sh ];then
 	/run.sh
 	quit

+ 1 - 1
package/asterisk/Makefile

@@ -105,7 +105,7 @@ TARGET_LDFLAGS+=	-lm -ltinfo -ldl -lpthread
 MAKE_ENV=		ASTCFLAGS="${TARGET_CPPFLAGS} -DHAVE_STRTOQ" \
 			ASTLDFLAGS="${TARGET_LDFLAGS}"
 MAKE_FLAGS+=		DESTDIR="$(WRKINST)" \
-			OPTIMIZE="${TARGET_OPTIMIZATION}" \
+			OPTIMIZE="${TARGET_CFLAGS}" \
 			NOISY_BUILD=1
 ALL_TARGET:=		all install samples
 

+ 12 - 13
package/base-files/Makefile

@@ -6,7 +6,7 @@ include $(TOPDIR)/mk/rootfs.mk
 
 PKG_NAME:=		base-files
 PKG_VERSION:=		1.0
-PKG_RELEASE:=		76
+PKG_RELEASE:=		78
 PKG_SECTION:=		base
 PKG_DESCR:=		basic files and scripts
 PKG_BUILDDEP:=		pkgconf-host file-host
@@ -30,6 +30,11 @@ endif
 	$(SED) 's,@ARCH@,$(ADK_TARGET_CPU_ARCH),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
 	$(SED) 's,@SYSTEM@,$(ADK_TARGET_SYSTEM),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
 	$(SED) 's,@LIBC@,$(ADK_TARGET_LIBC),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
+ifneq ($(ADK_TARGET_ABI),)
+	$(SED) 's,@ABI@,_$(ADK_TARGET_ABI),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
+else
+	$(SED) 's,@ABI@,,g' $(IDIR_BASE_FILES)/etc/ipkg.conf
+endif
 	$(SED) 's,@HOST@,$(ADK_HOST),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
 	$(SED) 's,@VENDOR@,$(ADK_VENDOR),g' $(IDIR_BASE_FILES)/etc/ipkg.conf
 	echo /bin/sh >${IDIR_BASE_FILES}/etc/shells
@@ -51,6 +56,7 @@ endif
 	chmod 755 $(IDIR_BASE_FILES)/lib/mdev/init
 	chmod 600 $(IDIR_BASE_FILES)/etc/shadow
 	chmod 600 $(IDIR_BASE_FILES)/etc/network/interfaces
+	(cd $(IDIR_BASE_FILES)/etc; ln -sf ../tmp/resolv.conf .)
 	chmod 1777 ${IDIR_BASE_FILES}/tmp
 	ln -sf ../proc/mounts $(IDIR_BASE_FILES)/etc/mtab
 	rm -rf $(IDIR_BASE_FILES)/var
@@ -80,23 +86,20 @@ ifneq (${ADK_PACKAGE_CONFIG_IN_ETC},)
 	gzip -9c ${TOPDIR}/.config >$(IDIR_BASE_FILES)/etc/adkconfig.gz
 	chmod 600 $(IDIR_BASE_FILES)/etc/adkconfig.gz
 endif
-ifeq ($(ADK_TARGET_SYSTEM_RASPBERRY_PI),y)
-	echo 'export LD_LIBRARY_PATH=/opt/vc/lib' >> $(IDIR_BASE_FILES)/etc/profile
-ifneq ($(ADK_TARGET_SYSTEM_RASPBERRY_PI)$(ADK_TARGET_SYSTEM_IBM_X40)$(ADK_TARGET_SYSTEM_LEMOTE_YEELONG),)
+ifeq ($(ADK_TARGET_WITH_ROOT_RW),y)
 	echo 'export IPKGTMPDIR=/root/.ipkg' >> $(IDIR_BASE_FILES)/etc/profile
 else
-	echo 'export IPKGTMPDIR=/tmp >> $(IDIR_BASE_FILES)/etc/profile
+	echo 'export IPKGTMPDIR=/tmp' >> $(IDIR_BASE_FILES)/etc/profile
 endif
-
+ifeq ($(ADK_TARGET_SYSTEM_RASPBERRY_PI),y)
+	echo 'export LD_LIBRARY_PATH=/opt/vc/lib' >> $(IDIR_BASE_FILES)/etc/profile
 endif
 
 # simple network configuration
 ifneq (${ADK_SIMPLE_NETWORK_CONFIG},)
 	${INSTALL_DIR} ${IDIR_BASE_FILES}/etc/network
-
 	# network config local
 	echo -e "auto lo\niface lo inet loopback" > ${IDIR_BASE_FILES}/etc/network/interfaces
-
 	# network config eth0
 	# configure nic with dhcp
 ifeq (${SIMPLE_NETWORK_CONFIG_ETH0_TYPE_NIC},y)
@@ -123,12 +126,10 @@ ifeq (${SIMPLE_NETWORK_CONFIG_ETH0_TYPE_BRIDGE_IP},y)
 	echo -e "  broadcast ${SIMPLE_NETWORK_CONFIG_ETH0_BC}" >> ${IDIR_BASE_FILES}/etc/network/interfaces
 	echo -e "  bridge-ports ${SIMPLE_NETWORK_CONFIG_ETH0_BRIDGE}" >> ${IDIR_BASE_FILES}/etc/network/interfaces
 endif
-
 	# network config wlan0
 ifeq (${SIMPLE_NETWORK_CONFIG_WLAN0_TYPE_NIC},y)
 	echo -e "\nauto wlan0\niface wlan0 inet dhcp" >> ${IDIR_BASE_FILES}/etc/network/interfaces
 endif
-
 	# network config eth1
 	# configure nic with dhcp
 ifeq (${SIMPLE_NETWORK_CONFIG_ETH1_TYPE_NIC},y)
@@ -155,13 +156,11 @@ ifeq (${SIMPLE_NETWORK_CONFIG_ETH1_TYPE_BRIDGE_IP},y)
 	echo -e "  broadcast ${SIMPLE_NETWORK_CONFIG_ETH1_BC}" >> ${IDIR_BASE_FILES}/etc/network/interfaces
 	echo -e "  bridge-ports ${SIMPLE_NETWORK_CONFIG_ETH1_BRIDGE}" >> ${IDIR_BASE_FILES}/etc/network/interfaces
 endif
-
 	# newline at the end of interfaces file
 	echo -en "\n" >>  ${IDIR_BASE_FILES}/etc/network/interfaces
-
 	# resolver config
+	rm ${IDIR_BASE_FILES}/etc/resolv.conf
 	echo -e "nameserver ${SIMPLE_NETWORK_CONFIG_RESOLV}" > ${IDIR_BASE_FILES}/etc/resolv.conf
 endif
 
-
 include ${TOPDIR}/mk/pkg-bottom.mk

+ 1 - 1
package/base-files/files/inittab.shell

@@ -1 +1 @@
-::askfirst:/bin/sh
+::askfirst:-/bin/sh

+ 1 - 1
package/base-files/src/etc/ipkg.conf

@@ -1,3 +1,3 @@
-src @VENDOR@ http://@HOST@/@SYSTEM@_@ARCH@_@LIBC@/packages
+src @VENDOR@ http://@HOST@/pkg/@SYSTEM@_@ARCH@_@LIBC@@ABI@/packages
 dest root /
 dest ram /tmp

+ 0 - 4
package/base-files/src/usr/share/udhcpc/default.script

@@ -23,16 +23,12 @@ case $1 in
 			ip route add to default via $i
 		done
 	fi
-
-	touch /tmp/resolv.conf
-	ln -sf /tmp/resolv.conf $RESOLV_CONF
 	echo -n >$RESOLV_CONF
 	${domain:+echo search $domain} >>$RESOLV_CONF
 	for i in $dns; do
 		echo "adding dns $i"
 		echo "nameserver $i" >>$RESOLV_CONF
 	done
-
 	# user rules
 	[ -f /etc/udhcpc.user ] && . /etc/udhcpc.user
 ;;

+ 26 - 0
package/check/Makefile

@@ -0,0 +1,26 @@
+# This file is part of the OpenADK project. OpenADK is copyrighted
+# material, please see the LICENCE file in the top-level directory.
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=		check
+PKG_VERSION:=		0.9.12
+PKG_RELEASE:=		1
+PKG_MD5SUM:=		46fe540d1a03714c7a1967dbc6d484e7
+PKG_DESCR:=		unit testing framework for C
+PKG_SECTION:=		libs
+PKG_URL:=		http://check.sourceforge.net/
+PKG_SITES:=		${MASTER_SITE_SOURCEFORGE:=check/}
+PKG_LIBNAME:=		libcheck
+PKG_OPTS:=		dev
+
+include $(TOPDIR)/mk/package.mk
+
+$(eval $(call PKG_template,LIBCHECK,libcheck,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
+
+libcheck-install:
+	$(INSTALL_DIR) $(IDIR_CHECK)/usr/lib
+	$(CP) $(WRKINST)/usr/lib/libcheck*.so* \
+		$(IDIR_CHECK)/usr/lib
+
+include ${TOPDIR}/mk/pkg-bottom.mk

+ 2 - 0
package/dbus-python/Makefile

@@ -14,6 +14,8 @@ PKG_BUILDDEP:=		dbus dbus-glib
 PKG_URL:=		http://dbus.freedesktop.org/doc/dbus-python/
 PKG_SITES:=		http://dbus.freedesktop.org/releases/dbus-python/
 
+PKG_CFLINE_DBUS_PYTHON:=	depends on ADK_BROKEN
+
 include $(TOPDIR)/mk/package.mk
 
 $(eval $(call PKG_template,DBUS_PYTHON,dbus-python,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))

+ 1 - 1
package/ebtables/Makefile

@@ -21,7 +21,7 @@ $(eval $(call PKG_template,EBTABLES,ebtables,${PKG_VERSION}-${PKG_RELEASE},${PKG
 
 CONFIG_STYLE:=		manual
 
-post-install:
+ebtables-install:
 	${INSTALL_DIR} ${IDIR_EBTABLES}/etc
 	${INSTALL_DIR} ${IDIR_EBTABLES}/usr/sbin ${IDIR_EBTABLES}/usr/lib
 	${INSTALL_DATA} ${WRKINST}/etc/ethertypes ${IDIR_EBTABLES}/etc

+ 3 - 3
package/ebtables/patches/patch-Makefile

@@ -1,6 +1,6 @@
---- ebtables-v2.0.10-3.orig/Makefile	2011-12-04 10:46:26.000000000 +0100
-+++ ebtables-v2.0.10-3/Makefile	2011-12-11 16:35:34.619464748 +0100
-@@ -10,16 +10,16 @@ LOCKDIR:=$(shell echo $(LOCKFILE) | sed 
+--- ebtables-v2.0.10-4.orig/Makefile	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/Makefile	2014-03-23 15:46:20.000000000 +0100
+@@ -10,16 +10,16 @@ LOCKDIR:=$(shell echo $(LOCKFILE) | sed
  
  # default paths
  LIBDIR:=/usr/lib

+ 10 - 0
package/ebtables/patches/patch-extensions_ebt_among_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/extensions/ebt_among.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/extensions/ebt_among.c	2014-03-23 15:51:29.000000000 +0100
+@@ -13,7 +13,6 @@
+ #include <ctype.h>
+ #include <unistd.h>
+ #include "../include/ebtables_u.h"
+-#include <netinet/ether.h>
+ #include "../include/ethernetdb.h"
+ #include <linux/if_ether.h>
+ #include <linux/netfilter_bridge/ebt_among.h>

+ 10 - 0
package/ebtables/patches/patch-extensions_ebt_arpreply_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/extensions/ebt_arpreply.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/extensions/ebt_arpreply.c	2014-03-23 15:50:38.000000000 +0100
+@@ -12,7 +12,6 @@
+ #include <string.h>
+ #include <getopt.h>
+ #include "../include/ebtables_u.h"
+-#include <netinet/ether.h>
+ #include <linux/netfilter_bridge/ebt_arpreply.h>
+ 
+ static int mac_supplied;

+ 10 - 0
package/ebtables/patches/patch-extensions_ebt_ip6_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/extensions/ebt_ip6.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/extensions/ebt_ip6.c	2014-03-23 15:51:09.000000000 +0100
+@@ -11,6 +11,7 @@
+  *
+  */
+ 
++#include <sys/types.h>
+ #include <errno.h>
+ #include <inttypes.h>
+ #include <limits.h>

+ 10 - 0
package/ebtables/patches/patch-extensions_ebt_limit_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/extensions/ebt_limit.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/extensions/ebt_limit.c	2014-03-23 15:52:04.000000000 +0100
+@@ -8,6 +8,7 @@
+  * September, 2003
+  */
+ 
++#include <sys/types.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>

+ 10 - 0
package/ebtables/patches/patch-extensions_ebt_nat_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/extensions/ebt_nat.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/extensions/ebt_nat.c	2014-03-23 15:50:13.000000000 +0100
+@@ -11,7 +11,6 @@
+ #include <string.h>
+ #include <getopt.h>
+ #include "../include/ebtables_u.h"
+-#include <netinet/ether.h>
+ #include <linux/netfilter_bridge/ebt_nat.h>
+ 
+ static int to_source_supplied, to_dest_supplied;

+ 29 - 0
package/ebtables/patches/patch-include_ethernetdb_h

@@ -0,0 +1,29 @@
+--- ebtables-v2.0.10-4.orig/include/ethernetdb.h	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/include/ethernetdb.h	2014-03-23 15:47:35.000000000 +0100
+@@ -38,21 +38,20 @@ struct ethertypeent {
+ 
+ /* Open ethertype data base files and mark them as staying open even
+    after a later search if STAY_OPEN is non-zero.  */
+-extern void setethertypeent(int __stay_open) __THROW;
++extern void setethertypeent(int __stay_open);
+ 
+ /* Close ethertype data base files and clear `stay open' flag.  */
+-extern void endethertypeent(void) __THROW;
++extern void endethertypeent(void);
+ 
+ /* Get next entry from ethertype data base file.  Open data base if
+    necessary.  */
+-extern struct ethertypeent *getethertypeent(void) __THROW;
++extern struct ethertypeent *getethertypeent(void);
+ 
+ /* Return entry from ethertype data base for network with NAME.  */
+-extern struct ethertypeent *getethertypebyname(__const char *__name)
+-    __THROW;
++extern struct ethertypeent *getethertypebyname(__const char *__name);
+ 
+ /* Return entry from ethertype data base which number is PROTO.  */
+-extern struct ethertypeent *getethertypebynumber(int __ethertype) __THROW;
++extern struct ethertypeent *getethertypebynumber(int __ethertype);
+ 
+ 
+ #endif				/* ethernetdb.h */

+ 10 - 0
package/ebtables/patches/patch-useful_functions_c

@@ -0,0 +1,10 @@
+--- ebtables-v2.0.10-4.orig/useful_functions.c	2011-12-15 21:02:47.000000000 +0100
++++ ebtables-v2.0.10-4/useful_functions.c	2014-03-23 15:49:15.000000000 +0100
+@@ -25,7 +25,6 @@
+ #include "include/ebtables_u.h"
+ #include "include/ethernetdb.h"
+ #include <stdio.h>
+-#include <netinet/ether.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <getopt.h>

+ 7 - 5
package/ethtool/Makefile

@@ -4,12 +4,14 @@
 include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		ethtool
-PKG_VERSION:=		2.6.36
-PKG_RELEASE:=		1
-PKG_MD5SUM:=		3b2322695e9ee7bf447ebcdb85f93e83
-PKG_DESCR:=		Display or change ethernet card settings
+PKG_VERSION:=		3.13
+PKG_RELEASE:=		2
+PKG_MD5SUM:=		dcb8f345d44ee79108282e7d0bdf5013
+PKG_DESCR:=		display or change ethernet card settings
 PKG_SECTION:=		net
-PKG_SITES:=		${MASTER_SITE_SOURCEFORGE:=gkernel/}
+PKG_SITES:=		https://www.kernel.org/pub/software/network/ethtool/
+
+DISTFILES:=		${PKG_NAME}-${PKG_VERSION}.tar.xz
 
 include ${TOPDIR}/mk/package.mk
 

+ 33 - 0
package/ethtool/patches/patch-internal_h

@@ -0,0 +1,33 @@
+--- ethtool-3.13.orig/internal.h	2014-01-27 02:27:14.000000000 +0100
++++ ethtool-3.13/internal.h	2014-03-23 13:47:54.000000000 +0100
+@@ -7,6 +7,7 @@
+ #include "ethtool-config.h"
+ #endif
+ #include <stdio.h>
++#include <stdint.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #include <sys/types.h>
+@@ -17,16 +18,16 @@
+ 
+ /* ethtool.h expects these to be defined by <linux/types.h> */
+ #ifndef HAVE_BE_TYPES
+-typedef __uint16_t __be16;
+-typedef __uint32_t __be32;
++typedef uint16_t __be16;
++typedef uint32_t __be32;
+ typedef unsigned long long __be64;
+ #endif
+ 
+ typedef unsigned long long u64;
+-typedef __uint32_t u32;
+-typedef __uint16_t u16;
+-typedef __uint8_t u8;
+-typedef __int32_t s32;
++typedef uint32_t u32;
++typedef uint16_t u16;
++typedef uint8_t u8;
++typedef int32_t s32;
+ 
+ #include "ethtool-copy.h"
+ #include "net_tstamp-copy.h"

+ 11 - 13
package/eudev/Makefile

@@ -4,10 +4,10 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		eudev
-PKG_VERSION:=		1.3
+PKG_VERSION:=		1.5.3
 PKG_RELEASE:=		1
-PKG_MD5SUM:=		164df78f6f0093578a20bdd00335845f
-PKG_DESCR:=		udev device manager
+PKG_MD5SUM:=		51380938b489385cc394f4ebabc048f0
+PKG_DESCR:=		device manager (udev clone)
 PKG_SECTION:=		utils
 PKG_BUILDDEP:=		gperf-host glib
 PKG_DEPENDS:=		glib
@@ -16,20 +16,22 @@ PKG_SITES:=		http://dev.gentoo.org/~blueness/eudev/
 PKG_LIBNAME:=		libudev
 PKG_OPTS:=		dev
 
-PKG_SUBPKGS:=		UDEV LIBUDEV LIBGUDEV
-PKGSC_LIBGUDEV:=	libs
-PKGSD_LIBGUDEV:=	GUDEV library
+PKG_SUBPKGS:=		UDEV LIBUDEV
+PKGSD_UDEV:=		Dynamic device management manager
 PKGSC_LIBUDEV:=		libs
-PKGSD_LIBUDEV:=		UDEV library
-PKGSD_UDEV:=		Dynamic device management subsystem
+PKGSD_LIBUDEV:=		Dynamic device management library
+
+ifeq ($(ADK_STATIC),y)
+PKG_OPTS+=		libmix
+endif
 
 include $(TOPDIR)/mk/package.mk
 
 $(eval $(call PKG_template,UDEV,udev,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
 $(eval $(call PKG_template,LIBUDEV,libudev,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
-$(eval $(call PKG_template,LIBGUDEV,libgudev,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
 
 CONFIGURE_ARGS+=	--disable-manpages \
+			--datadir=${STAGING_TARGET_PREFIX}/usr/lib \
 			--disable-gtk-doc
 
 udev-install:
@@ -43,8 +45,4 @@ libudev-install:
 	${INSTALL_DIR} ${IDIR_LIBUDEV}/usr/lib
 	$(CP) $(WRKINST)/usr/lib/libudev.so* $(IDIR_LIBUDEV)/usr/lib
 
-libgudev-install:
-	${INSTALL_DIR} ${IDIR_LIBGUDEV}/usr/lib
-	$(CP) $(WRKINST)/usr/lib/libgudev*.so* $(IDIR_LIBGUDEV)/usr/lib
-
 include ${TOPDIR}/mk/pkg-bottom.mk

+ 2 - 2
package/feh/Makefile

@@ -4,9 +4,9 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		feh
-PKG_VERSION:=		1.16.1
+PKG_VERSION:=		2.10
 PKG_RELEASE:=		1
-PKG_MD5SUM:=		1bb080c7b0021db50884a52161251990
+PKG_MD5SUM:=		6714dedeff1db5c3593c4a27b0d9cf50
 PKG_DESCR:=		image viewer
 PKG_SECTION:=		multimedia
 PKG_BUILDDEP:=		imlib2 giblib libXt

+ 2 - 2
package/fetchmail/Makefile

@@ -4,9 +4,9 @@
 include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		fetchmail
-PKG_VERSION:=		6.3.9
+PKG_VERSION:=		6.3.26
 PKG_RELEASE:=		1
-PKG_MD5SUM:=		72c20ad2b9629f1a109668b05a84d823
+PKG_MD5SUM:=		d9ae3d939205a3c06a21ea79b8f14793
 PKG_DESCR:=		fetch mail from a POP or IMAP server
 PKG_SECTION:=		mail
 PKG_URL:=		http://fetchmail.berlios.de/

+ 17 - 8
package/findutils/Makefile

@@ -5,29 +5,38 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		findutils
 PKG_VERSION:=		4.4.2
-PKG_RELEASE:=		2
+PKG_RELEASE:=		4
 PKG_MD5SUM:=		351cc4adb07d54877fa15f75fb77d39f
 PKG_DESCR:=		GNU utilities for finding files
 PKG_SECTION:=		utils
 PKG_DEPENDS:=		libpthread
+PKG_BUILDDEP:=		autotool
 PKG_URL:=		http://www.gnu.org/software/findutils/
 PKG_SITES:=		http://ftp.gnu.org/pub/gnu/findutils/
 
-PKG_SUBPKGS:=		FINDUTILS LOCATE
-PKGSD_LOCATE:=		Locate utility
+PKG_SUBPKGS:=		FIND XARGS LOCATE
+PKGSD_LOCATE:=		locate utility
+PKGSD_XARGS:=		xargs utility
 
 include $(TOPDIR)/mk/package.mk
 
-$(eval $(call PKG_template,FINDUTILS,findutils,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+$(eval $(call PKG_template,FIND,find,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+$(eval $(call PKG_template,XARGS,xargs,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_XARGS},${PKG_SECTION}))
 $(eval $(call PKG_template,LOCATE,locate,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LOCATE},${PKG_SECTION}))
 
+AUTOTOOL_STYLE:=	autoreconf
 CONFIGURE_ENV+=		gl_cv_func_wcwidth_works=yes \
 			ac_cv_func_working_mktime=yes
 
-findutils-install:
-	$(INSTALL_DIR) $(IDIR_FINDUTILS)/usr/bin
-	$(INSTALL_BIN) $(WRKINST)/usr/bin/{find,oldfind,xargs} \
-		 $(IDIR_FINDUTILS)/usr/bin
+find-install:
+	$(INSTALL_DIR) $(IDIR_FIND)/usr/bin
+	$(INSTALL_BIN) $(WRKINST)/usr/bin/find \
+		 $(IDIR_FIND)/usr/bin
+
+xargs-install:
+	$(INSTALL_DIR) $(IDIR_XARGS)/usr/bin
+	$(INSTALL_BIN) $(WRKINST)/usr/bin/xargs \
+		 $(IDIR_XARGS)/usr/bin
 
 locate-install:
 	${INSTALL_DIR} ${IDIR_LOCATE}/usr/{bin,libexec}

+ 11 - 0
package/findutils/patches/patch-configure_ac

@@ -0,0 +1,11 @@
+--- findutils-4.4.2.orig/configure.ac	2009-05-16 17:27:39.000000000 +0200
++++ findutils-4.4.2/configure.ac	2014-03-23 19:39:22.000000000 +0100
+@@ -77,8 +77,6 @@ AC_PROG_CPP
+ dnl for gnulib
+ gl_EARLY
+ 
+-AM_C_PROTOTYPES
+-
+ AC_PROG_INSTALL
+ AC_PROG_RANLIB
+ dnl AC_PROG_LIBTOOL

+ 15 - 0
package/findutils/patches/patch-gnulib_lib_freadahead_c

@@ -0,0 +1,15 @@
+--- findutils-4.4.2.orig/gnulib/lib/freadahead.c	2009-05-10 23:23:57.000000000 +0200
++++ findutils-4.4.2/gnulib/lib/freadahead.c	2014-03-23 16:27:43.000000000 +0100
+@@ -19,6 +19,7 @@
+ /* Specification.  */
+ #include "freadahead.h"
+ 
++#ifndef HAVE___FREADAHEAD
+ size_t
+ freadahead (FILE *fp)
+ {
+@@ -64,3 +65,4 @@ freadahead (FILE *fp)
+  #error "Please port gnulib freadahead.c to your platform! Look at the definition of fflush, fread on your system, then report this to bug-gnulib."
+ #endif
+ }
++#endif

+ 24 - 0
package/findutils/patches/patch-gnulib_lib_freadahead_h

@@ -0,0 +1,24 @@
+--- findutils-4.4.2.orig/gnulib/lib/freadahead.h	2009-05-10 23:23:57.000000000 +0200
++++ findutils-4.4.2/gnulib/lib/freadahead.h	2014-03-23 16:27:43.000000000 +0100
+@@ -29,8 +29,21 @@ extern "C" {
+ 
+    STREAM must not be wide-character oriented.  */
+ 
++#if HAVE___FREADAHEAD || (defined(__linux__) && !defined(__GLIBC__) && !defined(__UCLIBC__)) /* musl libc */
++
++#ifndef HAVE___FREADAHEAD
++#define HAVE___FREADAHEAD 1
++#endif
++
++# include <stdio_ext.h>
++# define freadahead(stream) __freadahead (stream)
++
++#else
++
+ extern size_t freadahead (FILE *stream);
+ 
++#endif
++
+ #ifdef __cplusplus
+ }
+ #endif

+ 18 - 0
package/findutils/patches/patch-gnulib_lib_fseeko_c

@@ -0,0 +1,18 @@
+--- findutils-4.4.2.orig/gnulib/lib/fseeko.c	2009-05-10 23:25:10.000000000 +0200
++++ findutils-4.4.2/gnulib/lib/fseeko.c	2014-03-23 16:35:34.000000000 +0100
+@@ -94,8 +94,14 @@ rpl_fseeko (FILE *fp, off_t offset, int
+   if ((fp->_Mode & _MWRITE ? fp->_Next == fp->_Buf : fp->_Next == fp->_Rend)
+       && fp->_Rback == fp->_Back + sizeof (fp->_Back)
+       && fp->_Rsave == NULL)
++#elif FUNC_FFLUSH_STDIN < 0 && 200809 <= _POSIX_VERSION
++  /* Cross-compiling to some other system advertising conformance to
++     POSIX.1-2008 or later.  Assume fseeko and fflush work as advertised.
++     If this assumption is incorrect, please report the bug to
++     bug-gnulib.  */
++  if (0)
+ #else
+-  #error "Please port gnulib fseeko.c to your platform! Look at the code in fpurge.c, then report this to bug-gnulib."
++  #error "Please port gnulib fseeko.c to your platform! Look at the code in fseeko.c, then report this to bug-gnulib."
+ #endif
+     {
+       off_t pos = lseek (fileno (fp), offset, whence);

+ 25 - 0
package/findutils/patches/patch-gnulib_m4_fflush_m4

@@ -0,0 +1,25 @@
+--- findutils-4.4.2.orig/gnulib/m4/fflush.m4	2009-05-10 23:23:57.000000000 +0200
++++ findutils-4.4.2/gnulib/m4/fflush.m4	2014-03-23 18:40:09.000000000 +0100
+@@ -32,12 +32,18 @@ AC_DEFUN([gl_FUNC_FFLUSH],
+ 	   return 4;
+ 	 return !(lseek (fd, 0, SEEK_CUR) == 5);
+        ]])], [gl_cv_func_fflush_stdin=yes], [gl_cv_func_fflush_stdin=no],
+-     [dnl Pessimistically assume fflush is broken.  This is wrong for
+-      dnl at least glibc and cygwin; but lib/fflush.c takes this into account.
+-      gl_cv_func_fflush_stdin=no])
++	[gl_cv_func_fflush_stdin=cross])
+      rm conftest.txt
+     ])
+-  if test $gl_cv_func_fflush_stdin = no; then
++  case $gl_cv_func_fflush_stdin in
++    yes) gl_func_fflush_stdin=1 ;;
++    no)  gl_func_fflush_stdin=0 ;;
++    *)   gl_func_fflush_stdin='(-1)' ;;
++  esac
++  AC_DEFINE_UNQUOTED([FUNC_FFLUSH_STDIN], [$gl_func_fflush_stdin],
++    [Define to 1 if fflush is known to work on stdin as per POSIX.1-2008,
++     0 if fflush is known to not work, -1 if unknown.])
++  if test $gl_cv_func_fflush_stdin != yes; then
+     gl_REPLACE_FFLUSH
+   fi
+ ])

+ 3 - 3
package/gkrellm/Makefile

@@ -4,10 +4,10 @@
 include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		gkrellm
-PKG_VERSION:=		2.3.4
+PKG_VERSION:=		2.3.5
 PKG_RELEASE:=		1
-PKG_MD5SUM:=		600f4daa395112ed19a3633deb0829ff
-PKG_DESCR:=		The GNU Krell Monitors Server
+PKG_MD5SUM:=		05d00fa8d6376038b0c7e967583c0b8d
+PKG_DESCR:=		GNU krell monitors server
 PKG_SECTION:=		net/misc
 PKG_DEPENDS:=		glib libpthread
 PKG_BUILDDEP:=		glib

+ 0 - 30
package/gkrellm/patches/patch-server_Makefile

@@ -1,30 +0,0 @@
---- gkrellm-2.3.4.orig/server/Makefile	2008-10-03 23:52:48.000000000 +0200
-+++ gkrellm-2.3.4/server/Makefile	2011-05-17 11:34:14.926610183 +0200
-@@ -26,7 +26,7 @@ SMANDIR ?= $(INSTALLROOT)/share/man/man1
- MANMODE ?= 644
- MANDIRMODE ?= 755
- INSTALL ?= install
--LINK_FLAGS ?= -Wl,-E
-+LINK_FLAGS ?= -Wl,-E $(LDFLAGS)
- EXTRAOBJS =
- 
- SHARED_PATH = ../shared
-@@ -109,15 +109,15 @@ endif
- 
- override CC += -Wall $(FLAGS)
- 
--OS_NAME=$(shell uname -s)
--OS_RELEASE=$(shell uname -r)
-+OS_NAME=Linux
-+OS_RELEASE=2.6
- 
- OBJS = main.o monitor.o mail.o plugins.o glib.o utils.o sysdeps-unix.o log.o
- 
- all:	gkrellmd
- 
- gkrellmd: $(OBJS) $(EXTRAOBJS)
--	$(CC) $(OBJS) $(EXTRAOBJS) -o gkrellmd $(LIBS) $(LINK_FLAGS)
-+	$(CC) $(OBJS) $(EXTRAOBJS) -o gkrellmd $(LINK_FLAGS) $(LIBS)
- 
- static: $(OBJS) $(EXTRAOBJS)
- 	$(CC) $(OBJS) $(EXTRAOBJS) -o gkrellmd.static -static \

+ 24 - 0
package/gkrellm/patches/patch-server_main_c

@@ -0,0 +1,24 @@
+--- gkrellm-2.3.5.orig/server/main.c	2010-10-02 18:13:29.000000000 +0200
++++ gkrellm-2.3.5/server/main.c	2014-03-23 16:06:59.000000000 +0100
+@@ -39,21 +39,6 @@
+ 	#include <syslog.h>
+ #endif // !WIN32
+ 
+-// win32 defines addrinfo but only supports getaddrinfo call on winxp or newer
+-#if !defined(HAVE_GETADDRINFO) && !defined(WIN32)
+-struct addrinfo
+-	{
+-	int		ai_flags;		/* AI_PASSIVE, AI_CANONNAME, AI_NUMERICHOST */
+-	int		ai_family;		/* PF_xxx */
+-	int		ai_socktype;	/* SOCK_xxx */
+-	int		ai_protocol;	/* 0 or IPPROTO_xxx for IPv4 and IPv6 */
+-	size_t	ai_addrlen;		/* length of ai_addr */
+-	char	*ai_canonname;	/* canonical name for hostname */
+-	struct	sockaddr *ai_addr;	/* binary address */
+-	struct	addrinfo *ai_next;	/* next structure in linked list */
+-	};
+-#endif // !HAVE_GETADDRINFO
+-
+ #if !defined(IPV6_V6ONLY) && defined(IPV6_BINDV6ONLY)
+ #define	IPV6_V6ONLY	IPV6_BINDV6ONLY
+ #endif

+ 10 - 0
package/gkrellm/patches/patch-server_sysdeps-unix_c

@@ -0,0 +1,10 @@
+--- gkrellm-2.3.5.orig/server/sysdeps-unix.c	2010-09-14 18:34:34.000000000 +0200
++++ gkrellm-2.3.5/server/sysdeps-unix.c	2014-03-23 16:13:57.000000000 +0100
+@@ -145,6 +145,7 @@ gkrellm_sensors_linux_name_fix(gchar *id
+ #endif
+ 	}
+ 
++#define HAVE_GETADDRINFO 1
+ #ifdef SENSORS_COMMON
+ gint
+ gkrellm_connect_to(gchar *server, gint server_port)

+ 4 - 4
package/glib/Makefile

@@ -5,13 +5,14 @@ include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		glib
 PKG_VERSION:=		2.38.2
-PKG_RELEASE:=		2
+PKG_RELEASE:=		3
 PKG_EXTRAVER:=		2.38
 PKG_MD5SUM:=		26d1d08e478fc48c181ca8be44f5b69f
 PKG_DESCR:=		low-level core library that forms the basis of GTK+
 PKG_SECTION:=		libs
 PKG_DEPENDS:=		libpthread
-PKG_BUILDDEP:=		libffi gettext-tiny libiconv-tiny glib-host zlib libelf dbus
+PKG_BUILDDEP:=		glib-host zlib libelf dbus
+HOST_BUILDDEP:=		libffi-host gettext-tiny-host libiconv-tiny-host
 PKG_URL:=		http://www.gtk.org/
 PKG_SITES:=		http://ftp.gnome.org/pub/gnome/sources/glib/${PKG_EXTRAVER}/
 PKG_NOPARALLEL:=	1
@@ -29,9 +30,7 @@ include ${TOPDIR}/mk/package.mk
 $(eval $(call HOST_template,GLIB,glib,${PKG_VERSION}-${PKG_RELEASE}))
 $(eval $(call PKG_template,GLIB,glib,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
 
-HOST_STYLE:=		auto
 TARGET_CPPFLAGS+=	-D_GNU_SOURCE
-TARGET_CFLAGS:=         $(filter-out -flto,$(TARGET_CFLAGS))
 CONFIGURE_ARGS+=	--disable-mem-pools \
 			--disable-rebuilds \
 			--disable-fam \
@@ -43,6 +42,7 @@ CONFIGURE_ENV+=		glib_cv_long_long_format=ll \
 			ac_cv_func_posix_getpwuid_r=yes \
 			ac_cv_func_posix_getgrgid_r=yes
 
+HOST_STYLE:=		auto
 HOST_CONFIGURE_ARGS+=	--disable-fam \
 			--enable-static \
 			--disable-compile-warnings

+ 1 - 1
package/gpsd/Makefile

@@ -10,7 +10,7 @@ PKG_MD5SUM:=		fc5b03aae38b9b5b6880b31924d0ace3
 PKG_DESCR:=		An interface daemon for GPS receivers
 PKG_SECTION:=		misc
 PKG_DEPENDS:=		libpthread
-PKG_BUILDDEP:=		ncurses scons-host bzip2-host python2-host
+PKG_BUILDDEP:=		scons-host ncurses
 PKG_URL:=		http://catb.org/gpsd/
 PKG_SITES:=		http://download-mirror.savannah.gnu.org/releases/gpsd/
 

+ 1 - 1
package/ipcad/Makefile

@@ -5,7 +5,7 @@ include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		ipcad
 PKG_VERSION:=		3.7.3
-PKG_RELEASE:=		1
+PKG_RELEASE:=		2
 PKG_MD5SUM:=		125605249958894148ec26d3c88189f5
 PKG_DESCR:=		IP Cisco Accounting Daemon
 PKG_SECTION:=		net

+ 169 - 0
package/ipcad/patches/patch-Makefile

@@ -0,0 +1,169 @@
+--- ipcad-3.7.3.orig/Makefile	2007-04-22 10:08:45.000000000 +0200
++++ ipcad-3.7.3/Makefile	2014-03-23 17:59:56.000000000 +0100
+@@ -1,4 +1,163 @@
+-all: bootstrap
+ 
+-bootstrap:
+-	./configure && make
++prefix= /usr
++exec_prefix= ${prefix}
++bindir= /usr/bin
++sysconfdir= /etc
++datadir= /usr/share
++
++CC= /home/wbx/hudson/toolchain_x86_64-linux-gnu/usr/bin/arm-openadk-linux-muslgnueabihf-gcc
++LDFLAGS= -L/home/wbx/hudson/target_arm_musl_eabihf/lib -L/home/wbx/hudson/target_arm_musl_eabihf/usr/lib -Wl,-O1 -Wl,-rpath -Wl,/usr/lib -Wl,-rpath-link -Wl,/home/wbx/hudson/target_arm_musl_eabihf/usr/lib -Wl,-z,relro,-z,now
++LIBS= -lpcap 
++CFLAGS= -march=armv6 -mtune=arm1176jzf-s -mfpu=vfp -mfloat-abi=hard -fwrapv -fno-ident -fhonour-copts -fomit-frame-pointer -Os -pipe -fno-unwind-tables -fno-asynchronous-unwind-tables -g3 -DHAVE_CONFIG_H -W -Wall
++CPPFLAGS=-DIPCAD_VERSION=\"3.7.3\"
++CPPFLAGS+=-DCONFIG_FILE=\"${sysconfdir}/ipcad.conf\"
++CPPFLAGS+=-DHAVE_CONFIG_H -D_REENTRANT -D_THREAD_SAFE
++CPPFLAGS+=-DPSRC_pcap -DIFST_linux
++
++YACC=bison -y
++LEX=flex
++INSTALL=/usr/bin/install -c
++
++MANROOT=/usr/share/man/man
++MAN8=${MANROOT}8
++MAN5=${MANROOT}5
++
++NROFF= groff -Tascii -mandoc
++
++PACKAGE=ipcad
++TARGETS=ipcad
++VERSION=3.7.3
++
++IPCAD_OBJS= main.o process.o pps.o disp.o storage.o usage.o cfgy.o cfglex.o cfgread.o cfgvar.o dump.o import.o nflow.o cshelly.o cslex.o csparse.o service.o rw.o servers.o opt.o pidfile.o sf_lite.o
++IPCAD_OBJS+= ifst_linux.o		# Interface statistics
++IPCAD_OBJS+= ifs_list.o			# Interface statistics
++IPCAD_OBJS+= loop-pcap.o		# Method of capturing
++IPCAD_OBJS+= loop-file.o		# Method of capturing
++IPCAD_OBJS+= loop-divert.o		# Method of capturing
++IPCAD_OBJS+= loop-dynamic.o		# Method of capturing
++IPCAD_OBJS+= loop-ulog.o loop-ipq.o	# Methods of capturing
++IPCAD_OBJS+= psrc.o psrc-pcap.o	# Initialize capturers
++IPCAD_OBJS+= psrc-ipq.o psrc-ulog.o	# Initialize capturers
++IPCAD_OBJS+= psrc-file.o		# Initialize capturers
++IPCAD_OBJS+= psrc-dynamic.o		# Initialize capturers
++IPCAD_OBJS+= psrc-divert.o		# Initialize capturers
++IPCAD_OBJS+= wrap_oclose.o		# Special file descriptors cache
++IPCAD_OBJS+= genhash.o			# General hashing
++
++all: ${TARGETS} man
++
++ipcad: ${IPCAD_OBJS}
++	${CC} ${CFLAGS} -o $@ ${IPCAD_OBJS} ${LDFLAGS} ${LIBS}
++
++.SUFFIXES:
++.SUFFIXES: .o .c .0 .8 .5
++
++.c.o:
++	${CC} ${CPPFLAGS} ${CFLAGS} -o $@ -c $<
++
++.8.0:
++	${NROFF} $< > $@
++
++.5.0:
++	${NROFF} $< > $@
++
++cfgy.h cfgy.c: cfg.y
++	${YACC} -p ipcacfg -d cfg.y
++	@mv y.tab.c cfgy.c
++	@mv y.tab.h cfgy.h
++
++cshelly.h cshelly.c: cshell.y
++	${YACC} -p CS -d cshell.y
++	@mv y.tab.c cshelly.c
++	@mv y.tab.h cshelly.h
++
++cslex.c: cslex.l
++	${LEX} -s -p -Cem -ocslex.c -PCS cslex.l
++
++cfglex.c: cfglex.l
++	${LEX} -s -p -Cem -ocfglex.c -Pipcacfg cfglex.l
++
++
++man: ipcad.8 ipcad.conf.5
++
++distdir = $(PACKAGE)-$(VERSION)
++distdir:
++	rm -rf $(distdir)
++	mkdir $(distdir)
++	cp *.c *.h $(distdir)
++	cp ipcad.8 ipcad.conf.5 $(distdir)
++	cp *.y *.l $(distdir)
++	cp *.in configure install-sh $(distdir)
++	cp ipcad.conf.default $(distdir)
++	cp ipcad.conf.simple $(distdir)
++	cp ipcad.spec.in $(distdir)
++	cp Makefile.in Makefile $(distdir)
++	cp ChangeLog INSTALL README TODO BUGS AUTHORS COPYING FAQ $(distdir)
++	cd $(distdir) && make distclean
++
++dist: distdir
++	tar chof - $(distdir) | GZIP="--best" gzip -c > $(distdir).tar.gz
++	rm -rf $(distdir)
++
++clean:
++	rm -f *.o ${TARGETS} *.core 1
++	rm -f *.0
++
++distclean: clean
++	rm -f config.h
++	rm -f config.cache config.log config.status
++	rm -f Makefile
++	rm -f $(distdir).tar.gz
++	rm -f ipcad.spec
++	(echo "all: bootstrap"; echo; echo "bootstrap:"; \
++		echo "	./configure && make") > Makefile
++
++maintainer-clean: distclean
++	@echo "This command is intended for maintainers to use; it"
++	@echo "deletes files that may need special tools to rebuild."
++	rm -f Makefile
++	rm -f *.tab.* cfgy.? *lex.c
++	rm -f config.h.in configure
++
++install: all install-bin install-conf
++
++install-bin:
++	@${INSTALL} -d $(DESTDIR)${bindir}
++	${INSTALL} ipcad $(DESTDIR)${bindir}
++
++install-man: man
++	${INSTALL} -m 444 ipcad.8 $(DESTDIR)${MAN8}/ipcad.8
++	${INSTALL} -m 444 ipcad.conf.5 $(DESTDIR)${MAN5}/ipcad.conf.5
++
++install-conf:
++	@${INSTALL} -d $(DESTDIR)${sysconfdir}
++	${INSTALL} -m 644 ipcad.conf.simple $(DESTDIR)${sysconfdir}/ipcad.conf.simple
++	-@diff ${sysconfdir}/ipcad.conf					\
++	      ${sysconfdir}/ipcad.conf.default >/dev/null 2>&1;		\
++	if [ "$$?" -eq 0 ] || [ ! -f ${sysconfdir}/ipcad.conf ]; then	\
++	echo ${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf.default; \
++	${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf.default; \
++	echo ${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf;	\
++	${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf;	\
++	echo "**********************************************";		\
++	echo "* Please customize ${sysconfdir}/ipcad.conf *";		\
++	echo "**********************************************";		\
++	else								\
++	echo ${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf.default; \
++	${INSTALL} -m 644 ipcad.conf.default $(DESTDIR)${sysconfdir}/ipcad.conf.default; \
++	echo "*********************************************";		\
++	echo "* Updated ${sysconfdir}/ipcad.conf.default *";		\
++	echo "*********************************************";		\
++	fi
++	@echo ""
++	@echo "Now you might want to 'make install-man'"
++	@echo ""
++
++
++uninstall:
++	rm -f ${bindir}/ipcad
++	rm -f ${sysconfdir}/ipcad.conf.default
++	rm -f ${sysconfdir}/ipcad.conf.simple
++	rm -f ${MAN8}/ipcad.8
++	rm -f ${MAN5}/ipcad.conf.5
++

+ 10 - 1
package/ipcad/patches/patch-Makefile_in

@@ -1,5 +1,5 @@
 --- ipcad-3.7.3.orig/Makefile.in	2007-04-22 10:08:45.000000000 +0200
-+++ ipcad-3.7.3/Makefile.in	2011-01-11 17:16:15.000000000 +0100
++++ ipcad-3.7.3/Makefile.in	2014-03-23 17:58:49.000000000 +0100
 @@ -6,10 +6,10 @@ sysconfdir= @sysconfdir@
  datadir= @datadir@
  
@@ -15,3 +15,12 @@
  CPPFLAGS+=-DCONFIG_FILE=\"${sysconfdir}/ipcad.conf\"
  CPPFLAGS+=@DEFS@ -D_REENTRANT -D_THREAD_SAFE
  CPPFLAGS+=-DPSRC_@PSRC@ -DIFST_@IFST@
+@@ -28,7 +28,7 @@ PACKAGE=ipcad
+ TARGETS=ipcad
+ VERSION=@IPCAD_VERSION@
+ 
+-IPCAD_OBJS= main.o process.o pps.o disp.o storage.o usage.o cfgy.o cfglex.o cfgread.o cfgvar.o rsh.o rshp.o dump.o import.o nflow.o cshelly.o cslex.o csparse.o service.o rw.o servers.o opt.o pidfile.o sf_lite.o
++IPCAD_OBJS= main.o process.o pps.o disp.o storage.o usage.o cfgy.o cfglex.o cfgread.o cfgvar.o dump.o import.o nflow.o cshelly.o cslex.o csparse.o service.o rw.o servers.o opt.o pidfile.o sf_lite.o
+ IPCAD_OBJS+= ifst_@IFST@.o		# Interface statistics
+ IPCAD_OBJS+= ifs_list.o			# Interface statistics
+ IPCAD_OBJS+= loop-@PSRC@.o		# Method of capturing

+ 60 - 0
package/ipcad/patches/patch-cfg_y

@@ -0,0 +1,60 @@
+--- ipcad-3.7.3.orig/cfg.y	2007-04-22 10:08:45.000000000 +0200
++++ ipcad-3.7.3/cfg.y	2014-03-23 18:03:07.000000000 +0100
+@@ -3,7 +3,6 @@
+ #include "headers.h"
+ #include "cfgvar.h"
+ #include "servers.h"
+-#include "rsh.h"
+ #include "opt.h"
+ #include "storage.h"
+ 
+@@ -214,49 +213,6 @@ block:
+ 	| CAPTURE_PORTS DENY {
+ 		conf->capture_ports = 0;
+ 	}
+-	| RSH ALLOW at_ip {
+-		if(add_server(rsh_server, "RSH Server", &($3), 514))
+-			return yyerror("Failed to install RSH server");
+-		fprintf(stderr, "Configured RSH Server listening at %s\n",
+-			inet_ntoa($3));
+-	}
+-	| RSH DENY at_ip {
+-		fprintf(stderr, "Warning: Option at line %d has no effect\n",
+-			ipcacfglineno);
+-	}
+-	| RSH TIMEOUT EQ TOK_STRING {
+-		int to_ms;
+-		to_ms = atoi($4);
+-		free($4);
+-		if(to_ms < 0)
+-			to_ms = -1;	/* INFTIM */
+-		else
+-			to_ms = to_ms * 1000;
+-		rsh_rw_timeout = to_ms;
+-	}
+-	| RSH TOK_STRING privlevel {
+-		cfg_add_rsh_host("", $2, $3);
+-		free($2);
+-	}
+-	| RSH AT TOK_STRING privlevel {
+-		cfg_add_rsh_host("", $3, $4);
+-		free($3);
+-	}
+-	| RSH TOK_STRING AT TOK_STRING privlevel {
+-		cfg_add_rsh_host($2, $4, $5);
+-		free($2); free($4);
+-	}
+-	| RSH TTL EQ TOK_STRING {
+-		conf->rsh_ttl = atoi($4);
+-		free($4);
+-	}
+-	| TTL EQ TOK_STRING {
+-		fprintf(stderr, "WARNING: \"ttl = %s;\" at line %d: "
+-			"Obsolete syntax. Please use \"rsh ttl = %s;\"\n",
+-			$3, ipcacfglineno, $3);
+-		conf->rsh_ttl = atoi($3);
+-		free($3);
+-	}
+ 	| NetFlow
+ 	| CHROOT EQ TOK_STRING {
+ 		if(conf->chroot_to)

+ 2 - 0
package/iptables-snmp/Makefile

@@ -13,6 +13,8 @@ PKG_BUILDDEP:=		net-snmp
 PKG_URL:=		http://www.nobiscuit.com/iptables-snmp/
 PKG_SITES:=		http://www.nobiscuit.com/iptables-snmp/
 
+PKG_LIBC_DEPENDS:=	uclibc glibc
+
 include $(TOPDIR)/mk/package.mk
 
 $(eval $(call PKG_template,IPTABLES_SNMP,iptables-snmp,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))

+ 8 - 3
package/kbd/Makefile

@@ -4,17 +4,22 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		kbd
-PKG_VERSION:=		1.15.3
+PKG_VERSION:=		2.0.1
 PKG_RELEASE:=		1
-PKG_MD5SUM:=		8143e179a0f3c25646ce5085e8777200
+PKG_MD5SUM:=		cc0ee9f2537d8636cae85a8c6541ed2e
 PKG_DESCR:=		keyboard utility
 PKG_SECTION:=		utils
-PKG_SITES:=		ftp://ftp.altlinux.org/pub/people/legion/kbd/
+PKG_DEPENDS:=		libcheck
+PKG_BUILDDEP:=		check
+PKG_URL:=		http://kbd-project.org/
+PKG_SITES:=		http://kbd-project.org/download/
 
 include $(TOPDIR)/mk/package.mk
 
 $(eval $(call PKG_template,KBD,kbd,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
 
+CONFIGURE_ARGS+=	--disable-vlock
+
 kbd-install:
 	$(INSTALL_DIR) $(IDIR_KBD)/usr/bin
 	$(INSTALL_BIN) $(WRKINST)/usr/bin/loadkeys \

+ 46 - 0
package/kbd/patches/patch-src_kbdinfo_c

@@ -0,0 +1,46 @@
+--- kbd-2.0.1.orig/src/kbdinfo.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/kbdinfo.c	2014-03-24 13:24:51.000000000 +0100
+@@ -1,6 +1,6 @@
+ #include <stdio.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <unistd.h>
+ #include <sys/ioctl.h>
+ #include <linux/kd.h>
+@@ -75,7 +75,7 @@ main(int argc, char **argv) {
+ 
+ 	if (!strcasecmp("GETMODE", action)) {
+ 		if (ioctl(fd, KDGETMODE, &mode) == -1)
+-			error(EXIT_FAILURE, errno, "ioctl");
++			err(EXIT_FAILURE, "ioctl");
+ 
+ 		switch (mode) {
+ 			case KD_TEXT:		rc = answer("text");		break;
+@@ -84,7 +84,7 @@ main(int argc, char **argv) {
+ 
+ 	} else if (!strcasecmp("GKBMODE", action)) {
+ 		if (ioctl(fd, KDGKBMODE, &mode) == -1)
+-			error(EXIT_FAILURE, errno, "ioctl");
++			err(EXIT_FAILURE, "ioctl");
+ 
+ 		switch (mode) {
+ 			case K_RAW:		rc = answer("raw");		break;
+@@ -95,7 +95,7 @@ main(int argc, char **argv) {
+ 
+ 	} else if (!strcasecmp("GKBMETA", action)) {
+ 		if (ioctl(fd, KDGKBMETA, &mode) == -1)
+-			error(EXIT_FAILURE, errno, "ioctl");
++			err(EXIT_FAILURE, "ioctl");
+ 
+ 		switch (mode) {
+ 			case K_METABIT:		rc = answer("metabit");		break;
+@@ -104,7 +104,7 @@ main(int argc, char **argv) {
+ 
+ 	} else if (!strcasecmp("GKBLED", action)) {
+ 		if (ioctl(fd, KDGKBLED, &flags) == -1)
+-			error(EXIT_FAILURE, errno, "ioctl");
++			err(EXIT_FAILURE, "ioctl");
+ 
+ 		mode = (flags & 0x7);
+ 

+ 10 - 0
package/kbd/patches/patch-src_kbdrate_c

@@ -0,0 +1,10 @@
+--- kbd-2.0.1.orig/src/kbdrate.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/kbdrate.c	2014-03-24 12:40:34.000000000 +0100
+@@ -68,6 +68,7 @@ beats rebuilding the kernel!
+ 
+ */
+ 
++#include <fcntl.h>
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <stdlib.h>

+ 11 - 0
package/kbd/patches/patch-src_libkeymap_dump_c

@@ -0,0 +1,11 @@
+--- kbd-2.0.1.orig/src/libkeymap/dump.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/libkeymap/dump.c	2014-03-24 12:18:50.000000000 +0100
+@@ -9,6 +9,8 @@
+  * This file is covered by the GNU General Public License,
+  * which should be included with kbd as the file COPYING.
+  */
++
++#include <sys/types.h>
+ #include <stdio.h>
+ #include <string.h>
+ #include <ctype.h>

+ 7 - 0
package/kbd/patches/patch-src_libkeymap_kmap_c

@@ -0,0 +1,7 @@
+--- kbd-2.0.1.orig/src/libkeymap/kmap.c	2013-10-07 16:13:31.000000000 +0200
++++ kbd-2.0.1/src/libkeymap/kmap.c	2014-03-24 12:17:45.000000000 +0100
+@@ -1,3 +1,4 @@
++#include <sys/types.h>
+ #include <stdlib.h>
+ #include <string.h>
+ 

+ 11 - 0
package/kbd/patches/patch-src_libkeymap_summary_c

@@ -0,0 +1,11 @@
+--- kbd-2.0.1.orig/src/libkeymap/summary.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/libkeymap/summary.c	2014-03-24 12:23:53.000000000 +0100
+@@ -6,6 +6,8 @@
+  * This file is covered by the GNU General Public License,
+  * which should be included with kbd as the file COPYING.
+  */
++
++#include <sys/types.h>
+ #include <string.h>
+ #include <errno.h>
+ #include <sys/ioctl.h>

+ 8 - 0
package/kbd/patches/patch-src_openvt_c

@@ -0,0 +1,8 @@
+--- kbd-2.0.1.orig/src/openvt.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/openvt.c	2014-03-24 12:48:07.000000000 +0100
+@@ -1,3 +1,5 @@
++#include <fcntl.h>
++#include <limits.h>
+ #include <stdio.h>
+ #include <stdarg.h>
+ #include <unistd.h>

+ 70 - 0
package/kbd/patches/patch-src_setvtrgb_c

@@ -0,0 +1,70 @@
+--- kbd-2.0.1.orig/src/setvtrgb.c	2013-08-27 22:45:33.000000000 +0200
++++ kbd-2.0.1/src/setvtrgb.c	2014-03-24 13:10:47.000000000 +0100
+@@ -5,7 +5,7 @@
+ #include <sys/ioctl.h>
+ #include <linux/kd.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include "kbd.h"
+ #include "getfd.h"
+ #include "nls.h"
+@@ -60,7 +60,7 @@ set_colormap(unsigned char *colormap)
+ 
+ 	/* Apply the color map to the tty via ioctl */
+ 	if (ioctl(fd, PIO_CMAP, colormap) == -1)
+-		error(EXIT_FAILURE, errno, "ioctl");
++		err(EXIT_FAILURE, "ioctl");
+ 
+ 	close(fd);
+ }
+@@ -72,7 +72,7 @@ parse_file(FILE *fd, const char *filenam
+ 	unsigned int rows, cols, val;
+ 
+ 	if ((cmap = calloc(3 * 16, sizeof(unsigned char))) == NULL)
+-		error(EXIT_FAILURE, errno, "calloc");
++		err(EXIT_FAILURE, "calloc");
+ 
+ 	for (rows = 0; rows < 3; rows++) {
+ 		cols = 0;
+@@ -80,26 +80,26 @@ parse_file(FILE *fd, const char *filenam
+ 		while (cols < 16) {
+ 			if ((c = fscanf(fd, "%u", &val)) != 1) {
+ 				if (c == EOF)
+-					error(EXIT_FAILURE, errno, "fscanf");
++					err(EXIT_FAILURE, "fscanf");
+ 
+-				error(EXIT_FAILURE, 0, _("Error: %s: Invalid value in field %u in line %u."),
++				err(EXIT_FAILURE, _("Error: %s: Invalid value in field %u in line %u."),
+ 				      filename, rows + 1, cols + 1);
+ 			}
+ 
+ 			cmap[rows + cols * 3] = (unsigned char) val;
+ 
+ 			if (cols < 15 && fgetc(fd) != ',')
+-				error(EXIT_FAILURE, 0, _("Error: %s: Insufficient number of fields in line %u."),
++				err(EXIT_FAILURE, _("Error: %s: Insufficient number of fields in line %u."),
+ 				      filename, rows + 1);
+ 			cols++;
+ 		}
+ 
+ 		if ((c = fgetc(fd)) == EOF)
+-			error(EXIT_FAILURE, 0, _("Error: %s: Line %u has ended unexpectedly.\n"),
++			err(EXIT_FAILURE, _("Error: %s: Line %u has ended unexpectedly.\n"),
+ 			      filename, rows + 1); 
+ 
+ 		if (c != '\n')
+-			error(EXIT_FAILURE, 0, _("Error: %s: Line %u is too long.\n"),
++			err(EXIT_FAILURE, _("Error: %s: Line %u is too long.\n"),
+ 			      filename, rows + 1);
+ 	}
+ }
+@@ -141,7 +141,7 @@ main(int argc, char **argv) {
+ 
+ 	} else {
+ 		if ((fd = fopen(file, "r")) == NULL)
+-			error(EXIT_FAILURE, errno, "fopen");
++			err(EXIT_FAILURE, "fopen");
+ 
+ 		parse_file(fd, file);
+ 		fclose(fd);

+ 4 - 4
package/libmodplug/Makefile

@@ -4,13 +4,13 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=		libmodplug
-PKG_VERSION:=		0.8.8.4
-PKG_RELEASE:=		2
-PKG_MD5SUM:=		fddc3c704c5489de2a3cf0fedfec59db
+PKG_VERSION:=		0.8.8.5
+PKG_RELEASE:=		1
+PKG_MD5SUM:=		5f30241db109d647781b784e62ddfaa1
 PKG_DESCR:=		a MOD player library
 PKG_SECTION:=		libs
 PKG_URL:=		http://modplug-xmms.sourceforge.net
-PKG_SITES:=		${MASTER_SITE_SOURCEFORGE:=modplug-xmms/libmodplug/0.8.8.4/}
+PKG_SITES:=		${MASTER_SITE_SOURCEFORGE:=modplug-xmms/libmodplug/0.8.8.5/}
 PKG_OPTS:=		dev
 
 include $(TOPDIR)/mk/package.mk

+ 1 - 3
package/libtirpc/Makefile

@@ -5,7 +5,7 @@ include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		libtirpc
 PKG_VERSION:=		0.2.3
-PKG_RELEASE:=		2
+PKG_RELEASE:=		3
 PKG_MD5SUM:=		b70e6c12a369a91e69fcc3b9feb23d61
 PKG_DESCR:=		a transport independent RPC library
 PKG_SECTION:=		libs
@@ -15,8 +15,6 @@ PKG_URL:=		http://sourceforge.net/projects/libtirpc/
 PKG_SITES:=		${MASTER_SITE_SOURCEFORGE:=libtirpc/}
 PKG_OPTS:=		dev
 
-PKG_LIBC_DEPENDS:=	uclibc glibc
-
 DISTFILES:=		$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 
 include ${TOPDIR}/mk/package.mk

+ 18 - 0
package/libtirpc/patches/patch-src_auth_des_c

@@ -0,0 +1,18 @@
+--- libtirpc-0.2.3.orig/src/auth_des.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/auth_des.c	2014-03-22 13:20:52.000000000 +0100
+@@ -38,7 +38,6 @@
+ #include <string.h>
+ #include <stdlib.h>
+ #include <unistd.h>
+-#include <sys/cdefs.h>
+ #include <rpc/des_crypt.h>
+ #include <syslog.h>
+ #include <rpc/types.h>
+@@ -52,7 +51,6 @@
+ 
+ #if defined(LIBC_SCCS) && !defined(lint)
+ #endif
+-#include <sys/cdefs.h>
+ 
+ #define USEC_PER_SEC		1000000
+ #define RTIME_TIMEOUT		5	/* seconds to wait for sync */

+ 10 - 0
package/libtirpc/patches/patch-src_auth_none_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/auth_none.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/auth_none.c	2014-03-22 13:20:53.000000000 +0100
+@@ -31,7 +31,6 @@
+ static char *sccsid = "@(#)auth_none.c 1.19 87/08/11 Copyr 1984 Sun Micro";
+ static char *sccsid = "@(#)auth_none.c	2.1 88/07/29 4.0 RPCSRC";
+ #endif
+-#include <sys/cdefs.h>
+ __FBSDID("$FreeBSD: src/lib/libc/rpc/auth_none.c,v 1.12 2002/03/22 23:18:35 obrien Exp $");
+ */
+ 

+ 13 - 5
package/libtirpc/patches/patch-src_auth_time_c

@@ -1,6 +1,14 @@
---- libtirpc-0.2.2.orig/src/auth_time.c	2011-05-02 14:10:40.000000000 +0200
-+++ libtirpc-0.2.2/src/auth_time.c	2012-03-22 19:02:30.422855534 +0100
-@@ -43,7 +43,7 @@
+--- libtirpc-0.2.3.orig/src/auth_time.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/auth_time.c	2014-03-22 13:20:53.000000000 +0100
+@@ -25,7 +25,6 @@
+  *	needed to deal with TCP connections.
+  */
+ 
+-#include <sys/cdefs.h>
+ #include <stdio.h>
+ #include <syslog.h>
+ #include <string.h>
+@@ -43,7 +42,7 @@
  //#include <clnt_soc.h>
  #include <sys/select.h>
  #undef NIS
@@ -9,7 +17,7 @@
  
  
  #ifdef TESTING
-@@ -138,6 +138,7 @@ free_eps(eps, num)
+@@ -138,6 +137,7 @@ free_eps(eps, num)
   * NIS+ server will call __rpc_get_time_offset() with the nis_server
   * structure already populated.
   */
@@ -17,7 +25,7 @@
  static nis_server *
  get_server(sin, host, srv, eps, maxep)
  	struct sockaddr_in *sin;
-@@ -491,3 +492,4 @@ error:
+@@ -491,3 +491,4 @@ error:
  
  	return (time_valid);
  }

+ 10 - 0
package/libtirpc/patches/patch-src_auth_unix_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/auth_unix.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/auth_unix.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * auth_unix.c, Implements UNIX style authentication parameters.

+ 7 - 0
package/libtirpc/patches/patch-src_authdes_prot_c

@@ -0,0 +1,7 @@
+--- libtirpc-0.2.3.orig/src/authdes_prot.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/authdes_prot.c	2014-03-22 13:20:53.000000000 +0100
+@@ -1,4 +1,3 @@
+-#include <sys/cdefs.h>
+ /*
+  * Copyright (c) 2009, Sun Microsystems, Inc.
+  * All rights reserved.

+ 10 - 0
package/libtirpc/patches/patch-src_authunix_prot_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/authunix_prot.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/authunix_prot.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * authunix_prot.c

+ 18 - 0
package/libtirpc/patches/patch-src_bindresvport_c

@@ -0,0 +1,18 @@
+--- libtirpc-0.2.3.orig/src/bindresvport.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/bindresvport.c	2014-03-22 13:24:36.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * Copyright (c) 1987 by Sun Microsystems, Inc.
+@@ -38,6 +37,7 @@
+ #include <sys/socket.h>
+ 
+ #include <netinet/in.h>
++#include <netdb.h>
+ 
+ #include <errno.h>
+ #include <string.h>

+ 22 - 0
package/libtirpc/patches/patch-src_clnt_bcast_c

@@ -0,0 +1,22 @@
+--- libtirpc-0.2.3.orig/src/clnt_bcast.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/clnt_bcast.c	2014-03-22 14:19:29.000000000 +0100
+@@ -28,7 +28,6 @@
+ /*
+  * Copyright (c) 1986-1991 by Sun Microsystems Inc. 
+  */
+-#include <sys/cdefs.h>
+ 
+ /*
+  * clnt_bcast.c
+@@ -41,10 +40,8 @@
+  */
+ #include <sys/socket.h>
+ #include <sys/types.h>
+-#include <sys/queue.h>
+ 
+-/* new queue functions */
+-#include <misc/queue.h>
++#include "queue.h"
+ 
+ #include <net/if.h>
+ #include <netinet/in.h>

+ 10 - 0
package/libtirpc/patches/patch-src_clnt_perror_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/clnt_perror.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/clnt_perror.c	2014-03-22 13:20:53.000000000 +0100
+@@ -27,7 +27,6 @@
+  */
+ 
+ /*
+-#include <sys/cdefs.h>
+ */
+ /*
+  * clnt_perror.c

+ 10 - 0
package/libtirpc/patches/patch-src_clnt_simple_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/clnt_simple.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/clnt_simple.c	2014-03-22 13:20:53.000000000 +0100
+@@ -29,7 +29,6 @@
+  * Copyright (c) 1986-1991 by Sun Microsystems Inc. 
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * clnt_simple.c

+ 10 - 0
package/libtirpc/patches/patch-src_crypt_client_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/crypt_client.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/crypt_client.c	2014-03-22 13:20:53.000000000 +0100
+@@ -30,7 +30,6 @@
+  * SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ #include <err.h>
+ #include <sys/types.h>

+ 7 - 3
package/libtirpc/patches/patch-src_des_crypt_c

@@ -1,6 +1,10 @@
 --- libtirpc-0.2.3.orig/src/des_crypt.c	2013-02-13 16:13:59.000000000 +0100
-+++ libtirpc-0.2.3/src/des_crypt.c	2013-08-12 16:47:07.000000000 +0200
-@@ -43,7 +43,7 @@ static char sccsid[] = "@(#)des_crypt.c
++++ libtirpc-0.2.3/src/des_crypt.c	2014-03-22 13:20:53.000000000 +0100
+@@ -39,11 +39,10 @@
+ static char sccsid[] = "@(#)des_crypt.c	2.2 88/08/10 4.0 RPCSRC; from 1.13 88/02/08 SMI";
+ #endif
+ #endif
+-#include <sys/cdefs.h>
  
  static int common_crypt( char *, char *, unsigned, unsigned, struct desparams * );
  int (*__des_crypt_LOCAL)() = 0;
@@ -9,7 +13,7 @@
  /*
   * Copy 8 bytes
   */
-@@ -145,10 +145,6 @@ common_crypt(key, buf, len, mode, desp)
+@@ -145,10 +144,6 @@ common_crypt(key, buf, len, mode, desp)
  		if (!__des_crypt_LOCAL(buf, len, desp)) {
  			return (DESERR_HWERROR);
  		}

+ 9 - 0
package/libtirpc/patches/patch-src_des_soft_c

@@ -0,0 +1,9 @@
+--- libtirpc-0.2.3.orig/src/des_soft.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/des_soft.c	2014-03-22 13:20:53.000000000 +0100
+@@ -1,5 +1,4 @@
+-//#include <sys/cdefs.h>
+-
++//
+ /*
+  * Copyright (c) 2009, Sun Microsystems, Inc.
+  * All rights reserved.

+ 10 - 0
package/libtirpc/patches/patch-src_getnetconfig_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/getnetconfig.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/getnetconfig.c	2014-03-22 13:20:53.000000000 +0100
+@@ -32,7 +32,6 @@
+  
+ #include <pthread.h>
+ #include <reentrant.h>
+-#include <sys/cdefs.h>
+ #include <stdio.h>
+ #include <errno.h>
+ #include <netconfig.h>

+ 16 - 0
package/libtirpc/patches/patch-src_getnetpath_c

@@ -0,0 +1,16 @@
+--- libtirpc-0.2.3.orig/src/getnetpath.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/getnetpath.c	2014-03-22 13:20:53.000000000 +0100
+@@ -25,13 +25,11 @@
+  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+-#include <sys/cdefs.h>
+ 
+ /*
+  * Copyright (c) 1989 by Sun Microsystems, Inc.
+  */
+ 
+-#include <sys/cdefs.h>
+ #include <stdio.h>
+ #include <errno.h>
+ #include <netconfig.h>

+ 10 - 0
package/libtirpc/patches/patch-src_getpeereid_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/getpeereid.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/getpeereid.c	2014-03-22 13:20:52.000000000 +0100
+@@ -24,7 +24,6 @@
+  * SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ #include <sys/param.h>
+ #include <sys/socket.h>

+ 10 - 0
package/libtirpc/patches/patch-src_getpublickey_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/getpublickey.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/getpublickey.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ /*
+-#include <sys/cdefs.h>
+ */
+ 
+ /*

+ 10 - 0
package/libtirpc/patches/patch-src_key_call_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/key_call.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/key_call.c	2014-03-22 13:20:52.000000000 +0100
+@@ -30,7 +30,6 @@
+  */
+ 
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * key_call.c, Interface to keyserver

+ 10 - 0
package/libtirpc/patches/patch-src_key_prot_xdr_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/key_prot_xdr.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/key_prot_xdr.c	2014-03-22 13:20:53.000000000 +0100
+@@ -33,7 +33,6 @@
+  */
+ /* Copyright (c)  1990, 1991 Sun Microsystems, Inc. */
+ 
+-#include <sys/cdefs.h>
+ 
+ /* 
+  * Compiled from key_prot.x using rpcgen.

+ 8 - 0
package/libtirpc/patches/patch-src_mt_misc_c

@@ -0,0 +1,8 @@
+--- libtirpc-0.2.3.orig/src/mt_misc.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/mt_misc.c	2014-03-22 13:20:53.000000000 +0100
+@@ -1,5 +1,4 @@
+ 
+-#include <sys/cdefs.h>
+ #include <pthread.h>
+ #include <reentrant.h>
+ #include <rpc/rpc.h>

+ 10 - 0
package/libtirpc/patches/patch-src_pmap_clnt_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/pmap_clnt.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/pmap_clnt.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * pmap_clnt.c

+ 10 - 0
package/libtirpc/patches/patch-src_pmap_getmaps_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/pmap_getmaps.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/pmap_getmaps.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * pmap_getmap.c

+ 31 - 0
package/libtirpc/patches/patch-src_rpc_com_h

@@ -0,0 +1,31 @@
+--- libtirpc-0.2.3.orig/src/rpc_com.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/rpc_com.h	2014-03-22 13:20:53.000000000 +0100
+@@ -40,7 +40,6 @@
+ #ifndef _TIRPC_RPCCOM_H
+ #define	_TIRPC_RPCCOM_H
+ 
+-#include <sys/cdefs.h>
+ 
+ /* #pragma ident	"@(#)rpc_com.h	1.11	93/07/05 SMI" */
+ 
+@@ -54,7 +53,9 @@
+ #define __RPC_GETXID(now) ((u_int32_t)getpid() ^ (u_int32_t)(now)->tv_sec ^ \
+     (u_int32_t)(now)->tv_usec)
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern u_int __rpc_get_a_size(int);
+ extern int __rpc_dtbsize(void);
+ extern struct netconfig * __rpcgettp(int);
+@@ -90,6 +91,8 @@ void __xprt_set_raddr(SVCXPRT *, const s
+ SVCXPRT **__svc_xports;
+ int __svc_maxrec;
+ 
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif /* _TIRPC_RPCCOM_H */

+ 10 - 0
package/libtirpc/patches/patch-src_rpc_generic_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/rpc_generic.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/rpc_generic.c	2014-03-22 13:20:53.000000000 +0100
+@@ -29,7 +29,6 @@
+  * Copyright (c) 1986-1991 by Sun Microsystems Inc. 
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * rpc_generic.c, Miscl routines for RPC.

+ 10 - 0
package/libtirpc/patches/patch-src_rpcb_st_xdr_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/rpcb_st_xdr.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/rpcb_st_xdr.c	2014-03-22 13:20:53.000000000 +0100
+@@ -35,7 +35,6 @@
+  * routines used with the rpcbind stats facility.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ #include <rpc/rpc.h>
+ 

+ 10 - 0
package/libtirpc/patches/patch-src_rpcdname_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/rpcdname.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/rpcdname.c	2014-03-22 13:20:53.000000000 +0100
+@@ -25,7 +25,6 @@
+  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+-#include <sys/cdefs.h>
+ 
+ /*
+  * rpcdname.c

+ 10 - 0
package/libtirpc/patches/patch-src_svc_dg_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/svc_dg.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/svc_dg.c	2014-03-22 13:20:52.000000000 +0100
+@@ -31,7 +31,6 @@
+  * Copyright (c) 1986-1991 by Sun Microsystems Inc.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * svc_dg.c, Server side for connectionless RPC.

+ 10 - 0
package/libtirpc/patches/patch-src_svc_simple_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/svc_simple.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/svc_simple.c	2014-03-22 13:20:53.000000000 +0100
+@@ -29,7 +29,6 @@
+  * Copyright (c) 1986-1991 by Sun Microsystems Inc. 
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * svc_simple.c

+ 10 - 0
package/libtirpc/patches/patch-src_svc_vc_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/svc_vc.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/svc_vc.c	2014-03-22 13:20:53.000000000 +0100
+@@ -27,7 +27,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * svc_vc.c, Server side for Connection Oriented based RPC. 

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_array_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr_array.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_array.c	2014-03-22 13:20:53.000000000 +0100
+@@ -27,7 +27,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_array.c, Generic XDR routines impelmentation.

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr.c, Generic XDR routines implementation.

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_float_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr_float.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_float.c	2014-03-22 13:20:53.000000000 +0100
+@@ -27,7 +27,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_float.c, Generic XDR routines implementation.

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_mem_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr_mem.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_mem.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_mem.h, XDR implementation using memory buffers.

+ 11 - 0
package/libtirpc/patches/patch-src_xdr_rec_c

@@ -0,0 +1,11 @@
+--- libtirpc-0.2.3.orig/src/xdr_rec.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_rec.c	2014-03-22 13:20:53.000000000 +0100
+@@ -27,8 +27,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_rec.c, Implements TCP/IP based XDR streams with a "record marking"

+ 11 - 0
package/libtirpc/patches/patch-src_xdr_reference_c

@@ -0,0 +1,11 @@
+--- libtirpc-0.2.3.orig/src/xdr_reference.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_reference.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,8 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_reference.c, Generic XDR routines impelmentation.

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_sizeof_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr_sizeof.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_sizeof.c	2014-03-22 13:20:53.000000000 +0100
+@@ -34,7 +34,6 @@
+  * when serialized using XDR.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ #include "namespace.h"
+ #include <rpc/types.h>

+ 10 - 0
package/libtirpc/patches/patch-src_xdr_stdio_c

@@ -0,0 +1,10 @@
+--- libtirpc-0.2.3.orig/src/xdr_stdio.c	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/src/xdr_stdio.c	2014-03-22 13:20:53.000000000 +0100
+@@ -26,7 +26,6 @@
+  * POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
+-#include <sys/cdefs.h>
+ 
+ /*
+  * xdr_stdio.c, XDR implementation on standard i/o file.

+ 24 - 0
package/libtirpc/patches/patch-tirpc_misc_event_h

@@ -0,0 +1,24 @@
+--- libtirpc-0.2.3.orig/tirpc/misc/event.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/misc/event.h	2014-03-22 13:20:52.000000000 +0100
+@@ -186,15 +186,18 @@ extern int	kqueue_del_filteropts(int fil
+ 
+ #else 	/* !_KERNEL */
+ 
+-#include <sys/cdefs.h>
+ struct timespec;
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ int     kqueue(void);
+ int     kevent(int kq, const struct kevent *changelist, int nchanges,
+ 	    struct kevent *eventlist, int nevents,
+ 	    const struct timespec *timeout);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif /* !_KERNEL */
+ 

+ 23 - 0
package/libtirpc/patches/patch-tirpc_netconfig_h

@@ -0,0 +1,23 @@
+--- libtirpc-0.2.3.orig/tirpc/netconfig.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/netconfig.h	2014-03-22 13:20:52.000000000 +0100
+@@ -74,7 +74,9 @@ typedef struct {
+ #define NC_UDP		"udp"
+ #define NC_ICMP		"icmp"
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ 
+ extern void *setnetconfig (void);
+ extern struct netconfig *getnetconfig (void *);
+@@ -89,6 +91,8 @@ extern int endnetpath (void *);
+ extern void nc_perror (const char *);
+ extern char *nc_sperror (void);
+ 
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif /* _NETCONFIG_H_ */

+ 32 - 0
package/libtirpc/patches/patch-tirpc_rpc_auth_des_h

@@ -0,0 +1,32 @@
+--- libtirpc-0.2.3.orig/tirpc/rpc/auth_des.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/rpc/auth_des.h	2014-03-22 13:20:52.000000000 +0100
+@@ -114,17 +114,25 @@ struct authdes_verf {
+  * Map a des credential into a unix cred.
+  *
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern int authdes_getucred( struct authdes_cred *, uid_t *, gid_t *, int *, gid_t * );
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern bool_t	xdr_authdes_cred(XDR *, struct authdes_cred *);
+ extern bool_t	xdr_authdes_verf(XDR *, struct authdes_verf *);
+ extern int	rtime(dev_t, struct netbuf *, int, struct timeval *,
+ 		    struct timeval *);
+ extern void	kgetnetname(char *);
+ extern enum auth_stat _svcauth_des(struct svc_req *, struct rpc_msg *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif /* ndef _TI_AUTH_DES_ */

+ 53 - 0
package/libtirpc/patches/patch-tirpc_rpc_auth_gss_h

@@ -0,0 +1,53 @@
+--- libtirpc-0.2.3.orig/tirpc/rpc/auth_gss.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/rpc/auth_gss.h	2014-03-22 13:20:52.000000000 +0100
+@@ -104,28 +104,32 @@ struct rpc_gss_init_res {
+ #define MAXSEQ		0x80000000
+ 
+ /* Prototypes. */
+-__BEGIN_DECLS
+-bool_t	xdr_rpc_gss_cred	__P((XDR *xdrs, struct rpc_gss_cred *p));
+-bool_t	xdr_rpc_gss_init_args	__P((XDR *xdrs, gss_buffer_desc *p));
+-bool_t	xdr_rpc_gss_init_res	__P((XDR *xdrs, struct rpc_gss_init_res *p));
+-bool_t	xdr_rpc_gss_data	__P((XDR *xdrs, xdrproc_t xdr_func,
++#ifdef __cplusplus
++extern "C" {
++#endif
++bool_t	xdr_rpc_gss_cred	(XDR *xdrs, struct rpc_gss_cred *p);
++bool_t	xdr_rpc_gss_init_args	(XDR *xdrs, gss_buffer_desc *p);
++bool_t	xdr_rpc_gss_init_res	(XDR *xdrs, struct rpc_gss_init_res *p);
++bool_t	xdr_rpc_gss_data	(XDR *xdrs, xdrproc_t xdr_func,
+ 				     caddr_t xdr_ptr, gss_ctx_id_t ctx,
+ 				     gss_qop_t qop, rpc_gss_svc_t svc,
+-				     u_int seq));
++				     u_int seq);
+ 
+-AUTH   *authgss_create		__P((CLIENT *, gss_name_t,
+-				     struct rpc_gss_sec *));
+-AUTH   *authgss_create_default	__P((CLIENT *, char *, struct rpc_gss_sec *));
+-bool_t authgss_service		__P((AUTH *auth, int svc));
+-bool_t authgss_get_private_data	__P((AUTH *auth,
+-	    			     struct authgss_private_data *));
+-bool_t authgss_free_private_data __P((struct authgss_private_data *));
++AUTH   *authgss_create		(CLIENT *, gss_name_t,
++				     struct rpc_gss_sec *);
++AUTH   *authgss_create_default	(CLIENT *, char *, struct rpc_gss_sec *);
++bool_t authgss_service		(AUTH *auth, int svc);
++bool_t authgss_get_private_data	(AUTH *auth,
++	    			     struct authgss_private_data *);
++bool_t authgss_free_private_data (struct authgss_private_data *);
+ 
+-void	gss_log_debug		__P((const char *fmt, ...));
+-void	gss_log_status		__P((char *m, OM_uint32 major,
+-				     OM_uint32 minor));
+-void	gss_log_hexdump		__P((const u_char *buf, int len, int offset));
++void	gss_log_debug		(const char *fmt, ...);
++void	gss_log_status		(char *m, OM_uint32 major,
++				     OM_uint32 minor);
++void	gss_log_hexdump		(const u_char *buf, int len, int offset);
+ 
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif /* !_TIRPC_AUTH_GSS_H */

+ 192 - 0
package/libtirpc/patches/patch-tirpc_rpc_auth_h

@@ -0,0 +1,192 @@
+--- libtirpc-0.2.3.orig/tirpc/rpc/auth.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/rpc/auth.h	2014-03-22 13:20:52.000000000 +0100
+@@ -48,7 +48,6 @@
+ 
+ #include <rpc/xdr.h>
+ #include <rpc/clnt_stat.h>
+-#include <sys/cdefs.h>
+ #include <sys/socket.h>
+ #include <sys/types.h>
+ #include <stdio.h>
+@@ -165,9 +164,13 @@ union des_block {
+ 	char c[8];
+ };
+ typedef union des_block des_block;
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern bool_t xdr_des_block(XDR *, des_block *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Authentication info.  Opaque to client.
+@@ -288,9 +291,13 @@ auth_put(AUTH *auth)
+ 		xfunc, xwhere))
+ 
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern struct opaque_auth _null_auth;
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Any style authentication.  These routines can be used by any
+@@ -311,11 +318,15 @@ int authany_wrap(void), authany_unwrap(v
+  *	int len;
+  *	int *aup_gids;
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern AUTH *authunix_create(char *, uid_t, uid_t, int, uid_t *);
+ extern AUTH *authunix_create_default(void);	/* takes no parameters */
+ extern AUTH *authnone_create(void);		/* takes no parameters */
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ /*
+  * DES style authentication
+  * AUTH *authsecdes_create(servername, window, timehost, ckey)
+@@ -324,15 +335,23 @@ __END_DECLS
+  * 	const char *timehost;			- optional hostname to sync with
+  * 	des_block *ckey;		- optional conversation key to use
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern AUTH *authdes_create (char *, u_int, struct sockaddr *, des_block *);
+ extern AUTH *authdes_seccreate (const char *, const u_int, const  char *,
+     const  des_block *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern bool_t xdr_opaque_auth		(XDR *, struct opaque_auth *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #define authsys_create(c,i1,i2,i3,ip) authunix_create((c),(i1),(i2),(i3),(ip))
+ #define authsys_create_default() authunix_create_default()
+@@ -340,36 +359,48 @@ __END_DECLS
+ /*
+  * Netname manipulation routines.
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern int getnetname(char *);
+ extern int host2netname(char *, const char *, const char *);
+ extern int user2netname(char *, const uid_t, const char *);
+ extern int netname2user(char *, uid_t *, gid_t *, int *, gid_t *);
+ extern int netname2host(char *, char *, const int);
+ extern void passwd2des ( char *, char * );
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  *
+  * These routines interface to the keyserv daemon
+  *
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern int key_decryptsession(const char *, des_block *);
+ extern int key_encryptsession(const char *, des_block *);
+ extern int key_gendes(des_block *);
+ extern int key_setsecret(const char *);
+ extern int key_secretkey_is_set(void);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Publickey routines.
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern int getpublickey (const char *, char *);
+ extern int getpublicandprivatekey (char *, char *);
+ extern int getsecretkey (char *, char *, char *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #ifdef KERBEROS
+ /*
+@@ -382,10 +413,14 @@ __END_DECLS
+  *	const char *timehost;			- optional hostname to sync with
+  *	int *status;				- kerberos status returned
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern AUTH	*authkerb_seccreate(const char *, const char *, const  char *,
+ 		    const u_int, const char *, int *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Map a kerberos credential into a unix cred.
+@@ -398,19 +433,27 @@ __END_DECLS
+  *	int *groups;
+  *
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern int	authkerb_getucred(/* struct svc_req *, uid_t *, gid_t *,
+ 		    short *, int * */);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ #endif /* KERBEROS */
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ struct svc_req;
+ struct rpc_msg;
+ enum auth_stat _svcauth_none (struct svc_req *, struct rpc_msg *);
+ enum auth_stat _svcauth_short (struct svc_req *, struct rpc_msg *);
+ enum auth_stat _svcauth_unix (struct svc_req *, struct rpc_msg *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #define AUTH_NONE	0		/* no authentication */
+ #define	AUTH_NULL	0		/* backward compatibility */

+ 26 - 0
package/libtirpc/patches/patch-tirpc_rpc_auth_unix_h

@@ -0,0 +1,26 @@
+--- libtirpc-0.2.3.orig/tirpc/rpc/auth_unix.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/rpc/auth_unix.h	2014-03-22 13:20:52.000000000 +0100
+@@ -45,7 +45,6 @@
+ 
+ #ifndef _TIRPC_AUTH_UNIX_H
+ #define _TIRPC_AUTH_UNIX_H
+-#include <sys/cdefs.h>
+ 
+ /* The machine name is part of a credential; it may not exceed 255 bytes */
+ #define MAX_MACHINE_NAME 255
+@@ -67,9 +66,13 @@ struct authunix_parms {
+ 
+ #define authsys_parms authunix_parms
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern bool_t xdr_authunix_parms(XDR *, struct authunix_parms *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * If a response verifier has flavor AUTH_SHORT,

+ 132 - 0
package/libtirpc/patches/patch-tirpc_rpc_clnt_h

@@ -0,0 +1,132 @@
+--- libtirpc-0.2.3.orig/tirpc/rpc/clnt.h	2013-02-13 16:13:59.000000000 +0100
++++ libtirpc-0.2.3/tirpc/rpc/clnt.h	2014-03-22 13:20:52.000000000 +0100
+@@ -42,7 +42,6 @@
+ #include <rpc/clnt_stat.h>
+ #include <rpc/auth.h>
+ 
+-#include <sys/cdefs.h>
+ #include <netconfig.h>
+ #include <sys/un.h>
+ 
+@@ -267,7 +266,9 @@ struct rpc_timers {
+  * Generic client creation routine. Supported protocols are those that
+  * belong to the nettype namespace (/etc/netconfig).
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern CLIENT *clnt_create(const char *, const rpcprog_t, const rpcvers_t,
+ 			   const char *);
+ /*
+@@ -414,32 +415,46 @@ extern CLIENT *clnt_dg_create(const int,
+  */
+ extern CLIENT *clnt_raw_create(rpcprog_t, rpcvers_t);
+ 
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ 
+ /*
+  * Print why creation failed
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern void clnt_pcreateerror(const char *);			/* stderr */
+ extern char *clnt_spcreateerror(const char *);			/* string */
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Like clnt_perror(), but is more verbose in its output
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern void clnt_perrno(enum clnt_stat);		/* stderr */
+ extern char *clnt_sperrno(enum clnt_stat);		/* string */
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * Print an English error message, given the client error code
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern void clnt_perror(CLIENT *, const char *);	 	/* stderr */
+ extern char *clnt_sperror(CLIENT *, const char *);		/* string */
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ 
+ /*
+@@ -450,9 +465,13 @@ struct rpc_createerr {
+ 	struct rpc_err cf_error; /* useful when cf_stat == RPC_PMAPFAILURE */
+ };
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern struct rpc_createerr	*__rpc_createerr(void);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ #define get_rpc_createerr()	(*(__rpc_createerr()))
+ #define rpc_createerr		(*(__rpc_createerr()))
+ 
+@@ -469,12 +488,16 @@ __END_DECLS
+  *	char *out;
+  *	const char *nettype;
+  */
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern enum clnt_stat rpc_call(const char *, const rpcprog_t,
+ 			       const rpcvers_t, const rpcproc_t,
+ 			       const xdrproc_t, const char *,
+ 			       const xdrproc_t, char *, const char *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /*
+  * RPC broadcast interface
+@@ -522,7 +545,9 @@ __END_DECLS
+ 
+ typedef bool_t (*resultproc_t)(caddr_t, ...);
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ extern enum clnt_stat rpc_broadcast(const rpcprog_t, const rpcvers_t,
+ 				    const rpcproc_t, const xdrproc_t,
+ 				    caddr_t, const xdrproc_t, caddr_t,
+@@ -532,7 +557,9 @@ extern enum clnt_stat rpc_broadcast_exp(
+ 					caddr_t, const xdrproc_t, caddr_t,
+ 					const resultproc_t, const int,
+ 					const int, const char *);
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ /* For backward compatibility */
+ #include <rpc/clnt_soc.h>

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels