fix: _brightness.sh - find brighness files with '*video*' path (multiple files)
[cmdllinux.git] / buildroot / _buildroot / buildroot-2017.05-rc2-2017.05.2.patch
blob1fcca679b0f087230970c4cd4e684d7e09513f2e
1 diff -Naurp buildroot-2017.05-rc2/arch/Config.in.arm buildroot-2017.05.2/arch/Config.in.arm
2 --- buildroot-2017.05-rc2/arch/Config.in.arm 2017-05-17 10:27:16.013401440 +0200
3 +++ buildroot-2017.05.2/arch/Config.in.arm 2017-07-27 08:16:52.017486944 +0200
4 @@ -534,15 +534,9 @@ config BR2_GCC_TARGET_CPU
5 default "strongarm" if BR2_strongarm
6 default "xscale" if BR2_xscale
7 default "iwmmxt" if BR2_iwmmxt
8 - default "cortex-a53" if (BR2_cortex_a53 && !BR2_ARCH_IS_64)
9 - default "cortex-a53+fp" if (BR2_cortex_a53 && BR2_ARCH_IS_64 && BR2_ARM_FPU_FP_ARMV8)
10 - default "cortex-a53+fp+simd" if (BR2_cortex_a53 && BR2_ARCH_IS_64 && BR2_ARM_FPU_NEON_FP_ARMV8)
11 - default "cortex-a57" if (BR2_cortex_a57 && !BR2_ARCH_IS_64)
12 - default "cortex-a57+fp" if (BR2_cortex_a57 && BR2_ARCH_IS_64 && BR2_ARM_FPU_FP_ARMV8)
13 - default "cortex-a57+fp+simd" if (BR2_cortex_a57 && BR2_ARCH_IS_64 && BR2_ARM_FPU_NEON_FP_ARMV8)
14 - default "cortex-a72" if (BR2_cortex_a72 && !BR2_ARCH_IS_64)
15 - default "cortex-a72+fp" if (BR2_cortex_a72 && BR2_ARCH_IS_64 && BR2_ARM_FPU_FP_ARMV8)
16 - default "cortex-a72+fp+simd" if (BR2_cortex_a72 && BR2_ARCH_IS_64 && BR2_ARM_FPU_NEON_FP_ARMV8)
17 + default "cortex-a53" if BR2_cortex_a53
18 + default "cortex-a57" if BR2_cortex_a57
19 + default "cortex-a72" if BR2_cortex_a72
21 config BR2_GCC_TARGET_ABI
22 default "aapcs-linux" if BR2_arm || BR2_armeb
23 diff -Naurp buildroot-2017.05-rc2/board/atmel/at91sam9x5ek_mmc/genimage.cfg buildroot-2017.05.2/board/atmel/at91sam9x5ek_mmc/genimage.cfg
24 --- buildroot-2017.05-rc2/board/atmel/at91sam9x5ek_mmc/genimage.cfg 2017-05-17 10:27:16.013401440 +0200
25 +++ buildroot-2017.05.2/board/atmel/at91sam9x5ek_mmc/genimage.cfg 2017-07-27 08:16:52.017486944 +0200
26 @@ -24,6 +24,7 @@ image sdcard.img {
27 partition-type = 0xC
28 bootable = "true"
29 image = "boot.vfat"
30 + offset = 1M
33 partition rootfs {
34 diff -Naurp buildroot-2017.05-rc2/boot/syslinux/Config.in buildroot-2017.05.2/boot/syslinux/Config.in
35 --- buildroot-2017.05-rc2/boot/syslinux/Config.in 2017-05-17 10:27:16.013401440 +0200
36 +++ buildroot-2017.05.2/boot/syslinux/Config.in 2017-07-27 08:16:52.017486944 +0200
37 @@ -35,6 +35,7 @@ config BR2_TARGET_SYSLINUX_PXELINUX
39 config BR2_TARGET_SYSLINUX_MBR
40 bool "install mbr"
41 + depends on !BR2_TOOLCHAIN_HAS_BINUTILS_BUG_19615
42 select BR2_TARGET_SYSLINUX_LEGACY_BIOS
43 help
44 Install the legacy-BIOS 'mbr' image, to boot off a
45 diff -Naurp buildroot-2017.05-rc2/boot/syslinux/syslinux.mk buildroot-2017.05.2/boot/syslinux/syslinux.mk
46 --- buildroot-2017.05-rc2/boot/syslinux/syslinux.mk 2017-05-17 10:27:16.013401440 +0200
47 +++ buildroot-2017.05.2/boot/syslinux/syslinux.mk 2017-07-27 08:16:52.017486944 +0200
48 @@ -13,7 +13,8 @@ SYSLINUX_LICENSE_FILES = COPYING
50 SYSLINUX_INSTALL_IMAGES = YES
52 -SYSLINUX_DEPENDENCIES = host-nasm host-upx util-linux
53 +# host-util-linux needed to provide libuuid when building host tools
54 +SYSLINUX_DEPENDENCIES = host-nasm host-upx util-linux host-util-linux
56 ifeq ($(BR2_TARGET_SYSLINUX_LEGACY_BIOS),y)
57 SYSLINUX_TARGET += bios
58 diff -Naurp buildroot-2017.05-rc2/.br-external.mk buildroot-2017.05.2/.br-external.mk
59 --- buildroot-2017.05-rc2/.br-external.mk 2017-05-17 10:29:56.013401440 +0200
60 +++ buildroot-2017.05.2/.br-external.mk 1970-01-01 01:00:00.000000000 +0100
61 @@ -1,10 +0,0 @@
63 -# Automatically generated file; DO NOT EDIT.
66 -BR2_EXTERNAL ?=
67 -BR2_EXTERNAL_NAMES =
68 -BR2_EXTERNAL_DIRS =
69 -BR2_EXTERNAL_MKS =
71 -# No br2-external tree defined.
72 diff -Naurp buildroot-2017.05-rc2/CHANGES buildroot-2017.05.2/CHANGES
73 --- buildroot-2017.05-rc2/CHANGES 2017-05-17 10:27:16.013401440 +0200
74 +++ buildroot-2017.05.2/CHANGES 2017-07-27 08:16:52.017486944 +0200
75 @@ -1,3 +1,97 @@
76 +2017.05.2, Released July 27th, 2017
78 + Important / security related fixes.
80 + Webkitgtk bumped to the 2.16.x series, fixing a large number
81 + of security issues.
83 + host-aespipe compile fix for Debian/Gentoo/Ubuntu toolchains
84 + which default to PIE mode.
86 + Updated/fixed packages: aespipe, apache, bind, binutils,
87 + busybox, ccache, collectd, dieharder, efibootmgr, efivar,
88 + expat, ffmpeg, gcc, heimdal, iproute2, irssi, libglib2,
89 + libmemcached, libosip2, libtirpc, libxml-parser-perl,
90 + linux-fusion, linux-zigbee, mpg123, orc, pcre, php, protobuf,
91 + pulseaudio, python-setproctitle, qt5base, rpi-firmware,
92 + samba4, syslinux, systemd, spice, tcpdump, tiff, uboot-tools,
93 + webkitgtk, x265, xserver_xorg-server, xvisor
95 + Issues resolved (http://bugs.buildroot.org):
97 + #10061: gcc5.4 buildroot toolchain for powerpc libsanitizer...
99 +2017.05.1, Released July 4th, 2017
101 + Important / security related fixes.
103 + Update support/scripts/scancpan to use METACPAN v1 API as v0
104 + has been shutdown.
106 + Update support/scripts/mkusers to handle setups where
107 + /etc/shadow is a symlink.
109 + External toolchain: Don't create musl dynamic loader symlink
110 + for static builds.
112 + Setlocalversion: Correct detection of mercurial revisions for
113 + non-tagged versions.
115 + Defconfigs: at91sam9x5ek_mmc: workaround boot rom issue.
117 + Updated/fixed packages: apache, automake, bind, botan, c-ares,
118 + dhcp, expat, fcgiwrap, gcc, gdb, gesftpserver, glibc, glmark2,
119 + gnutls, gst1-plugins-bad, imagemagick, imx-uuc, intltool,
120 + iperf, ipsec-tools, irssi, kmod, libcurl, libgcrypt, libmad,
121 + libnl, lugaro, mosquitto, mpg123, ncurses, nodejs, ntp,
122 + openssh, openvpn, pngquant, python-simplegeneric, qt5base,
123 + qt5multimedia, rtl8821au, socat, spice, systemd, tor, trinity,
124 + tslib, vlc, x264, xen, xlib_libxshmfenc, xserver_xorg-server
126 + Issues resolved (http://bugs.buildroot.org):
128 + #9976: License file for package 'rtl8821au' incorrect
130 +2017.05, Released May 31st, 2017
132 + Minor fixes.
134 + External toolchain: musl dynamic linker symlink for mips-sf
135 + corrected.
137 + Updated/fixed packages: agentpp, bash, exim, hans, madplay,
138 + qpid-proton, rtl8188eu, snmppp, stm32flash, strongswan, sudo,
139 + xen
141 + Issues resolved (http://bugs.buildroot.org):
143 + #9906: genimage: Disk full
145 +2017.05-rc3, Released May 30th, 2017
147 + Fixes all over the tree.
149 + ARC toolchain bumped to 2017.03
151 + Runtime testing improvements and cleanups.
153 + Updated/fixed packages: acpica, armadillo, audiofile, c-icap,
154 + cppcms, dhcp, docker-engine, dropbear, elfutils, erlang,
155 + fbgrab, ffmpeg, flashrom, ftop, gnutls, google-breakpad,
156 + keepalived, kodi, libcdio, libepoxy, libev, libminiupnpc,
157 + libqmi, libtasn1, libv4l, mariadb, mono, mosh, mosquitto,
158 + mxml, ntp, opencv, openpowerlink, oracle-mysql, popt,
159 + pulseview, python-enum34, rabbitmq-c, redis, samba4, stella,
160 + xen
162 + Removed packages: firejail, ola
164 + Issues resolved (http://bugs.buildroot.org):
166 + #9871: fbgrab 1.3 won't build with BR2_REPRODUCIBLE set
167 + #9876: aarch64 support with gcc 4.8 toolchain
168 + #9896: host-gcc-initial error downloading because incorrect URL
170 2017.05-rc2, Released May 17th, 2017
172 Fixes all over the tree.
173 diff -Naurp buildroot-2017.05-rc2/Config.in buildroot-2017.05.2/Config.in
174 --- buildroot-2017.05-rc2/Config.in 2017-05-17 10:27:16.013401440 +0200
175 +++ buildroot-2017.05.2/Config.in 2017-07-27 08:16:52.017486944 +0200
176 @@ -57,6 +57,11 @@ config BR2_HOST_GCC_AT_LEAST_6
177 default y if BR2_HOST_GCC_VERSION = "6"
178 select BR2_HOST_GCC_AT_LEAST_5
180 +config BR2_HOST_GCC_AT_LEAST_7
181 + bool
182 + default y if BR2_HOST_GCC_VERSION = "7"
183 + select BR2_HOST_GCC_AT_LEAST_6
185 # Hidden boolean selected by packages in need of Java in order to build
186 # (example: xbmc)
187 config BR2_NEEDS_HOST_JAVA
188 diff -Naurp buildroot-2017.05-rc2/Config.in.legacy buildroot-2017.05.2/Config.in.legacy
189 --- buildroot-2017.05-rc2/Config.in.legacy 2017-05-17 10:27:16.013401440 +0200
190 +++ buildroot-2017.05.2/Config.in.legacy 2017-07-27 08:16:52.017486944 +0200
191 @@ -143,8 +143,42 @@ comment "-------------------------------
192 endif
194 ###############################################################################
196 comment "Legacy options removed in 2017.05"
198 +config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTC
199 + bool "gst1-plugins-bad webrtc renamed to webrtcdsp"
200 + select BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTCDSP
201 + select BR2_LEGACY
202 + help
203 + The WebRTC plugin in GStreamer 1.x has always been named
204 + webrtcdsp, but was wrongly introduced in Buildroot under the
205 + name webrtc. Therefore, we have renamed the option to match
206 + the actual name of the GStreamer plugin.
208 +config BR2_PACKAGE_SPICE_CLIENT
209 + bool "spice client support removed"
210 + select BR2_LEGACY
211 + help
212 + Spice client support has been removed upstream. The
213 + functionality now lives in the spice-gtk widget and
214 + virt-viewer.
216 +config BR2_PACKAGE_SPICE_GUI
217 + bool "spice gui support removed"
218 + select BR2_LEGACY
219 + help
220 + Spice gui support has been removed upstream. The
221 + functionality now lives in the spice-gtk widget and
222 + virt-viewer.
224 +config BR2_PACKAGE_SPICE_TUNNEL
225 + bool "spice network redirection removed"
226 + select BR2_LEGACY
227 + help
228 + Spice network redirection, aka tunnelling has been removed
229 + upstream.
231 config BR2_PACKAGE_SUNXI_MALI_R2P4
232 bool "sunxi-mali r2p4 removed"
233 select BR2_LEGACY
234 diff -Naurp buildroot-2017.05-rc2/DEVELOPERS buildroot-2017.05.2/DEVELOPERS
235 --- buildroot-2017.05-rc2/DEVELOPERS 2017-05-17 10:27:16.013401440 +0200
236 +++ buildroot-2017.05.2/DEVELOPERS 2017-07-27 08:16:52.017486944 +0200
237 @@ -30,9 +30,17 @@ N: Abhilash Tuse <abhilash.tuse@imgtec.c
238 F: package/gstreamer1/gst1-rtsp-server/
240 N: Adam Duskett <aduskett@gmail.com>
241 +F: package/audit/
242 +F: package/checkpolicy/
243 F: package/gstreamer1/gst1-vaapi/
244 +F: package/libselinux/
245 +F: package/libsemanage/
246 +F: package/libsepol/
247 F: package/nginx-naxsi/
248 +F: package/policycoreutils/
249 F: package/python-mutagen/
250 +F: package/sepolgen/
251 +F: package/setools/
252 F: package/sngrep/
254 N: Alex Suykov <alex.suykov@gmail.com>
255 @@ -75,9 +83,6 @@ N: Andrey Smirnov <andrew.smirnov@gmail.
256 F: package/python-decorator/
257 F: package/python-simplegeneric/
259 -N: Andrew Ruder <andrew.ruder@elecsyscorp.com>
260 -F: package/expect/
262 N: Andy Kennedy <andy.kennedy@adtran.com>
263 F: package/libunwind/
265 @@ -160,6 +165,8 @@ F: boot/syslinux/
266 F: package/dc3dd/
268 N: Bernd Kuhls <bernd.kuhls@t-online.de>
269 +F: package/alsa-lib/
270 +F: package/alsa-utils/
271 F: package/apache/
272 F: package/apr/
273 F: package/apr-util/
274 @@ -315,9 +322,6 @@ F: package/libdvbsi/
275 F: package/libsvg/
276 F: package/libsvg-cairo/
278 -N: Chris Frederick <chrisf@cdf123.net>
279 -F: package/firejail/
281 N: Chris Packham <judge.packham@gmail.com>
282 F: package/eventlog/
283 F: package/micropython/
284 @@ -397,9 +401,6 @@ F: package/lua-cjson/
285 F: package/luaexpat/
286 F: package/xinetd/
288 -N: Dave Skok <blanco.ether@gmail.com>
289 -F: package/ola/
291 N: David Bachelart <david.bachelart@bbright.com>
292 F: package/ccrypt/
293 F: package/dos2unix/
294 @@ -1193,9 +1194,6 @@ F: package/nvidia-tegra23/nvidia-tegra23
295 N: Nimai Mahajan <nimaim@gmail.com>
296 F: package/libucl/
298 -N: Niranjan Reddy <niranjan.reddy@rockwellcollins.com>
299 -F: package/cgroupfs-mount/
301 N: Noé Rubinstein <noe.rubinstein@gmail.com>
302 F: package/tpm-tools/
303 F: package/trousers/
304 diff -Naurp buildroot-2017.05-rc2/.gitlab-ci.yml buildroot-2017.05.2/.gitlab-ci.yml
305 --- buildroot-2017.05-rc2/.gitlab-ci.yml 2017-05-17 10:27:16.013401440 +0200
306 +++ buildroot-2017.05.2/.gitlab-ci.yml 2017-07-27 08:16:52.017486944 +0200
307 @@ -4,18 +4,7 @@
308 # It needs to be regenerated every time a defconfig is added, using
309 # "make .gitlab-ci.yml".
311 -image: debian:stable
313 -before_script:
314 - - dpkg --add-architecture i386
315 - # The container has no package lists, so need to update first
316 - - apt-get update -qq
317 - - apt-get install -y -qq --no-install-recommends
318 - build-essential locales bc ca-certificates file rsync gcc-multilib
319 - git bzr cvs mercurial subversion libc6:i386 unzip wget cpio
320 - # To be able to generate a toolchain with locales, enable one UTF-8 locale
321 - - sed -i 's/# \(en_US.UTF-8\)/\1/' /etc/locale.gen
322 - - /usr/sbin/locale-gen
323 +image: buildroot/base
325 .defconfig_script: &defconfig_script
326 - echo 'Configure Buildroot'
327 diff -Naurp buildroot-2017.05-rc2/.gitlab-ci.yml.in buildroot-2017.05.2/.gitlab-ci.yml.in
328 --- buildroot-2017.05-rc2/.gitlab-ci.yml.in 2017-05-17 10:27:16.013401440 +0200
329 +++ buildroot-2017.05.2/.gitlab-ci.yml.in 2017-07-27 08:16:52.017486944 +0200
330 @@ -4,18 +4,7 @@
331 # It needs to be regenerated every time a defconfig is added, using
332 # "make .gitlab-ci.yml".
334 -image: debian:stable
336 -before_script:
337 - - dpkg --add-architecture i386
338 - # The container has no package lists, so need to update first
339 - - apt-get update -qq
340 - - apt-get install -y -qq --no-install-recommends
341 - build-essential locales bc ca-certificates file rsync gcc-multilib
342 - git bzr cvs mercurial subversion libc6:i386 unzip wget cpio
343 - # To be able to generate a toolchain with locales, enable one UTF-8 locale
344 - - sed -i 's/# \(en_US.UTF-8\)/\1/' /etc/locale.gen
345 - - /usr/sbin/locale-gen
346 +image: buildroot/base
348 .defconfig_script: &defconfig_script
349 - echo 'Configure Buildroot'
350 diff -Naurp buildroot-2017.05-rc2/linux/Config.in buildroot-2017.05.2/linux/Config.in
351 --- buildroot-2017.05-rc2/linux/Config.in 2017-05-17 10:27:16.013401440 +0200
352 +++ buildroot-2017.05.2/linux/Config.in 2017-07-27 08:16:52.017486944 +0200
353 @@ -26,7 +26,7 @@ choice
354 prompt "Kernel version"
356 config BR2_LINUX_KERNEL_LATEST_VERSION
357 - bool "Latest version (4.11.1)"
358 + bool "Latest version (4.11.9)"
360 config BR2_LINUX_KERNEL_LATEST_CIP_VERSION
361 bool "Latest CIP SLTS version (v4.4.55-cip3)"
362 @@ -116,7 +116,7 @@ endif
364 config BR2_LINUX_KERNEL_VERSION
365 string
366 - default "4.11.1" if BR2_LINUX_KERNEL_LATEST_VERSION
367 + default "4.11.9" if BR2_LINUX_KERNEL_LATEST_VERSION
368 default "v4.4.55-cip3" if BR2_LINUX_KERNEL_LATEST_CIP_VERSION
369 default BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE \
370 if BR2_LINUX_KERNEL_CUSTOM_VERSION
371 diff -Naurp buildroot-2017.05-rc2/linux/linux.mk buildroot-2017.05.2/linux/linux.mk
372 --- buildroot-2017.05-rc2/linux/linux.mk 2017-05-17 10:27:16.013401440 +0200
373 +++ buildroot-2017.05.2/linux/linux.mk 2017-07-27 08:16:52.017486944 +0200
374 @@ -278,7 +278,7 @@ define LINUX_KCONFIG_FIXUP_CMDS
375 $(call KCONFIG_ENABLE_OPT,CONFIG_FHANDLE,$(@D)/.config)
376 $(call KCONFIG_ENABLE_OPT,CONFIG_AUTOFS4_FS,$(@D)/.config)
377 $(call KCONFIG_ENABLE_OPT,CONFIG_TMPFS_POSIX_ACL,$(@D)/.config)
378 - $(call KCONFIG_ENABLE_OPT,CONFIG_TMPFS_POSIX_XATTR,$(@D)/.config))
379 + $(call KCONFIG_ENABLE_OPT,CONFIG_TMPFS_XATTR,$(@D)/.config))
380 $(if $(BR2_PACKAGE_SMACK),
381 $(call KCONFIG_ENABLE_OPT,CONFIG_SECURITY,$(@D)/.config)
382 $(call KCONFIG_ENABLE_OPT,CONFIG_SECURITY_SMACK,$(@D)/.config)
383 diff -Naurp buildroot-2017.05-rc2/Makefile buildroot-2017.05.2/Makefile
384 --- buildroot-2017.05-rc2/Makefile 2017-05-17 10:27:16.013401440 +0200
385 +++ buildroot-2017.05.2/Makefile 2017-07-27 08:16:52.017486944 +0200
386 @@ -86,9 +86,9 @@ else # umask / $(CURDIR) / $(O)
387 all:
389 # Set and export the version string
390 -export BR2_VERSION := 2017.05-rc2
391 +export BR2_VERSION := 2017.05.2
392 # Actual time the release is cut (for reproducible builds)
393 -BR2_VERSION_EPOCH = 1495000000
394 +BR2_VERSION_EPOCH = 1501136000
396 # Save running make version since it's clobbered by the make package
397 RUNNING_MAKE_VERSION := $(MAKE_VERSION)
398 diff -Naurp buildroot-2017.05-rc2/package/acpica/acpica.mk buildroot-2017.05.2/package/acpica/acpica.mk
399 --- buildroot-2017.05-rc2/package/acpica/acpica.mk 2017-05-17 10:27:16.013401440 +0200
400 +++ buildroot-2017.05.2/package/acpica/acpica.mk 2017-07-27 08:16:52.017486944 +0200
401 @@ -17,10 +17,22 @@ define ACPICA_BUILD_CMDS
403 endef
405 +define HOST_ACPICA_BUILD_CMDS
406 + $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
407 + all
408 +endef
410 define ACPICA_INSTALL_TARGET_CMDS
411 $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
412 HARDWARE_NAME=$(BR2_ARCH) DESTDIR="$(TARGET_DIR)" \
413 INSTALLFLAGS=-m755 install
414 endef
416 +define HOST_ACPICA_INSTALL_CMDS
417 + $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
418 + PREFIX="$(HOST_DIR)/usr" \
419 + INSTALLFLAGS=-m755 install
420 +endef
422 $(eval $(generic-package))
423 +$(eval $(host-generic-package))
424 diff -Naurp buildroot-2017.05-rc2/package/aespipe/aespipe.mk buildroot-2017.05.2/package/aespipe/aespipe.mk
425 --- buildroot-2017.05-rc2/package/aespipe/aespipe.mk 2017-05-17 10:27:16.013401440 +0200
426 +++ buildroot-2017.05.2/package/aespipe/aespipe.mk 2017-07-27 08:16:52.017486944 +0200
427 @@ -9,5 +9,15 @@ AESPIPE_SOURCE = aespipe-v$(AESPIPE_VERS
428 AESPIPE_SITE = http://loop-aes.sourceforge.net/aespipe
429 AESPIPE_LICENSE = GPL
431 +# Recent Debian, Gentoo and Ubuntu enable -fPIE by default, breaking the build:
432 +# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837393
433 +# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=835148
434 +# Older gcc versions however don't support the -no-pie flag, so we have to
435 +# check its availability.
436 +HOST_AESPIPE_NO_PIE_FLAG = $(call host-cc-option,-no-pie)
437 +HOST_AESPIPE_CONF_ENV = \
438 + CFLAGS="$(HOST_CFLAGS) $(HOST_AESPIPE_NO_PIE_FLAG)" \
439 + LDFLAGS="$(HOST_LDFLAGS) $(HOST_AESPIPE_NO_PIE_FLAG)"
441 $(eval $(autotools-package))
442 $(eval $(host-autotools-package))
443 diff -Naurp buildroot-2017.05-rc2/package/agentpp/Config.in buildroot-2017.05.2/package/agentpp/Config.in
444 --- buildroot-2017.05-rc2/package/agentpp/Config.in 2017-05-17 10:27:16.013401440 +0200
445 +++ buildroot-2017.05.2/package/agentpp/Config.in 2017-07-27 08:16:52.017486944 +0200
446 @@ -5,13 +5,14 @@ config BR2_PACKAGE_AGENTPP
447 depends on !BR2_STATIC_LIBS # snmp++
448 select BR2_PACKAGE_SNMPPP
449 help
450 - AGENT++ is a set of C++ classes which provides a complete protocol
451 - engine and dispatch table for the development of SNMP agents.
452 - AGENT++ is a multilingual API which supports SNMPv1, SNMPv2c, and
453 - SNMPv3. It provides various C++ classes implementing prototypes for
454 - scalar and table SNMP managed objects that can be customized by
455 - derivation. Additional classes support the development of proxy
456 - agents as well as sending notifications.
457 + AGENT++ is a set of C++ classes which provides a complete
458 + protocol engine and dispatch table for the development of
459 + SNMP agents. AGENT++ is a multilingual API which supports
460 + SNMPv1, SNMPv2c, and SNMPv3. It provides various C++ classes
461 + implementing prototypes for scalar and table SNMP managed
462 + objects that can be customized by derivation. Additional
463 + classes support the development of proxy agents as well as
464 + sending notifications.
466 SNMPv3 support is enabled if SNMP++ enables it.
468 diff -Naurp buildroot-2017.05-rc2/package/aiccu/Config.in buildroot-2017.05.2/package/aiccu/Config.in
469 --- buildroot-2017.05-rc2/package/aiccu/Config.in 2017-05-17 10:27:16.013401440 +0200
470 +++ buildroot-2017.05.2/package/aiccu/Config.in 2017-07-27 08:16:52.017486944 +0200
471 @@ -1,5 +1,6 @@
472 config BR2_PACKAGE_AICCU
473 bool "aiccu"
474 + depends on !BR2_STATIC_LIBS # gnutls
475 depends on BR2_USE_WCHAR
476 depends on BR2_TOOLCHAIN_HAS_THREADS
477 depends on BR2_USE_MMU # fork()
478 @@ -18,6 +19,7 @@ config BR2_PACKAGE_AICCU
480 http://www.sixxs.net/tools/aiccu/
482 -comment "aiccu needs a toolchain w/ wchar, threads"
483 +comment "aiccu needs a toolchain w/ wchar, threads, dynamic library"
484 depends on BR2_USE_MMU
485 - depends on !(BR2_USE_WCHAR && BR2_TOOLCHAIN_HAS_THREADS)
486 + depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS \
487 + || BR2_STATIC_LIBS
488 diff -Naurp buildroot-2017.05-rc2/package/apache/apache.hash buildroot-2017.05.2/package/apache/apache.hash
489 --- buildroot-2017.05-rc2/package/apache/apache.hash 2017-05-17 10:27:16.013401440 +0200
490 +++ buildroot-2017.05.2/package/apache/apache.hash 2017-07-27 08:16:52.017486944 +0200
491 @@ -1,2 +1,2 @@
492 -# From http://www.apache.org/dist/httpd/httpd-2.4.23.tar.bz2.sha1
493 -sha1 bd6d138c31c109297da2346c6e7b93b9283993d2 httpd-2.4.25.tar.bz2
494 +# From http://www.apache.org/dist/httpd/httpd-2.4.27.tar.bz2.sha256
495 +sha256 71fcc128238a690515bd8174d5330a5309161ef314a326ae45c7c15ed139c13a httpd-2.4.27.tar.bz2
496 diff -Naurp buildroot-2017.05-rc2/package/apache/apache.mk buildroot-2017.05.2/package/apache/apache.mk
497 --- buildroot-2017.05-rc2/package/apache/apache.mk 2017-05-17 10:27:16.013401440 +0200
498 +++ buildroot-2017.05.2/package/apache/apache.mk 2017-07-27 08:16:52.017486944 +0200
499 @@ -4,7 +4,7 @@
501 ################################################################################
503 -APACHE_VERSION = 2.4.25
504 +APACHE_VERSION = 2.4.27
505 APACHE_SOURCE = httpd-$(APACHE_VERSION).tar.bz2
506 APACHE_SITE = http://archive.apache.org/dist/httpd
507 APACHE_LICENSE = Apache-2.0
508 diff -Naurp buildroot-2017.05-rc2/package/armadillo/armadillo.mk buildroot-2017.05.2/package/armadillo/armadillo.mk
509 --- buildroot-2017.05-rc2/package/armadillo/armadillo.mk 2017-05-17 10:27:16.013401440 +0200
510 +++ buildroot-2017.05.2/package/armadillo/armadillo.mk 2017-07-27 08:16:52.017486944 +0200
511 @@ -5,7 +5,9 @@
512 ################################################################################
514 ARMADILLO_VERSION = 6.500.4
515 -ARMADILLO_SITE = http://downloads.sourceforge.net/project/arma
516 +# upstream removed tarball from
517 +# http://downloads.sourceforge.net/project/arma
518 +ARMADILLO_SITE = https://ftp.fau.de/macports/distfiles/armadillo
519 ARMADILLO_DEPENDENCIES = clapack
520 ARMADILLO_INSTALL_STAGING = YES
521 ARMADILLO_LICENSE = MPL-2.0
522 diff -Naurp buildroot-2017.05-rc2/package/audiofile/0008-CVE-2015-7747.patch buildroot-2017.05.2/package/audiofile/0008-CVE-2015-7747.patch
523 --- buildroot-2017.05-rc2/package/audiofile/0008-CVE-2015-7747.patch 1970-01-01 01:00:00.000000000 +0100
524 +++ buildroot-2017.05.2/package/audiofile/0008-CVE-2015-7747.patch 2017-07-27 08:16:52.017486944 +0200
525 @@ -0,0 +1,161 @@
526 +Description: fix buffer overflow when changing both sample format and
527 + number of channels
528 +Origin: https://github.com/mpruett/audiofile/pull/25
529 +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/audiofile/+bug/1502721
530 +Bug-Debian: https://bugs.debian.org/801102
532 +Downloaded from
533 +https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/audiofile/files/audiofile-0.3.6-CVE-2015-7747.patch
535 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
537 +--- a/libaudiofile/modules/ModuleState.cpp
538 ++++ b/libaudiofile/modules/ModuleState.cpp
539 +@@ -402,7 +402,7 @@ status ModuleState::arrange(AFfilehandle
540 + addModule(new Transform(outfc, in.pcm, out.pcm));
542 + if (in.channelCount != out.channelCount)
543 +- addModule(new ApplyChannelMatrix(infc, isReading,
544 ++ addModule(new ApplyChannelMatrix(outfc, isReading,
545 + in.channelCount, out.channelCount,
546 + in.pcm.minClip, in.pcm.maxClip,
547 + track->channelMatrix));
548 +--- a/test/Makefile.am
549 ++++ b/test/Makefile.am
550 +@@ -26,6 +26,7 @@ TESTS = \
551 + VirtualFile \
552 + floatto24 \
553 + query2 \
554 ++ sixteen-stereo-to-eight-mono \
555 + sixteen-to-eight \
556 + testchannelmatrix \
557 + testdouble \
558 +@@ -139,6 +140,7 @@ printmarkers_SOURCES = printmarkers.c
559 + printmarkers_LDADD = $(LIBAUDIOFILE) -lm
561 + sixteen_to_eight_SOURCES = sixteen-to-eight.c TestUtilities.cpp TestUtilities.h
562 ++sixteen_stereo_to_eight_mono_SOURCES = sixteen-stereo-to-eight-mono.c TestUtilities.cpp TestUtilities.h
564 + testchannelmatrix_SOURCES = testchannelmatrix.c TestUtilities.cpp TestUtilities.h
566 +--- /dev/null
567 ++++ b/test/sixteen-stereo-to-eight-mono.c
568 +@@ -0,0 +1,118 @@
569 ++/*
570 ++ Audio File Library
572 ++ Copyright 2000, Silicon Graphics, Inc.
574 ++ This program is free software; you can redistribute it and/or modify
575 ++ it under the terms of the GNU General Public License as published by
576 ++ the Free Software Foundation; either version 2 of the License, or
577 ++ (at your option) any later version.
579 ++ This program is distributed in the hope that it will be useful,
580 ++ but WITHOUT ANY WARRANTY; without even the implied warranty of
581 ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
582 ++ GNU General Public License for more details.
584 ++ You should have received a copy of the GNU General Public License along
585 ++ with this program; if not, write to the Free Software Foundation, Inc.,
586 ++ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
587 ++*/
589 ++/*
590 ++ sixteen-stereo-to-eight-mono.c
592 ++ This program tests the conversion from 2-channel 16-bit integers to
593 ++ 1-channel 8-bit integers.
594 ++*/
596 ++#ifdef HAVE_CONFIG_H
597 ++#include <config.h>
598 ++#endif
600 ++#include <stdint.h>
601 ++#include <stdio.h>
602 ++#include <stdlib.h>
603 ++#include <string.h>
604 ++#include <unistd.h>
605 ++#include <limits.h>
607 ++#include <audiofile.h>
609 ++#include "TestUtilities.h"
611 ++int main (int argc, char **argv)
613 ++ AFfilehandle file;
614 ++ AFfilesetup setup;
615 ++ int16_t frames16[] = {14298, 392, 3923, -683, 958, -1921};
616 ++ int8_t frames8[] = {28, 6, -2};
617 ++ int i, frameCount = 3;
618 ++ int8_t byte;
619 ++ AFframecount result;
621 ++ setup = afNewFileSetup();
623 ++ afInitFileFormat(setup, AF_FILE_WAVE);
625 ++ afInitSampleFormat(setup, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 16);
626 ++ afInitChannels(setup, AF_DEFAULT_TRACK, 2);
628 ++ char *testFileName;
629 ++ if (!createTemporaryFile("sixteen-to-eight", &testFileName))
630 ++ {
631 ++ fprintf(stderr, "Could not create temporary file.\n");
632 ++ exit(EXIT_FAILURE);
633 ++ }
635 ++ file = afOpenFile(testFileName, "w", setup);
636 ++ if (file == AF_NULL_FILEHANDLE)
637 ++ {
638 ++ fprintf(stderr, "could not open file for writing\n");
639 ++ exit(EXIT_FAILURE);
640 ++ }
642 ++ afFreeFileSetup(setup);
644 ++ afWriteFrames(file, AF_DEFAULT_TRACK, frames16, frameCount);
646 ++ afCloseFile(file);
648 ++ file = afOpenFile(testFileName, "r", AF_NULL_FILESETUP);
649 ++ if (file == AF_NULL_FILEHANDLE)
650 ++ {
651 ++ fprintf(stderr, "could not open file for reading\n");
652 ++ exit(EXIT_FAILURE);
653 ++ }
655 ++ afSetVirtualSampleFormat(file, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 8);
656 ++ afSetVirtualChannels(file, AF_DEFAULT_TRACK, 1);
658 ++ for (i=0; i<frameCount; i++)
659 ++ {
660 ++ /* Read one frame. */
661 ++ result = afReadFrames(file, AF_DEFAULT_TRACK, &byte, 1);
663 ++ if (result != 1)
664 ++ break;
666 ++ /* Compare the byte read with its precalculated value. */
667 ++ if (memcmp(&byte, &frames8[i], 1) != 0)
668 ++ {
669 ++ printf("error\n");
670 ++ printf("expected %d, got %d\n", frames8[i], byte);
671 ++ exit(EXIT_FAILURE);
672 ++ }
673 ++ else
674 ++ {
675 ++#ifdef DEBUG
676 ++ printf("got what was expected: %d\n", byte);
677 ++#endif
678 ++ }
679 ++ }
681 ++ afCloseFile(file);
682 ++ unlink(testFileName);
683 ++ free(testFileName);
685 ++ exit(EXIT_SUCCESS);
687 diff -Naurp buildroot-2017.05-rc2/package/audiofile/0009-Fix-static-linking-with-libsndfile.patch buildroot-2017.05.2/package/audiofile/0009-Fix-static-linking-with-libsndfile.patch
688 --- buildroot-2017.05-rc2/package/audiofile/0009-Fix-static-linking-with-libsndfile.patch 1970-01-01 01:00:00.000000000 +0100
689 +++ buildroot-2017.05.2/package/audiofile/0009-Fix-static-linking-with-libsndfile.patch 2017-07-27 08:16:52.017486944 +0200
690 @@ -0,0 +1,193 @@
691 +From d89a938f48e97b5770509d53c5478c5c3008d6e8 Mon Sep 17 00:00:00 2001
692 +From: Bernd Kuhls <bernd.kuhls@t-online.de>
693 +Date: Sat, 27 May 2017 17:53:33 +0200
694 +Subject: [PATCH 1/1] Fix static linking with libsndfile
696 +libsndfile and audiofile both contain mixXX functions in their alac
697 +code which lead to symbol name clashes when apps like mpd try to
698 +statically link to both audiofile and libsndfile at the same time.
700 +This patch renames these functions to avoid the problem which was
701 +detected by the buildroot autobuilders:
702 +http://autobuild.buildroot.net/results/799/7997ccd698f03885f98d00bd150dc3a578e4b161/
704 +Patch sent upstream: https://github.com/mpruett/audiofile/pull/45
706 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
707 +---
708 + libaudiofile/alac/ALACEncoder.cpp | 28 ++++++++++++++--------------
709 + libaudiofile/alac/matrix_enc.c | 8 ++++----
710 + libaudiofile/alac/matrixlib.h | 8 ++++----
711 + 3 files changed, 22 insertions(+), 22 deletions(-)
713 +diff --git a/libaudiofile/alac/ALACEncoder.cpp b/libaudiofile/alac/ALACEncoder.cpp
714 +index da922c2..3d088cc 100644
715 +--- a/libaudiofile/alac/ALACEncoder.cpp
716 ++++ b/libaudiofile/alac/ALACEncoder.cpp
717 +@@ -332,19 +332,19 @@ int32_t ALACEncoder::EncodeStereo( BitBuffer * bitstream, void * inputBuffer, ui
718 + switch ( mBitDepth )
720 + case 16:
721 +- mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate, mixBits, mixRes );
722 ++ audiofile_alac_mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate, mixBits, mixRes );
723 + break;
724 + case 20:
725 +- mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate, mixBits, mixRes );
726 ++ audiofile_alac_mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate, mixBits, mixRes );
727 + break;
728 + case 24:
729 + // includes extraction of shifted-off bytes
730 +- mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate,
731 ++ audiofile_alac_mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate,
732 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
733 + break;
734 + case 32:
735 + // includes extraction of shifted-off bytes
736 +- mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate,
737 ++ audiofile_alac_mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples/dilate,
738 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
739 + break;
741 +@@ -379,19 +379,19 @@ int32_t ALACEncoder::EncodeStereo( BitBuffer * bitstream, void * inputBuffer, ui
742 + switch ( mBitDepth )
744 + case 16:
745 +- mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
746 ++ audiofile_alac_mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
747 + break;
748 + case 20:
749 +- mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
750 ++ audiofile_alac_mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
751 + break;
752 + case 24:
753 + // also extracts the shifted off bytes into the shift buffers
754 +- mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
755 ++ audiofile_alac_mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
756 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
757 + break;
758 + case 32:
759 + // also extracts the shifted off bytes into the shift buffers
760 +- mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
761 ++ audiofile_alac_mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
762 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
763 + break;
765 +@@ -605,19 +605,19 @@ int32_t ALACEncoder::EncodeStereoFast( BitBuffer * bitstream, void * inputBuffer
766 + switch ( mBitDepth )
768 + case 16:
769 +- mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
770 ++ audiofile_alac_mix16( (int16_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
771 + break;
772 + case 20:
773 +- mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
774 ++ audiofile_alac_mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, mixBits, mixRes );
775 + break;
776 + case 24:
777 + // also extracts the shifted off bytes into the shift buffers
778 +- mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
779 ++ audiofile_alac_mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
780 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
781 + break;
782 + case 32:
783 + // also extracts the shifted off bytes into the shift buffers
784 +- mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
785 ++ audiofile_alac_mix32( (int32_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples,
786 + mixBits, mixRes, mShiftBufferUV, bytesShifted );
787 + break;
789 +@@ -756,7 +756,7 @@ int32_t ALACEncoder::EncodeStereoEscape( BitBuffer * bitstream, void * inputBuff
790 + break;
791 + case 20:
792 + // mix20() with mixres param = 0 means de-interleave so use it to simplify things
793 +- mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, 0, 0 );
794 ++ audiofile_alac_mix20( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, 0, 0 );
795 + for ( index = 0; index < numSamples; index++ )
797 + BitBufferWrite( bitstream, mMixBufferU[index], 20 );
798 +@@ -765,7 +765,7 @@ int32_t ALACEncoder::EncodeStereoEscape( BitBuffer * bitstream, void * inputBuff
799 + break;
800 + case 24:
801 + // mix24() with mixres param = 0 means de-interleave so use it to simplify things
802 +- mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, 0, 0, mShiftBufferUV, 0 );
803 ++ audiofile_alac_mix24( (uint8_t *) inputBuffer, stride, mMixBufferU, mMixBufferV, numSamples, 0, 0, mShiftBufferUV, 0 );
804 + for ( index = 0; index < numSamples; index++ )
806 + BitBufferWrite( bitstream, mMixBufferU[index], 24 );
807 +diff --git a/libaudiofile/alac/matrix_enc.c b/libaudiofile/alac/matrix_enc.c
808 +index e194330..8abd556 100644
809 +--- a/libaudiofile/alac/matrix_enc.c
810 ++++ b/libaudiofile/alac/matrix_enc.c
811 +@@ -57,7 +57,7 @@
813 + // 16-bit routines
815 +-void mix16( int16_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres )
816 ++void audiofile_alac_mix16( int16_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres )
818 + int16_t * ip = in;
819 + int32_t j;
820 +@@ -95,7 +95,7 @@ void mix16( int16_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t num
821 + // 20-bit routines
822 + // - the 20 bits of data are left-justified in 3 bytes of storage but right-aligned for input/output predictor buffers
824 +-void mix20( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres )
825 ++void audiofile_alac_mix20( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres )
827 + int32_t l, r;
828 + uint8_t * ip = in;
829 +@@ -140,7 +140,7 @@ void mix20( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t num
830 + // 24-bit routines
831 + // - the 24 bits of data are right-justified in the input/output predictor buffers
833 +-void mix24( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
834 ++void audiofile_alac_mix24( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
835 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted )
836 + {
837 + int32_t l, r;
838 +@@ -240,7 +240,7 @@ void mix24( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t num
839 + // - otherwise, the calculations might overflow into the 33rd bit and be lost
840 + // - therefore, these routines deal with the specified "unused lower" bytes in the "shift" buffers
842 +-void mix32( int32_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
843 ++void audiofile_alac_mix32( int32_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
844 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted )
846 + int32_t * ip = in;
847 +diff --git a/libaudiofile/alac/matrixlib.h b/libaudiofile/alac/matrixlib.h
848 +index 0a4f371..5728b6d 100644
849 +--- a/libaudiofile/alac/matrixlib.h
850 ++++ b/libaudiofile/alac/matrixlib.h
851 +@@ -38,17 +38,17 @@ extern "C" {
852 + #endif
854 + // 16-bit routines
855 +-void mix16( int16_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres );
856 ++void audiofile_alac_mix16( int16_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres );
857 + void unmix16( int32_t * u, int32_t * v, int16_t * out, uint32_t stride, int32_t numSamples, int32_t mixbits, int32_t mixres );
859 + // 20-bit routines
860 +-void mix20( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres );
861 ++void audiofile_alac_mix20( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples, int32_t mixbits, int32_t mixres );
862 + void unmix20( int32_t * u, int32_t * v, uint8_t * out, uint32_t stride, int32_t numSamples, int32_t mixbits, int32_t mixres );
864 + // 24-bit routines
865 + // - 24-bit data sometimes compresses better by shifting off the bottom byte so these routines deal with
866 + // the specified "unused lower bytes" in the combined "shift" buffer
867 +-void mix24( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
868 ++void audiofile_alac_mix24( uint8_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
869 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted );
870 + void unmix24( int32_t * u, int32_t * v, uint8_t * out, uint32_t stride, int32_t numSamples,
871 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted );
872 +@@ -57,7 +57,7 @@ void unmix24( int32_t * u, int32_t * v, uint8_t * out, uint32_t stride, int32_t
873 + // - note that these really expect the internal data width to be < 32-bit but the arrays are 32-bit
874 + // - otherwise, the calculations might overflow into the 33rd bit and be lost
875 + // - therefore, these routines deal with the specified "unused lower" bytes in the combined "shift" buffer
876 +-void mix32( int32_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
877 ++void audiofile_alac_mix32( int32_t * in, uint32_t stride, int32_t * u, int32_t * v, int32_t numSamples,
878 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted );
879 + void unmix32( int32_t * u, int32_t * v, int32_t * out, uint32_t stride, int32_t numSamples,
880 + int32_t mixbits, int32_t mixres, uint16_t * shiftUV, int32_t bytesShifted );
881 +--
882 +2.11.0
884 diff -Naurp buildroot-2017.05-rc2/package/bash/bash.mk buildroot-2017.05.2/package/bash/bash.mk
885 --- buildroot-2017.05-rc2/package/bash/bash.mk 2017-05-17 10:27:16.013401440 +0200
886 +++ buildroot-2017.05.2/package/bash/bash.mk 2017-07-27 08:16:52.017486944 +0200
887 @@ -9,7 +9,7 @@ BASH_SITE = $(BR2_GNU_MIRROR)/bash
888 # Build after since bash is better than busybox shells
889 BASH_DEPENDENCIES = ncurses readline host-bison \
890 $(if $(BR2_PACKAGE_BUSYBOX),busybox)
891 -BASH_CONF_OPTS = --with-installed-readline
892 +BASH_CONF_OPTS = --with-installed-readline --without-bash-malloc
893 BASH_LICENSE = GPL-3.0+
894 BASH_LICENSE_FILES = COPYING
896 @@ -24,7 +24,7 @@ BASH_CONF_ENV += \
898 # The static build needs some trickery
899 ifeq ($(BR2_STATIC_LIBS),y)
900 -BASH_CONF_OPTS += --enable-static-link --without-bash-malloc
901 +BASH_CONF_OPTS += --enable-static-link
902 # bash wants to redefine the getenv() function. To check whether this is
903 # possible, AC_TRY_RUN is used which is not possible in
904 # cross-compilation.
905 diff -Naurp buildroot-2017.05-rc2/package/bind/bind.hash buildroot-2017.05.2/package/bind/bind.hash
906 --- buildroot-2017.05-rc2/package/bind/bind.hash 2017-05-17 10:27:16.013401440 +0200
907 +++ buildroot-2017.05.2/package/bind/bind.hash 2017-07-27 08:16:52.017486944 +0200
908 @@ -1,2 +1,3 @@
909 -# Verified from http://ftp.isc.org/isc/bind9/9.11.1/bind-9.11.1.tar.gz.sha256.asc
910 -sha256 22050095f5c82a1385cc4174190ac60392670bbc5d63d592ecae52a214bc10b2 bind-9.11.1.tar.gz
911 +# Verified from http://ftp.isc.org/isc/bind9/9.11.1-P3/bind-9.11.1-P3.tar.gz.sha256.asc
912 +sha256 52426e75432e46996dc90f24fca027805a341c38fbbb022b60dc9acd2677ccf4 bind-9.11.1-P3.tar.gz
913 +sha256 d3906dfe153e2c48440d3ca1d5319f5e89b4b820cdfc5d0779c23d7ac2b175e9 COPYRIGHT
914 diff -Naurp buildroot-2017.05-rc2/package/bind/bind.mk buildroot-2017.05.2/package/bind/bind.mk
915 --- buildroot-2017.05-rc2/package/bind/bind.mk 2017-05-17 10:27:16.013401440 +0200
916 +++ buildroot-2017.05.2/package/bind/bind.mk 2017-07-27 08:16:52.017486944 +0200
917 @@ -4,7 +4,7 @@
919 ################################################################################
921 -BIND_VERSION = 9.11.1
922 +BIND_VERSION = 9.11.1-P3
923 BIND_SITE = ftp://ftp.isc.org/isc/bind9/$(BIND_VERSION)
924 # bind does not support parallel builds.
925 BIND_MAKE = $(MAKE1)
926 diff -Naurp buildroot-2017.05-rc2/package/binutils/2.27/0907-Automatically-enable-CRC-instructions-on-supported-A.patch buildroot-2017.05.2/package/binutils/2.27/0907-Automatically-enable-CRC-instructions-on-supported-A.patch
927 --- buildroot-2017.05-rc2/package/binutils/2.27/0907-Automatically-enable-CRC-instructions-on-supported-A.patch 1970-01-01 01:00:00.000000000 +0100
928 +++ buildroot-2017.05.2/package/binutils/2.27/0907-Automatically-enable-CRC-instructions-on-supported-A.patch 2017-07-27 08:16:52.017486944 +0200
929 @@ -0,0 +1,88 @@
930 +From 29a4659015ca7044c2d425d32a0b828e0fbb5ac1 Mon Sep 17 00:00:00 2001
931 +From: Richard Earnshaw <Richard.Earnshaw@arm.com>
932 +Date: Wed, 7 Sep 2016 17:14:54 +0100
933 +Subject: [PATCH] Automatically enable CRC instructions on supported ARMv8-A
934 + CPUs.
936 +2016-09-07 Richard Earnshaw <rearnsha@arm.com>
938 + * opcode/arm.h (ARM_ARCH_V8A_CRC): New architecture.
940 +2016-09-07 Richard Earnshaw <rearnsha@arm.com>
942 + * config/tc-arm.c ((arm_cpus): Use ARM_ARCH_V8A_CRC for all
943 + ARMv8-A CPUs except xgene1.
945 +Upstream: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=patch;h=27e5a270962fb92c07e7d476966ba380fa3bb68e
946 +Signed-off-by: Peter Seiderer <ps.report@gmx.net>
947 +---
948 + gas/config/tc-arm.c | 18 +++++++++---------
949 + include/opcode/arm.h | 2 ++
950 + 2 files changed, 11 insertions(+), 9 deletions(-)
952 +diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
953 +index 73d05316..7c86184d 100644
954 +--- a/gas/config/tc-arm.c
955 ++++ b/gas/config/tc-arm.c
956 +@@ -25332,17 +25332,17 @@ static const struct arm_cpu_option_table arm_cpus[] =
957 + "Cortex-A15"),
958 + ARM_CPU_OPT ("cortex-a17", ARM_ARCH_V7VE, FPU_ARCH_NEON_VFP_V4,
959 + "Cortex-A17"),
960 +- ARM_CPU_OPT ("cortex-a32", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
961 ++ ARM_CPU_OPT ("cortex-a32", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
962 + "Cortex-A32"),
963 +- ARM_CPU_OPT ("cortex-a35", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
964 ++ ARM_CPU_OPT ("cortex-a35", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
965 + "Cortex-A35"),
966 +- ARM_CPU_OPT ("cortex-a53", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
967 ++ ARM_CPU_OPT ("cortex-a53", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
968 + "Cortex-A53"),
969 +- ARM_CPU_OPT ("cortex-a57", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
970 ++ ARM_CPU_OPT ("cortex-a57", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
971 + "Cortex-A57"),
972 +- ARM_CPU_OPT ("cortex-a72", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
973 ++ ARM_CPU_OPT ("cortex-a72", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
974 + "Cortex-A72"),
975 +- ARM_CPU_OPT ("cortex-a73", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
976 ++ ARM_CPU_OPT ("cortex-a73", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
977 + "Cortex-A73"),
978 + ARM_CPU_OPT ("cortex-r4", ARM_ARCH_V7R, FPU_NONE, "Cortex-R4"),
979 + ARM_CPU_OPT ("cortex-r4f", ARM_ARCH_V7R, FPU_ARCH_VFP_V3D16,
980 +@@ -25361,10 +25361,10 @@ static const struct arm_cpu_option_table arm_cpus[] =
981 + ARM_CPU_OPT ("cortex-m1", ARM_ARCH_V6SM, FPU_NONE, "Cortex-M1"),
982 + ARM_CPU_OPT ("cortex-m0", ARM_ARCH_V6SM, FPU_NONE, "Cortex-M0"),
983 + ARM_CPU_OPT ("cortex-m0plus", ARM_ARCH_V6SM, FPU_NONE, "Cortex-M0+"),
984 +- ARM_CPU_OPT ("exynos-m1", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
985 ++ ARM_CPU_OPT ("exynos-m1", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
986 + "Samsung " \
987 + "Exynos M1"),
988 +- ARM_CPU_OPT ("qdf24xx", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
989 ++ ARM_CPU_OPT ("qdf24xx", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
990 + "Qualcomm "
991 + "QDF24XX"),
993 +@@ -25389,7 +25389,7 @@ static const struct arm_cpu_option_table arm_cpus[] =
994 + /* APM X-Gene family. */
995 + ARM_CPU_OPT ("xgene1", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
996 + "APM X-Gene 1"),
997 +- ARM_CPU_OPT ("xgene2", ARM_ARCH_V8A, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
998 ++ ARM_CPU_OPT ("xgene2", ARM_ARCH_V8A_CRC, FPU_ARCH_CRYPTO_NEON_VFP_ARMV8,
999 + "APM X-Gene 2"),
1001 + { NULL, 0, ARM_ARCH_NONE, ARM_ARCH_NONE, NULL }
1002 +diff --git a/include/opcode/arm.h b/include/opcode/arm.h
1003 +index 60715cf8..feace5cd 100644
1004 +--- a/include/opcode/arm.h
1005 ++++ b/include/opcode/arm.h
1006 +@@ -263,6 +263,8 @@
1007 + #define ARM_ARCH_V7M ARM_FEATURE_CORE (ARM_AEXT_V7M, ARM_EXT2_V6T2_V8M)
1008 + #define ARM_ARCH_V7EM ARM_FEATURE_CORE (ARM_AEXT_V7EM, ARM_EXT2_V6T2_V8M)
1009 + #define ARM_ARCH_V8A ARM_FEATURE_CORE (ARM_AEXT_V8A, ARM_AEXT2_V8A)
1010 ++#define ARM_ARCH_V8A_CRC ARM_FEATURE (ARM_AEXT_V8A, ARM_AEXT2_V8A, \
1011 ++ CRC_EXT_ARMV8)
1012 + #define ARM_ARCH_V8_1A ARM_FEATURE (ARM_AEXT_V8A, ARM_AEXT2_V8_1A, \
1013 + CRC_EXT_ARMV8 | FPU_NEON_EXT_RDMA)
1014 + #define ARM_ARCH_V8_2A ARM_FEATURE (ARM_AEXT_V8A, ARM_AEXT2_V8_2A, \
1015 +--
1016 +2.11.0
1018 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03/0300-PATCH-ld-makefile.patch buildroot-2017.05.2/package/binutils/arc-2017.03/0300-PATCH-ld-makefile.patch
1019 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03/0300-PATCH-ld-makefile.patch 1970-01-01 01:00:00.000000000 +0100
1020 +++ buildroot-2017.05.2/package/binutils/arc-2017.03/0300-PATCH-ld-makefile.patch 2017-07-27 08:16:52.017486944 +0200
1021 @@ -0,0 +1,41 @@
1022 +From 32078014f734430e1c68fe40aaf970b9805ecaf5 Mon Sep 17 00:00:00 2001
1023 +From: Romain Naour <romain.naour@gmail.com>
1024 +Date: Fri, 21 Apr 2017 21:19:13 +0300
1025 +Subject: [PATCH] ld-makefile
1027 +[Romain: rebase on top of 2.26]
1028 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
1029 +---
1030 + ld/Makefile.am | 2 +-
1031 + ld/Makefile.in | 2 +-
1032 + 2 files changed, 2 insertions(+), 2 deletions(-)
1034 +diff --git a/ld/Makefile.am b/ld/Makefile.am
1035 +index 9dd31ff..553a107 100644
1036 +--- a/ld/Makefile.am
1037 ++++ b/ld/Makefile.am
1038 +@@ -57,7 +57,7 @@ endif
1039 + # We put the scripts in the directory $(scriptdir)/ldscripts.
1040 + # We can't put the scripts in $(datadir) because the SEARCH_DIR
1041 + # directives need to be different for native and cross linkers.
1042 +-scriptdir = $(tooldir)/lib
1043 ++scriptdir = $(libdir)
1045 + EMUL = @EMUL@
1046 + EMULATION_OFILES = @EMULATION_OFILES@
1047 +diff --git a/ld/Makefile.in b/ld/Makefile.in
1048 +index c464302..feb34ba 100644
1049 +--- a/ld/Makefile.in
1050 ++++ b/ld/Makefile.in
1051 +@@ -446,7 +446,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
1052 + # We put the scripts in the directory $(scriptdir)/ldscripts.
1053 + # We can't put the scripts in $(datadir) because the SEARCH_DIR
1054 + # directives need to be different for native and cross linkers.
1055 +-scriptdir = $(tooldir)/lib
1056 ++scriptdir = $(libdir)
1057 + BASEDIR = $(srcdir)/..
1058 + BFDDIR = $(BASEDIR)/bfd
1059 + INCDIR = $(BASEDIR)/include
1060 +--
1061 +2.7.4
1063 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03/0301-PATCH-check-ldrunpath-length.patch buildroot-2017.05.2/package/binutils/arc-2017.03/0301-PATCH-check-ldrunpath-length.patch
1064 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03/0301-PATCH-check-ldrunpath-length.patch 1970-01-01 01:00:00.000000000 +0100
1065 +++ buildroot-2017.05.2/package/binutils/arc-2017.03/0301-PATCH-check-ldrunpath-length.patch 2017-07-27 08:16:52.017486944 +0200
1066 @@ -0,0 +1,36 @@
1067 +From 4a5a8b983fb31a67f976e0dd9cf5e8580ef55098 Mon Sep 17 00:00:00 2001
1068 +From: Romain Naour <romain.naour@gmail.com>
1069 +Date: Fri, 21 Apr 2017 21:23:55 +0300
1070 +Subject: [PATCH] check-ldrunpath-length
1072 +[Romain: rebase on top of 2.26]
1073 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
1074 +---
1075 + ld/emultempl/elf32.em | 4 ++++
1076 + 1 file changed, 4 insertions(+)
1078 +diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
1079 +index d4837d0..937da8a 100644
1080 +--- a/ld/emultempl/elf32.em
1081 ++++ b/ld/emultempl/elf32.em
1082 +@@ -1460,6 +1460,8 @@ fragment <<EOF
1083 + && command_line.rpath == NULL)
1085 + path = (const char *) getenv ("LD_RUN_PATH");
1086 ++ if ((path) && (strlen (path) == 0))
1087 ++ path = NULL;
1088 + if (path
1089 + && gld${EMULATION_NAME}_search_needed (path, &n, force))
1090 + break;
1091 +@@ -1737,6 +1739,8 @@ gld${EMULATION_NAME}_before_allocation (void)
1092 + rpath = command_line.rpath;
1093 + if (rpath == NULL)
1094 + rpath = (const char *) getenv ("LD_RUN_PATH");
1095 ++ if ((rpath) && (strlen (rpath) == 0))
1096 ++ rpath = NULL;
1098 + for (abfd = link_info.input_bfds; abfd; abfd = abfd->link.next)
1099 + if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
1100 +--
1101 +2.7.4
1103 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03/0500-add-sysroot-fix-from-bug-3049.patch buildroot-2017.05.2/package/binutils/arc-2017.03/0500-add-sysroot-fix-from-bug-3049.patch
1104 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03/0500-add-sysroot-fix-from-bug-3049.patch 1970-01-01 01:00:00.000000000 +0100
1105 +++ buildroot-2017.05.2/package/binutils/arc-2017.03/0500-add-sysroot-fix-from-bug-3049.patch 2017-07-27 08:16:52.017486944 +0200
1106 @@ -0,0 +1,48 @@
1107 +From 30628870e583375f8927c04398c7219c6e9f703c Mon Sep 17 00:00:00 2001
1108 +From: Romain Naour <romain.naour@gmail.com>
1109 +Date: Fri, 25 Dec 2015 11:42:48 +0100
1110 +Subject: [PATCH] add sysroot fix from bug #3049
1112 +Always try to prepend the sysroot prefix to absolute filenames first.
1114 +http://bugs.gentoo.org/275666
1115 +http://sourceware.org/bugzilla/show_bug.cgi?id=10340
1117 +Signed-off-by: Sven Rebhan <odinshorse@googlemail.com>
1118 +[Romain: rebase on top of 2.26]
1119 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
1120 +---
1121 + ld/ldfile.c | 11 +++++++++--
1122 + 1 file changed, 9 insertions(+), 2 deletions(-)
1124 +diff --git a/ld/ldfile.c diff --git b/ld/ldfile.c
1125 +--- a/ld/ldfile.c 2017-03-02 03:23:54.000000000 -0500
1126 ++++ b/ld/ldfile.c 2017-03-20 09:52:27.687415942 -0400
1127 +@@ -336,18 +336,24 @@
1128 + directory first. */
1129 + if (!entry->flags.maybe_archive)
1131 +- if (entry->flags.sysrooted && IS_ABSOLUTE_PATH (entry->filename))
1132 ++ /* For absolute pathnames, try to always open the file in the
1133 ++ sysroot first. If this fails, try to open the file at the
1134 ++ given location. */
1135 ++ entry->flags.sysrooted = is_sysrooted_pathname (entry->filename);
1136 ++ if (!entry->flags.sysrooted && IS_ABSOLUTE_PATH (entry->filename)
1137 ++ && ld_sysroot)
1139 + char *name = concat (ld_sysroot, entry->filename,
1140 + (const char *) NULL);
1141 + if (ldfile_try_open_bfd (name, entry))
1143 + entry->filename = name;
1144 ++ entry->flags.sysrooted = TRUE;
1145 + return TRUE;
1147 + free (name);
1149 +- else if (ldfile_try_open_bfd (entry->filename, entry))
1150 ++ if (ldfile_try_open_bfd (entry->filename, entry))
1151 + return TRUE;
1153 + if (IS_ABSOLUTE_PATH (entry->filename))
1155 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03/0600-poison-system-directories.patch buildroot-2017.05.2/package/binutils/arc-2017.03/0600-poison-system-directories.patch
1156 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03/0600-poison-system-directories.patch 1970-01-01 01:00:00.000000000 +0100
1157 +++ buildroot-2017.05.2/package/binutils/arc-2017.03/0600-poison-system-directories.patch 2017-07-27 08:16:52.017486944 +0200
1158 @@ -0,0 +1,306 @@
1159 +From be366461dd49e760440fb28eaee5164eb281adcc Mon Sep 17 00:00:00 2001
1160 +From: Romain Naour <romain.naour@gmail.com>
1161 +Date: Fri, 25 Dec 2015 11:45:38 +0100
1162 +Subject: [PATCH] poison-system-directories
1164 +Patch adapted to binutils 2.23.2 and extended to use
1165 +BR_COMPILER_PARANOID_UNSAFE_PATH by Thomas Petazzoni.
1167 +[Romain: rebase on top of 2.26]
1168 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
1169 +[Gustavo: adapt to binutils 2.25]
1170 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
1171 +Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
1173 +Upstream-Status: Inappropriate [distribution: codesourcery]
1175 +Patch originally created by Mark Hatle, forward-ported to
1176 +binutils 2.21 by Scott Garman.
1178 +purpose: warn for uses of system directories when cross linking
1180 +Code Merged from Sourcery G++ binutils 2.19 - 4.4-277
1182 +2008-07-02 Joseph Myers <joseph@codesourcery.com>
1184 + ld/
1185 + * ld.h (args_type): Add error_poison_system_directories.
1186 + * ld.texinfo (--error-poison-system-directories): Document.
1187 + * ldfile.c (ldfile_add_library_path): Check
1188 + command_line.error_poison_system_directories.
1189 + * ldmain.c (main): Initialize
1190 + command_line.error_poison_system_directories.
1191 + * lexsup.c (enum option_values): Add
1192 + OPTION_ERROR_POISON_SYSTEM_DIRECTORIES.
1193 + (ld_options): Add --error-poison-system-directories.
1194 + (parse_args): Handle new option.
1196 +2007-06-13 Joseph Myers <joseph@codesourcery.com>
1198 + ld/
1199 + * config.in: Regenerate.
1200 + * ld.h (args_type): Add poison_system_directories.
1201 + * ld.texinfo (--no-poison-system-directories): Document.
1202 + * ldfile.c (ldfile_add_library_path): Check
1203 + command_line.poison_system_directories.
1204 + * ldmain.c (main): Initialize
1205 + command_line.poison_system_directories.
1206 + * lexsup.c (enum option_values): Add
1207 + OPTION_NO_POISON_SYSTEM_DIRECTORIES.
1208 + (ld_options): Add --no-poison-system-directories.
1209 + (parse_args): Handle new option.
1211 +2007-04-20 Joseph Myers <joseph@codesourcery.com>
1213 + Merge from Sourcery G++ binutils 2.17:
1215 + 2007-03-20 Joseph Myers <joseph@codesourcery.com>
1216 + Based on patch by Mark Hatle <mark.hatle@windriver.com>.
1217 + ld/
1218 + * configure.ac (--enable-poison-system-directories): New option.
1219 + * configure, config.in: Regenerate.
1220 + * ldfile.c (ldfile_add_library_path): If
1221 + ENABLE_POISON_SYSTEM_DIRECTORIES defined, warn for use of /lib,
1222 + /usr/lib, /usr/local/lib or /usr/X11R6/lib.
1224 +Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
1225 +Signed-off-by: Scott Garman <scott.a.garman@intel.com>
1226 +---
1227 + ld/config.in | 3 +++
1228 + ld/configure | 14 ++++++++++++++
1229 + ld/configure.ac | 10 ++++++++++
1230 + ld/ld.h | 8 ++++++++
1231 + ld/ld.texinfo | 12 ++++++++++++
1232 + ld/ldfile.c | 17 +++++++++++++++++
1233 + ld/ldlex.h | 2 ++
1234 + ld/ldmain.c | 2 ++
1235 + ld/lexsup.c | 21 +++++++++++++++++++++
1236 + 9 files changed, 89 insertions(+)
1238 +diff --git a/ld/config.in b/ld/config.in
1239 +index 276fb77..35c58eb 100644
1240 +--- a/ld/config.in
1241 ++++ b/ld/config.in
1242 +@@ -17,6 +17,9 @@
1243 + language is requested. */
1244 + #undef ENABLE_NLS
1246 ++/* Define to warn for use of native system library directories */
1247 ++#undef ENABLE_POISON_SYSTEM_DIRECTORIES
1249 + /* Additional extension a shared object might have. */
1250 + #undef EXTRA_SHLIB_EXTENSION
1252 +diff --git a/ld/configure b/ld/configure
1253 +index a446283..d1f9504 100755
1254 +--- a/ld/configure
1255 ++++ b/ld/configure
1256 +@@ -789,6 +789,7 @@ with_lib_path
1257 + enable_targets
1258 + enable_64_bit_bfd
1259 + with_sysroot
1260 ++enable_poison_system_directories
1261 + enable_gold
1262 + enable_got
1263 + enable_compressed_debug_sections
1264 +@@ -1446,6 +1447,8 @@ Optional Features:
1265 + --disable-largefile omit support for large files
1266 + --enable-targets alternative target configurations
1267 + --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
1268 ++ --enable-poison-system-directories
1269 ++ warn for use of native system library directories
1270 + --enable-gold[=ARG] build gold [ARG={default,yes,no}]
1271 + --enable-got=<type> GOT handling scheme (target, single, negative,
1272 + multigot)
1273 +@@ -15499,7 +15502,18 @@ else
1274 + fi
1277 ++# Check whether --enable-poison-system-directories was given.
1278 ++if test "${enable_poison_system_directories+set}" = set; then :
1279 ++ enableval=$enable_poison_system_directories;
1280 ++else
1281 ++ enable_poison_system_directories=no
1282 ++fi
1284 ++if test "x${enable_poison_system_directories}" = "xyes"; then
1286 ++$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
1288 ++fi
1290 + # Check whether --enable-got was given.
1291 + if test "${enable_got+set}" = set; then :
1292 +diff --git a/ld/configure.ac b/ld/configure.ac
1293 +index 188172d..2cd8443 100644
1294 +--- a/ld/configure.ac
1295 ++++ b/ld/configure.ac
1296 +@@ -95,6 +95,16 @@ AC_SUBST(use_sysroot)
1297 + AC_SUBST(TARGET_SYSTEM_ROOT)
1298 + AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
1300 ++AC_ARG_ENABLE([poison-system-directories],
1301 ++ AS_HELP_STRING([--enable-poison-system-directories],
1302 ++ [warn for use of native system library directories]),,
1303 ++ [enable_poison_system_directories=no])
1304 ++if test "x${enable_poison_system_directories}" = "xyes"; then
1305 ++ AC_DEFINE([ENABLE_POISON_SYSTEM_DIRECTORIES],
1306 ++ [1],
1307 ++ [Define to warn for use of native system library directories])
1308 ++fi
1310 + dnl Use --enable-gold to decide if this linker should be the default.
1311 + dnl "install_as_default" is set to false if gold is the default linker.
1312 + dnl "installed_linker" is the installed BFD linker name.
1313 +diff --git a/ld/ld.h b/ld/ld.h
1314 +index d84ec4e..3476b26 100644
1315 +--- a/ld/ld.h
1316 ++++ b/ld/ld.h
1317 +@@ -172,6 +172,14 @@ typedef struct {
1318 + /* If set, display the target memory usage (per memory region). */
1319 + bfd_boolean print_memory_usage;
1321 ++ /* If TRUE (the default) warn for uses of system directories when
1322 ++ cross linking. */
1323 ++ bfd_boolean poison_system_directories;
1325 ++ /* If TRUE (default FALSE) give an error for uses of system
1326 ++ directories when cross linking instead of a warning. */
1327 ++ bfd_boolean error_poison_system_directories;
1329 + /* Big or little endian as set on command line. */
1330 + enum endian_enum endian;
1332 +diff --git a/ld/ld.texinfo b/ld/ld.texinfo
1333 +index 1dd7492..fb1438e 100644
1334 +--- a/ld/ld.texinfo
1335 ++++ b/ld/ld.texinfo
1336 +@@ -2403,6 +2403,18 @@ string identifying the original linked file does not change.
1338 + Passing @code{none} for @var{style} disables the setting from any
1339 + @code{--build-id} options earlier on the command line.
1341 ++@kindex --no-poison-system-directories
1342 ++@item --no-poison-system-directories
1343 ++Do not warn for @option{-L} options using system directories such as
1344 ++@file{/usr/lib} when cross linking. This option is intended for use
1345 ++in chroot environments when such directories contain the correct
1346 ++libraries for the target system rather than the host.
1348 ++@kindex --error-poison-system-directories
1349 ++@item --error-poison-system-directories
1350 ++Give an error instead of a warning for @option{-L} options using
1351 ++system directories when cross linking.
1352 + @end table
1354 + @c man end
1355 +diff --git a/ld/ldfile.c b/ld/ldfile.c
1356 +index 1439309..086b354 100644
1357 +--- a/ld/ldfile.c
1358 ++++ b/ld/ldfile.c
1359 +@@ -114,6 +114,23 @@ ldfile_add_library_path (const char *name, bfd_boolean cmdline)
1360 + new_dirs->name = concat (ld_sysroot, name + 1, (const char *) NULL);
1361 + else
1362 + new_dirs->name = xstrdup (name);
1364 ++#ifdef ENABLE_POISON_SYSTEM_DIRECTORIES
1365 ++ if (command_line.poison_system_directories
1366 ++ && ((!strncmp (name, "/lib", 4))
1367 ++ || (!strncmp (name, "/usr/lib", 8))
1368 ++ || (!strncmp (name, "/usr/local/lib", 14))
1369 ++ || (!strncmp (name, "/usr/X11R6/lib", 14))))
1370 ++ {
1371 ++ if (command_line.error_poison_system_directories)
1372 ++ einfo (_("%X%P: error: library search path \"%s\" is unsafe for "
1373 ++ "cross-compilation\n"), name);
1374 ++ else
1375 ++ einfo (_("%P: warning: library search path \"%s\" is unsafe for "
1376 ++ "cross-compilation\n"), name);
1377 ++ }
1378 ++#endif
1382 + /* Try to open a BFD for a lang_input_statement. */
1383 +diff --git a/ld/ldlex.h b/ld/ldlex.h
1384 +index 6f11e7b..0ca3110 100644
1385 +--- a/ld/ldlex.h
1386 ++++ b/ld/ldlex.h
1387 +@@ -146,6 +146,8 @@ enum option_values
1388 + OPTION_PRINT_MEMORY_USAGE,
1389 + OPTION_REQUIRE_DEFINED_SYMBOL,
1390 + OPTION_ORPHAN_HANDLING,
1391 ++ OPTION_NO_POISON_SYSTEM_DIRECTORIES,
1392 ++ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES,
1393 + };
1395 + /* The initial parser states. */
1396 +diff --git a/ld/ldmain.c b/ld/ldmain.c
1397 +index bb0b9cc..a23c56c 100644
1398 +--- a/ld/ldmain.c
1399 ++++ b/ld/ldmain.c
1400 +@@ -270,6 +270,8 @@ main (int argc, char **argv)
1401 + command_line.warn_mismatch = TRUE;
1402 + command_line.warn_search_mismatch = TRUE;
1403 + command_line.check_section_addresses = -1;
1404 ++ command_line.poison_system_directories = TRUE;
1405 ++ command_line.error_poison_system_directories = FALSE;
1407 + /* We initialize DEMANGLING based on the environment variable
1408 + COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
1409 +diff --git a/ld/lexsup.c b/ld/lexsup.c
1410 +index 4cad209..be7d584 100644
1411 +--- a/ld/lexsup.c
1412 ++++ b/ld/lexsup.c
1413 +@@ -535,6 +535,14 @@ static const struct ld_option ld_options[] =
1414 + { {"orphan-handling", required_argument, NULL, OPTION_ORPHAN_HANDLING},
1415 + '\0', N_("=MODE"), N_("Control how orphan sections are handled."),
1416 + TWO_DASHES },
1417 ++ { {"no-poison-system-directories", no_argument, NULL,
1418 ++ OPTION_NO_POISON_SYSTEM_DIRECTORIES},
1419 ++ '\0', NULL, N_("Do not warn for -L options using system directories"),
1420 ++ TWO_DASHES },
1421 ++ { {"error-poison-system-directories", no_argument, NULL,
1422 ++ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES},
1423 ++ '\0', NULL, N_("Give an error for -L options using system directories"),
1424 ++ TWO_DASHES },
1425 + };
1427 + #define OPTION_COUNT ARRAY_SIZE (ld_options)
1428 +@@ -547,6 +555,7 @@ parse_args (unsigned argc, char **argv)
1429 + int ingroup = 0;
1430 + char *default_dirlist = NULL;
1431 + char *shortopts;
1432 ++ char *BR_paranoid_env;
1433 + struct option *longopts;
1434 + struct option *really_longopts;
1435 + int last_optind;
1436 +@@ -1528,6 +1537,14 @@ parse_args (unsigned argc, char **argv)
1438 + break;
1440 ++ case OPTION_NO_POISON_SYSTEM_DIRECTORIES:
1441 ++ command_line.poison_system_directories = FALSE;
1442 ++ break;
1444 ++ case OPTION_ERROR_POISON_SYSTEM_DIRECTORIES:
1445 ++ command_line.error_poison_system_directories = TRUE;
1446 ++ break;
1448 + case OPTION_PUSH_STATE:
1449 + input_flags.pushed = xmemdup (&input_flags,
1450 + sizeof (input_flags),
1451 +@@ -1571,6 +1588,10 @@ parse_args (unsigned argc, char **argv)
1452 + command_line.soname = NULL;
1455 ++ BR_paranoid_env = getenv("BR_COMPILER_PARANOID_UNSAFE_PATH");
1456 ++ if (BR_paranoid_env && strlen(BR_paranoid_env) > 0)
1457 ++ command_line.error_poison_system_directories = TRUE;
1459 + while (ingroup)
1461 + lang_leave_group ();
1462 +--
1463 +2.4.3
1465 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0300-PATCH-ld-makefile.patch buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0300-PATCH-ld-makefile.patch
1466 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0300-PATCH-ld-makefile.patch 2017-05-17 10:27:16.013401440 +0200
1467 +++ buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0300-PATCH-ld-makefile.patch 1970-01-01 01:00:00.000000000 +0100
1468 @@ -1,41 +0,0 @@
1469 -From 32078014f734430e1c68fe40aaf970b9805ecaf5 Mon Sep 17 00:00:00 2001
1470 -From: Romain Naour <romain.naour@gmail.com>
1471 -Date: Fri, 21 Apr 2017 21:19:13 +0300
1472 -Subject: [PATCH] ld-makefile
1474 -[Romain: rebase on top of 2.26]
1475 -Signed-off-by: Romain Naour <romain.naour@gmail.com>
1476 ----
1477 - ld/Makefile.am | 2 +-
1478 - ld/Makefile.in | 2 +-
1479 - 2 files changed, 2 insertions(+), 2 deletions(-)
1481 -diff --git a/ld/Makefile.am b/ld/Makefile.am
1482 -index 9dd31ff..553a107 100644
1483 ---- a/ld/Makefile.am
1484 -+++ b/ld/Makefile.am
1485 -@@ -57,7 +57,7 @@ endif
1486 - # We put the scripts in the directory $(scriptdir)/ldscripts.
1487 - # We can't put the scripts in $(datadir) because the SEARCH_DIR
1488 - # directives need to be different for native and cross linkers.
1489 --scriptdir = $(tooldir)/lib
1490 -+scriptdir = $(libdir)
1492 - EMUL = @EMUL@
1493 - EMULATION_OFILES = @EMULATION_OFILES@
1494 -diff --git a/ld/Makefile.in b/ld/Makefile.in
1495 -index c464302..feb34ba 100644
1496 ---- a/ld/Makefile.in
1497 -+++ b/ld/Makefile.in
1498 -@@ -446,7 +446,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
1499 - # We put the scripts in the directory $(scriptdir)/ldscripts.
1500 - # We can't put the scripts in $(datadir) because the SEARCH_DIR
1501 - # directives need to be different for native and cross linkers.
1502 --scriptdir = $(tooldir)/lib
1503 -+scriptdir = $(libdir)
1504 - BASEDIR = $(srcdir)/..
1505 - BFDDIR = $(BASEDIR)/bfd
1506 - INCDIR = $(BASEDIR)/include
1507 ---
1508 -2.7.4
1510 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0301-PATCH-check-ldrunpath-length.patch buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0301-PATCH-check-ldrunpath-length.patch
1511 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0301-PATCH-check-ldrunpath-length.patch 2017-05-17 10:27:16.013401440 +0200
1512 +++ buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0301-PATCH-check-ldrunpath-length.patch 1970-01-01 01:00:00.000000000 +0100
1513 @@ -1,36 +0,0 @@
1514 -From 4a5a8b983fb31a67f976e0dd9cf5e8580ef55098 Mon Sep 17 00:00:00 2001
1515 -From: Romain Naour <romain.naour@gmail.com>
1516 -Date: Fri, 21 Apr 2017 21:23:55 +0300
1517 -Subject: [PATCH] check-ldrunpath-length
1519 -[Romain: rebase on top of 2.26]
1520 -Signed-off-by: Romain Naour <romain.naour@gmail.com>
1521 ----
1522 - ld/emultempl/elf32.em | 4 ++++
1523 - 1 file changed, 4 insertions(+)
1525 -diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
1526 -index d4837d0..937da8a 100644
1527 ---- a/ld/emultempl/elf32.em
1528 -+++ b/ld/emultempl/elf32.em
1529 -@@ -1460,6 +1460,8 @@ fragment <<EOF
1530 - && command_line.rpath == NULL)
1532 - path = (const char *) getenv ("LD_RUN_PATH");
1533 -+ if ((path) && (strlen (path) == 0))
1534 -+ path = NULL;
1535 - if (path
1536 - && gld${EMULATION_NAME}_search_needed (path, &n, force))
1537 - break;
1538 -@@ -1737,6 +1739,8 @@ gld${EMULATION_NAME}_before_allocation (void)
1539 - rpath = command_line.rpath;
1540 - if (rpath == NULL)
1541 - rpath = (const char *) getenv ("LD_RUN_PATH");
1542 -+ if ((rpath) && (strlen (rpath) == 0))
1543 -+ rpath = NULL;
1545 - for (abfd = link_info.input_bfds; abfd; abfd = abfd->link.next)
1546 - if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
1547 ---
1548 -2.7.4
1550 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0500-add-sysroot-fix-from-bug-3049.patch buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0500-add-sysroot-fix-from-bug-3049.patch
1551 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0500-add-sysroot-fix-from-bug-3049.patch 2017-05-17 10:27:16.013401440 +0200
1552 +++ buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0500-add-sysroot-fix-from-bug-3049.patch 1970-01-01 01:00:00.000000000 +0100
1553 @@ -1,48 +0,0 @@
1554 -From 30628870e583375f8927c04398c7219c6e9f703c Mon Sep 17 00:00:00 2001
1555 -From: Romain Naour <romain.naour@gmail.com>
1556 -Date: Fri, 25 Dec 2015 11:42:48 +0100
1557 -Subject: [PATCH] add sysroot fix from bug #3049
1559 -Always try to prepend the sysroot prefix to absolute filenames first.
1561 -http://bugs.gentoo.org/275666
1562 -http://sourceware.org/bugzilla/show_bug.cgi?id=10340
1564 -Signed-off-by: Sven Rebhan <odinshorse@googlemail.com>
1565 -[Romain: rebase on top of 2.26]
1566 -Signed-off-by: Romain Naour <romain.naour@gmail.com>
1567 ----
1568 - ld/ldfile.c | 11 +++++++++--
1569 - 1 file changed, 9 insertions(+), 2 deletions(-)
1571 -diff --git a/ld/ldfile.c diff --git b/ld/ldfile.c
1572 ---- a/ld/ldfile.c 2017-03-02 03:23:54.000000000 -0500
1573 -+++ b/ld/ldfile.c 2017-03-20 09:52:27.687415942 -0400
1574 -@@ -336,18 +336,24 @@
1575 - directory first. */
1576 - if (!entry->flags.maybe_archive)
1578 -- if (entry->flags.sysrooted && IS_ABSOLUTE_PATH (entry->filename))
1579 -+ /* For absolute pathnames, try to always open the file in the
1580 -+ sysroot first. If this fails, try to open the file at the
1581 -+ given location. */
1582 -+ entry->flags.sysrooted = is_sysrooted_pathname (entry->filename);
1583 -+ if (!entry->flags.sysrooted && IS_ABSOLUTE_PATH (entry->filename)
1584 -+ && ld_sysroot)
1586 - char *name = concat (ld_sysroot, entry->filename,
1587 - (const char *) NULL);
1588 - if (ldfile_try_open_bfd (name, entry))
1590 - entry->filename = name;
1591 -+ entry->flags.sysrooted = TRUE;
1592 - return TRUE;
1594 - free (name);
1596 -- else if (ldfile_try_open_bfd (entry->filename, entry))
1597 -+ if (ldfile_try_open_bfd (entry->filename, entry))
1598 - return TRUE;
1600 - if (IS_ABSOLUTE_PATH (entry->filename))
1602 diff -Naurp buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0600-poison-system-directories.patch buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0600-poison-system-directories.patch
1603 --- buildroot-2017.05-rc2/package/binutils/arc-2017.03-rc2/0600-poison-system-directories.patch 2017-05-17 10:27:16.013401440 +0200
1604 +++ buildroot-2017.05.2/package/binutils/arc-2017.03-rc2/0600-poison-system-directories.patch 1970-01-01 01:00:00.000000000 +0100
1605 @@ -1,306 +0,0 @@
1606 -From be366461dd49e760440fb28eaee5164eb281adcc Mon Sep 17 00:00:00 2001
1607 -From: Romain Naour <romain.naour@gmail.com>
1608 -Date: Fri, 25 Dec 2015 11:45:38 +0100
1609 -Subject: [PATCH] poison-system-directories
1611 -Patch adapted to binutils 2.23.2 and extended to use
1612 -BR_COMPILER_PARANOID_UNSAFE_PATH by Thomas Petazzoni.
1614 -[Romain: rebase on top of 2.26]
1615 -Signed-off-by: Romain Naour <romain.naour@gmail.com>
1616 -[Gustavo: adapt to binutils 2.25]
1617 -Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
1618 -Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
1620 -Upstream-Status: Inappropriate [distribution: codesourcery]
1622 -Patch originally created by Mark Hatle, forward-ported to
1623 -binutils 2.21 by Scott Garman.
1625 -purpose: warn for uses of system directories when cross linking
1627 -Code Merged from Sourcery G++ binutils 2.19 - 4.4-277
1629 -2008-07-02 Joseph Myers <joseph@codesourcery.com>
1631 - ld/
1632 - * ld.h (args_type): Add error_poison_system_directories.
1633 - * ld.texinfo (--error-poison-system-directories): Document.
1634 - * ldfile.c (ldfile_add_library_path): Check
1635 - command_line.error_poison_system_directories.
1636 - * ldmain.c (main): Initialize
1637 - command_line.error_poison_system_directories.
1638 - * lexsup.c (enum option_values): Add
1639 - OPTION_ERROR_POISON_SYSTEM_DIRECTORIES.
1640 - (ld_options): Add --error-poison-system-directories.
1641 - (parse_args): Handle new option.
1643 -2007-06-13 Joseph Myers <joseph@codesourcery.com>
1645 - ld/
1646 - * config.in: Regenerate.
1647 - * ld.h (args_type): Add poison_system_directories.
1648 - * ld.texinfo (--no-poison-system-directories): Document.
1649 - * ldfile.c (ldfile_add_library_path): Check
1650 - command_line.poison_system_directories.
1651 - * ldmain.c (main): Initialize
1652 - command_line.poison_system_directories.
1653 - * lexsup.c (enum option_values): Add
1654 - OPTION_NO_POISON_SYSTEM_DIRECTORIES.
1655 - (ld_options): Add --no-poison-system-directories.
1656 - (parse_args): Handle new option.
1658 -2007-04-20 Joseph Myers <joseph@codesourcery.com>
1660 - Merge from Sourcery G++ binutils 2.17:
1662 - 2007-03-20 Joseph Myers <joseph@codesourcery.com>
1663 - Based on patch by Mark Hatle <mark.hatle@windriver.com>.
1664 - ld/
1665 - * configure.ac (--enable-poison-system-directories): New option.
1666 - * configure, config.in: Regenerate.
1667 - * ldfile.c (ldfile_add_library_path): If
1668 - ENABLE_POISON_SYSTEM_DIRECTORIES defined, warn for use of /lib,
1669 - /usr/lib, /usr/local/lib or /usr/X11R6/lib.
1671 -Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
1672 -Signed-off-by: Scott Garman <scott.a.garman@intel.com>
1673 ----
1674 - ld/config.in | 3 +++
1675 - ld/configure | 14 ++++++++++++++
1676 - ld/configure.ac | 10 ++++++++++
1677 - ld/ld.h | 8 ++++++++
1678 - ld/ld.texinfo | 12 ++++++++++++
1679 - ld/ldfile.c | 17 +++++++++++++++++
1680 - ld/ldlex.h | 2 ++
1681 - ld/ldmain.c | 2 ++
1682 - ld/lexsup.c | 21 +++++++++++++++++++++
1683 - 9 files changed, 89 insertions(+)
1685 -diff --git a/ld/config.in b/ld/config.in
1686 -index 276fb77..35c58eb 100644
1687 ---- a/ld/config.in
1688 -+++ b/ld/config.in
1689 -@@ -17,6 +17,9 @@
1690 - language is requested. */
1691 - #undef ENABLE_NLS
1693 -+/* Define to warn for use of native system library directories */
1694 -+#undef ENABLE_POISON_SYSTEM_DIRECTORIES
1696 - /* Additional extension a shared object might have. */
1697 - #undef EXTRA_SHLIB_EXTENSION
1699 -diff --git a/ld/configure b/ld/configure
1700 -index a446283..d1f9504 100755
1701 ---- a/ld/configure
1702 -+++ b/ld/configure
1703 -@@ -789,6 +789,7 @@ with_lib_path
1704 - enable_targets
1705 - enable_64_bit_bfd
1706 - with_sysroot
1707 -+enable_poison_system_directories
1708 - enable_gold
1709 - enable_got
1710 - enable_compressed_debug_sections
1711 -@@ -1446,6 +1447,8 @@ Optional Features:
1712 - --disable-largefile omit support for large files
1713 - --enable-targets alternative target configurations
1714 - --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
1715 -+ --enable-poison-system-directories
1716 -+ warn for use of native system library directories
1717 - --enable-gold[=ARG] build gold [ARG={default,yes,no}]
1718 - --enable-got=<type> GOT handling scheme (target, single, negative,
1719 - multigot)
1720 -@@ -15499,7 +15502,18 @@ else
1721 - fi
1724 -+# Check whether --enable-poison-system-directories was given.
1725 -+if test "${enable_poison_system_directories+set}" = set; then :
1726 -+ enableval=$enable_poison_system_directories;
1727 -+else
1728 -+ enable_poison_system_directories=no
1729 -+fi
1731 -+if test "x${enable_poison_system_directories}" = "xyes"; then
1733 -+$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
1735 -+fi
1737 - # Check whether --enable-got was given.
1738 - if test "${enable_got+set}" = set; then :
1739 -diff --git a/ld/configure.ac b/ld/configure.ac
1740 -index 188172d..2cd8443 100644
1741 ---- a/ld/configure.ac
1742 -+++ b/ld/configure.ac
1743 -@@ -95,6 +95,16 @@ AC_SUBST(use_sysroot)
1744 - AC_SUBST(TARGET_SYSTEM_ROOT)
1745 - AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
1747 -+AC_ARG_ENABLE([poison-system-directories],
1748 -+ AS_HELP_STRING([--enable-poison-system-directories],
1749 -+ [warn for use of native system library directories]),,
1750 -+ [enable_poison_system_directories=no])
1751 -+if test "x${enable_poison_system_directories}" = "xyes"; then
1752 -+ AC_DEFINE([ENABLE_POISON_SYSTEM_DIRECTORIES],
1753 -+ [1],
1754 -+ [Define to warn for use of native system library directories])
1755 -+fi
1757 - dnl Use --enable-gold to decide if this linker should be the default.
1758 - dnl "install_as_default" is set to false if gold is the default linker.
1759 - dnl "installed_linker" is the installed BFD linker name.
1760 -diff --git a/ld/ld.h b/ld/ld.h
1761 -index d84ec4e..3476b26 100644
1762 ---- a/ld/ld.h
1763 -+++ b/ld/ld.h
1764 -@@ -172,6 +172,14 @@ typedef struct {
1765 - /* If set, display the target memory usage (per memory region). */
1766 - bfd_boolean print_memory_usage;
1768 -+ /* If TRUE (the default) warn for uses of system directories when
1769 -+ cross linking. */
1770 -+ bfd_boolean poison_system_directories;
1772 -+ /* If TRUE (default FALSE) give an error for uses of system
1773 -+ directories when cross linking instead of a warning. */
1774 -+ bfd_boolean error_poison_system_directories;
1776 - /* Big or little endian as set on command line. */
1777 - enum endian_enum endian;
1779 -diff --git a/ld/ld.texinfo b/ld/ld.texinfo
1780 -index 1dd7492..fb1438e 100644
1781 ---- a/ld/ld.texinfo
1782 -+++ b/ld/ld.texinfo
1783 -@@ -2403,6 +2403,18 @@ string identifying the original linked file does not change.
1785 - Passing @code{none} for @var{style} disables the setting from any
1786 - @code{--build-id} options earlier on the command line.
1788 -+@kindex --no-poison-system-directories
1789 -+@item --no-poison-system-directories
1790 -+Do not warn for @option{-L} options using system directories such as
1791 -+@file{/usr/lib} when cross linking. This option is intended for use
1792 -+in chroot environments when such directories contain the correct
1793 -+libraries for the target system rather than the host.
1795 -+@kindex --error-poison-system-directories
1796 -+@item --error-poison-system-directories
1797 -+Give an error instead of a warning for @option{-L} options using
1798 -+system directories when cross linking.
1799 - @end table
1801 - @c man end
1802 -diff --git a/ld/ldfile.c b/ld/ldfile.c
1803 -index 1439309..086b354 100644
1804 ---- a/ld/ldfile.c
1805 -+++ b/ld/ldfile.c
1806 -@@ -114,6 +114,23 @@ ldfile_add_library_path (const char *name, bfd_boolean cmdline)
1807 - new_dirs->name = concat (ld_sysroot, name + 1, (const char *) NULL);
1808 - else
1809 - new_dirs->name = xstrdup (name);
1811 -+#ifdef ENABLE_POISON_SYSTEM_DIRECTORIES
1812 -+ if (command_line.poison_system_directories
1813 -+ && ((!strncmp (name, "/lib", 4))
1814 -+ || (!strncmp (name, "/usr/lib", 8))
1815 -+ || (!strncmp (name, "/usr/local/lib", 14))
1816 -+ || (!strncmp (name, "/usr/X11R6/lib", 14))))
1817 -+ {
1818 -+ if (command_line.error_poison_system_directories)
1819 -+ einfo (_("%X%P: error: library search path \"%s\" is unsafe for "
1820 -+ "cross-compilation\n"), name);
1821 -+ else
1822 -+ einfo (_("%P: warning: library search path \"%s\" is unsafe for "
1823 -+ "cross-compilation\n"), name);
1824 -+ }
1825 -+#endif
1829 - /* Try to open a BFD for a lang_input_statement. */
1830 -diff --git a/ld/ldlex.h b/ld/ldlex.h
1831 -index 6f11e7b..0ca3110 100644
1832 ---- a/ld/ldlex.h
1833 -+++ b/ld/ldlex.h
1834 -@@ -146,6 +146,8 @@ enum option_values
1835 - OPTION_PRINT_MEMORY_USAGE,
1836 - OPTION_REQUIRE_DEFINED_SYMBOL,
1837 - OPTION_ORPHAN_HANDLING,
1838 -+ OPTION_NO_POISON_SYSTEM_DIRECTORIES,
1839 -+ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES,
1840 - };
1842 - /* The initial parser states. */
1843 -diff --git a/ld/ldmain.c b/ld/ldmain.c
1844 -index bb0b9cc..a23c56c 100644
1845 ---- a/ld/ldmain.c
1846 -+++ b/ld/ldmain.c
1847 -@@ -270,6 +270,8 @@ main (int argc, char **argv)
1848 - command_line.warn_mismatch = TRUE;
1849 - command_line.warn_search_mismatch = TRUE;
1850 - command_line.check_section_addresses = -1;
1851 -+ command_line.poison_system_directories = TRUE;
1852 -+ command_line.error_poison_system_directories = FALSE;
1854 - /* We initialize DEMANGLING based on the environment variable
1855 - COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
1856 -diff --git a/ld/lexsup.c b/ld/lexsup.c
1857 -index 4cad209..be7d584 100644
1858 ---- a/ld/lexsup.c
1859 -+++ b/ld/lexsup.c
1860 -@@ -535,6 +535,14 @@ static const struct ld_option ld_options[] =
1861 - { {"orphan-handling", required_argument, NULL, OPTION_ORPHAN_HANDLING},
1862 - '\0', N_("=MODE"), N_("Control how orphan sections are handled."),
1863 - TWO_DASHES },
1864 -+ { {"no-poison-system-directories", no_argument, NULL,
1865 -+ OPTION_NO_POISON_SYSTEM_DIRECTORIES},
1866 -+ '\0', NULL, N_("Do not warn for -L options using system directories"),
1867 -+ TWO_DASHES },
1868 -+ { {"error-poison-system-directories", no_argument, NULL,
1869 -+ OPTION_ERROR_POISON_SYSTEM_DIRECTORIES},
1870 -+ '\0', NULL, N_("Give an error for -L options using system directories"),
1871 -+ TWO_DASHES },
1872 - };
1874 - #define OPTION_COUNT ARRAY_SIZE (ld_options)
1875 -@@ -547,6 +555,7 @@ parse_args (unsigned argc, char **argv)
1876 - int ingroup = 0;
1877 - char *default_dirlist = NULL;
1878 - char *shortopts;
1879 -+ char *BR_paranoid_env;
1880 - struct option *longopts;
1881 - struct option *really_longopts;
1882 - int last_optind;
1883 -@@ -1528,6 +1537,14 @@ parse_args (unsigned argc, char **argv)
1885 - break;
1887 -+ case OPTION_NO_POISON_SYSTEM_DIRECTORIES:
1888 -+ command_line.poison_system_directories = FALSE;
1889 -+ break;
1891 -+ case OPTION_ERROR_POISON_SYSTEM_DIRECTORIES:
1892 -+ command_line.error_poison_system_directories = TRUE;
1893 -+ break;
1895 - case OPTION_PUSH_STATE:
1896 - input_flags.pushed = xmemdup (&input_flags,
1897 - sizeof (input_flags),
1898 -@@ -1571,6 +1588,10 @@ parse_args (unsigned argc, char **argv)
1899 - command_line.soname = NULL;
1902 -+ BR_paranoid_env = getenv("BR_COMPILER_PARANOID_UNSAFE_PATH");
1903 -+ if (BR_paranoid_env && strlen(BR_paranoid_env) > 0)
1904 -+ command_line.error_poison_system_directories = TRUE;
1906 - while (ingroup)
1908 - lang_leave_group ();
1909 ---
1910 -2.4.3
1912 diff -Naurp buildroot-2017.05-rc2/package/binutils/binutils.hash buildroot-2017.05.2/package/binutils/binutils.hash
1913 --- buildroot-2017.05-rc2/package/binutils/binutils.hash 2017-05-17 10:27:16.013401440 +0200
1914 +++ buildroot-2017.05.2/package/binutils/binutils.hash 2017-07-27 08:16:52.017486944 +0200
1915 @@ -4,4 +4,4 @@ sha512 cf276f84935312361a2ca077e04d0b469
1916 sha512 ede2e4e59a800260eea8c14eafbaee94e30abadafd5c419a3370f9f62213cf027d6400a1d4970b6958bd4d220e675dcd483a708107016e7abd5c99d7392ba8fd binutils-2.28.tar.bz2
1918 # Locally calculated (fetched from Github)
1919 -sha512 577fbd59dc8d41022ed511b86f3afc49af48ab798a7b187411a466621dc6247dff7dd84fa110ca278f09a9e523d8bdb892a233c00bf47d11b92be70e7278efe9 binutils-arc-2017.03-rc2.tar.gz
1920 +sha512 07d5639e74eafe8fced259870c1a7dedee67c534573dda53fb78ee1ffeec9e17479fdde41dccd03b1cf0248023acbef7f66013398b2f722e4a8891ac680d1d16 binutils-arc-2017.03.tar.gz
1921 diff -Naurp buildroot-2017.05-rc2/package/binutils/binutils.mk buildroot-2017.05.2/package/binutils/binutils.mk
1922 --- buildroot-2017.05-rc2/package/binutils/binutils.mk 2017-05-17 10:27:16.013401440 +0200
1923 +++ buildroot-2017.05.2/package/binutils/binutils.mk 2017-07-27 08:16:52.017486944 +0200
1924 @@ -9,7 +9,7 @@
1925 BINUTILS_VERSION = $(call qstrip,$(BR2_BINUTILS_VERSION))
1926 ifeq ($(BINUTILS_VERSION),)
1927 ifeq ($(BR2_arc),y)
1928 -BINUTILS_VERSION = arc-2017.03-rc2
1929 +BINUTILS_VERSION = arc-2017.03
1930 else
1931 BINUTILS_VERSION = 2.27
1932 endif
1933 diff -Naurp buildroot-2017.05-rc2/package/binutils/Config.in.host buildroot-2017.05.2/package/binutils/Config.in.host
1934 --- buildroot-2017.05-rc2/package/binutils/Config.in.host 2017-05-17 10:27:16.013401440 +0200
1935 +++ buildroot-2017.05.2/package/binutils/Config.in.host 2017-07-27 08:16:52.017486944 +0200
1936 @@ -23,7 +23,7 @@ endchoice
1938 config BR2_BINUTILS_VERSION
1939 string
1940 - default "arc-2017.03-rc2" if BR2_arc
1941 + default "arc-2017.03" if BR2_arc
1942 default "2.26.1" if BR2_BINUTILS_VERSION_2_26_X
1943 default "2.27" if BR2_BINUTILS_VERSION_2_27_X
1944 default "2.28" if BR2_BINUTILS_VERSION_2_28_X
1945 diff -Naurp buildroot-2017.05-rc2/package/botan/botan.mk buildroot-2017.05.2/package/botan/botan.mk
1946 --- buildroot-2017.05-rc2/package/botan/botan.mk 2017-05-17 10:27:16.013401440 +0200
1947 +++ buildroot-2017.05.2/package/botan/botan.mk 2017-07-27 08:16:52.017486944 +0200
1948 @@ -43,6 +43,12 @@ BOTAN_DEPENDENCIES += zlib
1949 BOTAN_CONF_OPTS += --with-zlib
1950 endif
1952 +ifeq ($(BR2_POWERPC_CPU_HAS_ALTIVEC),y)
1953 +BOTAN_CONF_OPTS += --enable-altivec
1954 +else
1955 +BOTAN_CONF_OPTS += --disable-altivec
1956 +endif
1958 define BOTAN_CONFIGURE_CMDS
1959 (cd $(@D); $(TARGET_MAKE_ENV) ./configure.py $(BOTAN_CONF_OPTS))
1960 endef
1961 diff -Naurp buildroot-2017.05-rc2/package/busybox/busybox.config buildroot-2017.05.2/package/busybox/busybox.config
1962 --- buildroot-2017.05-rc2/package/busybox/busybox.config 2017-05-17 10:27:16.013401440 +0200
1963 +++ buildroot-2017.05.2/package/busybox/busybox.config 2017-07-27 08:16:52.017486944 +0200
1964 @@ -22,7 +22,7 @@ CONFIG_FEATURE_INSTALLER=y
1965 # CONFIG_PAM is not set
1966 CONFIG_LONG_OPTS=y
1967 CONFIG_FEATURE_DEVPTS=y
1968 -CONFIG_FEATURE_CLEAN_UP=y
1969 +# CONFIG_FEATURE_CLEAN_UP is not set
1970 CONFIG_FEATURE_UTMP=y
1971 CONFIG_FEATURE_WTMP=y
1972 # CONFIG_FEATURE_PIDFILE is not set
1973 diff -Naurp buildroot-2017.05-rc2/package/busybox/busybox-minimal.config buildroot-2017.05.2/package/busybox/busybox-minimal.config
1974 --- buildroot-2017.05-rc2/package/busybox/busybox-minimal.config 2017-05-17 10:27:16.013401440 +0200
1975 +++ buildroot-2017.05.2/package/busybox/busybox-minimal.config 2017-07-27 08:16:52.017486944 +0200
1976 @@ -22,7 +22,7 @@ CONFIG_FEATURE_INSTALLER=y
1977 # CONFIG_PAM is not set
1978 CONFIG_LONG_OPTS=y
1979 CONFIG_FEATURE_DEVPTS=y
1980 -CONFIG_FEATURE_CLEAN_UP=y
1981 +# CONFIG_FEATURE_CLEAN_UP is not set
1982 CONFIG_FEATURE_UTMP=y
1983 CONFIG_FEATURE_WTMP=y
1984 # CONFIG_FEATURE_PIDFILE is not set
1985 diff -Naurp buildroot-2017.05-rc2/package/c-ares/c-ares.hash buildroot-2017.05.2/package/c-ares/c-ares.hash
1986 --- buildroot-2017.05-rc2/package/c-ares/c-ares.hash 2017-05-17 10:27:16.013401440 +0200
1987 +++ buildroot-2017.05.2/package/c-ares/c-ares.hash 2017-07-27 08:16:52.017486944 +0200
1988 @@ -1,2 +1,2 @@
1989 # Locally calculated after checking pgp signature
1990 -sha256 8692f9403cdcdf936130e045c84021665118ee9bfea905d1a76f04d4e6f365fb c-ares-1.12.0.tar.gz
1991 +sha256 03f708f1b14a26ab26c38abd51137640cb444d3ec72380b21b20f1a8d2861da7 c-ares-1.13.0.tar.gz
1992 diff -Naurp buildroot-2017.05-rc2/package/c-ares/c-ares.mk buildroot-2017.05.2/package/c-ares/c-ares.mk
1993 --- buildroot-2017.05-rc2/package/c-ares/c-ares.mk 2017-05-17 10:27:16.013401440 +0200
1994 +++ buildroot-2017.05.2/package/c-ares/c-ares.mk 2017-07-27 08:16:52.017486944 +0200
1995 @@ -4,7 +4,7 @@
1997 ################################################################################
1999 -C_ARES_VERSION = 1.12.0
2000 +C_ARES_VERSION = 1.13.0
2001 C_ARES_SITE = http://c-ares.haxx.se/download
2002 C_ARES_INSTALL_STAGING = YES
2003 C_ARES_CONF_OPTS = --with-random=/dev/urandom
2004 diff -Naurp buildroot-2017.05-rc2/package/ccache/ccache.mk buildroot-2017.05.2/package/ccache/ccache.mk
2005 --- buildroot-2017.05-rc2/package/ccache/ccache.mk 2017-05-17 10:27:16.013401440 +0200
2006 +++ buildroot-2017.05.2/package/ccache/ccache.mk 2017-07-27 08:16:52.017486944 +0200
2007 @@ -28,9 +28,13 @@ HOST_CCACHE_CONF_OPTS += --with-bundled-
2008 # BR2_CCACHE_DIR.
2009 # - Change hard-coded last-ditch default to match path in .config, to avoid
2010 # the need to specify BR_CACHE_DIR when invoking ccache directly.
2011 +# CCache replaces "%s" with the home directory of the current user,
2012 +# So rewrite BR_CACHE_DIR to take that into consideration for SDK purpose
2013 +HOST_CCACHE_DEFAULT_CCACHE_DIR = $(patsubst $(HOME)/%,\%s/%,$(BR_CACHE_DIR))
2015 define HOST_CCACHE_PATCH_CONFIGURATION
2016 sed -i 's,getenv("CCACHE_DIR"),getenv("BR_CACHE_DIR"),' $(@D)/ccache.c
2017 - sed -i 's,"%s/.ccache","$(BR_CACHE_DIR)",' $(@D)/conf.c
2018 + sed -i 's,"%s/.ccache","$(HOST_CCACHE_DEFAULT_CCACHE_DIR)",' $(@D)/conf.c
2019 endef
2021 HOST_CCACHE_POST_PATCH_HOOKS += HOST_CCACHE_PATCH_CONFIGURATION
2022 diff -Naurp buildroot-2017.05-rc2/package/c-icap/c-icap.mk buildroot-2017.05.2/package/c-icap/c-icap.mk
2023 --- buildroot-2017.05-rc2/package/c-icap/c-icap.mk 2017-05-17 10:27:16.013401440 +0200
2024 +++ buildroot-2017.05.2/package/c-icap/c-icap.mk 2017-07-27 08:16:52.017486944 +0200
2025 @@ -29,17 +29,17 @@ C_ICAP_CONF_ENV = ac_cv_10031b_ipc_sem=y
2026 C_ICAP_AUTORECONF = YES
2028 ifeq ($(BR2_PACKAGE_BERKELEYDB),y)
2029 -C_ICAP_CONF_OPTS += --with-berkeleydb
2030 +C_ICAP_CONF_OPTS += --with-bdb
2031 C_ICAP_DEPENDENCIES += berkeleydb
2032 else
2033 -C_ICAP_CONF_OPTS += --without-berkeleydb
2034 +C_ICAP_CONF_OPTS += --without-bdb
2035 endif
2037 ifeq ($(BR2_PACKAGE_BZIP2),y)
2038 -C_ICAP_CONF_OPTS += --with-bzip2
2039 +C_ICAP_CONF_OPTS += --with-bzlib
2040 C_ICAP_DEPENDENCIES += bzip2
2041 else
2042 -C_ICAP_CONF_OPTS += --without-bzip2
2043 +C_ICAP_CONF_OPTS += --without-bzlib
2044 endif
2046 ifeq ($(BR2_PACKAGE_ZLIB),y)
2047 diff -Naurp buildroot-2017.05-rc2/package/collectd/0001-libcollectdclient-increase-error-buffer.patch buildroot-2017.05.2/package/collectd/0001-libcollectdclient-increase-error-buffer.patch
2048 --- buildroot-2017.05-rc2/package/collectd/0001-libcollectdclient-increase-error-buffer.patch 1970-01-01 01:00:00.000000000 +0100
2049 +++ buildroot-2017.05.2/package/collectd/0001-libcollectdclient-increase-error-buffer.patch 2017-07-27 08:16:52.017486944 +0200
2050 @@ -0,0 +1,87 @@
2051 +From e170f3559fcda6d37a012aba187a96b1f42e8f9d Mon Sep 17 00:00:00 2001
2052 +From: Ruben Kerkhof <ruben@rubenkerkhof.com>
2053 +Date: Sun, 2 Jul 2017 21:52:14 +0200
2054 +Subject: [PATCH] libcollectdclient: increase error buffer
2055 +MIME-Version: 1.0
2056 +Content-Type: text/plain; charset=utf8
2057 +Content-Transfer-Encoding: 8bit
2059 +make[1]: Entering directory '/home/ruben/src/collectd'
2060 + CC src/libcollectdclient/libcollectdclient_la-client.lo
2061 +src/libcollectdclient/client.c: In function ‘lcc_getval’:
2062 +src/libcollectdclient/client.c:621:23: warning: ‘%s’ directive output may be truncated writing up to 1023 bytes into a region of size 1010 [-Wformat-truncation=]
2063 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2064 + ^ ~
2065 +src/libcollectdclient/client.c:94:48: note: in definition of macro ‘LCC_SET_ERRSTR’
2066 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2067 + ^~~~~~~~~~~
2068 +src/libcollectdclient/client.c:94:5: note: ‘snprintf’ output between 15 and 1038 bytes into a destination of size 1024
2069 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2070 + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2071 +src/libcollectdclient/client.c:621:5: note: in expansion of macro ‘LCC_SET_ERRSTR’
2072 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2073 + ^~~~~~~~~~~~~~
2074 +src/libcollectdclient/client.c: In function ‘lcc_putval’:
2075 +src/libcollectdclient/client.c:754:23: warning: ‘%s’ directive output may be truncated writing up to 1023 bytes into a region of size 1010 [-Wformat-truncation=]
2076 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2077 + ^ ~
2078 +src/libcollectdclient/client.c:94:48: note: in definition of macro ‘LCC_SET_ERRSTR’
2079 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2080 + ^~~~~~~~~~~
2081 +src/libcollectdclient/client.c:94:5: note: ‘snprintf’ output between 15 and 1038 bytes into a destination of size 1024
2082 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2083 + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2084 +src/libcollectdclient/client.c:754:5: note: in expansion of macro ‘LCC_SET_ERRSTR’
2085 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2086 + ^~~~~~~~~~~~~~
2087 +src/libcollectdclient/client.c: In function ‘lcc_flush’:
2088 +src/libcollectdclient/client.c:802:23: warning: ‘%s’ directive output may be truncated writing up to 1023 bytes into a region of size 1010 [-Wformat-truncation=]
2089 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2090 + ^ ~
2091 +src/libcollectdclient/client.c:94:48: note: in definition of macro ‘LCC_SET_ERRSTR’
2092 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2093 + ^~~~~~~~~~~
2094 +src/libcollectdclient/client.c:94:5: note: ‘snprintf’ output between 15 and 1038 bytes into a destination of size 1024
2095 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2096 + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2097 +src/libcollectdclient/client.c:802:5: note: in expansion of macro ‘LCC_SET_ERRSTR’
2098 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2099 + ^~~~~~~~~~~~~~
2100 +src/libcollectdclient/client.c: In function ‘lcc_listval’:
2101 +src/libcollectdclient/client.c:834:23: warning: ‘%s’ directive output may be truncated writing up to 1023 bytes into a region of size 1010 [-Wformat-truncation=]
2102 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2103 + ^ ~
2104 +src/libcollectdclient/client.c:94:48: note: in definition of macro ‘LCC_SET_ERRSTR’
2105 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2106 + ^~~~~~~~~~~
2107 +src/libcollectdclient/client.c:94:5: note: ‘snprintf’ output between 15 and 1038 bytes into a destination of size 1024
2108 + snprintf((c)->errbuf, sizeof((c)->errbuf), __VA_ARGS__); \
2109 + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2110 +src/libcollectdclient/client.c:834:5: note: in expansion of macro ‘LCC_SET_ERRSTR’
2111 + LCC_SET_ERRSTR(c, "Server error: %s", res.message);
2112 + ^~~~~~~~~~~~~~
2114 +Fixes #2200
2116 +[Upstream commit: https://git.octo.it/?p=collectd.git;a=commitdiff;h=e170f3559fcda6d37a012aba187a96b1f42e8f9d]
2117 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2118 +---
2119 + src/libcollectdclient/client.c | 2 +-
2120 + 1 file changed, 1 insertion(+), 1 deletion(-)
2122 +diff --git a/src/libcollectdclient/client.c b/src/libcollectdclient/client.c
2123 +index 51a4ab2..3ae2e71 100644
2124 +--- a/src/libcollectdclient/client.c
2125 ++++ b/src/libcollectdclient/client.c
2126 +@@ -99,7 +99,7 @@
2127 + */
2128 + struct lcc_connection_s {
2129 + FILE *fh;
2130 +- char errbuf[1024];
2131 ++ char errbuf[2048];
2132 + };
2134 + struct lcc_response_s {
2135 +--
2136 +1.7.10.4
2138 diff -Naurp buildroot-2017.05-rc2/package/Config.in buildroot-2017.05.2/package/Config.in
2139 --- buildroot-2017.05-rc2/package/Config.in 2017-05-17 10:27:16.013401440 +0200
2140 +++ buildroot-2017.05.2/package/Config.in 2017-07-27 08:16:52.017486944 +0200
2141 @@ -440,7 +440,6 @@ endmenu
2142 source "package/odroid-mali/Config.in"
2143 source "package/odroid-scripts/Config.in"
2144 source "package/ofono/Config.in"
2145 - source "package/ola/Config.in"
2146 source "package/on2-8170-modules/Config.in"
2147 source "package/open2300/Config.in"
2148 source "package/openipmi/Config.in"
2149 @@ -1811,7 +1810,6 @@ menu "System tools"
2150 source "package/efibootmgr/Config.in"
2151 source "package/efivar/Config.in"
2152 source "package/emlog/Config.in"
2153 - source "package/firejail/Config.in"
2154 source "package/ftop/Config.in"
2155 source "package/getent/Config.in"
2156 source "package/htop/Config.in"
2157 diff -Naurp buildroot-2017.05-rc2/package/connman/Config.in buildroot-2017.05.2/package/connman/Config.in
2158 --- buildroot-2017.05-rc2/package/connman/Config.in 2017-05-17 10:27:16.013401440 +0200
2159 +++ buildroot-2017.05.2/package/connman/Config.in 2017-07-27 08:16:52.017486944 +0200
2160 @@ -33,12 +33,16 @@ config BR2_PACKAGE_CONNMAN_WIFI
2162 config BR2_PACKAGE_CONNMAN_WISPR
2163 bool "enable WISPr support"
2164 + depends on !BR2_STATIC_LIBS # gnutls
2165 select BR2_PACKAGE_GNUTLS
2166 help
2167 Enable support for Wireless Internet Service Provider
2168 roaming (WISPr). A RADIUS server is used to authenticate the
2169 subscriber's credentials.
2171 +comment "connman WISPr needs a toolchain w/ dynamic library"
2172 + depends on BR2_STATIC_LIBS
2174 config BR2_PACKAGE_CONNMAN_BLUETOOTH
2175 bool "enable Bluetooth support"
2176 help
2177 diff -Naurp buildroot-2017.05-rc2/package/cppcms/cppcms.mk buildroot-2017.05.2/package/cppcms/cppcms.mk
2178 --- buildroot-2017.05-rc2/package/cppcms/cppcms.mk 2017-05-17 10:27:16.013401440 +0200
2179 +++ buildroot-2017.05.2/package/cppcms/cppcms.mk 2017-07-27 08:16:52.017486944 +0200
2180 @@ -11,6 +11,10 @@ CPPCMS_LICENSE_FILES = COPYING.TXT
2181 CPPCMS_SITE = http://downloads.sourceforge.net/project/cppcms/cppcms/$(CPPCMS_VERSION)
2182 CPPCMS_INSTALL_STAGING = YES
2184 +# disable rpath to avoid getting /usr/lib added to the link search
2185 +# path
2186 +CPPCMS_CONF_OPTS = -DCMAKE_SKIP_RPATH=ON
2188 CPPCMS_DEPENDENCIES = zlib pcre libgcrypt
2190 ifeq ($(BR2_PACKAGE_CPPCMS_ICU),y)
2191 diff -Naurp buildroot-2017.05-rc2/package/dhcp/Config.in buildroot-2017.05.2/package/dhcp/Config.in
2192 --- buildroot-2017.05-rc2/package/dhcp/Config.in 2017-05-17 10:27:16.013401440 +0200
2193 +++ buildroot-2017.05.2/package/dhcp/Config.in 2017-07-27 08:16:52.017486944 +0200
2194 @@ -12,6 +12,7 @@ if BR2_PACKAGE_DHCP
2196 config BR2_PACKAGE_DHCP_SERVER
2197 bool "dhcp server"
2198 + select BR2_PACKAGE_SYSTEMD_TMPFILES if BR2_PACKAGE_SYSTEMD
2199 help
2200 DHCP server from the ISC DHCP distribution.
2202 diff -Naurp buildroot-2017.05-rc2/package/dhcp/dhcp.mk buildroot-2017.05.2/package/dhcp/dhcp.mk
2203 --- buildroot-2017.05-rc2/package/dhcp/dhcp.mk 2017-05-17 10:27:16.013401440 +0200
2204 +++ buildroot-2017.05.2/package/dhcp/dhcp.mk 2017-07-27 08:16:52.017486944 +0200
2205 @@ -102,6 +102,7 @@ define DHCP_INSTALL_INIT_SYSTEMD
2206 ln -sf ../../../../usr/lib/systemd/system/dhcpd.service \
2207 $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/dhcpd.service
2209 + mkdir -p $(TARGET_DIR)/usr/lib/tmpfiles.d
2210 echo "d /var/lib/dhcp 0755 - - - -" > \
2211 $(TARGET_DIR)/usr/lib/tmpfiles.d/dhcpd.conf
2212 echo "f /var/lib/dhcp/dhcpd.leases - - - - -" >> \
2213 diff -Naurp buildroot-2017.05-rc2/package/dieharder/0004-Add-static-to-inline-functions.patch buildroot-2017.05.2/package/dieharder/0004-Add-static-to-inline-functions.patch
2214 --- buildroot-2017.05-rc2/package/dieharder/0004-Add-static-to-inline-functions.patch 1970-01-01 01:00:00.000000000 +0100
2215 +++ buildroot-2017.05.2/package/dieharder/0004-Add-static-to-inline-functions.patch 2017-07-27 08:16:52.017486944 +0200
2216 @@ -0,0 +1,65 @@
2217 +From 9c71a211dcf20f53f747326f5bc3fee9fabe3f52 Mon Sep 17 00:00:00 2001
2218 +From: Julien Viard de Galbert <julien@vdg.name>
2219 +Date: Tue, 27 Jun 2017 00:16:11 +0200
2220 +Subject: [PATCH] Add static to inline functions
2222 +This is needed to avoid a link error where the inline functions appear
2223 +missing at link time.
2224 +From c99 standard inline function should either be declared static or
2225 +have an extern instance in a c file for linking.
2226 +This fix is necessary to build with gcc 7; for some reason it was not
2227 +trigerred before.
2229 +Signed-off-by: Julien Viard de Galbert <julien@vdg.name>
2230 +---
2231 + libdieharder/dab_filltree.c | 4 ++--
2232 + libdieharder/dab_filltree2.c | 4 ++--
2233 + 2 files changed, 4 insertions(+), 4 deletions(-)
2235 +diff --git a/libdieharder/dab_filltree.c b/libdieharder/dab_filltree.c
2236 +index 9cc5ce7..a377c3d 100644
2237 +--- a/libdieharder/dab_filltree.c
2238 ++++ b/libdieharder/dab_filltree.c
2239 +@@ -34,7 +34,7 @@ static double targetData[] = {
2240 + 0.0, 0.0, 0.0, 0.0, 0.13333333, 0.20000000, 0.20634921, 0.17857143, 0.13007085, 0.08183633, 0.04338395, 0.01851828, 0.00617270, 0.00151193, 0.00023520, 0.00001680, 0.00000000, 0.00000000, 0.00000000, 0.00000000
2241 + };
2243 +-inline int insert(double x, double *array, unsigned int startVal);
2244 ++static inline int insert(double x, double *array, unsigned int startVal);
2246 + int dab_filltree(Test **test,int irun) {
2247 + int size = (ntuple == 0) ? 32 : ntuple;
2248 +@@ -105,7 +105,7 @@ int dab_filltree(Test **test,int irun) {
2252 +-inline int insert(double x, double *array, unsigned int startVal) {
2253 ++static inline int insert(double x, double *array, unsigned int startVal) {
2254 + uint d = (startVal + 1) / 2;
2255 + uint i = startVal;
2256 + while (d > 0) {
2257 +diff --git a/libdieharder/dab_filltree2.c b/libdieharder/dab_filltree2.c
2258 +index 1e33af2..59cbd52 100644
2259 +--- a/libdieharder/dab_filltree2.c
2260 ++++ b/libdieharder/dab_filltree2.c
2261 +@@ -92,7 +92,7 @@ static double targetData[128] = { // size=128, generated from 6e9 samples
2262 + 0.00000000000e+00,0.00000000000e+00,0.00000000000e+00,0.00000000000e+00,
2263 + };
2265 +-inline int insertBit(uint x, uchar *array, uint *i, uint *d);
2266 ++static inline int insertBit(uint x, uchar *array, uint *i, uint *d);
2268 + int dab_filltree2(Test **test, int irun) {
2269 + int size = (ntuple == 0) ? 128 : ntuple;
2270 +@@ -181,7 +181,7 @@ int dab_filltree2(Test **test, int irun) {
2271 + * The function returns >= 0 if the path went too deep; the
2272 + * returned value is the last position of the path.
2273 + */
2274 +-inline int insertBit(uint x, uchar *array, uint *i, uint *d) {
2275 ++static inline int insertBit(uint x, uchar *array, uint *i, uint *d) {
2276 + if (x != 0) {
2277 + *i += *d;
2278 + } else {
2279 +--
2280 +2.13.2
2282 diff -Naurp buildroot-2017.05-rc2/package/docker-engine/docker-engine.mk buildroot-2017.05.2/package/docker-engine/docker-engine.mk
2283 --- buildroot-2017.05-rc2/package/docker-engine/docker-engine.mk 2017-05-17 10:27:16.013401440 +0200
2284 +++ buildroot-2017.05.2/package/docker-engine/docker-engine.mk 2017-07-27 08:16:52.017486944 +0200
2285 @@ -42,6 +42,11 @@ DOCKER_ENGINE_BUILD_TAGS += seccomp
2286 DOCKER_ENGINE_DEPENDENCIES += libseccomp
2287 endif
2289 +ifeq ($(BR2_INIT_SYSTEMD),y)
2290 +DOCKER_ENGINE_BUILD_TAGS += journald
2291 +DOCKER_ENGINE_DEPENDENCIES += systemd
2292 +endif
2294 ifeq ($(BR2_PACKAGE_DOCKER_ENGINE_DAEMON),y)
2295 DOCKER_ENGINE_BUILD_TAGS += daemon
2296 DOCKER_ENGINE_BUILD_TARGETS += dockerd
2297 diff -Naurp buildroot-2017.05-rc2/package/dropbear/dropbear.hash buildroot-2017.05.2/package/dropbear/dropbear.hash
2298 --- buildroot-2017.05-rc2/package/dropbear/dropbear.hash 2017-05-17 10:27:16.013401440 +0200
2299 +++ buildroot-2017.05.2/package/dropbear/dropbear.hash 2017-07-27 08:16:52.017486944 +0200
2300 @@ -1,2 +1,2 @@
2301 # From https://matt.ucc.asn.au/dropbear/releases/SHA256SUM.asc
2302 -sha256 2720ea54ed009af812701bcc290a2a601d5c107d12993e5d92c0f5f81f718891 dropbear-2016.74.tar.bz2
2303 +sha256 6cbc1dcb1c9709d226dff669e5604172a18cf5dbf9a201474d5618ae4465098c dropbear-2017.75.tar.bz2
2304 diff -Naurp buildroot-2017.05-rc2/package/dropbear/dropbear.mk buildroot-2017.05.2/package/dropbear/dropbear.mk
2305 --- buildroot-2017.05-rc2/package/dropbear/dropbear.mk 2017-05-17 10:27:16.013401440 +0200
2306 +++ buildroot-2017.05.2/package/dropbear/dropbear.mk 2017-07-27 08:16:52.017486944 +0200
2307 @@ -4,7 +4,7 @@
2309 ################################################################################
2311 -DROPBEAR_VERSION = 2016.74
2312 +DROPBEAR_VERSION = 2017.75
2313 DROPBEAR_SITE = http://matt.ucc.asn.au/dropbear/releases
2314 DROPBEAR_SOURCE = dropbear-$(DROPBEAR_VERSION).tar.bz2
2315 DROPBEAR_LICENSE = MIT, BSD-2-Clause-like, BSD-2-Clause
2316 diff -Naurp buildroot-2017.05-rc2/package/efibootmgr/0003-Remove-extra-const-keywords-gcc-7-gripes-about.patch buildroot-2017.05.2/package/efibootmgr/0003-Remove-extra-const-keywords-gcc-7-gripes-about.patch
2317 --- buildroot-2017.05-rc2/package/efibootmgr/0003-Remove-extra-const-keywords-gcc-7-gripes-about.patch 1970-01-01 01:00:00.000000000 +0100
2318 +++ buildroot-2017.05.2/package/efibootmgr/0003-Remove-extra-const-keywords-gcc-7-gripes-about.patch 2017-07-27 08:16:52.017486944 +0200
2319 @@ -0,0 +1,51 @@
2320 +From a542b169003c2ef95ce6c00d40050eb10568b612 Mon Sep 17 00:00:00 2001
2321 +From: Peter Jones <pjones@redhat.com>
2322 +Date: Mon, 6 Feb 2017 16:34:54 -0500
2323 +Subject: [PATCH] Remove extra const keywords gcc 7 gripes about.
2325 +Signed-off-by: Peter Jones <pjones@redhat.com>
2326 +[Backported from upstream commit a542b169003c2ef95ce6c00d40050eb10568b612]
2327 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2328 +---
2329 + src/efibootdump.c | 2 +-
2330 + src/efibootmgr.c | 4 ++--
2331 + 2 files changed, 3 insertions(+), 3 deletions(-)
2333 +diff --git a/src/efibootdump.c b/src/efibootdump.c
2334 +index 6ff8360..30a1943 100644
2335 +--- a/src/efibootdump.c
2336 ++++ b/src/efibootdump.c
2337 +@@ -39,7 +39,7 @@ print_boot_entry(efi_load_option *loadopt, size_t data_size)
2338 + uint8_t *optional_data = NULL;
2339 + size_t optional_data_len = 0;
2340 + uint16_t pathlen;
2341 +- const unsigned char const *desc;
2342 ++ const unsigned char *desc;
2343 + char *raw;
2344 + size_t raw_len;
2346 +diff --git a/src/efibootmgr.c b/src/efibootmgr.c
2347 +index 493f2cf..90a0998 100644
2348 +--- a/src/efibootmgr.c
2349 ++++ b/src/efibootmgr.c
2350 +@@ -221,7 +221,7 @@ warn_duplicate_name(list_t *var_list)
2351 + list_t *pos;
2352 + var_entry_t *entry;
2353 + efi_load_option *load_option;
2354 +- const unsigned char const *desc;
2355 ++ const unsigned char *desc;
2357 + list_for_each(pos, var_list) {
2358 + entry = list_entry(pos, var_entry_t, list);
2359 +@@ -873,7 +873,7 @@ show_vars(const char *prefix)
2361 + list_t *pos;
2362 + var_entry_t *boot;
2363 +- const unsigned char const *description;
2364 ++ const unsigned char *description;
2365 + efi_load_option *load_option;
2366 + efidp dp = NULL;
2367 + unsigned char *optional_data = NULL;
2368 +--
2369 +2.9.4
2371 diff -Naurp buildroot-2017.05-rc2/package/efivar/0003-Remove-some-extra-const-that-gcc-complains-about.patch buildroot-2017.05.2/package/efivar/0003-Remove-some-extra-const-that-gcc-complains-about.patch
2372 --- buildroot-2017.05-rc2/package/efivar/0003-Remove-some-extra-const-that-gcc-complains-about.patch 1970-01-01 01:00:00.000000000 +0100
2373 +++ buildroot-2017.05.2/package/efivar/0003-Remove-some-extra-const-that-gcc-complains-about.patch 2017-07-27 08:16:52.017486944 +0200
2374 @@ -0,0 +1,47 @@
2375 +From 1c7c0f71c9d22efda4156881eb187b8c69d1cca7 Mon Sep 17 00:00:00 2001
2376 +From: Peter Jones <pjones@redhat.com>
2377 +Date: Mon, 6 Feb 2017 14:28:19 -0500
2378 +Subject: [PATCH] Remove some extra "const" that gcc complains about.
2380 +One of these days I'll get these right.
2382 +Signed-off-by: Peter Jones <pjones@redhat.com>
2383 +Signed-off-by: Baruch Siach <baruch@tkos.co.il>
2384 +---
2385 +Upstream commit 1c7c0f71c9d22e.
2387 + src/include/efivar/efiboot-loadopt.h | 4 ++--
2388 + src/loadopt.c | 2 +-
2389 + 2 files changed, 3 insertions(+), 3 deletions(-)
2391 +diff --git a/src/include/efivar/efiboot-loadopt.h b/src/include/efivar/efiboot-loadopt.h
2392 +index 07db5c4c53e3..efc29c69d47e 100644
2393 +--- a/src/include/efivar/efiboot-loadopt.h
2394 ++++ b/src/include/efivar/efiboot-loadopt.h
2395 +@@ -32,8 +32,8 @@ extern ssize_t efi_loadopt_create(uint8_t *buf, ssize_t size,
2397 + extern efidp efi_loadopt_path(efi_load_option *opt, ssize_t limit)
2398 + __attribute__((__nonnull__ (1)));
2399 +-extern const unsigned char const * efi_loadopt_desc(efi_load_option *opt,
2400 +- ssize_t limit)
2401 ++extern const unsigned char * efi_loadopt_desc(efi_load_option *opt,
2402 ++ ssize_t limit)
2403 + __attribute__((__visibility__ ("default")))
2404 + __attribute__((__nonnull__ (1)));
2405 + extern uint32_t efi_loadopt_attrs(efi_load_option *opt)
2406 +diff --git a/src/loadopt.c b/src/loadopt.c
2407 +index a63ca792d2dc..ce889867fd29 100644
2408 +--- a/src/loadopt.c
2409 ++++ b/src/loadopt.c
2410 +@@ -357,7 +357,7 @@ teardown(void)
2412 + __attribute__((__nonnull__ (1)))
2413 + __attribute__((__visibility__ ("default")))
2414 +-const unsigned char const *
2415 ++const unsigned char *
2416 + efi_loadopt_desc(efi_load_option *opt, ssize_t limit)
2418 + if (last_desc) {
2419 +--
2420 +2.13.2
2422 diff -Naurp buildroot-2017.05-rc2/package/elfutils/0002-disable-progs.patch buildroot-2017.05.2/package/elfutils/0002-disable-progs.patch
2423 --- buildroot-2017.05-rc2/package/elfutils/0002-disable-progs.patch 2017-05-17 10:27:16.013401440 +0200
2424 +++ buildroot-2017.05.2/package/elfutils/0002-disable-progs.patch 2017-07-27 08:16:52.017486944 +0200
2425 @@ -1,4 +1,7 @@
2426 -Add a --{enable,disable}-progs configure option
2427 +From dfea82b761b2ea4708fbf9370a5467ae4be525ca Mon Sep 17 00:00:00 2001
2428 +From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2429 +Date: Mon, 29 May 2017 23:03:48 +0300
2430 +Subject: [PATCH] Add a --{enable,disable}-progs configure option
2432 Add a --{enable,disable}-progs configuration option to elfutils. This
2433 allows to selectively disable the compilation of the elfutils programs
2434 @@ -13,26 +16,15 @@ Based on the former patch by Thomas Peta
2436 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2437 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
2438 +---
2439 + Makefile.am | 6 +++++-
2440 + configure.ac | 6 ++++++
2441 + 2 files changed, 11 insertions(+), 1 deletion(-)
2443 -diff -rup a/configure.ac b/configure.ac
2444 ---- a/configure.ac 2016-03-31 09:48:08.000000000 +0100
2445 -+++ b/configure.ac 2016-06-17 14:47:03.561704498 +0100
2446 -@@ -253,6 +253,12 @@ AC_SUBST([LIBEBL_SUBDIR])
2447 - AC_DEFINE_UNQUOTED(LIBEBL_SUBDIR, "$LIBEBL_SUBDIR")
2448 - AH_TEMPLATE([LIBEBL_SUBDIR], [$libdir subdirectory containing libebl modules.])
2450 -+AC_ARG_ENABLE([progs],
2451 -+ AS_HELP_STRING([--enable-progs], [enable progs]),
2452 -+ enable_progs=$enableval,
2453 -+ enable_progs=yes)
2454 -+AM_CONDITIONAL(ENABLE_PROGS, test "$enable_progs" = yes)
2456 - dnl zlib is mandatory.
2457 - save_LIBS="$LIBS"
2458 - LIBS=
2459 -diff -rup a/Makefile.am b/Makefile.am
2460 ---- a/Makefile.am 2016-01-12 12:49:19.000000000 +0000
2461 -+++ b/Makefile.am 2016-06-17 14:48:02.585861468 +0100
2462 +diff --git a/Makefile.am b/Makefile.am
2463 +index 2ff444e7bf1d..70443abb4fb6 100644
2464 +--- a/Makefile.am
2465 ++++ b/Makefile.am
2466 @@ -26,9 +26,13 @@ AM_MAKEFLAGS = --no-print-directory
2468 pkginclude_HEADERS = version.h
2469 @@ -48,3 +40,23 @@ diff -rup a/Makefile.am b/Makefile.am
2471 EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \
2472 COPYING COPYING-GPLV2 COPYING-LGPLV3
2473 +diff --git a/configure.ac b/configure.ac
2474 +index c2c1d90b2133..7b4c38381cca 100644
2475 +--- a/configure.ac
2476 ++++ b/configure.ac
2477 +@@ -259,6 +259,12 @@ AC_SUBST([LIBEBL_SUBDIR])
2478 + AC_DEFINE_UNQUOTED(LIBEBL_SUBDIR, "$LIBEBL_SUBDIR")
2479 + AH_TEMPLATE([LIBEBL_SUBDIR], [$libdir subdirectory containing libebl modules.])
2481 ++AC_ARG_ENABLE([progs],
2482 ++ AS_HELP_STRING([--enable-progs], [enable progs]),
2483 ++ enable_progs=$enableval,
2484 ++ enable_progs=yes)
2485 ++AM_CONDITIONAL(ENABLE_PROGS, test "$enable_progs" = yes)
2487 + dnl zlib is mandatory.
2488 + save_LIBS="$LIBS"
2489 + LIBS=
2490 +--
2491 +2.11.0
2493 diff -Naurp buildroot-2017.05-rc2/package/elfutils/0003-fts.patch buildroot-2017.05.2/package/elfutils/0003-fts.patch
2494 --- buildroot-2017.05-rc2/package/elfutils/0003-fts.patch 2017-05-17 10:27:16.013401440 +0200
2495 +++ buildroot-2017.05.2/package/elfutils/0003-fts.patch 2017-07-27 08:16:52.017486944 +0200
2496 @@ -1,4 +1,7 @@
2497 -Add an implementation of the fts_*() functions
2498 +From 098760f7eac1fb86b3f6871d5bb10f9f44468f2d Mon Sep 17 00:00:00 2001
2499 +From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2500 +Date: Mon, 29 May 2017 23:08:05 +0300
2501 +Subject: [PATCH] Add an implementation of the fts_*() functions
2503 The fts_*() functions are optional in uClibc, and not compiled in our
2504 default configuration. The best option would be to migrate this
2505 @@ -28,11 +31,21 @@ Based on the former patch by Thomas Peta
2507 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2508 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
2509 +---
2510 + configure.ac | 4 +
2511 + libdwfl/Makefile.am | 3 +
2512 + libdwfl/fts.c | 1095 ++++++++++++++++++++++++++++++++++++++++
2513 + libdwfl/fts_.h | 131 +++++
2514 + libdwfl/linux-kernel-modules.c | 4 +
2515 + 5 files changed, 1237 insertions(+)
2516 + create mode 100644 libdwfl/fts.c
2517 + create mode 100644 libdwfl/fts_.h
2519 -diff -Nrup a/configure.ac b/configure.ac
2520 ---- a/configure.ac 2016-06-17 14:47:03.561704498 +0100
2521 -+++ b/configure.ac 2016-06-17 14:52:35.038200412 +0100
2522 -@@ -259,6 +259,10 @@ AC_ARG_ENABLE([progs],
2523 +diff --git a/configure.ac b/configure.ac
2524 +index 7b4c38381cca..bcebb05fa532 100644
2525 +--- a/configure.ac
2526 ++++ b/configure.ac
2527 +@@ -265,6 +265,10 @@ AC_ARG_ENABLE([progs],
2528 enable_progs=yes)
2529 AM_CONDITIONAL(ENABLE_PROGS, test "$enable_progs" = yes)
2531 @@ -43,9 +56,25 @@ diff -Nrup a/configure.ac b/configure.ac
2532 dnl zlib is mandatory.
2533 save_LIBS="$LIBS"
2534 LIBS=
2535 -diff -Nrup a/libdwfl/fts.c b/libdwfl/fts.c
2536 ---- a/libdwfl/fts.c 1970-01-01 01:00:00.000000000 +0100
2537 -+++ b/libdwfl/fts.c 2016-06-17 14:57:26.649912084 +0100
2538 +diff --git a/libdwfl/Makefile.am b/libdwfl/Makefile.am
2539 +index 89ca92ed8110..a5a5615c5f94 100644
2540 +--- a/libdwfl/Makefile.am
2541 ++++ b/libdwfl/Makefile.am
2542 +@@ -77,6 +77,9 @@ endif
2543 + if LZMA
2544 + libdwfl_a_SOURCES += lzma.c
2545 + endif
2546 ++if !HAVE_FTS
2547 ++libdwfl_a_SOURCES += fts.c
2548 ++endif
2550 + libdwfl = $(libdw)
2551 + libdw = ../libdw/libdw.so
2552 +diff --git a/libdwfl/fts.c b/libdwfl/fts.c
2553 +new file mode 100644
2554 +index 000000000000..f34cc03bd963
2555 +--- /dev/null
2556 ++++ b/libdwfl/fts.c
2557 @@ -0,0 +1,1095 @@
2558 +/*-
2559 + * Copyright (c) 1990, 1993, 1994
2560 @@ -1142,9 +1171,11 @@ diff -Nrup a/libdwfl/fts.c b/libdwfl/fts
2561 + errno = oerrno;
2562 + return (ret);
2564 -diff -Nrup a/libdwfl/fts_.h b/libdwfl/fts_.h
2565 ---- a/libdwfl/fts_.h 1970-01-01 01:00:00.000000000 +0100
2566 -+++ b/libdwfl/fts_.h 2016-06-17 14:58:42.003387566 +0100
2567 +diff --git a/libdwfl/fts_.h b/libdwfl/fts_.h
2568 +new file mode 100644
2569 +index 000000000000..0a070ba8dce5
2570 +--- /dev/null
2571 ++++ b/libdwfl/fts_.h
2572 @@ -0,0 +1,131 @@
2574 + * Copyright (c) 1989, 1993
2575 @@ -1277,31 +1308,25 @@ diff -Nrup a/libdwfl/fts_.h b/libdwfl/ft
2576 +__END_DECLS
2578 +#endif /* fts.h */
2579 -diff -Nrup a/libdwfl/linux-kernel-modules.c b/libdwfl/linux-kernel-modules.c
2580 ---- a/libdwfl/linux-kernel-modules.c 2016-03-02 16:25:38.000000000 +0000
2581 -+++ b/libdwfl/linux-kernel-modules.c 2016-06-17 14:59:50.267724089 +0100
2582 -@@ -29,7 +29,11 @@
2583 - /* We include this before config.h because it can't handle _FILE_OFFSET_BITS.
2584 - Everything we need here is fine if its declarations just come first. */
2586 +diff --git a/libdwfl/linux-kernel-modules.c b/libdwfl/linux-kernel-modules.c
2587 +index 9d0fef2cf260..47f0e3892294 100644
2588 +--- a/libdwfl/linux-kernel-modules.c
2589 ++++ b/libdwfl/linux-kernel-modules.c
2590 +@@ -31,10 +31,14 @@
2591 + Everything we need here is fine if its declarations just come first.
2592 + Also, include sys/types.h before fts. On some systems fts.h is not self
2593 + contained. */
2594 +#ifdef HAVE_FTS_H
2595 - #include <fts.h>
2596 + #ifdef BAD_FTS
2597 + #include <sys/types.h>
2598 + #include <fts.h>
2599 + #endif
2600 +#else
2601 +#include <fts_.h>
2602 +#endif
2604 #include <config.h>
2606 -diff -Nrup a/libdwfl/Makefile.am b/libdwfl/Makefile.am
2607 ---- a/libdwfl/Makefile.am 2016-01-12 12:49:19.000000000 +0000
2608 -+++ b/libdwfl/Makefile.am 2016-06-17 15:01:03.492157569 +0100
2609 -@@ -77,6 +77,9 @@ endif
2610 - if LZMA
2611 - libdwfl_a_SOURCES += lzma.c
2612 - endif
2613 -+if !HAVE_FTS
2614 -+libdwfl_a_SOURCES += fts.c
2615 -+endif
2617 - libdwfl = $(libdw)
2618 - libdw = ../libdw/libdw.so
2619 + #include <system.h>
2620 +--
2621 +2.11.0
2623 diff -Naurp buildroot-2017.05-rc2/package/elfutils/0005-really-make-werror-conditional-to-build-werror.patch buildroot-2017.05.2/package/elfutils/0005-really-make-werror-conditional-to-build-werror.patch
2624 --- buildroot-2017.05-rc2/package/elfutils/0005-really-make-werror-conditional-to-build-werror.patch 2017-05-17 10:27:16.013401440 +0200
2625 +++ buildroot-2017.05.2/package/elfutils/0005-really-make-werror-conditional-to-build-werror.patch 2017-07-27 08:16:52.017486944 +0200
2626 @@ -1,4 +1,7 @@
2627 -Really make -Werror conditional to BUILD_WERROR
2628 +From 1d8f27d73df6369b19ddd6732960df0d4fdec338 Mon Sep 17 00:00:00 2001
2629 +From: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
2630 +Date: Mon, 29 May 2017 23:24:42 +0300
2631 +Subject: [PATCH] Really make -Werror conditional to BUILD_WERROR
2633 Otherwise it will fail with an error message like this one:
2635 @@ -12,15 +15,22 @@ cc1: all warnings being treated as error
2637 Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2638 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
2639 +---
2640 + config/eu.am | 1 -
2641 + 1 file changed, 1 deletion(-)
2643 -diff -rup a/config/eu.am b/config/eu.am
2644 ---- a/config/eu.am 2016-03-02 16:25:38.000000000 +0000
2645 -+++ b/config/eu.am 2016-06-17 15:05:08.270974835 +0100
2646 -@@ -65,7 +65,6 @@ AM_CFLAGS = -std=gnu99 -Wall -Wshadow -W
2647 +diff --git a/config/eu.am b/config/eu.am
2648 +index 8fe1e259f9e2..c5a6209a4e04 100644
2649 +--- a/config/eu.am
2650 ++++ b/config/eu.am
2651 +@@ -71,7 +71,6 @@ AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \
2652 -Wold-style-definition -Wstrict-prototypes \
2653 $(LOGICAL_OP_WARNING) $(DUPLICATED_COND_WARNING) \
2654 - $(NULL_DEREFERENCE_WARNING) \
2655 + $(NULL_DEREFERENCE_WARNING) $(IMPLICIT_FALLTHROUGH_WARNING) \
2656 - $(if $($(*F)_no_Werror),,-Werror) \
2657 $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \
2658 $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \
2659 $($(*F)_CFLAGS)
2660 +--
2661 +2.11.0
2663 diff -Naurp buildroot-2017.05-rc2/package/elfutils/elfutils.hash buildroot-2017.05.2/package/elfutils/elfutils.hash
2664 --- buildroot-2017.05-rc2/package/elfutils/elfutils.hash 2017-05-17 10:27:16.013401440 +0200
2665 +++ buildroot-2017.05.2/package/elfutils/elfutils.hash 2017-07-27 08:16:52.017486944 +0200
2666 @@ -1,2 +1,2 @@
2667 -# Locally calculated
2668 -sha256 3c056914c8a438b210be0d790463b960fc79d234c3f05ce707cbff80e94cba30 elfutils-0.166.tar.bz2
2669 +# From https://sourceware.org/elfutils/ftp/0.169/sha512.sum
2670 +sha512 0a81a20bb2aff533d035d6b76f1403437b2e11bce390db57e34b8c26e4b9b3150346d83dddcbfbbdc58063f046ca3223508dba35c6ce88e375d201e7a777a8b9 elfutils-0.169.tar.bz2
2671 diff -Naurp buildroot-2017.05-rc2/package/elfutils/elfutils.mk buildroot-2017.05.2/package/elfutils/elfutils.mk
2672 --- buildroot-2017.05-rc2/package/elfutils/elfutils.mk 2017-05-17 10:27:16.013401440 +0200
2673 +++ buildroot-2017.05.2/package/elfutils/elfutils.mk 2017-07-27 08:16:52.017486944 +0200
2674 @@ -4,7 +4,7 @@
2676 ################################################################################
2678 -ELFUTILS_VERSION = 0.166
2679 +ELFUTILS_VERSION = 0.169
2680 ELFUTILS_SOURCE = elfutils-$(ELFUTILS_VERSION).tar.bz2
2681 ELFUTILS_SITE = https://sourceware.org/elfutils/ftp/$(ELFUTILS_VERSION)
2682 ELFUTILS_INSTALL_STAGING = YES
2683 @@ -20,11 +20,9 @@ HOST_ELFUTILS_AUTORECONF = YES
2684 # Pass a custom program prefix to avoid a naming conflict between
2685 # elfutils binaries and binutils binaries.
2686 ELFUTILS_CONF_OPTS += \
2687 - --disable-werror \
2688 --program-prefix="eu-"
2690 HOST_ELFUTILS_CONF_OPTS = \
2691 - --disable-werror \
2692 --with-bzlib \
2693 --with-lzma \
2694 --disable-progs
2695 diff -Naurp buildroot-2017.05-rc2/package/erlang/Config.in buildroot-2017.05.2/package/erlang/Config.in
2696 --- buildroot-2017.05-rc2/package/erlang/Config.in 2017-05-17 10:27:16.013401440 +0200
2697 +++ buildroot-2017.05.2/package/erlang/Config.in 2017-07-27 08:16:52.017486944 +0200
2698 @@ -16,11 +16,12 @@ config BR2_PACKAGE_ERLANG
2699 depends on !BR2_STATIC_LIBS
2700 depends on BR2_PACKAGE_ERLANG_ARCH_SUPPORTS
2701 help
2702 - Erlang is a programming language used to build massively scalable
2703 - soft real-time systems with requirements on high availability.
2704 - Some of its uses are in telecoms, banking, e-commerce, computer
2705 - telephony and instant messaging. Erlang's runtime system has
2706 - built-in support for concurrency, distribution and fault tolerance.
2707 + Erlang is a programming language used to build massively
2708 + scalable soft real-time systems with requirements on high
2709 + availability. Some of its uses are in telecoms, banking,
2710 + e-commerce, computer telephony and instant messaging.
2711 + Erlang's runtime system has built-in support for
2712 + concurrency, distribution and fault tolerance.
2714 http://www.erlang.org
2716 @@ -29,18 +30,19 @@ if BR2_PACKAGE_ERLANG
2717 config BR2_PACKAGE_ERLANG_SMP
2718 bool "enable SMP support"
2719 help
2720 - Erlang provides both a UP and an SMP emulator. The UP emulator
2721 - is always built, and this option enables compilation of the SMP
2722 - emulator. The choice of which emulator to use is made at runtime.
2723 - If you do not need SMP support, turning this option off reduces
2724 - compile time and the size of the Erlang installation.
2725 + Erlang provides both a UP and an SMP emulator. The UP
2726 + emulator is always built, and this option enables
2727 + compilation of the SMP emulator. The choice of which
2728 + emulator to use is made at runtime. If you do not need SMP
2729 + support, turning this option off reduces compile time and
2730 + the size of the Erlang installation.
2732 config BR2_PACKAGE_ERLANG_MEGACO
2733 bool "install megaco application"
2734 help
2735 - The Megaco application is a framework for building applications
2736 - on top of the Megaco/H.248 protocol. It is approximately 14MB in
2737 - size so if you do not need it then it is recommended not to
2738 - enable it.
2739 + The Megaco application is a framework for building
2740 + applications on top of the Megaco/H.248 protocol. It is
2741 + approximately 14MB in size so if you do not need it then
2742 + it is recommended not to enable it.
2744 endif # BR2_PACKAGE_ERLANG
2745 diff -Naurp buildroot-2017.05-rc2/package/exim/Config.in buildroot-2017.05.2/package/exim/Config.in
2746 --- buildroot-2017.05-rc2/package/exim/Config.in 2017-05-17 10:27:16.013401440 +0200
2747 +++ buildroot-2017.05.2/package/exim/Config.in 2017-07-27 08:16:52.017486944 +0200
2748 @@ -8,8 +8,9 @@ config BR2_PACKAGE_EXIM
2749 select BR2_PACKAGE_PCRE
2750 select BR2_PACKAGE_BERKELEYDB
2751 help
2752 - Exim is a message transfer agent (MTA) developed at the University of
2753 - Cambridge for use on Unix systems connected to the Internet.
2754 + Exim is a message transfer agent (MTA) developed at the
2755 + University of Cambridge for use on Unix systems connected to
2756 + the Internet.
2758 http://www.exim.org/
2760 diff -Naurp buildroot-2017.05-rc2/package/expat/expat.hash buildroot-2017.05.2/package/expat/expat.hash
2761 --- buildroot-2017.05-rc2/package/expat/expat.hash 2017-05-17 10:27:16.013401440 +0200
2762 +++ buildroot-2017.05.2/package/expat/expat.hash 2017-07-27 08:16:52.017486944 +0200
2763 @@ -1,5 +1,5 @@
2764 -# From https://sourceforge.net/projects/expat/files/expat/2.2.0/
2765 -md5 2f47841c829facb346eb6e3fab5212e2 expat-2.2.0.tar.bz2
2766 -sha1 8453bc52324be4c796fd38742ec48470eef358b3 expat-2.2.0.tar.bz2
2767 +# From https://sourceforge.net/projects/expat/files/expat/2.2.2/
2768 +md5 1ede9a41223c78528b8c5d23e69a2667 expat-2.2.2.tar.bz2
2769 +sha1 891cee988b38d5d66953f62f94c3150b8810a70a expat-2.2.2.tar.bz2
2770 # Calculated based on the hashes above
2771 -sha256 d9e50ff2d19b3538bd2127902a89987474e1a4db8e43a66a4d1a712ab9a504ff expat-2.2.0.tar.bz2
2772 +sha256 4376911fcf81a23ebd821bbabc26fd933f3ac74833f74924342c29aad2c86046 expat-2.2.2.tar.bz2
2773 diff -Naurp buildroot-2017.05-rc2/package/expat/expat.mk buildroot-2017.05.2/package/expat/expat.mk
2774 --- buildroot-2017.05-rc2/package/expat/expat.mk 2017-05-17 10:27:16.013401440 +0200
2775 +++ buildroot-2017.05.2/package/expat/expat.mk 2017-07-27 08:16:52.017486944 +0200
2776 @@ -4,7 +4,7 @@
2778 ################################################################################
2780 -EXPAT_VERSION = 2.2.0
2781 +EXPAT_VERSION = 2.2.2
2782 EXPAT_SITE = http://downloads.sourceforge.net/project/expat/expat/$(EXPAT_VERSION)
2783 EXPAT_SOURCE = expat-$(EXPAT_VERSION).tar.bz2
2784 EXPAT_INSTALL_STAGING = YES
2785 @@ -15,5 +15,14 @@ HOST_EXPAT_DEPENDENCIES = host-pkgconf
2786 EXPAT_LICENSE = MIT
2787 EXPAT_LICENSE_FILES = COPYING
2789 +# Kernel versions older than 3.17 do not support getrandom()
2790 +ifeq ($(BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_17),)
2791 +EXPAT_CONF_ENV += CPPFLAGS="$(TARGET_CPPFLAGS) -DXML_POOR_ENTROPY"
2792 +endif
2794 +# Make build succeed on host kernel older than 3.17. getrandom() will still
2795 +# be used on newer kernels.
2796 +HOST_EXPAT_CONF_ENV += CPPFLAGS="$(HOST_CPPFLAGS) -DXML_POOR_ENTROPY"
2798 $(eval $(autotools-package))
2799 $(eval $(host-autotools-package))
2800 diff -Naurp buildroot-2017.05-rc2/package/fbgrab/fbgrab.mk buildroot-2017.05.2/package/fbgrab/fbgrab.mk
2801 --- buildroot-2017.05-rc2/package/fbgrab/fbgrab.mk 2017-05-17 10:27:16.013401440 +0200
2802 +++ buildroot-2017.05.2/package/fbgrab/fbgrab.mk 2017-07-27 08:16:52.017486944 +0200
2803 @@ -11,7 +11,7 @@ FBGRAB_LICENSE = GPL-2.0
2804 FBGRAB_LICENSE_FILES = COPYING
2806 define FBGRAB_BUILD_CMDS
2807 - $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)
2808 + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) fbgrab
2809 endef
2811 define FBGRAB_INSTALL_TARGET_CMDS
2812 diff -Naurp buildroot-2017.05-rc2/package/fcgiwrap/fcgiwrap.mk buildroot-2017.05.2/package/fcgiwrap/fcgiwrap.mk
2813 --- buildroot-2017.05-rc2/package/fcgiwrap/fcgiwrap.mk 2017-05-17 10:27:16.013401440 +0200
2814 +++ buildroot-2017.05.2/package/fcgiwrap/fcgiwrap.mk 2017-07-27 08:16:52.017486944 +0200
2815 @@ -10,6 +10,7 @@ FCGIWRAP_DEPENDENCIES = host-pkgconf lib
2816 FCGIWRAP_LICENSE = MIT
2817 FCGIWRAP_LICENSE_FILES = COPYING
2818 FCGIWRAP_AUTORECONF = YES
2819 +FCGIWRAP_CONF_ENV = CFLAGS="$(TARGET_CFLAGS) -Wno-error"
2821 ifeq ($(BR2_PACKAGE_SYSTEMD),y)
2822 FCGIWRAP_DEPENDENCIES += systemd
2823 diff -Naurp buildroot-2017.05-rc2/package/ffmpeg/Config.in buildroot-2017.05.2/package/ffmpeg/Config.in
2824 --- buildroot-2017.05-rc2/package/ffmpeg/Config.in 2017-05-17 10:27:16.013401440 +0200
2825 +++ buildroot-2017.05.2/package/ffmpeg/Config.in 2017-07-27 08:16:52.017486944 +0200
2826 @@ -3,7 +3,13 @@ config BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
2827 # fenv.h lacks FE_INVALID, FE_OVERFLOW & FE_UNDERFLOW on nios2
2828 # No support for ARMv7-M in the ARM assembly logic
2829 # Microblaze build affected by gcc PR71124 (infinite loop)
2830 - default y if !BR2_nios2 && !BR2_ARM_CPU_ARMV7M && !BR2_microblaze
2831 + # m68k coldfire causes a build failure, because the check for
2832 + # atomics (atomic_store) succeeds, which causes ffmpeg to
2833 + # think atomic intrinsics are available, while they are
2834 + # not. See https://patchwork.ozlabs.org/patch/756664/ and
2835 + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68467 for more
2836 + # details.
2837 + default y if !BR2_nios2 && !BR2_ARM_CPU_ARMV7M && !BR2_microblaze && !BR2_m68k_cf
2839 menuconfig BR2_PACKAGE_FFMPEG
2840 bool "ffmpeg"
2841 diff -Naurp buildroot-2017.05-rc2/package/ffmpeg/ffmpeg.mk buildroot-2017.05.2/package/ffmpeg/ffmpeg.mk
2842 --- buildroot-2017.05-rc2/package/ffmpeg/ffmpeg.mk 2017-05-17 10:27:16.013401440 +0200
2843 +++ buildroot-2017.05.2/package/ffmpeg/ffmpeg.mk 2017-07-27 08:16:52.017486944 +0200
2844 @@ -42,6 +42,9 @@ FFMPEG_CONF_OPTS = \
2845 --disable-mipsdspr2 \
2846 --disable-msa \
2847 --enable-hwaccels \
2848 + --disable-cuda \
2849 + --disable-cuvid \
2850 + --disable-nvenc \
2851 --disable-avisynth \
2852 --disable-frei0r \
2853 --disable-libopencore-amrnb \
2854 @@ -157,12 +160,18 @@ endif
2856 ifeq ($(BR2_PACKAGE_FFMPEG_INDEVS),y)
2857 FFMPEG_CONF_OPTS += --enable-indevs
2858 +ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
2859 +FFMPEG_DEPENDENCIES += alsa-lib
2860 +endif
2861 else
2862 FFMPEG_CONF_OPTS += --disable-indevs
2863 endif
2865 ifeq ($(BR2_PACKAGE_FFMPEG_OUTDEVS),y)
2866 FFMPEG_CONF_OPTS += --enable-outdevs
2867 +ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
2868 +FFMPEG_DEPENDENCIES += alsa-lib
2869 +endif
2870 else
2871 FFMPEG_CONF_OPTS += --disable-outdevs
2872 endif
2873 diff -Naurp buildroot-2017.05-rc2/package/firejail/Config.in buildroot-2017.05.2/package/firejail/Config.in
2874 --- buildroot-2017.05-rc2/package/firejail/Config.in 2017-05-17 10:27:16.013401440 +0200
2875 +++ buildroot-2017.05.2/package/firejail/Config.in 1970-01-01 01:00:00.000000000 +0100
2876 @@ -1,21 +0,0 @@
2877 -config BR2_PACKAGE_FIREJAIL
2878 - bool "firejail"
2879 - depends on BROKEN # does not cross-compile at all
2880 - depends on BR2_USE_MMU # fork()
2881 - depends on BR2_TOOLCHAIN_HAS_THREADS
2882 - # uClibc: error: ‘EM_ARM’ undeclared
2883 - depends on !BR2_TOOLCHAIN_USES_UCLIBC
2884 - help
2885 - Firejail is a SUID program that reduces the risk of security
2886 - breaches by restricting the running environment of untrusted
2887 - applications using Linux namespaces and seccomp-bpf. It
2888 - allows a process and all its descendants to have their own
2889 - private view of the globally shared kernel resources, such
2890 - as the network stack, process table, mount table.
2892 - https://firejail.wordpress.com/
2894 -comment "firejail needs a glibc or musl toolchain w/ threads"
2895 - depends on BR2_USE_MMU
2896 - depends on BROKEN
2897 - depends on BR2_TOOLCHAIN_USES_UCLIBC || !BR2_TOOLCHAIN_HAS_THREADS
2898 diff -Naurp buildroot-2017.05-rc2/package/firejail/firejail.hash buildroot-2017.05.2/package/firejail/firejail.hash
2899 --- buildroot-2017.05-rc2/package/firejail/firejail.hash 2017-05-17 10:27:16.013401440 +0200
2900 +++ buildroot-2017.05.2/package/firejail/firejail.hash 1970-01-01 01:00:00.000000000 +0100
2901 @@ -1,3 +0,0 @@
2902 -# From https://sourceforge.net/projects/firejail/files/firejail/
2903 -md5 7e6dca7202b1d70105b39646755cc620 firejail-0.9.44.8.tar.xz
2904 -sha1 019423df0aee84d474f9fcd1f6a871a2fe8aa9a5 firejail-0.9.44.8.tar.xz
2905 diff -Naurp buildroot-2017.05-rc2/package/firejail/firejail.mk buildroot-2017.05.2/package/firejail/firejail.mk
2906 --- buildroot-2017.05-rc2/package/firejail/firejail.mk 2017-05-17 10:27:16.013401440 +0200
2907 +++ buildroot-2017.05.2/package/firejail/firejail.mk 1970-01-01 01:00:00.000000000 +0100
2908 @@ -1,28 +0,0 @@
2909 -################################################################################
2911 -# firejail
2913 -################################################################################
2915 -FIREJAIL_VERSION = 0.9.44.8
2916 -FIREJAIL_SITE = http://download.sourceforge.net/firejail
2917 -FIREJAIL_SOURCE = firejail-$(FIREJAIL_VERSION).tar.xz
2918 -FIREJAIL_LICENSE = GPL-2.0+
2919 -FIREJAIL_LICENSE_FILES = COPYING
2921 -FIREJAIL_CONF_OPTS = \
2922 - --enable-bind \
2923 - --enable-file-transfer \
2924 - --enable-network \
2925 - --enable-seccomp \
2926 - --enable-userns
2928 -ifeq ($(BR2_PACKAGE_BUSYBOX),y)
2929 -FIREJAIL_CONF_OPTS += --enable-busybox-workaround
2930 -endif
2932 -define FIREJAIL_PERMISSIONS
2933 - /usr/bin/firejail f 4755 0 0 - - - - -
2934 -endef
2936 -$(eval $(autotools-package))
2937 diff -Naurp buildroot-2017.05-rc2/package/flashrom/0002-sys-io.h.patch buildroot-2017.05.2/package/flashrom/0002-sys-io.h.patch
2938 --- buildroot-2017.05-rc2/package/flashrom/0002-sys-io.h.patch 2017-05-17 10:27:16.013401440 +0200
2939 +++ buildroot-2017.05.2/package/flashrom/0002-sys-io.h.patch 1970-01-01 01:00:00.000000000 +0100
2940 @@ -1,27 +0,0 @@
2941 -hwaccess: sys/io.h is not specific to glibc
2943 -Under Linux, sys/io.h provides inb and outb, so we really need it.
2944 -However, its inclusion is conditional to the _GLIBC_ define. This is
2945 -usually OK under Linux, since both glibc and uClibc define it (uclibc
2946 -fakes being glibc).
2948 -But the musl C library does not impersonate glibc, so we're missing
2949 -including sys/io.h in this case.
2951 -Change the include from checking _GLIBC_ to checking whether this is
2952 -Linux, looking for the __linux__ define.
2954 -Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2956 -diff -durN flashrom-0.9.8.orig/hwaccess.h flashrom-0.9.8/hwaccess.h
2957 ---- flashrom-0.9.8.orig/hwaccess.h 2015-02-10 09:03:10.000000000 +0100
2958 -+++ flashrom-0.9.8/hwaccess.h 2015-10-28 20:01:54.259202484 +0100
2959 -@@ -27,7 +27,7 @@
2960 - #include "platform.h"
2962 - #if IS_X86
2963 --#if defined(__GLIBC__)
2964 -+#if defined(__linux__)
2965 - #include <sys/io.h>
2966 - #endif
2967 - #endif
2968 diff -Naurp buildroot-2017.05-rc2/package/flashrom/flashrom.hash buildroot-2017.05.2/package/flashrom/flashrom.hash
2969 --- buildroot-2017.05-rc2/package/flashrom/flashrom.hash 2017-05-17 10:27:16.013401440 +0200
2970 +++ buildroot-2017.05.2/package/flashrom/flashrom.hash 2017-07-27 08:16:52.017486944 +0200
2971 @@ -1,2 +1,2 @@
2972 # Locally computed
2973 -sha256 13dc7c895e583111ecca370363a3527d237d178a134a94b20db7df177c05f934 flashrom-0.9.8.tar.bz2
2974 +sha256 cb3156b0f63eb192024b76c0814135930297aac41f80761a5d293de769783c45 flashrom-0.9.9.tar.bz2
2975 diff -Naurp buildroot-2017.05-rc2/package/flashrom/flashrom.mk buildroot-2017.05.2/package/flashrom/flashrom.mk
2976 --- buildroot-2017.05-rc2/package/flashrom/flashrom.mk 2017-05-17 10:27:16.013401440 +0200
2977 +++ buildroot-2017.05.2/package/flashrom/flashrom.mk 2017-07-27 08:16:52.017486944 +0200
2978 @@ -4,7 +4,7 @@
2980 ################################################################################
2982 -FLASHROM_VERSION = 0.9.8
2983 +FLASHROM_VERSION = 0.9.9
2984 FLASHROM_SOURCE = flashrom-$(FLASHROM_VERSION).tar.bz2
2985 FLASHROM_SITE = http://download.flashrom.org/releases
2986 FLASHROM_DEPENDENCIES = pciutils libusb libusb-compat libftdi host-pkgconf
2987 diff -Naurp buildroot-2017.05-rc2/package/freescale-imx/imx-uuc/S80imx-uuc buildroot-2017.05.2/package/freescale-imx/imx-uuc/S80imx-uuc
2988 --- buildroot-2017.05-rc2/package/freescale-imx/imx-uuc/S80imx-uuc 2017-05-17 10:27:16.013401440 +0200
2989 +++ buildroot-2017.05.2/package/freescale-imx/imx-uuc/S80imx-uuc 2017-07-27 08:16:52.017486944 +0200
2990 @@ -6,7 +6,7 @@ DAEMON=/usr/bin/$NAME
2991 case "$1" in
2992 start)
2993 printf "Starting $NAME: "
2994 - start-stop-daemon -S -q -b -p /var/run/${NAME}.pid -x $DAEMON
2995 + start-stop-daemon -S -q -b -m -p /var/run/${NAME}.pid -x $DAEMON
2996 [ $? = 0 ] && echo "OK" || echo "FAIL"
2998 stop)
2999 diff -Naurp buildroot-2017.05-rc2/package/ftop/Config.in buildroot-2017.05.2/package/ftop/Config.in
3000 --- buildroot-2017.05-rc2/package/ftop/Config.in 2017-05-17 10:27:16.013401440 +0200
3001 +++ buildroot-2017.05.2/package/ftop/Config.in 2017-07-27 08:16:52.017486944 +0200
3002 @@ -5,4 +5,4 @@ config BR2_PACKAGE_FTOP
3003 Ftop is to files what top is to processes.
3004 The progress of all open files and file systems can be monitored.
3006 - https://code.google.com/p/ftop/
3007 + https://sourceforge.net/projects/ftop/
3008 diff -Naurp buildroot-2017.05-rc2/package/ftop/ftop.hash buildroot-2017.05.2/package/ftop/ftop.hash
3009 --- buildroot-2017.05-rc2/package/ftop/ftop.hash 2017-05-17 10:27:16.013401440 +0200
3010 +++ buildroot-2017.05.2/package/ftop/ftop.hash 2017-07-27 08:16:52.017486944 +0200
3011 @@ -1,2 +1,5 @@
3012 -# From https://code.google.com/p/ftop/downloads/detail?name=ftop-1.0.tar.gz&can=2&q=
3013 -sha1 a0523862dd63ed3bec14846b6e05afcfdebb15c2 ftop-1.0.tar.gz
3014 +# From https://sourceforge.net/projects/ftop/files/ftop/1.0/
3015 +md5 57c68b6e7431f4219d9eddaebcb395da ftop-1.0.tar.bz2
3016 +sha1 d3ef1b74825f50c7c442d299b29d23c2478f199b ftop-1.0.tar.bz2
3017 +# Locally computed
3018 +sha256 3a705f4f291384344cd32c3dd5f5f6a7cd7cea7624c83cb7e923966dbcd47f82 ftop-1.0.tar.bz2
3019 diff -Naurp buildroot-2017.05-rc2/package/ftop/ftop.mk buildroot-2017.05.2/package/ftop/ftop.mk
3020 --- buildroot-2017.05-rc2/package/ftop/ftop.mk 2017-05-17 10:27:16.013401440 +0200
3021 +++ buildroot-2017.05.2/package/ftop/ftop.mk 2017-07-27 08:16:52.017486944 +0200
3022 @@ -5,7 +5,8 @@
3023 ################################################################################
3025 FTOP_VERSION = 1.0
3026 -FTOP_SITE = http://ftop.googlecode.com/files
3027 +FTOP_SOURCE = ftop-$(FTOP_VERSION).tar.bz2
3028 +FTOP_SITE = https://sourceforge.net/projects/ftop/files/ftop/$(FTOP_VERSION)
3029 FTOP_DEPENDENCIES = ncurses
3030 FTOP_LICENSE = GPL-3.0+
3031 FTOP_LICENSE_FILES = COPYING
3032 diff -Naurp buildroot-2017.05-rc2/package/gcc/4.9.4/942-asan-fix-missing-include-signal-h.patch buildroot-2017.05.2/package/gcc/4.9.4/942-asan-fix-missing-include-signal-h.patch
3033 --- buildroot-2017.05-rc2/package/gcc/4.9.4/942-asan-fix-missing-include-signal-h.patch 1970-01-01 01:00:00.000000000 +0100
3034 +++ buildroot-2017.05.2/package/gcc/4.9.4/942-asan-fix-missing-include-signal-h.patch 2017-07-27 08:16:52.017486944 +0200
3035 @@ -0,0 +1,36 @@
3036 +From 205aa8e97bab553e5e6fe45896325e97962de704 Mon Sep 17 00:00:00 2001
3037 +From: Rolf Eike Beer <eb@emlix.com>
3038 +Date: Wed, 8 Feb 2017 11:42:52 +0100
3039 +Subject: [PATCH] asan: fix missing include of signal.h
3041 +This breaks when building gcc 4.9.4 / 5.4.0 with
3042 +target_platform=powerpc-unknown-linux-gnu with glibc 2.25:
3044 +../../../../gcc-host/libsanitizer/asan/asan_linux.cc: In function 'bool __asan::AsanInterceptsSignal(int)':
3045 +../../../../gcc-host/libsanitizer/asan/asan_linux.cc:222:20: error: 'SIGSEGV' was not declared in this scope
3046 + return signum == SIGSEGV && common_flags()->handle_segv;
3048 +This has been verified to apply to at least 4.9.4 and up to 5.4,
3049 +the code has been reworked for gcc 6.
3051 +Resolves (Buildroot) Bug: https://bugs.busybox.net/show_bug.cgi?id=10061
3053 +Upstream: https://patchwork.ozlabs.org/patch/725596/
3055 +Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
3056 +---
3057 + libsanitizer/asan/asan_linux.cc | 1 +
3058 + 1 file changed, 1 insertion(+)
3060 +diff --git a/libsanitizer/asan/asan_linux.cc b/libsanitizer/asan/asan_linux.cc
3061 +index c504168..59087b9 100644
3062 +--- a/libsanitizer/asan/asan_linux.cc
3063 ++++ b/libsanitizer/asan/asan_linux.cc
3064 +@@ -29,6 +29,7 @@
3065 + #include <dlfcn.h>
3066 + #include <fcntl.h>
3067 + #include <pthread.h>
3068 ++#include <signal.h>
3069 + #include <stdio.h>
3070 + #include <unistd.h>
3071 + #include <unwind.h>
3072 diff -Naurp buildroot-2017.05-rc2/package/gcc/5.4.0/942-asan-fix-missing-include-signal-h.patch buildroot-2017.05.2/package/gcc/5.4.0/942-asan-fix-missing-include-signal-h.patch
3073 --- buildroot-2017.05-rc2/package/gcc/5.4.0/942-asan-fix-missing-include-signal-h.patch 1970-01-01 01:00:00.000000000 +0100
3074 +++ buildroot-2017.05.2/package/gcc/5.4.0/942-asan-fix-missing-include-signal-h.patch 2017-07-27 08:16:52.017486944 +0200
3075 @@ -0,0 +1,36 @@
3076 +From 205aa8e97bab553e5e6fe45896325e97962de704 Mon Sep 17 00:00:00 2001
3077 +From: Rolf Eike Beer <eb@emlix.com>
3078 +Date: Wed, 8 Feb 2017 11:42:52 +0100
3079 +Subject: [PATCH] asan: fix missing include of signal.h
3081 +This breaks when building gcc 4.9.4 / 5.4.0 with
3082 +target_platform=powerpc-unknown-linux-gnu with glibc 2.25:
3084 +../../../../gcc-host/libsanitizer/asan/asan_linux.cc: In function 'bool __asan::AsanInterceptsSignal(int)':
3085 +../../../../gcc-host/libsanitizer/asan/asan_linux.cc:222:20: error: 'SIGSEGV' was not declared in this scope
3086 + return signum == SIGSEGV && common_flags()->handle_segv;
3088 +This has been verified to apply to at least 4.9.4 and up to 5.4,
3089 +the code has been reworked for gcc 6.
3091 +Resolves (Buildroot) Bug: https://bugs.busybox.net/show_bug.cgi?id=10061
3093 +Upstream: https://patchwork.ozlabs.org/patch/725596/
3095 +Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
3096 +---
3097 + libsanitizer/asan/asan_linux.cc | 1 +
3098 + 1 file changed, 1 insertion(+)
3100 +diff --git a/libsanitizer/asan/asan_linux.cc b/libsanitizer/asan/asan_linux.cc
3101 +index c504168..59087b9 100644
3102 +--- a/libsanitizer/asan/asan_linux.cc
3103 ++++ b/libsanitizer/asan/asan_linux.cc
3104 +@@ -29,6 +29,7 @@
3105 + #include <dlfcn.h>
3106 + #include <fcntl.h>
3107 + #include <pthread.h>
3108 ++#include <signal.h>
3109 + #include <stdio.h>
3110 + #include <unistd.h>
3111 + #include <unwind.h>
3112 diff -Naurp buildroot-2017.05-rc2/package/gcc/6.3.0/942-ubsan-fix-check-empty-string.patch buildroot-2017.05.2/package/gcc/6.3.0/942-ubsan-fix-check-empty-string.patch
3113 --- buildroot-2017.05-rc2/package/gcc/6.3.0/942-ubsan-fix-check-empty-string.patch 1970-01-01 01:00:00.000000000 +0100
3114 +++ buildroot-2017.05.2/package/gcc/6.3.0/942-ubsan-fix-check-empty-string.patch 2017-07-27 08:16:52.017486944 +0200
3115 @@ -0,0 +1,40 @@
3116 +From 8db2cf6353c13f2a84cbe49b689654897906c499 Mon Sep 17 00:00:00 2001
3117 +From: kyukhin <kyukhin@138bc75d-0d04-0410-961f-82ee72b054a4>
3118 +Date: Sat, 3 Sep 2016 10:57:05 +0000
3119 +Subject: [PATCH] gcc/ubsan.c: Fix check for empty string
3121 +Building host-gcc-initial with GCC7 on the host fails due to the
3122 +comparison of a pointer to an integer in ubsan_use_new_style_p, which
3123 +is forbidden by ISO C++:
3125 +ubsan.c:1474:23: error: ISO C++ forbids comparison between pointer and
3126 +integer [-fpermissive]
3127 + || xloc.file == '\0' || xloc.file[0] == '\xff'
3129 +Backport the fix from upstream GCC to enable the build with GCC 7.
3131 +Backported from:
3132 +https://gcc.gnu.org/viewcvs/gcc?view=revision&revision=239971
3134 +Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
3135 +[Add commit log from [1]]
3136 +Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
3138 +[1] https://patchwork.openembedded.org/patch/138884/
3139 +---
3140 + gcc/ubsan.c | 2 +-
3141 + 2 files changed, 5 insertions(+), 1 deletion(-)
3143 +Index: gcc-6.3.0/gcc/ubsan.c
3144 +===================================================================
3145 +--- gcc-6.3.0.orig/gcc/ubsan.c
3146 ++++ gcc-6.3.0/gcc/ubsan.c
3147 +@@ -1471,7 +1471,7 @@ ubsan_use_new_style_p (location_t loc)
3149 + expanded_location xloc = expand_location (loc);
3150 + if (xloc.file == NULL || strncmp (xloc.file, "\1", 2) == 0
3151 +- || xloc.file == '\0' || xloc.file[0] == '\xff'
3152 ++ || xloc.file[0] == '\0' || xloc.file[0] == '\xff'
3153 + || xloc.file[1] == '\xff')
3154 + return false;
3156 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03/0001-ARC-Fix-tst_movb-pattern.patch buildroot-2017.05.2/package/gcc/arc-2017.03/0001-ARC-Fix-tst_movb-pattern.patch
3157 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03/0001-ARC-Fix-tst_movb-pattern.patch 1970-01-01 01:00:00.000000000 +0100
3158 +++ buildroot-2017.05.2/package/gcc/arc-2017.03/0001-ARC-Fix-tst_movb-pattern.patch 2017-07-27 08:16:52.017486944 +0200
3159 @@ -0,0 +1,55 @@
3160 +From 08235ef444fd32d311fc9edb65895133820462e3 Mon Sep 17 00:00:00 2001
3161 +From: claziss <claziss@synopsys.com>
3162 +Date: Wed, 24 May 2017 12:53:43 +0200
3163 +Subject: [PATCH] [ARC] Fix tst_movb pattern.
3165 +The tst_movb pattern is missing guarding when spitting.
3167 +gcc/
3168 +2017-05-24 Claudiu Zissulescu <claziss@synopsys.com>
3170 + * config/arc/arc.md (tst_movb): Add guard when splitting.
3172 +testsuite/
3173 +2017-05-24 Claudiu Zissulescu <claziss@synopsys.com>
3175 + * gcc.target/arc/pr9001195952.c: New test.
3176 +---
3177 + gcc/config/arc/arc.md | 2 +-
3178 + gcc/testsuite/gcc.target/arc/pr9001195952.c | 11 +++++++++++
3179 + 2 files changed, 12 insertions(+), 1 deletion(-)
3180 + create mode 100755 gcc/testsuite/gcc.target/arc/pr9001195952.c
3182 +diff --git a/gcc/config/arc/arc.md b/gcc/config/arc/arc.md
3183 +index e78abaaafc42..d5510aeb0600 100644
3184 +--- a/gcc/config/arc/arc.md
3185 ++++ b/gcc/config/arc/arc.md
3186 +@@ -863,7 +863,7 @@ archs4xd, archs4xd_slow"
3187 + (clobber (match_scratch:SI 3 "=X,X,X,X,X,X,Rrq,Rrq,c"))]
3188 + "TARGET_NPS_BITOPS"
3189 + "movb.f.cl %3,%1,%p2,%p2,%s2"
3190 +- "reload_completed
3191 ++ "TARGET_NPS_BITOPS && reload_completed
3192 + && (extract_constrain_insn_cached (insn), (which_alternative & ~1) != 6)"
3193 + [(set (match_dup 0) (match_dup 4))])
3195 +diff --git a/gcc/testsuite/gcc.target/arc/pr9001195952.c b/gcc/testsuite/gcc.target/arc/pr9001195952.c
3196 +new file mode 100755
3197 +index 000000000000..252438d8d78b
3198 +--- /dev/null
3199 ++++ b/gcc/testsuite/gcc.target/arc/pr9001195952.c
3200 +@@ -0,0 +1,11 @@
3201 ++/* { dg-do compile } */
3202 ++/* { dg-skip-if "" { ! { clmcpu } } } */
3203 ++/* { dg-options "-mcpu=archs -Os -w -fpic" } */
3205 ++/* tst_movb split pattern is wrong for anything else than NPS
3206 ++ chip. */
3207 ++__bswap_32___bsx() {
3208 ++ int a = __builtin_bswap32(__bswap_32___bsx);
3209 ++ if (a & 1048575)
3210 ++ zlog_warn();
3212 +--
3213 +2.7.4
3215 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03/301-missing-execinfo_h.patch buildroot-2017.05.2/package/gcc/arc-2017.03/301-missing-execinfo_h.patch
3216 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03/301-missing-execinfo_h.patch 1970-01-01 01:00:00.000000000 +0100
3217 +++ buildroot-2017.05.2/package/gcc/arc-2017.03/301-missing-execinfo_h.patch 2017-07-27 08:16:52.017486944 +0200
3218 @@ -0,0 +1,13 @@
3219 +Index: b/boehm-gc/include/gc.h
3220 +===================================================================
3221 +--- a/boehm-gc/include/gc.h
3222 ++++ b/boehm-gc/include/gc.h
3223 +@@ -503,7 +503,7 @@
3224 + #if defined(__linux__) || defined(__GLIBC__)
3225 + # include <features.h>
3226 + # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
3227 +- && !defined(__ia64__)
3228 ++ && !defined(__ia64__) && !defined(__UCLIBC__)
3229 + # ifndef GC_HAVE_BUILTIN_BACKTRACE
3230 + # define GC_HAVE_BUILTIN_BACKTRACE
3231 + # endif
3232 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03/860-cilk-wchar.patch buildroot-2017.05.2/package/gcc/arc-2017.03/860-cilk-wchar.patch
3233 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03/860-cilk-wchar.patch 1970-01-01 01:00:00.000000000 +0100
3234 +++ buildroot-2017.05.2/package/gcc/arc-2017.03/860-cilk-wchar.patch 2017-07-27 08:16:52.017486944 +0200
3235 @@ -0,0 +1,56 @@
3236 +[PATCH] cilk: fix build without wchar
3238 +When building against uClibc with wchar support disabled, WCHAR_MIN and
3239 +WCHAR_MAX are not defined leading to compilation errors.
3241 +Fix it by only including the wchar code if available.
3243 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
3244 +---
3245 + libcilkrts/include/cilk/reducer_min_max.h | 8 ++++++++
3246 + 1 file changed, 8 insertions(+)
3248 +Index: b/libcilkrts/include/cilk/reducer_min_max.h
3249 +===================================================================
3250 +--- a/libcilkrts/include/cilk/reducer_min_max.h
3251 ++++ b/libcilkrts/include/cilk/reducer_min_max.h
3252 +@@ -3154,7 +3154,9 @@
3253 + CILK_C_REDUCER_MAX_INSTANCE(char, char, CHAR_MIN)
3254 + CILK_C_REDUCER_MAX_INSTANCE(unsigned char, uchar, 0)
3255 + CILK_C_REDUCER_MAX_INSTANCE(signed char, schar, SCHAR_MIN)
3256 ++#ifdef WCHAR_MIN
3257 + CILK_C_REDUCER_MAX_INSTANCE(wchar_t, wchar_t, WCHAR_MIN)
3258 ++#endif
3259 + CILK_C_REDUCER_MAX_INSTANCE(short, short, SHRT_MIN)
3260 + CILK_C_REDUCER_MAX_INSTANCE(unsigned short, ushort, 0)
3261 + CILK_C_REDUCER_MAX_INSTANCE(int, int, INT_MIN)
3262 +@@ -3306,7 +3308,9 @@
3263 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(char, char, CHAR_MIN)
3264 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(unsigned char, uchar, 0)
3265 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(signed char, schar, SCHAR_MIN)
3266 ++#ifdef WCHAR_MIN
3267 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(wchar_t, wchar_t, WCHAR_MIN)
3268 ++#endif
3269 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(short, short, SHRT_MIN)
3270 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(unsigned short, ushort, 0)
3271 + CILK_C_REDUCER_MAX_INDEX_INSTANCE(int, int, INT_MIN)
3272 +@@ -3432,7 +3436,9 @@
3273 + CILK_C_REDUCER_MIN_INSTANCE(char, char, CHAR_MAX)
3274 + CILK_C_REDUCER_MIN_INSTANCE(unsigned char, uchar, CHAR_MAX)
3275 + CILK_C_REDUCER_MIN_INSTANCE(signed char, schar, SCHAR_MAX)
3276 ++#ifdef WCHAR_MAX
3277 + CILK_C_REDUCER_MIN_INSTANCE(wchar_t, wchar_t, WCHAR_MAX)
3278 ++#endif
3279 + CILK_C_REDUCER_MIN_INSTANCE(short, short, SHRT_MAX)
3280 + CILK_C_REDUCER_MIN_INSTANCE(unsigned short, ushort, USHRT_MAX)
3281 + CILK_C_REDUCER_MIN_INSTANCE(int, int, INT_MAX)
3282 +@@ -3584,7 +3590,9 @@
3283 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(char, char, CHAR_MAX)
3284 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(unsigned char, uchar, CHAR_MAX)
3285 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(signed char, schar, SCHAR_MAX)
3286 ++#ifdef WCHAR_MAX
3287 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(wchar_t, wchar_t, WCHAR_MAX)
3288 ++#endif
3289 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(short, short, SHRT_MAX)
3290 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(unsigned short, ushort, USHRT_MAX)
3291 + CILK_C_REDUCER_MIN_INDEX_INSTANCE(int, int, INT_MAX)
3292 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03/940-uclinux-enable-threads.patch buildroot-2017.05.2/package/gcc/arc-2017.03/940-uclinux-enable-threads.patch
3293 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03/940-uclinux-enable-threads.patch 1970-01-01 01:00:00.000000000 +0100
3294 +++ buildroot-2017.05.2/package/gcc/arc-2017.03/940-uclinux-enable-threads.patch 2017-07-27 08:16:52.017486944 +0200
3295 @@ -0,0 +1,19 @@
3296 +Enable POSIX threads for uClinux targets
3297 +Reported upstream:
3298 +https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71721
3300 +Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
3302 +diff -Nur gcc-6.1.0.orig/gcc/config.gcc gcc-6.1.0/gcc/config.gcc
3303 +--- gcc-6.1.0.orig/gcc/config.gcc 2016-04-11 12:14:59.000000000 +0200
3304 ++++ gcc-6.1.0/gcc/config.gcc 2016-07-02 20:04:25.732169982 +0200
3305 +@@ -833,6 +833,9 @@
3306 + *-*-uclinux*)
3307 + extra_options="$extra_options gnu-user.opt"
3308 + use_gcc_stdint=wrap
3309 ++ case ${enable_threads} in
3310 ++ "" | yes | posix) thread_file='posix' ;;
3311 ++ esac
3312 + tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC SINGLE_LIBC"
3313 + ;;
3314 + *-*-rdos*)
3315 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/0001-FIX-PIC-return-false-for-any-PIC-related-unspecs.patch buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/0001-FIX-PIC-return-false-for-any-PIC-related-unspecs.patch
3316 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/0001-FIX-PIC-return-false-for-any-PIC-related-unspecs.patch 2017-05-17 10:27:16.013401440 +0200
3317 +++ buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/0001-FIX-PIC-return-false-for-any-PIC-related-unspecs.patch 1970-01-01 01:00:00.000000000 +0100
3318 @@ -1,58 +0,0 @@
3319 -From 139fed9d29ab935b3bc5159c0bdf7b8b8a39442d Mon Sep 17 00:00:00 2001
3320 -From: Claudiu Zissulescu <claziss@gmail.com>
3321 -Date: Mon, 15 May 2017 05:05:27 -0400
3322 -Subject: [PATCH] [FIX] PIC: return false for any PIC related unspecs
3324 ----
3325 - gcc/config/arc/arc.c | 9 ++++-----
3326 - gcc/testsuite/gcc.target/arc/pr9001191897.c | 10 ++++++++++
3327 - 2 files changed, 14 insertions(+), 5 deletions(-)
3328 - create mode 100644 gcc/testsuite/gcc.target/arc/pr9001191897.c
3330 -diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
3331 -index 3d53a667d37f..b00126f4d2c4 100644
3332 ---- a/gcc/config/arc/arc.c
3333 -+++ b/gcc/config/arc/arc.c
3334 -@@ -6056,11 +6056,8 @@ arc_legitimate_constant_p (machine_mode mode, rtx x)
3335 - return true;
3337 - case NEG:
3338 -- /* Assembler does not understand -(@label@gotoff). Also, we do
3339 -- not print such pic address constant. */
3340 -- if (GET_CODE (XEXP (x, 0)) == UNSPEC)
3341 -- return false;
3342 - return arc_legitimate_constant_p (mode, XEXP (x, 0));
3344 - case PLUS:
3345 - case MINUS:
3347 -@@ -6090,7 +6087,9 @@ arc_legitimate_constant_p (machine_mode mode, rtx x)
3348 - case UNSPEC_TLS_IE:
3349 - return true;
3350 - default:
3351 -- break;
3352 -+ /* Any other unspec ending here are pic related, hence the above
3353 -+ constant pic address checking returned false. */
3354 -+ return false;
3356 - /* Fall through. */
3358 -diff --git a/gcc/testsuite/gcc.target/arc/pr9001191897.c b/gcc/testsuite/gcc.target/arc/pr9001191897.c
3359 -new file mode 100644
3360 -index 000000000000..2b9e1689803f
3361 ---- /dev/null
3362 -+++ b/gcc/testsuite/gcc.target/arc/pr9001191897.c
3363 -@@ -0,0 +1,10 @@
3364 -+/* { dg-do compile } */
3365 -+/* { dg-skip-if "" { ! { clmcpu } } } */
3366 -+/* { dg-options "-mcpu=arch2 -Os -fpic -mno-sdata -mno-indexed-loads -w" } */
3367 -+a;
3368 -+c() {
3369 -+ static char b[25];
3370 -+ for (; a >= 0; a--)
3371 -+ if (b[a])
3372 -+ b[a] = '\0';
3374 ---
3375 -2.7.4
3377 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/301-missing-execinfo_h.patch buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/301-missing-execinfo_h.patch
3378 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/301-missing-execinfo_h.patch 2017-05-17 10:27:16.013401440 +0200
3379 +++ buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/301-missing-execinfo_h.patch 1970-01-01 01:00:00.000000000 +0100
3380 @@ -1,13 +0,0 @@
3381 -Index: b/boehm-gc/include/gc.h
3382 -===================================================================
3383 ---- a/boehm-gc/include/gc.h
3384 -+++ b/boehm-gc/include/gc.h
3385 -@@ -503,7 +503,7 @@
3386 - #if defined(__linux__) || defined(__GLIBC__)
3387 - # include <features.h>
3388 - # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
3389 -- && !defined(__ia64__)
3390 -+ && !defined(__ia64__) && !defined(__UCLIBC__)
3391 - # ifndef GC_HAVE_BUILTIN_BACKTRACE
3392 - # define GC_HAVE_BUILTIN_BACKTRACE
3393 - # endif
3394 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/860-cilk-wchar.patch buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/860-cilk-wchar.patch
3395 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/860-cilk-wchar.patch 2017-05-17 10:27:16.013401440 +0200
3396 +++ buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/860-cilk-wchar.patch 1970-01-01 01:00:00.000000000 +0100
3397 @@ -1,56 +0,0 @@
3398 -[PATCH] cilk: fix build without wchar
3400 -When building against uClibc with wchar support disabled, WCHAR_MIN and
3401 -WCHAR_MAX are not defined leading to compilation errors.
3403 -Fix it by only including the wchar code if available.
3405 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
3406 ----
3407 - libcilkrts/include/cilk/reducer_min_max.h | 8 ++++++++
3408 - 1 file changed, 8 insertions(+)
3410 -Index: b/libcilkrts/include/cilk/reducer_min_max.h
3411 -===================================================================
3412 ---- a/libcilkrts/include/cilk/reducer_min_max.h
3413 -+++ b/libcilkrts/include/cilk/reducer_min_max.h
3414 -@@ -3154,7 +3154,9 @@
3415 - CILK_C_REDUCER_MAX_INSTANCE(char, char, CHAR_MIN)
3416 - CILK_C_REDUCER_MAX_INSTANCE(unsigned char, uchar, 0)
3417 - CILK_C_REDUCER_MAX_INSTANCE(signed char, schar, SCHAR_MIN)
3418 -+#ifdef WCHAR_MIN
3419 - CILK_C_REDUCER_MAX_INSTANCE(wchar_t, wchar_t, WCHAR_MIN)
3420 -+#endif
3421 - CILK_C_REDUCER_MAX_INSTANCE(short, short, SHRT_MIN)
3422 - CILK_C_REDUCER_MAX_INSTANCE(unsigned short, ushort, 0)
3423 - CILK_C_REDUCER_MAX_INSTANCE(int, int, INT_MIN)
3424 -@@ -3306,7 +3308,9 @@
3425 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(char, char, CHAR_MIN)
3426 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(unsigned char, uchar, 0)
3427 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(signed char, schar, SCHAR_MIN)
3428 -+#ifdef WCHAR_MIN
3429 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(wchar_t, wchar_t, WCHAR_MIN)
3430 -+#endif
3431 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(short, short, SHRT_MIN)
3432 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(unsigned short, ushort, 0)
3433 - CILK_C_REDUCER_MAX_INDEX_INSTANCE(int, int, INT_MIN)
3434 -@@ -3432,7 +3436,9 @@
3435 - CILK_C_REDUCER_MIN_INSTANCE(char, char, CHAR_MAX)
3436 - CILK_C_REDUCER_MIN_INSTANCE(unsigned char, uchar, CHAR_MAX)
3437 - CILK_C_REDUCER_MIN_INSTANCE(signed char, schar, SCHAR_MAX)
3438 -+#ifdef WCHAR_MAX
3439 - CILK_C_REDUCER_MIN_INSTANCE(wchar_t, wchar_t, WCHAR_MAX)
3440 -+#endif
3441 - CILK_C_REDUCER_MIN_INSTANCE(short, short, SHRT_MAX)
3442 - CILK_C_REDUCER_MIN_INSTANCE(unsigned short, ushort, USHRT_MAX)
3443 - CILK_C_REDUCER_MIN_INSTANCE(int, int, INT_MAX)
3444 -@@ -3584,7 +3590,9 @@
3445 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(char, char, CHAR_MAX)
3446 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(unsigned char, uchar, CHAR_MAX)
3447 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(signed char, schar, SCHAR_MAX)
3448 -+#ifdef WCHAR_MAX
3449 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(wchar_t, wchar_t, WCHAR_MAX)
3450 -+#endif
3451 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(short, short, SHRT_MAX)
3452 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(unsigned short, ushort, USHRT_MAX)
3453 - CILK_C_REDUCER_MIN_INDEX_INSTANCE(int, int, INT_MAX)
3454 diff -Naurp buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/940-uclinux-enable-threads.patch buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/940-uclinux-enable-threads.patch
3455 --- buildroot-2017.05-rc2/package/gcc/arc-2017.03-rc2/940-uclinux-enable-threads.patch 2017-05-17 10:27:16.013401440 +0200
3456 +++ buildroot-2017.05.2/package/gcc/arc-2017.03-rc2/940-uclinux-enable-threads.patch 1970-01-01 01:00:00.000000000 +0100
3457 @@ -1,19 +0,0 @@
3458 -Enable POSIX threads for uClinux targets
3459 -Reported upstream:
3460 -https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71721
3462 -Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
3464 -diff -Nur gcc-6.1.0.orig/gcc/config.gcc gcc-6.1.0/gcc/config.gcc
3465 ---- gcc-6.1.0.orig/gcc/config.gcc 2016-04-11 12:14:59.000000000 +0200
3466 -+++ gcc-6.1.0/gcc/config.gcc 2016-07-02 20:04:25.732169982 +0200
3467 -@@ -833,6 +833,9 @@
3468 - *-*-uclinux*)
3469 - extra_options="$extra_options gnu-user.opt"
3470 - use_gcc_stdint=wrap
3471 -+ case ${enable_threads} in
3472 -+ "" | yes | posix) thread_file='posix' ;;
3473 -+ esac
3474 - tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC SINGLE_LIBC"
3475 - ;;
3476 - *-*-rdos*)
3477 diff -Naurp buildroot-2017.05-rc2/package/gcc/Config.in.host buildroot-2017.05.2/package/gcc/Config.in.host
3478 --- buildroot-2017.05-rc2/package/gcc/Config.in.host 2017-05-17 10:27:16.013401440 +0200
3479 +++ buildroot-2017.05.2/package/gcc/Config.in.host 2017-07-27 08:16:52.017486944 +0200
3480 @@ -106,7 +106,7 @@ config BR2_GCC_VERSION
3481 default "4.9.4" if BR2_GCC_VERSION_4_9_X
3482 default "5.4.0" if BR2_GCC_VERSION_5_X
3483 default "6.3.0" if BR2_GCC_VERSION_6_X
3484 - default "arc-2017.03-rc2" if BR2_GCC_VERSION_ARC
3485 + default "arc-2017.03" if BR2_GCC_VERSION_ARC
3486 default "musl-5.4.0" if BR2_GCC_VERSION_OR1K
3488 config BR2_EXTRA_GCC_CONFIG_OPTIONS
3489 diff -Naurp buildroot-2017.05-rc2/package/gcc/gcc-final/gcc-final.hash buildroot-2017.05.2/package/gcc/gcc-final/gcc-final.hash
3490 --- buildroot-2017.05-rc2/package/gcc/gcc-final/gcc-final.hash 2017-05-17 10:27:16.013401440 +0200
3491 +++ buildroot-2017.05.2/package/gcc/gcc-final/gcc-final.hash 2017-07-27 08:16:52.017486944 +0200
3492 @@ -12,6 +12,6 @@ sha512 2941cc950c8f2409a314df497631f9b0
3493 sha512 234dd9b1bdc9a9c6e352216a7ef4ccadc6c07f156006a59759c5e0e6a69f0abcdc14630eff11e3826dd6ba5933a8faa43043f3d1d62df6bd5ab1e82862f9bf78 gcc-6.3.0.tar.bz2
3495 # Locally calculated (fetched from Github)
3496 -sha512 8157d784367de2de853f7d288a213ee3222ac77321d18a887cd5a9c55b53f5948cc8608ec82398cb7e0a155ffa79f86f6469a23b505b22cd0eb5b69d610abd41 gcc-arc-2017.03-rc2.tar.gz
3497 +sha512 282f76b8b63372f5b4426092b80d36da96cd0bda2a8588405b9ec22806c69fafb696b0e0df65bc36c3c3aa8ce5befc24246fd5c6ddb21dcde01f45f7b11ff7c4 gcc-arc-2017.03.tar.gz
3498 # Locally calculated (fetched from Github)
3499 sha512 841101f7de45f327bf2e92f3efc73ca88a021e4b9b541458ce80a16e55882bd8606a8492d75c57c589ee2c10d42ae2865b67690155d7289a541df1d68096402f gcc-musl-5.4.0.tar.gz
3500 diff -Naurp buildroot-2017.05-rc2/package/gcc/gcc.hash buildroot-2017.05.2/package/gcc/gcc.hash
3501 --- buildroot-2017.05-rc2/package/gcc/gcc.hash 2017-05-17 10:27:16.013401440 +0200
3502 +++ buildroot-2017.05.2/package/gcc/gcc.hash 2017-07-27 08:16:52.017486944 +0200
3503 @@ -12,6 +12,6 @@ sha512 2941cc950c8f2409a314df497631f9b0
3504 sha512 234dd9b1bdc9a9c6e352216a7ef4ccadc6c07f156006a59759c5e0e6a69f0abcdc14630eff11e3826dd6ba5933a8faa43043f3d1d62df6bd5ab1e82862f9bf78 gcc-6.3.0.tar.bz2
3506 # Locally calculated (fetched from Github)
3507 -sha512 8157d784367de2de853f7d288a213ee3222ac77321d18a887cd5a9c55b53f5948cc8608ec82398cb7e0a155ffa79f86f6469a23b505b22cd0eb5b69d610abd41 gcc-arc-2017.03-rc2.tar.gz
3508 +sha512 282f76b8b63372f5b4426092b80d36da96cd0bda2a8588405b9ec22806c69fafb696b0e0df65bc36c3c3aa8ce5befc24246fd5c6ddb21dcde01f45f7b11ff7c4 gcc-arc-2017.03.tar.gz
3509 # Locally calculated (fetched from Github)
3510 sha512 841101f7de45f327bf2e92f3efc73ca88a021e4b9b541458ce80a16e55882bd8606a8492d75c57c589ee2c10d42ae2865b67690155d7289a541df1d68096402f gcc-musl-5.4.0.tar.gz
3511 diff -Naurp buildroot-2017.05-rc2/package/gcc/gcc-initial/gcc-initial.hash buildroot-2017.05.2/package/gcc/gcc-initial/gcc-initial.hash
3512 --- buildroot-2017.05-rc2/package/gcc/gcc-initial/gcc-initial.hash 2017-05-17 10:27:16.013401440 +0200
3513 +++ buildroot-2017.05.2/package/gcc/gcc-initial/gcc-initial.hash 2017-07-27 08:16:52.017486944 +0200
3514 @@ -12,6 +12,6 @@ sha512 2941cc950c8f2409a314df497631f9b0
3515 sha512 234dd9b1bdc9a9c6e352216a7ef4ccadc6c07f156006a59759c5e0e6a69f0abcdc14630eff11e3826dd6ba5933a8faa43043f3d1d62df6bd5ab1e82862f9bf78 gcc-6.3.0.tar.bz2
3517 # Locally calculated (fetched from Github)
3518 -sha512 8157d784367de2de853f7d288a213ee3222ac77321d18a887cd5a9c55b53f5948cc8608ec82398cb7e0a155ffa79f86f6469a23b505b22cd0eb5b69d610abd41 gcc-arc-2017.03-rc2.tar.gz
3519 +sha512 282f76b8b63372f5b4426092b80d36da96cd0bda2a8588405b9ec22806c69fafb696b0e0df65bc36c3c3aa8ce5befc24246fd5c6ddb21dcde01f45f7b11ff7c4 gcc-arc-2017.03.tar.gz
3520 # Locally calculated (fetched from Github)
3521 sha512 841101f7de45f327bf2e92f3efc73ca88a021e4b9b541458ce80a16e55882bd8606a8492d75c57c589ee2c10d42ae2865b67690155d7289a541df1d68096402f gcc-musl-5.4.0.tar.gz
3522 diff -Naurp buildroot-2017.05-rc2/package/gdb/7.10.1/0011-use-asm-sgidefs.h.patch buildroot-2017.05.2/package/gdb/7.10.1/0011-use-asm-sgidefs.h.patch
3523 --- buildroot-2017.05-rc2/package/gdb/7.10.1/0011-use-asm-sgidefs.h.patch 1970-01-01 01:00:00.000000000 +0100
3524 +++ buildroot-2017.05.2/package/gdb/7.10.1/0011-use-asm-sgidefs.h.patch 2017-07-27 08:16:52.017486944 +0200
3525 @@ -0,0 +1,41 @@
3526 +From 12a0b8d81e1fda6ba98abdce8d6f09f9555ebcf5 Mon Sep 17 00:00:00 2001
3527 +From: Andre McCurdy <amccurdy@gmail.com>
3528 +Date: Sat, 30 Apr 2016 15:29:06 -0700
3529 +Subject: [PATCH] use <asm/sgidefs.h>
3531 +Build fix for MIPS with musl libc
3533 +The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
3534 +but not by musl. Regardless of the libc, the kernel headers provide
3535 +<asm/sgidefs.h> which provides the same definitions, so use that
3536 +instead.
3538 +Upstream-Status: Pending
3540 +[Vincent:
3541 +Taken from https://sourceware.org/bugzilla/show_bug.cgi?id=21070
3542 +Patch has been adapted to apply on 7.10.1.]
3544 +Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
3545 +Signed-off-by: Khem Raj <raj.khem@gmail.com>
3546 +Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
3547 +---
3548 + gdb/mips-linux-nat.c | 2 +-
3549 + 1 file changed, 1 insertion(+), 1 deletion(-)
3551 +diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
3552 +index 9f6d697..8f57bb2 100644
3553 +--- a/gdb/mips-linux-nat.c
3554 ++++ b/gdb/mips-linux-nat.c
3555 +@@ -31,7 +31,7 @@
3556 + #include "gdb_proc_service.h"
3557 + #include "gregset.h"
3559 +-#include <sgidefs.h>
3560 ++#include <asm/sgidefs.h>
3561 + #include <sys/ptrace.h>
3562 + #include <asm/ptrace.h>
3564 +--
3565 +2.13.1
3567 diff -Naurp buildroot-2017.05-rc2/package/gdb/7.11.1/0006-use-asm-sgidefs.h.patch buildroot-2017.05.2/package/gdb/7.11.1/0006-use-asm-sgidefs.h.patch
3568 --- buildroot-2017.05-rc2/package/gdb/7.11.1/0006-use-asm-sgidefs.h.patch 1970-01-01 01:00:00.000000000 +0100
3569 +++ buildroot-2017.05.2/package/gdb/7.11.1/0006-use-asm-sgidefs.h.patch 2017-07-27 08:16:52.017486944 +0200
3570 @@ -0,0 +1,40 @@
3571 +From 12a0b8d81e1fda6ba98abdce8d6f09f9555ebcf5 Mon Sep 17 00:00:00 2001
3572 +From: Andre McCurdy <amccurdy@gmail.com>
3573 +Date: Sat, 30 Apr 2016 15:29:06 -0700
3574 +Subject: [PATCH] use <asm/sgidefs.h>
3576 +Build fix for MIPS with musl libc
3578 +The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
3579 +but not by musl. Regardless of the libc, the kernel headers provide
3580 +<asm/sgidefs.h> which provides the same definitions, so use that
3581 +instead.
3583 +Upstream-Status: Pending
3585 +[Vincent:
3586 +Taken from: https://sourceware.org/bugzilla/show_bug.cgi?id=21070]
3588 +Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
3589 +Signed-off-by: Khem Raj <raj.khem@gmail.com>
3590 +Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
3591 +---
3592 + gdb/mips-linux-nat.c | 2 +-
3593 + 1 file changed, 1 insertion(+), 1 deletion(-)
3595 +diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
3596 +index f2df1b9907..d24664cb56 100644
3597 +--- a/gdb/mips-linux-nat.c
3598 ++++ b/gdb/mips-linux-nat.c
3599 +@@ -31,7 +31,7 @@
3600 + #include "gdb_proc_service.h"
3601 + #include "gregset.h"
3603 +-#include <sgidefs.h>
3604 ++#include <asm/sgidefs.h>
3605 + #include "nat/gdb_ptrace.h"
3606 + #include <asm/ptrace.h>
3607 + #include "inf-ptrace.h"
3608 +--
3609 +2.13.1
3611 diff -Naurp buildroot-2017.05-rc2/package/gdb/7.12.1/0005-use-asm-sgidefs.h.patch buildroot-2017.05.2/package/gdb/7.12.1/0005-use-asm-sgidefs.h.patch
3612 --- buildroot-2017.05-rc2/package/gdb/7.12.1/0005-use-asm-sgidefs.h.patch 1970-01-01 01:00:00.000000000 +0100
3613 +++ buildroot-2017.05.2/package/gdb/7.12.1/0005-use-asm-sgidefs.h.patch 2017-07-27 08:16:52.017486944 +0200
3614 @@ -0,0 +1,40 @@
3615 +From 12a0b8d81e1fda6ba98abdce8d6f09f9555ebcf5 Mon Sep 17 00:00:00 2001
3616 +From: Andre McCurdy <amccurdy@gmail.com>
3617 +Date: Sat, 30 Apr 2016 15:29:06 -0700
3618 +Subject: [PATCH] use <asm/sgidefs.h>
3620 +Build fix for MIPS with musl libc
3622 +The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
3623 +but not by musl. Regardless of the libc, the kernel headers provide
3624 +<asm/sgidefs.h> which provides the same definitions, so use that
3625 +instead.
3627 +Upstream-Status: Pending
3629 +[Vincent:
3630 +Taken from: https://sourceware.org/bugzilla/show_bug.cgi?id=21070]
3632 +Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
3633 +Signed-off-by: Khem Raj <raj.khem@gmail.com>
3634 +Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
3635 +---
3636 + gdb/mips-linux-nat.c | 2 +-
3637 + 1 file changed, 1 insertion(+), 1 deletion(-)
3639 +diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
3640 +index f2df1b9907..d24664cb56 100644
3641 +--- a/gdb/mips-linux-nat.c
3642 ++++ b/gdb/mips-linux-nat.c
3643 +@@ -31,7 +31,7 @@
3644 + #include "gdb_proc_service.h"
3645 + #include "gregset.h"
3647 +-#include <sgidefs.h>
3648 ++#include <asm/sgidefs.h>
3649 + #include "nat/gdb_ptrace.h"
3650 + #include <asm/ptrace.h>
3651 + #include "inf-ptrace.h"
3652 +--
3653 +2.13.1
3655 diff -Naurp buildroot-2017.05-rc2/package/gdb/Config.in.host buildroot-2017.05.2/package/gdb/Config.in.host
3656 --- buildroot-2017.05-rc2/package/gdb/Config.in.host 2017-05-17 10:27:16.013401440 +0200
3657 +++ buildroot-2017.05.2/package/gdb/Config.in.host 2017-07-27 08:16:52.017486944 +0200
3658 @@ -55,7 +55,7 @@ endif
3659 # If cross-gdb is not enabled, the latest working version is chosen.
3660 config BR2_GDB_VERSION
3661 string
3662 - default "arc-2017.03-rc2-gdb" if BR2_arc
3663 + default "arc-2017.03-gdb" if BR2_arc
3664 default "6be65fb56ea6694a9260733a536a023a1e2d4d57" if BR2_microblaze
3665 default "7.10.1" if BR2_GDB_VERSION_7_10
3666 default "7.11.1" if BR2_GDB_VERSION_7_11 || !BR2_PACKAGE_HOST_GDB
3667 diff -Naurp buildroot-2017.05-rc2/package/gdb/gdb.hash buildroot-2017.05.2/package/gdb/gdb.hash
3668 --- buildroot-2017.05-rc2/package/gdb/gdb.hash 2017-05-17 10:27:16.013401440 +0200
3669 +++ buildroot-2017.05.2/package/gdb/gdb.hash 2017-07-27 08:16:52.017486944 +0200
3670 @@ -5,4 +5,4 @@ sha512 0ac8d0a495103611ef41167a08313a01
3672 # Locally calculated (fetched from Github)
3673 sha512 0a467091d4b01fbecabb4b8da1cb743025c70e7f4874a0b5c8fa2ec623569a39bde6762b91806de0be6e63711aeb6909715cfbe43860de73d8aec6159a9f10a7 gdb-6be65fb56ea6694a9260733a536a023a1e2d4d57.tar.gz
3674 -sha512 275241c215d0bd32ab0f9f16358c46a66fd0d5db09d9a148b169a6b8135cfe91c6240a6bb75977573d4fc449a98f0702254577cbdc4598c6153ebbdca39253cf gdb-arc-2017.03-rc2-gdb.tar.gz
3675 +sha512 8ec849a5ea1c16f104c51c4813c35ab229e460eef0025967673b87316f62b5171f05448cda018464914d43d2da50b2902eb7f9f060d0af1368a9db111f959668 gdb-arc-2017.03-gdb.tar.gz
3676 diff -Naurp buildroot-2017.05-rc2/package/gesftpserver/gesftpserver.hash buildroot-2017.05.2/package/gesftpserver/gesftpserver.hash
3677 --- buildroot-2017.05-rc2/package/gesftpserver/gesftpserver.hash 2017-05-17 10:27:16.013401440 +0200
3678 +++ buildroot-2017.05.2/package/gesftpserver/gesftpserver.hash 2017-07-27 08:16:52.017486944 +0200
3679 @@ -1,2 +1,2 @@
3680 # Locally calculated
3681 -sha256 5f744c38df9bb82f5ab500858a0fb4767ac3ee2254301da03cbcf8e6c587cbf5 sftpserver-0.2.1.tar.gz
3682 +sha256 8ac1938d0f62a05799b2aeab489d6ce098c3fe53280a9b66c0957b1fdcbcbab9 sftpserver-0.2.2.tar.gz
3683 diff -Naurp buildroot-2017.05-rc2/package/gesftpserver/gesftpserver.mk buildroot-2017.05.2/package/gesftpserver/gesftpserver.mk
3684 --- buildroot-2017.05-rc2/package/gesftpserver/gesftpserver.mk 2017-05-17 10:27:16.013401440 +0200
3685 +++ buildroot-2017.05.2/package/gesftpserver/gesftpserver.mk 2017-07-27 08:16:52.017486944 +0200
3686 @@ -4,7 +4,7 @@
3688 ################################################################################
3690 -GESFTPSERVER_VERSION = 0.2.1
3691 +GESFTPSERVER_VERSION = 0.2.2
3692 GESFTPSERVER_SOURCE = sftpserver-$(GESFTPSERVER_VERSION).tar.gz
3693 GESFTPSERVER_SITE = http://www.greenend.org.uk/rjk/sftpserver
3694 GESFTPSERVER_LICENSE = GPL-2.0+
3695 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.23/0006-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch buildroot-2017.05.2/package/glibc/2.23/0006-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch
3696 --- buildroot-2017.05-rc2/package/glibc/2.23/0006-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 1970-01-01 01:00:00.000000000 +0100
3697 +++ buildroot-2017.05.2/package/glibc/2.23/0006-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 2017-07-27 08:16:52.017486944 +0200
3698 @@ -0,0 +1,35 @@
3699 +From f6110a8fee2ca36f8e2d2abecf3cba9fa7b8ea7d Mon Sep 17 00:00:00 2001
3700 +From: Florian Weimer <fweimer@redhat.com>
3701 +Date: Mon, 19 Jun 2017 17:09:55 +0200
3702 +Subject: [PATCH] CVE-2017-1000366: Ignore LD_LIBRARY_PATH for AT_SECURE=1
3703 + programs [BZ #21624]
3705 +LD_LIBRARY_PATH can only be used to reorder system search paths, which
3706 +is not useful functionality.
3708 +This makes an exploitable unbounded alloca in _dl_init_paths unreachable
3709 +for AT_SECURE=1 programs.
3711 +[Peter: Drop ChangeLog modification]
3712 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
3713 +---
3714 + elf/rtld.c | 3 ++-
3715 + 1 file changed, 8 insertions(+), 1 deletion(-)
3717 +diff --git a/elf/rtld.c b/elf/rtld.c
3718 +index 2446a87680..2269dbec81 100644
3719 +--- a/elf/rtld.c
3720 ++++ b/elf/rtld.c
3721 +@@ -2422,7 +2422,8 @@ process_envvars (enum mode *modep)
3723 + case 12:
3724 + /* The library search path. */
3725 +- if (memcmp (envline, "LIBRARY_PATH", 12) == 0)
3726 ++ if (!__libc_enable_secure
3727 ++ && memcmp (envline, "LIBRARY_PATH", 12) == 0)
3729 + library_path = &envline[13];
3730 + break;
3731 +--
3732 +2.11.0
3734 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.23/0007-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch buildroot-2017.05.2/package/glibc/2.23/0007-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch
3735 --- buildroot-2017.05-rc2/package/glibc/2.23/0007-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
3736 +++ buildroot-2017.05.2/package/glibc/2.23/0007-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
3737 @@ -0,0 +1,122 @@
3738 +From 6d0ba622891bed9d8394eef1935add53003b12e8 Mon Sep 17 00:00:00 2001
3739 +From: Florian Weimer <fweimer@redhat.com>
3740 +Date: Mon, 19 Jun 2017 22:31:04 +0200
3741 +Subject: [PATCH] ld.so: Reject overly long LD_PRELOAD path elements
3743 +[Peter: Drop ChangeLog modification]
3744 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
3745 +---
3746 + elf/rtld.c | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++------------
3747 + 1 file changed, 72 insertions(+), 16 deletions(-)
3749 +diff --git a/elf/rtld.c b/elf/rtld.c
3750 +index 2269dbec81..86ae20c83f 100644
3751 +--- a/elf/rtld.c
3752 ++++ b/elf/rtld.c
3753 +@@ -99,6 +99,35 @@ uintptr_t __pointer_chk_guard_local
3754 + strong_alias (__pointer_chk_guard_local, __pointer_chk_guard)
3755 + #endif
3757 ++/* Length limits for names and paths, to protect the dynamic linker,
3758 ++ particularly when __libc_enable_secure is active. */
3759 ++#ifdef NAME_MAX
3760 ++# define SECURE_NAME_LIMIT NAME_MAX
3761 ++#else
3762 ++# define SECURE_NAME_LIMIT 255
3763 ++#endif
3764 ++#ifdef PATH_MAX
3765 ++# define SECURE_PATH_LIMIT PATH_MAX
3766 ++#else
3767 ++# define SECURE_PATH_LIMIT 1024
3768 ++#endif
3770 ++/* Check that AT_SECURE=0, or that the passed name does not contain
3771 ++ directories and is not overly long. Reject empty names
3772 ++ unconditionally. */
3773 ++static bool
3774 ++dso_name_valid_for_suid (const char *p)
3776 ++ if (__glibc_unlikely (__libc_enable_secure))
3777 ++ {
3778 ++ /* Ignore pathnames with directories for AT_SECURE=1
3779 ++ programs, and also skip overlong names. */
3780 ++ size_t len = strlen (p);
3781 ++ if (len >= SECURE_NAME_LIMIT || memchr (p, '/', len) != NULL)
3782 ++ return false;
3783 ++ }
3784 ++ return *p != '\0';
3787 + /* List of auditing DSOs. */
3788 + static struct audit_list
3789 +@@ -718,6 +747,42 @@ static const char *preloadlist attribute_relro;
3790 + /* Nonzero if information about versions has to be printed. */
3791 + static int version_info attribute_relro;
3793 ++/* The LD_PRELOAD environment variable gives list of libraries
3794 ++ separated by white space or colons that are loaded before the
3795 ++ executable's dependencies and prepended to the global scope list.
3796 ++ (If the binary is running setuid all elements containing a '/' are
3797 ++ ignored since it is insecure.) Return the number of preloads
3798 ++ performed. */
3799 ++unsigned int
3800 ++handle_ld_preload (const char *preloadlist, struct link_map *main_map)
3802 ++ unsigned int npreloads = 0;
3803 ++ const char *p = preloadlist;
3804 ++ char fname[SECURE_PATH_LIMIT];
3806 ++ while (*p != '\0')
3807 ++ {
3808 ++ /* Split preload list at space/colon. */
3809 ++ size_t len = strcspn (p, " :");
3810 ++ if (len > 0 && len < sizeof (fname))
3811 ++ {
3812 ++ memcpy (fname, p, len);
3813 ++ fname[len] = '\0';
3814 ++ }
3815 ++ else
3816 ++ fname[0] = '\0';
3818 ++ /* Skip over the substring and the following delimiter. */
3819 ++ p += len;
3820 ++ if (*p != '\0')
3821 ++ ++p;
3823 ++ if (dso_name_valid_for_suid (fname))
3824 ++ npreloads += do_preload (fname, main_map, "LD_PRELOAD");
3825 ++ }
3826 ++ return npreloads;
3829 + static void
3830 + dl_main (const ElfW(Phdr) *phdr,
3831 + ElfW(Word) phnum,
3832 +@@ -1464,23 +1529,8 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
3834 + if (__glibc_unlikely (preloadlist != NULL))
3836 +- /* The LD_PRELOAD environment variable gives list of libraries
3837 +- separated by white space or colons that are loaded before the
3838 +- executable's dependencies and prepended to the global scope
3839 +- list. If the binary is running setuid all elements
3840 +- containing a '/' are ignored since it is insecure. */
3841 +- char *list = strdupa (preloadlist);
3842 +- char *p;
3844 + HP_TIMING_NOW (start);
3846 +- /* Prevent optimizing strsep. Speed is not important here. */
3847 +- while ((p = (strsep) (&list, " :")) != NULL)
3848 +- if (p[0] != '\0'
3849 +- && (__builtin_expect (! __libc_enable_secure, 1)
3850 +- || strchr (p, '/') == NULL))
3851 +- npreloads += do_preload (p, main_map, "LD_PRELOAD");
3853 ++ npreloads += handle_ld_preload (preloadlist, main_map);
3854 + HP_TIMING_NOW (stop);
3855 + HP_TIMING_DIFF (diff, start, stop);
3856 + HP_TIMING_ACCUM_NT (load_time, diff);
3857 +--
3858 +2.11.0
3860 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.23/0008-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch buildroot-2017.05.2/package/glibc/2.23/0008-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch
3861 --- buildroot-2017.05-rc2/package/glibc/2.23/0008-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
3862 +++ buildroot-2017.05.2/package/glibc/2.23/0008-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
3863 @@ -0,0 +1,204 @@
3864 +From 81b82fb966ffbd94353f793ad17116c6088dedd9 Mon Sep 17 00:00:00 2001
3865 +From: Florian Weimer <fweimer@redhat.com>
3866 +Date: Mon, 19 Jun 2017 22:32:12 +0200
3867 +Subject: [PATCH] ld.so: Reject overly long LD_AUDIT path elements
3869 +Also only process the last LD_AUDIT entry.
3871 +[Peter: Drop ChangeLog modification]
3872 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
3873 +---
3874 + elf/rtld.c | 110 ++++++++++++++++++++++++++++++++++++++++++++++++++++---------
3875 + 1 file changed, 105 insertions(+), 15 deletions(-)
3877 +diff --git a/elf/rtld.c b/elf/rtld.c
3878 +index 86ae20c83f..65647fb1c8 100644
3879 +--- a/elf/rtld.c
3880 ++++ b/elf/rtld.c
3881 +@@ -129,13 +129,91 @@ dso_name_valid_for_suid (const char *p)
3882 + return *p != '\0';
3885 +-/* List of auditing DSOs. */
3886 ++/* LD_AUDIT variable contents. Must be processed before the
3887 ++ audit_list below. */
3888 ++const char *audit_list_string;
3890 ++/* Cyclic list of auditing DSOs. audit_list->next is the first
3891 ++ element. */
3892 + static struct audit_list
3894 + const char *name;
3895 + struct audit_list *next;
3896 + } *audit_list;
3898 ++/* Iterator for audit_list_string followed by audit_list. */
3899 ++struct audit_list_iter
3901 ++ /* Tail of audit_list_string still needing processing, or NULL. */
3902 ++ const char *audit_list_tail;
3904 ++ /* The list element returned in the previous iteration. NULL before
3905 ++ the first element. */
3906 ++ struct audit_list *previous;
3908 ++ /* Scratch buffer for returning a name which is part of
3909 ++ audit_list_string. */
3910 ++ char fname[SECURE_NAME_LIMIT];
3911 ++};
3913 ++/* Initialize an audit list iterator. */
3914 ++static void
3915 ++audit_list_iter_init (struct audit_list_iter *iter)
3917 ++ iter->audit_list_tail = audit_list_string;
3918 ++ iter->previous = NULL;
3921 ++/* Iterate through both audit_list_string and audit_list. */
3922 ++static const char *
3923 ++audit_list_iter_next (struct audit_list_iter *iter)
3925 ++ if (iter->audit_list_tail != NULL)
3926 ++ {
3927 ++ /* First iterate over audit_list_string. */
3928 ++ while (*iter->audit_list_tail != '\0')
3929 ++ {
3930 ++ /* Split audit list at colon. */
3931 ++ size_t len = strcspn (iter->audit_list_tail, ":");
3932 ++ if (len > 0 && len < sizeof (iter->fname))
3933 ++ {
3934 ++ memcpy (iter->fname, iter->audit_list_tail, len);
3935 ++ iter->fname[len] = '\0';
3936 ++ }
3937 ++ else
3938 ++ /* Do not return this name to the caller. */
3939 ++ iter->fname[0] = '\0';
3941 ++ /* Skip over the substring and the following delimiter. */
3942 ++ iter->audit_list_tail += len;
3943 ++ if (*iter->audit_list_tail == ':')
3944 ++ ++iter->audit_list_tail;
3946 ++ /* If the name is valid, return it. */
3947 ++ if (dso_name_valid_for_suid (iter->fname))
3948 ++ return iter->fname;
3949 ++ /* Otherwise, wrap around and try the next name. */
3950 ++ }
3951 ++ /* Fall through to the procesing of audit_list. */
3952 ++ }
3954 ++ if (iter->previous == NULL)
3955 ++ {
3956 ++ if (audit_list == NULL)
3957 ++ /* No pre-parsed audit list. */
3958 ++ return NULL;
3959 ++ /* Start of audit list. The first list element is at
3960 ++ audit_list->next (cyclic list). */
3961 ++ iter->previous = audit_list->next;
3962 ++ return iter->previous->name;
3963 ++ }
3964 ++ if (iter->previous == audit_list)
3965 ++ /* Cyclic list wrap-around. */
3966 ++ return NULL;
3967 ++ iter->previous = iter->previous->next;
3968 ++ return iter->previous->name;
3971 + #ifndef HAVE_INLINED_SYSCALLS
3972 + /* Set nonzero during loading and initialization of executable and
3973 + libraries, cleared before the executable's entry point runs. This
3974 +@@ -1305,11 +1383,13 @@ of this helper program; chances are you did not intend to run this program.\n\
3975 + GL(dl_rtld_map).l_tls_modid = _dl_next_tls_modid ();
3977 + /* If we have auditing DSOs to load, do it now. */
3978 +- if (__glibc_unlikely (audit_list != NULL))
3979 ++ bool need_security_init = true;
3980 ++ if (__glibc_unlikely (audit_list != NULL)
3981 ++ || __glibc_unlikely (audit_list_string != NULL))
3983 +- /* Iterate over all entries in the list. The order is important. */
3984 + struct audit_ifaces *last_audit = NULL;
3985 +- struct audit_list *al = audit_list->next;
3986 ++ struct audit_list_iter al_iter;
3987 ++ audit_list_iter_init (&al_iter);
3989 + /* Since we start using the auditing DSOs right away we need to
3990 + initialize the data structures now. */
3991 +@@ -1320,9 +1400,14 @@ of this helper program; chances are you did not intend to run this program.\n\
3992 + use different values (especially the pointer guard) and will
3993 + fail later on. */
3994 + security_init ();
3995 ++ need_security_init = false;
3997 +- do
3998 ++ while (true)
4000 ++ const char *name = audit_list_iter_next (&al_iter);
4001 ++ if (name == NULL)
4002 ++ break;
4004 + int tls_idx = GL(dl_tls_max_dtv_idx);
4006 + /* Now it is time to determine the layout of the static TLS
4007 +@@ -1331,7 +1416,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4008 + no DF_STATIC_TLS bit is set. The reason is that we know
4009 + glibc will use the static model. */
4010 + struct dlmopen_args dlmargs;
4011 +- dlmargs.fname = al->name;
4012 ++ dlmargs.fname = name;
4013 + dlmargs.map = NULL;
4015 + const char *objname;
4016 +@@ -1344,7 +1429,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4017 + not_loaded:
4018 + _dl_error_printf ("\
4019 + ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4020 +- al->name, err_str);
4021 ++ name, err_str);
4022 + if (malloced)
4023 + free ((char *) err_str);
4025 +@@ -1448,10 +1533,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4026 + goto not_loaded;
4030 +- al = al->next;
4032 +- while (al != audit_list->next);
4034 + /* If we have any auditing modules, announce that we already
4035 + have two objects loaded. */
4036 +@@ -1715,7 +1797,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4037 + if (tcbp == NULL)
4038 + tcbp = init_tls ();
4040 +- if (__glibc_likely (audit_list == NULL))
4041 ++ if (__glibc_likely (need_security_init))
4042 + /* Initialize security features. But only if we have not done it
4043 + earlier. */
4044 + security_init ();
4045 +@@ -2346,9 +2428,7 @@ process_dl_audit (char *str)
4046 + char *p;
4048 + while ((p = (strsep) (&str, ":")) != NULL)
4049 +- if (p[0] != '\0'
4050 +- && (__builtin_expect (! __libc_enable_secure, 1)
4051 +- || strchr (p, '/') == NULL))
4052 ++ if (dso_name_valid_for_suid (p))
4054 + /* This is using the local malloc, not the system malloc. The
4055 + memory can never be freed. */
4056 +@@ -2412,7 +2492,7 @@ process_envvars (enum mode *modep)
4057 + break;
4059 + if (memcmp (envline, "AUDIT", 5) == 0)
4060 +- process_dl_audit (&envline[6]);
4061 ++ audit_list_string = &envline[6];
4062 + break;
4064 + case 7:
4065 +--
4066 +2.11.0
4068 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.24/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch buildroot-2017.05.2/package/glibc/2.24/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch
4069 --- buildroot-2017.05-rc2/package/glibc/2.24/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 1970-01-01 01:00:00.000000000 +0100
4070 +++ buildroot-2017.05.2/package/glibc/2.24/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 2017-07-27 08:16:52.017486944 +0200
4071 @@ -0,0 +1,35 @@
4072 +From f6110a8fee2ca36f8e2d2abecf3cba9fa7b8ea7d Mon Sep 17 00:00:00 2001
4073 +From: Florian Weimer <fweimer@redhat.com>
4074 +Date: Mon, 19 Jun 2017 17:09:55 +0200
4075 +Subject: [PATCH] CVE-2017-1000366: Ignore LD_LIBRARY_PATH for AT_SECURE=1
4076 + programs [BZ #21624]
4078 +LD_LIBRARY_PATH can only be used to reorder system search paths, which
4079 +is not useful functionality.
4081 +This makes an exploitable unbounded alloca in _dl_init_paths unreachable
4082 +for AT_SECURE=1 programs.
4084 +[Peter: Drop ChangeLog modification]
4085 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4086 +---
4087 + elf/rtld.c | 3 ++-
4088 + 1 file changed, 8 insertions(+), 1 deletion(-)
4090 +diff --git a/elf/rtld.c b/elf/rtld.c
4091 +index 2446a87680..2269dbec81 100644
4092 +--- a/elf/rtld.c
4093 ++++ b/elf/rtld.c
4094 +@@ -2422,7 +2422,8 @@ process_envvars (enum mode *modep)
4096 + case 12:
4097 + /* The library search path. */
4098 +- if (memcmp (envline, "LIBRARY_PATH", 12) == 0)
4099 ++ if (!__libc_enable_secure
4100 ++ && memcmp (envline, "LIBRARY_PATH", 12) == 0)
4102 + library_path = &envline[13];
4103 + break;
4104 +--
4105 +2.11.0
4107 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.24/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch buildroot-2017.05.2/package/glibc/2.24/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch
4108 --- buildroot-2017.05-rc2/package/glibc/2.24/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
4109 +++ buildroot-2017.05.2/package/glibc/2.24/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
4110 @@ -0,0 +1,122 @@
4111 +From 6d0ba622891bed9d8394eef1935add53003b12e8 Mon Sep 17 00:00:00 2001
4112 +From: Florian Weimer <fweimer@redhat.com>
4113 +Date: Mon, 19 Jun 2017 22:31:04 +0200
4114 +Subject: [PATCH] ld.so: Reject overly long LD_PRELOAD path elements
4116 +[Peter: Drop ChangeLog modification]
4117 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4118 +---
4119 + elf/rtld.c | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++------------
4120 + 1 file changed, 72 insertions(+), 16 deletions(-)
4122 +diff --git a/elf/rtld.c b/elf/rtld.c
4123 +index 2269dbec81..86ae20c83f 100644
4124 +--- a/elf/rtld.c
4125 ++++ b/elf/rtld.c
4126 +@@ -99,6 +99,35 @@ uintptr_t __pointer_chk_guard_local
4127 + strong_alias (__pointer_chk_guard_local, __pointer_chk_guard)
4128 + #endif
4130 ++/* Length limits for names and paths, to protect the dynamic linker,
4131 ++ particularly when __libc_enable_secure is active. */
4132 ++#ifdef NAME_MAX
4133 ++# define SECURE_NAME_LIMIT NAME_MAX
4134 ++#else
4135 ++# define SECURE_NAME_LIMIT 255
4136 ++#endif
4137 ++#ifdef PATH_MAX
4138 ++# define SECURE_PATH_LIMIT PATH_MAX
4139 ++#else
4140 ++# define SECURE_PATH_LIMIT 1024
4141 ++#endif
4143 ++/* Check that AT_SECURE=0, or that the passed name does not contain
4144 ++ directories and is not overly long. Reject empty names
4145 ++ unconditionally. */
4146 ++static bool
4147 ++dso_name_valid_for_suid (const char *p)
4149 ++ if (__glibc_unlikely (__libc_enable_secure))
4150 ++ {
4151 ++ /* Ignore pathnames with directories for AT_SECURE=1
4152 ++ programs, and also skip overlong names. */
4153 ++ size_t len = strlen (p);
4154 ++ if (len >= SECURE_NAME_LIMIT || memchr (p, '/', len) != NULL)
4155 ++ return false;
4156 ++ }
4157 ++ return *p != '\0';
4160 + /* List of auditing DSOs. */
4161 + static struct audit_list
4162 +@@ -718,6 +747,42 @@ static const char *preloadlist attribute_relro;
4163 + /* Nonzero if information about versions has to be printed. */
4164 + static int version_info attribute_relro;
4166 ++/* The LD_PRELOAD environment variable gives list of libraries
4167 ++ separated by white space or colons that are loaded before the
4168 ++ executable's dependencies and prepended to the global scope list.
4169 ++ (If the binary is running setuid all elements containing a '/' are
4170 ++ ignored since it is insecure.) Return the number of preloads
4171 ++ performed. */
4172 ++unsigned int
4173 ++handle_ld_preload (const char *preloadlist, struct link_map *main_map)
4175 ++ unsigned int npreloads = 0;
4176 ++ const char *p = preloadlist;
4177 ++ char fname[SECURE_PATH_LIMIT];
4179 ++ while (*p != '\0')
4180 ++ {
4181 ++ /* Split preload list at space/colon. */
4182 ++ size_t len = strcspn (p, " :");
4183 ++ if (len > 0 && len < sizeof (fname))
4184 ++ {
4185 ++ memcpy (fname, p, len);
4186 ++ fname[len] = '\0';
4187 ++ }
4188 ++ else
4189 ++ fname[0] = '\0';
4191 ++ /* Skip over the substring and the following delimiter. */
4192 ++ p += len;
4193 ++ if (*p != '\0')
4194 ++ ++p;
4196 ++ if (dso_name_valid_for_suid (fname))
4197 ++ npreloads += do_preload (fname, main_map, "LD_PRELOAD");
4198 ++ }
4199 ++ return npreloads;
4202 + static void
4203 + dl_main (const ElfW(Phdr) *phdr,
4204 + ElfW(Word) phnum,
4205 +@@ -1464,23 +1529,8 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4207 + if (__glibc_unlikely (preloadlist != NULL))
4209 +- /* The LD_PRELOAD environment variable gives list of libraries
4210 +- separated by white space or colons that are loaded before the
4211 +- executable's dependencies and prepended to the global scope
4212 +- list. If the binary is running setuid all elements
4213 +- containing a '/' are ignored since it is insecure. */
4214 +- char *list = strdupa (preloadlist);
4215 +- char *p;
4217 + HP_TIMING_NOW (start);
4219 +- /* Prevent optimizing strsep. Speed is not important here. */
4220 +- while ((p = (strsep) (&list, " :")) != NULL)
4221 +- if (p[0] != '\0'
4222 +- && (__builtin_expect (! __libc_enable_secure, 1)
4223 +- || strchr (p, '/') == NULL))
4224 +- npreloads += do_preload (p, main_map, "LD_PRELOAD");
4226 ++ npreloads += handle_ld_preload (preloadlist, main_map);
4227 + HP_TIMING_NOW (stop);
4228 + HP_TIMING_DIFF (diff, start, stop);
4229 + HP_TIMING_ACCUM_NT (load_time, diff);
4230 +--
4231 +2.11.0
4233 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.24/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch buildroot-2017.05.2/package/glibc/2.24/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch
4234 --- buildroot-2017.05-rc2/package/glibc/2.24/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
4235 +++ buildroot-2017.05.2/package/glibc/2.24/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
4236 @@ -0,0 +1,204 @@
4237 +From 81b82fb966ffbd94353f793ad17116c6088dedd9 Mon Sep 17 00:00:00 2001
4238 +From: Florian Weimer <fweimer@redhat.com>
4239 +Date: Mon, 19 Jun 2017 22:32:12 +0200
4240 +Subject: [PATCH] ld.so: Reject overly long LD_AUDIT path elements
4242 +Also only process the last LD_AUDIT entry.
4244 +[Peter: Drop ChangeLog modification]
4245 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4246 +---
4247 + elf/rtld.c | 110 ++++++++++++++++++++++++++++++++++++++++++++++++++++---------
4248 + 1 file changed, 105 insertions(+), 15 deletions(-)
4250 +diff --git a/elf/rtld.c b/elf/rtld.c
4251 +index 86ae20c83f..65647fb1c8 100644
4252 +--- a/elf/rtld.c
4253 ++++ b/elf/rtld.c
4254 +@@ -129,13 +129,91 @@ dso_name_valid_for_suid (const char *p)
4255 + return *p != '\0';
4258 +-/* List of auditing DSOs. */
4259 ++/* LD_AUDIT variable contents. Must be processed before the
4260 ++ audit_list below. */
4261 ++const char *audit_list_string;
4263 ++/* Cyclic list of auditing DSOs. audit_list->next is the first
4264 ++ element. */
4265 + static struct audit_list
4267 + const char *name;
4268 + struct audit_list *next;
4269 + } *audit_list;
4271 ++/* Iterator for audit_list_string followed by audit_list. */
4272 ++struct audit_list_iter
4274 ++ /* Tail of audit_list_string still needing processing, or NULL. */
4275 ++ const char *audit_list_tail;
4277 ++ /* The list element returned in the previous iteration. NULL before
4278 ++ the first element. */
4279 ++ struct audit_list *previous;
4281 ++ /* Scratch buffer for returning a name which is part of
4282 ++ audit_list_string. */
4283 ++ char fname[SECURE_NAME_LIMIT];
4284 ++};
4286 ++/* Initialize an audit list iterator. */
4287 ++static void
4288 ++audit_list_iter_init (struct audit_list_iter *iter)
4290 ++ iter->audit_list_tail = audit_list_string;
4291 ++ iter->previous = NULL;
4294 ++/* Iterate through both audit_list_string and audit_list. */
4295 ++static const char *
4296 ++audit_list_iter_next (struct audit_list_iter *iter)
4298 ++ if (iter->audit_list_tail != NULL)
4299 ++ {
4300 ++ /* First iterate over audit_list_string. */
4301 ++ while (*iter->audit_list_tail != '\0')
4302 ++ {
4303 ++ /* Split audit list at colon. */
4304 ++ size_t len = strcspn (iter->audit_list_tail, ":");
4305 ++ if (len > 0 && len < sizeof (iter->fname))
4306 ++ {
4307 ++ memcpy (iter->fname, iter->audit_list_tail, len);
4308 ++ iter->fname[len] = '\0';
4309 ++ }
4310 ++ else
4311 ++ /* Do not return this name to the caller. */
4312 ++ iter->fname[0] = '\0';
4314 ++ /* Skip over the substring and the following delimiter. */
4315 ++ iter->audit_list_tail += len;
4316 ++ if (*iter->audit_list_tail == ':')
4317 ++ ++iter->audit_list_tail;
4319 ++ /* If the name is valid, return it. */
4320 ++ if (dso_name_valid_for_suid (iter->fname))
4321 ++ return iter->fname;
4322 ++ /* Otherwise, wrap around and try the next name. */
4323 ++ }
4324 ++ /* Fall through to the procesing of audit_list. */
4325 ++ }
4327 ++ if (iter->previous == NULL)
4328 ++ {
4329 ++ if (audit_list == NULL)
4330 ++ /* No pre-parsed audit list. */
4331 ++ return NULL;
4332 ++ /* Start of audit list. The first list element is at
4333 ++ audit_list->next (cyclic list). */
4334 ++ iter->previous = audit_list->next;
4335 ++ return iter->previous->name;
4336 ++ }
4337 ++ if (iter->previous == audit_list)
4338 ++ /* Cyclic list wrap-around. */
4339 ++ return NULL;
4340 ++ iter->previous = iter->previous->next;
4341 ++ return iter->previous->name;
4344 + #ifndef HAVE_INLINED_SYSCALLS
4345 + /* Set nonzero during loading and initialization of executable and
4346 + libraries, cleared before the executable's entry point runs. This
4347 +@@ -1305,11 +1383,13 @@ of this helper program; chances are you did not intend to run this program.\n\
4348 + GL(dl_rtld_map).l_tls_modid = _dl_next_tls_modid ();
4350 + /* If we have auditing DSOs to load, do it now. */
4351 +- if (__glibc_unlikely (audit_list != NULL))
4352 ++ bool need_security_init = true;
4353 ++ if (__glibc_unlikely (audit_list != NULL)
4354 ++ || __glibc_unlikely (audit_list_string != NULL))
4356 +- /* Iterate over all entries in the list. The order is important. */
4357 + struct audit_ifaces *last_audit = NULL;
4358 +- struct audit_list *al = audit_list->next;
4359 ++ struct audit_list_iter al_iter;
4360 ++ audit_list_iter_init (&al_iter);
4362 + /* Since we start using the auditing DSOs right away we need to
4363 + initialize the data structures now. */
4364 +@@ -1320,9 +1400,14 @@ of this helper program; chances are you did not intend to run this program.\n\
4365 + use different values (especially the pointer guard) and will
4366 + fail later on. */
4367 + security_init ();
4368 ++ need_security_init = false;
4370 +- do
4371 ++ while (true)
4373 ++ const char *name = audit_list_iter_next (&al_iter);
4374 ++ if (name == NULL)
4375 ++ break;
4377 + int tls_idx = GL(dl_tls_max_dtv_idx);
4379 + /* Now it is time to determine the layout of the static TLS
4380 +@@ -1331,7 +1416,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4381 + no DF_STATIC_TLS bit is set. The reason is that we know
4382 + glibc will use the static model. */
4383 + struct dlmopen_args dlmargs;
4384 +- dlmargs.fname = al->name;
4385 ++ dlmargs.fname = name;
4386 + dlmargs.map = NULL;
4388 + const char *objname;
4389 +@@ -1344,7 +1429,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4390 + not_loaded:
4391 + _dl_error_printf ("\
4392 + ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4393 +- al->name, err_str);
4394 ++ name, err_str);
4395 + if (malloced)
4396 + free ((char *) err_str);
4398 +@@ -1448,10 +1533,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4399 + goto not_loaded;
4403 +- al = al->next;
4405 +- while (al != audit_list->next);
4407 + /* If we have any auditing modules, announce that we already
4408 + have two objects loaded. */
4409 +@@ -1715,7 +1797,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4410 + if (tcbp == NULL)
4411 + tcbp = init_tls ();
4413 +- if (__glibc_likely (audit_list == NULL))
4414 ++ if (__glibc_likely (need_security_init))
4415 + /* Initialize security features. But only if we have not done it
4416 + earlier. */
4417 + security_init ();
4418 +@@ -2346,9 +2428,7 @@ process_dl_audit (char *str)
4419 + char *p;
4421 + while ((p = (strsep) (&str, ":")) != NULL)
4422 +- if (p[0] != '\0'
4423 +- && (__builtin_expect (! __libc_enable_secure, 1)
4424 +- || strchr (p, '/') == NULL))
4425 ++ if (dso_name_valid_for_suid (p))
4427 + /* This is using the local malloc, not the system malloc. The
4428 + memory can never be freed. */
4429 +@@ -2412,7 +2492,7 @@ process_envvars (enum mode *modep)
4430 + break;
4432 + if (memcmp (envline, "AUDIT", 5) == 0)
4433 +- process_dl_audit (&envline[6]);
4434 ++ audit_list_string = &envline[6];
4435 + break;
4437 + case 7:
4438 +--
4439 +2.11.0
4441 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.25/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch buildroot-2017.05.2/package/glibc/2.25/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch
4442 --- buildroot-2017.05-rc2/package/glibc/2.25/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 1970-01-01 01:00:00.000000000 +0100
4443 +++ buildroot-2017.05.2/package/glibc/2.25/0002-CVE-2017-1000366-Ignore-LD_LIBRARY_PATH-for-AT_SECUR.patch 2017-07-27 08:16:52.017486944 +0200
4444 @@ -0,0 +1,35 @@
4445 +From f6110a8fee2ca36f8e2d2abecf3cba9fa7b8ea7d Mon Sep 17 00:00:00 2001
4446 +From: Florian Weimer <fweimer@redhat.com>
4447 +Date: Mon, 19 Jun 2017 17:09:55 +0200
4448 +Subject: [PATCH] CVE-2017-1000366: Ignore LD_LIBRARY_PATH for AT_SECURE=1
4449 + programs [BZ #21624]
4451 +LD_LIBRARY_PATH can only be used to reorder system search paths, which
4452 +is not useful functionality.
4454 +This makes an exploitable unbounded alloca in _dl_init_paths unreachable
4455 +for AT_SECURE=1 programs.
4457 +[Peter: Drop ChangeLog modification]
4458 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4459 +---
4460 + elf/rtld.c | 3 ++-
4461 + 1 file changed, 8 insertions(+), 1 deletion(-)
4463 +diff --git a/elf/rtld.c b/elf/rtld.c
4464 +index 2446a87680..2269dbec81 100644
4465 +--- a/elf/rtld.c
4466 ++++ b/elf/rtld.c
4467 +@@ -2422,7 +2422,8 @@ process_envvars (enum mode *modep)
4469 + case 12:
4470 + /* The library search path. */
4471 +- if (memcmp (envline, "LIBRARY_PATH", 12) == 0)
4472 ++ if (!__libc_enable_secure
4473 ++ && memcmp (envline, "LIBRARY_PATH", 12) == 0)
4475 + library_path = &envline[13];
4476 + break;
4477 +--
4478 +2.11.0
4480 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.25/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch buildroot-2017.05.2/package/glibc/2.25/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch
4481 --- buildroot-2017.05-rc2/package/glibc/2.25/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
4482 +++ buildroot-2017.05.2/package/glibc/2.25/0003-ld.so-Reject-overly-long-LD_PRELOAD-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
4483 @@ -0,0 +1,122 @@
4484 +From 6d0ba622891bed9d8394eef1935add53003b12e8 Mon Sep 17 00:00:00 2001
4485 +From: Florian Weimer <fweimer@redhat.com>
4486 +Date: Mon, 19 Jun 2017 22:31:04 +0200
4487 +Subject: [PATCH] ld.so: Reject overly long LD_PRELOAD path elements
4489 +[Peter: Drop ChangeLog modification]
4490 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4491 +---
4492 + elf/rtld.c | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++------------
4493 + 1 file changed, 72 insertions(+), 16 deletions(-)
4495 +diff --git a/elf/rtld.c b/elf/rtld.c
4496 +index 2269dbec81..86ae20c83f 100644
4497 +--- a/elf/rtld.c
4498 ++++ b/elf/rtld.c
4499 +@@ -99,6 +99,35 @@ uintptr_t __pointer_chk_guard_local
4500 + strong_alias (__pointer_chk_guard_local, __pointer_chk_guard)
4501 + #endif
4503 ++/* Length limits for names and paths, to protect the dynamic linker,
4504 ++ particularly when __libc_enable_secure is active. */
4505 ++#ifdef NAME_MAX
4506 ++# define SECURE_NAME_LIMIT NAME_MAX
4507 ++#else
4508 ++# define SECURE_NAME_LIMIT 255
4509 ++#endif
4510 ++#ifdef PATH_MAX
4511 ++# define SECURE_PATH_LIMIT PATH_MAX
4512 ++#else
4513 ++# define SECURE_PATH_LIMIT 1024
4514 ++#endif
4516 ++/* Check that AT_SECURE=0, or that the passed name does not contain
4517 ++ directories and is not overly long. Reject empty names
4518 ++ unconditionally. */
4519 ++static bool
4520 ++dso_name_valid_for_suid (const char *p)
4522 ++ if (__glibc_unlikely (__libc_enable_secure))
4523 ++ {
4524 ++ /* Ignore pathnames with directories for AT_SECURE=1
4525 ++ programs, and also skip overlong names. */
4526 ++ size_t len = strlen (p);
4527 ++ if (len >= SECURE_NAME_LIMIT || memchr (p, '/', len) != NULL)
4528 ++ return false;
4529 ++ }
4530 ++ return *p != '\0';
4533 + /* List of auditing DSOs. */
4534 + static struct audit_list
4535 +@@ -718,6 +747,42 @@ static const char *preloadlist attribute_relro;
4536 + /* Nonzero if information about versions has to be printed. */
4537 + static int version_info attribute_relro;
4539 ++/* The LD_PRELOAD environment variable gives list of libraries
4540 ++ separated by white space or colons that are loaded before the
4541 ++ executable's dependencies and prepended to the global scope list.
4542 ++ (If the binary is running setuid all elements containing a '/' are
4543 ++ ignored since it is insecure.) Return the number of preloads
4544 ++ performed. */
4545 ++unsigned int
4546 ++handle_ld_preload (const char *preloadlist, struct link_map *main_map)
4548 ++ unsigned int npreloads = 0;
4549 ++ const char *p = preloadlist;
4550 ++ char fname[SECURE_PATH_LIMIT];
4552 ++ while (*p != '\0')
4553 ++ {
4554 ++ /* Split preload list at space/colon. */
4555 ++ size_t len = strcspn (p, " :");
4556 ++ if (len > 0 && len < sizeof (fname))
4557 ++ {
4558 ++ memcpy (fname, p, len);
4559 ++ fname[len] = '\0';
4560 ++ }
4561 ++ else
4562 ++ fname[0] = '\0';
4564 ++ /* Skip over the substring and the following delimiter. */
4565 ++ p += len;
4566 ++ if (*p != '\0')
4567 ++ ++p;
4569 ++ if (dso_name_valid_for_suid (fname))
4570 ++ npreloads += do_preload (fname, main_map, "LD_PRELOAD");
4571 ++ }
4572 ++ return npreloads;
4575 + static void
4576 + dl_main (const ElfW(Phdr) *phdr,
4577 + ElfW(Word) phnum,
4578 +@@ -1464,23 +1529,8 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4580 + if (__glibc_unlikely (preloadlist != NULL))
4582 +- /* The LD_PRELOAD environment variable gives list of libraries
4583 +- separated by white space or colons that are loaded before the
4584 +- executable's dependencies and prepended to the global scope
4585 +- list. If the binary is running setuid all elements
4586 +- containing a '/' are ignored since it is insecure. */
4587 +- char *list = strdupa (preloadlist);
4588 +- char *p;
4590 + HP_TIMING_NOW (start);
4592 +- /* Prevent optimizing strsep. Speed is not important here. */
4593 +- while ((p = (strsep) (&list, " :")) != NULL)
4594 +- if (p[0] != '\0'
4595 +- && (__builtin_expect (! __libc_enable_secure, 1)
4596 +- || strchr (p, '/') == NULL))
4597 +- npreloads += do_preload (p, main_map, "LD_PRELOAD");
4599 ++ npreloads += handle_ld_preload (preloadlist, main_map);
4600 + HP_TIMING_NOW (stop);
4601 + HP_TIMING_DIFF (diff, start, stop);
4602 + HP_TIMING_ACCUM_NT (load_time, diff);
4603 +--
4604 +2.11.0
4606 diff -Naurp buildroot-2017.05-rc2/package/glibc/2.25/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch buildroot-2017.05.2/package/glibc/2.25/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch
4607 --- buildroot-2017.05-rc2/package/glibc/2.25/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 1970-01-01 01:00:00.000000000 +0100
4608 +++ buildroot-2017.05.2/package/glibc/2.25/0004-ld.so-Reject-overly-long-LD_AUDIT-path-elements.patch 2017-07-27 08:16:52.017486944 +0200
4609 @@ -0,0 +1,204 @@
4610 +From 81b82fb966ffbd94353f793ad17116c6088dedd9 Mon Sep 17 00:00:00 2001
4611 +From: Florian Weimer <fweimer@redhat.com>
4612 +Date: Mon, 19 Jun 2017 22:32:12 +0200
4613 +Subject: [PATCH] ld.so: Reject overly long LD_AUDIT path elements
4615 +Also only process the last LD_AUDIT entry.
4617 +[Peter: Drop ChangeLog modification]
4618 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
4619 +---
4620 + elf/rtld.c | 110 ++++++++++++++++++++++++++++++++++++++++++++++++++++---------
4621 + 1 file changed, 105 insertions(+), 15 deletions(-)
4623 +diff --git a/elf/rtld.c b/elf/rtld.c
4624 +index 86ae20c83f..65647fb1c8 100644
4625 +--- a/elf/rtld.c
4626 ++++ b/elf/rtld.c
4627 +@@ -129,13 +129,91 @@ dso_name_valid_for_suid (const char *p)
4628 + return *p != '\0';
4631 +-/* List of auditing DSOs. */
4632 ++/* LD_AUDIT variable contents. Must be processed before the
4633 ++ audit_list below. */
4634 ++const char *audit_list_string;
4636 ++/* Cyclic list of auditing DSOs. audit_list->next is the first
4637 ++ element. */
4638 + static struct audit_list
4640 + const char *name;
4641 + struct audit_list *next;
4642 + } *audit_list;
4644 ++/* Iterator for audit_list_string followed by audit_list. */
4645 ++struct audit_list_iter
4647 ++ /* Tail of audit_list_string still needing processing, or NULL. */
4648 ++ const char *audit_list_tail;
4650 ++ /* The list element returned in the previous iteration. NULL before
4651 ++ the first element. */
4652 ++ struct audit_list *previous;
4654 ++ /* Scratch buffer for returning a name which is part of
4655 ++ audit_list_string. */
4656 ++ char fname[SECURE_NAME_LIMIT];
4657 ++};
4659 ++/* Initialize an audit list iterator. */
4660 ++static void
4661 ++audit_list_iter_init (struct audit_list_iter *iter)
4663 ++ iter->audit_list_tail = audit_list_string;
4664 ++ iter->previous = NULL;
4667 ++/* Iterate through both audit_list_string and audit_list. */
4668 ++static const char *
4669 ++audit_list_iter_next (struct audit_list_iter *iter)
4671 ++ if (iter->audit_list_tail != NULL)
4672 ++ {
4673 ++ /* First iterate over audit_list_string. */
4674 ++ while (*iter->audit_list_tail != '\0')
4675 ++ {
4676 ++ /* Split audit list at colon. */
4677 ++ size_t len = strcspn (iter->audit_list_tail, ":");
4678 ++ if (len > 0 && len < sizeof (iter->fname))
4679 ++ {
4680 ++ memcpy (iter->fname, iter->audit_list_tail, len);
4681 ++ iter->fname[len] = '\0';
4682 ++ }
4683 ++ else
4684 ++ /* Do not return this name to the caller. */
4685 ++ iter->fname[0] = '\0';
4687 ++ /* Skip over the substring and the following delimiter. */
4688 ++ iter->audit_list_tail += len;
4689 ++ if (*iter->audit_list_tail == ':')
4690 ++ ++iter->audit_list_tail;
4692 ++ /* If the name is valid, return it. */
4693 ++ if (dso_name_valid_for_suid (iter->fname))
4694 ++ return iter->fname;
4695 ++ /* Otherwise, wrap around and try the next name. */
4696 ++ }
4697 ++ /* Fall through to the procesing of audit_list. */
4698 ++ }
4700 ++ if (iter->previous == NULL)
4701 ++ {
4702 ++ if (audit_list == NULL)
4703 ++ /* No pre-parsed audit list. */
4704 ++ return NULL;
4705 ++ /* Start of audit list. The first list element is at
4706 ++ audit_list->next (cyclic list). */
4707 ++ iter->previous = audit_list->next;
4708 ++ return iter->previous->name;
4709 ++ }
4710 ++ if (iter->previous == audit_list)
4711 ++ /* Cyclic list wrap-around. */
4712 ++ return NULL;
4713 ++ iter->previous = iter->previous->next;
4714 ++ return iter->previous->name;
4717 + #ifndef HAVE_INLINED_SYSCALLS
4718 + /* Set nonzero during loading and initialization of executable and
4719 + libraries, cleared before the executable's entry point runs. This
4720 +@@ -1305,11 +1383,13 @@ of this helper program; chances are you did not intend to run this program.\n\
4721 + GL(dl_rtld_map).l_tls_modid = _dl_next_tls_modid ();
4723 + /* If we have auditing DSOs to load, do it now. */
4724 +- if (__glibc_unlikely (audit_list != NULL))
4725 ++ bool need_security_init = true;
4726 ++ if (__glibc_unlikely (audit_list != NULL)
4727 ++ || __glibc_unlikely (audit_list_string != NULL))
4729 +- /* Iterate over all entries in the list. The order is important. */
4730 + struct audit_ifaces *last_audit = NULL;
4731 +- struct audit_list *al = audit_list->next;
4732 ++ struct audit_list_iter al_iter;
4733 ++ audit_list_iter_init (&al_iter);
4735 + /* Since we start using the auditing DSOs right away we need to
4736 + initialize the data structures now. */
4737 +@@ -1320,9 +1400,14 @@ of this helper program; chances are you did not intend to run this program.\n\
4738 + use different values (especially the pointer guard) and will
4739 + fail later on. */
4740 + security_init ();
4741 ++ need_security_init = false;
4743 +- do
4744 ++ while (true)
4746 ++ const char *name = audit_list_iter_next (&al_iter);
4747 ++ if (name == NULL)
4748 ++ break;
4750 + int tls_idx = GL(dl_tls_max_dtv_idx);
4752 + /* Now it is time to determine the layout of the static TLS
4753 +@@ -1331,7 +1416,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4754 + no DF_STATIC_TLS bit is set. The reason is that we know
4755 + glibc will use the static model. */
4756 + struct dlmopen_args dlmargs;
4757 +- dlmargs.fname = al->name;
4758 ++ dlmargs.fname = name;
4759 + dlmargs.map = NULL;
4761 + const char *objname;
4762 +@@ -1344,7 +1429,7 @@ of this helper program; chances are you did not intend to run this program.\n\
4763 + not_loaded:
4764 + _dl_error_printf ("\
4765 + ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4766 +- al->name, err_str);
4767 ++ name, err_str);
4768 + if (malloced)
4769 + free ((char *) err_str);
4771 +@@ -1448,10 +1533,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4772 + goto not_loaded;
4776 +- al = al->next;
4778 +- while (al != audit_list->next);
4780 + /* If we have any auditing modules, announce that we already
4781 + have two objects loaded. */
4782 +@@ -1715,7 +1797,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n",
4783 + if (tcbp == NULL)
4784 + tcbp = init_tls ();
4786 +- if (__glibc_likely (audit_list == NULL))
4787 ++ if (__glibc_likely (need_security_init))
4788 + /* Initialize security features. But only if we have not done it
4789 + earlier. */
4790 + security_init ();
4791 +@@ -2346,9 +2428,7 @@ process_dl_audit (char *str)
4792 + char *p;
4794 + while ((p = (strsep) (&str, ":")) != NULL)
4795 +- if (p[0] != '\0'
4796 +- && (__builtin_expect (! __libc_enable_secure, 1)
4797 +- || strchr (p, '/') == NULL))
4798 ++ if (dso_name_valid_for_suid (p))
4800 + /* This is using the local malloc, not the system malloc. The
4801 + memory can never be freed. */
4802 +@@ -2412,7 +2492,7 @@ process_envvars (enum mode *modep)
4803 + break;
4805 + if (memcmp (envline, "AUDIT", 5) == 0)
4806 +- process_dl_audit (&envline[6]);
4807 ++ audit_list_string = &envline[6];
4808 + break;
4810 + case 7:
4811 +--
4812 +2.11.0
4814 diff -Naurp buildroot-2017.05-rc2/package/glmark2/0002-NativeStateDRM-use-fixed-event-context-version.patch buildroot-2017.05.2/package/glmark2/0002-NativeStateDRM-use-fixed-event-context-version.patch
4815 --- buildroot-2017.05-rc2/package/glmark2/0002-NativeStateDRM-use-fixed-event-context-version.patch 1970-01-01 01:00:00.000000000 +0100
4816 +++ buildroot-2017.05.2/package/glmark2/0002-NativeStateDRM-use-fixed-event-context-version.patch 2017-07-27 08:16:52.017486944 +0200
4817 @@ -0,0 +1,28 @@
4818 +From: Lucas Stach <l.stach@pengutronix.de>
4819 +Date: Wed, 31 May 2017 13:01:00 +0200
4820 +Subject: [PATCH] NativeStateDRM: use fixed event context version
4822 +Using the latest version is not a good idea, as the context content may
4823 +change between versions.
4825 +Fixes a segfault with new kernel and libdrm.
4827 +Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
4828 +Signed-off-by: Fabio Estevam <festevam@gmail.com>
4829 +---
4830 + src/native-state-drm.cpp | 2 +-
4831 + 1 file changed, 1 insertion(+), 1 deletion(-)
4833 +diff --git a/src/native-state-drm.cpp b/src/native-state-drm.cpp
4834 +index 454a24d898ff..b9af996667dc 100644
4835 +--- a/src/native-state-drm.cpp
4836 ++++ b/src/native-state-drm.cpp
4837 +@@ -106,7 +106,7 @@ NativeStateDRM::flip()
4838 + FD_ZERO(&fds);
4839 + FD_SET(fd_, &fds);
4840 + drmEventContext evCtx;
4841 +- evCtx.version = DRM_EVENT_CONTEXT_VERSION;
4842 ++ evCtx.version = 2;
4843 + evCtx.page_flip_handler = page_flip_handler;
4845 + while (waiting) {
4846 diff -Naurp buildroot-2017.05-rc2/package/gnutls/Config.in buildroot-2017.05.2/package/gnutls/Config.in
4847 --- buildroot-2017.05-rc2/package/gnutls/Config.in 2017-05-17 10:27:16.013401440 +0200
4848 +++ buildroot-2017.05.2/package/gnutls/Config.in 2017-07-27 08:16:52.017486944 +0200
4849 @@ -1,5 +1,7 @@
4850 config BR2_PACKAGE_GNUTLS
4851 bool "gnutls"
4852 + # https://gitlab.com/gnutls/gnutls/issues/203
4853 + depends on !BR2_STATIC_LIBS
4854 depends on BR2_USE_WCHAR
4855 select BR2_PACKAGE_LIBTASN1
4856 select BR2_PACKAGE_LIBUNISTRING
4857 @@ -22,5 +24,5 @@ config BR2_PACKAGE_GNUTLS_TOOLS
4859 endif
4861 -comment "gnutls needs a toolchain w/ wchar"
4862 - depends on !BR2_USE_WCHAR
4863 +comment "gnutls needs a toolchain w/ wchar, dynamic library"
4864 + depends on !BR2_USE_WCHAR || BR2_STATIC_LIBS
4865 diff -Naurp buildroot-2017.05-rc2/package/gnutls/gnutls.hash buildroot-2017.05.2/package/gnutls/gnutls.hash
4866 --- buildroot-2017.05-rc2/package/gnutls/gnutls.hash 2017-05-17 10:27:16.013401440 +0200
4867 +++ buildroot-2017.05.2/package/gnutls/gnutls.hash 2017-07-27 08:16:52.017486944 +0200
4868 @@ -1,2 +1,2 @@
4869 # Locally calculated after checking pgp signature
4870 -sha256 af443e86ba538d4d3e37c4732c00101a492fe4b56a55f4112ff0ab39dbe6579d gnutls-3.5.10.tar.xz
4871 +sha256 79f5480ad198dad5bc78e075f4a40c4a315a1b2072666919d2d05a08aec13096 gnutls-3.5.13.tar.xz
4872 diff -Naurp buildroot-2017.05-rc2/package/gnutls/gnutls.mk buildroot-2017.05.2/package/gnutls/gnutls.mk
4873 --- buildroot-2017.05-rc2/package/gnutls/gnutls.mk 2017-05-17 10:27:16.013401440 +0200
4874 +++ buildroot-2017.05.2/package/gnutls/gnutls.mk 2017-07-27 08:16:52.017486944 +0200
4875 @@ -5,9 +5,9 @@
4876 ################################################################################
4878 GNUTLS_VERSION_MAJOR = 3.5
4879 -GNUTLS_VERSION = $(GNUTLS_VERSION_MAJOR).10
4880 +GNUTLS_VERSION = $(GNUTLS_VERSION_MAJOR).13
4881 GNUTLS_SOURCE = gnutls-$(GNUTLS_VERSION).tar.xz
4882 -GNUTLS_SITE = ftp://ftp.gnutls.org/gcrypt/gnutls/v$(GNUTLS_VERSION_MAJOR)
4883 +GNUTLS_SITE = https://www.gnupg.org/ftp/gcrypt/gnutls/v$(GNUTLS_VERSION_MAJOR)
4884 GNUTLS_LICENSE = LGPL-2.1+ (core library), GPL-3.0+ (gnutls-openssl library)
4885 GNUTLS_LICENSE_FILES = doc/COPYING doc/COPYING.LESSER
4886 GNUTLS_DEPENDENCIES = host-pkgconf libunistring libtasn1 nettle pcre
4887 diff -Naurp buildroot-2017.05-rc2/package/google-breakpad/google-breakpad.mk buildroot-2017.05.2/package/google-breakpad/google-breakpad.mk
4888 --- buildroot-2017.05-rc2/package/google-breakpad/google-breakpad.mk 2017-05-17 10:27:16.013401440 +0200
4889 +++ buildroot-2017.05.2/package/google-breakpad/google-breakpad.mk 2017-07-27 08:16:52.017486944 +0200
4890 @@ -23,14 +23,14 @@ define HOST_GOOGLE_BREAKPAD_LSS
4891 $(HOST_DIR)/usr/include/linux_syscall_support.h \
4892 $(@D)/src/third_party/lss/linux_syscall_support.h
4893 endef
4894 -HOST_GOOGLE_BREAKPAD_POST_EXTRACT_HOOKS += HOST_GOOGLE_BREAKPAD_LSS
4895 +HOST_GOOGLE_BREAKPAD_PRE_CONFIGURE_HOOKS += HOST_GOOGLE_BREAKPAD_LSS
4897 define GOOGLE_BREAKPAD_LSS
4898 $(INSTALL) -D -m 0644 \
4899 $(STAGING_DIR)/usr/include/linux_syscall_support.h \
4900 $(@D)/src/third_party/lss/linux_syscall_support.h
4901 endef
4902 -GOOGLE_BREAKPAD_POST_EXTRACT_HOOKS += GOOGLE_BREAKPAD_LSS
4903 +GOOGLE_BREAKPAD_PRE_CONFIGURE_HOOKS += GOOGLE_BREAKPAD_LSS
4905 define GOOGLE_BREAKPAD_EXTRACT_SYMBOLS
4906 $(EXTRA_ENV) package/google-breakpad/gen-syms.sh $(STAGING_DIR) \
4907 diff -Naurp buildroot-2017.05-rc2/package/gstreamer1/gst1-plugins-bad/Config.in buildroot-2017.05.2/package/gstreamer1/gst1-plugins-bad/Config.in
4908 --- buildroot-2017.05-rc2/package/gstreamer1/gst1-plugins-bad/Config.in 2017-05-17 10:27:16.013401440 +0200
4909 +++ buildroot-2017.05.2/package/gstreamer1/gst1-plugins-bad/Config.in 2017-07-27 08:16:52.017486944 +0200
4910 @@ -698,8 +698,8 @@ config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUG
4911 help
4912 Webp image format plugin
4914 -config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTC
4915 - bool "webrtc"
4916 +config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTCDSP
4917 + bool "webrtcdsp"
4918 # All depends from webrtc-audio-processing
4919 depends on BR2_PACKAGE_WEBRTC_AUDIO_PROCESSING_ARCH_SUPPORTS
4920 depends on BR2_INSTALL_LIBSTDCPP
4921 @@ -710,7 +710,7 @@ config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUG
4922 help
4923 WebRTC echo-cancellation, gain control and noise suppression
4925 -comment "webrtc needs a toolchain w/ C++, NPTL, gcc >= 4.8"
4926 +comment "webrtcdsp needs a toolchain w/ C++, NPTL, gcc >= 4.8"
4927 depends on BR2_PACKAGE_WEBRTC_AUDIO_PROCESSING_ARCH_SUPPORTS
4928 depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS_NPTL \
4929 || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_8
4930 diff -Naurp buildroot-2017.05-rc2/package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk buildroot-2017.05.2/package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk
4931 --- buildroot-2017.05-rc2/package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk 2017-05-17 10:27:16.013401440 +0200
4932 +++ buildroot-2017.05.2/package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk 2017-07-27 08:16:52.017486944 +0200
4933 @@ -813,11 +813,11 @@ else
4934 GST1_PLUGINS_BAD_CONF_OPTS += --disable-webp
4935 endif
4937 -ifeq ($(BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTC),y)
4938 -GST1_PLUGINS_BAD_CONF_OPTS += --enable-webrtc
4939 +ifeq ($(BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WEBRTCDSP),y)
4940 +GST1_PLUGINS_BAD_CONF_OPTS += --enable-webrtcdsp
4941 GST1_PLUGINS_BAD_DEPENDENCIES += webrtc-audio-processing
4942 else
4943 -GST1_PLUGINS_BAD_CONF_OPTS += --disable-webrtc
4944 +GST1_PLUGINS_BAD_CONF_OPTS += --disable-webrtcdsp
4945 endif
4947 ifeq ($(BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_X265),y)
4948 diff -Naurp buildroot-2017.05-rc2/package/hans/hans.mk buildroot-2017.05.2/package/hans/hans.mk
4949 --- buildroot-2017.05-rc2/package/hans/hans.mk 2017-05-17 10:27:16.013401440 +0200
4950 +++ buildroot-2017.05.2/package/hans/hans.mk 2017-07-27 08:16:52.017486944 +0200
4951 @@ -10,7 +10,7 @@ HANS_LICENSE = GPL-3.0+
4952 HANS_LICENSE_FILES = LICENSE
4954 define HANS_BUILD_CMDS
4955 - $(TARGET_MAKE_ENV) $(MAKE) GCC="$(TARGET_CC)" GPP="$(TARGET_CXX)" -C $(@D)
4956 + $(TARGET_MAKE_ENV) $(MAKE1) GCC="$(TARGET_CC)" GPP="$(TARGET_CXX)" -C $(@D)
4957 endef
4959 define HANS_INSTALL_TARGET_CMDS
4960 diff -Naurp buildroot-2017.05-rc2/package/heimdal/heimdal.hash buildroot-2017.05.2/package/heimdal/heimdal.hash
4961 --- buildroot-2017.05-rc2/package/heimdal/heimdal.hash 2017-05-17 10:27:16.013401440 +0200
4962 +++ buildroot-2017.05.2/package/heimdal/heimdal.hash 2017-07-27 08:16:52.017486944 +0200
4963 @@ -1,2 +1,2 @@
4964 -# Locally calculated after checking pgp signature
4965 -sha256 cee58ab3a4ce79f243a3e73f465dac19fe2b93ef1c5ff244d6f1d689fedbde2d heimdal-7.1.0.tar.gz
4966 +# Locally calculated
4967 +sha256 3de14ecd36ad21c1694a13da347512b047f4010d176fe412820664cb5d1429ad heimdal-7.4.0.tar.gz
4968 diff -Naurp buildroot-2017.05-rc2/package/heimdal/heimdal.mk buildroot-2017.05.2/package/heimdal/heimdal.mk
4969 --- buildroot-2017.05-rc2/package/heimdal/heimdal.mk 2017-05-17 10:27:16.013401440 +0200
4970 +++ buildroot-2017.05.2/package/heimdal/heimdal.mk 2017-07-27 08:16:52.017486944 +0200
4971 @@ -4,8 +4,8 @@
4973 ################################################################################
4975 -HEIMDAL_VERSION = 7.1.0
4976 -HEIMDAL_SITE = http://www.h5l.org/dist/src
4977 +HEIMDAL_VERSION = 7.4.0
4978 +HEIMDAL_SITE = https://github.com/heimdal/heimdal/releases/download/heimdal-$(HEIMDAL_VERSION)
4979 HOST_HEIMDAL_DEPENDENCIES = host-e2fsprogs host-ncurses host-pkgconf
4980 HEIMDAL_INSTALL_STAGING = YES
4981 HEIMDAL_MAKE = $(MAKE1)
4982 @@ -15,6 +15,7 @@ HOST_HEIMDAL_CONF_OPTS = \
4983 --enable-static \
4984 --without-openldap \
4985 --without-capng \
4986 + --with-db-type-preference= \
4987 --without-sqlite3 \
4988 --without-libintl \
4989 --without-openssl \
4990 diff -Naurp buildroot-2017.05-rc2/package/imagemagick/0001-https-github.com-ImageMagick-ImageMagick-issues-415.patch buildroot-2017.05.2/package/imagemagick/0001-https-github.com-ImageMagick-ImageMagick-issues-415.patch
4991 --- buildroot-2017.05-rc2/package/imagemagick/0001-https-github.com-ImageMagick-ImageMagick-issues-415.patch 2017-05-17 10:27:16.013401440 +0200
4992 +++ buildroot-2017.05.2/package/imagemagick/0001-https-github.com-ImageMagick-ImageMagick-issues-415.patch 1970-01-01 01:00:00.000000000 +0100
4993 @@ -1,52 +0,0 @@
4994 -From b218117cad34d39b9ffb587b45c71c5a49b12bde Mon Sep 17 00:00:00 2001
4995 -From: Cristy <urban-warrior@imagemagick.org>
4996 -Date: Fri, 31 Mar 2017 15:24:33 -0400
4997 -Subject: [PATCH] https://github.com/ImageMagick/ImageMagick/issues/415
4999 -Fixes CVE-2017-7606
5001 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
5002 ----
5003 - coders/pnm.c | 2 +-
5004 - coders/rle.c | 5 +++--
5005 - 2 files changed, 4 insertions(+), 3 deletions(-)
5007 -diff --git a/coders/pnm.c b/coders/pnm.c
5008 -index 9a1221d79..c525ebb8f 100644
5009 ---- a/coders/pnm.c
5010 -+++ b/coders/pnm.c
5011 -@@ -1979,7 +1979,7 @@ static MagickBooleanType WritePNMImage(const ImageInfo *image_info,Image *image,
5012 - pixel=ScaleQuantumToChar(GetPixelRed(image,p));
5013 - else
5014 - pixel=ScaleQuantumToAny(GetPixelRed(image,p),
5015 -- max_value);
5016 -+ max_value);
5018 - q=PopCharPixel((unsigned char) pixel,q);
5019 - p+=GetPixelChannels(image);
5020 -diff --git a/coders/rle.c b/coders/rle.c
5021 -index 2318901ec..ec071dc7b 100644
5022 ---- a/coders/rle.c
5023 -+++ b/coders/rle.c
5024 -@@ -271,7 +271,8 @@ static Image *ReadRLEImage(const ImageInfo *image_info,ExceptionInfo *exception)
5025 - p=colormap;
5026 - for (i=0; i < (ssize_t) number_colormaps; i++)
5027 - for (x=0; x < (ssize_t) map_length; x++)
5028 -- *p++=(unsigned char) ScaleShortToQuantum(ReadBlobLSBShort(image));
5029 -+ *p++=(unsigned char) ScaleQuantumToChar(ScaleShortToQuantum(
5030 -+ ReadBlobLSBShort(image)));
5032 - if ((flags & 0x08) != 0)
5034 -@@ -476,7 +477,7 @@ static Image *ReadRLEImage(const ImageInfo *image_info,ExceptionInfo *exception)
5035 - for (x=0; x < (ssize_t) number_planes; x++)
5037 - ValidateColormapValue(image,(size_t) (x*map_length+
5038 -- (*p & mask)),&index,exception);
5039 -+ (*p & mask)),&index,exception);
5040 - *p=colormap[(ssize_t) index];
5041 - p++;
5043 ---
5044 -2.11.0
5046 diff -Naurp buildroot-2017.05-rc2/package/imagemagick/imagemagick.hash buildroot-2017.05.2/package/imagemagick/imagemagick.hash
5047 --- buildroot-2017.05-rc2/package/imagemagick/imagemagick.hash 2017-05-17 10:27:16.013401440 +0200
5048 +++ buildroot-2017.05.2/package/imagemagick/imagemagick.hash 2017-07-27 08:16:52.017486944 +0200
5049 @@ -1,2 +1,2 @@
5050 # From http://www.imagemagick.org/download/releases/digest.rdf
5051 -sha256 4a1dde5bdfec0fc549955a051be25b7ff96dfb192060997699e43c7ce0f06ab2 ImageMagick-7.0.5-4.tar.xz
5052 +sha256 0058fcde533986334458a5c99600b1b9633182dd9562cbad4ba618c5ccf2a28f ImageMagick-7.0.5-10.tar.xz
5053 diff -Naurp buildroot-2017.05-rc2/package/imagemagick/imagemagick.mk buildroot-2017.05.2/package/imagemagick/imagemagick.mk
5054 --- buildroot-2017.05-rc2/package/imagemagick/imagemagick.mk 2017-05-17 10:27:16.013401440 +0200
5055 +++ buildroot-2017.05.2/package/imagemagick/imagemagick.mk 2017-07-27 08:16:52.017486944 +0200
5056 @@ -4,7 +4,7 @@
5058 ################################################################################
5060 -IMAGEMAGICK_VERSION = 7.0.5-4
5061 +IMAGEMAGICK_VERSION = 7.0.5-10
5062 IMAGEMAGICK_SOURCE = ImageMagick-$(IMAGEMAGICK_VERSION).tar.xz
5063 IMAGEMAGICK_SITE = http://www.imagemagick.org/download/releases
5064 IMAGEMAGICK_LICENSE = Apache-2.0
5065 diff -Naurp buildroot-2017.05-rc2/package/intltool/0001-perl-5.26-compatibility.patch buildroot-2017.05.2/package/intltool/0001-perl-5.26-compatibility.patch
5066 --- buildroot-2017.05-rc2/package/intltool/0001-perl-5.26-compatibility.patch 1970-01-01 01:00:00.000000000 +0100
5067 +++ buildroot-2017.05.2/package/intltool/0001-perl-5.26-compatibility.patch 2017-07-27 08:16:52.017486944 +0200
5068 @@ -0,0 +1,55 @@
5069 +Fix regex errors thrown by Perl 5.26:
5071 +Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/^(.*)\${ <-- HERE ?([A-Z_]+)}?(.*)$/ at $BUILDROOT/host/usr/bin/intltool-update line 1065.
5073 +Fetched from:
5074 +https://github.com/Alexpux/MSYS2-packages/blob/master/intltool/perl-5.22-compatibility.patch
5076 +Reported upstream:
5077 +https://bugs.launchpad.net/intltool/+bug/1696658
5079 +Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
5081 +--- intltool-0.51.0.orig/intltool-update.in 2015-03-09 02:39:54.000000000 +0100
5082 ++++ intltool-0.51.0.orig/intltool-update.in 2015-06-19 01:52:07.171228154 +0200
5083 +@@ -1062,7 +1062,7 @@
5087 +- if ($str =~ /^(.*)\${?([A-Z_]+)}?(.*)$/)
5088 ++ if ($str =~ /^(.*)\$\{?([A-Z_]+)}?(.*)$/)
5090 + my $rest = $3;
5091 + my $untouched = $1;
5092 +@@ -1190,10 +1190,10 @@
5093 + $name =~ s/\(+$//g;
5094 + $version =~ s/\(+$//g;
5096 +- $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\${?AC_PACKAGE_NAME}?/);
5097 +- $varhash{"PACKAGE"} = $name if (not $name =~ /\${?PACKAGE}?/);
5098 +- $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\${?AC_PACKAGE_VERSION}?/);
5099 +- $varhash{"VERSION"} = $version if (not $name =~ /\${?VERSION}?/);
5100 ++ $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\$\{?AC_PACKAGE_NAME}?/);
5101 ++ $varhash{"PACKAGE"} = $name if (not $name =~ /\$\{?PACKAGE}?/);
5102 ++ $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\$\{?AC_PACKAGE_VERSION}?/);
5103 ++ $varhash{"VERSION"} = $version if (not $name =~ /\$\{?VERSION}?/);
5106 + if ($conf_source =~ /^AC_INIT\(([^,\)]+),([^,\)]+)[,]?([^,\)]+)?/m)
5107 +@@ -1219,11 +1219,11 @@
5108 + $version =~ s/\(+$//g;
5109 + $bugurl =~ s/\(+$//g if (defined $bugurl);
5111 +- $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\${?AC_PACKAGE_NAME}?/);
5112 +- $varhash{"PACKAGE"} = $name if (not $name =~ /\${?PACKAGE}?/);
5113 +- $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\${?AC_PACKAGE_VERSION}?/);
5114 +- $varhash{"VERSION"} = $version if (not $name =~ /\${?VERSION}?/);
5115 +- $varhash{"PACKAGE_BUGREPORT"} = $bugurl if (defined $bugurl and not $bugurl =~ /\${?\w+}?/);
5116 ++ $varhash{"PACKAGE_NAME"} = $name if (not $name =~ /\$\{?AC_PACKAGE_NAME}?/);
5117 ++ $varhash{"PACKAGE"} = $name if (not $name =~ /\$\{?PACKAGE}?/);
5118 ++ $varhash{"PACKAGE_VERSION"} = $version if (not $name =~ /\$\{?AC_PACKAGE_VERSION}?/);
5119 ++ $varhash{"VERSION"} = $version if (not $name =~ /\$\{?VERSION}?/);
5120 ++ $varhash{"PACKAGE_BUGREPORT"} = $bugurl if (defined $bugurl and not $bugurl =~ /\$\{?\w+}?/);
5123 + # \s makes this not work, why?
5124 diff -Naurp buildroot-2017.05-rc2/package/iperf/iperf.hash buildroot-2017.05.2/package/iperf/iperf.hash
5125 --- buildroot-2017.05-rc2/package/iperf/iperf.hash 2017-05-17 10:27:16.013401440 +0200
5126 +++ buildroot-2017.05.2/package/iperf/iperf.hash 2017-07-27 08:16:52.017486944 +0200
5127 @@ -1,4 +1,4 @@
5128 # From https://sourceforge.net/projects/iperf2/files/
5129 -sha1 9e215f6af8edd97f947f2b0207ff5487845d83d4 iperf-2.0.9.tar.gz
5130 +sha1 59820895df9106ba189ccfdc5677077535ad50e7 iperf-2.0.9.tar.gz
5131 # Locally computed:
5132 -sha256 a5350777b191e910334d3a107b5e5219b72ffa393da4186da1e0a4552aeeded6 iperf-2.0.9.tar.gz
5133 +sha256 db02911f35686e808ed247160dfa766e08ae3f59d1e7dcedef0ffb2a6643f0bf iperf-2.0.9.tar.gz
5134 diff -Naurp buildroot-2017.05-rc2/package/iproute2/iproute2.mk buildroot-2017.05.2/package/iproute2/iproute2.mk
5135 --- buildroot-2017.05-rc2/package/iproute2/iproute2.mk 2017-05-17 10:27:16.013401440 +0200
5136 +++ buildroot-2017.05.2/package/iproute2/iproute2.mk 2017-07-27 08:16:52.017486944 +0200
5137 @@ -9,7 +9,7 @@ IPROUTE2_SOURCE = iproute2-$(IPROUTE2_VE
5138 IPROUTE2_SITE = $(BR2_KERNEL_MIRROR)/linux/utils/net/iproute2
5139 IPROUTE2_DEPENDENCIES = host-bison host-flex host-pkgconf \
5140 $(if $(BR2_PACKAGE_LIBMNL),libmnl)
5141 -IPROUTE2_LICENSE = GPL-2.0
5142 +IPROUTE2_LICENSE = GPL-2.0+
5143 IPROUTE2_LICENSE_FILES = COPYING
5145 # If both iproute2 and busybox are selected, make certain we win
5146 diff -Naurp buildroot-2017.05-rc2/package/ipsec-tools/0002-CVE-2015-4047.patch buildroot-2017.05.2/package/ipsec-tools/0002-CVE-2015-4047.patch
5147 --- buildroot-2017.05-rc2/package/ipsec-tools/0002-CVE-2015-4047.patch 1970-01-01 01:00:00.000000000 +0100
5148 +++ buildroot-2017.05.2/package/ipsec-tools/0002-CVE-2015-4047.patch 2017-07-27 08:16:52.017486944 +0200
5149 @@ -0,0 +1,26 @@
5150 +ipsec-tools: CVE-2015-4047: null pointer dereference crash in racoon
5152 +See: https://bugs.gentoo.org/show_bug.cgi?id=550118
5154 +Downloaded from
5155 +https://gitweb.gentoo.org/repo/gentoo.git/tree/net-vpn/ipsec-tools/files/ipsec-tools-CVE-2015-4047.patch
5157 +See also
5158 +https://sources.debian.net/src/ipsec-tools/1:0.8.2%2B20140711-8/debian/patches/bug785778-null-pointer-deref.patch/
5160 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
5162 +--- ./src/racoon/gssapi.c 9 Sep 2006 16:22:09 -0000 1.4
5163 ++++ ./src/racoon/gssapi.c 19 May 2015 15:16:00 -0000 1.6
5164 +@@ -192,6 +192,11 @@
5165 + gss_name_t princ, canon_princ;
5166 + OM_uint32 maj_stat, min_stat;
5168 ++ if (iph1->rmconf == NULL) {
5169 ++ plog(LLV_ERROR, LOCATION, NULL, "no remote config\n");
5170 ++ return -1;
5171 ++ }
5173 + gps = racoon_calloc(1, sizeof (struct gssapi_ph1_state));
5174 + if (gps == NULL) {
5175 + plog(LLV_ERROR, LOCATION, NULL, "racoon_calloc failed\n");
5176 diff -Naurp buildroot-2017.05-rc2/package/irssi/0001-Get-back-to-using-pkg-config-to-check-for-OpenSSL.patch buildroot-2017.05.2/package/irssi/0001-Get-back-to-using-pkg-config-to-check-for-OpenSSL.patch
5177 --- buildroot-2017.05-rc2/package/irssi/0001-Get-back-to-using-pkg-config-to-check-for-OpenSSL.patch 2017-05-17 10:27:16.013401440 +0200
5178 +++ buildroot-2017.05.2/package/irssi/0001-Get-back-to-using-pkg-config-to-check-for-OpenSSL.patch 1970-01-01 01:00:00.000000000 +0100
5179 @@ -1,77 +0,0 @@
5180 -From ed0c2c1b9504a99a6dcc3c0f5de3b3a1c0232758 Mon Sep 17 00:00:00 2001
5181 -From: Rodrigo Rebello <rprebello@gmail.com>
5182 -Date: Mon, 20 Mar 2017 13:17:42 -0300
5183 -Subject: [PATCH] Get back to using pkg-config to check for OpenSSL
5185 -Commit 6300dfec7 removed the option to disable SSL support from the
5186 -configure script since it became a requirement, but it also removed the
5187 -use of pkg-config for finding the OpenSSL library and its dependencies.
5189 -This had the unfortunate consequence of breaking the correct detection
5190 -of library flags in many static linking scenarios. In some cases, for
5191 -example, OpenSSL might have been built with zlib, which requires `-lz`
5192 -to be passed to the linker when doing a static link of the irssi
5193 -executable. Thus, pkg-config becomes an invaluable tool in such
5194 -situations, since no guessing work is needed as the OpenSSL .pc file
5195 -provides all the necessary flags.
5197 -So, this patch re-inserts the PKG_CHECK_MODULES macro in the configure
5198 -script when looking for OpenSSL. The test using AC_CHECK_LIB remains,
5199 -but only as a last resort in case the one using pkg-config fails.
5201 -Also, because the macro AM_PATH_GLIB_2_0 contains an unconditional call
5202 -to PKG_PROG_PKG_CONFIG, the OpenSSL checks are moved so that they come
5203 -after the Glib ones in order to avoid doubly checking for the pkg-config
5204 -binary (PKG_CHECK_MODULES skips that check if it has been performed
5205 -before, but PKG_PROG_PKG_CONFIG does not).
5207 -Upstream status: submitted
5208 -https://github.com/irssi/irssi/pull/677
5210 -Signed-off-by: Rodrigo Rebello <rprebello@gmail.com>
5211 ----
5212 - configure.ac | 21 +++++++++++++++------
5213 - 1 file changed, 15 insertions(+), 6 deletions(-)
5215 -diff --git a/configure.ac b/configure.ac
5216 -index 02b33497..9f191d3f 100644
5217 ---- a/configure.ac
5218 -+++ b/configure.ac
5219 -@@ -231,11 +231,6 @@ if test "x$want_socks" = "xyes"; then
5220 - fi
5222 - dnl **
5223 --dnl ** OpenSSL checks
5224 --dnl **
5225 --AC_CHECK_LIB([ssl], [SSL_library_init])
5227 --dnl **
5228 - dnl ** fe-text checks
5229 - dnl **
5231 -@@ -276,7 +271,21 @@ if test -z "$GLIB_LIBS"; then
5232 - AC_ERROR([GLIB is required to build irssi.])
5233 - fi
5235 --LIBS="$LIBS $GLIB_LIBS -lssl -lcrypto"
5236 -+LIBS="$LIBS $GLIB_LIBS"
5238 -+dnl **
5239 -+dnl ** OpenSSL checks
5240 -+dnl **
5241 -+PKG_CHECK_MODULES([OPENSSL], [openssl], [
5242 -+ CFLAGS="$CFLAGS $OPENSSL_CFLAGS"
5243 -+ LIBS="$LIBS $OPENSSL_LIBS"
5244 -+], [
5245 -+ AC_CHECK_LIB([ssl], [SSL_library_init], [
5246 -+ LIBS="$LIBS -lssl -lcrypto"
5247 -+ ], [
5248 -+ AC_MSG_ERROR([The OpenSSL library was not found])
5249 -+ ])
5250 -+])
5252 - dnl **
5253 - dnl ** curses checks
5254 ---
5255 -2.11.0
5257 diff -Naurp buildroot-2017.05-rc2/package/irssi/irssi.hash buildroot-2017.05.2/package/irssi/irssi.hash
5258 --- buildroot-2017.05-rc2/package/irssi/irssi.hash 2017-05-17 10:27:16.013401440 +0200
5259 +++ buildroot-2017.05.2/package/irssi/irssi.hash 2017-07-27 08:16:52.017486944 +0200
5260 @@ -1,2 +1,2 @@
5261 # Locally calculated after checking pgp signature
5262 -sha256 5c1c3cc2caf103aad073fadeb000e0f8cb3b416833a7f43ceb8bd9fcf275fbe9 irssi-1.0.2.tar.xz
5263 +sha256 b85c07dbafe178213eccdc69f5f8f0ac024dea01c67244668f91ec1c06b986ca irssi-1.0.4.tar.xz
5264 diff -Naurp buildroot-2017.05-rc2/package/irssi/irssi.mk buildroot-2017.05.2/package/irssi/irssi.mk
5265 --- buildroot-2017.05-rc2/package/irssi/irssi.mk 2017-05-17 10:27:16.013401440 +0200
5266 +++ buildroot-2017.05.2/package/irssi/irssi.mk 2017-07-27 08:16:52.017486944 +0200
5267 @@ -4,7 +4,7 @@
5269 ################################################################################
5271 -IRSSI_VERSION = 1.0.2
5272 +IRSSI_VERSION = 1.0.4
5273 IRSSI_SOURCE = irssi-$(IRSSI_VERSION).tar.xz
5274 # Do not use the github helper here. The generated tarball is *NOT* the
5275 # same as the one uploaded by upstream for the release.
5276 @@ -13,12 +13,8 @@ IRSSI_LICENSE = GPL-2.0+
5277 IRSSI_LICENSE_FILES = COPYING
5278 IRSSI_DEPENDENCIES = host-pkgconf libglib2 ncurses openssl
5280 -# We're patching configure.ac, so we need to autoreconf
5281 -IRSSI_AUTORECONF = YES
5283 IRSSI_CONF_OPTS = \
5284 --disable-glibtest \
5285 - --with-ncurses=$(STAGING_DIR)/usr \
5286 --without-perl
5288 ifeq ($(BR2_PACKAGE_IRSSI_PROXY),y)
5289 diff -Naurp buildroot-2017.05-rc2/package/keepalived/Config.in buildroot-2017.05.2/package/keepalived/Config.in
5290 --- buildroot-2017.05-rc2/package/keepalived/Config.in 2017-05-17 10:27:16.013401440 +0200
5291 +++ buildroot-2017.05.2/package/keepalived/Config.in 2017-07-27 08:16:52.017486944 +0200
5292 @@ -2,6 +2,7 @@ config BR2_PACKAGE_KEEPALIVED
5293 bool "keepalived"
5294 depends on BR2_USE_MMU
5295 depends on !BR2_STATIC_LIBS # uses libdl
5296 + depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_4
5297 select BR2_PACKAGE_OPENSSL
5298 select BR2_PACKAGE_POPT
5299 help
5300 @@ -15,6 +16,6 @@ config BR2_PACKAGE_KEEPALIVED
5302 http://www.keepalived.org/
5304 -comment "keepalived needs a toolchain w/ dynamic library"
5305 +comment "keepalived needs a toolchain w/ dynamic library, headers >= 3.4"
5306 depends on BR2_USE_MMU
5307 - depends on BR2_STATIC_LIBS
5308 + depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_4
5309 diff -Naurp buildroot-2017.05-rc2/package/kmod/0002-shared-util.c-assert_cc-can-only-be-used-inside-func.patch buildroot-2017.05.2/package/kmod/0002-shared-util.c-assert_cc-can-only-be-used-inside-func.patch
5310 --- buildroot-2017.05-rc2/package/kmod/0002-shared-util.c-assert_cc-can-only-be-used-inside-func.patch 1970-01-01 01:00:00.000000000 +0100
5311 +++ buildroot-2017.05.2/package/kmod/0002-shared-util.c-assert_cc-can-only-be-used-inside-func.patch 2017-07-27 08:16:52.017486944 +0200
5312 @@ -0,0 +1,56 @@
5313 +From 7cd698eb31059012305d8bb7516577c8cd383e32 Mon Sep 17 00:00:00 2001
5314 +From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5315 +Date: Sat, 3 Jun 2017 16:52:37 +0200
5316 +Subject: [PATCH] shared/util.c: assert_cc() can only be used inside functions
5318 +shared/macro.h has two versions of assert_cc, one that uses gcc
5319 +_Static_assert(), which requires recent enough gcc versions, and one
5320 +that uses a fake array to trigger a build error. The latter can only
5321 +work inside functions, so assert_cc() should only be used inside
5322 +functions.
5324 +Fixes the following build failure when building kmod with old gcc
5325 +versions such as gcc 4.3.x:
5327 +shared/util.c:52: error: expected identifier or '(' before 'do'
5328 +shared/util.c:52: error: expected identifier or '(' before 'while'
5330 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5331 +---
5332 + shared/util.c | 6 ++++--
5333 + 1 file changed, 4 insertions(+), 2 deletions(-)
5335 +diff --git a/shared/util.c b/shared/util.c
5336 +index 9de080a..fd2028d 100644
5337 +--- a/shared/util.c
5338 ++++ b/shared/util.c
5339 +@@ -49,8 +49,6 @@ static const struct kmod_ext {
5340 + { }
5341 + };
5343 +-assert_cc(EAGAIN == EWOULDBLOCK);
5345 + /* string handling functions and memory allocations */
5346 + /* ************************************************************************ */
5348 +@@ -201,6 +199,8 @@ ssize_t read_str_safe(int fd, char *buf, size_t buflen)
5349 + size_t todo = buflen - 1;
5350 + size_t done = 0;
5352 ++ assert_cc(EAGAIN == EWOULDBLOCK);
5354 + do {
5355 + ssize_t r = read(fd, buf + done, todo);
5357 +@@ -226,6 +226,8 @@ ssize_t write_str_safe(int fd, const char *buf, size_t buflen)
5358 + size_t todo = buflen;
5359 + size_t done = 0;
5361 ++ assert_cc(EAGAIN == EWOULDBLOCK);
5363 + do {
5364 + ssize_t r = write(fd, buf + done, todo);
5366 +--
5367 +2.7.4
5369 diff -Naurp buildroot-2017.05-rc2/package/kodi/kodi.hash buildroot-2017.05.2/package/kodi/kodi.hash
5370 --- buildroot-2017.05-rc2/package/kodi/kodi.hash 2017-05-17 10:27:16.013401440 +0200
5371 +++ buildroot-2017.05.2/package/kodi/kodi.hash 2017-07-27 08:16:52.017486944 +0200
5372 @@ -1,5 +1,5 @@
5373 # Locally computed
5374 -sha256 303f3903cbb57ccc2961f09cf3746505542bcb129a464f0687d7ca8601cebbee kodi-17.1-Krypton.tar.gz
5375 +sha256 1de8653a3729cefd1baaf09ecde5ace01a1e3a58fbf29d48c1363f2503d331a1 kodi-17.3-Krypton.tar.gz
5376 # Locally computed - libdvdcss
5377 sha256 b6eb2d929ff56cb051152c32010afc5e7cf5fe8c5ae32dca412a2b46b6b57e34 2f12236.tar.gz
5378 # Locally computed - libdvdnav
5379 diff -Naurp buildroot-2017.05-rc2/package/kodi/kodi.mk buildroot-2017.05.2/package/kodi/kodi.mk
5380 --- buildroot-2017.05-rc2/package/kodi/kodi.mk 2017-05-17 10:27:16.013401440 +0200
5381 +++ buildroot-2017.05.2/package/kodi/kodi.mk 2017-07-27 08:16:52.017486944 +0200
5382 @@ -6,7 +6,7 @@
5384 # When updating the version, please also update kodi-jsonschemabuilder
5385 # and kodi-texturepacker
5386 -KODI_VERSION = 17.1-Krypton
5387 +KODI_VERSION = 17.3-Krypton
5388 KODI_SITE = $(call github,xbmc,xbmc,$(KODI_VERSION))
5389 KODI_LICENSE = GPL-2.0
5390 KODI_LICENSE_FILES = LICENSE.GPL
5391 diff -Naurp buildroot-2017.05-rc2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.hash buildroot-2017.05.2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.hash
5392 --- buildroot-2017.05-rc2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.hash 2017-05-17 10:27:16.013401440 +0200
5393 +++ buildroot-2017.05.2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.hash 2017-07-27 08:16:52.017486944 +0200
5394 @@ -1,5 +1,5 @@
5395 # Locally computed
5396 -sha256 303f3903cbb57ccc2961f09cf3746505542bcb129a464f0687d7ca8601cebbee kodi-17.1-Krypton.tar.gz
5397 +sha256 1de8653a3729cefd1baaf09ecde5ace01a1e3a58fbf29d48c1363f2503d331a1 kodi-17.3-Krypton.tar.gz
5398 # Locally computed - libdvdcss
5399 sha256 b6eb2d929ff56cb051152c32010afc5e7cf5fe8c5ae32dca412a2b46b6b57e34 2f12236.tar.gz
5400 # Locally computed - libdvdnav
5401 diff -Naurp buildroot-2017.05-rc2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk buildroot-2017.05.2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk
5402 --- buildroot-2017.05-rc2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk 2017-05-17 10:27:16.013401440 +0200
5403 +++ buildroot-2017.05.2/package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk 2017-07-27 08:16:52.017486944 +0200
5404 @@ -6,7 +6,7 @@
5406 # Not possible to directly refer to kodi variables, because of
5407 # first/second expansion trickery...
5408 -KODI_JSONSCHEMABUILDER_VERSION = 17.1-Krypton
5409 +KODI_JSONSCHEMABUILDER_VERSION = 17.3-Krypton
5410 KODI_JSONSCHEMABUILDER_SITE = $(call github,xbmc,xbmc,$(KODI_JSONSCHEMABUILDER_VERSION))
5411 KODI_JSONSCHEMABUILDER_SOURCE = kodi-$(KODI_JSONSCHEMABUILDER_VERSION).tar.gz
5412 KODI_JSONSCHEMABUILDER_LICENSE = GPL-2.0
5413 diff -Naurp buildroot-2017.05-rc2/package/kodi-texturepacker/kodi-texturepacker.hash buildroot-2017.05.2/package/kodi-texturepacker/kodi-texturepacker.hash
5414 --- buildroot-2017.05-rc2/package/kodi-texturepacker/kodi-texturepacker.hash 2017-05-17 10:27:16.013401440 +0200
5415 +++ buildroot-2017.05.2/package/kodi-texturepacker/kodi-texturepacker.hash 2017-07-27 08:16:52.017486944 +0200
5416 @@ -1,5 +1,5 @@
5417 # Locally computed
5418 -sha256 303f3903cbb57ccc2961f09cf3746505542bcb129a464f0687d7ca8601cebbee kodi-17.1-Krypton.tar.gz
5419 +sha256 1de8653a3729cefd1baaf09ecde5ace01a1e3a58fbf29d48c1363f2503d331a1 kodi-17.3-Krypton.tar.gz
5420 # Locally computed - libdvdcss
5421 sha256 b6eb2d929ff56cb051152c32010afc5e7cf5fe8c5ae32dca412a2b46b6b57e34 2f12236.tar.gz
5422 # Locally computed - libdvdnav
5423 diff -Naurp buildroot-2017.05-rc2/package/kodi-texturepacker/kodi-texturepacker.mk buildroot-2017.05.2/package/kodi-texturepacker/kodi-texturepacker.mk
5424 --- buildroot-2017.05-rc2/package/kodi-texturepacker/kodi-texturepacker.mk 2017-05-17 10:27:16.013401440 +0200
5425 +++ buildroot-2017.05.2/package/kodi-texturepacker/kodi-texturepacker.mk 2017-07-27 08:16:52.017486944 +0200
5426 @@ -6,7 +6,7 @@
5428 # Not possible to directly refer to kodi variables, because of
5429 # first/second expansion trickery...
5430 -KODI_TEXTUREPACKER_VERSION = 17.1-Krypton
5431 +KODI_TEXTUREPACKER_VERSION = 17.3-Krypton
5432 KODI_TEXTUREPACKER_SITE = $(call github,xbmc,xbmc,$(KODI_TEXTUREPACKER_VERSION))
5433 KODI_TEXTUREPACKER_SOURCE = kodi-$(KODI_TEXTUREPACKER_VERSION).tar.gz
5434 KODI_TEXTUREPACKER_LICENSE = GPL-2.0
5435 diff -Naurp buildroot-2017.05-rc2/package/libcdio/Config.in buildroot-2017.05.2/package/libcdio/Config.in
5436 --- buildroot-2017.05-rc2/package/libcdio/Config.in 2017-05-17 10:27:16.013401440 +0200
5437 +++ buildroot-2017.05.2/package/libcdio/Config.in 2017-07-27 08:16:52.017486944 +0200
5438 @@ -1,8 +1,6 @@
5439 config BR2_PACKAGE_LIBCDIO
5440 bool "libcdio"
5441 depends on BR2_USE_MMU # fork()
5442 - # ARC toolchain issue
5443 - depends on !BR2_arc
5444 select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
5445 help
5446 The GNU Compact Disc Input and Control library.
5447 diff -Naurp buildroot-2017.05-rc2/package/libcurl/libcurl.mk buildroot-2017.05.2/package/libcurl/libcurl.mk
5448 --- buildroot-2017.05-rc2/package/libcurl/libcurl.mk 2017-05-17 10:27:16.013401440 +0200
5449 +++ buildroot-2017.05.2/package/libcurl/libcurl.mk 2017-07-27 08:16:52.017486944 +0200
5450 @@ -11,7 +11,7 @@ LIBCURL_DEPENDENCIES = host-pkgconf \
5451 $(if $(BR2_PACKAGE_ZLIB),zlib) \
5452 $(if $(BR2_PACKAGE_LIBIDN),libidn) \
5453 $(if $(BR2_PACKAGE_RTMPDUMP),rtmpdump)
5454 -LIBCURL_LICENSE = ISC
5455 +LIBCURL_LICENSE = curl
5456 LIBCURL_LICENSE_FILES = COPYING
5457 LIBCURL_INSTALL_STAGING = YES
5459 diff -Naurp buildroot-2017.05-rc2/package/libepoxy/0002-Make-EGL-support-optional.patch buildroot-2017.05.2/package/libepoxy/0002-Make-EGL-support-optional.patch
5460 --- buildroot-2017.05-rc2/package/libepoxy/0002-Make-EGL-support-optional.patch 1970-01-01 01:00:00.000000000 +0100
5461 +++ buildroot-2017.05.2/package/libepoxy/0002-Make-EGL-support-optional.patch 2017-07-27 08:16:52.017486944 +0200
5462 @@ -0,0 +1,200 @@
5463 +From 0511fc56e7017209ad18d16551ccaad05de9486c Mon Sep 17 00:00:00 2001
5464 +From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5465 +Date: Mon, 8 May 2017 23:12:49 +0200
5466 +Subject: [PATCH] Make EGL support optional
5468 +It is perfectly possible to build Mesa3D with just OpenGL support, and
5469 +use with GLX in X.org, without having EGL/OpenGLES support.
5471 +However, libepoxy currently unconditionally requires EGL support in its
5472 +configure.ac, which causes a build failure when Mesa3D only provides
5473 +full OpenGL support:
5475 +checking for EGL... no
5476 +configure: error: Package requirements (egl) were not met:
5478 +Package egl was not found in the pkg-config search path.
5479 +Perhaps you should add the directory containing `egl.pc'
5480 +to the PKG_CONFIG_PATH environment variable
5481 +Package 'egl', required by 'world', not found
5483 +This commit fixes that by:
5485 + - Adjusting the configure.ac to add a --{enable,disable}-egl option
5486 + handled in the exact same way as --{enable,disable}-glx
5488 + - Adjusting the meson build logic in the same way.
5490 + - Adjusting src/dispatch_common.h to define PLATFORM_HAS_EGL correctly,
5491 + which allows to not include any EGL related header file if EGL
5492 + support is not enabled.
5494 +Submitted-upstream: https://github.com/anholt/libepoxy/pull/123
5495 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5496 +---
5497 + configure.ac | 33 ++++++++++++++++++++++++++++-----
5498 + meson.build | 21 ++++++++++++++++++---
5499 + meson_options.txt | 5 +++++
5500 + src/dispatch_common.h | 8 ++++----
5501 + 4 files changed, 55 insertions(+), 12 deletions(-)
5503 +diff --git a/configure.ac b/configure.ac
5504 +index 31b0985..2dbecd9 100644
5505 +--- a/configure.ac
5506 ++++ b/configure.ac
5507 +@@ -88,11 +88,35 @@ AS_CASE([$enable_glx],
5508 + [AC_MSG_ERROR([Invalid value "$enable_glx" for option "--enable-glx"])]
5509 + ])
5511 +-# The remaining platform specific API for GL/GLES are enabled
5512 +-# depending on the platform we're building for
5513 ++AC_ARG_ENABLE([egl],
5514 ++ [AC_HELP_STRING([--enable-egl=@<:@auto,yes,no@:>@], [Enable EGL support @<:@default=auto@:>@])],
5515 ++ [enable_egl=$enableval],
5516 ++ [enable_egl=auto])
5518 ++AS_CASE([$enable_egl],
5519 ++ [auto], [
5520 ++ AS_CASE([$host_os],
5521 ++ [mingw*], [build_egl=no],
5522 ++ [darwin*], [build_egl=no],
5523 ++ [android*], [build_egl=no],
5524 ++ [build_egl=yes])
5525 ++ ],
5527 ++ [yes], [
5528 ++ build_egl=yes
5529 ++ ],
5531 ++ [no], [
5532 ++ build_egl=no
5533 ++ ],
5535 ++ [AC_MSG_ERROR([Invalid value "$enable_egl" for option "--enable-egl"])]
5536 ++])
5538 ++# The remaining platform specific API are enabled depending on the
5539 ++# platform we're building for
5540 + AS_CASE([$host_os],
5541 + [mingw*], [
5542 +- build_egl=no
5543 + build_wgl=yes
5544 + has_znow=yes
5545 + # On windows, the DLL has to have all of its functions
5546 +@@ -108,7 +132,6 @@ AS_CASE([$host_os],
5547 + ],
5549 + [darwin*], [
5550 +- build_egl=no
5551 + build_wgl=no
5552 + build_apple=yes
5553 + has_znow=no
5554 +@@ -116,7 +139,6 @@ AS_CASE([$host_os],
5555 + ],
5558 +- build_egl=yes
5559 + build_wgl=no
5560 + has_znow=yes
5561 + # On platforms with dlopen, we load everything dynamically and
5562 +@@ -131,6 +153,7 @@ AM_CONDITIONAL(BUILD_EGL, test x$build_egl = xyes)
5563 + if test x$build_egl = xyes; then
5564 + PKG_CHECK_MODULES(EGL, [egl])
5565 + AC_DEFINE([BUILD_EGL], [1], [build EGL tests])
5566 ++ AC_DEFINE(ENABLE_EGL, [1], [Whether EGL support is enabled])
5567 + fi
5569 + AM_CONDITIONAL(BUILD_GLX, test x$build_glx = xyes)
5570 +diff --git a/meson.build b/meson.build
5571 +index 5435f45..226152e 100644
5572 +--- a/meson.build
5573 ++++ b/meson.build
5574 +@@ -51,26 +51,41 @@ elif enable_glx == 'no'
5575 + build_glx = false
5576 + endif
5578 ++enable_egl = get_option('enable-egl')
5579 ++if enable_egl == 'auto'
5580 ++ if host_system == 'windows'
5581 ++ build_egl = false
5582 ++ elif host_system == 'darwin'
5583 ++ build_egl = false
5584 ++ elif host_system == 'android'
5585 ++ build_egl = false
5586 ++ else
5587 ++ build_egl = true
5588 ++ endif
5589 ++elif enable_egl == 'yes'
5590 ++ build_egl = true
5591 ++elif enable_egl == 'no'
5592 ++ build_egl = false
5593 ++endif
5595 + # The remaining platform specific API for GL/GLES are enabled
5596 + # depending on the platform we're building for
5597 + if host_system == 'windows'
5598 +- build_egl = false
5599 + build_apple = false
5600 + build_wgl = true
5601 + has_znow = true
5602 + elif host_system == 'darwin'
5603 +- build_egl = false
5604 + build_apple = true
5605 + build_wgl = false
5606 + has_znow = false
5607 + else
5608 +- build_egl = true
5609 + build_apple = false
5610 + build_wgl = false
5611 + has_znow = true
5612 + endif
5614 + conf.set10('ENABLE_GLX', build_glx)
5615 ++conf.set10('ENABLE_EGL', build_egl)
5617 + # Compiler flags, taken from the Xorg macros
5618 + if cc.get_id() == 'msvc'
5619 +diff --git a/meson_options.txt b/meson_options.txt
5620 +index 18932f5..244476a 100644
5621 +--- a/meson_options.txt
5622 ++++ b/meson_options.txt
5623 +@@ -6,3 +6,8 @@ option('enable-glx',
5624 + choices: [ 'auto', 'yes', 'no' ],
5625 + value: 'auto',
5626 + description: 'Enable GLX support')
5627 ++option('enable-egl',
5628 ++ type: 'combo',
5629 ++ choices: [ 'auto', 'yes', 'no' ],
5630 ++ value: 'auto',
5631 ++ description: 'Enable EGL support')
5632 +diff --git a/src/dispatch_common.h b/src/dispatch_common.h
5633 +index e3277f7..e16771f 100644
5634 +--- a/src/dispatch_common.h
5635 ++++ b/src/dispatch_common.h
5636 +@@ -24,19 +24,19 @@
5637 + #include "config.h"
5639 + #ifdef _WIN32
5640 +-#define PLATFORM_HAS_EGL 0
5641 ++#define PLATFORM_HAS_EGL ENABLE_EGL
5642 + #define PLATFORM_HAS_GLX ENABLE_GLX
5643 + #define PLATFORM_HAS_WGL 1
5644 + #elif defined(__APPLE__)
5645 +-#define PLATFORM_HAS_EGL 0
5646 ++#define PLATFORM_HAS_EGL ENABLE_EGL
5647 + #define PLATFORM_HAS_GLX ENABLE_GLX
5648 + #define PLATFORM_HAS_WGL 0
5649 + #elif defined(ANDROID)
5650 +-#define PLATFORM_HAS_EGL 1
5651 ++#define PLATFORM_HAS_EGL ENABLE_EGL
5652 + #define PLATFORM_HAS_GLX 0
5653 + #define PLATFORM_HAS_WGL 0
5654 + #else
5655 +-#define PLATFORM_HAS_EGL 1
5656 ++#define PLATFORM_HAS_EGL ENABLE_EGL
5657 + #define PLATFORM_HAS_GLX ENABLE_GLX
5658 + #define PLATFORM_HAS_WGL 0
5659 + #endif
5660 +--
5661 +2.7.4
5663 diff -Naurp buildroot-2017.05-rc2/package/libepoxy/libepoxy.mk buildroot-2017.05.2/package/libepoxy/libepoxy.mk
5664 --- buildroot-2017.05-rc2/package/libepoxy/libepoxy.mk 2017-05-17 10:27:16.013401440 +0200
5665 +++ buildroot-2017.05.2/package/libepoxy/libepoxy.mk 2017-07-27 08:16:52.017486944 +0200
5666 @@ -12,6 +12,8 @@ LIBEPOXY_INSTALL_STAGING = YES
5667 LIBEPOXY_DEPENDENCIES = host-pkgconf xutil_util-macros
5668 LIBEPOXY_LICENSE = MIT
5669 LIBEPOXY_LICENSE_FILES = COPYING
5670 +# 0002-Make-EGL-support-optional.patch
5671 +LIBEPOXY_AUTORECONF = YES
5673 ifeq ($(BR2_PACKAGE_HAS_LIBEGL),y)
5674 LIBEPOXY_CONF_OPTS += --enable-egl
5675 diff -Naurp buildroot-2017.05-rc2/package/libev/libev.mk buildroot-2017.05.2/package/libev/libev.mk
5676 --- buildroot-2017.05-rc2/package/libev/libev.mk 2017-05-17 10:27:16.013401440 +0200
5677 +++ buildroot-2017.05.2/package/libev/libev.mk 2017-07-27 08:16:52.017486944 +0200
5678 @@ -5,7 +5,7 @@
5679 ################################################################################
5681 LIBEV_VERSION = 4.22
5682 -LIBEV_SITE = http://dist.schmorp.de/libev
5683 +LIBEV_SITE = http://dist.schmorp.de/libev/Attic
5684 LIBEV_INSTALL_STAGING = YES
5685 LIBEV_LICENSE = BSD-2-Clause or GPL-2.0+
5686 LIBEV_LICENSE_FILES = LICENSE
5687 diff -Naurp buildroot-2017.05-rc2/package/libgcrypt/libgcrypt.hash buildroot-2017.05.2/package/libgcrypt/libgcrypt.hash
5688 --- buildroot-2017.05-rc2/package/libgcrypt/libgcrypt.hash 2017-05-17 10:27:16.013401440 +0200
5689 +++ buildroot-2017.05.2/package/libgcrypt/libgcrypt.hash 2017-07-27 08:16:52.017486944 +0200
5690 @@ -1,2 +1,5 @@
5691 -# Locally calculated
5692 -sha256 626aafee84af9d2ce253d2c143dc1c0902dda045780cc241f39970fc60be05bc libgcrypt-1.7.6.tar.bz2
5693 +# From https://lists.gnupg.org/pipermail/gnupg-announce/2017q2/000408.html
5694 +sha1 65a4a495aa858483e66868199eaa8238572ca6cd libgcrypt-1.7.8.tar.bz2
5695 +# Locally calculated after checking signature
5696 +# https://gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.7.8.tar.bz2.sig
5697 +sha256 948276ea47e6ba0244f36a17b51dcdd52cfd1e664b0a1ac3bc82134fb6cec199 libgcrypt-1.7.8.tar.bz2
5698 diff -Naurp buildroot-2017.05-rc2/package/libgcrypt/libgcrypt.mk buildroot-2017.05.2/package/libgcrypt/libgcrypt.mk
5699 --- buildroot-2017.05-rc2/package/libgcrypt/libgcrypt.mk 2017-05-17 10:27:16.013401440 +0200
5700 +++ buildroot-2017.05.2/package/libgcrypt/libgcrypt.mk 2017-07-27 08:16:52.017486944 +0200
5701 @@ -4,11 +4,11 @@
5703 ################################################################################
5705 -LIBGCRYPT_VERSION = 1.7.6
5706 +LIBGCRYPT_VERSION = 1.7.8
5707 LIBGCRYPT_SOURCE = libgcrypt-$(LIBGCRYPT_VERSION).tar.bz2
5708 LIBGCRYPT_LICENSE = LGPL-2.1+
5709 LIBGCRYPT_LICENSE_FILES = COPYING.LIB
5710 -LIBGCRYPT_SITE = ftp://ftp.gnupg.org/gcrypt/libgcrypt
5711 +LIBGCRYPT_SITE = https://gnupg.org/ftp/gcrypt/libgcrypt
5712 LIBGCRYPT_INSTALL_STAGING = YES
5713 LIBGCRYPT_DEPENDENCIES = libgpg-error
5714 LIBGCRYPT_CONFIG_SCRIPTS = libgcrypt-config
5715 diff -Naurp buildroot-2017.05-rc2/package/libglib2/libglib2.mk buildroot-2017.05.2/package/libglib2/libglib2.mk
5716 --- buildroot-2017.05-rc2/package/libglib2/libglib2.mk 2017-05-17 10:27:16.013401440 +0200
5717 +++ buildroot-2017.05.2/package/libglib2/libglib2.mk 2017-07-27 08:16:52.017486944 +0200
5718 @@ -113,7 +113,8 @@ HOST_LIBGLIB2_DEPENDENCIES = \
5719 host-zlib
5721 LIBGLIB2_CONF_OPTS = \
5722 - --with-pcre=system
5723 + --with-pcre=system \
5724 + --disable-compile-warnings
5726 ifneq ($(BR2_ENABLE_LOCALE),y)
5727 LIBGLIB2_DEPENDENCIES += libiconv
5728 diff -Naurp buildroot-2017.05-rc2/package/libmad/libmad.hash buildroot-2017.05.2/package/libmad/libmad.hash
5729 --- buildroot-2017.05-rc2/package/libmad/libmad.hash 2017-05-17 10:27:16.013401440 +0200
5730 +++ buildroot-2017.05.2/package/libmad/libmad.hash 2017-07-27 08:16:52.017486944 +0200
5731 @@ -1,2 +1,3 @@
5732 # Locally computed:
5733 sha256 bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690 libmad-0.15.1b.tar.gz
5734 +sha256 0e21f2c6b19337d0b237dacc04f7b90a56be7f359f4c9a2ee0b202d9af0cfa69 frame_length.diff
5735 diff -Naurp buildroot-2017.05-rc2/package/libmad/libmad.mk buildroot-2017.05.2/package/libmad/libmad.mk
5736 --- buildroot-2017.05-rc2/package/libmad/libmad.mk 2017-05-17 10:27:16.013401440 +0200
5737 +++ buildroot-2017.05.2/package/libmad/libmad.mk 2017-07-27 08:16:52.017486944 +0200
5738 @@ -10,6 +10,8 @@ LIBMAD_INSTALL_STAGING = YES
5739 LIBMAD_LIBTOOL_PATCH = NO
5740 LIBMAD_LICENSE = GPL-2.0+
5741 LIBMAD_LICENSE_FILES = COPYING
5742 +LIBMAD_PATCH = \
5743 + https://sources.debian.net/data/main/libm/libmad/0.15.1b-8/debian/patches/frame_length.diff
5745 define LIBMAD_PREVENT_AUTOMAKE
5746 # Prevent automake from running.
5747 diff -Naurp buildroot-2017.05-rc2/package/libmemcached/0005-fix-pointer-comparaison.patch buildroot-2017.05.2/package/libmemcached/0005-fix-pointer-comparaison.patch
5748 --- buildroot-2017.05-rc2/package/libmemcached/0005-fix-pointer-comparaison.patch 1970-01-01 01:00:00.000000000 +0100
5749 +++ buildroot-2017.05.2/package/libmemcached/0005-fix-pointer-comparaison.patch 2017-07-27 08:16:52.017486944 +0200
5750 @@ -0,0 +1,30 @@
5751 +Fix pointer comparaison
5753 +opt_servers is a pointer, not a boolean, so testing against false to
5754 +know if the pointer is NULL no longer works with the more strict gcc
5755 +7.x checks.
5757 +[Taken from http://pkgs.fedoraproject.org/cgit/rpms/libmemcached.git/plain/libmemcached-build.patch.]
5758 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5760 +diff -up ./clients/memflush.cc.old ./clients/memflush.cc
5761 +--- ./clients/memflush.cc.old 2017-02-12 10:12:59.615209225 +0100
5762 ++++ ./clients/memflush.cc 2017-02-12 10:13:39.998382783 +0100
5763 +@@ -39,7 +39,7 @@ int main(int argc, char *argv[])
5765 + options_parse(argc, argv);
5767 +- if (opt_servers == false)
5768 ++ if (!opt_servers)
5770 + char *temp;
5772 +@@ -48,7 +48,7 @@ int main(int argc, char *argv[])
5773 + opt_servers= strdup(temp);
5776 +- if (opt_servers == false)
5777 ++ if (!opt_servers)
5779 + std::cerr << "No Servers provided" << std::endl;
5780 + exit(EXIT_FAILURE);
5781 diff -Naurp buildroot-2017.05-rc2/package/libmicrohttpd/Config.in buildroot-2017.05.2/package/libmicrohttpd/Config.in
5782 --- buildroot-2017.05-rc2/package/libmicrohttpd/Config.in 2017-05-17 10:27:16.013401440 +0200
5783 +++ buildroot-2017.05.2/package/libmicrohttpd/Config.in 2017-07-27 08:16:52.017486944 +0200
5784 @@ -12,14 +12,15 @@ if BR2_PACKAGE_LIBMICROHTTPD
5785 config BR2_PACKAGE_LIBMICROHTTPD_SSL
5786 bool "https support"
5787 depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt
5788 + depends on !BR2_STATIC_LIBS # gnutls
5789 depends on BR2_USE_WCHAR
5790 select BR2_PACKAGE_GNUTLS
5791 select BR2_PACKAGE_LIBGCRYPT
5792 help
5793 Enable HTTPS (SSL) support.
5795 -comment "libmicrohttpd https support needs a toolchain w/ wchar"
5796 - depends on !BR2_USE_WCHAR
5797 +comment "libmicrohttpd https support needs a toolchain w/ wchar, dynamic library"
5798 + depends on !BR2_USE_WCHAR || BR2_STATIC_LIBS
5800 endif
5802 diff -Naurp buildroot-2017.05-rc2/package/libmicrohttpd/libmicrohttpd.hash buildroot-2017.05.2/package/libmicrohttpd/libmicrohttpd.hash
5803 --- buildroot-2017.05-rc2/package/libmicrohttpd/libmicrohttpd.hash 2017-05-17 10:27:16.013401440 +0200
5804 +++ buildroot-2017.05.2/package/libmicrohttpd/libmicrohttpd.hash 2017-07-27 08:16:52.017486944 +0200
5805 @@ -1,2 +1,2 @@
5806 # Locally calculated
5807 -sha256 54797f6e763d417627f89f60e4ae0a431dab0523f92f83def23ea02d0defafea libmicrohttpd-0.9.52.tar.gz
5808 +sha256 0c1cab8dc9f2588bd3076a28f77a7f8de9560cbf2d80e53f9a8696ada80ed0f8 libmicrohttpd-0.9.55.tar.gz
5809 diff -Naurp buildroot-2017.05-rc2/package/libmicrohttpd/libmicrohttpd.mk buildroot-2017.05.2/package/libmicrohttpd/libmicrohttpd.mk
5810 --- buildroot-2017.05-rc2/package/libmicrohttpd/libmicrohttpd.mk 2017-05-17 10:27:16.013401440 +0200
5811 +++ buildroot-2017.05.2/package/libmicrohttpd/libmicrohttpd.mk 2017-07-27 08:16:52.017486944 +0200
5812 @@ -4,7 +4,7 @@
5814 ################################################################################
5816 -LIBMICROHTTPD_VERSION = 0.9.52
5817 +LIBMICROHTTPD_VERSION = 0.9.55
5818 LIBMICROHTTPD_SITE = $(BR2_GNU_MIRROR)/libmicrohttpd
5819 LIBMICROHTTPD_LICENSE_FILES = COPYING
5820 LIBMICROHTTPD_INSTALL_STAGING = YES
5821 diff -Naurp buildroot-2017.05-rc2/package/libminiupnpc/0001-miniupnpc-Fix-CVE-2017-8798.patch buildroot-2017.05.2/package/libminiupnpc/0001-miniupnpc-Fix-CVE-2017-8798.patch
5822 --- buildroot-2017.05-rc2/package/libminiupnpc/0001-miniupnpc-Fix-CVE-2017-8798.patch 1970-01-01 01:00:00.000000000 +0100
5823 +++ buildroot-2017.05.2/package/libminiupnpc/0001-miniupnpc-Fix-CVE-2017-8798.patch 2017-07-27 08:16:52.017486944 +0200
5824 @@ -0,0 +1,59 @@
5825 +From f0f1f4b22d6a98536377a1bb07e7c20e4703d229 Mon Sep 17 00:00:00 2001
5826 +From: Thomas Bernard <miniupnp@free.fr>
5827 +Date: Tue, 9 May 2017 12:00:47 +0200
5828 +Subject: [PATCH] miniupnpc: Fix CVE-2017-8798
5830 +Thanks to tin/Team OSTStrom
5832 +[Peter: drop Changelog.txt modification, convert to -p1 format]
5833 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
5834 +---
5835 + miniupnpc/miniwget.c | 12 +++++++-----
5836 + 1 file changed, 9 insertions(+), 5 deletions(-)
5838 +diff --git a/miniwget.c b/miniwget.c
5839 +index 37cb47b7..1eda57c5 100644
5840 +--- a/miniwget.c
5841 ++++ b/miniwget.c
5842 +@@ -284,11 +284,12 @@ getHTTPResponse(int s, int * size, int * status_code)
5843 + goto end_of_stream;
5846 +- bytestocopy = ((int)chunksize < (n - i))?chunksize:(unsigned int)(n - i);
5847 ++ /* it is guaranteed that (n >= i) */
5848 ++ bytestocopy = (chunksize < (unsigned int)(n - i))?chunksize:(unsigned int)(n - i);
5849 + if((content_buf_used + bytestocopy) > content_buf_len)
5851 + char * tmp;
5852 +- if(content_length >= (int)(content_buf_used + bytestocopy)) {
5853 ++ if((content_length >= 0) && ((unsigned int)content_length >= (content_buf_used + bytestocopy))) {
5854 + content_buf_len = content_length;
5855 + } else {
5856 + content_buf_len = content_buf_used + bytestocopy;
5857 +@@ -313,14 +314,15 @@ getHTTPResponse(int s, int * size, int * status_code)
5859 + /* not chunked */
5860 + if(content_length > 0
5861 +- && (int)(content_buf_used + n) > content_length) {
5862 ++ && (content_buf_used + n) > (unsigned int)content_length) {
5863 + /* skipping additional bytes */
5864 + n = content_length - content_buf_used;
5866 + if(content_buf_used + n > content_buf_len)
5868 + char * tmp;
5869 +- if(content_length >= (int)(content_buf_used + n)) {
5870 ++ if(content_length >= 0
5871 ++ && (unsigned int)content_length >= (content_buf_used + n)) {
5872 + content_buf_len = content_length;
5873 + } else {
5874 + content_buf_len = content_buf_used + n;
5875 +@@ -340,7 +342,7 @@ getHTTPResponse(int s, int * size, int * status_code)
5878 + /* use the Content-Length header value if available */
5879 +- if(content_length > 0 && (int)content_buf_used >= content_length)
5880 ++ if(content_length > 0 && content_buf_used >= (unsigned int)content_length)
5882 + #ifdef DEBUG
5883 + printf("End of HTTP content\n");
5884 diff -Naurp buildroot-2017.05-rc2/package/libosip2/0001-fix-bug-report-sr-109133-Heap-buffer-overflow-in-uti.patch buildroot-2017.05.2/package/libosip2/0001-fix-bug-report-sr-109133-Heap-buffer-overflow-in-uti.patch
5885 --- buildroot-2017.05-rc2/package/libosip2/0001-fix-bug-report-sr-109133-Heap-buffer-overflow-in-uti.patch 1970-01-01 01:00:00.000000000 +0100
5886 +++ buildroot-2017.05.2/package/libosip2/0001-fix-bug-report-sr-109133-Heap-buffer-overflow-in-uti.patch 2017-07-27 08:16:52.017486944 +0200
5887 @@ -0,0 +1,30 @@
5888 +From 7e0793e15e21f68337e130c67b031ca38edf055f Mon Sep 17 00:00:00 2001
5889 +From: Aymeric Moizard <amoizard@gmail.com>
5890 +Date: Mon, 5 Sep 2016 15:01:53 +0200
5891 +Subject: [PATCH] * fix bug report: sr #109133: Heap buffer overflow in
5892 + utility function *osip_clrncpy* https://savannah.gnu.org/support/?109133
5894 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
5895 +---
5896 + src/osipparser2/osip_port.c | 4 +++-
5897 + 1 file changed, 3 insertions(+), 1 deletion(-)
5899 +diff --git a/src/osipparser2/osip_port.c b/src/osipparser2/osip_port.c
5900 +index 0e64147..d8941b0 100644
5901 +--- a/src/osipparser2/osip_port.c
5902 ++++ b/src/osipparser2/osip_port.c
5903 +@@ -1291,8 +1291,10 @@ osip_clrncpy (char *dst, const char *src, size_t len)
5904 + char *p;
5905 + size_t spaceless_length;
5907 +- if (src == NULL)
5908 ++ if (src == NULL || len == 0) {
5909 ++ *dst = '\0';
5910 + return NULL;
5911 ++ }
5913 + /* find the start of relevant text */
5914 + pbeg = src;
5915 +--
5916 +2.11.0
5918 diff -Naurp buildroot-2017.05-rc2/package/libqmi/0001-musl-compat-canonicalize_file_name.patch buildroot-2017.05.2/package/libqmi/0001-musl-compat-canonicalize_file_name.patch
5919 --- buildroot-2017.05-rc2/package/libqmi/0001-musl-compat-canonicalize_file_name.patch 2017-05-17 10:27:16.013401440 +0200
5920 +++ buildroot-2017.05.2/package/libqmi/0001-musl-compat-canonicalize_file_name.patch 2017-07-27 08:16:52.017486944 +0200
5921 @@ -1,22 +1,24 @@
5922 -From 85863c9e051fe59add4e47dbfcb37072234f0110 Mon Sep 17 00:00:00 2001
5923 +From 8f6181b6f8dd82aa1ab1288cc7f2fd05d4a2519f Mon Sep 17 00:00:00 2001
5924 From: Matt Weber <matthew.weber@rockwellcollins.com>
5925 Date: Mon, 1 May 2017 19:55:07 -0500
5926 Subject: [PATCH] musl compat canonicalize_file_name()
5928 -Adds an inline equivalent of canonicalize_file_name
5929 +Adds an equivalent of canonicalize_file_name
5930 using realpath().
5932 Bug report (origin of this patch):
5933 https://bugs.freedesktop.org/show_bug.cgi?id=99944
5935 +Bug report has been updated with suggestion to not use inline.
5937 Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
5939 configure.ac | 2 ++
5940 - src/libqmi-glib/qmi-utils.h | 18 ++++++++++++++++++
5941 - 2 files changed, 20 insertions(+)
5942 + src/libqmi-glib/qmi-utils.c | 15 +++++++++++++++
5943 + 2 files changed, 17 insertions(+)
5945 diff --git a/configure.ac b/configure.ac
5946 -index 162d5ae..9cb82fd 100644
5947 +index c56fa3e..d835db4 100644
5948 --- a/configure.ac
5949 +++ b/configure.ac
5950 @@ -80,6 +80,8 @@ AC_SUBST(GLIB_LIBS)
5951 @@ -28,19 +30,16 @@ index 162d5ae..9cb82fd 100644
5952 dnl qmi-firmware-update is optional, enabled by default
5953 AC_ARG_ENABLE([firmware-update],
5954 AS_HELP_STRING([--enable-firmware-update],
5955 -diff --git a/src/libqmi-glib/qmi-utils.h b/src/libqmi-glib/qmi-utils.h
5956 -index 4fd5199..4869da5 100644
5957 ---- a/src/libqmi-glib/qmi-utils.h
5958 -+++ b/src/libqmi-glib/qmi-utils.h
5959 -@@ -29,6 +29,24 @@
5960 - #error "Only <libqmi-glib.h> can be included directly."
5961 - #endif
5962 +diff --git a/src/libqmi-glib/qmi-utils.c b/src/libqmi-glib/qmi-utils.c
5963 +index 29e5f22..26aff9e 100644
5964 +--- a/src/libqmi-glib/qmi-utils.c
5965 ++++ b/src/libqmi-glib/qmi-utils.c
5966 +@@ -34,6 +34,21 @@
5967 + #include "qmi-utils.h"
5968 + #include "qmi-error-types.h"
5970 +#ifndef HAVE_CANONICALIZE_FILE_NAME
5971 +#include <limits.h>
5972 -+#include <string.h>
5973 -+#include <stdlib.h>
5974 -+#include <stdio.h>
5975 +static char * canonicalize_file_name(const char *path)
5977 + char buf[PATH_MAX] = { };
5978 @@ -54,9 +53,9 @@ index 4fd5199..4869da5 100644
5980 +#endif
5982 - #include <glib.h>
5984 - G_BEGIN_DECLS
5985 + /**
5986 + * SECTION:qmi-utils
5987 + * @title: Common utilities
5989 -2.7.4
5990 +1.9.1
5992 diff -Naurp buildroot-2017.05-rc2/package/libsoup/Config.in buildroot-2017.05.2/package/libsoup/Config.in
5993 --- buildroot-2017.05-rc2/package/libsoup/Config.in 2017-05-17 10:27:16.013401440 +0200
5994 +++ buildroot-2017.05.2/package/libsoup/Config.in 2017-07-27 08:16:52.017486944 +0200
5995 @@ -22,11 +22,15 @@ config BR2_PACKAGE_LIBSOUP_GNOME
5997 config BR2_PACKAGE_LIBSOUP_SSL
5998 bool "https support"
5999 + depends on !BR2_STATIC_LIBS # gnutls
6000 select BR2_PACKAGE_GLIB_NETWORKING
6001 select BR2_PACKAGE_GNUTLS
6002 help
6003 Enable HTTPS (SSL) support.
6005 +comment "libsoup https support needs a toolchain w/ dynamic library"
6006 + depends on BR2_STATIC_LIBS
6008 endif
6010 comment "libsoup needs a toolchain w/ wchar, threads"
6011 diff -Naurp buildroot-2017.05-rc2/package/libtasn1/0001-configure-don-t-add-Werror-to-build-flags.patch buildroot-2017.05.2/package/libtasn1/0001-configure-don-t-add-Werror-to-build-flags.patch
6012 --- buildroot-2017.05-rc2/package/libtasn1/0001-configure-don-t-add-Werror-to-build-flags.patch 2017-05-17 10:27:16.013401440 +0200
6013 +++ buildroot-2017.05.2/package/libtasn1/0001-configure-don-t-add-Werror-to-build-flags.patch 1970-01-01 01:00:00.000000000 +0100
6014 @@ -1,28 +0,0 @@
6015 -From dd091c8af163213e12aa92f61bc4916e0f102633 Mon Sep 17 00:00:00 2001
6016 -From: Nikos Mavrogiannopoulos <nmav@redhat.com>
6017 -Date: Tue, 26 Jul 2016 08:45:33 +0200
6018 -Subject: [PATCH] configure: don't add -Werror to build flags
6020 -Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
6021 ----
6022 -Patch status: upstream
6024 - configure.ac | 2 --
6025 - 1 file changed, 2 deletions(-)
6027 -diff --git a/configure.ac b/configure.ac
6028 -index 7a14e04..066f5fe 100644
6029 ---- a/configure.ac
6030 -+++ b/configure.ac
6031 -@@ -70,8 +70,6 @@ AC_ARG_ENABLE([gcc-warnings],
6034 - if test "$gl_gcc_warnings" = yes; then
6035 -- gl_WARN_ADD([-Werror], [WERROR_CFLAGS])
6037 - nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
6038 - nw="$nw -Wc++-compat" # We don't care strongly about C++ compilers
6039 - nw="$nw -Wtraditional" # Warns on #elif which we use often
6040 ---
6041 -2.7.3
6043 diff -Naurp buildroot-2017.05-rc2/package/libtasn1/libtasn1.hash buildroot-2017.05.2/package/libtasn1/libtasn1.hash
6044 --- buildroot-2017.05-rc2/package/libtasn1/libtasn1.hash 2017-05-17 10:27:16.013401440 +0200
6045 +++ buildroot-2017.05.2/package/libtasn1/libtasn1.hash 2017-07-27 08:16:52.017486944 +0200
6046 @@ -1,2 +1,2 @@
6047 # Locally calculated after checking pgp signature
6048 -sha256 4f6f7a8fd691ac2b8307c8ca365bad711db607d4ad5966f6938a9d2ecd65c920 libtasn1-4.9.tar.gz
6049 +sha256 6753da2e621257f33f5b051cc114d417e5206a0818fe0b1ecfd6153f70934753 libtasn1-4.12.tar.gz
6050 diff -Naurp buildroot-2017.05-rc2/package/libtasn1/libtasn1.mk buildroot-2017.05.2/package/libtasn1/libtasn1.mk
6051 --- buildroot-2017.05-rc2/package/libtasn1/libtasn1.mk 2017-05-17 10:27:16.013401440 +0200
6052 +++ buildroot-2017.05.2/package/libtasn1/libtasn1.mk 2017-07-27 08:16:52.017486944 +0200
6053 @@ -4,7 +4,7 @@
6055 ################################################################################
6057 -LIBTASN1_VERSION = 4.9
6058 +LIBTASN1_VERSION = 4.12
6059 LIBTASN1_SITE = $(BR2_GNU_MIRROR)/libtasn1
6060 LIBTASN1_DEPENDENCIES = host-bison
6061 LIBTASN1_LICENSE = GPL-3.0+ (tests, tools), LGPL-2.1+ (library)
6062 @@ -12,7 +12,5 @@ LIBTASN1_LICENSE_FILES = COPYING COPYING
6063 LIBTASN1_INSTALL_STAGING = YES
6064 # 'missing' fallback logic botched so disable it completely
6065 LIBTASN1_CONF_ENV = MAKEINFO="true"
6066 -# For 0001-configure-don-t-add-Werror-to-build-flags.patch
6067 -LIBTASN1_AUTORECONF = YES
6069 $(eval $(autotools-package))
6070 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch buildroot-2017.05.2/package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch
6071 --- buildroot-2017.05-rc2/package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch 2017-05-17 10:27:16.013401440 +0200
6072 +++ buildroot-2017.05.2/package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch 2017-07-27 08:16:52.017486944 +0200
6073 @@ -13,6 +13,8 @@ Signed-off-by: "Yann E. MORIN" <yann.mor
6074 Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
6075 [peda@axentia.se: update for 1.0.1]
6076 Signed-off-by: Peter Rosin <peda@axentia.se>
6077 +[bernd.kuhls@t-online.de: update for 1.0.2]
6078 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
6080 src/Makefile.am | 6 +++---
6081 1 file changed, 3 insertions(+), 3 deletions(-)
6082 @@ -25,8 +27,8 @@ index 6cc567a..9834f9a 100644
6083 rpcb_st_xdr.c svc.c svc_auth.c svc_dg.c svc_auth_unix.c svc_auth_none.c \
6084 svc_auth_des.c \
6085 svc_generic.c svc_raw.c svc_run.c svc_simple.c svc_vc.c getpeereid.c \
6086 -- auth_time.c auth_des.c authdes_prot.c debug.c
6087 -+ auth_des.c authdes_prot.c debug.c
6088 +- auth_time.c auth_des.c authdes_prot.c debug.c des_crypt.c des_impl.c
6089 ++ auth_des.c authdes_prot.c debug.c des_crypt.c des_impl.c
6091 ## XDR
6092 libtirpc_la_SOURCES += xdr.c xdr_rec.c xdr_array.c xdr_float.c xdr_mem.c xdr_reference.c xdr_stdio.c xdr_sizeof.c
6093 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/0002-uClibc-without-RPC-support-and-musl-does-not-install-rpcent.h.patch buildroot-2017.05.2/package/libtirpc/0002-uClibc-without-RPC-support-and-musl-does-not-install-rpcent.h.patch
6094 --- buildroot-2017.05-rc2/package/libtirpc/0002-uClibc-without-RPC-support-and-musl-does-not-install-rpcent.h.patch 2017-05-17 10:27:16.013401440 +0200
6095 +++ buildroot-2017.05.2/package/libtirpc/0002-uClibc-without-RPC-support-and-musl-does-not-install-rpcent.h.patch 2017-07-27 08:16:52.017486944 +0200
6096 @@ -8,6 +8,8 @@ Signed-off-by: Thomas Petazzoni <thomas.
6097 Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
6098 [joerg.krause@embedded.rocks: musl fix]
6099 Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
6100 +[bernd.kuhls@t-online.de: update for 1.0.2]
6101 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
6103 tirpc/rpc/rpcent.h | 5 +++--
6104 1 file changed, 3 insertions(+), 2 deletions(-)
6105 @@ -21,7 +23,7 @@ index 147f909..4a58180 100644
6106 #endif
6108 -/* These are defined in /usr/include/rpc/netdb.h */
6109 --#if !defined(__GLIBC__)
6110 +-#if !defined(__GLIBC__) || defined(__UCLIBC__)
6111 +/* These are defined in /usr/include/rpc/netdb.h, unless we are using
6112 + the C library without RPC support. */
6113 +#if defined(__UCLIBC__) && !defined(__UCLIBC_HAS_RPC__) || !defined(__GLIBC__)
6114 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/0006-Disable-DES-authentification-support.patch buildroot-2017.05.2/package/libtirpc/0006-Disable-DES-authentification-support.patch
6115 --- buildroot-2017.05-rc2/package/libtirpc/0006-Disable-DES-authentification-support.patch 2017-05-17 10:27:16.013401440 +0200
6116 +++ buildroot-2017.05.2/package/libtirpc/0006-Disable-DES-authentification-support.patch 2017-07-27 08:16:52.017486944 +0200
6117 @@ -11,6 +11,8 @@ uClibc and musl does not provide DES aut
6118 Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
6119 [peda@axentia.se: update for 1.0.1]
6120 Signed-off-by: Peter Rosin <peda@axentia.se>
6121 +[bernd.kuhls@t-online.de: update for 1.0.2]
6122 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
6124 src/Makefile.am | 2 +-
6125 src/rpc_soc.c | 32 --------------------------------
6126 @@ -26,7 +28,7 @@ index 960a522..3a88e31 100644
6127 rpcb_st_xdr.c svc.c svc_auth.c svc_dg.c svc_auth_unix.c svc_auth_none.c \
6128 - svc_auth_des.c \
6129 svc_generic.c svc_raw.c svc_run.c svc_simple.c svc_vc.c getpeereid.c \
6130 -- auth_des.c authdes_prot.c debug.c
6131 +- auth_des.c authdes_prot.c debug.c des_crypt.c des_impl.c
6132 + debug.c
6134 ## XDR
6135 @@ -48,14 +50,6 @@ diff --git a/src/rpc_soc.c b/src/rpc_soc
6136 index e146ed4..161a1ec 100644
6137 --- a/src/rpc_soc.c
6138 +++ b/src/rpc_soc.c
6139 -@@ -61,7 +61,6 @@ #ifdef PORTMAP
6140 - #include <string.h>
6141 - #include <unistd.h>
6142 - #include <fcntl.h>
6143 --#include <rpcsvc/nis.h>
6145 - #include "rpc_com.h"
6147 @@ -522,86 +521,6 @@ clnt_broadcast(prog, vers, proc, xargs, argsp, xresults, resultsp, eachresult)
6150 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/0007-Add-missing-rwlock_unlocks-in-xprt_register.patch buildroot-2017.05.2/package/libtirpc/0007-Add-missing-rwlock_unlocks-in-xprt_register.patch
6151 --- buildroot-2017.05-rc2/package/libtirpc/0007-Add-missing-rwlock_unlocks-in-xprt_register.patch 2017-05-17 10:27:16.013401440 +0200
6152 +++ buildroot-2017.05.2/package/libtirpc/0007-Add-missing-rwlock_unlocks-in-xprt_register.patch 1970-01-01 01:00:00.000000000 +0100
6153 @@ -1,63 +0,0 @@
6154 -From 4f1503e84b2f7bd229a097335e52fb8203f5bb0b Mon Sep 17 00:00:00 2001
6155 -From: Michael Forney <mforney@mforney.org>
6156 -Date: Wed, 4 Nov 2015 13:58:06 -0500
6157 -Subject: [PATCH] Add missing rwlock_unlocks in xprt_register
6159 -It looks like in b2c9430f46c4ac848957fb8adaac176a3f6ac03f when svc_run
6160 -switched to poll, an early return was added, but the rwlock was not
6161 -unlocked.
6163 -I observed that rpcbind built against libtirpc-1.0.1 would handle only
6164 -one request before hanging, and tracked it down to a missing
6165 -rwlock_unlock here.
6167 -Fixes: b2c9430f46c4 ('Use poll() instead of select() in svc_run()')
6168 -Signed-off-by: Michael Forney <mforney@mforney.org>
6169 -Signed-off-by: Steve Dickson <steved@redhat.com>
6170 -[peda@axentia.se: backport from upstream]
6171 -Signed-off-by: Peter Rosin <peda@axentia.se>
6172 ----
6173 - src/svc.c | 7 ++++---
6174 - 1 file changed, 4 insertions(+), 3 deletions(-)
6176 -diff --git a/src/svc.c b/src/svc.c
6177 -index 9c41445..b59467b 100644
6178 ---- a/src/svc.c
6179 -+++ b/src/svc.c
6180 -@@ -99,7 +99,7 @@ xprt_register (xprt)
6182 - __svc_xports = (SVCXPRT **) calloc (_rpc_dtablesize(), sizeof (SVCXPRT *));
6183 - if (__svc_xports == NULL)
6184 -- return;
6185 -+ goto unlock;
6187 - if (sock < _rpc_dtablesize())
6189 -@@ -120,14 +120,14 @@ xprt_register (xprt)
6190 - svc_pollfd[i].fd = sock;
6191 - svc_pollfd[i].events = (POLLIN | POLLPRI |
6192 - POLLRDNORM | POLLRDBAND);
6193 -- return;
6194 -+ goto unlock;
6197 - new_svc_pollfd = (struct pollfd *) realloc (svc_pollfd,
6198 - sizeof (struct pollfd)
6199 - * (svc_max_pollfd + 1));
6200 - if (new_svc_pollfd == NULL) /* Out of memory */
6201 -- return;
6202 -+ goto unlock;
6203 - svc_pollfd = new_svc_pollfd;
6204 - ++svc_max_pollfd;
6206 -@@ -135,6 +135,7 @@ xprt_register (xprt)
6207 - svc_pollfd[svc_max_pollfd - 1].events = (POLLIN | POLLPRI |
6208 - POLLRDNORM | POLLRDBAND);
6210 -+unlock:
6211 - rwlock_unlock (&svc_fd_lock);
6214 ---
6215 -2.5.3
6217 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/0007-include-stdint.h-for-uintptr_t.patch buildroot-2017.05.2/package/libtirpc/0007-include-stdint.h-for-uintptr_t.patch
6218 --- buildroot-2017.05-rc2/package/libtirpc/0007-include-stdint.h-for-uintptr_t.patch 1970-01-01 01:00:00.000000000 +0100
6219 +++ buildroot-2017.05.2/package/libtirpc/0007-include-stdint.h-for-uintptr_t.patch 2017-07-27 08:16:52.017486944 +0200
6220 @@ -0,0 +1,31 @@
6221 +From 18f8a605e176f0362da22fd1203eb7cedb136aaf Mon Sep 17 00:00:00 2001
6222 +From: Khem Raj <raj.khem@gmail.com>
6223 +Date: Tue, 20 Jun 2017 22:06:35 +0200
6224 +Subject: [PATCH] include stdint.h for uintptr_t
6226 +Fixes
6227 +| ../../libtirpc-1.0.1/src/xdr_sizeof.c:93:13: error: 'uintptr_t' undeclared (first use in this function); did you mean '__intptr_t'?
6228 +| if (len < (uintptr_t)xdrs->x_base) {
6229 +| ^~~~~~~~~
6231 +Signed-off-by: Khem Raj <raj.khem@gmail.com>
6232 +Signed-off-by: Dmitrii Kolesnichenko <dmitrii@synopsys.com>
6233 +---
6234 + src/xdr_sizeof.c | 1 +
6235 + 1 file changed, 1 insertion(+)
6237 +diff --git a/src/xdr_sizeof.c b/src/xdr_sizeof.c
6238 +index d23fbd1..79d6707 100644
6239 +--- a/src/xdr_sizeof.c
6240 ++++ b/src/xdr_sizeof.c
6241 +@@ -39,6 +39,7 @@
6242 + #include <rpc/xdr.h>
6243 + #include <sys/types.h>
6244 + #include <stdlib.h>
6245 ++#include <stdint.h>
6246 + #include "un-namespace.h"
6248 + /* ARGSUSED */
6249 +--
6250 +2.9.4
6252 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/libtirpc.hash buildroot-2017.05.2/package/libtirpc/libtirpc.hash
6253 --- buildroot-2017.05-rc2/package/libtirpc/libtirpc.hash 2017-05-17 10:27:16.013401440 +0200
6254 +++ buildroot-2017.05.2/package/libtirpc/libtirpc.hash 2017-07-27 08:16:52.017486944 +0200
6255 @@ -1,4 +1,4 @@
6256 # From sourceforge's info on download page:
6257 -sha1 8da1636f98b5909c0d587e7534bc1e91f5c1a970 libtirpc-1.0.1.tar.bz2
6258 +sha1 2a8dc0e6eecc45be6597c8287b1d8e15cbee46e3 libtirpc-1.0.2.tar.bz2
6259 # Locally computed
6260 -sha256 5156974f31be7ccbc8ab1de37c4739af6d9d42c87b1d5caf4835dda75fcbb89e libtirpc-1.0.1.tar.bz2
6261 +sha256 723c5ce92706cbb601a8db09110df1b4b69391643158f20ff587e20e7c5f90f5 libtirpc-1.0.2.tar.bz2
6262 diff -Naurp buildroot-2017.05-rc2/package/libtirpc/libtirpc.mk buildroot-2017.05.2/package/libtirpc/libtirpc.mk
6263 --- buildroot-2017.05-rc2/package/libtirpc/libtirpc.mk 2017-05-17 10:27:16.013401440 +0200
6264 +++ buildroot-2017.05.2/package/libtirpc/libtirpc.mk 2017-07-27 08:16:52.017486944 +0200
6265 @@ -4,7 +4,7 @@
6267 ################################################################################
6269 -LIBTIRPC_VERSION = 1.0.1
6270 +LIBTIRPC_VERSION = 1.0.2
6271 LIBTIRPC_SOURCE = libtirpc-$(LIBTIRPC_VERSION).tar.bz2
6272 LIBTIRPC_SITE = http://downloads.sourceforge.net/project/libtirpc/libtirpc/$(LIBTIRPC_VERSION)
6273 LIBTIRPC_LICENSE = BSD-3-Clause
6274 diff -Naurp buildroot-2017.05-rc2/package/libv4l/libv4l.mk buildroot-2017.05.2/package/libv4l/libv4l.mk
6275 --- buildroot-2017.05-rc2/package/libv4l/libv4l.mk 2017-05-17 10:27:16.013401440 +0200
6276 +++ buildroot-2017.05.2/package/libv4l/libv4l.mk 2017-07-27 08:16:52.017486944 +0200
6277 @@ -46,10 +46,7 @@ LIBV4L_DEPENDENCIES += libgl
6278 endif
6280 ifeq ($(BR2_PACKAGE_HAS_UDEV),y)
6281 -LIBV4L_CONF_OPTS += --with-libudev
6282 LIBV4L_DEPENDENCIES += udev
6283 -else
6284 -LIBV4L_CONF_OPTS += --without-libudev
6285 endif
6287 ifeq ($(BR2_PACKAGE_LIBGLU),y)
6288 diff -Naurp buildroot-2017.05-rc2/package/libxml-parser-perl/libxml-parser-perl.mk buildroot-2017.05.2/package/libxml-parser-perl/libxml-parser-perl.mk
6289 --- buildroot-2017.05-rc2/package/libxml-parser-perl/libxml-parser-perl.mk 2017-05-17 10:27:16.013401440 +0200
6290 +++ buildroot-2017.05.2/package/libxml-parser-perl/libxml-parser-perl.mk 2017-07-27 08:16:52.017486944 +0200
6291 @@ -9,6 +9,7 @@ LIBXML_PARSER_PERL_SOURCE = XML-Parser-$
6292 LIBXML_PARSER_PERL_SITE = $(BR2_CPAN_MIRROR)/authors/id/T/TO/TODDR
6293 HOST_LIBXML_PARSER_PERL_DEPENDENCIES = host-expat
6294 LIBXML_PARSER_PERL_LICENSE = Artistic or GPL-1.0+
6295 +LIBXML_PARSER_PERL_LICENSE_FILES = README
6296 LIBXML_PARSER_PERL_RUN_PERL = `which perl`
6298 define HOST_LIBXML_PARSER_PERL_CONFIGURE_CMDS
6299 diff -Naurp buildroot-2017.05-rc2/package/linux-fusion/0004-Port-one-one_udp.c-to-Linux-4.1.patch buildroot-2017.05.2/package/linux-fusion/0004-Port-one-one_udp.c-to-Linux-4.1.patch
6300 --- buildroot-2017.05-rc2/package/linux-fusion/0004-Port-one-one_udp.c-to-Linux-4.1.patch 2017-05-17 10:27:16.013401440 +0200
6301 +++ buildroot-2017.05.2/package/linux-fusion/0004-Port-one-one_udp.c-to-Linux-4.1.patch 2017-07-27 08:16:52.017486944 +0200
6302 @@ -24,12 +24,20 @@ one/one_udp.c: In function 'ksocket_send
6303 one/one_udp.c:192:13: error: too many arguments to function 'sock_sendmsg'
6305 Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com>
6307 +Kernel commit 2da62906b1e29 dropped the size parameter in sock_recvmsg
6308 +since 4.7
6310 +In function 'ksocket_receive'
6311 +one/one_udp.c:235:13: error: too many arguments to function 'sock_recvmsg'
6313 +Signed-off-by: Matthew Shyu <matthew.shyu@amlogic.com>
6315 - one/one_udp.c | 30 +++++++++++++++---------------
6316 - 1 file changed, 15 insertions(+), 15 deletions(-)
6317 + one/one_udp.c | 34 +++++++++++++++++++---------------
6318 + 1 file changed, 19 insertions(+), 15 deletions(-)
6320 diff --git a/one/one_udp.c b/one/one_udp.c
6321 -index 26b9e6a1f729..b1daae164cdf 100644
6322 +index 26b9e6a..9b59529 100644
6323 --- a/one/one_udp.c
6324 +++ b/one/one_udp.c
6325 @@ -161,7 +161,7 @@ ksocket_send_iov( struct socket *sock,
6326 @@ -78,7 +86,7 @@ index 26b9e6a1f729..b1daae164cdf 100644
6327 struct iovec iov;
6328 mm_segment_t oldfs;
6329 int size = 0;
6330 -@@ -213,14 +215,12 @@ ksocket_receive(struct socket* sock, struct sockaddr_in* addr, void *buf, int le
6331 +@@ -213,18 +215,20 @@ ksocket_receive(struct socket* sock, struct sockaddr_in* addr, void *buf, int le
6332 iov.iov_base = buf;
6333 iov.iov_len = len;
6335 @@ -97,3 +105,14 @@ index 26b9e6a1f729..b1daae164cdf 100644
6337 oldfs = get_fs();
6338 set_fs(KERNEL_DS);
6339 ++#if LINUX_VERSION_CODE < KERNEL_VERSION(4,7,0) // commit 2da62906b1e29
6340 + size = sock_recvmsg(sock,&msg,len,msg.msg_flags);
6341 ++#else
6342 ++ size = sock_recvmsg(sock, &msg,msg.msg_flags);
6343 ++#endif
6344 + set_fs(oldfs);
6346 + return size;
6347 +--
6348 +2.11.0
6350 diff -Naurp buildroot-2017.05-rc2/package/linux-headers/Config.in.host buildroot-2017.05.2/package/linux-headers/Config.in.host
6351 --- buildroot-2017.05-rc2/package/linux-headers/Config.in.host 2017-05-17 10:27:16.013401440 +0200
6352 +++ buildroot-2017.05.2/package/linux-headers/Config.in.host 2017-07-27 08:16:52.017486944 +0200
6353 @@ -222,13 +222,13 @@ endchoice
6355 config BR2_DEFAULT_KERNEL_HEADERS
6356 string
6357 - default "3.2.88" if BR2_KERNEL_HEADERS_3_2
6358 + default "3.2.89" if BR2_KERNEL_HEADERS_3_2
6359 default "3.4.113" if BR2_KERNEL_HEADERS_3_4
6360 - default "3.10.105" if BR2_KERNEL_HEADERS_3_10
6361 + default "3.10.106" if BR2_KERNEL_HEADERS_3_10
6362 default "3.12.74" if BR2_KERNEL_HEADERS_3_12
6363 - default "4.1.39" if BR2_KERNEL_HEADERS_4_1
6364 - default "4.4.68" if BR2_KERNEL_HEADERS_4_4
6365 - default "4.9.28" if BR2_KERNEL_HEADERS_4_9
6366 - default "4.10.16" if BR2_KERNEL_HEADERS_4_10
6367 - default "4.11.1" if BR2_KERNEL_HEADERS_4_11
6368 + default "4.1.42" if BR2_KERNEL_HEADERS_4_1
6369 + default "4.4.78" if BR2_KERNEL_HEADERS_4_4
6370 + default "4.9.39" if BR2_KERNEL_HEADERS_4_9
6371 + default "4.10.17" if BR2_KERNEL_HEADERS_4_10
6372 + default "4.11.12" if BR2_KERNEL_HEADERS_4_11
6373 default BR2_DEFAULT_KERNEL_VERSION if BR2_KERNEL_HEADERS_VERSION
6374 diff -Naurp buildroot-2017.05-rc2/package/linux-zigbee/linux-zigbee.mk buildroot-2017.05.2/package/linux-zigbee/linux-zigbee.mk
6375 --- buildroot-2017.05-rc2/package/linux-zigbee/linux-zigbee.mk 2017-05-17 10:27:16.013401440 +0200
6376 +++ buildroot-2017.05.2/package/linux-zigbee/linux-zigbee.mk 2017-07-27 08:16:52.017486944 +0200
6377 @@ -15,6 +15,7 @@ LINUX_ZIGBEE_AUTORECONF = YES
6379 LINUX_ZIGBEE_CONF_OPTS = \
6380 --disable-manpages \
6381 + --disable-werror \
6382 --with-leasefile="$(call qstrip,$(BR2_PACKAGE_LINUX_ZIGBEE_LEASEFILE))"
6384 ifeq ($(BR2_PACKAGE_LINUX_ZIGBEE_TESTS),y)
6385 diff -Naurp buildroot-2017.05-rc2/package/lugaru/0002-Fix-mismatched-usage-length-build-fail-on-g.patch buildroot-2017.05.2/package/lugaru/0002-Fix-mismatched-usage-length-build-fail-on-g.patch
6386 --- buildroot-2017.05-rc2/package/lugaru/0002-Fix-mismatched-usage-length-build-fail-on-g.patch 1970-01-01 01:00:00.000000000 +0100
6387 +++ buildroot-2017.05.2/package/lugaru/0002-Fix-mismatched-usage-length-build-fail-on-g.patch 2017-07-27 08:16:52.017486944 +0200
6388 @@ -0,0 +1,58 @@
6389 +From 5a0c9f6358169b447840acdb721250ce932cb180 Mon Sep 17 00:00:00 2001
6390 +From: Martin Erik Werner <martinerikwerner@gmail.com>
6391 +Date: Wed, 8 Mar 2017 22:51:16 +0100
6392 +Subject: [PATCH] Fix mismatched usage length, build fail on g++
6393 +MIME-Version: 1.0
6394 +Content-Type: text/plain; charset=UTF-8
6395 +Content-Transfer-Encoding: 8bit
6397 +The length of const option::Descriptor usage[] is intended to be
6398 +inferred based on the initialisation in Source/main.cpp, however, the
6399 +extern declaration in Source/Game.hpp hard-codes it to 13.
6401 +Remove the hard-coded 13 in the extern declaration, in favour of the
6402 +inferred length.
6404 +This also fixes the follwoing build failure with g++ (Debian 4.9.2-10)
6405 +4.9.2:
6406 +(...)/Source/main.cpp:602:5: error: uninitialized const member ‘option::Descriptor::index’
6407 + };
6409 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::index’ [-Wmissing-field-initializers]
6410 +(...)/Source/main.cpp:602:5: error: uninitialized const member ‘option::Descriptor::type’
6411 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::type’ [-Wmissing-field-initializers]
6412 +(...)/Source/main.cpp:602:5: error: uninitialized const member ‘option::Descriptor::shortopt’
6413 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::shortopt’ [-Wmissing-field-initializers]
6414 +(...)/Source/main.cpp:602:5: error: uninitialized const member ‘option::Descriptor::longopt’
6415 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::longopt’ [-Wmissing-field-initializers]
6416 +(...)/Source/main.cpp:602:5: error: uninitialized const member ‘option::Descriptor::check_arg’
6417 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::check_arg’ [-Wmissing-field-initializers]
6418 +(...)/Source/main.cpp:602:5: warning: missing initializer for member ‘option::Descriptor::help’ [-Wmissing-field-initializers]
6419 +CMakeFiles/lugaru.dir/build.make:54: recipe for target 'CMakeFiles/lugaru.dir/Source/main.cpp.o' failed
6421 +Signed-off-by: Martin Erik Werner <martinerikwerner@gmail.com>
6423 +[Romain: backport to v1.2]
6424 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
6426 +(cherry picked from commit dd685fe9080c2853422d8272792691358ea07dfc)
6427 +---
6428 + Source/Game.hpp | 2 +-
6429 + 1 file changed, 1 insertion(+), 1 deletion(-)
6431 +diff --git a/Source/Game.hpp b/Source/Game.hpp
6432 +index 51232cc..9bb6adb 100644
6433 +--- a/Source/Game.hpp
6434 ++++ b/Source/Game.hpp
6435 +@@ -234,7 +234,7 @@ enum optionIndex
6436 + /* Number of options + 1 */
6437 + const int commandLineOptionsNumber = 10;
6439 +-extern const option::Descriptor usage[13];
6440 ++extern const option::Descriptor usage[];
6442 + extern option::Option commandLineOptions[commandLineOptionsNumber];
6443 + extern option::Option* commandLineOptionsBuffer;
6444 +--
6445 +2.9.4
6447 diff -Naurp buildroot-2017.05-rc2/package/madplay/0002-buildroot-libtool-v1.5.patch.patch buildroot-2017.05.2/package/madplay/0002-buildroot-libtool-v1.5.patch.patch
6448 --- buildroot-2017.05-rc2/package/madplay/0002-buildroot-libtool-v1.5.patch.patch 1970-01-01 01:00:00.000000000 +0100
6449 +++ buildroot-2017.05.2/package/madplay/0002-buildroot-libtool-v1.5.patch.patch 2017-07-27 08:16:52.017486944 +0200
6450 @@ -0,0 +1,109 @@
6451 +From ce661985c098635965573aac8fc983a72f60d396 Mon Sep 17 00:00:00 2001
6452 +From: Romain Naour <romain.naour@gmail.com>
6453 +Date: Tue, 30 May 2017 16:42:34 +0200
6454 +Subject: [PATCH] buildroot-libtool-v1.5.patch
6456 +Apply buildroot-libtool-v1.5.patch rebased on libtool 1.5.2 used
6457 +in madplay and fixing all conflicts.
6459 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
6460 +---
6461 + ltmain.sh | 40 ++++++++++++++++++++++++++++++----------
6462 + 1 file changed, 30 insertions(+), 10 deletions(-)
6464 +diff --git a/ltmain.sh b/ltmain.sh
6465 +index 4b9f940..0b71220 100644
6466 +--- a/ltmain.sh
6467 ++++ b/ltmain.sh
6468 +@@ -164,6 +164,11 @@ do
6469 + arg="$1"
6470 + shift
6472 ++ # Make -static behave as -all-static
6473 ++ case $arg in
6474 ++ -static) arg="-all-static" ;;
6475 ++ esac
6477 + case $arg in
6478 + -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;;
6479 + *) optarg= ;;
6480 +@@ -549,8 +554,9 @@ if test -z "$show_help"; then
6481 + # line option must be used.
6482 + if test -z "$tagname"; then
6483 + $echo "$modename: unable to infer tagged configuration"
6484 +- $echo "$modename: specify a tag with \`--tag'" 1>&2
6485 +- exit 1
6486 ++ $echo "$modename: defaulting to \`CC'"
6487 ++ $echo "$modename: if this is not correct, specify a tag with \`--tag'"
6488 ++# exit 1
6489 + # else
6490 + # $echo "$modename: using $tagname tagged configuration"
6491 + fi
6492 +@@ -1228,7 +1234,8 @@ EOF
6493 + prevarg="$arg"
6495 + case $arg in
6496 +- -all-static)
6497 ++ # Make -static behave like -all-static
6498 ++ -all-static | -static)
6499 + if test -n "$link_static_flag"; then
6500 + compile_command="$compile_command $link_static_flag"
6501 + finalize_command="$finalize_command $link_static_flag"
6502 +@@ -2135,8 +2142,14 @@ EOF
6503 + absdir="$abs_ladir"
6504 + libdir="$abs_ladir"
6505 + else
6506 +- dir="$libdir"
6507 +- absdir="$libdir"
6508 ++ # Adding 'libdir' from the .la file to our library search paths
6509 ++ # breaks crosscompilation horribly. We cheat here and don't add
6510 ++ # it, instead adding the path where we found the .la. -CL
6511 ++ dir="$abs_ladir"
6512 ++ absdir="$abs_ladir"
6513 ++ libdir="$abs_ladir"
6514 ++ #dir="$libdir"
6515 ++ #absdir="$libdir"
6516 + fi
6517 + else
6518 + dir="$ladir/$objdir"
6519 +@@ -2261,7 +2274,7 @@ EOF
6520 + { test "$prefer_static_libs" = no || test -z "$old_library"; }; then
6521 + if test "$installed" = no; then
6522 + notinst_deplibs="$notinst_deplibs $lib"
6523 +- need_relink=yes
6524 ++ need_relink=no
6525 + fi
6526 + # This is a shared library
6528 +@@ -5146,6 +5159,10 @@ fi\
6529 + # Replace all uninstalled libtool libraries with the installed ones
6530 + newdependency_libs=
6531 + for deplib in $dependency_libs; do
6532 ++ # Replacing uninstalled with installed can easily break crosscompilation,
6533 ++ # since the installed path is generally the wrong architecture. -CL
6534 ++ newdependency_libs="$newdependency_libs $deplib"
6535 ++ continue
6536 + case $deplib in
6537 + *.la)
6538 + name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'`
6539 +@@ -5464,10 +5481,13 @@ relink_command=\"$relink_command\""
6540 + # At present, this check doesn't affect windows .dll's that
6541 + # are installed into $libdir/../bin (currently, that works fine)
6542 + # but it's something to keep an eye on.
6543 +- if test "$inst_prefix_dir" = "$destdir"; then
6544 +- $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2
6545 +- exit 1
6546 +- fi
6547 ++ #
6548 ++ # This breaks install into our staging area. -PB
6549 ++ #
6550 ++ # if test "$inst_prefix_dir" = "$destdir"; then
6551 ++ # $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2
6552 ++ # exit 1
6553 ++ # fi
6555 + if test -n "$inst_prefix_dir"; then
6556 + # Stick the inst_prefix_dir data into the link command.
6557 +--
6558 +2.9.4
6560 diff -Naurp buildroot-2017.05-rc2/package/Makefile.in buildroot-2017.05.2/package/Makefile.in
6561 --- buildroot-2017.05-rc2/package/Makefile.in 2017-05-17 10:27:16.013401440 +0200
6562 +++ buildroot-2017.05.2/package/Makefile.in 2017-07-27 08:16:52.017486944 +0200
6563 @@ -207,7 +207,7 @@ TARGET_STRIP = $(TARGET_CROSS)strip
6564 STRIPCMD = $(TARGET_CROSS)strip --remove-section=.comment --remove-section=.note
6565 endif
6566 ifeq ($(BR2_STRIP_none),y)
6567 -TARGET_STRIP = true
6568 +TARGET_STRIP = /bin/true
6569 STRIPCMD = $(TARGET_STRIP)
6570 endif
6571 INSTALL := $(shell which install || type -p install)
6572 @@ -223,6 +223,27 @@ HOST_CFLAGS += $(HOST_CPPFLAGS)
6573 HOST_CXXFLAGS += $(HOST_CFLAGS)
6574 HOST_LDFLAGS += -L$(HOST_DIR)/lib -L$(HOST_DIR)/usr/lib -Wl,-rpath,$(HOST_DIR)/usr/lib
6576 +# The macros below are taken from linux 4.11 and adapted slightly.
6577 +# Copy more when needed.
6579 +# try-run
6580 +# Usage: option = $(call try-run, $(CC)...-o "$$TMP",option-ok,otherwise)
6581 +# Exit code chooses option. "$$TMP" is can be used as temporary file and
6582 +# is automatically cleaned up.
6583 +try-run = $(shell set -e; \
6584 + TMP="$$(tempfile)"; \
6585 + if ($(1)) >/dev/null 2>&1; \
6586 + then echo "$(2)"; \
6587 + else echo "$(3)"; \
6588 + fi; \
6589 + rm -f "$$TMP")
6591 +# host-cc-option
6592 +# Usage: HOST_FOO_CFLAGS += $(call host-cc-option,-no-pie,)
6593 +host-cc-option = $(call try-run,\
6594 + $(HOSTCC) $(HOST_CFLAGS) $(1) -c -x c /dev/null -o "$$TMP",$(1),$(2))
6597 # host-intltool should be executed with the system perl, so we save
6598 # the path to the system perl, before a host-perl built by Buildroot
6599 # might get installed into $(HOST_DIR)/usr/bin and therefore appears
6600 diff -Naurp buildroot-2017.05-rc2/package/mariadb/mariadb.hash buildroot-2017.05.2/package/mariadb/mariadb.hash
6601 --- buildroot-2017.05-rc2/package/mariadb/mariadb.hash 2017-05-17 10:27:16.013401440 +0200
6602 +++ buildroot-2017.05.2/package/mariadb/mariadb.hash 2017-07-27 08:16:52.017486944 +0200
6603 @@ -1,2 +1,2 @@
6604 -# From https://downloads.mariadb.org/mariadb/10.1.22/
6605 -sha256 bcb0572e7ad32cea9740a21e9255f733bdf60a5561ffbda317c22dd12b3966ce mariadb-10.1.22.tar.gz
6606 +# From https://downloads.mariadb.org/mariadb/10.1.23/
6607 +sha256 54d8114e24bfa5e3ebdc7d69e071ad1471912847ea481b227d204f9d644300bf mariadb-10.1.23.tar.gz
6608 diff -Naurp buildroot-2017.05-rc2/package/mariadb/mariadb.mk buildroot-2017.05.2/package/mariadb/mariadb.mk
6609 --- buildroot-2017.05-rc2/package/mariadb/mariadb.mk 2017-05-17 10:27:16.013401440 +0200
6610 +++ buildroot-2017.05.2/package/mariadb/mariadb.mk 2017-07-27 08:16:52.017486944 +0200
6611 @@ -4,10 +4,12 @@
6613 ################################################################################
6615 -MARIADB_VERSION = 10.1.22
6616 +MARIADB_VERSION = 10.1.23
6617 MARIADB_SITE = https://downloads.mariadb.org/interstitial/mariadb-$(MARIADB_VERSION)/source
6618 MARIADB_LICENSE = GPL-2.0 (server), GPL-2.0 with FLOSS exception (GPL client library), LGPL-2.0 (LGPL client library)
6619 -MARIADB_LICENSE_FILES = README COPYING COPYING.LESSER
6620 +# Tarball no longer contains LGPL license text
6621 +# https://jira.mariadb.org/browse/MDEV-12297
6622 +MARIADB_LICENSE_FILES = README COPYING
6623 MARIADB_INSTALL_STAGING = YES
6624 MARIADB_PROVIDES = mysql
6626 diff -Naurp buildroot-2017.05-rc2/package/mesa3d/Config.in buildroot-2017.05.2/package/mesa3d/Config.in
6627 --- buildroot-2017.05-rc2/package/mesa3d/Config.in 2017-05-17 10:27:16.013401440 +0200
6628 +++ buildroot-2017.05.2/package/mesa3d/Config.in 2017-07-27 08:16:52.017486944 +0200
6629 @@ -30,8 +30,15 @@ config BR2_PACKAGE_MESA3D_GALLIUM_DRIVER
6630 config BR2_PACKAGE_MESA3D_DRI_DRIVER
6631 bool
6632 select BR2_PACKAGE_MESA3D_DRIVER
6633 - select BR2_PACKAGE_XLIB_LIBXSHMFENCE if BR2_PACKAGE_XPROTO_DRI3PROTO
6634 - select BR2_PACKAGE_XPROTO_PRESENTPROTO if BR2_PACKAGE_XPROTO_DRI3PROTO
6635 + # xlib-libxshmfence needs sync_4, so we cannot select it if
6636 + # BR2_TOOLCHAIN_HAS_SYNC_4 is false. xproto-presentproto
6637 + # doesn't need sync_4, but it is only needed in conjunction
6638 + # with xlib-libxshmfence and dri3proto to provide dri3
6639 + # support, so we also only select it if sync_4 is available.
6640 + select BR2_PACKAGE_XLIB_LIBXSHMFENCE if \
6641 + (BR2_PACKAGE_XPROTO_DRI3PROTO && BR2_TOOLCHAIN_HAS_SYNC_4)
6642 + select BR2_PACKAGE_XPROTO_PRESENTPROTO if \
6643 + (BR2_PACKAGE_XPROTO_DRI3PROTO && BR2_TOOLCHAIN_HAS_SYNC_4)
6645 config BR2_PACKAGE_MESA3D_VULKAN_DRIVER
6646 bool
6647 diff -Naurp buildroot-2017.05-rc2/package/mesa3d/mesa3d.mk buildroot-2017.05.2/package/mesa3d/mesa3d.mk
6648 --- buildroot-2017.05-rc2/package/mesa3d/mesa3d.mk 2017-05-17 10:27:16.013401440 +0200
6649 +++ buildroot-2017.05.2/package/mesa3d/mesa3d.mk 2017-07-27 08:16:52.017486944 +0200
6650 @@ -90,7 +90,7 @@ ifeq ($(BR2_PACKAGE_MESA3D_DRI_DRIVER),)
6651 MESA3D_CONF_OPTS += \
6652 --without-dri-drivers --disable-dri3
6653 else
6654 -ifeq ($(BR2_PACKAGE_XPROTO_DRI3PROTO),y)
6655 +ifeq ($(BR2_PACKAGE_XLIB_LIBXSHMFENCE)$(BR2_PACKAGE_XPROTO_DRI3PROTO),yy)
6656 MESA3D_DEPENDENCIES += xlib_libxshmfence xproto_dri3proto xproto_presentproto
6657 MESA3D_CONF_OPTS += --enable-dri3
6658 else
6659 diff -Naurp buildroot-2017.05-rc2/package/mono/mono.mk buildroot-2017.05.2/package/mono/mono.mk
6660 --- buildroot-2017.05-rc2/package/mono/mono.mk 2017-05-17 10:27:16.013401440 +0200
6661 +++ buildroot-2017.05.2/package/mono/mono.mk 2017-07-27 08:16:52.017486944 +0200
6662 @@ -29,7 +29,6 @@ MONO_CONF_OPTS = --with-mcs-docs=no \
6663 define MONO_INSTALL_LIBS
6664 rsync -av --exclude=*.so --exclude=*.mdb \
6665 $(HOST_DIR)/usr/lib/mono $(TARGET_DIR)/usr/lib/
6666 - rsync -av $(HOST_DIR)/etc/mono $(TARGET_DIR)/etc
6667 endef
6669 MONO_POST_INSTALL_TARGET_HOOKS += MONO_INSTALL_LIBS
6670 diff -Naurp buildroot-2017.05-rc2/package/mosh/Config.in buildroot-2017.05.2/package/mosh/Config.in
6671 --- buildroot-2017.05-rc2/package/mosh/Config.in 2017-05-17 10:27:16.013401440 +0200
6672 +++ buildroot-2017.05.2/package/mosh/Config.in 2017-07-27 08:16:52.017486944 +0200
6673 @@ -24,4 +24,11 @@ config BR2_PACKAGE_MOSH
6674 allows roaming, and provides speculative local echo and line editing
6675 of user keystrokes.
6677 + Mosh requires that the remote machine has a locale setting matching
6678 + the one on the client.
6680 + When using mosh with dropbear on a remote machine, the client needs mosh
6681 + with a version above 1.3.0 and the --no-ssh-pty option needs to be passed
6682 + when starting the connection.
6684 https://mosh.mit.edu
6685 diff -Naurp buildroot-2017.05-rc2/package/mosquitto/0001-Remove-lanl-when-WITH_ADNS-is-unset.patch buildroot-2017.05.2/package/mosquitto/0001-Remove-lanl-when-WITH_ADNS-is-unset.patch
6686 --- buildroot-2017.05-rc2/package/mosquitto/0001-Remove-lanl-when-WITH_ADNS-is-unset.patch 2017-05-17 10:27:16.013401440 +0200
6687 +++ buildroot-2017.05.2/package/mosquitto/0001-Remove-lanl-when-WITH_ADNS-is-unset.patch 1970-01-01 01:00:00.000000000 +0100
6688 @@ -1,32 +0,0 @@
6689 -From 0de640dd834b6c01c4904e11d51f3a1406c89469 Mon Sep 17 00:00:00 2001
6690 -From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
6691 -Date: Mon, 3 Apr 2017 20:34:07 +0200
6692 -Subject: [PATCH] Remove -lanl when WITH_ADNS is unset
6694 -Do not add -lanl to BROKER_LIBS for all Linux builds.
6695 -Indeed, -lanl is only needed for getaddrinfo_a which is only used in
6696 -_mosquitto_try_connect_step1 when WITH_ADNS is set
6698 -Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
6699 ----
6700 - config.mk | 4 ----
6701 - 1 file changed, 4 deletions(-)
6703 -diff --git a/config.mk b/config.mk
6704 -index 6e369c2..44639d2 100644
6705 ---- a/config.mk
6706 -+++ b/config.mk
6707 -@@ -159,10 +159,6 @@ ifeq ($(UNAME),QNX)
6708 - LIB_LIBS:=$(LIB_LIBS) -lsocket
6709 - endif
6711 --ifeq ($(UNAME),Linux)
6712 -- BROKER_LIBS:=$(BROKER_LIBS) -lanl
6713 --endif
6715 - ifeq ($(WITH_WRAP),yes)
6716 - BROKER_LIBS:=$(BROKER_LIBS) -lwrap
6717 - BROKER_CFLAGS:=$(BROKER_CFLAGS) -DWITH_WRAP
6718 ---
6719 -2.5.0
6721 diff -Naurp buildroot-2017.05-rc2/package/mosquitto/mosquitto.hash buildroot-2017.05.2/package/mosquitto/mosquitto.hash
6722 --- buildroot-2017.05-rc2/package/mosquitto/mosquitto.hash 2017-05-17 10:27:16.013401440 +0200
6723 +++ buildroot-2017.05.2/package/mosquitto/mosquitto.hash 2017-07-27 08:16:52.017486944 +0200
6724 @@ -1,2 +1,3 @@
6725 # Locally computed:
6726 -sha512 c05ca8679b9a6f540868f4ccf701257fcabc114d5450ac0bbbe80b91bb7cd4fc52668773e945506760c7a5bd8a494e0a56100714112e5d2713d57bfab8951587 mosquitto-1.4.11.tar.gz
6727 +sha512 75e6105498869ab13265df7a0bea6052c014d59d0c0efb61162d8257d34c0153fce32130e84c28e99fd494f374949aac5e01c19f7439c2eea575b52ef1179c3c mosquitto-1.4.12.tar.gz
6728 +sha256 06abd1206e548ac2378dd96f5434cb3e40ed77cecb6a9c37fbabab0b0f1360e5 mosquitto-1.4.x_cve-2017-9868.patch
6729 diff -Naurp buildroot-2017.05-rc2/package/mosquitto/mosquitto.mk buildroot-2017.05.2/package/mosquitto/mosquitto.mk
6730 --- buildroot-2017.05-rc2/package/mosquitto/mosquitto.mk 2017-05-17 10:27:16.013401440 +0200
6731 +++ buildroot-2017.05.2/package/mosquitto/mosquitto.mk 2017-07-27 08:16:52.017486944 +0200
6732 @@ -4,11 +4,13 @@
6734 ################################################################################
6736 -MOSQUITTO_VERSION = 1.4.11
6737 +MOSQUITTO_VERSION = 1.4.12
6738 MOSQUITTO_SITE = http://mosquitto.org/files/source
6739 MOSQUITTO_LICENSE = EPL-1.0 or EDLv1.0
6740 MOSQUITTO_LICENSE_FILES = LICENSE.txt epl-v10 edl-v10
6741 MOSQUITTO_INSTALL_STAGING = YES
6742 +MOSQUITTO_PATCH = \
6743 + https://mosquitto.org/files/cve/2017-9868/mosquitto-1.4.x_cve-2017-9868.patch
6745 MOSQUITTO_MAKE_OPTS = \
6746 UNAME=Linux \
6747 diff -Naurp buildroot-2017.05-rc2/package/mpg123/mpg123.hash buildroot-2017.05.2/package/mpg123/mpg123.hash
6748 --- buildroot-2017.05-rc2/package/mpg123/mpg123.hash 2017-05-17 10:27:16.013401440 +0200
6749 +++ buildroot-2017.05.2/package/mpg123/mpg123.hash 2017-07-27 08:16:52.017486944 +0200
6750 @@ -1,2 +1,5 @@
6751 # Locally calculated after checking pgp signature
6752 -sha256 de2303c8ecb65593e39815c0a2f2f2d91f708c43b85a55fdd1934c82e677cf8e mpg123-1.23.8.tar.bz2
6753 +sha256 5314b0fb8ad291bfc79ff4c5c321b971916819a65233ec065434358fcf8aee38 mpg123-1.25.2.tar.bz2
6755 +# License file
6756 +sha256 f40e0dd86b27b52e429b693a87b3ca63ae0a98a4d142e77207aa6bdf1db7a295 COPYING
6757 diff -Naurp buildroot-2017.05-rc2/package/mpg123/mpg123.mk buildroot-2017.05.2/package/mpg123/mpg123.mk
6758 --- buildroot-2017.05-rc2/package/mpg123/mpg123.mk 2017-05-17 10:27:16.013401440 +0200
6759 +++ buildroot-2017.05.2/package/mpg123/mpg123.mk 2017-07-27 08:16:52.017486944 +0200
6760 @@ -4,7 +4,7 @@
6762 ################################################################################
6764 -MPG123_VERSION = 1.23.8
6765 +MPG123_VERSION = 1.25.2
6766 MPG123_SOURCE = mpg123-$(MPG123_VERSION).tar.bz2
6767 MPG123_SITE = http://downloads.sourceforge.net/project/mpg123/mpg123/$(MPG123_VERSION)
6768 MPG123_CONF_OPTS = --disable-lfs-alias
6769 @@ -74,10 +74,11 @@ endif
6771 MPG123_CONF_OPTS += --with-audio=$(subst $(space),$(comma),$(MPG123_AUDIO))
6773 -ifeq ($(BR2_PACKAGE_LIBTOOL),y)
6774 -MPG123_DEPENDENCIES += libtool
6775 -# .la files gets stripped , so directly load .so files rather than .la
6776 -MPG123_CONF_OPTS += --with-modules --with-module-suffix=.so
6777 +# output modules are loaded with dlopen()
6778 +ifeq ($(BR2_STATIC_LIBS),y)
6779 +MPG123_CONF_OPTS += --disable-modules
6780 +else
6781 +MPG123_CONF_OPTS += --enable-modules
6782 endif
6784 $(eval $(autotools-package))
6785 diff -Naurp buildroot-2017.05-rc2/package/mxml/mxml.mk buildroot-2017.05.2/package/mxml/mxml.mk
6786 --- buildroot-2017.05-rc2/package/mxml/mxml.mk 2017-05-17 10:27:16.013401440 +0200
6787 +++ buildroot-2017.05.2/package/mxml/mxml.mk 2017-07-27 08:16:52.017486944 +0200
6788 @@ -5,7 +5,7 @@
6789 ################################################################################
6791 MXML_VERSION = 2.10
6792 -MXML_SITE = http://www.msweet.org/files/project3
6793 +MXML_SITE = https://github.com/michaelrsweet/mxml/releases/download/release-$(MXML_VERSION)
6794 MXML_LICENSE = LGPL-2.0+ with exceptions
6795 MXML_LICENSE_FILES = COPYING
6796 MXML_INSTALL_STAGING = YES
6797 diff -Naurp buildroot-2017.05-rc2/package/ncurses/ncurses.mk buildroot-2017.05.2/package/ncurses/ncurses.mk
6798 --- buildroot-2017.05-rc2/package/ncurses/ncurses.mk 2017-05-17 10:27:16.013401440 +0200
6799 +++ buildroot-2017.05.2/package/ncurses/ncurses.mk 2017-07-27 08:16:52.017486944 +0200
6800 @@ -47,10 +47,12 @@ endif
6802 NCURSES_TERMINFO_FILES = \
6803 a/ansi \
6804 + d/dumb \
6805 l/linux \
6806 p/putty \
6807 p/putty-vt100 \
6808 s/screen \
6809 + s/screen-256color \
6810 v/vt100 \
6811 v/vt100-putty \
6812 v/vt102 \
6813 diff -Naurp buildroot-2017.05-rc2/package/network-manager/Config.in buildroot-2017.05.2/package/network-manager/Config.in
6814 --- buildroot-2017.05-rc2/package/network-manager/Config.in 2017-05-17 10:27:16.013401440 +0200
6815 +++ buildroot-2017.05.2/package/network-manager/Config.in 2017-07-27 08:16:52.017486944 +0200
6816 @@ -1,6 +1,7 @@
6817 config BR2_PACKAGE_NETWORK_MANAGER
6818 bool "networkmanager"
6819 depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt
6820 + depends on !BR2_STATIC_LIBS # gnutls
6821 depends on BR2_USE_MMU # dbus
6822 depends on BR2_PACKAGE_HAS_UDEV
6823 # Tested with 3.2, but may even work with earlier versions
6824 @@ -57,8 +58,8 @@ comment "pppd support needs a glibc or u
6826 endif
6828 -comment "NetworkManager needs udev /dev management and a glibc toolchain w/ headers >= 3.7"
6829 +comment "NetworkManager needs udev /dev management and a glibc toolchain w/ headers >= 3.7, dynamic library"
6830 depends on BR2_USE_MMU
6831 depends on !BR2_PACKAGE_HAS_UDEV || \
6832 !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_7 || \
6833 - !BR2_TOOLCHAIN_USES_GLIBC
6834 + !BR2_TOOLCHAIN_USES_GLIBC || BR2_STATIC_LIBS
6835 diff -Naurp buildroot-2017.05-rc2/package/ntp/0003-ntpq-fpic.patch buildroot-2017.05.2/package/ntp/0003-ntpq-fpic.patch
6836 --- buildroot-2017.05-rc2/package/ntp/0003-ntpq-fpic.patch 1970-01-01 01:00:00.000000000 +0100
6837 +++ buildroot-2017.05.2/package/ntp/0003-ntpq-fpic.patch 2017-07-27 08:16:52.017486944 +0200
6838 @@ -0,0 +1,23 @@
6839 +ntpq/Makefile.am: add NTP_HARD_CFLAGS
6841 +Pass NTP_HARD_CFLAGS when building ntpq, like in all other ntp
6842 +modules, to make sure -fPIC is passed.
6844 +Originally taken from
6845 +https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=494143c3b4921a5c8b8596d58f2c8b98296bf688.
6847 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
6849 +Index: b/ntpq/Makefile.am
6850 +===================================================================
6851 +--- a/ntpq/Makefile.am
6852 ++++ b/ntpq/Makefile.am
6853 +@@ -23,7 +23,7 @@
6854 + ntpq_LDADD += $(LDADD_NTP)
6855 + noinst_HEADERS= ntpq.h
6856 + noinst_LIBRARIES= libntpq.a
6857 +-libntpq_a_CFLAGS= -DNO_MAIN_ALLOWED -DBUILD_AS_LIB
6858 ++libntpq_a_CFLAGS= $(NTP_HARD_CFLAGS) -DNO_MAIN_ALLOWED -DBUILD_AS_LIB
6859 + CLEANFILES=
6860 + DISTCLEANFILES= .version version.c config.log $(man_MANS)
6861 + ETAGS_ARGS= Makefile.am
6862 diff -Naurp buildroot-2017.05-rc2/package/ntp/ntp.mk buildroot-2017.05.2/package/ntp/ntp.mk
6863 --- buildroot-2017.05-rc2/package/ntp/ntp.mk 2017-05-17 10:27:16.013401440 +0200
6864 +++ buildroot-2017.05.2/package/ntp/ntp.mk 2017-07-27 08:16:52.017486944 +0200
6865 @@ -21,6 +21,7 @@ NTP_CONF_OPTS = \
6866 --with-crypto
6868 # 0002-ntp-syscalls-fallback.patch
6869 +# 0003-ntpq-fpic.patch
6870 NTP_AUTORECONF = YES
6872 ifeq ($(BR2_TOOLCHAIN_HAS_SSP),y)
6873 @@ -64,6 +65,12 @@ else
6874 NTP_CONF_OPTS += --disable-SHM
6875 endif
6877 +ifeq ($(BR2_PACKAGE_NTP_SNTP),y)
6878 +NTP_CONF_OPTS += --with-sntp
6879 +else
6880 +NTP_CONF_OPTS += --without-sntp
6881 +endif
6883 NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_KEYGEN) += util/ntp-keygen
6884 NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_WAIT) += scripts/ntp-wait/ntp-wait
6885 NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPDATE) += ntpdate/ntpdate
6886 diff -Naurp buildroot-2017.05-rc2/package/ola/0001-Remove-fvisibiliy-inlines-hidden.patch buildroot-2017.05.2/package/ola/0001-Remove-fvisibiliy-inlines-hidden.patch
6887 --- buildroot-2017.05-rc2/package/ola/0001-Remove-fvisibiliy-inlines-hidden.patch 2017-05-17 10:27:16.013401440 +0200
6888 +++ buildroot-2017.05.2/package/ola/0001-Remove-fvisibiliy-inlines-hidden.patch 1970-01-01 01:00:00.000000000 +0100
6889 @@ -1,26 +0,0 @@
6890 -From cd4f5d9d8a10c368584e8e714ebb0f9695267063 Mon Sep 17 00:00:00 2001
6891 -From: Simon Marchi <simon.marchi@polymtl.ca>
6892 -Date: Mon, 10 Aug 2015 15:01:42 -0400
6893 -Subject: [PATCH] Remove -fvisibiliy-inlines-hidden
6895 -Signed-off-by: Simon Marchi <simon.marchi@polymtl.ca>
6896 ----
6897 - Makefile.am | 2 +-
6898 - 1 file changed, 1 insertion(+), 1 deletion(-)
6900 -diff --git a/Makefile.am b/Makefile.am
6901 -index 714e435..17a23e2 100644
6902 ---- a/Makefile.am
6903 -+++ b/Makefile.am
6904 -@@ -32,7 +32,7 @@ AM_DISTCHECK_CONFIGURE_FLAGS = --enable-python-libs
6905 - COMMON_CXXFLAGS_ONLY_WARNINGS = \
6906 - -I$(top_srcdir)/include \
6907 - -I$(top_builddir)/include \
6908 -- -Wall -Wformat -W -fvisibility-inlines-hidden \
6909 -+ -Wall -Wformat -W \
6910 - $(libprotobuf_CFLAGS)
6912 - COMMON_CXXFLAGS = $(COMMON_CXXFLAGS_ONLY_WARNINGS)
6913 ---
6914 -2.5.0
6916 diff -Naurp buildroot-2017.05-rc2/package/ola/0002-Remove-replacing-I-with-isystem.patch buildroot-2017.05.2/package/ola/0002-Remove-replacing-I-with-isystem.patch
6917 --- buildroot-2017.05-rc2/package/ola/0002-Remove-replacing-I-with-isystem.patch 2017-05-17 10:27:16.013401440 +0200
6918 +++ buildroot-2017.05.2/package/ola/0002-Remove-replacing-I-with-isystem.patch 1970-01-01 01:00:00.000000000 +0100
6919 @@ -1,106 +0,0 @@
6920 -From bbb03794def326c2e8ad2de523c5a61a4c8cb464 Mon Sep 17 00:00:00 2001
6921 -From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
6922 -Date: Thu, 22 Sep 2016 00:58:58 +0200
6923 -Subject: [PATCH] Remove replacing -I with -isystem
6924 -MIME-Version: 1.0
6925 -Content-Type: text/plain; charset=UTF-8
6926 -Content-Transfer-Encoding: 8bit
6928 -Building OLA with a GCC 6 cross-toolchain fails:
6930 -```
6931 -/usr/bin/arm-linux-g++ -DHAVE_CONFIG_H -I. -D_LARGEFILE_SOURCE
6932 --D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -I./include -I./include
6933 --Wall -Wformat -W -isystem
6934 -/usr/arm-buildroot-linux-gnueabihf/sysroot/usr/include -pthread
6935 --D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Os
6936 --pthread -c -o libs/acn/e131_transmit_test.o
6937 -libs/acn/e131_transmit_test.cpp
6938 -/usr/bin/arm-linux-g++ -DHAVE_CONFIG_H -I. -D_LARGEFILE_SOURCE
6939 --D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -I./include -I./include
6940 --Wall -Wformat -W -isystem
6941 -/usr/arm-buildroot-linux-gnueabihf/sysroot/usr/include -pthread
6942 --D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Os
6943 --pthread -c -o libs/acn/E131TestFramework.o
6944 -libs/acn/E131TestFramework.cpp
6945 -In file included from
6946 -/opt/ext-toolchain/arm-buildroot-linux-gnueabihf/include/c++/6.1.0/ext/string_conversions.h:41:0,
6947 - from
6948 -/opt/ext-toolchain/arm-buildroot-linux-gnueabihf/include/c++/6.1.0/bits/basic_string.h:5402,
6949 - from
6950 -/opt/ext-toolchain/arm-buildroot-linux-gnueabihf/include/c++/6.1.0/string:52,
6951 - from ./tools/ola_trigger/config.ypp:2:
6952 -/opt/ext-toolchain/arm-buildroot-linux-gnueabihf/include/c++/6.1.0/cstdlib:75:25:
6953 -fatal error: stdlib.h: No such file or directory
6954 - #include_next <stdlib.h>
6956 -compilation terminated.
6957 -```
6959 -The C++ library in GCC 6 now provides its own `<stdlib.h>` header that
6960 -wraps the C library header of the same name, so in `<cstdlib>` the
6961 -header include
6963 -```
6964 -#include <stdlib.h>
6965 -```
6967 -has become
6969 -```
6970 -#include_next <stdlib.h>
6971 -```
6973 -`#include_next` is sensitive to the order of directories in the
6974 -preprocessor's search path, so if that order is changed with `-isystem`
6975 -then the compiler can't find the right header:
6977 -```
6978 -[1] /usr/arm-buildroot-linux-gnueabihf/sysroot/usr/include
6979 -[2] /opt/ext-toolchain/arm-buildroot-linux-gnueabihf/include/c++/6.1.0
6980 -[..]
6981 -End of search list.
6982 -```
6984 -`<cstdlib>` is located in [2] whereas `<stdlib.h>` (C library header) is
6985 -in [1]. In this case, the `#include_next <stdlib.h>` statement in
6986 -`<cstdlib>`, located in [2], is evaluated **after** the search path [1],
6987 -so the compiler does not find the right system header.
6989 -The problem is that the OLA build system replaces the `-I` in the CFLAGS
6990 -from libprotobuf with `-isystem` to fix some warnings treated as errors
6991 -in the libprotobuf header files.
6993 -`-isystem` should be used to suppress warnings in system headers only
6994 -and the libprotobuf header files are not system files.
6996 -The correct fix is to compile with less restrictions and remove
6997 -`-Werror` for the build.
6999 -As using `-isystem` is reordering GCCs search path and using `-isystem`
7000 -is really not necessary, remove the faulty replacement of `-I`.
7002 -Upstream status: https://github.com/OpenLightingProject/ola/pull/1126
7004 -Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
7005 ----
7006 - config/ola.m4 | 3 ---
7007 - 1 file changed, 3 deletions(-)
7009 -diff --git a/config/ola.m4 b/config/ola.m4
7010 -index 2796cfb..d3b8cc8 100644
7011 ---- a/config/ola.m4
7012 -+++ b/config/ola.m4
7013 -@@ -24,9 +24,6 @@ AC_DEFUN([PROTOBUF_SUPPORT],
7014 - AC_REQUIRE_CPP()
7015 - PKG_CHECK_MODULES(libprotobuf, [protobuf >= $1])
7017 --# We want to replace -I with -isystem here to disable errors in the .h files
7018 --# See https://groups.google.com/forum/#!topic/open-lighting/39Mj0KXlCIk
7019 --libprotobuf_CFLAGS=`echo $libprotobuf_CFLAGS | sed 's/-I/-isystem /'`
7020 - AC_SUBST([libprotobuf_CFLAGS])
7022 - AC_ARG_WITH([protoc],
7023 ---
7024 -2.10.0
7026 diff -Naurp buildroot-2017.05-rc2/package/ola/Config.in buildroot-2017.05.2/package/ola/Config.in
7027 --- buildroot-2017.05-rc2/package/ola/Config.in 2017-05-17 10:27:16.013401440 +0200
7028 +++ buildroot-2017.05.2/package/ola/Config.in 1970-01-01 01:00:00.000000000 +0100
7029 @@ -1,138 +0,0 @@
7030 -comment "ola needs a toolchain w/ C++, threads, dynamic library, host and target gcc >= 4.5"
7031 - depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \
7032 - || BR2_STATIC_LIBS || !BR2_HOST_GCC_AT_LEAST_4_5 \
7033 - || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_5
7034 - depends on BROKEN
7035 - depends on BR2_PACKAGE_PROTOBUF_ARCH_SUPPORTS
7037 -menuconfig BR2_PACKAGE_OLA
7038 - bool "ola (open lighting architecture)"
7039 - select BR2_PACKAGE_PROTOBUF
7040 - select BR2_PACKAGE_UTIL_LINUX_LIBUUID
7041 - select BR2_PACKAGE_UTIL_LINUX
7042 - # Build fails with current protobuf
7043 - # https://github.com/OpenLightingProject/ola/issues/1192
7044 - depends on BROKEN
7045 - depends on BR2_INSTALL_LIBSTDCPP # protobuf
7046 - depends on !BR2_STATIC_LIBS # protobuf
7047 - depends on BR2_TOOLCHAIN_HAS_THREADS
7048 - depends on BR2_PACKAGE_PROTOBUF_ARCH_SUPPORTS
7049 - depends on BR2_HOST_GCC_AT_LEAST_4_5 # protobuf
7050 - depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_5 # protobuf
7051 - help
7052 - Open Lighting Architecture provides applications
7053 - with a mechanism to send and receive DMX512 & RDM
7054 - commands using hardware devices and DMX over IP protocols.
7056 - http://www.opendmx.net/index.php/OLA
7058 -if BR2_PACKAGE_OLA
7060 -comment "bindings and interface"
7062 -config BR2_PACKAGE_OLA_WEB
7063 - bool "http interface"
7064 - depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt, libmicrohttpd
7065 - select BR2_PACKAGE_LIBMICROHTTPD
7066 - help
7067 - Build OLA with browser interface.
7069 -config BR2_PACKAGE_OLA_PYTHON_BINDINGS
7070 - bool "python bindings"
7071 - depends on BR2_PACKAGE_PYTHON
7072 - select BR2_PACKAGE_PYTHON_PROTOBUF
7073 - help
7074 - Build OLA with support for the Python language.
7076 -config BR2_PACKAGE_OLA_SLP
7077 - bool "slp tools"
7078 - help
7079 - Build OLA with slp tools.
7081 -comment "tests and examples"
7083 -config BR2_PACKAGE_OLA_EXAMPLES
7084 - bool "examples"
7085 - select BR2_PACKAGE_NCURSES
7086 - help
7087 - Build OLA examples.
7089 -config BR2_PACKAGE_OLA_RDM_TESTS
7090 - bool "rdm tests"
7091 - depends on BR2_PACKAGE_OLA_PYTHON_BINDINGS
7092 - depends on BR2_PACKAGE_PYTHON_NUMPY_ARCH_SUPPORTS
7093 - select BR2_PACKAGE_PYTHON_NUMPY
7094 - help
7095 - Build OLA RDM tests.
7097 -comment "plugin selections"
7099 -config BR2_PACKAGE_OLA_PLUGIN_E131
7100 - bool "acn E131"
7101 - help
7102 - Build ACN E131 plugin for OLA.
7104 -config BR2_PACKAGE_OLA_PLUGIN_ARTNET
7105 - bool "artnet"
7106 - help
7107 - Build Artnet plugin for OLA.
7109 -config BR2_PACKAGE_OLA_PLUGIN_OPENDMX
7110 - bool "DMX4Linux"
7111 - help
7112 - Build DMX4Linux plugin for OLA.
7114 -config BR2_PACKAGE_OLA_PLUGIN_DUMMY
7115 - bool "dummy"
7116 - help
7117 - Build Dummy plugin for OLA.
7119 -config BR2_PACKAGE_OLA_PLUGIN_ESPNET
7120 - bool "espnet"
7121 - help
7122 - Build EspNet plugin for OLA.
7124 -config BR2_PACKAGE_OLA_PLUGIN_KINET
7125 - bool "kinet"
7126 - help
7127 - Build KiNet plugin for OLA.
7129 -config BR2_PACKAGE_OLA_PLUGIN_MILINT
7130 - bool "Milford Instruments"
7131 - help
7132 - Build Milford Instruments 1-463 plugin for OLA.
7134 -config BR2_PACKAGE_OLA_PLUGIN_OSC
7135 - bool "osc"
7136 - select BR2_PACKAGE_LIBLO
7137 - help
7138 - Build Open Sound Control plugin for OLA.
7140 -config BR2_PACKAGE_OLA_PLUGIN_PATHPORT
7141 - bool "pathport"
7142 - help
7143 - Build Pathport plugin for OLA.
7145 -config BR2_PACKAGE_OLA_PLUGIN_SANDNET
7146 - bool "sandnet"
7147 - help
7148 - Build SandNet plugin for OLA.
7150 -config BR2_PACKAGE_OLA_PLUGIN_SHOWNET
7151 - bool "shownet"
7152 - help
7153 - Build ShowNet plugin for OLA.
7155 -config BR2_PACKAGE_OLA_PLUGIN_STAGEPROFI
7156 - bool "stageprofi"
7157 - select BR2_PACKAGE_LIBUSB
7158 - help
7159 - Build StageProfi plugin for OLA.
7161 -config BR2_PACKAGE_OLA_PLUGIN_USBPRO
7162 - bool "usbpro"
7163 - select BR2_PACKAGE_LIBUSB
7164 - help
7165 - Build UsbPro plugin for OLA.
7167 -endif
7168 diff -Naurp buildroot-2017.05-rc2/package/ola/ola.hash buildroot-2017.05.2/package/ola/ola.hash
7169 --- buildroot-2017.05-rc2/package/ola/ola.hash 2017-05-17 10:27:16.013401440 +0200
7170 +++ buildroot-2017.05.2/package/ola/ola.hash 1970-01-01 01:00:00.000000000 +0100
7171 @@ -1,2 +0,0 @@
7172 -# Locally calculated
7173 -sha256 986e61874bc80db3b23cf201af2dafa39e3412cc50cddf1cd449c869110bfd27 ola-0.10.2.tar.gz
7174 diff -Naurp buildroot-2017.05-rc2/package/ola/ola.mk buildroot-2017.05.2/package/ola/ola.mk
7175 --- buildroot-2017.05-rc2/package/ola/ola.mk 2017-05-17 10:27:16.013401440 +0200
7176 +++ buildroot-2017.05.2/package/ola/ola.mk 1970-01-01 01:00:00.000000000 +0100
7177 @@ -1,180 +0,0 @@
7178 -################################################################################
7180 -# ola
7182 -################################################################################
7184 -OLA_VERSION = 0.10.2
7185 -OLA_SITE = https://github.com/OpenLightingProject/ola/releases/download/$(OLA_VERSION)
7186 -OLA_LICENSE = LGPL-2.1+ (libola, libolacommon, Python bindings), GPL-2.0+ (libolaserver, olad, Python examples and tests)
7187 -OLA_LICENSE_FILES = LICENCE GPL LGPL
7188 -OLA_INSTALL_STAGING = YES
7189 -OLA_AUTORECONF = YES
7191 -# util-linux provides uuid lib
7192 -OLA_DEPENDENCIES = protobuf util-linux host-bison host-flex host-ola
7194 -OLA_CONF_OPTS = \
7195 - ac_cv_have_pymod_google_protobuf=yes \
7196 - --disable-gcov \
7197 - --disable-tcmalloc \
7198 - --disable-unittests \
7199 - --disable-root-check \
7200 - --disable-java-libs \
7201 - --disable-fatal-warnings \
7202 - --with-ola-protoc-plugin=$(HOST_DIR)/usr/bin/ola_protoc_plugin
7204 -HOST_OLA_DEPENDENCIES = host-util-linux host-protobuf
7206 -# When building the host part, disable as much as possible to speed up
7207 -# the configure step and avoid missing host dependencies.
7208 -HOST_OLA_CONF_OPTS = \
7209 - --disable-all-plugins \
7210 - --disable-slp \
7211 - --disable-osc \
7212 - --disable-uart \
7213 - --disable-libusb \
7214 - --disable-libftdi \
7215 - --disable-http \
7216 - --disable-examples \
7217 - --disable-unittests \
7218 - --disable-doxygen-html \
7219 - --disable-doxygen-doc \
7220 - --disable-fatal-warnings
7222 -# On the host side, we only need ola_protoc_plugin, so build and install this
7223 -# only.
7224 -HOST_OLA_MAKE_OPTS = protoc/ola_protoc_plugin
7225 -define HOST_OLA_INSTALL_CMDS
7226 - $(INSTALL) -D -m 0755 $(@D)/protoc/ola_protoc_plugin $(HOST_DIR)/usr/bin/ola_protoc_plugin
7227 -endef
7229 -# sets where to find python libs built for target and required by ola
7230 -OLA_CONF_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
7231 -OLA_MAKE_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
7233 -## OLA Bindings and Interface selections
7235 -ifeq ($(BR2_PACKAGE_OLA_WEB),y)
7236 -OLA_CONF_OPTS += --enable-http
7237 -OLA_DEPENDENCIES += libmicrohttpd
7238 -else
7239 -OLA_CONF_OPTS += --disable-http
7240 -endif
7242 -ifeq ($(BR2_PACKAGE_OLA_SLP),y)
7243 -OLA_CONF_OPTS += --enable-slp
7244 -else
7245 -OLA_CONF_OPTS += --disable-slp
7246 -endif
7248 -ifeq ($(BR2_PACKAGE_OLA_PYTHON_BINDINGS),y)
7249 -OLA_CONF_OPTS += --enable-python-libs
7250 -OLA_DEPENDENCIES += python python-protobuf
7251 -else
7252 -OLA_CONF_OPTS += --disable-python-libs
7253 -endif
7255 -## OLA Examples and Tests
7257 -ifeq ($(BR2_PACKAGE_OLA_EXAMPLES),y)
7258 -OLA_CONF_OPTS += --enable-examples
7259 -OLA_DEPENDENCIES += ncurses
7260 -else
7261 -OLA_CONF_OPTS += --disable-examples
7262 -endif
7264 -ifeq ($(BR2_PACKAGE_OLA_RDM_TESTS),y)
7265 -OLA_CONF_OPTS += --enable-rdm-tests
7266 -OLA_DEPENDENCIES += python-numpy
7267 -# needed as numpy builds some shared libraries and ola checks for
7268 -# numpy using a host python test program which fails with 'wrong ELF
7269 -# class'.
7270 -OLA_CONF_ENV = ac_cv_have_pymod_numpy=yes
7271 -else
7272 -OLA_CONF_OPTS += --disable-rdm-tests
7273 -endif
7275 -## OLA Plugin selections
7277 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_E131),y)
7278 -OLA_CONF_OPTS += --enable-e131
7279 -else
7280 -OLA_CONF_OPTS += --disable-e131
7281 -endif
7283 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_ARTNET),y)
7284 -OLA_CONF_OPTS += --enable-artnet
7285 -else
7286 -OLA_CONF_OPTS += --disable-artnet
7287 -endif
7289 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_OPENDMX),y)
7290 -OLA_CONF_OPTS += --enable-opendmx
7291 -else
7292 -OLA_CONF_OPTS += --disable-opendmx
7293 -endif
7295 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_DUMMY),y)
7296 -OLA_CONF_OPTS += --enable-dummy
7297 -else
7298 -OLA_CONF_OPTS += --disable-dummy
7299 -endif
7301 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_ESPNET),y)
7302 -OLA_CONF_OPTS += --enable-espnet
7303 -else
7304 -OLA_CONF_OPTS += --disable-espnet
7305 -endif
7307 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_KINET),y)
7308 -OLA_CONF_OPTS += --enable-kinet
7309 -else
7310 -OLA_CONF_OPTS += --disable-kinet
7311 -endif
7313 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_OSC),y)
7314 -OLA_CONF_OPTS += --enable-osc
7315 -OLA_DEPENDENCIES += liblo
7316 -else
7317 -OLA_CONF_OPTS += --disable-osc
7318 -endif
7320 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_MILINT),y)
7321 -OLA_CONF_OPTS += --enable-milinst
7322 -else
7323 -OLA_CONF_OPTS += --disable-milinst
7324 -endif
7326 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_PATHPORT),y)
7327 -OLA_CONF_OPTS += --enable-pathport
7328 -else
7329 -OLA_CONF_OPTS += --disable-pathport
7330 -endif
7332 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_SANDNET),y)
7333 -OLA_CONF_OPTS += --enable-sandnet
7334 -else
7335 -OLA_CONF_OPTS += --disable-sandnet
7336 -endif
7338 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_SHOWNET),y)
7339 -OLA_CONF_OPTS += --enable-shownet
7340 -else
7341 -OLA_CONF_OPTS += --disable-shownet
7342 -endif
7344 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_STAGEPROFI),y)
7345 -OLA_CONF_OPTS += --enable-stageprofi --enable-libusb
7346 -else
7347 -OLA_CONF_OPTS += --disable-stageprofi
7348 -endif
7350 -ifeq ($(BR2_PACKAGE_OLA_PLUGIN_USBPRO),y)
7351 -OLA_CONF_OPTS += --enable-usbpro --enable-libusb
7352 -else
7353 -OLA_CONF_OPTS += --disable-usbpro
7354 -endif
7356 -$(eval $(autotools-package))
7357 -$(eval $(host-autotools-package))
7358 diff -Naurp buildroot-2017.05-rc2/package/opencv/opencv.mk buildroot-2017.05.2/package/opencv/opencv.mk
7359 --- buildroot-2017.05-rc2/package/opencv/opencv.mk 2017-05-17 10:27:16.013401440 +0200
7360 +++ buildroot-2017.05.2/package/opencv/opencv.mk 2017-07-27 08:16:52.017486944 +0200
7361 @@ -192,7 +192,8 @@ OPENCV_CONF_OPTS += -DWITH_GTK=OFF
7362 endif
7364 ifeq ($(BR2_PACKAGE_OPENCV_WITH_JASPER),y)
7365 -OPENCV_CONF_OPTS += -DWITH_JASPER=ON
7366 +OPENCV_CONF_OPTS += -DWITH_JASPER=ON \
7367 + -DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -D__STDC_LIMIT_MACROS"
7368 OPENCV_DEPENDENCIES += jasper
7369 else
7370 OPENCV_CONF_OPTS += -DWITH_JASPER=OFF
7371 diff -Naurp buildroot-2017.05-rc2/package/openpowerlink/0004-FIX-use-contrib-getopt-only-on-Windows.patch buildroot-2017.05.2/package/openpowerlink/0004-FIX-use-contrib-getopt-only-on-Windows.patch
7372 --- buildroot-2017.05-rc2/package/openpowerlink/0004-FIX-use-contrib-getopt-only-on-Windows.patch 1970-01-01 01:00:00.000000000 +0100
7373 +++ buildroot-2017.05.2/package/openpowerlink/0004-FIX-use-contrib-getopt-only-on-Windows.patch 2017-07-27 08:16:52.017486944 +0200
7374 @@ -0,0 +1,102 @@
7375 +From d05273e65657d82e44fb7bd91a8fba0ba990ff2c Mon Sep 17 00:00:00 2001
7376 +From: Romain Naour <romain.naour@gmail.com>
7377 +Date: Sat, 27 May 2017 23:51:41 +0200
7378 +Subject: [PATCH] [FIX] use contrib getopt() only on Windows
7380 +Otherwise, contrib getopt will clash with the one from the libc when
7381 +building statically.
7383 +lib64/libc.a(getopt.os):(.data+0x8): multiple definition of `optind'
7384 +CMakeFiles/demo_mn_console.dir/__/__/contrib/getopt/getopt.c.o:(.data+0x8): first defined here
7385 +lib64/libc.a(getopt.os):(.data+0x4): multiple definition of `opterr'
7386 +CMakeFiles/demo_mn_console.dir/__/__/contrib/getopt/getopt.c.o:(.data+0xc): first defined here
7387 +/lib64/libc.a(getopt.os): In function `__GI_getopt':
7388 +getopt.c:(.text+0x76e): multiple definition of `getopt'
7390 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
7391 +---
7392 + apps/demo_cn_console/CMakeLists.txt | 2 +-
7393 + apps/demo_cn_console/src/main.c | 6 ++++++
7394 + apps/demo_mn_console/CMakeLists.txt | 2 +-
7395 + apps/demo_mn_console/src/main.c | 6 ++++++
7396 + 4 files changed, 14 insertions(+), 2 deletions(-)
7398 +diff --git a/apps/demo_cn_console/CMakeLists.txt b/apps/demo_cn_console/CMakeLists.txt
7399 +index a3a80bb..5733213 100644
7400 +--- a/apps/demo_cn_console/CMakeLists.txt
7401 ++++ b/apps/demo_cn_console/CMakeLists.txt
7402 +@@ -61,7 +61,6 @@ SET(DEMO_SOURCES
7403 + ${COMMON_SOURCE_DIR}/eventlog/eventlog.c
7404 + ${COMMON_SOURCE_DIR}/eventlog/eventlogstring.c
7405 + ${CONTRIB_SOURCE_DIR}/console/printlog.c
7406 +- ${CONTRIB_SOURCE_DIR}/getopt/getopt.c
7409 + INCLUDE_DIRECTORIES(
7410 +@@ -114,6 +113,7 @@ ENDIF (CFG_KERNEL_STACK_DIRECTLINK)
7411 + IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
7412 + include(linux.cmake)
7413 + ELSEIF(CMAKE_SYSTEM_NAME STREQUAL "Windows")
7414 ++ SET(DEMO_SOURCES ${DEMO_SOURCES} ${CONTRIB_SOURCE_DIR}/getopt/getopt.c)
7415 + include (windows.cmake)
7416 + ELSE()
7417 + MESSAGE(FATAL_ERROR "System ${CMAKE_SYSTEM_NAME} is not supported!")
7418 +diff --git a/apps/demo_cn_console/src/main.c b/apps/demo_cn_console/src/main.c
7419 +index c630586..9406473 100644
7420 +--- a/apps/demo_cn_console/src/main.c
7421 ++++ b/apps/demo_cn_console/src/main.c
7422 +@@ -50,7 +50,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
7424 + #include <system/system.h>
7425 + #include <obdcreate/obdcreate.h>
7427 ++#if (TARGET_SYSTEM == _WIN32_)
7428 + #include <getopt/getopt.h>
7429 ++#else
7430 ++#include <unistd.h>
7431 ++#endif
7433 + #include <console/console.h>
7434 + #include <eventlog/eventlog.h>
7436 +diff --git a/apps/demo_mn_console/CMakeLists.txt b/apps/demo_mn_console/CMakeLists.txt
7437 +index 9c3378c..a81c4b3 100644
7438 +--- a/apps/demo_mn_console/CMakeLists.txt
7439 ++++ b/apps/demo_mn_console/CMakeLists.txt
7440 +@@ -67,7 +67,6 @@ SET(DEMO_SOURCES
7441 + ${COMMON_SOURCE_DIR}/eventlog/eventlog.c
7442 + ${COMMON_SOURCE_DIR}/eventlog/eventlogstring.c
7443 + ${CONTRIB_SOURCE_DIR}/console/printlog.c
7444 +- ${CONTRIB_SOURCE_DIR}/getopt/getopt.c
7447 + INCLUDE_DIRECTORIES(
7448 +@@ -129,6 +128,7 @@ ENDIF()
7449 + IF(CMAKE_SYSTEM_NAME STREQUAL "Linux")
7450 + include(linux.cmake)
7451 + ELSEIF(CMAKE_SYSTEM_NAME STREQUAL "Windows")
7452 ++ SET(DEMO_SOURCES ${DEMO_SOURCES} ${CONTRIB_SOURCE_DIR}/getopt/getopt.c)
7453 + include (windows.cmake)
7454 + ELSE()
7455 + MESSAGE(FATAL_ERROR "System ${CMAKE_SYSTEM_NAME} is not supported!")
7456 +diff --git a/apps/demo_mn_console/src/main.c b/apps/demo_mn_console/src/main.c
7457 +index 12d9be0..194e446 100644
7458 +--- a/apps/demo_mn_console/src/main.c
7459 ++++ b/apps/demo_mn_console/src/main.c
7460 +@@ -50,7 +50,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
7462 + #include <system/system.h>
7463 + #include <obdcreate/obdcreate.h>
7465 ++#if (TARGET_SYSTEM == _WIN32_)
7466 + #include <getopt/getopt.h>
7467 ++#else
7468 ++#include <unistd.h>
7469 ++#endif
7471 + #include <console/console.h>
7472 + #include <eventlog/eventlog.h>
7474 +--
7475 +2.9.4
7477 diff -Naurp buildroot-2017.05-rc2/package/openpowerlink/0005-FIX-use-pcap-config-to-fix-static-linking-with-libpc.patch buildroot-2017.05.2/package/openpowerlink/0005-FIX-use-pcap-config-to-fix-static-linking-with-libpc.patch
7478 --- buildroot-2017.05-rc2/package/openpowerlink/0005-FIX-use-pcap-config-to-fix-static-linking-with-libpc.patch 1970-01-01 01:00:00.000000000 +0100
7479 +++ buildroot-2017.05.2/package/openpowerlink/0005-FIX-use-pcap-config-to-fix-static-linking-with-libpc.patch 2017-07-27 08:16:52.017486944 +0200
7480 @@ -0,0 +1,166 @@
7481 +From 406e1759dc6a4c18f6a38c3d7571aacb177487c6 Mon Sep 17 00:00:00 2001
7482 +From: Romain Naour <romain.naour@gmail.com>
7483 +Date: Sun, 28 May 2017 00:25:11 +0200
7484 +Subject: [PATCH] [FIX]: use pcap-config to fix static linking with libpcap
7486 +When linking demo_mn_console statically with pcap, the CMake build
7487 +system forget to link with other libraries linked with libpcap
7488 +(-lnl-genl-3 -lnl-3 -ldbus-1 -pthread).
7490 +[100%] Linking C executable demo_mn_console
7491 +lib64/libpcap.a(pcap-linux.o): In function nl80211_init': pcap-linux.c:(.text+0x41e): undefined reference tonl_socket_alloc'
7493 +To fix this, the build system could use pcap-config:
7494 +pcap-config --libs --static
7495 +-L/path/to/sysroot/usr/lib -lpcap -L/path/to/sysroot/usr/lib/.libs
7496 +-lnl-genl-3 -lnl-3 -L/path/to/sysroot/usr/lib -ldbus-1 -pthread
7498 +Fixes:
7499 +http://autobuild.buildroot.net/results/f43/f437d09ac6c689c911e1885b95da33b692f2cb3c
7500 +http://autobuild.buildroot.net/results/385/3859dc0f4de7e3284a96d5841f040f69f71842df
7501 +https://github.com/OpenAutomationTechnologies/openPOWERLINK_V2/issues/187
7503 +Signed-off-by: Romain Naour <romain.naour@gmail.com>
7504 +---
7505 + apps/demo_cn_console/linux.cmake | 20 ++++++++++++++++++++
7506 + apps/demo_mn_console/linux.cmake | 20 ++++++++++++++++++++
7507 + apps/demo_mn_qt/linux.cmake | 22 +++++++++++++++++++++-
7508 + drivers/linux/drv_daemon_pcap/CMakeLists.txt | 22 +++++++++++++++++++++-
7509 + 4 files changed, 82 insertions(+), 2 deletions(-)
7511 +diff --git a/apps/demo_cn_console/linux.cmake b/apps/demo_cn_console/linux.cmake
7512 +index 1c6f51c..7752917 100644
7513 +--- a/apps/demo_cn_console/linux.cmake
7514 ++++ b/apps/demo_cn_console/linux.cmake
7515 +@@ -46,8 +46,28 @@ SET (DEMO_ARCH_SOURCES
7516 + ################################################################################
7517 + # Set architecture specific libraries
7519 ++IF (NOT CFG_COMPILE_SHARED_LIBRARY)
7520 ++ SET(PCAP_CONFIG_OPTS --static)
7521 ++ENDIF()
7523 + IF (CFG_KERNEL_STACK_DIRECTLINK OR CFG_KERNEL_STACK_USERSPACE_DAEMON)
7525 ++find_program(PCAP_CONFIG NAMES pcap-config PATHS)
7527 ++if (PCAP_CONFIG)
7528 ++ message (STATUS "Looking for pcap-config... ${PCAP_CONFIG}")
7530 ++ execute_process (COMMAND ${PCAP_CONFIG} --libs ${PCAP_CONFIG_OPTS}
7531 ++ OUTPUT_VARIABLE PCAP_LDFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7532 ++ execute_process (COMMAND ${PCAP_CONFIG} --cflags ${PCAP_CONFIG_OPTS}
7533 ++ OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7535 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} ${PCAP_LDFLAGS})
7536 ++else (PCAP_CONFIG)
7537 ++ message (STATUS "pcap-config not found, using defaults...")
7538 + SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pcap)
7539 ++endif (PCAP_CONFIG)
7541 + ENDIF (CFG_KERNEL_STACK_DIRECTLINK OR CFG_KERNEL_STACK_USERSPACE_DAEMON)
7542 + SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pthread rt)
7544 +diff --git a/apps/demo_mn_console/linux.cmake b/apps/demo_mn_console/linux.cmake
7545 +index d24e4fc..5951dbf 100644
7546 +--- a/apps/demo_mn_console/linux.cmake
7547 ++++ b/apps/demo_mn_console/linux.cmake
7548 +@@ -46,8 +46,28 @@ SET (DEMO_ARCH_SOURCES
7549 + ################################################################################
7550 + # Set architecture specific libraries
7552 ++IF (NOT CFG_COMPILE_SHARED_LIBRARY)
7553 ++ SET(PCAP_CONFIG_OPTS --static)
7554 ++ENDIF()
7556 + IF (CFG_KERNEL_STACK_DIRECTLINK OR CFG_KERNEL_STACK_USERSPACE_DAEMON)
7558 ++find_program(PCAP_CONFIG NAMES pcap-config PATHS)
7560 ++if (PCAP_CONFIG)
7561 ++ message (STATUS "Looking for pcap-config... ${PCAP_CONFIG}")
7563 ++ execute_process (COMMAND ${PCAP_CONFIG} --libs ${PCAP_CONFIG_OPTS}
7564 ++ OUTPUT_VARIABLE PCAP_LDFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7565 ++ execute_process (COMMAND ${PCAP_CONFIG} --cflags ${PCAP_CONFIG_OPTS}
7566 ++ OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7568 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} ${PCAP_LDFLAGS})
7569 ++else (PCAP_CONFIG)
7570 ++ message (STATUS "pcap-config not found, using defaults...")
7571 + SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pcap)
7572 ++endif (PCAP_CONFIG)
7574 + ENDIF (CFG_KERNEL_STACK_DIRECTLINK OR CFG_KERNEL_STACK_USERSPACE_DAEMON)
7575 + SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pthread rt)
7577 +diff --git a/apps/demo_mn_qt/linux.cmake b/apps/demo_mn_qt/linux.cmake
7578 +index 6ed75ee..c69dbd9 100644
7579 +--- a/apps/demo_mn_qt/linux.cmake
7580 ++++ b/apps/demo_mn_qt/linux.cmake
7581 +@@ -37,8 +37,28 @@
7582 + ################################################################################
7583 + # Set architecture specific libraries
7585 ++IF (NOT CFG_COMPILE_SHARED_LIBRARY)
7586 ++ SET(PCAP_CONFIG_OPTS --static)
7587 ++ENDIF()
7589 + IF(CFG_KERNEL_STACK_DIRECTLINK OR CFG_KERNEL_STACK_USERSPACE_DAEMON)
7590 +- SET(ARCH_LIBRARIES ${ARCH_LIBRARIES} pcap)
7592 ++find_program(PCAP_CONFIG NAMES pcap-config PATHS)
7594 ++if (PCAP_CONFIG)
7595 ++ message (STATUS "Looking for pcap-config... ${PCAP_CONFIG}")
7597 ++ execute_process (COMMAND ${PCAP_CONFIG} --libs ${PCAP_CONFIG_OPTS}
7598 ++ OUTPUT_VARIABLE PCAP_LDFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7599 ++ execute_process (COMMAND ${PCAP_CONFIG} --cflags ${PCAP_CONFIG_OPTS}
7600 ++ OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7602 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} ${PCAP_LDFLAGS})
7603 ++else (PCAP_CONFIG)
7604 ++ message (STATUS "pcap-config not found, using defaults...")
7605 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pcap)
7606 ++endif (PCAP_CONFIG)
7608 + ENDIF()
7609 + SET(ARCH_LIBRARIES ${ARCH_LIBRARIES} pthread rt)
7611 +diff --git a/drivers/linux/drv_daemon_pcap/CMakeLists.txt b/drivers/linux/drv_daemon_pcap/CMakeLists.txt
7612 +index 2b4a2c1..98f693f 100644
7613 +--- a/drivers/linux/drv_daemon_pcap/CMakeLists.txt
7614 ++++ b/drivers/linux/drv_daemon_pcap/CMakeLists.txt
7615 +@@ -134,7 +134,27 @@ INCLUDE_DIRECTORIES(
7616 + ${CONTRIB_SOURCE_DIR}
7619 +-SET (ARCH_LIBRARIES pcap pthread rt)
7620 ++IF (NOT CFG_COMPILE_SHARED_LIBRARY)
7621 ++ SET(PCAP_CONFIG_OPTS --static)
7622 ++ENDIF()
7624 ++find_program(PCAP_CONFIG NAMES pcap-config PATHS)
7626 ++if (PCAP_CONFIG)
7627 ++ message (STATUS "Looking for pcap-config... ${PCAP_CONFIG}")
7629 ++ execute_process (COMMAND ${PCAP_CONFIG} --libs ${PCAP_CONFIG_OPTS}
7630 ++ OUTPUT_VARIABLE PCAP_LDFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7631 ++ execute_process (COMMAND ${PCAP_CONFIG} --cflags ${PCAP_CONFIG_OPTS}
7632 ++ OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE)
7634 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} ${PCAP_LDFLAGS})
7635 ++else (PCAP_CONFIG)
7636 ++ message (STATUS "pcap-config not found, using defaults...")
7637 ++ SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pcap)
7638 ++endif (PCAP_CONFIG)
7640 ++SET (ARCH_LIBRARIES ${ARCH_LIBRARIES} pthread rt)
7642 + ADD_EXECUTABLE(${EXE_NAME} ${DRV_SOURCES})
7643 + SET_PROPERTY(TARGET ${EXE_NAME} PROPERTY COMPILE_DEFINITIONS_DEBUG DEBUG;DEF_DEBUG_LVL=${CFG_DEBUG_LVL})
7644 +--
7645 +2.9.4
7647 diff -Naurp buildroot-2017.05-rc2/package/openpowerlink/openpowerlink.mk buildroot-2017.05.2/package/openpowerlink/openpowerlink.mk
7648 --- buildroot-2017.05-rc2/package/openpowerlink/openpowerlink.mk 2017-05-17 10:27:16.013401440 +0200
7649 +++ buildroot-2017.05.2/package/openpowerlink/openpowerlink.mk 2017-07-27 08:16:52.017486944 +0200
7650 @@ -40,7 +40,8 @@ OPENPOWERLINK_CONF_OPTS += \
7651 -DCFG_COMPILE_LIB_CN=$(OPENPOWERLINK_CN_ONOFF) \
7652 -DCFG_COMPILE_LIB_CNAPP_USERINTF=OFF \
7653 -DCFG_COMPILE_LIB_CNAPP_KERNELINTF=OFF \
7654 - -DCFG_COMPILE_LIB_CNDRV_PCAP=OFF
7655 + -DCFG_COMPILE_LIB_CNDRV_PCAP=OFF \
7656 + -DPCAP_CONFIG="$(STAGING_DIR)/usr/bin/pcap-config"
7657 else ifeq ($(BR2_PACKAGE_OPENPOWERLINK_STACK_USERSPACE_DAEMON_LIB),y)
7658 OPENPOWERLINK_DEPENDENCIES += libpcap
7659 OPENPOWERLINK_CONF_OPTS += \
7660 @@ -52,7 +53,8 @@ OPENPOWERLINK_CONF_OPTS += \
7661 -DCFG_COMPILE_LIB_CN=OFF \
7662 -DCFG_COMPILE_LIB_CNAPP_USERINTF=$(OPENPOWERLINK_CN_ONOFF) \
7663 -DCFG_COMPILE_LIB_CNAPP_KERNELINTF=OFF \
7664 - -DCFG_COMPILE_LIB_CNDRV_PCAP=$(OPENPOWERLINK_CN_ONOFF)
7665 + -DCFG_COMPILE_LIB_CNDRV_PCAP=$(OPENPOWERLINK_CN_ONOFF) \
7666 + -DPCAP_CONFIG="$(STAGING_DIR)/usr/bin/pcap-config"
7667 else ifeq ($(BR2_PACKAGE_OPENPOWERLINK_STACK_KERNEL_STACK_LIB),y)
7668 OPENPOWERLINK_CONF_OPTS += \
7669 -DCFG_COMPILE_LIB_MN=OFF \
7670 diff -Naurp buildroot-2017.05-rc2/package/openssh/openssh.hash buildroot-2017.05.2/package/openssh/openssh.hash
7671 --- buildroot-2017.05-rc2/package/openssh/openssh.hash 2017-05-17 10:27:16.013401440 +0200
7672 +++ buildroot-2017.05.2/package/openssh/openssh.hash 2017-07-27 08:16:52.017486944 +0200
7673 @@ -1,2 +1,4 @@
7674 # From http://www.openssh.com/txt/release-7.5 (base64 encoded)
7675 sha256 9846e3c5fab9f0547400b4d2c017992f914222b3fd1f8eee6c7dc6bc5e59f9f0 openssh-7.5p1.tar.gz
7676 +sha256 310860606c4175cdfd095e724f624df27340c89a916f7a09300bcb7988d5cfbf afc3e31b637db9dae106d4fad78f7b481c8c24e3.patch
7677 +sha256 395aa1006967713b599555440e09f898781a5559e496223587401768ece10904 f4fcd8c788a4854d4ebae400cf55e3957f906835.patch
7678 diff -Naurp buildroot-2017.05-rc2/package/openssh/openssh.mk buildroot-2017.05.2/package/openssh/openssh.mk
7679 --- buildroot-2017.05-rc2/package/openssh/openssh.mk 2017-05-17 10:27:16.013401440 +0200
7680 +++ buildroot-2017.05.2/package/openssh/openssh.mk 2017-07-27 08:16:52.017486944 +0200
7681 @@ -8,6 +8,12 @@ OPENSSH_VERSION = 7.5p1
7682 OPENSSH_SITE = http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable
7683 OPENSSH_LICENSE = BSD-3-Clause, BSD-2-Clause, Public Domain
7684 OPENSSH_LICENSE_FILES = LICENCE
7685 +# Autoreconf needed due to the following patches modifying configure.ac:
7686 +# f4fcd8c788a4854d4ebae400cf55e3957f906835.patch
7687 +# afc3e31b637db9dae106d4fad78f7b481c8c24e3.patch
7688 +OPENSSH_AUTORECONF = YES
7689 +OPENSSH_PATCH = https://github.com/openssh/openssh-portable/commit/f4fcd8c788a4854d4ebae400cf55e3957f906835.patch \
7690 + https://github.com/openssh/openssh-portable/commit/afc3e31b637db9dae106d4fad78f7b481c8c24e3.patch
7691 OPENSSH_CONF_ENV = LD="$(TARGET_CC)" LDFLAGS="$(TARGET_CFLAGS)"
7692 OPENSSH_CONF_OPTS = \
7693 --sysconfdir=/etc/ssh \
7694 diff -Naurp buildroot-2017.05-rc2/package/openvpn/openvpn.hash buildroot-2017.05.2/package/openvpn/openvpn.hash
7695 --- buildroot-2017.05-rc2/package/openvpn/openvpn.hash 2017-05-17 10:27:16.013401440 +0200
7696 +++ buildroot-2017.05.2/package/openvpn/openvpn.hash 2017-07-27 08:16:52.017486944 +0200
7697 @@ -1,2 +1,2 @@
7698 -# Locally calculated
7699 -sha256 df5c4f384b7df6b08a2f6fa8a84b9fd382baf59c2cef1836f82e2a7f62f1bff9 openvpn-2.4.2.tar.xz
7700 +# Locally calculated after checking signature
7701 +sha256 15e15fc97f189b52aee7c90ec8355aa77469c773125110b4c2f089abecde36fb openvpn-2.4.3.tar.xz
7702 diff -Naurp buildroot-2017.05-rc2/package/openvpn/openvpn.mk buildroot-2017.05.2/package/openvpn/openvpn.mk
7703 --- buildroot-2017.05-rc2/package/openvpn/openvpn.mk 2017-05-17 10:27:16.013401440 +0200
7704 +++ buildroot-2017.05.2/package/openvpn/openvpn.mk 2017-07-27 08:16:52.017486944 +0200
7705 @@ -4,7 +4,7 @@
7707 ################################################################################
7709 -OPENVPN_VERSION = 2.4.2
7710 +OPENVPN_VERSION = 2.4.3
7711 OPENVPN_SOURCE = openvpn-$(OPENVPN_VERSION).tar.xz
7712 OPENVPN_SITE = http://swupdate.openvpn.net/community/releases
7713 OPENVPN_DEPENDENCIES = host-pkgconf openssl
7714 diff -Naurp buildroot-2017.05-rc2/package/oracle-mysql/0008-fix-type-conversion.patch buildroot-2017.05.2/package/oracle-mysql/0008-fix-type-conversion.patch
7715 --- buildroot-2017.05-rc2/package/oracle-mysql/0008-fix-type-conversion.patch 1970-01-01 01:00:00.000000000 +0100
7716 +++ buildroot-2017.05.2/package/oracle-mysql/0008-fix-type-conversion.patch 2017-07-27 08:16:52.017486944 +0200
7717 @@ -0,0 +1,22 @@
7718 +Fix type conversion
7720 +Fixes the following build error with gcc 6.x:
7722 +protocol.cc:27:40: error: narrowing conversion of ''\37777777776'' from 'char' to 'uchar {aka unsigned char}' inside { } [-Wnarrowing]
7723 + static uchar eof_buff[1]= { (char) 254 }; /* Marker for end of fields */
7725 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7727 +Index: b/server-tools/instance-manager/protocol.cc
7728 +===================================================================
7729 +--- a/server-tools/instance-manager/protocol.cc
7730 ++++ b/server-tools/instance-manager/protocol.cc
7731 +@@ -24,7 +24,7 @@
7732 + #include <m_string.h>
7735 +-static uchar eof_buff[1]= { (char) 254 }; /* Marker for end of fields */
7736 ++static uchar eof_buff[1]= { (uchar) 254 }; /* Marker for end of fields */
7737 + static const char ERROR_PACKET_CODE= (char) 255;
7740 diff -Naurp buildroot-2017.05-rc2/package/orc/Config.in buildroot-2017.05.2/package/orc/Config.in
7741 --- buildroot-2017.05-rc2/package/orc/Config.in 2017-05-17 10:27:16.013401440 +0200
7742 +++ buildroot-2017.05.2/package/orc/Config.in 2017-07-27 08:16:52.017486944 +0200
7743 @@ -6,7 +6,7 @@ config BR2_PACKAGE_ORC
7744 Orc is a library and set of tools for compiling and executing
7745 very simple programs that operate on arrays of data.
7747 - http://code.entropywave.com/projects/orc/
7748 + https://gstreamer.freedesktop.org/projects/orc.html
7750 comment "orc needs a toolchain w/ threads"
7751 depends on !BR2_TOOLCHAIN_HAS_THREADS
7752 diff -Naurp buildroot-2017.05-rc2/package/pcre/0003-CVE-2017-6004.patch buildroot-2017.05.2/package/pcre/0003-CVE-2017-6004.patch
7753 --- buildroot-2017.05-rc2/package/pcre/0003-CVE-2017-6004.patch 2017-05-17 10:27:16.013401440 +0200
7754 +++ buildroot-2017.05.2/package/pcre/0003-CVE-2017-6004.patch 1970-01-01 01:00:00.000000000 +0100
7755 @@ -1,21 +0,0 @@
7756 -Description: CVE-2017-6004: crafted regular expression may cause denial of service
7757 -Origin: upstream, https://vcs.pcre.org/pcre/code/trunk/pcre_jit_compile.c?r1=1676&r2=1680&view=patch
7758 -Bug: https://bugs.exim.org/show_bug.cgi?id=2035
7759 -Bug-Debian: https://bugs.debian.org/855405
7760 -Forwarded: not-needed
7761 -Author: Salvatore Bonaccorso <carnil@debian.org>
7762 -Last-Update: 2017-02-17
7764 -Signed-off-by: Baruch Siach <baruch@tkos.co.il>
7766 ---- a/pcre_jit_compile.c
7767 -+++ b/pcre_jit_compile.c
7768 -@@ -8111,7 +8111,7 @@ if (opcode == OP_COND || opcode == OP_SC
7770 - if (*matchingpath == OP_FAIL)
7771 - stacksize = 0;
7772 -- if (*matchingpath == OP_RREF)
7773 -+ else if (*matchingpath == OP_RREF)
7775 - stacksize = GET2(matchingpath, 1);
7776 - if (common->currententry == NULL)
7777 diff -Naurp buildroot-2017.05-rc2/package/pcre/0004-CVE-2017-7186.patch buildroot-2017.05.2/package/pcre/0004-CVE-2017-7186.patch
7778 --- buildroot-2017.05-rc2/package/pcre/0004-CVE-2017-7186.patch 2017-05-17 10:27:16.013401440 +0200
7779 +++ buildroot-2017.05.2/package/pcre/0004-CVE-2017-7186.patch 1970-01-01 01:00:00.000000000 +0100
7780 @@ -1,60 +0,0 @@
7781 -Description: Upstream fix for CVE-2017-7186 (Upstream rev 1688)
7782 - Fix Unicode property crash for 32-bit characters greater than 0x10ffff.
7783 -Author: Matthew Vernon <matthew@debian.org>
7784 -X-Dgit-Generated: 2:8.39-3 c4c2c7c4f74d53b263af2471d8e11db88096bd13
7786 -Signed-off-by: Baruch Siach <baruch@tkos.co.il>
7787 ----
7789 ---- pcre3-8.39.orig/pcre_internal.h
7790 -+++ pcre3-8.39/pcre_internal.h
7791 -@@ -2772,6 +2772,9 @@ extern const pcre_uint8 PRIV(ucd_stage1
7792 - extern const pcre_uint16 PRIV(ucd_stage2)[];
7793 - extern const pcre_uint32 PRIV(ucp_gentype)[];
7794 - extern const pcre_uint32 PRIV(ucp_gbtable)[];
7795 -+#ifdef COMPILE_PCRE32
7796 -+extern const ucd_record PRIV(dummy_ucd_record)[];
7797 -+#endif
7798 - #ifdef SUPPORT_JIT
7799 - extern const int PRIV(ucp_typerange)[];
7800 - #endif
7801 -@@ -2780,9 +2783,15 @@ extern const int PRIV(ucp_typera
7802 - /* UCD access macros */
7804 - #define UCD_BLOCK_SIZE 128
7805 --#define GET_UCD(ch) (PRIV(ucd_records) + \
7806 -+#define REAL_GET_UCD(ch) (PRIV(ucd_records) + \
7807 - PRIV(ucd_stage2)[PRIV(ucd_stage1)[(int)(ch) / UCD_BLOCK_SIZE] * \
7808 - UCD_BLOCK_SIZE + (int)(ch) % UCD_BLOCK_SIZE])
7810 -+#ifdef COMPILE_PCRE32
7811 -+#define GET_UCD(ch) ((ch > 0x10ffff)? PRIV(dummy_ucd_record) : REAL_GET_UCD(ch))
7812 -+#else
7813 -+#define GET_UCD(ch) REAL_GET_UCD(ch)
7814 -+#endif
7816 - #define UCD_CHARTYPE(ch) GET_UCD(ch)->chartype
7817 - #define UCD_SCRIPT(ch) GET_UCD(ch)->script
7818 ---- pcre3-8.39.orig/pcre_ucd.c
7819 -+++ pcre3-8.39/pcre_ucd.c
7820 -@@ -38,6 +38,20 @@ const pcre_uint16 PRIV(ucd_stage2)[] = {
7821 - const pcre_uint32 PRIV(ucd_caseless_sets)[] = {0};
7822 - #else
7824 -+/* If the 32-bit library is run in non-32-bit mode, character values
7825 -+greater than 0x10ffff may be encountered. For these we set up a
7826 -+special record. */
7828 -+#ifdef COMPILE_PCRE32
7829 -+const ucd_record PRIV(dummy_ucd_record)[] = {{
7830 -+ ucp_Common, /* script */
7831 -+ ucp_Cn, /* type unassigned */
7832 -+ ucp_gbOther, /* grapheme break property */
7833 -+ 0, /* case set */
7834 -+ 0, /* other case */
7835 -+ }};
7836 -+#endif
7838 - /* When recompiling tables with a new Unicode version, please check the
7839 - types in this structure definition from pcre_internal.h (the actual
7840 - field names will be different):
7841 diff -Naurp buildroot-2017.05-rc2/package/pcre/pcre.hash buildroot-2017.05.2/package/pcre/pcre.hash
7842 --- buildroot-2017.05-rc2/package/pcre/pcre.hash 2017-05-17 10:27:16.013401440 +0200
7843 +++ buildroot-2017.05.2/package/pcre/pcre.hash 2017-07-27 08:16:52.017486944 +0200
7844 @@ -1,2 +1,2 @@
7845 # Locally calculated after checking pgp signature
7846 -sha256 00e27a29ead4267e3de8111fcaa59b132d0533cdfdbdddf4b0604279acbcf4f4 pcre-8.40.tar.bz2
7847 +sha256 e62c7eac5ae7c0e7286db61ff82912e1c0b7a0c13706616e94a7dd729321b530 pcre-8.41.tar.bz2
7848 diff -Naurp buildroot-2017.05-rc2/package/pcre/pcre.mk buildroot-2017.05.2/package/pcre/pcre.mk
7849 --- buildroot-2017.05-rc2/package/pcre/pcre.mk 2017-05-17 10:27:16.013401440 +0200
7850 +++ buildroot-2017.05.2/package/pcre/pcre.mk 2017-07-27 08:16:52.017486944 +0200
7851 @@ -4,7 +4,7 @@
7853 ################################################################################
7855 -PCRE_VERSION = 8.40
7856 +PCRE_VERSION = 8.41
7857 PCRE_SITE = https://ftp.pcre.org/pub/pcre
7858 PCRE_SOURCE = pcre-$(PCRE_VERSION).tar.bz2
7859 PCRE_LICENSE = BSD-3-Clause
7860 diff -Naurp buildroot-2017.05-rc2/package/php/php.hash buildroot-2017.05.2/package/php/php.hash
7861 --- buildroot-2017.05-rc2/package/php/php.hash 2017-05-17 10:27:16.013401440 +0200
7862 +++ buildroot-2017.05.2/package/php/php.hash 2017-07-27 08:16:52.017486944 +0200
7863 @@ -1,2 +1,5 @@
7864 # From http://php.net/downloads.php
7865 -sha256 d149a3c396c45611f5dc6bf14be190f464897145a76a8e5851cf18ff7094f6ac php-7.1.5.tar.xz
7866 +sha256 0d42089729be7b2bb0308cbe189c2782f9cb4b07078c8a235495be5874fff729 php-7.1.7.tar.xz
7868 +# License file
7869 +sha256 a44951f93b10c87c3f7cd9f311d95999c57c95ed950eec32b14c1c7ea6baf25e LICENSE
7870 diff -Naurp buildroot-2017.05-rc2/package/php/php.mk buildroot-2017.05.2/package/php/php.mk
7871 --- buildroot-2017.05-rc2/package/php/php.mk 2017-05-17 10:27:16.013401440 +0200
7872 +++ buildroot-2017.05.2/package/php/php.mk 2017-07-27 08:16:52.017486944 +0200
7873 @@ -4,7 +4,7 @@
7875 ################################################################################
7877 -PHP_VERSION = 7.1.5
7878 +PHP_VERSION = 7.1.7
7879 PHP_SITE = http://www.php.net/distributions
7880 PHP_SOURCE = php-$(PHP_VERSION).tar.xz
7881 PHP_INSTALL_STAGING = YES
7882 diff -Naurp buildroot-2017.05-rc2/package/pngquant/pngquant.mk buildroot-2017.05.2/package/pngquant/pngquant.mk
7883 --- buildroot-2017.05-rc2/package/pngquant/pngquant.mk 2017-05-17 10:27:16.013401440 +0200
7884 +++ buildroot-2017.05.2/package/pngquant/pngquant.mk 2017-07-27 08:16:52.017486944 +0200
7885 @@ -36,6 +36,7 @@ endef
7886 define HOST_PNGQUANT_CONFIGURE_CMDS
7887 (cd $(@D) && \
7888 $(HOST_CONFIGURE_OPTS) \
7889 + CC=$(HOSTCC_NOCCACHE) \
7890 ./configure --prefix=$(HOST_DIR)/usr \
7891 --without-lcms2 \
7893 diff -Naurp buildroot-2017.05-rc2/package/popt/popt.mk buildroot-2017.05.2/package/popt/popt.mk
7894 --- buildroot-2017.05-rc2/package/popt/popt.mk 2017-05-17 10:27:16.013401440 +0200
7895 +++ buildroot-2017.05.2/package/popt/popt.mk 2017-07-27 08:16:52.017486944 +0200
7896 @@ -21,6 +21,7 @@ POPT_CONF_ENV = ac_cv_va_copy=yes
7897 ifeq ($(BR2_PACKAGE_LIBICONV),y)
7898 POPT_CONF_ENV += am_cv_lib_iconv=yes
7899 POPT_CONF_OPTS += --with-libiconv-prefix=$(STAGING_DIR)/usr
7900 +POPT_DEPENDENCIES += libiconv
7901 endif
7903 $(eval $(autotools-package))
7904 diff -Naurp buildroot-2017.05-rc2/package/protobuf/0001-Fix-freebsd-build.patch buildroot-2017.05.2/package/protobuf/0001-Fix-freebsd-build.patch
7905 --- buildroot-2017.05-rc2/package/protobuf/0001-Fix-freebsd-build.patch 1970-01-01 01:00:00.000000000 +0100
7906 +++ buildroot-2017.05.2/package/protobuf/0001-Fix-freebsd-build.patch 2017-07-27 08:16:52.017486944 +0200
7907 @@ -0,0 +1,145 @@
7908 +From 416f90939d4de58fe1a4e2489120010313183291 Mon Sep 17 00:00:00 2001
7909 +From: Feng Xiao <xfxyjwf@gmail.com>
7910 +Date: Tue, 14 Mar 2017 23:12:52 +0000
7911 +Subject: [PATCH] Fix freebsd build.
7913 +It turns out system headers included by generated plugin.pb.h file already contains
7914 +major/minor macro definitions when built on FreeBSD and we need to add #undefs to
7915 +the generated header file.
7917 +This change also fixes another compile error regarding EXPECT_DEATH on FreeBSD.
7919 +Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
7920 +---
7921 + src/google/protobuf/compiler/cpp/cpp_file.cc | 46 +++++++++++++++++++++++
7922 + src/google/protobuf/compiler/cpp/cpp_file.h | 9 +++++
7923 + src/google/protobuf/compiler/plugin.pb.h | 6 +++
7924 + src/google/protobuf/stubs/stringpiece_unittest.cc | 2 +
7925 + 4 files changed, 63 insertions(+)
7927 +diff --git a/src/google/protobuf/compiler/cpp/cpp_file.cc b/src/google/protobuf/compiler/cpp/cpp_file.cc
7928 +index 0e5e2f1..f2e013c 100644
7929 +--- a/src/google/protobuf/compiler/cpp/cpp_file.cc
7930 ++++ b/src/google/protobuf/compiler/cpp/cpp_file.cc
7931 +@@ -54,6 +54,39 @@ namespace google {
7932 + namespace protobuf {
7933 + namespace compiler {
7934 + namespace cpp {
7935 ++namespace {
7936 ++// The list of names that are defined as macros on some platforms. We need to
7937 ++// #undef them for the generated code to compile.
7938 ++const char* kMacroNames[] = {"major", "minor"};
7940 ++bool IsMacroName(const string& name) {
7941 ++ // Just do a linear search as the number of elements is very small.
7942 ++ for (int i = 0; i < GOOGLE_ARRAYSIZE(kMacroNames); ++i) {
7943 ++ if (name == kMacroNames[i]) return true;
7944 ++ }
7945 ++ return false;
7948 ++void CollectMacroNames(const Descriptor* message, vector<string>* names) {
7949 ++ for (int i = 0; i < message->field_count(); ++i) {
7950 ++ const FieldDescriptor* field = message->field(i);
7951 ++ if (IsMacroName(field->name())) {
7952 ++ names->push_back(field->name());
7953 ++ }
7954 ++ }
7955 ++ for (int i = 0; i < message->nested_type_count(); ++i) {
7956 ++ CollectMacroNames(message->nested_type(i), names);
7957 ++ }
7960 ++void CollectMacroNames(const FileDescriptor* file, vector<string>* names) {
7961 ++ for (int i = 0; i < file->message_type_count(); ++i) {
7962 ++ CollectMacroNames(file->message_type(i), names);
7963 ++ }
7967 ++} // namespace
7969 + // ===================================================================
7971 +@@ -103,10 +136,23 @@ FileGenerator::FileGenerator(const FileDescriptor* file, const Options& options)
7973 + FileGenerator::~FileGenerator() {}
7975 ++void FileGenerator::GenerateMacroUndefs(io::Printer* printer) {
7976 ++ vector<string> names_to_undef;
7977 ++ CollectMacroNames(file_, &names_to_undef);
7978 ++ for (int i = 0; i < names_to_undef.size(); ++i) {
7979 ++ printer->Print(
7980 ++ "#ifdef $name$\n"
7981 ++ "#undef $name$\n"
7982 ++ "#endif\n",
7983 ++ "name", names_to_undef[i]);
7984 ++ }
7987 + void FileGenerator::GenerateHeader(io::Printer* printer) {
7988 + printer->Print(
7989 + "// @@protoc_insertion_point(includes)\n");
7991 ++ GenerateMacroUndefs(printer);
7993 + GenerateForwardDeclarations(printer);
7995 +diff --git a/src/google/protobuf/compiler/cpp/cpp_file.h b/src/google/protobuf/compiler/cpp/cpp_file.h
7996 +index 25d6eab..e3fbb96 100644
7997 +--- a/src/google/protobuf/compiler/cpp/cpp_file.h
7998 ++++ b/src/google/protobuf/compiler/cpp/cpp_file.h
7999 +@@ -133,6 +133,15 @@ class FileGenerator {
8001 + void GenerateProto2NamespaceEnumSpecializations(io::Printer* printer);
8003 ++ // Sometimes the names we use in a .proto file happen to be defined as macros
8004 ++ // on some platforms (e.g., macro/minor used in plugin.proto are defined as
8005 ++ // macros in sys/types.h on FreeBSD and a few other platforms). To make the
8006 ++ // generated code compile on these platforms, we either have to undef the
8007 ++ // macro for these few platforms, or rename the field name for all platforms.
8008 ++ // Since these names are part of protobuf public API, renaming is generally
8009 ++ // a breaking change so we prefer the #undef approach.
8010 ++ void GenerateMacroUndefs(io::Printer* printer);
8012 + const FileDescriptor* file_;
8013 + const Options options_;
8015 +diff --git a/src/google/protobuf/compiler/plugin.pb.h b/src/google/protobuf/compiler/plugin.pb.h
8016 +index 1b91dac..d6afb21 100644
8017 +--- a/src/google/protobuf/compiler/plugin.pb.h
8018 ++++ b/src/google/protobuf/compiler/plugin.pb.h
8019 +@@ -30,6 +30,12 @@
8020 + #include <google/protobuf/unknown_field_set.h>
8021 + #include <google/protobuf/descriptor.pb.h>
8022 + // @@protoc_insertion_point(includes)
8023 ++#ifdef major
8024 ++#undef major
8025 ++#endif
8026 ++#ifdef minor
8027 ++#undef minor
8028 ++#endif
8029 + namespace google {
8030 + namespace protobuf {
8031 + class DescriptorProto;
8032 +diff --git a/src/google/protobuf/stubs/stringpiece_unittest.cc b/src/google/protobuf/stubs/stringpiece_unittest.cc
8033 +index a52d81f..a6a8759 100644
8034 +--- a/src/google/protobuf/stubs/stringpiece_unittest.cc
8035 ++++ b/src/google/protobuf/stubs/stringpiece_unittest.cc
8036 +@@ -783,11 +783,13 @@ TEST(FindOneCharTest, EdgeCases) {
8037 + EXPECT_EQ(StringPiece::npos, a.rfind('x'));
8040 ++#ifdef PROTOBUF_HAS_DEATH_TEST
8041 + #ifndef NDEBUG
8042 + TEST(NonNegativeLenTest, NonNegativeLen) {
8043 + EXPECT_DEATH(StringPiece("xyz", -1), "len >= 0");
8045 + #endif // ndef DEBUG
8046 ++#endif // PROTOBUF_HAS_DEATH_TEST
8048 + } // namespace
8049 + } // namespace protobuf
8050 +--
8051 +2.7.5
8053 diff -Naurp buildroot-2017.05-rc2/package/protobuf/protobuf.hash buildroot-2017.05.2/package/protobuf/protobuf.hash
8054 --- buildroot-2017.05-rc2/package/protobuf/protobuf.hash 2017-05-17 10:27:16.013401440 +0200
8055 +++ buildroot-2017.05.2/package/protobuf/protobuf.hash 2017-07-27 08:16:52.017486944 +0200
8056 @@ -1,3 +1,2 @@
8057 # Locally calculated
8058 sha256 51d773e4297238b282eaa4c1dd317099675b12eef2b414732b851c00459225c6 protobuf-cpp-3.2.0.tar.gz
8059 -sha256 da80c39838515913633f4cbd875fdd4ad711be95c83a50ff5096b9f1254033b3 416f90939d4de58fe1a4e2489120010313183291.patch
8060 diff -Naurp buildroot-2017.05-rc2/package/protobuf/protobuf.mk buildroot-2017.05.2/package/protobuf/protobuf.mk
8061 --- buildroot-2017.05-rc2/package/protobuf/protobuf.mk 2017-05-17 10:27:16.013401440 +0200
8062 +++ buildroot-2017.05.2/package/protobuf/protobuf.mk 2017-07-27 08:16:52.017486944 +0200
8063 @@ -23,8 +23,6 @@ endif
8065 PROTOBUF_INSTALL_STAGING = YES
8067 -PROTOBUF_PATCH = https://github.com/google/protobuf/commit/416f90939d4de58fe1a4e2489120010313183291.patch
8069 ifeq ($(BR2_PACKAGE_ZLIB),y)
8070 PROTOBUF_DEPENDENCIES += zlib
8071 endif
8072 diff -Naurp buildroot-2017.05-rc2/package/pulseaudio/pulseaudio.mk buildroot-2017.05.2/package/pulseaudio/pulseaudio.mk
8073 --- buildroot-2017.05-rc2/package/pulseaudio/pulseaudio.mk 2017-05-17 10:27:16.013401440 +0200
8074 +++ buildroot-2017.05.2/package/pulseaudio/pulseaudio.mk 2017-07-27 08:16:52.017486944 +0200
8075 @@ -32,6 +32,7 @@ PULSEAUDIO_DEPENDENCIES = \
8076 $(if $(BR2_PACKAGE_AVAHI_DAEMON),avahi) \
8077 $(if $(BR2_PACKAGE_DBUS),dbus) \
8078 $(if $(BR2_PACKAGE_BLUEZ_UTILS),bluez_utils) \
8079 + $(if $(BR2_PACKAGE_BLUEZ5_UTILS),bluez5_utils) \
8080 $(if $(BR2_PACKAGE_OPENSSL),openssl) \
8081 $(if $(BR2_PACKAGE_FFTW),fftw) \
8082 $(if $(BR2_PACKAGE_SYSTEMD),systemd)
8083 @@ -121,8 +122,6 @@ ifneq ($(BR2_ENABLE_LOCALE),y)
8084 define PULSEAUDIO_FIXUP_DESKTOP_FILES
8085 cp $(@D)/src/daemon/pulseaudio.desktop.in \
8086 $(@D)/src/daemon/pulseaudio.desktop
8087 - cp $(@D)/src/daemon/pulseaudio-kde.desktop.in \
8088 - $(@D)/src/daemon/pulseaudio-kde.desktop
8089 endef
8090 PULSEAUDIO_POST_PATCH_HOOKS += PULSEAUDIO_FIXUP_DESKTOP_FILES
8091 endif
8092 diff -Naurp buildroot-2017.05-rc2/package/pulseview/0003-CMakeLists.txt-Avoid-fext-numeric-literals-not-suppo.patch buildroot-2017.05.2/package/pulseview/0003-CMakeLists.txt-Avoid-fext-numeric-literals-not-suppo.patch
8093 --- buildroot-2017.05-rc2/package/pulseview/0003-CMakeLists.txt-Avoid-fext-numeric-literals-not-suppo.patch 1970-01-01 01:00:00.000000000 +0100
8094 +++ buildroot-2017.05.2/package/pulseview/0003-CMakeLists.txt-Avoid-fext-numeric-literals-not-suppo.patch 2017-07-27 08:16:52.017486944 +0200
8095 @@ -0,0 +1,28 @@
8096 +From 6ad4d7a6f17edecc3523a7ab3d627f9a70dbacc1 Mon Sep 17 00:00:00 2001
8097 +From: Uwe Hermann <uwe@hermann-uwe.de>
8098 +Date: Wed, 17 May 2017 11:00:44 +0200
8099 +Subject: [PATCH] CMakeLists.txt: Avoid -fext-numeric-literals, (not supported
8100 + by clang).
8102 +This (re-)fixes bug #863.
8104 +Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
8105 +---
8106 + CMakeLists.txt | 1 +
8107 + 1 file changed, 1 insertion(+)
8109 +diff --git a/CMakeLists.txt b/CMakeLists.txt
8110 +index e8bc79f..e7e4432 100644
8111 +--- a/CMakeLists.txt
8112 ++++ b/CMakeLists.txt
8113 +@@ -395,6 +395,7 @@ add_definitions(${QT_DEFINITIONS} -DQT_NO_KEYWORDS)
8114 + add_definitions(-D__STDC_LIMIT_MACROS)
8115 + add_definitions(-Wall -Wextra)
8116 + add_definitions(-std=c++11)
8117 ++add_definitions(-DBOOST_MATH_DISABLE_FLOAT128=1)
8119 + if(ENABLE_DECODE)
8120 + add_definitions(-DENABLE_DECODE)
8121 +--
8122 +2.9.3
8124 diff -Naurp buildroot-2017.05-rc2/package/python-enum34/python-enum34.mk buildroot-2017.05.2/package/python-enum34/python-enum34.mk
8125 --- buildroot-2017.05-rc2/package/python-enum34/python-enum34.mk 2017-05-17 10:27:16.013401440 +0200
8126 +++ buildroot-2017.05.2/package/python-enum34/python-enum34.mk 2017-07-27 08:16:52.017486944 +0200
8127 @@ -7,7 +7,7 @@
8128 PYTHON_ENUM34_VERSION = 1.1.6
8129 PYTHON_ENUM34_SOURCE = enum34-$(PYTHON_ENUM34_VERSION).tar.gz
8130 PYTHON_ENUM34_SITE = https://pypi.python.org/packages/bf/3e/31d502c25302814a7c2f1d3959d2a3b3f78e509002ba91aea64993936876
8131 -PYTHON_ENUM34_SETUP_TYPE = distutils
8132 +PYTHON_ENUM34_SETUP_TYPE = setuptools
8133 PYTHON_ENUM34_LICENSE = BSD-3-Clause
8134 PYTHON_ENUM34_LICENSE_FILES = enum/LICENSE
8136 diff -Naurp buildroot-2017.05-rc2/package/python-setproctitle/python-setproctitle.mk buildroot-2017.05.2/package/python-setproctitle/python-setproctitle.mk
8137 --- buildroot-2017.05-rc2/package/python-setproctitle/python-setproctitle.mk 2017-05-17 10:27:16.013401440 +0200
8138 +++ buildroot-2017.05.2/package/python-setproctitle/python-setproctitle.mk 2017-07-27 08:16:52.017486944 +0200
8139 @@ -9,6 +9,6 @@ PYTHON_SETPROCTITLE_SOURCE = setproctitl
8140 PYTHON_SETPROCTITLE_SITE = https://pypi.python.org/packages/5a/0d/dc0d2234aacba6cf1a729964383e3452c52096dc695581248b548786f2b3
8141 PYTHON_SETPROCTITLE_LICENSE = BSD-3-Clause
8142 PYTHON_SETPROCTITLE_LICENSE_FILES = COPYRIGHT
8143 -PYTHON_SETPROCTITLE_SETUP_TYPE = distutils
8144 +PYTHON_SETPROCTITLE_SETUP_TYPE = setuptools
8146 $(eval $(python-package))
8147 diff -Naurp buildroot-2017.05-rc2/package/python-simplegeneric/python-simplegeneric.mk buildroot-2017.05.2/package/python-simplegeneric/python-simplegeneric.mk
8148 --- buildroot-2017.05-rc2/package/python-simplegeneric/python-simplegeneric.mk 2017-05-17 10:27:16.013401440 +0200
8149 +++ buildroot-2017.05.2/package/python-simplegeneric/python-simplegeneric.mk 2017-07-27 08:16:52.017486944 +0200
8150 @@ -8,7 +8,12 @@ PYTHON_SIMPLEGENERIC_VERSION = 0.8.1
8151 PYTHON_SIMPLEGENERIC_SOURCE = simplegeneric-$(PYTHON_SIMPLEGENERIC_VERSION).zip
8152 PYTHON_SIMPLEGENERIC_SITE = https://pypi.python.org/packages/3d/57/4d9c9e3ae9a255cd4e1106bb57e24056d3d0709fc01b2e3e345898e49d5b
8153 PYTHON_SIMPLEGENERIC_LICENSE = ZPL-2.1
8154 -PYTHON_SIMPLEGENERIC_SETUP_TYPE = distutils
8156 +# Force setup-type to be 'setuptools' in order to force the package to
8157 +# be installed with --single-version-externally-managed. Otherwise we
8158 +# end up with a .egg file, which is a zip archive, and as such forces
8159 +# us to have 'zlib' as a runtime dependency
8160 +PYTHON_SIMPLEGENERIC_SETUP_TYPE = setuptools
8162 define PYTHON_SIMPLEGENERIC_EXTRACT_CMDS
8163 unzip $(DL_DIR)/$(PYTHON_SIMPLEGENERIC_SOURCE) -d $(@D)
8164 diff -Naurp buildroot-2017.05-rc2/package/qpid-proton/Config.in buildroot-2017.05.2/package/qpid-proton/Config.in
8165 --- buildroot-2017.05-rc2/package/qpid-proton/Config.in 2017-05-17 10:27:16.013401440 +0200
8166 +++ buildroot-2017.05.2/package/qpid-proton/Config.in 2017-07-27 08:16:52.017486944 +0200
8167 @@ -6,10 +6,10 @@ config BR2_PACKAGE_QPID_PROTON
8168 help
8169 The AMQP messaging toolkit
8171 - Qpid Proton is a high-performance, lightweight messaging library.
8172 - It can be used in the widest range of messaging applications,
8173 - including brokers, client libraries, routers, bridges, proxies, and
8174 - more.
8175 + Qpid Proton is a high-performance, lightweight messaging
8176 + library. It can be used in the widest range of messaging
8177 + applications, including brokers, client libraries, routers,
8178 + bridges, proxies, and more.
8180 https://qpid.apache.org/proton/
8182 diff -Naurp buildroot-2017.05-rc2/package/qt5/qt5base/5.8.0/0005-Fix-error-attribute-target-crc-is-unknown.patch buildroot-2017.05.2/package/qt5/qt5base/5.8.0/0005-Fix-error-attribute-target-crc-is-unknown.patch
8183 --- buildroot-2017.05-rc2/package/qt5/qt5base/5.8.0/0005-Fix-error-attribute-target-crc-is-unknown.patch 1970-01-01 01:00:00.000000000 +0100
8184 +++ buildroot-2017.05.2/package/qt5/qt5base/5.8.0/0005-Fix-error-attribute-target-crc-is-unknown.patch 2017-07-27 08:16:52.017486944 +0200
8185 @@ -0,0 +1,44 @@
8186 +From f0c02fb22bc277e2015a18e562b551ec7b3eed9e Mon Sep 17 00:00:00 2001
8187 +From: Peter Seiderer <ps.report@gmx.net>
8188 +Date: Sun, 16 Jul 2017 00:05:44 +0200
8189 +Subject: [PATCH] Fix error attribute(target("+crc")) is unknown
8191 +Task-number: QTBUG-61975
8192 +Change-Id: I0b1b55c0737dad485b5ace8e6eb7cb842589453d
8193 +---
8194 + src/corelib/tools/qhash.cpp | 2 ++
8195 + src/corelib/tools/qsimd_p.h | 3 +++
8196 + 2 files changed, 5 insertions(+)
8198 +diff --git a/src/corelib/tools/qhash.cpp b/src/corelib/tools/qhash.cpp
8199 +index 1f9c05c..bbf6efb 100644
8200 +--- a/src/corelib/tools/qhash.cpp
8201 ++++ b/src/corelib/tools/qhash.cpp
8202 +@@ -144,7 +144,9 @@ static inline bool hasFastCrc32()
8205 + template <typename Char>
8206 ++#if defined(__aarch64__)
8207 + QT_FUNCTION_TARGET(CRC32)
8208 ++#endif
8209 + static uint crc32(const Char *ptr, size_t len, uint h)
8211 + // The crc32[whbd] instructions on Aarch64/Aarch32 calculate a 32-bit CRC32 checksum
8212 +diff --git a/src/corelib/tools/qsimd_p.h b/src/corelib/tools/qsimd_p.h
8213 +index 023a4b0..a85d572 100644
8214 +--- a/src/corelib/tools/qsimd_p.h
8215 ++++ b/src/corelib/tools/qsimd_p.h
8216 +@@ -326,7 +326,10 @@
8217 + #endif
8218 + // AArch64/ARM64
8219 + #if defined(Q_PROCESSOR_ARM_V8) && defined(__ARM_FEATURE_CRC32)
8220 ++#if defined(__aarch64__)
8221 ++// only available on aarch64
8222 + #define QT_FUNCTION_TARGET_STRING_CRC32 "+crc"
8223 ++#endif
8224 + # include <arm_acle.h>
8225 + #endif
8227 +--
8228 +2.7.4
8230 diff -Naurp buildroot-2017.05-rc2/package/qt5/qt5base/qmake.conf buildroot-2017.05.2/package/qt5/qt5base/qmake.conf
8231 --- buildroot-2017.05-rc2/package/qt5/qt5base/qmake.conf 2017-05-17 10:27:16.013401440 +0200
8232 +++ buildroot-2017.05.2/package/qt5/qt5base/qmake.conf 2017-07-27 08:16:52.017486944 +0200
8233 @@ -21,5 +21,8 @@ CONFIG += nostrip
8234 QMAKE_LIBS += -lrt -lpthread -ldl
8235 QMAKE_CFLAGS_ISYSTEM =
8237 +# Architecturespecific configuration
8238 +include(arch.conf)
8240 include(../common/linux_device_post.conf)
8241 load(qt_config)
8242 diff -Naurp buildroot-2017.05-rc2/package/qt5/qt5base/qt5base.mk buildroot-2017.05.2/package/qt5/qt5base/qt5base.mk
8243 --- buildroot-2017.05-rc2/package/qt5/qt5base/qt5base.mk 2017-05-17 10:27:16.013401440 +0200
8244 +++ buildroot-2017.05.2/package/qt5/qt5base/qt5base.mk 2017-07-27 08:16:52.017486944 +0200
8245 @@ -214,12 +214,22 @@ define QT5BASE_CONFIGURE_CONFIG_FILE
8246 endef
8247 endif
8249 +QT5BASE_ARCH_CONFIG_FILE = $(@D)/mkspecs/devices/linux-buildroot-g++/arch.conf
8250 +ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC)$(BR2_PACKAGE_QT5_VERSION_LATEST),yy)
8251 +# Qt 5.8 needs atomics, which on various architectures are in -latomic
8252 +define QT5BASE_CONFIGURE_ARCH_CONFIG
8253 + printf 'LIBS += -latomic\n' >$(QT5BASE_ARCH_CONFIG_FILE)
8254 +endef
8255 +endif
8257 define QT5BASE_CONFIGURE_CMDS
8258 $(INSTALL) -m 0644 -D $(QT5BASE_PKGDIR)/qmake.conf \
8259 $(@D)/mkspecs/devices/linux-buildroot-g++/qmake.conf
8260 $(INSTALL) -m 0644 -D $(QT5BASE_PKGDIR)/qplatformdefs.h \
8261 $(@D)/mkspecs/devices/linux-buildroot-g++/qplatformdefs.h
8262 $(QT5BASE_CONFIGURE_CONFIG_FILE)
8263 + touch $(QT5BASE_ARCH_CONFIG_FILE)
8264 + $(QT5BASE_CONFIGURE_ARCH_CONFIG)
8265 (cd $(@D); \
8266 $(TARGET_MAKE_ENV) \
8267 PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
8268 diff -Naurp buildroot-2017.05-rc2/package/qt5/qt5multimedia/qt5multimedia.mk buildroot-2017.05.2/package/qt5/qt5multimedia/qt5multimedia.mk
8269 --- buildroot-2017.05-rc2/package/qt5/qt5multimedia/qt5multimedia.mk 2017-05-17 10:27:16.013401440 +0200
8270 +++ buildroot-2017.05.2/package/qt5/qt5multimedia/qt5multimedia.mk 2017-07-27 08:16:52.017486944 +0200
8271 @@ -26,6 +26,14 @@ ifeq ($(BR2_PACKAGE_QT5DECLARATIVE),y)
8272 QT5MULTIMEDIA_DEPENDENCIES += qt5declarative
8273 endif
8275 +ifeq ($(BR2_PACKAGE_LIBGLIB2)$(BR2_PACKAGE_PULSEAUDIO),yy)
8276 +QT5MULTIMEDIA_DEPENDENCIES += libglib2 pulseaudio
8277 +endif
8279 +ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
8280 +QT5MULTIMEDIA_DEPENDENCIES += alsa-lib
8281 +endif
8283 define QT5MULTIMEDIA_CONFIGURE_CMDS
8284 (cd $(@D); $(TARGET_MAKE_ENV) $(HOST_DIR)/usr/bin/qmake)
8285 endef
8286 diff -Naurp buildroot-2017.05-rc2/package/rabbitmq-c/rabbitmq-c.mk buildroot-2017.05.2/package/rabbitmq-c/rabbitmq-c.mk
8287 --- buildroot-2017.05-rc2/package/rabbitmq-c/rabbitmq-c.mk 2017-05-17 10:27:16.013401440 +0200
8288 +++ buildroot-2017.05.2/package/rabbitmq-c/rabbitmq-c.mk 2017-07-27 08:16:52.017486944 +0200
8289 @@ -21,14 +21,20 @@ else ifeq ($(BR2_SHARED_LIBS),y)
8290 RABBITMQ_C_CONF_OPTS += -DBUILD_SHARED_LIBS=ON -DBUILD_STATIC_LIBS=OFF
8291 endif
8293 -ifeq ($(BR2_PACKAGE_OPENSSL),y)
8294 +# CMake OpenSSL detection is buggy, and doesn't properly use
8295 +# pkg-config, so it fails when statically linking. See
8296 +# https://gitlab.kitware.com/cmake/cmake/issues/16885.
8297 +ifeq ($(BR2_PACKAGE_OPENSSL):$(BR2_STATIC_LIBS),y:)
8298 RABBITMQ_C_CONF_OPTS += -DENABLE_SSL_SUPPORT=ON
8299 RABBITMQ_C_DEPENDENCIES += openssl
8300 else
8301 RABBITMQ_C_CONF_OPTS += -DENABLE_SSL_SUPPORT=OFF
8302 endif
8304 -ifeq ($(BR2_PACKAGE_POPT), y)
8305 +# Popt is sometimes linked against libintl, but CMake doesn't know
8306 +# about that, and there's no way to tell manually CMake to link
8307 +# against an additional library.
8308 +ifeq ($(BR2_PACKAGE_POPT):$(BR2_STATIC_LIBS),y:)
8309 RABBITMQ_C_CONF_OPTS += -DBUILD_TOOLS=ON
8310 RABBITMQ_C_DEPENDENCIES += popt
8311 else
8312 diff -Naurp buildroot-2017.05-rc2/package/redis/redis.mk buildroot-2017.05.2/package/redis/redis.mk
8313 --- buildroot-2017.05-rc2/package/redis/redis.mk 2017-05-17 10:27:16.013401440 +0200
8314 +++ buildroot-2017.05.2/package/redis/redis.mk 2017-07-27 08:16:52.017486944 +0200
8315 @@ -13,16 +13,21 @@ define REDIS_USERS
8316 redis -1 redis -1 * /var/lib/redis /bin/false - Redis Server
8317 endef
8319 -# Uses __atomic_fetch_add_4
8320 +# Uses __atomic_fetch_add_4. Adding -latomic to LDFLAGS does not work,
8321 +# because LDFLAGS is used before the list of object files. We need to
8322 +# add -latomic to FINAL_LIBS to provide -latomic at the correct place
8323 +# in the linking command.
8324 ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
8325 -REDIS_LIBATOMIC = -latomic
8326 +define REDIS_FIX_MAKEFILE
8327 + $(SED) 's/FINAL_LIBS=-lm/FINAL_LIBS=-lm -latomic/' $(@D)/src/Makefile
8328 +endef
8329 +REDIS_POST_PATCH_HOOKS = REDIS_FIX_MAKEFILE
8330 endif
8332 # Redis doesn't support DESTDIR (yet, see
8333 # https://github.com/antirez/redis/pull/609). We set PREFIX
8334 # instead.
8335 REDIS_BUILDOPTS = $(TARGET_CONFIGURE_OPTS) \
8336 - LDFLAGS="$(TARGET_LDFLAGS) $(REDIS_LIBATOMIC)" \
8337 PREFIX=$(TARGET_DIR)/usr MALLOC=libc
8339 define REDIS_BUILD_CMDS
8340 diff -Naurp buildroot-2017.05-rc2/package/rpi-firmware/rpi-firmware.mk buildroot-2017.05.2/package/rpi-firmware/rpi-firmware.mk
8341 --- buildroot-2017.05-rc2/package/rpi-firmware/rpi-firmware.mk 2017-05-17 10:27:16.013401440 +0200
8342 +++ buildroot-2017.05.2/package/rpi-firmware/rpi-firmware.mk 2017-07-27 08:16:52.017486944 +0200
8343 @@ -31,6 +31,8 @@ ifeq ($(BR2_PACKAGE_RPI_FIRMWARE_INSTALL
8344 define RPI_FIRMWARE_INSTALL_TARGET_CMDS
8345 $(INSTALL) -D -m 0700 $(@D)/$(if BR2_ARM_EABIHF,hardfp/)opt/vc/bin/vcdbg \
8346 $(TARGET_DIR)/usr/sbin/vcdbg
8347 + $(INSTALL) -D -m 0644 $(@D)/$(if BR2_ARM_EABIHF,hardfp/)opt/vc/lib/libelftoolchain.so \
8348 + $(TARGET_DIR)/usr/lib/libelftoolchain.so
8349 endef
8350 endif # INSTALL_VCDBG
8352 diff -Naurp buildroot-2017.05-rc2/package/rtl8188eu/Config.in buildroot-2017.05.2/package/rtl8188eu/Config.in
8353 --- buildroot-2017.05-rc2/package/rtl8188eu/Config.in 2017-05-17 10:27:16.013401440 +0200
8354 +++ buildroot-2017.05.2/package/rtl8188eu/Config.in 2017-07-27 08:16:52.017486944 +0200
8355 @@ -4,14 +4,14 @@ config BR2_PACKAGE_RTL8188EU
8356 help
8357 A standalone driver for the RTL8188EU USB Wi-Fi adapter.
8358 This is needed only for Linux kernels before 3.12.
8359 - Since 3.12, there is a (staging) driver in mainline, with a similar
8360 - codebase.
8361 + Since 3.12, there is a (staging) driver in mainline, with a
8362 + similar codebase.
8364 - Make sure your target kernel has the CONFIG_WIRELESS_EXT config
8365 - option enabled.
8366 + Make sure your target kernel has the CONFIG_WIRELESS_EXT
8367 + config option enabled.
8369 - Note: this package needs a firmware loading mechanism to load the
8370 - binary blob for the chip to work.
8371 + Note: this package needs a firmware loading mechanism to load
8372 + the binary blob for the chip to work.
8374 https://github.com/lwfinger/rtl8188eu
8376 diff -Naurp buildroot-2017.05-rc2/package/rtl8821au/rtl8821au.mk buildroot-2017.05.2/package/rtl8821au/rtl8821au.mk
8377 --- buildroot-2017.05-rc2/package/rtl8821au/rtl8821au.mk 2017-05-17 10:27:16.013401440 +0200
8378 +++ buildroot-2017.05.2/package/rtl8821au/rtl8821au.mk 2017-07-27 08:16:52.017486944 +0200
8379 @@ -7,7 +7,7 @@
8380 RTL8821AU_VERSION = b018b446fb0729fa659e7eead475d6c13f192642
8381 RTL8821AU_SITE = $(call github,abperiasamy,rtl8812AU_8821AU_linux,$(RTL8821AU_VERSION))
8382 RTL8821AU_LICENSE = GPL-2.0
8383 -RTL8821AU_LICENSE_FILES = COPYING
8384 +RTL8821AU_LICENSE_FILES = LICENSE
8386 RTL8821AU_MODULE_MAKE_OPTS = \
8387 CONFIG_RTL8812AU_8821AU=m \
8388 diff -Naurp buildroot-2017.05-rc2/package/samba4/Config.in buildroot-2017.05.2/package/samba4/Config.in
8389 --- buildroot-2017.05-rc2/package/samba4/Config.in 2017-05-17 10:27:16.013401440 +0200
8390 +++ buildroot-2017.05.2/package/samba4/Config.in 2017-07-27 08:16:52.017486944 +0200
8391 @@ -10,7 +10,7 @@ config BR2_PACKAGE_SAMBA4
8392 depends on BR2_USE_WCHAR # python
8393 depends on BR2_TOOLCHAIN_HAS_NATIVE_RPC
8394 depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # python -> libffi
8395 - depends on !BR2_STATIC_LIBS # python
8396 + depends on !BR2_STATIC_LIBS # python, gnutls
8397 depends on !BR2_nios2 # binary too large, relocations don't fit
8398 depends on BR2_TOOLCHAIN_HAS_SYNC_4
8399 select BR2_PACKAGE_E2FSPROGS
8400 diff -Naurp buildroot-2017.05-rc2/package/samba4/samba4.hash buildroot-2017.05.2/package/samba4/samba4.hash
8401 --- buildroot-2017.05-rc2/package/samba4/samba4.hash 2017-05-17 10:27:16.013401440 +0200
8402 +++ buildroot-2017.05.2/package/samba4/samba4.hash 2017-07-27 08:16:52.017486944 +0200
8403 @@ -1,2 +1,2 @@
8404 # Locally calculated
8405 -sha256 f63b656d8823a280c50c9dbd6b692816cd7a88adfe9b47997ce697fd75bf81f0 samba-4.5.8.tar.gz
8406 +sha256 f4c17123e3cc852a5ecc7e38884b00deab57632b9519aebc243e2a94b9b5ace4 samba-4.5.12.tar.gz
8407 diff -Naurp buildroot-2017.05-rc2/package/samba4/samba4.mk buildroot-2017.05.2/package/samba4/samba4.mk
8408 --- buildroot-2017.05-rc2/package/samba4/samba4.mk 2017-05-17 10:27:16.013401440 +0200
8409 +++ buildroot-2017.05.2/package/samba4/samba4.mk 2017-07-27 08:16:52.017486944 +0200
8410 @@ -4,7 +4,7 @@
8412 ################################################################################
8414 -SAMBA4_VERSION = 4.5.8
8415 +SAMBA4_VERSION = 4.5.12
8416 SAMBA4_SITE = https://download.samba.org/pub/samba/stable
8417 SAMBA4_SOURCE = samba-$(SAMBA4_VERSION).tar.gz
8418 SAMBA4_INSTALL_STAGING = YES
8419 diff -Naurp buildroot-2017.05-rc2/package/snmppp/Config.in buildroot-2017.05.2/package/snmppp/Config.in
8420 --- buildroot-2017.05-rc2/package/snmppp/Config.in 2017-05-17 10:27:16.013401440 +0200
8421 +++ buildroot-2017.05.2/package/snmppp/Config.in 2017-07-27 08:16:52.017486944 +0200
8422 @@ -14,8 +14,9 @@ config BR2_PACKAGE_SNMPPP_LOGGING
8423 bool "enable logging"
8424 help
8425 Enable logging output for SNMP++.
8426 - According to the SNMP++ documentation, disabling logging "increases
8427 - performance drastically and minimizes memory consumption".
8428 + According to the SNMP++ documentation, disabling logging
8429 + "increases performance drastically and minimizes memory
8430 + consumption".
8432 config BR2_PACKAGE_SNMPPP_SNMPV3
8433 bool "enable SNMPv3"
8434 diff -Naurp buildroot-2017.05-rc2/package/socat/socat.mk buildroot-2017.05.2/package/socat/socat.mk
8435 --- buildroot-2017.05-rc2/package/socat/socat.mk 2017-05-17 10:27:16.013401440 +0200
8436 +++ buildroot-2017.05.2/package/socat/socat.mk 2017-07-27 08:16:52.017486944 +0200
8437 @@ -9,11 +9,20 @@ SOCAT_SOURCE = socat-$(SOCAT_VERSION).ta
8438 SOCAT_SITE = http://www.dest-unreach.org/socat/download
8439 SOCAT_LICENSE = GPL-2.0
8440 SOCAT_LICENSE_FILES = COPYING
8441 -SOCAT_CONF_ENV = \
8442 - sc_cv_termios_ispeed=no \
8444 +SOCAT_CONF_ENV = sc_cv_termios_ispeed=no
8446 +ifeq ($(BR2_powerpc)$(BR2_powerpc64)$(BR2_powerpc64le),y)
8447 +SOCAT_CONF_ENV += \
8448 + sc_cv_sys_crdly_shift=12 \
8449 + sc_cv_sys_tabdly_shift=10 \
8450 + sc_cv_sys_csize_shift=8
8451 +else
8452 +SOCAT_CONF_ENV += \
8453 sc_cv_sys_crdly_shift=9 \
8454 sc_cv_sys_tabdly_shift=11 \
8455 sc_cv_sys_csize_shift=4
8456 +endif
8458 # We need to run autoconf to regenerate the configure script, in order
8459 # to ensure that the test checking linux/ext2_fs.h works
8460 diff -Naurp buildroot-2017.05-rc2/package/spice/0001-fix-missing-monitor_latency-argument.patch buildroot-2017.05.2/package/spice/0001-fix-missing-monitor_latency-argument.patch
8461 --- buildroot-2017.05-rc2/package/spice/0001-fix-missing-monitor_latency-argument.patch 2017-05-17 10:27:16.013401440 +0200
8462 +++ buildroot-2017.05.2/package/spice/0001-fix-missing-monitor_latency-argument.patch 1970-01-01 01:00:00.000000000 +0100
8463 @@ -1,28 +0,0 @@
8464 -From 0d3767853ca179ce04a9b312d7a30d33d1266a3b Mon Sep 17 00:00:00 2001
8465 -From: Axel Lin <axel.lin@ingics.com>
8466 -Date: Thu, 10 Oct 2013 12:36:40 +0800
8467 -Subject: [PATCH] red_tunnel_worker: Fix build error due to missing monitor_latency argument
8469 -Fix missing monitor_latency argument in red_channel_client_create call.
8471 -Signed-off-by: Axel Lin <axel.lin@ingics.com>
8472 ----
8473 - server/red_tunnel_worker.c | 2 +-
8474 - 1 file changed, 1 insertion(+), 1 deletion(-)
8476 -diff --git a/server/red_tunnel_worker.c b/server/red_tunnel_worker.c
8477 -index 97dcafd..6781d73 100644
8478 ---- a/server/red_tunnel_worker.c
8479 -+++ b/server/red_tunnel_worker.c
8480 -@@ -3417,7 +3417,7 @@ static void handle_tunnel_channel_link(RedChannel *channel, RedClient *client,
8483 - tcc = (TunnelChannelClient*)red_channel_client_create(sizeof(TunnelChannelClient),
8484 -- channel, client, stream,
8485 -+ channel, client, stream, FALSE,
8486 - 0, NULL, 0, NULL);
8487 - if (!tcc) {
8488 - return;
8489 ---
8490 -1.8.1.2
8492 diff -Naurp buildroot-2017.05-rc2/package/spice/0001-Prevent-possible-DoS-attempts-during-protocol-handsh.patch buildroot-2017.05.2/package/spice/0001-Prevent-possible-DoS-attempts-during-protocol-handsh.patch
8493 --- buildroot-2017.05-rc2/package/spice/0001-Prevent-possible-DoS-attempts-during-protocol-handsh.patch 1970-01-01 01:00:00.000000000 +0100
8494 +++ buildroot-2017.05.2/package/spice/0001-Prevent-possible-DoS-attempts-during-protocol-handsh.patch 2017-07-27 08:16:52.017486944 +0200
8495 @@ -0,0 +1,60 @@
8496 +From 1c6517973095a67c8cb57f3550fc1298404ab556 Mon Sep 17 00:00:00 2001
8497 +From: Frediano Ziglio <fziglio@redhat.com>
8498 +Date: Tue, 13 Dec 2016 14:39:48 +0000
8499 +Subject: [PATCH] Prevent possible DoS attempts during protocol handshake
8501 +The limit for link message is specified using a 32 bit unsigned integer.
8502 +This could cause possible DoS due to excessive memory allocations and
8503 +some possible crashes.
8504 +For instance a value >= 2^31 causes a spice_assert to be triggered in
8505 +async_read_handler (reds-stream.c) due to an integer overflow at this
8506 +line:
8508 + int n = async->end - async->now;
8510 +This could be easily triggered with a program like
8512 + #!/usr/bin/env python
8514 + import socket
8515 + import time
8516 + from struct import pack
8518 + server = '127.0.0.1'
8519 + port = 5900
8521 + s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
8522 + s.connect((server, port))
8523 + data = pack('<4sIII', 'REDQ', 2, 2, 0xaaaaaaaa)
8524 + s.send(data)
8526 + time.sleep(1)
8528 +without requiring any authentication (the same can be done
8529 +with TLS).
8531 +[Peter: fixes CVE-2016-9578]
8532 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8533 +Acked-by: Christophe Fergeau <cfergeau@redhat.com>
8534 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8535 +---
8536 + server/reds.c | 3 ++-
8537 + 1 file changed, 2 insertions(+), 1 deletion(-)
8539 +diff --git a/server/reds.c b/server/reds.c
8540 +index f40b65c1..86a33d53 100644
8541 +--- a/server/reds.c
8542 ++++ b/server/reds.c
8543 +@@ -2202,7 +2202,8 @@ static void reds_handle_read_header_done(void *opaque)
8545 + reds->peer_minor_version = header->minor_version;
8547 +- if (header->size < sizeof(SpiceLinkMess)) {
8548 ++ /* the check for 4096 is to avoid clients to cause arbitrary big memory allocations */
8549 ++ if (header->size < sizeof(SpiceLinkMess) || header->size > 4096) {
8550 + reds_send_link_error(link, SPICE_LINK_ERR_INVALID_DATA);
8551 + spice_warning("bad size %u", header->size);
8552 + reds_link_free(link);
8553 +--
8554 +2.11.0
8556 diff -Naurp buildroot-2017.05-rc2/package/spice/0002-Prevent-integer-overflows-in-capability-checks.patch buildroot-2017.05.2/package/spice/0002-Prevent-integer-overflows-in-capability-checks.patch
8557 --- buildroot-2017.05-rc2/package/spice/0002-Prevent-integer-overflows-in-capability-checks.patch 1970-01-01 01:00:00.000000000 +0100
8558 +++ buildroot-2017.05.2/package/spice/0002-Prevent-integer-overflows-in-capability-checks.patch 2017-07-27 08:16:52.017486944 +0200
8559 @@ -0,0 +1,43 @@
8560 +From f66dc643635518e53dfbe5262f814a64eec54e4a Mon Sep 17 00:00:00 2001
8561 +From: Frediano Ziglio <fziglio@redhat.com>
8562 +Date: Tue, 13 Dec 2016 14:40:10 +0000
8563 +Subject: [PATCH] Prevent integer overflows in capability checks
8565 +The limits for capabilities are specified using 32 bit unsigned integers.
8566 +This could cause possible integer overflows causing buffer overflows.
8567 +For instance the sum of num_common_caps and num_caps can be 0 avoiding
8568 +additional checks.
8569 +As the link message is now capped to 4096 and the capabilities are
8570 +contained in the link message limit the capabilities to 1024
8571 +(capabilities are expressed in number of uint32_t items).
8573 +[Peter: fixes CVE-2016-9578]
8574 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8575 +Acked-by: Christophe Fergeau <cfergeau@redhat.com>
8576 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8577 +---
8578 + server/reds.c | 8 ++++++++
8579 + 1 file changed, 8 insertions(+)
8581 +diff --git a/server/reds.c b/server/reds.c
8582 +index 86a33d53..91504544 100644
8583 +--- a/server/reds.c
8584 ++++ b/server/reds.c
8585 +@@ -2110,6 +2110,14 @@ static void reds_handle_read_link_done(void *opaque)
8586 + link_mess->num_channel_caps = GUINT32_FROM_LE(link_mess->num_channel_caps);
8587 + link_mess->num_common_caps = GUINT32_FROM_LE(link_mess->num_common_caps);
8589 ++ /* Prevent DoS. Currently we defined only 13 capabilities,
8590 ++ * I expect 1024 to be valid for quite a lot time */
8591 ++ if (link_mess->num_channel_caps > 1024 || link_mess->num_common_caps > 1024) {
8592 ++ reds_send_link_error(link, SPICE_LINK_ERR_INVALID_DATA);
8593 ++ reds_link_free(link);
8594 ++ return;
8595 ++ }
8597 + num_caps = link_mess->num_common_caps + link_mess->num_channel_caps;
8598 + caps = (uint32_t *)((uint8_t *)link_mess + link_mess->caps_offset);
8600 +--
8601 +2.11.0
8603 diff -Naurp buildroot-2017.05-rc2/package/spice/0003-main-channel-Prevent-overflow-reading-messages-from-.patch buildroot-2017.05.2/package/spice/0003-main-channel-Prevent-overflow-reading-messages-from-.patch
8604 --- buildroot-2017.05-rc2/package/spice/0003-main-channel-Prevent-overflow-reading-messages-from-.patch 1970-01-01 01:00:00.000000000 +0100
8605 +++ buildroot-2017.05.2/package/spice/0003-main-channel-Prevent-overflow-reading-messages-from-.patch 2017-07-27 08:16:52.017486944 +0200
8606 @@ -0,0 +1,33 @@
8607 +From 5f96b596353d73bdf4bb3cd2de61e48a7fd5b4c3 Mon Sep 17 00:00:00 2001
8608 +From: Frediano Ziglio <fziglio@redhat.com>
8609 +Date: Tue, 29 Nov 2016 16:46:56 +0000
8610 +Subject: [PATCH] main-channel: Prevent overflow reading messages from client
8612 +Caller is supposed the function return a buffer able to store
8613 +size bytes.
8615 +[Peter: fixes CVE-2016-9577]
8616 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8617 +Acked-by: Christophe Fergeau <cfergeau@redhat.com>
8618 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8619 +---
8620 + server/main_channel.c | 3 +++
8621 + 1 file changed, 3 insertions(+)
8623 +diff --git a/server/main_channel.c b/server/main_channel.c
8624 +index 0ecc9df8..1fc39155 100644
8625 +--- a/server/main_channel.c
8626 ++++ b/server/main_channel.c
8627 +@@ -1026,6 +1026,9 @@ static uint8_t *main_channel_alloc_msg_rcv_buf(RedChannelClient *rcc,
8629 + if (type == SPICE_MSGC_MAIN_AGENT_DATA) {
8630 + return reds_get_agent_data_buffer(mcc, size);
8631 ++ } else if (size > sizeof(main_chan->recv_buf)) {
8632 ++ /* message too large, caller will log a message and close the connection */
8633 ++ return NULL;
8634 + } else {
8635 + return main_chan->recv_buf;
8637 +--
8638 +2.11.0
8640 diff -Naurp buildroot-2017.05-rc2/package/spice/0004-reds-Disconnect-when-receiving-overly-big-ClientMoni.patch buildroot-2017.05.2/package/spice/0004-reds-Disconnect-when-receiving-overly-big-ClientMoni.patch
8641 --- buildroot-2017.05-rc2/package/spice/0004-reds-Disconnect-when-receiving-overly-big-ClientMoni.patch 1970-01-01 01:00:00.000000000 +0100
8642 +++ buildroot-2017.05.2/package/spice/0004-reds-Disconnect-when-receiving-overly-big-ClientMoni.patch 2017-07-27 08:16:52.017486944 +0200
8643 @@ -0,0 +1,75 @@
8644 +From f1e7ec03e26ab6b8ca9b7ec060846a5b706a963d Mon Sep 17 00:00:00 2001
8645 +From: Frediano Ziglio <fziglio@redhat.com>
8646 +Date: Mon, 15 May 2017 15:57:28 +0100
8647 +Subject: [PATCH] reds: Disconnect when receiving overly big
8648 + ClientMonitorsConfig
8650 +Total message size received from the client was unlimited. There is
8651 +a 2kiB size check on individual agent messages, but the MonitorsConfig
8652 +message can be split in multiple chunks, and the size of the
8653 +non-chunked MonitorsConfig message was never checked. This could easily
8654 +lead to memory exhaustion on the host.
8656 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8657 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8658 +---
8659 + server/reds.c | 25 +++++++++++++++++++++++--
8660 + 1 file changed, 23 insertions(+), 2 deletions(-)
8662 +diff --git a/server/reds.c b/server/reds.c
8663 +index f439a366..7be85fdf 100644
8664 +--- a/server/reds.c
8665 ++++ b/server/reds.c
8666 +@@ -993,19 +993,34 @@ static void reds_client_monitors_config_cleanup(void)
8667 + static void reds_on_main_agent_monitors_config(
8668 + MainChannelClient *mcc, void *message, size_t size)
8670 ++ const unsigned int MAX_MONITORS = 256;
8671 ++ const unsigned int MAX_MONITOR_CONFIG_SIZE =
8672 ++ sizeof(VDAgentMonitorsConfig) + MAX_MONITORS * sizeof(VDAgentMonConfig);
8674 + VDAgentMessage *msg_header;
8675 + VDAgentMonitorsConfig *monitors_config;
8676 + RedsClientMonitorsConfig *cmc = &reds->client_monitors_config;
8678 ++ // limit size of message sent by the client as this can cause a DoS through
8679 ++ // memory exhaustion, or potentially some integer overflows
8680 ++ if (sizeof(VDAgentMessage) + MAX_MONITOR_CONFIG_SIZE - cmc->buffer_size < size) {
8681 ++ goto overflow;
8682 ++ }
8683 + cmc->buffer_size += size;
8684 + cmc->buffer = realloc(cmc->buffer, cmc->buffer_size);
8685 + spice_assert(cmc->buffer);
8686 + cmc->mcc = mcc;
8687 + memcpy(cmc->buffer + cmc->buffer_pos, message, size);
8688 + cmc->buffer_pos += size;
8689 ++ if (sizeof(VDAgentMessage) > cmc->buffer_size) {
8690 ++ spice_debug("not enough data yet. %d", cmc->buffer_size);
8691 ++ return;
8692 ++ }
8693 + msg_header = (VDAgentMessage *)cmc->buffer;
8694 +- if (sizeof(VDAgentMessage) > cmc->buffer_size ||
8695 +- msg_header->size > cmc->buffer_size - sizeof(VDAgentMessage)) {
8696 ++ if (msg_header->size > MAX_MONITOR_CONFIG_SIZE) {
8697 ++ goto overflow;
8698 ++ }
8699 ++ if (msg_header->size > cmc->buffer_size - sizeof(VDAgentMessage)) {
8700 + spice_debug("not enough data yet. %d", cmc->buffer_size);
8701 + return;
8703 +@@ -1013,6 +1028,12 @@ static void reds_on_main_agent_monitors_config(
8704 + spice_debug("%s: %d", __func__, monitors_config->num_of_monitors);
8705 + red_dispatcher_client_monitors_config(monitors_config);
8706 + reds_client_monitors_config_cleanup();
8707 ++ return;
8709 ++overflow:
8710 ++ spice_warning("received invalid MonitorsConfig request from client, disconnecting");
8711 ++ red_channel_client_disconnect(main_channel_client_get_base(mcc));
8712 ++ reds_client_monitors_config_cleanup();
8715 + void reds_on_main_agent_data(MainChannelClient *mcc, void *message, size_t size)
8716 +--
8717 +2.11.0
8719 diff -Naurp buildroot-2017.05-rc2/package/spice/0005-reds-Avoid-integer-overflows-handling-monitor-config.patch buildroot-2017.05.2/package/spice/0005-reds-Avoid-integer-overflows-handling-monitor-config.patch
8720 --- buildroot-2017.05-rc2/package/spice/0005-reds-Avoid-integer-overflows-handling-monitor-config.patch 1970-01-01 01:00:00.000000000 +0100
8721 +++ buildroot-2017.05.2/package/spice/0005-reds-Avoid-integer-overflows-handling-monitor-config.patch 2017-07-27 08:16:52.017486944 +0200
8722 @@ -0,0 +1,31 @@
8723 +From ec6229c79abe05d731953df5f7e9a05ec9f6df79 Mon Sep 17 00:00:00 2001
8724 +From: Frediano Ziglio <fziglio@redhat.com>
8725 +Date: Mon, 15 May 2017 15:57:28 +0100
8726 +Subject: [PATCH] reds: Avoid integer overflows handling monitor
8727 + configuration
8729 +Avoid VDAgentMessage::size integer overflows.
8731 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8732 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8733 +---
8734 + server/reds.c | 3 +++
8735 + 1 file changed, 3 insertions(+)
8737 +diff --git a/server/reds.c b/server/reds.c
8738 +index 7be85fdf..e1c8c108 100644
8739 +--- a/server/reds.c
8740 ++++ b/server/reds.c
8741 +@@ -1024,6 +1024,9 @@ static void reds_on_main_agent_monitors_config(
8742 + spice_debug("not enough data yet. %d", cmc->buffer_size);
8743 + return;
8745 ++ if (msg_header->size < sizeof(VDAgentMonitorsConfig)) {
8746 ++ goto overflow;
8747 ++ }
8748 + monitors_config = (VDAgentMonitorsConfig *)(cmc->buffer + sizeof(*msg_header));
8749 + spice_debug("%s: %d", __func__, monitors_config->num_of_monitors);
8750 + red_dispatcher_client_monitors_config(monitors_config);
8751 +--
8752 +2.11.0
8754 diff -Naurp buildroot-2017.05-rc2/package/spice/0006-reds-Avoid-buffer-overflows-handling-monitor-configu.patch buildroot-2017.05.2/package/spice/0006-reds-Avoid-buffer-overflows-handling-monitor-configu.patch
8755 --- buildroot-2017.05-rc2/package/spice/0006-reds-Avoid-buffer-overflows-handling-monitor-configu.patch 1970-01-01 01:00:00.000000000 +0100
8756 +++ buildroot-2017.05.2/package/spice/0006-reds-Avoid-buffer-overflows-handling-monitor-configu.patch 2017-07-27 08:16:52.017486944 +0200
8757 @@ -0,0 +1,48 @@
8758 +From a957a90baf2c62d31f3547e56bba7d0e812d2331 Mon Sep 17 00:00:00 2001
8759 +From: Frediano Ziglio <fziglio@redhat.com>
8760 +Date: Mon, 15 May 2017 15:57:28 +0100
8761 +Subject: [PATCH] reds: Avoid buffer overflows handling monitor
8762 + configuration
8764 +It was also possible for a malicious client to set
8765 +VDAgentMonitorsConfig::num_of_monitors to a number larger
8766 +than the actual size of VDAgentMOnitorsConfig::monitors.
8767 +This would lead to buffer overflows, which could allow the guest to
8768 +read part of the host memory. This might cause write overflows in the
8769 +host as well, but controlling the content of such buffers seems
8770 +complicated.
8772 +Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
8773 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
8774 +---
8775 + server/reds.c | 7 +++++++
8776 + 1 file changed, 7 insertions(+)
8778 +diff --git a/server/reds.c b/server/reds.c
8779 +index e1c8c108..3a42c375 100644
8780 +--- a/server/reds.c
8781 ++++ b/server/reds.c
8782 +@@ -1000,6 +1000,7 @@ static void reds_on_main_agent_monitors_config(
8783 + VDAgentMessage *msg_header;
8784 + VDAgentMonitorsConfig *monitors_config;
8785 + RedsClientMonitorsConfig *cmc = &reds->client_monitors_config;
8786 ++ uint32_t max_monitors;
8788 + // limit size of message sent by the client as this can cause a DoS through
8789 + // memory exhaustion, or potentially some integer overflows
8790 +@@ -1028,6 +1029,12 @@ static void reds_on_main_agent_monitors_config(
8791 + goto overflow;
8793 + monitors_config = (VDAgentMonitorsConfig *)(cmc->buffer + sizeof(*msg_header));
8794 ++ // limit the monitor number to avoid buffer overflows
8795 ++ max_monitors = (msg_header->size - sizeof(VDAgentMonitorsConfig)) /
8796 ++ sizeof(VDAgentMonConfig);
8797 ++ if (monitors_config->num_of_monitors > max_monitors) {
8798 ++ goto overflow;
8799 ++ }
8800 + spice_debug("%s: %d", __func__, monitors_config->num_of_monitors);
8801 + red_dispatcher_client_monitors_config(monitors_config);
8802 + reds_client_monitors_config_cleanup();
8803 +--
8804 +2.11.0
8806 diff -Naurp buildroot-2017.05-rc2/package/spice/Config.in buildroot-2017.05.2/package/spice/Config.in
8807 --- buildroot-2017.05-rc2/package/spice/Config.in 2017-05-17 10:27:16.013401440 +0200
8808 +++ buildroot-2017.05.2/package/spice/Config.in 2017-07-27 08:16:52.017486944 +0200
8809 @@ -2,23 +2,15 @@ comment "spice server needs a toolchain
8810 depends on BR2_i386 || BR2_x86_64
8811 depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
8813 -comment "spice server depends on python (for pyparsing)"
8814 - depends on BR2_i386 || BR2_x86_64
8815 - depends on !BR2_PACKAGE_PYTHON
8817 config BR2_PACKAGE_SPICE
8818 bool "spice server"
8819 depends on BR2_i386 || BR2_x86_64
8820 - depends on BR2_PACKAGE_PYTHON
8821 depends on BR2_USE_WCHAR # libglib2
8822 depends on BR2_TOOLCHAIN_HAS_THREADS # libglib2
8823 - select BR2_PACKAGE_ALSA_LIB
8824 - select BR2_PACKAGE_CELT051
8825 select BR2_PACKAGE_JPEG
8826 select BR2_PACKAGE_LIBGLIB2
8827 select BR2_PACKAGE_OPENSSL
8828 select BR2_PACKAGE_PIXMAN
8829 - select BR2_PACKAGE_PYTHON_PYPARSING
8830 select BR2_PACKAGE_SPICE_PROTOCOL
8831 help
8832 The Spice project aims to provide a complete open source
8833 @@ -30,41 +22,3 @@ config BR2_PACKAGE_SPICE
8834 This package implements the server-part of Spice.
8836 http://www.spice-space.org/
8838 -if BR2_PACKAGE_SPICE
8840 -comment "client depends on X.org"
8841 - depends on !BR2_PACKAGE_XORG7
8843 -config BR2_PACKAGE_SPICE_CLIENT
8844 - bool "Enable client"
8845 - depends on BR2_PACKAGE_XORG7
8846 - depends on BR2_TOOLCHAIN_HAS_THREADS
8847 - depends on BR2_INSTALL_LIBSTDCPP
8848 - select BR2_PACKAGE_XLIB_LIBXFIXES
8849 - select BR2_PACKAGE_XLIB_LIBXRANDR
8851 -comment "client needs a toolchain w/ threads, C++"
8852 - depends on BR2_PACKAGE_XORG7
8853 - depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_INSTALL_LIBSTDCPP
8855 -config BR2_PACKAGE_SPICE_GUI
8856 - bool "Enable GUI"
8857 - depends on BR2_PACKAGE_SPICE_CLIENT
8858 - depends on !BR2_STATIC_LIBS
8859 - select BR2_PACKAGE_CEGUI06
8860 - help
8861 - Say 'y' here to enable the Graphical User Interface (GUI)
8862 - start dialog.
8864 -comment "gui needs a toolchain w/ dynamic library"
8865 - depends on BR2_STATIC_LIBS
8867 -config BR2_PACKAGE_SPICE_TUNNEL
8868 - bool "Enable network redirection"
8869 - select BR2_PACKAGE_SLIRP
8870 - help
8871 - Say 'y' here to enable network redirection, aka tunnelling
8872 - through a SLIP/SLIRP session.
8874 -endif # BR2_PACKAGE_SPICE
8875 diff -Naurp buildroot-2017.05-rc2/package/spice/spice.hash buildroot-2017.05.2/package/spice/spice.hash
8876 --- buildroot-2017.05-rc2/package/spice/spice.hash 2017-05-17 10:27:16.013401440 +0200
8877 +++ buildroot-2017.05.2/package/spice/spice.hash 2017-07-27 08:16:52.017486944 +0200
8878 @@ -1,2 +1,2 @@
8879 # Locally calculated
8880 -sha256 cf063e7df42e331a835529d2f613d8a01f8cb2963e8edaadf73a8d65c46fb387 spice-0.12.4.tar.bz2
8881 +sha256 f901a5c5873d61acac84642f9eea5c4d6386fc3e525c2b68792322794e1c407d spice-0.12.8.tar.bz2
8882 diff -Naurp buildroot-2017.05-rc2/package/spice/spice.mk buildroot-2017.05.2/package/spice/spice.mk
8883 --- buildroot-2017.05-rc2/package/spice/spice.mk 2017-05-17 10:27:16.013401440 +0200
8884 +++ buildroot-2017.05.2/package/spice/spice.mk 2017-07-27 08:16:52.017486944 +0200
8885 @@ -4,20 +4,17 @@
8887 ################################################################################
8889 -SPICE_VERSION = 0.12.4
8890 +SPICE_VERSION = 0.12.8
8891 SPICE_SOURCE = spice-$(SPICE_VERSION).tar.bz2
8892 SPICE_SITE = http://www.spice-space.org/download/releases
8893 SPICE_LICENSE = LGPL-2.1+
8894 SPICE_LICENSE_FILES = COPYING
8895 SPICE_INSTALL_STAGING = YES
8896 SPICE_DEPENDENCIES = \
8897 - alsa-lib \
8898 - celt051 \
8899 jpeg \
8900 libglib2 \
8901 openssl \
8902 pixman \
8903 - python-pyparsing \
8904 spice-protocol
8906 # We disable everything for now, because the dependency tree can become
8907 @@ -26,34 +23,30 @@ SPICE_CONF_OPTS = \
8908 --disable-opengl \
8909 --disable-smartcard \
8910 --disable-automated-tests \
8911 - --without-sasl
8912 + --without-sasl \
8913 + --disable-manual
8915 SPICE_DEPENDENCIES += host-pkgconf
8917 -ifeq ($(BR2_PACKAGE_SPICE_CLIENT),y)
8918 -SPICE_CONF_OPTS += --enable-client
8919 -SPICE_DEPENDENCIES += xlib_libXfixes xlib_libXrandr
8920 +ifeq ($(BR2_PACKAGE_CELT051),y)
8921 +SPICE_CONF_OPTS += --enable-celt051
8922 +SPICE_DEPENDENCIES += celt051
8923 else
8924 -SPICE_CONF_OPTS += --disable-client
8925 +SPICE_CONF_OPTS += --disable-celt051
8926 endif
8928 -ifeq ($(BR2_PACKAGE_SPICE_GUI),y)
8929 -SPICE_CONF_OPTS += --enable-gui
8930 -SPICE_DEPENDENCIES += cegui06
8931 +ifeq ($(BR2_PACKAGE_LZ4),y)
8932 +SPICE_CONF_OPTS += --enable-lz4
8933 +SPICE_DEPENDENCIES += lz4
8934 else
8935 -SPICE_CONF_OPTS += --disable-gui
8936 +SPICE_CONF_OPTS += --disable-lz4
8937 endif
8939 -ifeq ($(BR2_PACKAGE_SPICE_TUNNEL),y)
8940 -SPICE_CONF_OPTS += --enable-tunnel
8941 -SPICE_DEPENDENCIES += slirp
8942 -else
8943 -SPICE_CONF_OPTS += --disable-tunnel
8944 +# no enable/disable, detected using pkg-config
8945 +ifeq ($(BR2_PACKAGE_OPUS),y)
8946 +SPICE_DEPENDENCIES += opus
8947 endif
8949 -SPICE_CONF_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
8950 -SPICE_MAKE_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
8952 # We need to tweak spice.pc because it /forgets/ (for static linking) that
8953 # it should link against libz and libjpeg. libz is pkg-config-aware, while
8954 # libjpeg isn't, hence the two-line tweak
8955 diff -Naurp buildroot-2017.05-rc2/package/stella/Config.in buildroot-2017.05.2/package/stella/Config.in
8956 --- buildroot-2017.05-rc2/package/stella/Config.in 2017-05-17 10:27:16.013401440 +0200
8957 +++ buildroot-2017.05.2/package/stella/Config.in 2017-07-27 08:16:52.017486944 +0200
8958 @@ -9,7 +9,7 @@ config BR2_PACKAGE_STELLA
8959 help
8960 Stella is a multi-platform Atari 2600 VCS emulator.
8962 - http://stella.sourceforge.net/
8963 + https://stella-emu.github.io/
8965 comment "stella needs a toolchain w/ dynamic library, C++, gcc >= 4.8"
8966 depends on BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || \
8967 diff -Naurp buildroot-2017.05-rc2/package/stella/stella.mk buildroot-2017.05.2/package/stella/stella.mk
8968 --- buildroot-2017.05-rc2/package/stella/stella.mk 2017-05-17 10:27:16.013401440 +0200
8969 +++ buildroot-2017.05.2/package/stella/stella.mk 2017-07-27 08:16:52.017486944 +0200
8970 @@ -6,7 +6,7 @@
8972 STELLA_VERSION = 4.7.2
8973 STELLA_SOURCE = stella-$(STELLA_VERSION)-src.tar.xz
8974 -STELLA_SITE = http://downloads.sourceforge.net/stella
8975 +STELLA_SITE = https://github.com/stella-emu/stella/releases/download/release-$(STELLA_VERSION)
8976 STELLA_LICENSE = GPL-2.0+
8977 STELLA_LICENSE_FILES = Copyright.txt License.txt
8979 diff -Naurp buildroot-2017.05-rc2/package/stm32flash/Config.in buildroot-2017.05.2/package/stm32flash/Config.in
8980 --- buildroot-2017.05-rc2/package/stm32flash/Config.in 2017-05-17 10:27:16.013401440 +0200
8981 +++ buildroot-2017.05.2/package/stm32flash/Config.in 2017-07-27 08:16:52.017486944 +0200
8982 @@ -2,7 +2,7 @@ config BR2_PACKAGE_STM32FLASH
8983 bool "stm32flash"
8984 help
8985 Open source cross platform flash program for the STM32 ARM
8986 - microcontrollers using the built-in ST serial bootloader over UART
8987 - or I2C.
8988 + microcontrollers using the built-in ST serial bootloader
8989 + over UART or I2C.
8991 http://sourceforge.net/projects/stm32flash/
8992 diff -Naurp buildroot-2017.05-rc2/package/strongswan/strongswan.hash buildroot-2017.05.2/package/strongswan/strongswan.hash
8993 --- buildroot-2017.05-rc2/package/strongswan/strongswan.hash 2017-05-17 10:27:16.013401440 +0200
8994 +++ buildroot-2017.05.2/package/strongswan/strongswan.hash 2017-07-27 08:16:52.017486944 +0200
8995 @@ -2,3 +2,6 @@
8996 md5 9d7c77b0da9b69f859624897e5e9ebbf strongswan-5.4.0.tar.bz2
8997 # Calculated based on the hash above
8998 sha256 f8288faaea6a9cd8a7d413c0b76b7922be5da3dfcd01fd05cb30d2c55d3bbe89 strongswan-5.4.0.tar.bz2
8999 +# Locally calculated
9000 +sha256 f5ba7f46cf7ae81dd81bc86f9e4cfa0c5c7c6987149b3bc9c0b8bf08598a1063 strongswan-4.4.0-5.5.2_gmp_mpz_powm_sec.patch
9001 +sha256 03db8c7a4133e877e8992e155c046dd27ec4810d50f239abf55595f0280caf31 strongswan-5.0.0-5.5.2_asn1_choice.patch
9002 diff -Naurp buildroot-2017.05-rc2/package/strongswan/strongswan.mk buildroot-2017.05.2/package/strongswan/strongswan.mk
9003 --- buildroot-2017.05-rc2/package/strongswan/strongswan.mk 2017-05-17 10:27:16.013401440 +0200
9004 +++ buildroot-2017.05.2/package/strongswan/strongswan.mk 2017-07-27 08:16:52.017486944 +0200
9005 @@ -7,6 +7,9 @@
9006 STRONGSWAN_VERSION = 5.4.0
9007 STRONGSWAN_SOURCE = strongswan-$(STRONGSWAN_VERSION).tar.bz2
9008 STRONGSWAN_SITE = http://download.strongswan.org
9009 +STRONGSWAN_PATCH = \
9010 + $(STRONGSWAN_SITE)/patches/21_gmp_mpz_powm_sec_patch/strongswan-4.4.0-5.5.2_gmp_mpz_powm_sec.patch \
9011 + $(STRONGSWAN_SITE)/patches/22_asn1_choice_patch/strongswan-5.0.0-5.5.2_asn1_choice.patch
9012 STRONGSWAN_LICENSE = GPL-2.0+
9013 STRONGSWAN_LICENSE_FILES = COPYING LICENSE
9014 STRONGSWAN_DEPENDENCIES = host-pkgconf
9015 diff -Naurp buildroot-2017.05-rc2/package/sudo/0001-fix-CVE-2017-1000367.patch buildroot-2017.05.2/package/sudo/0001-fix-CVE-2017-1000367.patch
9016 --- buildroot-2017.05-rc2/package/sudo/0001-fix-CVE-2017-1000367.patch 1970-01-01 01:00:00.000000000 +0100
9017 +++ buildroot-2017.05.2/package/sudo/0001-fix-CVE-2017-1000367.patch 2017-07-27 08:16:52.017486944 +0200
9018 @@ -0,0 +1,264 @@
9019 +Downloaded from upstream: https://www.sudo.ws/repos/sudo/raw-rev/b5460cbbb11b
9021 +# HG changeset patch
9022 +# User Todd C. Miller <Todd.Miller@courtesan.com>
9023 +# Date 1496089973 21600
9024 +# Node ID b5460cbbb11bbf9d92ffcc6798a686cf4125efd3
9025 +# Parent c303e6eecc7841e2f891d70613e80fcf27fa6e86
9026 +Fix for CVE-2017-1000367, parsing of /proc/pid/stat on Linux when
9027 +the process name contains spaces. Since the user has control over
9028 +the command name this could be used by a user with sudo access to
9029 +overwrite an arbitrary file.
9030 +Thanks to Qualys for investigating and reporting this bug.
9032 +Also stop performing a breadth-first traversal of /dev when looking
9033 +for the device. Only the directories specified in search_devs[]
9034 +are checked.
9036 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
9037 +diff -r c303e6eecc78 -r b5460cbbb11b src/ttyname.c
9038 +--- a/src/ttyname.c Tue May 23 13:26:54 2017 -0600
9039 ++++ b/src/ttyname.c Mon May 29 14:32:53 2017 -0600
9040 +@@ -1,5 +1,5 @@
9041 + /*
9042 +- * Copyright (c) 2012-2016 Todd C. Miller <Todd.Miller@courtesan.com>
9043 ++ * Copyright (c) 2012-2017 Todd C. Miller <Todd.Miller@courtesan.com>
9045 + * Permission to use, copy, modify, and distribute this software for any
9046 + * purpose with or without fee is hereby granted, provided that the above
9047 +@@ -145,20 +145,22 @@
9049 + #elif defined(HAVE_STRUCT_PSINFO_PR_TTYDEV) || defined(HAVE_PSTAT_GETPROC) || defined(__linux__)
9050 + /*
9051 +- * Devices to search before doing a breadth-first scan.
9052 ++ * Device nodes and directories to search before searching all of /dev
9053 + */
9054 + static char *search_devs[] = {
9055 + "/dev/console",
9056 +- "/dev/wscons",
9057 +- "/dev/pts/",
9058 +- "/dev/vt/",
9059 +- "/dev/term/",
9060 +- "/dev/zcons/",
9061 ++ "/dev/pts/", /* POSIX pty */
9062 ++ "/dev/vt/", /* Solaris virtual console */
9063 ++ "/dev/term/", /* Solaris serial ports */
9064 ++ "/dev/zcons/", /* Solaris zone console */
9065 ++ "/dev/pty/", /* HP-UX old-style pty */
9066 + NULL
9067 + };
9069 ++/*
9070 ++ * Device nodes to ignore when searching all of /dev
9071 ++ */
9072 + static char *ignore_devs[] = {
9073 +- "/dev/fd/",
9074 + "/dev/stdin",
9075 + "/dev/stdout",
9076 + "/dev/stderr",
9077 +@@ -166,16 +168,18 @@
9078 + };
9080 + /*
9081 +- * Do a breadth-first scan of dir looking for the specified device.
9082 ++ * Do a scan of a directory looking for the specified device.
9083 ++ * Does not descend into subdirectories.
9084 + * Returns name on success and NULL on failure, setting errno.
9085 + */
9086 + static char *
9087 +-sudo_ttyname_scan(const char *dir, dev_t rdev, bool builtin, char *name, size_t namelen)
9088 ++sudo_ttyname_scan(const char *dir, dev_t rdev, char *name, size_t namelen)
9090 +- size_t sdlen, num_subdirs = 0, max_subdirs = 0;
9091 +- char pathbuf[PATH_MAX], **subdirs = NULL;
9092 ++ size_t sdlen;
9093 ++ char pathbuf[PATH_MAX];
9094 + char *ret = NULL;
9095 + struct dirent *dp;
9096 ++ struct stat sb;
9097 + unsigned int i;
9098 + DIR *d = NULL;
9099 + debug_decl(sudo_ttyname_scan, SUDO_DEBUG_UTIL)
9100 +@@ -187,6 +191,18 @@
9101 + if ((d = opendir(dir)) == NULL)
9102 + goto done;
9104 ++ if (fstat(dirfd(d), &sb) == -1) {
9105 ++ sudo_debug_printf(SUDO_DEBUG_ERROR|SUDO_DEBUG_LINENO,
9106 ++ "unable to fstat %s", dir);
9107 ++ goto done;
9108 ++ }
9109 ++ if ((sb.st_mode & S_IWOTH) != 0) {
9110 ++ sudo_debug_printf(SUDO_DEBUG_ERROR|SUDO_DEBUG_LINENO,
9111 ++ "ignoring world-writable directory %s", dir);
9112 ++ errno = ENOENT;
9113 ++ goto done;
9114 ++ }
9116 + sudo_debug_printf(SUDO_DEBUG_INFO|SUDO_DEBUG_LINENO,
9117 + "scanning for dev %u in %s", (unsigned int)rdev, dir);
9119 +@@ -224,18 +240,6 @@
9121 + if (ignore_devs[i] != NULL)
9122 + continue;
9123 +- if (!builtin) {
9124 +- /* Skip entries in search_devs; we already checked them. */
9125 +- for (i = 0; search_devs[i] != NULL; i++) {
9126 +- len = strlen(search_devs[i]);
9127 +- if (search_devs[i][len - 1] == '/')
9128 +- len--;
9129 +- if (d_len == len && strncmp(pathbuf, search_devs[i], len) == 0)
9130 +- break;
9131 +- }
9132 +- if (search_devs[i] != NULL)
9133 +- continue;
9134 +- }
9135 + # if defined(HAVE_STRUCT_DIRENT_D_TYPE) && defined(DTTOIF)
9136 + /*
9137 + * Avoid excessive stat() calls by checking dp->d_type.
9138 +@@ -248,39 +252,14 @@
9139 + if (stat(pathbuf, &sb) == -1)
9140 + continue;
9141 + break;
9142 +- case DT_DIR:
9143 +- /* Directory, no need to stat() it. */
9144 +- sb.st_mode = DTTOIF(dp->d_type);
9145 +- sb.st_rdev = 0; /* quiet ccc-analyzer false positive */
9146 +- break;
9147 + default:
9148 +- /* Not a character device, link or directory, skip it. */
9149 ++ /* Not a character device or link, skip it. */
9150 + continue;
9152 + # else
9153 + if (stat(pathbuf, &sb) == -1)
9154 + continue;
9155 + # endif
9156 +- if (S_ISDIR(sb.st_mode)) {
9157 +- if (!builtin) {
9158 +- /* Add to list of subdirs to search. */
9159 +- if (num_subdirs + 1 > max_subdirs) {
9160 +- char **new_subdirs;
9162 +- new_subdirs = reallocarray(subdirs, max_subdirs + 64,
9163 +- sizeof(char *));
9164 +- if (new_subdirs == NULL)
9165 +- goto done;
9166 +- subdirs = new_subdirs;
9167 +- max_subdirs += 64;
9168 +- }
9169 +- subdirs[num_subdirs] = strdup(pathbuf);
9170 +- if (subdirs[num_subdirs] == NULL)
9171 +- goto done;
9172 +- num_subdirs++;
9173 +- }
9174 +- continue;
9175 +- }
9176 + if (S_ISCHR(sb.st_mode) && sb.st_rdev == rdev) {
9177 + sudo_debug_printf(SUDO_DEBUG_INFO|SUDO_DEBUG_LINENO,
9178 + "resolved dev %u as %s", (unsigned int)rdev, pathbuf);
9179 +@@ -296,16 +275,9 @@
9183 +- /* Search subdirs if we didn't find it in the root level. */
9184 +- for (i = 0; ret == NULL && i < num_subdirs; i++)
9185 +- ret = sudo_ttyname_scan(subdirs[i], rdev, false, name, namelen);
9187 + done:
9188 + if (d != NULL)
9189 + closedir(d);
9190 +- for (i = 0; i < num_subdirs; i++)
9191 +- free(subdirs[i]);
9192 +- free(subdirs);
9193 + debug_return_str(ret);
9196 +@@ -324,7 +296,7 @@
9197 + debug_decl(sudo_ttyname_dev, SUDO_DEBUG_UTIL)
9199 + /*
9200 +- * First check search_devs for common tty devices.
9201 ++ * First check search_devs[] for common tty devices.
9202 + */
9203 + for (sd = search_devs; (devname = *sd) != NULL; sd++) {
9204 + len = strlen(devname);
9205 +@@ -349,7 +321,7 @@
9206 + "comparing dev %u to %s: no", (unsigned int)rdev, buf);
9207 + } else {
9208 + /* Traverse directory */
9209 +- ret = sudo_ttyname_scan(devname, rdev, true, name, namelen);
9210 ++ ret = sudo_ttyname_scan(devname, rdev, name, namelen);
9211 + if (ret != NULL || errno == ENOMEM)
9212 + goto done;
9214 +@@ -367,9 +339,9 @@
9217 + /*
9218 +- * Not found? Do a breadth-first traversal of /dev/.
9219 ++ * Not found? Check all device nodes in /dev.
9220 + */
9221 +- ret = sudo_ttyname_scan(_PATH_DEV, rdev, false, name, namelen);
9222 ++ ret = sudo_ttyname_scan(_PATH_DEV, rdev, name, namelen);
9224 + done:
9225 + debug_return_str(ret);
9226 +@@ -493,28 +465,35 @@
9227 + len = getline(&line, &linesize, fp);
9228 + fclose(fp);
9229 + if (len != -1) {
9230 +- /* Field 7 is the tty dev (0 if no tty) */
9231 +- char *cp = line;
9232 +- char *ep = line;
9233 +- const char *errstr;
9234 +- int field = 0;
9235 +- while (*++ep != '\0') {
9236 +- if (*ep == ' ') {
9237 +- *ep = '\0';
9238 +- if (++field == 7) {
9239 +- dev_t tdev = strtonum(cp, INT_MIN, INT_MAX, &errstr);
9240 +- if (errstr) {
9241 +- sudo_debug_printf(SUDO_DEBUG_ERROR|SUDO_DEBUG_LINENO,
9242 +- "%s: tty device %s: %s", path, cp, errstr);
9243 ++ /*
9244 ++ * Field 7 is the tty dev (0 if no tty).
9245 ++ * Since the process name at field 2 "(comm)" may include spaces,
9246 ++ * start at the last ')' found.
9247 ++ */
9248 ++ char *cp = strrchr(line, ')');
9249 ++ if (cp != NULL) {
9250 ++ char *ep = cp;
9251 ++ const char *errstr;
9252 ++ int field = 1;
9254 ++ while (*++ep != '\0') {
9255 ++ if (*ep == ' ') {
9256 ++ *ep = '\0';
9257 ++ if (++field == 7) {
9258 ++ dev_t tdev = strtonum(cp, INT_MIN, INT_MAX, &errstr);
9259 ++ if (errstr) {
9260 ++ sudo_debug_printf(SUDO_DEBUG_ERROR|SUDO_DEBUG_LINENO,
9261 ++ "%s: tty device %s: %s", path, cp, errstr);
9262 ++ }
9263 ++ if (tdev > 0) {
9264 ++ errno = serrno;
9265 ++ ret = sudo_ttyname_dev(tdev, name, namelen);
9266 ++ goto done;
9267 ++ }
9268 ++ break;
9270 +- if (tdev > 0) {
9271 +- errno = serrno;
9272 +- ret = sudo_ttyname_dev(tdev, name, namelen);
9273 +- goto done;
9274 +- }
9275 +- break;
9276 ++ cp = ep + 1;
9278 +- cp = ep + 1;
9283 diff -Naurp buildroot-2017.05-rc2/package/systemd/0001-fix-getty-unit.patch buildroot-2017.05.2/package/systemd/0001-fix-getty-unit.patch
9284 --- buildroot-2017.05-rc2/package/systemd/0001-fix-getty-unit.patch 2017-05-17 10:27:16.013401440 +0200
9285 +++ buildroot-2017.05.2/package/systemd/0001-fix-getty-unit.patch 1970-01-01 01:00:00.000000000 +0100
9286 @@ -1,30 +0,0 @@
9287 -Prefer getty to agetty in console setup systemd units
9289 -Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
9290 -Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
9291 ----
9293 -diff -aburN systemd-212.orig/units/getty@.service.m4 systemd-212/units/getty@.service.m4
9294 ---- systemd-212.orig/units/getty@.service.m4 2014-01-28 11:08:51.000000000 +0100
9295 -+++ systemd-212/units/getty@.service.m4 2014-03-26 11:06:27.000000000 +0100
9296 -@@ -27,7 +27,7 @@
9298 - [Service]
9299 - # the VT is cleared by TTYVTDisallocate
9300 --ExecStart=-/sbin/agetty --noclear %I $TERM
9301 -+ExecStart=-/sbin/getty -L %I 115200 vt100
9302 - Type=idle
9303 - Restart=always
9304 - RestartSec=0
9305 -diff -aburN systemd-212.orig/units/serial-getty@.service.m4 systemd-212/units/serial-getty@.service.m4
9306 ---- systemd-212.orig/units/serial-getty@.service.m4 2014-03-13 18:47:24.000000000 +0100
9307 -+++ systemd-212/units/serial-getty@.service.m4 2014-03-26 11:07:01.000000000 +0100
9308 -@@ -22,7 +22,7 @@
9309 - IgnoreOnIsolate=yes
9311 - [Service]
9312 --ExecStart=-/sbin/agetty --keep-baud 115200,38400,9600 %I $TERM
9313 -+ExecStart=-/sbin/getty -L %I 115200 vt100
9314 - Type=idle
9315 - Restart=always
9316 - RestartSec=0
9317 diff -Naurp buildroot-2017.05-rc2/package/systemd/0001-resolved-bugfix-of-null-pointer-p-question-dereferencing.patch buildroot-2017.05.2/package/systemd/0001-resolved-bugfix-of-null-pointer-p-question-dereferencing.patch
9318 --- buildroot-2017.05-rc2/package/systemd/0001-resolved-bugfix-of-null-pointer-p-question-dereferencing.patch 1970-01-01 01:00:00.000000000 +0100
9319 +++ buildroot-2017.05.2/package/systemd/0001-resolved-bugfix-of-null-pointer-p-question-dereferencing.patch 2017-07-27 08:16:52.017486944 +0200
9320 @@ -0,0 +1,28 @@
9321 +From a924f43f30f9c4acaf70618dd2a055f8b0f166be Mon Sep 17 00:00:00 2001
9322 +From: Evgeny Vereshchagin <evvers@ya.ru>
9323 +Date: Wed, 24 May 2017 08:56:48 +0300
9324 +Subject: [PATCH] resolved: bugfix of null pointer p->question dereferencing
9325 + (#6020)
9327 +See https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1621396
9329 +[Upstream commit: https://github.com/systemd/systemd/commit/a924f43f30f9c4acaf70618dd2a055f8b0f166be]
9330 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9331 +---
9332 + src/resolve/resolved-dns-packet.c | 3 +++
9333 + 1 file changed, 3 insertions(+)
9335 +diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c
9336 +index 652970284e..240ee448f4 100644
9337 +--- a/src/resolve/resolved-dns-packet.c
9338 ++++ b/src/resolve/resolved-dns-packet.c
9339 +@@ -2269,6 +2269,9 @@ int dns_packet_is_reply_for(DnsPacket *p, const DnsResourceKey *key) {
9340 + if (r < 0)
9341 + return r;
9343 ++ if (!p->question)
9344 ++ return 0;
9346 + if (p->question->n_keys != 1)
9347 + return 0;
9349 diff -Naurp buildroot-2017.05-rc2/package/systemd/0002-build-check-for-ln-relative.patch buildroot-2017.05.2/package/systemd/0002-build-check-for-ln-relative.patch
9350 --- buildroot-2017.05-rc2/package/systemd/0002-build-check-for-ln-relative.patch 2017-05-17 10:27:16.013401440 +0200
9351 +++ buildroot-2017.05.2/package/systemd/0002-build-check-for-ln-relative.patch 1970-01-01 01:00:00.000000000 +0100
9352 @@ -1,96 +0,0 @@
9353 -From c78fa2b40cb8b810d06ef225e30f12a7ed44ffa2 Mon Sep 17 00:00:00 2001
9354 -From: "Yann E. MORIN" <yann.morin.1998@free.fr>
9355 -Date: Sat, 1 Apr 2017 11:26:29 +0200
9356 -Subject: [PATCH] build: check for ln --relative
9358 -ln --relative is recent enough that not all distributions support it.
9359 -This is especially the case for enterprise-grade distributions than can
9360 -have a life-span of more than a decade.
9362 -Detect if ln supports --relative and use it if so.
9364 -If not supported, use a bit of sed magic to construct the ../ sequence,
9365 -that leads back to / when appended to the destination directory.
9367 -We introduce this as a macro that expands to a single command. To avoid
9368 -complexity in the macro, we expect paths to be passed whitout the
9369 -leading DESTDIR.
9371 ----
9372 -Upstream status: submitted, disputed:
9373 - https://github.com/systemd/systemd/pull/5682
9375 ----
9376 - Makefile.am | 25 ++++++++++++++++++++++---
9377 - configure.ac | 5 ++++-
9378 - 2 files changed, 26 insertions(+), 4 deletions(-)
9380 -diff --git a/Makefile.am b/Makefile.am
9381 -index 1cc657a..ec503f2 100644
9382 ---- a/Makefile.am
9383 -+++ b/Makefile.am
9384 -@@ -300,6 +300,24 @@ install-busnames-target-wants-hook:
9385 - what="$(BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(systemunitdir) && $(add-wants)
9386 - what="$(USER_BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(userunitdir) && $(add-wants)
9388 -+# Macro to emulate ln --relative when needed
9389 -+# $(1): options for ln, except --relative
9390 -+# $(2): source file, absolute path without leading DESTDIR
9391 -+# $(3): destination file, absolute path without leading DESTDIR
9392 -+if HAVE_LN_RELATIVE
9393 -+define ln-s-relative
9394 -+ $(LN_S) --relative $(1) \
9395 -+ $(DESTDIR)$(strip $(2)) \
9396 -+ $(DESTDIR)$(strip $(3))
9397 -+endef
9398 -+else
9399 -+define ln-s-relative
9400 -+ $(LN_S) $(1) \
9401 -+ `dirname $(strip $(3)) |sed -r -e 's:/+[^/]+:../:g; s:/$$::'`$(strip $(2)) \
9402 -+ $(DESTDIR)$(strip $(3))
9403 -+endef
9404 -+endif
9406 - define add-wants
9407 - [ -z "$$what" ] || ( \
9408 - dir=$(DESTDIR)$$dir/$$wants.wants && \
9409 -@@ -313,8 +331,9 @@ install-directories-hook:
9410 - $(MKDIR_P) $(addprefix $(DESTDIR),$(INSTALL_DIRS))
9412 - install-environment-conf-hook: install-directories-hook
9413 -- $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(sysconfdir)/environment \
9414 -- $(DESTDIR)$(environmentdir)/99-environment.conf
9415 -+ $(AM_V_LN)$(call ln-s-relative,-f,\
9416 -+ $(sysconfdir)/environment,\
9417 -+ $(environmentdir)/99-environment.conf)
9419 - install-aliases-hook:
9420 - set -- $(SYSTEM_UNIT_ALIASES) && \
9421 -@@ -337,7 +356,7 @@ define install-relative-aliases
9422 - while [ -n "$$1" ]; do \
9423 - $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
9424 - rm -f $(DESTDIR)$$dir/$$2 && \
9425 -- $(LN_S) --relative $(DESTDIR)$$1 $(DESTDIR)$$dir/$$2 && \
9426 -+ $(call ln-s-relative,,$$1,$$dir/$$2) && \
9427 - shift 2 || exit $$?; \
9428 - done
9429 - endef
9430 -diff --git a/configure.ac b/configure.ac
9431 -index cf37ca6..d586fc4 100644
9432 ---- a/configure.ac
9433 -+++ b/configure.ac
9434 -@@ -108,7 +108,10 @@ AC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin])
9435 - AC_PATH_PROG([MOUNT_PATH], [mount], [/usr/bin/mount], [$PATH:/usr/sbin:/sbin])
9436 - AC_PATH_PROG([UMOUNT_PATH], [umount], [/usr/bin/umount], [$PATH:/usr/sbin:/sbin])
9438 --AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])])
9439 -+AC_MSG_CHECKING([if ln supports --relative])
9440 -+AS_IF([! ${LN_S} --relative --help > /dev/null 2>&1], [ln_relative=no], [ln_relative=yes])
9441 -+AC_MSG_RESULT([$ln_relative])
9442 -+AM_CONDITIONAL([HAVE_LN_RELATIVE], [test "x$ln_relative" = "xyes"])
9444 - M4_DEFINES=
9446 ---
9447 -2.9.3
9449 diff -Naurp buildroot-2017.05-rc2/package/systemd/0002-resolved-simplify-alloc-size-calculation.patch buildroot-2017.05.2/package/systemd/0002-resolved-simplify-alloc-size-calculation.patch
9450 --- buildroot-2017.05-rc2/package/systemd/0002-resolved-simplify-alloc-size-calculation.patch 1970-01-01 01:00:00.000000000 +0100
9451 +++ buildroot-2017.05.2/package/systemd/0002-resolved-simplify-alloc-size-calculation.patch 2017-07-27 08:16:52.017486944 +0200
9452 @@ -0,0 +1,51 @@
9453 +From db848813bae4d28c524b3b6a7dad135e426659ce Mon Sep 17 00:00:00 2001
9454 +From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
9455 +Date: Sun, 18 Jun 2017 16:07:57 -0400
9456 +Subject: [PATCH] resolved: simplify alloc size calculation
9458 +The allocation size was calculated in a complicated way, and for values
9459 +close to the page size we would actually allocate less than requested.
9461 +Reported by Chris Coulson <chris.coulson@canonical.com>.
9463 +CVE-2017-9445
9465 +[Upstream commit: https://github.com/systemd/systemd/commit/db848813bae4d28c524b3b6a7dad135e426659ce]
9466 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9467 +---
9468 + src/resolve/resolved-dns-packet.c | 8 +-------
9469 + src/resolve/resolved-dns-packet.h | 2 --
9470 + 2 files changed, 1 insertion(+), 9 deletions(-)
9472 +diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c
9473 +index 240ee448f4..821b66e266 100644
9474 +--- a/src/resolve/resolved-dns-packet.c
9475 ++++ b/src/resolve/resolved-dns-packet.c
9476 +@@ -47,13 +47,7 @@ int dns_packet_new(DnsPacket **ret, DnsProtocol protocol, size_t mtu) {
9478 + assert(ret);
9480 +- if (mtu <= UDP_PACKET_HEADER_SIZE)
9481 +- a = DNS_PACKET_SIZE_START;
9482 +- else
9483 +- a = mtu - UDP_PACKET_HEADER_SIZE;
9485 +- if (a < DNS_PACKET_HEADER_SIZE)
9486 +- a = DNS_PACKET_HEADER_SIZE;
9487 ++ a = MAX(mtu, DNS_PACKET_HEADER_SIZE);
9489 + /* round up to next page size */
9490 + a = PAGE_ALIGN(ALIGN(sizeof(DnsPacket)) + a) - ALIGN(sizeof(DnsPacket));
9491 +diff --git a/src/resolve/resolved-dns-packet.h b/src/resolve/resolved-dns-packet.h
9492 +index 2c92392e4d..3abcaf8cf3 100644
9493 +--- a/src/resolve/resolved-dns-packet.h
9494 ++++ b/src/resolve/resolved-dns-packet.h
9495 +@@ -66,8 +66,6 @@ struct DnsPacketHeader {
9496 + /* With EDNS0 we can use larger packets, default to 4096, which is what is commonly used */
9497 + #define DNS_PACKET_UNICAST_SIZE_LARGE_MAX 4096
9499 +-#define DNS_PACKET_SIZE_START 512
9501 + struct DnsPacket {
9502 + int n_ref;
9503 + DnsProtocol protocol;
9504 diff -Naurp buildroot-2017.05-rc2/package/systemd/0003-fix-am-path-libgcrypt-no-found.patch buildroot-2017.05.2/package/systemd/0003-fix-am-path-libgcrypt-no-found.patch
9505 --- buildroot-2017.05-rc2/package/systemd/0003-fix-am-path-libgcrypt-no-found.patch 2017-05-17 10:27:16.013401440 +0200
9506 +++ buildroot-2017.05.2/package/systemd/0003-fix-am-path-libgcrypt-no-found.patch 1970-01-01 01:00:00.000000000 +0100
9507 @@ -1,145 +0,0 @@
9508 -Fix AM_PATH_LIBGCRYPT not found
9510 -This patch installs a copy of libgcrypt.m4 from the libgcrypt source tarball
9511 -to systemd m4 directory.
9513 -Libgcrypt uses a custom m4 macro and not pkg-config to check if the
9514 -development files are available. Though libgcrypt support is optional in
9515 -systemd, this macro should be available whenever autoreconf is used, otherwise
9516 -the re-configuration will fail with:
9518 - configure.ac:616: warning: macro 'AM_PATH_LIBGCRYPT' not found in library
9520 -As asking the user to install the development package of libgcrypt on the host
9521 -machine or adding libgcrypt as a build dependency to systemd is not
9522 -acceptable, the required file is added to the m4 directory.
9524 -Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
9525 -Index: systemd-213/m4/libgcrypt.m4
9526 -===================================================================
9527 ---- /dev/null 1970-01-01 00:00:00.000000000 +0000
9528 -+++ systemd-213/m4/libgcrypt.m4 2014-06-11 10:41:11.749305509 +0200
9529 -@@ -0,0 +1,123 @@
9530 -+dnl Autoconf macros for libgcrypt
9531 -+dnl Copyright (C) 2002, 2004 Free Software Foundation, Inc.
9532 -+dnl
9533 -+dnl This file is free software; as a special exception the author gives
9534 -+dnl unlimited permission to copy and/or distribute it, with or without
9535 -+dnl modifications, as long as this notice is preserved.
9536 -+dnl
9537 -+dnl This file is distributed in the hope that it will be useful, but
9538 -+dnl WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
9539 -+dnl implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9542 -+dnl AM_PATH_LIBGCRYPT([MINIMUM-VERSION,
9543 -+dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
9544 -+dnl Test for libgcrypt and define LIBGCRYPT_CFLAGS and LIBGCRYPT_LIBS.
9545 -+dnl MINIMUN-VERSION is a string with the version number optionalliy prefixed
9546 -+dnl with the API version to also check the API compatibility. Example:
9547 -+dnl a MINIMUN-VERSION of 1:1.2.5 won't pass the test unless the installed
9548 -+dnl version of libgcrypt is at least 1.2.5 *and* the API number is 1. Using
9549 -+dnl this features allows to prevent build against newer versions of libgcrypt
9550 -+dnl with a changed API.
9551 -+dnl
9552 -+AC_DEFUN([AM_PATH_LIBGCRYPT],
9553 -+[ AC_ARG_WITH(libgcrypt-prefix,
9554 -+ AC_HELP_STRING([--with-libgcrypt-prefix=PFX],
9555 -+ [prefix where LIBGCRYPT is installed (optional)]),
9556 -+ libgcrypt_config_prefix="$withval", libgcrypt_config_prefix="")
9557 -+ if test x$libgcrypt_config_prefix != x ; then
9558 -+ if test x${LIBGCRYPT_CONFIG+set} != xset ; then
9559 -+ LIBGCRYPT_CONFIG=$libgcrypt_config_prefix/bin/libgcrypt-config
9560 -+ fi
9561 -+ fi
9563 -+ AC_PATH_TOOL(LIBGCRYPT_CONFIG, libgcrypt-config, no)
9564 -+ tmp=ifelse([$1], ,1:1.2.0,$1)
9565 -+ if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
9566 -+ req_libgcrypt_api=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\1/'`
9567 -+ min_libgcrypt_version=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\2/'`
9568 -+ else
9569 -+ req_libgcrypt_api=0
9570 -+ min_libgcrypt_version="$tmp"
9571 -+ fi
9573 -+ AC_MSG_CHECKING(for LIBGCRYPT - version >= $min_libgcrypt_version)
9574 -+ ok=no
9575 -+ if test "$LIBGCRYPT_CONFIG" != "no" ; then
9576 -+ req_major=`echo $min_libgcrypt_version | \
9577 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\1/'`
9578 -+ req_minor=`echo $min_libgcrypt_version | \
9579 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
9580 -+ req_micro=`echo $min_libgcrypt_version | \
9581 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
9582 -+ libgcrypt_config_version=`$LIBGCRYPT_CONFIG --version`
9583 -+ major=`echo $libgcrypt_config_version | \
9584 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
9585 -+ minor=`echo $libgcrypt_config_version | \
9586 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
9587 -+ micro=`echo $libgcrypt_config_version | \
9588 -+ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\3/'`
9589 -+ if test "$major" -gt "$req_major"; then
9590 -+ ok=yes
9591 -+ else
9592 -+ if test "$major" -eq "$req_major"; then
9593 -+ if test "$minor" -gt "$req_minor"; then
9594 -+ ok=yes
9595 -+ else
9596 -+ if test "$minor" -eq "$req_minor"; then
9597 -+ if test "$micro" -ge "$req_micro"; then
9598 -+ ok=yes
9599 -+ fi
9600 -+ fi
9601 -+ fi
9602 -+ fi
9603 -+ fi
9604 -+ fi
9605 -+ if test $ok = yes; then
9606 -+ AC_MSG_RESULT([yes ($libgcrypt_config_version)])
9607 -+ else
9608 -+ AC_MSG_RESULT(no)
9609 -+ fi
9610 -+ if test $ok = yes; then
9611 -+ # If we have a recent libgcrypt, we should also check that the
9612 -+ # API is compatible
9613 -+ if test "$req_libgcrypt_api" -gt 0 ; then
9614 -+ tmp=`$LIBGCRYPT_CONFIG --api-version 2>/dev/null || echo 0`
9615 -+ if test "$tmp" -gt 0 ; then
9616 -+ AC_MSG_CHECKING([LIBGCRYPT API version])
9617 -+ if test "$req_libgcrypt_api" -eq "$tmp" ; then
9618 -+ AC_MSG_RESULT([okay])
9619 -+ else
9620 -+ ok=no
9621 -+ AC_MSG_RESULT([does not match. want=$req_libgcrypt_api got=$tmp])
9622 -+ fi
9623 -+ fi
9624 -+ fi
9625 -+ fi
9626 -+ if test $ok = yes; then
9627 -+ LIBGCRYPT_CFLAGS=`$LIBGCRYPT_CONFIG --cflags`
9628 -+ LIBGCRYPT_LIBS=`$LIBGCRYPT_CONFIG --libs`
9629 -+ ifelse([$2], , :, [$2])
9630 -+ if test x"$host" != x ; then
9631 -+ libgcrypt_config_host=`$LIBGCRYPT_CONFIG --host 2>/dev/null || echo none`
9632 -+ if test x"$libgcrypt_config_host" != xnone ; then
9633 -+ if test x"$libgcrypt_config_host" != x"$host" ; then
9634 -+ AC_MSG_WARN([[
9635 -+***
9636 -+*** The config script $LIBGCRYPT_CONFIG was
9637 -+*** built for $libgcrypt_config_host and thus may not match the
9638 -+*** used host $host.
9639 -+*** You may want to use the configure option --with-libgcrypt-prefix
9640 -+*** to specify a matching config script.
9641 -+***]])
9642 -+ fi
9643 -+ fi
9644 -+ fi
9645 -+ else
9646 -+ LIBGCRYPT_CFLAGS=""
9647 -+ LIBGCRYPT_LIBS=""
9648 -+ ifelse([$3], , :, [$3])
9649 -+ fi
9650 -+ AC_SUBST(LIBGCRYPT_CFLAGS)
9651 -+ AC_SUBST(LIBGCRYPT_LIBS)
9652 -+])
9653 diff -Naurp buildroot-2017.05-rc2/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch buildroot-2017.05.2/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch
9654 --- buildroot-2017.05-rc2/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch 1970-01-01 01:00:00.000000000 +0100
9655 +++ buildroot-2017.05.2/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch 2017-07-27 08:16:52.017486944 +0200
9656 @@ -0,0 +1,48 @@
9657 +From 88795538726a5bbfd9efc13d441cb05e1d7fc139 Mon Sep 17 00:00:00 2001
9658 +From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
9659 +Date: Tue, 27 Jun 2017 14:20:00 -0400
9660 +Subject: [PATCH] resolved: do not allocate packets with minimum size
9662 +dns_packet_new() is sometimes called with mtu == 0, and in that case we should
9663 +allocate more than the absolute minimum (which is the dns packet header size),
9664 +otherwise we have to resize immediately again after appending the first data to
9665 +the packet.
9667 +This partially reverts the previous commit.
9669 +[Upstream commit: https://github.com/systemd/systemd/commit/88795538726a5bbfd9efc13d441cb05e1d7fc139]
9670 +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9671 +---
9672 + src/resolve/resolved-dns-packet.c | 12 +++++++++++-
9673 + 1 file changed, 11 insertions(+), 1 deletion(-)
9675 +diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c
9676 +index 821b66e266..d1f0f760a4 100644
9677 +--- a/src/resolve/resolved-dns-packet.c
9678 ++++ b/src/resolve/resolved-dns-packet.c
9679 +@@ -28,6 +28,9 @@
9681 + #define EDNS0_OPT_DO (1<<15)
9683 ++#define DNS_PACKET_SIZE_START 512
9684 ++assert_cc(DNS_PACKET_SIZE_START > UDP_PACKET_HEADER_SIZE)
9686 + typedef struct DnsPacketRewinder {
9687 + DnsPacket *packet;
9688 + size_t saved_rindex;
9689 +@@ -47,7 +50,14 @@ int dns_packet_new(DnsPacket **ret, DnsProtocol protocol, size_t mtu) {
9691 + assert(ret);
9693 +- a = MAX(mtu, DNS_PACKET_HEADER_SIZE);
9694 ++ /* When dns_packet_new() is called with mtu == 0, allocate more than the
9695 ++ * absolute minimum (which is the dns packet header size), to avoid
9696 ++ * resizing immediately again after appending the first data to the packet.
9697 ++ */
9698 ++ if (mtu < UDP_PACKET_HEADER_SIZE)
9699 ++ a = DNS_PACKET_SIZE_START;
9700 ++ else
9701 ++ a = MAX(mtu, DNS_PACKET_HEADER_SIZE);
9703 + /* round up to next page size */
9704 + a = PAGE_ALIGN(ALIGN(sizeof(DnsPacket)) + a) - ALIGN(sizeof(DnsPacket));
9705 diff -Naurp buildroot-2017.05-rc2/package/systemd/0004-fix-getty-unit.patch buildroot-2017.05.2/package/systemd/0004-fix-getty-unit.patch
9706 --- buildroot-2017.05-rc2/package/systemd/0004-fix-getty-unit.patch 1970-01-01 01:00:00.000000000 +0100
9707 +++ buildroot-2017.05.2/package/systemd/0004-fix-getty-unit.patch 2017-07-27 08:16:52.017486944 +0200
9708 @@ -0,0 +1,30 @@
9709 +Prefer getty to agetty in console setup systemd units
9711 +Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
9712 +Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
9713 +---
9715 +diff -aburN systemd-212.orig/units/getty@.service.m4 systemd-212/units/getty@.service.m4
9716 +--- systemd-212.orig/units/getty@.service.m4 2014-01-28 11:08:51.000000000 +0100
9717 ++++ systemd-212/units/getty@.service.m4 2014-03-26 11:06:27.000000000 +0100
9718 +@@ -27,7 +27,7 @@
9720 + [Service]
9721 + # the VT is cleared by TTYVTDisallocate
9722 +-ExecStart=-/sbin/agetty --noclear %I $TERM
9723 ++ExecStart=-/sbin/getty -L %I 115200 vt100
9724 + Type=idle
9725 + Restart=always
9726 + RestartSec=0
9727 +diff -aburN systemd-212.orig/units/serial-getty@.service.m4 systemd-212/units/serial-getty@.service.m4
9728 +--- systemd-212.orig/units/serial-getty@.service.m4 2014-03-13 18:47:24.000000000 +0100
9729 ++++ systemd-212/units/serial-getty@.service.m4 2014-03-26 11:07:01.000000000 +0100
9730 +@@ -22,7 +22,7 @@
9731 + IgnoreOnIsolate=yes
9733 + [Service]
9734 +-ExecStart=-/sbin/agetty --keep-baud 115200,38400,9600 %I $TERM
9735 ++ExecStart=-/sbin/getty -L %I 115200 vt100
9736 + Type=idle
9737 + Restart=always
9738 + RestartSec=0
9739 diff -Naurp buildroot-2017.05-rc2/package/systemd/0005-build-check-for-ln-relative.patch buildroot-2017.05.2/package/systemd/0005-build-check-for-ln-relative.patch
9740 --- buildroot-2017.05-rc2/package/systemd/0005-build-check-for-ln-relative.patch 1970-01-01 01:00:00.000000000 +0100
9741 +++ buildroot-2017.05.2/package/systemd/0005-build-check-for-ln-relative.patch 2017-07-27 08:16:52.017486944 +0200
9742 @@ -0,0 +1,96 @@
9743 +From c78fa2b40cb8b810d06ef225e30f12a7ed44ffa2 Mon Sep 17 00:00:00 2001
9744 +From: "Yann E. MORIN" <yann.morin.1998@free.fr>
9745 +Date: Sat, 1 Apr 2017 11:26:29 +0200
9746 +Subject: [PATCH] build: check for ln --relative
9748 +ln --relative is recent enough that not all distributions support it.
9749 +This is especially the case for enterprise-grade distributions than can
9750 +have a life-span of more than a decade.
9752 +Detect if ln supports --relative and use it if so.
9754 +If not supported, use a bit of sed magic to construct the ../ sequence,
9755 +that leads back to / when appended to the destination directory.
9757 +We introduce this as a macro that expands to a single command. To avoid
9758 +complexity in the macro, we expect paths to be passed whitout the
9759 +leading DESTDIR.
9761 +---
9762 +Upstream status: submitted, disputed:
9763 + https://github.com/systemd/systemd/pull/5682
9765 +---
9766 + Makefile.am | 25 ++++++++++++++++++++++---
9767 + configure.ac | 5 ++++-
9768 + 2 files changed, 26 insertions(+), 4 deletions(-)
9770 +diff --git a/Makefile.am b/Makefile.am
9771 +index 1cc657a..ec503f2 100644
9772 +--- a/Makefile.am
9773 ++++ b/Makefile.am
9774 +@@ -300,6 +300,24 @@ install-busnames-target-wants-hook:
9775 + what="$(BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(systemunitdir) && $(add-wants)
9776 + what="$(USER_BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(userunitdir) && $(add-wants)
9778 ++# Macro to emulate ln --relative when needed
9779 ++# $(1): options for ln, except --relative
9780 ++# $(2): source file, absolute path without leading DESTDIR
9781 ++# $(3): destination file, absolute path without leading DESTDIR
9782 ++if HAVE_LN_RELATIVE
9783 ++define ln-s-relative
9784 ++ $(LN_S) --relative $(1) \
9785 ++ $(DESTDIR)$(strip $(2)) \
9786 ++ $(DESTDIR)$(strip $(3))
9787 ++endef
9788 ++else
9789 ++define ln-s-relative
9790 ++ $(LN_S) $(1) \
9791 ++ `dirname $(strip $(3)) |sed -r -e 's:/+[^/]+:../:g; s:/$$::'`$(strip $(2)) \
9792 ++ $(DESTDIR)$(strip $(3))
9793 ++endef
9794 ++endif
9796 + define add-wants
9797 + [ -z "$$what" ] || ( \
9798 + dir=$(DESTDIR)$$dir/$$wants.wants && \
9799 +@@ -313,8 +331,9 @@ install-directories-hook:
9800 + $(MKDIR_P) $(addprefix $(DESTDIR),$(INSTALL_DIRS))
9802 + install-environment-conf-hook: install-directories-hook
9803 +- $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(sysconfdir)/environment \
9804 +- $(DESTDIR)$(environmentdir)/99-environment.conf
9805 ++ $(AM_V_LN)$(call ln-s-relative,-f,\
9806 ++ $(sysconfdir)/environment,\
9807 ++ $(environmentdir)/99-environment.conf)
9809 + install-aliases-hook:
9810 + set -- $(SYSTEM_UNIT_ALIASES) && \
9811 +@@ -337,7 +356,7 @@ define install-relative-aliases
9812 + while [ -n "$$1" ]; do \
9813 + $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
9814 + rm -f $(DESTDIR)$$dir/$$2 && \
9815 +- $(LN_S) --relative $(DESTDIR)$$1 $(DESTDIR)$$dir/$$2 && \
9816 ++ $(call ln-s-relative,,$$1,$$dir/$$2) && \
9817 + shift 2 || exit $$?; \
9818 + done
9819 + endef
9820 +diff --git a/configure.ac b/configure.ac
9821 +index cf37ca6..d586fc4 100644
9822 +--- a/configure.ac
9823 ++++ b/configure.ac
9824 +@@ -108,7 +108,10 @@ AC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin])
9825 + AC_PATH_PROG([MOUNT_PATH], [mount], [/usr/bin/mount], [$PATH:/usr/sbin:/sbin])
9826 + AC_PATH_PROG([UMOUNT_PATH], [umount], [/usr/bin/umount], [$PATH:/usr/sbin:/sbin])
9828 +-AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])])
9829 ++AC_MSG_CHECKING([if ln supports --relative])
9830 ++AS_IF([! ${LN_S} --relative --help > /dev/null 2>&1], [ln_relative=no], [ln_relative=yes])
9831 ++AC_MSG_RESULT([$ln_relative])
9832 ++AM_CONDITIONAL([HAVE_LN_RELATIVE], [test "x$ln_relative" = "xyes"])
9834 + M4_DEFINES=
9836 +--
9837 +2.9.3
9839 diff -Naurp buildroot-2017.05-rc2/package/systemd/0006-fix-am-path-libgcrypt-no-found.patch buildroot-2017.05.2/package/systemd/0006-fix-am-path-libgcrypt-no-found.patch
9840 --- buildroot-2017.05-rc2/package/systemd/0006-fix-am-path-libgcrypt-no-found.patch 1970-01-01 01:00:00.000000000 +0100
9841 +++ buildroot-2017.05.2/package/systemd/0006-fix-am-path-libgcrypt-no-found.patch 2017-07-27 08:16:52.017486944 +0200
9842 @@ -0,0 +1,145 @@
9843 +Fix AM_PATH_LIBGCRYPT not found
9845 +This patch installs a copy of libgcrypt.m4 from the libgcrypt source tarball
9846 +to systemd m4 directory.
9848 +Libgcrypt uses a custom m4 macro and not pkg-config to check if the
9849 +development files are available. Though libgcrypt support is optional in
9850 +systemd, this macro should be available whenever autoreconf is used, otherwise
9851 +the re-configuration will fail with:
9853 + configure.ac:616: warning: macro 'AM_PATH_LIBGCRYPT' not found in library
9855 +As asking the user to install the development package of libgcrypt on the host
9856 +machine or adding libgcrypt as a build dependency to systemd is not
9857 +acceptable, the required file is added to the m4 directory.
9859 +Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
9860 +Index: systemd-213/m4/libgcrypt.m4
9861 +===================================================================
9862 +--- /dev/null 1970-01-01 00:00:00.000000000 +0000
9863 ++++ systemd-213/m4/libgcrypt.m4 2014-06-11 10:41:11.749305509 +0200
9864 +@@ -0,0 +1,123 @@
9865 ++dnl Autoconf macros for libgcrypt
9866 ++dnl Copyright (C) 2002, 2004 Free Software Foundation, Inc.
9867 ++dnl
9868 ++dnl This file is free software; as a special exception the author gives
9869 ++dnl unlimited permission to copy and/or distribute it, with or without
9870 ++dnl modifications, as long as this notice is preserved.
9871 ++dnl
9872 ++dnl This file is distributed in the hope that it will be useful, but
9873 ++dnl WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
9874 ++dnl implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9877 ++dnl AM_PATH_LIBGCRYPT([MINIMUM-VERSION,
9878 ++dnl [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
9879 ++dnl Test for libgcrypt and define LIBGCRYPT_CFLAGS and LIBGCRYPT_LIBS.
9880 ++dnl MINIMUN-VERSION is a string with the version number optionalliy prefixed
9881 ++dnl with the API version to also check the API compatibility. Example:
9882 ++dnl a MINIMUN-VERSION of 1:1.2.5 won't pass the test unless the installed
9883 ++dnl version of libgcrypt is at least 1.2.5 *and* the API number is 1. Using
9884 ++dnl this features allows to prevent build against newer versions of libgcrypt
9885 ++dnl with a changed API.
9886 ++dnl
9887 ++AC_DEFUN([AM_PATH_LIBGCRYPT],
9888 ++[ AC_ARG_WITH(libgcrypt-prefix,
9889 ++ AC_HELP_STRING([--with-libgcrypt-prefix=PFX],
9890 ++ [prefix where LIBGCRYPT is installed (optional)]),
9891 ++ libgcrypt_config_prefix="$withval", libgcrypt_config_prefix="")
9892 ++ if test x$libgcrypt_config_prefix != x ; then
9893 ++ if test x${LIBGCRYPT_CONFIG+set} != xset ; then
9894 ++ LIBGCRYPT_CONFIG=$libgcrypt_config_prefix/bin/libgcrypt-config
9895 ++ fi
9896 ++ fi
9898 ++ AC_PATH_TOOL(LIBGCRYPT_CONFIG, libgcrypt-config, no)
9899 ++ tmp=ifelse([$1], ,1:1.2.0,$1)
9900 ++ if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
9901 ++ req_libgcrypt_api=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\1/'`
9902 ++ min_libgcrypt_version=`echo "$tmp" | sed 's/\(.*\):\(.*\)/\2/'`
9903 ++ else
9904 ++ req_libgcrypt_api=0
9905 ++ min_libgcrypt_version="$tmp"
9906 ++ fi
9908 ++ AC_MSG_CHECKING(for LIBGCRYPT - version >= $min_libgcrypt_version)
9909 ++ ok=no
9910 ++ if test "$LIBGCRYPT_CONFIG" != "no" ; then
9911 ++ req_major=`echo $min_libgcrypt_version | \
9912 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\1/'`
9913 ++ req_minor=`echo $min_libgcrypt_version | \
9914 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
9915 ++ req_micro=`echo $min_libgcrypt_version | \
9916 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
9917 ++ libgcrypt_config_version=`$LIBGCRYPT_CONFIG --version`
9918 ++ major=`echo $libgcrypt_config_version | \
9919 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
9920 ++ minor=`echo $libgcrypt_config_version | \
9921 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
9922 ++ micro=`echo $libgcrypt_config_version | \
9923 ++ sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\3/'`
9924 ++ if test "$major" -gt "$req_major"; then
9925 ++ ok=yes
9926 ++ else
9927 ++ if test "$major" -eq "$req_major"; then
9928 ++ if test "$minor" -gt "$req_minor"; then
9929 ++ ok=yes
9930 ++ else
9931 ++ if test "$minor" -eq "$req_minor"; then
9932 ++ if test "$micro" -ge "$req_micro"; then
9933 ++ ok=yes
9934 ++ fi
9935 ++ fi
9936 ++ fi
9937 ++ fi
9938 ++ fi
9939 ++ fi
9940 ++ if test $ok = yes; then
9941 ++ AC_MSG_RESULT([yes ($libgcrypt_config_version)])
9942 ++ else
9943 ++ AC_MSG_RESULT(no)
9944 ++ fi
9945 ++ if test $ok = yes; then
9946 ++ # If we have a recent libgcrypt, we should also check that the
9947 ++ # API is compatible
9948 ++ if test "$req_libgcrypt_api" -gt 0 ; then
9949 ++ tmp=`$LIBGCRYPT_CONFIG --api-version 2>/dev/null || echo 0`
9950 ++ if test "$tmp" -gt 0 ; then
9951 ++ AC_MSG_CHECKING([LIBGCRYPT API version])
9952 ++ if test "$req_libgcrypt_api" -eq "$tmp" ; then
9953 ++ AC_MSG_RESULT([okay])
9954 ++ else
9955 ++ ok=no
9956 ++ AC_MSG_RESULT([does not match. want=$req_libgcrypt_api got=$tmp])
9957 ++ fi
9958 ++ fi
9959 ++ fi
9960 ++ fi
9961 ++ if test $ok = yes; then
9962 ++ LIBGCRYPT_CFLAGS=`$LIBGCRYPT_CONFIG --cflags`
9963 ++ LIBGCRYPT_LIBS=`$LIBGCRYPT_CONFIG --libs`
9964 ++ ifelse([$2], , :, [$2])
9965 ++ if test x"$host" != x ; then
9966 ++ libgcrypt_config_host=`$LIBGCRYPT_CONFIG --host 2>/dev/null || echo none`
9967 ++ if test x"$libgcrypt_config_host" != xnone ; then
9968 ++ if test x"$libgcrypt_config_host" != x"$host" ; then
9969 ++ AC_MSG_WARN([[
9970 ++***
9971 ++*** The config script $LIBGCRYPT_CONFIG was
9972 ++*** built for $libgcrypt_config_host and thus may not match the
9973 ++*** used host $host.
9974 ++*** You may want to use the configure option --with-libgcrypt-prefix
9975 ++*** to specify a matching config script.
9976 ++***]])
9977 ++ fi
9978 ++ fi
9979 ++ fi
9980 ++ else
9981 ++ LIBGCRYPT_CFLAGS=""
9982 ++ LIBGCRYPT_LIBS=""
9983 ++ ifelse([$3], , :, [$3])
9984 ++ fi
9985 ++ AC_SUBST(LIBGCRYPT_CFLAGS)
9986 ++ AC_SUBST(LIBGCRYPT_LIBS)
9987 ++])
9988 diff -Naurp buildroot-2017.05-rc2/package/systemd/Config.in buildroot-2017.05.2/package/systemd/Config.in
9989 --- buildroot-2017.05-rc2/package/systemd/Config.in 2017-05-17 10:27:16.013401440 +0200
9990 +++ buildroot-2017.05.2/package/systemd/Config.in 2017-07-27 08:16:52.017486944 +0200
9991 @@ -26,6 +26,7 @@ menuconfig BR2_PACKAGE_SYSTEMD
9992 select BR2_PACKAGE_KMOD
9993 select BR2_PACKAGE_BUSYBOX_SHOW_OTHERS # kmod-tools
9994 select BR2_PACKAGE_KMOD_TOOLS
9995 + select BR2_TARGET_TZ_INFO
9996 help
9997 systemd is a system and service manager for Linux, compatible with
9998 SysV and LSB init scripts. systemd provides aggressive parallelization
9999 diff -Naurp buildroot-2017.05-rc2/package/systemd/systemd.mk buildroot-2017.05.2/package/systemd/systemd.mk
10000 --- buildroot-2017.05-rc2/package/systemd/systemd.mk 2017-05-17 10:27:16.013401440 +0200
10001 +++ buildroot-2017.05.2/package/systemd/systemd.mk 2017-07-27 08:16:52.017486944 +0200
10002 @@ -42,10 +42,16 @@ SYSTEMD_CONF_OPTS += \
10004 SYSTEMD_CFLAGS = $(TARGET_CFLAGS) -fno-lto
10006 -# Override path to kmod, used in kmod-static-nodes.service
10007 +# Override paths to a few utilities needed at runtime, to
10008 +# avoid finding those we would install in $(HOST_DIR).
10009 SYSTEMD_CONF_ENV = \
10010 CFLAGS="$(SYSTEMD_CFLAGS)" \
10011 - ac_cv_path_KMOD=/usr/bin/kmod
10012 + ac_cv_path_KILL=/usr/bin/kill \
10013 + ac_cv_path_KMOD=/usr/bin/kmod \
10014 + ac_cv_path_KEXEC=/usr/sbin/kexec \
10015 + ac_cv_path_SULOGIN=/usr/sbin/sulogin \
10016 + ac_cv_path_MOUNT_PATH=/usr/bin/mount \
10017 + ac_cv_path_UMOUNT_PATH=/usr/bin/umount
10019 define SYSTEMD_RUN_INTLTOOLIZE
10020 cd $(@D) && $(HOST_DIR)/usr/bin/intltoolize --force --automake
10021 @@ -179,8 +185,14 @@ endif
10023 ifeq ($(BR2_PACKAGE_SYSTEMD_QUOTACHECK),y)
10024 SYSTEMD_CONF_OPTS += --enable-quotacheck
10025 +SYSTEMD_CONF_ENV += \
10026 + ac_cv_path_QUOTAON=/usr/sbin/quotaon \
10027 + ac_cv_path_QUOTACHECK=/usr/sbin/quotacheck
10028 else
10029 SYSTEMD_CONF_OPTS += --disable-quotacheck
10030 +SYSTEMD_CONF_ENV += \
10031 + ac_cv_path_QUOTAON=/.missing \
10032 + ac_cv_path_QUOTACHECK=/.missing
10033 endif
10035 ifeq ($(BR2_PACKAGE_SYSTEMD_TMPFILES),y)
10036 diff -Naurp buildroot-2017.05-rc2/package/taskd/Config.in buildroot-2017.05.2/package/taskd/Config.in
10037 --- buildroot-2017.05-rc2/package/taskd/Config.in 2017-05-17 10:27:16.013401440 +0200
10038 +++ buildroot-2017.05.2/package/taskd/Config.in 2017-07-27 08:16:52.017486944 +0200
10039 @@ -1,5 +1,6 @@
10040 config BR2_PACKAGE_TASKD
10041 bool "taskd"
10042 + depends on !BR2_STATIC_LIBS # gnutls
10043 depends on BR2_USE_WCHAR # gnutls
10044 depends on BR2_USE_MMU # fork()
10045 depends on BR2_INSTALL_LIBSTDCPP
10046 @@ -11,6 +12,7 @@ config BR2_PACKAGE_TASKD
10048 http://taskwarrior.org/
10050 -comment "taskd needs a toolchain w/ C++, wchar"
10051 +comment "taskd needs a toolchain w/ C++, wchar, dynamic library"
10052 depends on BR2_USE_MMU
10053 - depends on !BR2_USE_WCHAR || !BR2_INSTALL_LIBSTDCPP
10054 + depends on !BR2_USE_WCHAR || !BR2_INSTALL_LIBSTDCPP || \
10055 + BR2_STATIC_LIBS
10056 diff -Naurp buildroot-2017.05-rc2/package/tcpdump/tcpdump.hash buildroot-2017.05.2/package/tcpdump/tcpdump.hash
10057 --- buildroot-2017.05-rc2/package/tcpdump/tcpdump.hash 2017-05-17 10:27:16.013401440 +0200
10058 +++ buildroot-2017.05.2/package/tcpdump/tcpdump.hash 2017-07-27 08:16:52.017486944 +0200
10059 @@ -1,2 +1,2 @@
10060 -# Locally calculated after checking pgp signature
10061 -sha256 eae98121cbb1c9adbedd9a777bf2eae9fa1c1c676424a54740311c8abcee5a5e tcpdump-4.9.0.tar.gz
10062 +# Locally calculated after checking pgp signature at http://www.tcpdump.org/release/tcpdump-4.9.1.tar.gz.sig
10063 +sha256 f9448cf4deb2049acf713655c736342662e652ef40dbe0a8f6f8d5b9ce5bd8f3 tcpdump-4.9.1.tar.gz
10064 diff -Naurp buildroot-2017.05-rc2/package/tcpdump/tcpdump.mk buildroot-2017.05.2/package/tcpdump/tcpdump.mk
10065 --- buildroot-2017.05-rc2/package/tcpdump/tcpdump.mk 2017-05-17 10:27:16.013401440 +0200
10066 +++ buildroot-2017.05.2/package/tcpdump/tcpdump.mk 2017-07-27 08:16:52.017486944 +0200
10067 @@ -4,7 +4,7 @@
10069 ################################################################################
10071 -TCPDUMP_VERSION = 4.9.0
10072 +TCPDUMP_VERSION = 4.9.1
10073 TCPDUMP_SITE = http://www.tcpdump.org/release
10074 TCPDUMP_LICENSE = BSD-3-Clause
10075 TCPDUMP_LICENSE_FILES = LICENSE
10076 diff -Naurp buildroot-2017.05-rc2/package/tiff/0001-libtiff-tif_dirwrite.c-in-TIFFWriteDirectoryTagCheck.patch buildroot-2017.05.2/package/tiff/0001-libtiff-tif_dirwrite.c-in-TIFFWriteDirectoryTagCheck.patch
10077 --- buildroot-2017.05-rc2/package/tiff/0001-libtiff-tif_dirwrite.c-in-TIFFWriteDirectoryTagCheck.patch 1970-01-01 01:00:00.000000000 +0100
10078 +++ buildroot-2017.05.2/package/tiff/0001-libtiff-tif_dirwrite.c-in-TIFFWriteDirectoryTagCheck.patch 2017-07-27 08:16:52.017486944 +0200
10079 @@ -0,0 +1,70 @@
10080 +From 6173a57d39e04d68b139f8c1aa499a24dbe74ba1 Mon Sep 17 00:00:00 2001
10081 +From: Even Rouault <even.rouault@spatialys.com>
10082 +Date: Fri, 30 Jun 2017 17:29:44 +0000
10083 +Subject: [PATCH] * libtiff/tif_dirwrite.c: in
10084 + TIFFWriteDirectoryTagCheckedXXXX() functions associated with LONG8/SLONG8
10085 + data type, replace assertion that the file is BigTIFF, by a non-fatal error.
10086 + Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2712 Reported by team
10087 + OWL337
10089 +[Peter: drop ChangeLog modification]
10090 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10091 +---
10092 + libtiff/tif_dirwrite.c | 20 ++++++++++++++++----
10093 + 1 file changed, 23 insertions(+), 4 deletions(-)
10095 +diff --git a/libtiff/tif_dirwrite.c b/libtiff/tif_dirwrite.c
10096 +index 2967da58..8d6686ba 100644
10097 +--- a/libtiff/tif_dirwrite.c
10098 ++++ b/libtiff/tif_dirwrite.c
10099 +@@ -2111,7 +2111,10 @@ TIFFWriteDirectoryTagCheckedLong8(TIFF* tif, uint32* ndir, TIFFDirEntry* dir, ui
10101 + uint64 m;
10102 + assert(sizeof(uint64)==8);
10103 +- assert(tif->tif_flags&TIFF_BIGTIFF);
10104 ++ if( !(tif->tif_flags&TIFF_BIGTIFF) ) {
10105 ++ TIFFErrorExt(tif->tif_clientdata,"TIFFWriteDirectoryTagCheckedLong8","LONG8 not allowed for ClassicTIFF");
10106 ++ return(0);
10107 ++ }
10108 + m=value;
10109 + if (tif->tif_flags&TIFF_SWAB)
10110 + TIFFSwabLong8(&m);
10111 +@@ -2124,7 +2127,10 @@ TIFFWriteDirectoryTagCheckedLong8Array(TIFF* tif, uint32* ndir, TIFFDirEntry* di
10113 + assert(count<0x20000000);
10114 + assert(sizeof(uint64)==8);
10115 +- assert(tif->tif_flags&TIFF_BIGTIFF);
10116 ++ if( !(tif->tif_flags&TIFF_BIGTIFF) ) {
10117 ++ TIFFErrorExt(tif->tif_clientdata,"TIFFWriteDirectoryTagCheckedLong8","LONG8 not allowed for ClassicTIFF");
10118 ++ return(0);
10119 ++ }
10120 + if (tif->tif_flags&TIFF_SWAB)
10121 + TIFFSwabArrayOfLong8(value,count);
10122 + return(TIFFWriteDirectoryTagData(tif,ndir,dir,tag,TIFF_LONG8,count,count*8,value));
10123 +@@ -2136,7 +2142,10 @@ TIFFWriteDirectoryTagCheckedSlong8(TIFF* tif, uint32* ndir, TIFFDirEntry* dir, u
10125 + int64 m;
10126 + assert(sizeof(int64)==8);
10127 +- assert(tif->tif_flags&TIFF_BIGTIFF);
10128 ++ if( !(tif->tif_flags&TIFF_BIGTIFF) ) {
10129 ++ TIFFErrorExt(tif->tif_clientdata,"TIFFWriteDirectoryTagCheckedLong8","SLONG8 not allowed for ClassicTIFF");
10130 ++ return(0);
10131 ++ }
10132 + m=value;
10133 + if (tif->tif_flags&TIFF_SWAB)
10134 + TIFFSwabLong8((uint64*)(&m));
10135 +@@ -2149,7 +2158,10 @@ TIFFWriteDirectoryTagCheckedSlong8Array(TIFF* tif, uint32* ndir, TIFFDirEntry* d
10137 + assert(count<0x20000000);
10138 + assert(sizeof(int64)==8);
10139 +- assert(tif->tif_flags&TIFF_BIGTIFF);
10140 ++ if( !(tif->tif_flags&TIFF_BIGTIFF) ) {
10141 ++ TIFFErrorExt(tif->tif_clientdata,"TIFFWriteDirectoryTagCheckedLong8","SLONG8 not allowed for ClassicTIFF");
10142 ++ return(0);
10143 ++ }
10144 + if (tif->tif_flags&TIFF_SWAB)
10145 + TIFFSwabArrayOfLong8((uint64*)value,count);
10146 + return(TIFFWriteDirectoryTagData(tif,ndir,dir,tag,TIFF_SLONG8,count,count*8,value));
10147 +--
10148 +2.11.0
10150 diff -Naurp buildroot-2017.05-rc2/package/tiff/0001-libtiff-tif_read.c-libtiff-tiffiop.h-fix-uint32-over.patch buildroot-2017.05.2/package/tiff/0001-libtiff-tif_read.c-libtiff-tiffiop.h-fix-uint32-over.patch
10151 --- buildroot-2017.05-rc2/package/tiff/0001-libtiff-tif_read.c-libtiff-tiffiop.h-fix-uint32-over.patch 2017-05-17 10:27:16.013401440 +0200
10152 +++ buildroot-2017.05.2/package/tiff/0001-libtiff-tif_read.c-libtiff-tiffiop.h-fix-uint32-over.patch 1970-01-01 01:00:00.000000000 +0100
10153 @@ -1,46 +0,0 @@
10154 -From 438274f938e046d33cb0e1230b41da32ffe223e1 Mon Sep 17 00:00:00 2001
10155 -From: erouault <erouault>
10156 -Date: Fri, 2 Dec 2016 21:56:56 +0000
10157 -Subject: [PATCH] * libtiff/tif_read.c, libtiff/tiffiop.h: fix uint32 overflow
10158 - in TIFFReadEncodedStrip() that caused an integer division by zero. Reported
10159 - by Agostino Sarubbo. Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2596
10161 -Fixes CVE-2016-10266
10163 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10164 ----
10165 - libtiff/tif_read.c | 2 +-
10166 - libtiff/tiffiop.h | 4 ++++
10167 - 2 files changed, 12 insertions(+), 1 deletion(-)
10169 -diff --git a/libtiff/tif_read.c b/libtiff/tif_read.c
10170 -index c26c55f4..52bbf507 100644
10171 ---- a/libtiff/tif_read.c
10172 -+++ b/libtiff/tif_read.c
10173 -@@ -346,7 +346,7 @@ TIFFReadEncodedStrip(TIFF* tif, uint32 strip, void* buf, tmsize_t size)
10174 - rowsperstrip=td->td_rowsperstrip;
10175 - if (rowsperstrip>td->td_imagelength)
10176 - rowsperstrip=td->td_imagelength;
10177 -- stripsperplane=((td->td_imagelength+rowsperstrip-1)/rowsperstrip);
10178 -+ stripsperplane= TIFFhowmany_32_maxuint_compat(td->td_imagelength, rowsperstrip);
10179 - stripinplane=(strip%stripsperplane);
10180 - plane=(uint16)(strip/stripsperplane);
10181 - rows=td->td_imagelength-stripinplane*rowsperstrip;
10182 -diff --git a/libtiff/tiffiop.h b/libtiff/tiffiop.h
10183 -index ffbb647b..cb59460a 100644
10184 ---- a/libtiff/tiffiop.h
10185 -+++ b/libtiff/tiffiop.h
10186 -@@ -250,6 +250,10 @@ struct tiff {
10187 - #define TIFFhowmany_32(x, y) (((uint32)x < (0xffffffff - (uint32)(y-1))) ? \
10188 - ((((uint32)(x))+(((uint32)(y))-1))/((uint32)(y))) : \
10189 - 0U)
10190 -+/* Variant of TIFFhowmany_32() that doesn't return 0 if x close to MAXUINT. */
10191 -+/* Caution: TIFFhowmany_32_maxuint_compat(x,y)*y might overflow */
10192 -+#define TIFFhowmany_32_maxuint_compat(x, y) \
10193 -+ (((uint32)(x) / (uint32)(y)) + ((((uint32)(x) % (uint32)(y)) != 0) ? 1 : 0))
10194 - #define TIFFhowmany8_32(x) (((x)&0x07)?((uint32)(x)>>3)+1:(uint32)(x)>>3)
10195 - #define TIFFroundup_32(x, y) (TIFFhowmany_32(x,y)*(y))
10196 - #define TIFFhowmany_64(x, y) ((((uint64)(x))+(((uint64)(y))-1))/((uint64)(y)))
10197 ---
10198 -2.11.0
10200 diff -Naurp buildroot-2017.05-rc2/package/tiff/0002-libtiff-tif_ojpeg.c-make-OJPEGDecode-early-exit-in-c.patch buildroot-2017.05.2/package/tiff/0002-libtiff-tif_ojpeg.c-make-OJPEGDecode-early-exit-in-c.patch
10201 --- buildroot-2017.05-rc2/package/tiff/0002-libtiff-tif_ojpeg.c-make-OJPEGDecode-early-exit-in-c.patch 2017-05-17 10:27:16.013401440 +0200
10202 +++ buildroot-2017.05.2/package/tiff/0002-libtiff-tif_ojpeg.c-make-OJPEGDecode-early-exit-in-c.patch 1970-01-01 01:00:00.000000000 +0100
10203 @@ -1,53 +0,0 @@
10204 -From 43bc256d8ae44b92d2734a3c5bc73957a4d7c1ec Mon Sep 17 00:00:00 2001
10205 -From: erouault <erouault>
10206 -Date: Sat, 3 Dec 2016 11:15:18 +0000
10207 -Subject: [PATCH] * libtiff/tif_ojpeg.c: make OJPEGDecode() early exit in case
10208 - of failure in OJPEGPreDecode(). This will avoid a divide by zero, and
10209 - potential other issues. Reported by Agostino Sarubbo. Fixes
10210 - http://bugzilla.maptools.org/show_bug.cgi?id=2611
10212 -Fixes CVE-2016-10267
10214 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10215 ----
10216 - libtiff/tif_ojpeg.c | 8 ++++++++
10217 - 1 files changed, 15 insertions(+)
10219 -diff --git a/libtiff/tif_ojpeg.c b/libtiff/tif_ojpeg.c
10220 -index 1ccc3f9b..f19e8fd0 100644
10221 ---- a/libtiff/tif_ojpeg.c
10222 -+++ b/libtiff/tif_ojpeg.c
10223 -@@ -244,6 +244,7 @@ typedef enum {
10225 - typedef struct {
10226 - TIFF* tif;
10227 -+ int decoder_ok;
10228 - #ifndef LIBJPEG_ENCAP_EXTERNAL
10229 - JMP_BUF exit_jmpbuf;
10230 - #endif
10231 -@@ -722,6 +723,7 @@ OJPEGPreDecode(TIFF* tif, uint16 s)
10233 - sp->write_curstrile++;
10235 -+ sp->decoder_ok = 1;
10236 - return(1);
10239 -@@ -784,8 +786,14 @@ OJPEGPreDecodeSkipScanlines(TIFF* tif)
10240 - static int
10241 - OJPEGDecode(TIFF* tif, uint8* buf, tmsize_t cc, uint16 s)
10243 -+ static const char module[]="OJPEGDecode";
10244 - OJPEGState* sp=(OJPEGState*)tif->tif_data;
10245 - (void)s;
10246 -+ if( !sp->decoder_ok )
10247 -+ {
10248 -+ TIFFErrorExt(tif->tif_clientdata,module,"Cannot decode: decoder not correctly initialized");
10249 -+ return 0;
10250 -+ }
10251 - if (sp->libjpeg_jpeg_query_style==0)
10253 - if (OJPEGDecodeRaw(tif,buf,cc)==0)
10254 ---
10255 -2.11.0
10257 diff -Naurp buildroot-2017.05-rc2/package/tiff/0003-libtiff-tif_pixarlog.c-libtiff-tif_luv.c-fix-heap-ba.patch buildroot-2017.05.2/package/tiff/0003-libtiff-tif_pixarlog.c-libtiff-tif_luv.c-fix-heap-ba.patch
10258 --- buildroot-2017.05-rc2/package/tiff/0003-libtiff-tif_pixarlog.c-libtiff-tif_luv.c-fix-heap-ba.patch 2017-05-17 10:27:16.013401440 +0200
10259 +++ buildroot-2017.05.2/package/tiff/0003-libtiff-tif_pixarlog.c-libtiff-tif_luv.c-fix-heap-ba.patch 1970-01-01 01:00:00.000000000 +0100
10260 @@ -1,110 +0,0 @@
10261 -From 1044b43637fa7f70fb19b93593777b78bd20da86 Mon Sep 17 00:00:00 2001
10262 -From: erouault <erouault>
10263 -Date: Fri, 2 Dec 2016 23:05:51 +0000
10264 -Subject: [PATCH] * libtiff/tif_pixarlog.c, libtiff/tif_luv.c: fix heap-based
10265 - buffer overflow on generation of PixarLog / LUV compressed files, with
10266 - ColorMap, TransferFunction attached and nasty plays with bitspersample. The
10267 - fix for LUV has not been tested, but suffers from the same kind of issue of
10268 - PixarLog. Reported by Agostino Sarubbo. Fixes
10269 - http://bugzilla.maptools.org/show_bug.cgi?id=2604
10271 -Fixes CVE-2016-10269
10273 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10274 ----
10275 - libtiff/tif_luv.c | 18 ++++++++++++++----
10276 - libtiff/tif_pixarlog.c | 17 +++++++++++++++--
10277 - 2 files changed, 39 insertions(+), 6 deletions(-)
10279 -diff --git a/libtiff/tif_luv.c b/libtiff/tif_luv.c
10280 -index f68a9b13..e6783db5 100644
10281 ---- a/libtiff/tif_luv.c
10282 -+++ b/libtiff/tif_luv.c
10283 -@@ -158,6 +158,7 @@
10284 - typedef struct logLuvState LogLuvState;
10286 - struct logLuvState {
10287 -+ int encoder_state; /* 1 if encoder correctly initialized */
10288 - int user_datafmt; /* user data format */
10289 - int encode_meth; /* encoding method */
10290 - int pixel_size; /* bytes per pixel */
10291 -@@ -1552,6 +1553,7 @@ LogLuvSetupEncode(TIFF* tif)
10292 - td->td_photometric, "must be either LogLUV or LogL");
10293 - break;
10295 -+ sp->encoder_state = 1;
10296 - return (1);
10297 - notsupported:
10298 - TIFFErrorExt(tif->tif_clientdata, module,
10299 -@@ -1563,19 +1565,27 @@ notsupported:
10300 - static void
10301 - LogLuvClose(TIFF* tif)
10303 -+ LogLuvState* sp = (LogLuvState*) tif->tif_data;
10304 - TIFFDirectory *td = &tif->tif_dir;
10306 -+ assert(sp != 0);
10307 - /*
10308 - * For consistency, we always want to write out the same
10309 - * bitspersample and sampleformat for our TIFF file,
10310 - * regardless of the data format being used by the application.
10311 - * Since this routine is called after tags have been set but
10312 - * before they have been recorded in the file, we reset them here.
10313 -+ * Note: this is really a nasty approach. See PixarLogClose
10314 - */
10315 -- td->td_samplesperpixel =
10316 -- (td->td_photometric == PHOTOMETRIC_LOGL) ? 1 : 3;
10317 -- td->td_bitspersample = 16;
10318 -- td->td_sampleformat = SAMPLEFORMAT_INT;
10319 -+ if( sp->encoder_state )
10320 -+ {
10321 -+ /* See PixarLogClose. Might avoid issues with tags whose size depends
10322 -+ * on those below, but not completely sure this is enough. */
10323 -+ td->td_samplesperpixel =
10324 -+ (td->td_photometric == PHOTOMETRIC_LOGL) ? 1 : 3;
10325 -+ td->td_bitspersample = 16;
10326 -+ td->td_sampleformat = SAMPLEFORMAT_INT;
10327 -+ }
10330 - static void
10331 -diff --git a/libtiff/tif_pixarlog.c b/libtiff/tif_pixarlog.c
10332 -index d1246c3d..aa99bc92 100644
10333 ---- a/libtiff/tif_pixarlog.c
10334 -+++ b/libtiff/tif_pixarlog.c
10335 -@@ -1233,8 +1233,10 @@ PixarLogPostEncode(TIFF* tif)
10336 - static void
10337 - PixarLogClose(TIFF* tif)
10339 -+ PixarLogState* sp = (PixarLogState*) tif->tif_data;
10340 - TIFFDirectory *td = &tif->tif_dir;
10342 -+ assert(sp != 0);
10343 - /* In a really sneaky (and really incorrect, and untruthful, and
10344 - * troublesome, and error-prone) maneuver that completely goes against
10345 - * the spirit of TIFF, and breaks TIFF, on close, we covertly
10346 -@@ -1243,8 +1245,19 @@ PixarLogClose(TIFF* tif)
10347 - * readers that don't know about PixarLog, or how to set
10348 - * the PIXARLOGDATFMT pseudo-tag.
10349 - */
10350 -- td->td_bitspersample = 8;
10351 -- td->td_sampleformat = SAMPLEFORMAT_UINT;
10353 -+ if (sp->state&PLSTATE_INIT) {
10354 -+ /* We test the state to avoid an issue such as in
10355 -+ * http://bugzilla.maptools.org/show_bug.cgi?id=2604
10356 -+ * What appends in that case is that the bitspersample is 1 and
10357 -+ * a TransferFunction is set. The size of the TransferFunction
10358 -+ * depends on 1<<bitspersample. So if we increase it, an access
10359 -+ * out of the buffer will happen at directory flushing.
10360 -+ * Another option would be to clear those targs.
10361 -+ */
10362 -+ td->td_bitspersample = 8;
10363 -+ td->td_sampleformat = SAMPLEFORMAT_UINT;
10364 -+ }
10367 - static void
10368 ---
10369 -2.11.0
10371 diff -Naurp buildroot-2017.05-rc2/package/tiff/0004-libtiff-tif_dirread.c-modify-ChopUpSingleUncompresse.patch buildroot-2017.05.2/package/tiff/0004-libtiff-tif_dirread.c-modify-ChopUpSingleUncompresse.patch
10372 --- buildroot-2017.05-rc2/package/tiff/0004-libtiff-tif_dirread.c-modify-ChopUpSingleUncompresse.patch 2017-05-17 10:27:16.013401440 +0200
10373 +++ buildroot-2017.05.2/package/tiff/0004-libtiff-tif_dirread.c-modify-ChopUpSingleUncompresse.patch 1970-01-01 01:00:00.000000000 +0100
10374 @@ -1,107 +0,0 @@
10375 -From 9a72a69e035ee70ff5c41541c8c61cd97990d018 Mon Sep 17 00:00:00 2001
10376 -From: erouault <erouault>
10377 -Date: Sat, 3 Dec 2016 11:02:15 +0000
10378 -Subject: [PATCH] * libtiff/tif_dirread.c: modify
10379 - ChopUpSingleUncompressedStrip() to instanciate compute ntrips as
10380 - TIFFhowmany_32(td->td_imagelength, rowsperstrip), instead of a logic based on
10381 - the total size of data. Which is faulty is the total size of data is not
10382 - sufficient to fill the whole image, and thus results in reading outside of
10383 - the StripByCounts/StripOffsets arrays when using TIFFReadScanline(). Reported
10384 - by Agostino Sarubbo. Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2608.
10386 -* libtiff/tif_strip.c: revert the change in TIFFNumberOfStrips() done
10387 -for http://bugzilla.maptools.org/show_bug.cgi?id=2587 / CVE-2016-9273 since
10388 -the above change is a better fix that makes it unnecessary.
10390 -Fixes CVE-2016-10270
10392 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10393 ----
10394 - libtiff/tif_dirread.c | 22 ++++++++++------------
10395 - libtiff/tif_strip.c | 9 ---------
10396 - 2 files changed, 25 insertions(+), 21 deletions(-)
10398 -diff --git a/libtiff/tif_dirread.c b/libtiff/tif_dirread.c
10399 -index 3eec79c9..570d0c32 100644
10400 ---- a/libtiff/tif_dirread.c
10401 -+++ b/libtiff/tif_dirread.c
10402 -@@ -5502,8 +5502,7 @@ ChopUpSingleUncompressedStrip(TIFF* tif)
10403 - uint64 rowblockbytes;
10404 - uint64 stripbytes;
10405 - uint32 strip;
10406 -- uint64 nstrips64;
10407 -- uint32 nstrips32;
10408 -+ uint32 nstrips;
10409 - uint32 rowsperstrip;
10410 - uint64* newcounts;
10411 - uint64* newoffsets;
10412 -@@ -5534,18 +5533,17 @@ ChopUpSingleUncompressedStrip(TIFF* tif)
10413 - return;
10415 - /*
10416 -- * never increase the number of strips in an image
10417 -+ * never increase the number of rows per strip
10418 - */
10419 - if (rowsperstrip >= td->td_rowsperstrip)
10420 - return;
10421 -- nstrips64 = TIFFhowmany_64(bytecount, stripbytes);
10422 -- if ((nstrips64==0)||(nstrips64>0xFFFFFFFF)) /* something is wonky, do nothing. */
10423 -- return;
10424 -- nstrips32 = (uint32)nstrips64;
10425 -+ nstrips = TIFFhowmany_32(td->td_imagelength, rowsperstrip);
10426 -+ if( nstrips == 0 )
10427 -+ return;
10429 -- newcounts = (uint64*) _TIFFCheckMalloc(tif, nstrips32, sizeof (uint64),
10430 -+ newcounts = (uint64*) _TIFFCheckMalloc(tif, nstrips, sizeof (uint64),
10431 - "for chopped \"StripByteCounts\" array");
10432 -- newoffsets = (uint64*) _TIFFCheckMalloc(tif, nstrips32, sizeof (uint64),
10433 -+ newoffsets = (uint64*) _TIFFCheckMalloc(tif, nstrips, sizeof (uint64),
10434 - "for chopped \"StripOffsets\" array");
10435 - if (newcounts == NULL || newoffsets == NULL) {
10436 - /*
10437 -@@ -5562,18 +5560,18 @@ ChopUpSingleUncompressedStrip(TIFF* tif)
10438 - * Fill the strip information arrays with new bytecounts and offsets
10439 - * that reflect the broken-up format.
10440 - */
10441 -- for (strip = 0; strip < nstrips32; strip++) {
10442 -+ for (strip = 0; strip < nstrips; strip++) {
10443 - if (stripbytes > bytecount)
10444 - stripbytes = bytecount;
10445 - newcounts[strip] = stripbytes;
10446 -- newoffsets[strip] = offset;
10447 -+ newoffsets[strip] = stripbytes ? offset : 0;
10448 - offset += stripbytes;
10449 - bytecount -= stripbytes;
10451 - /*
10452 - * Replace old single strip info with multi-strip info.
10453 - */
10454 -- td->td_stripsperimage = td->td_nstrips = nstrips32;
10455 -+ td->td_stripsperimage = td->td_nstrips = nstrips;
10456 - TIFFSetField(tif, TIFFTAG_ROWSPERSTRIP, rowsperstrip);
10458 - _TIFFfree(td->td_stripbytecount);
10459 -diff --git a/libtiff/tif_strip.c b/libtiff/tif_strip.c
10460 -index 4c46ecf5..1676e47d 100644
10461 ---- a/libtiff/tif_strip.c
10462 -+++ b/libtiff/tif_strip.c
10463 -@@ -63,15 +63,6 @@ TIFFNumberOfStrips(TIFF* tif)
10464 - TIFFDirectory *td = &tif->tif_dir;
10465 - uint32 nstrips;
10467 -- /* If the value was already computed and store in td_nstrips, then return it,
10468 -- since ChopUpSingleUncompressedStrip might have altered and resized the
10469 -- since the td_stripbytecount and td_stripoffset arrays to the new value
10470 -- after the initial affectation of td_nstrips = TIFFNumberOfStrips() in
10471 -- tif_dirread.c ~line 3612.
10472 -- See http://bugzilla.maptools.org/show_bug.cgi?id=2587 */
10473 -- if( td->td_nstrips )
10474 -- return td->td_nstrips;
10476 - nstrips = (td->td_rowsperstrip == (uint32) -1 ? 1 :
10477 - TIFFhowmany_32(td->td_imagelength, td->td_rowsperstrip));
10478 - if (td->td_planarconfig == PLANARCONFIG_SEPARATE)
10479 ---
10480 -2.11.0
10482 diff -Naurp buildroot-2017.05-rc2/package/tiff/0005-tools-tiffcp.c-error-out-cleanly-in-cpContig2Separat.patch buildroot-2017.05.2/package/tiff/0005-tools-tiffcp.c-error-out-cleanly-in-cpContig2Separat.patch
10483 --- buildroot-2017.05-rc2/package/tiff/0005-tools-tiffcp.c-error-out-cleanly-in-cpContig2Separat.patch 2017-05-17 10:27:16.013401440 +0200
10484 +++ buildroot-2017.05.2/package/tiff/0005-tools-tiffcp.c-error-out-cleanly-in-cpContig2Separat.patch 1970-01-01 01:00:00.000000000 +0100
10485 @@ -1,74 +0,0 @@
10486 -From 5c080298d59efa53264d7248bbe3a04660db6ef7 Mon Sep 17 00:00:00 2001
10487 -From: erouault <erouault>
10488 -Date: Wed, 11 Jan 2017 19:25:44 +0000
10489 -Subject: [PATCH] * tools/tiffcp.c: error out cleanly in cpContig2SeparateByRow
10490 - and cpSeparate2ContigByRow if BitsPerSample != 8 to avoid heap based
10491 - overflow. Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2656 and
10492 - http://bugzilla.maptools.org/show_bug.cgi?id=2657
10494 -Fixes CVE-2017-5225
10496 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10497 ----
10498 - tools/tiffcp.c | 24 ++++++++++++++++++++++--
10499 - 1 file changed, 29 insertions(+), 2 deletions(-)
10501 -diff --git a/tools/tiffcp.c b/tools/tiffcp.c
10502 -index bdf754c3..8bbcd52f 100644
10503 ---- a/tools/tiffcp.c
10504 -+++ b/tools/tiffcp.c
10505 -@@ -591,7 +591,7 @@ static copyFunc pickCopyFunc(TIFF*, TIFF*, uint16, uint16);
10506 - static int
10507 - tiffcp(TIFF* in, TIFF* out)
10509 -- uint16 bitspersample, samplesperpixel = 1;
10510 -+ uint16 bitspersample = 1, samplesperpixel = 1;
10511 - uint16 input_compression, input_photometric = PHOTOMETRIC_MINISBLACK;
10512 - copyFunc cf;
10513 - uint32 width, length;
10514 -@@ -1067,6 +1067,16 @@ DECLAREcpFunc(cpContig2SeparateByRow)
10515 - register uint32 n;
10516 - uint32 row;
10517 - tsample_t s;
10518 -+ uint16 bps = 0;
10520 -+ (void) TIFFGetField(in, TIFFTAG_BITSPERSAMPLE, &bps);
10521 -+ if( bps != 8 )
10522 -+ {
10523 -+ TIFFError(TIFFFileName(in),
10524 -+ "Error, can only handle BitsPerSample=8 in %s",
10525 -+ "cpContig2SeparateByRow");
10526 -+ return 0;
10527 -+ }
10529 - inbuf = _TIFFmalloc(scanlinesizein);
10530 - outbuf = _TIFFmalloc(scanlinesizeout);
10531 -@@ -1120,6 +1130,16 @@ DECLAREcpFunc(cpSeparate2ContigByRow)
10532 - register uint32 n;
10533 - uint32 row;
10534 - tsample_t s;
10535 -+ uint16 bps = 0;
10537 -+ (void) TIFFGetField(in, TIFFTAG_BITSPERSAMPLE, &bps);
10538 -+ if( bps != 8 )
10539 -+ {
10540 -+ TIFFError(TIFFFileName(in),
10541 -+ "Error, can only handle BitsPerSample=8 in %s",
10542 -+ "cpSeparate2ContigByRow");
10543 -+ return 0;
10544 -+ }
10546 - inbuf = _TIFFmalloc(scanlinesizein);
10547 - outbuf = _TIFFmalloc(scanlinesizeout);
10548 -@@ -1784,7 +1804,7 @@ pickCopyFunc(TIFF* in, TIFF* out, uint16 bitspersample, uint16 samplesperpixel)
10549 - uint32 w, l, tw, tl;
10550 - int bychunk;
10552 -- (void) TIFFGetField(in, TIFFTAG_PLANARCONFIG, &shortv);
10553 -+ (void) TIFFGetFieldDefaulted(in, TIFFTAG_PLANARCONFIG, &shortv);
10554 - if (shortv != config && bitspersample != 8 && samplesperpixel > 1) {
10555 - fprintf(stderr,
10556 - "%s: Cannot handle different planar configuration w/ bits/sample != 8\n",
10557 ---
10558 -2.11.0
10560 diff -Naurp buildroot-2017.05-rc2/package/tiff/0006-libtiff-tif_getimage.c-add-explicit-uint32-cast-in-p.patch buildroot-2017.05.2/package/tiff/0006-libtiff-tif_getimage.c-add-explicit-uint32-cast-in-p.patch
10561 --- buildroot-2017.05-rc2/package/tiff/0006-libtiff-tif_getimage.c-add-explicit-uint32-cast-in-p.patch 2017-05-17 10:27:16.013401440 +0200
10562 +++ buildroot-2017.05.2/package/tiff/0006-libtiff-tif_getimage.c-add-explicit-uint32-cast-in-p.patch 1970-01-01 01:00:00.000000000 +0100
10563 @@ -1,31 +0,0 @@
10564 -From 48780b4fcc425cddc4ef8ffdf536f96a0d1b313b Mon Sep 17 00:00:00 2001
10565 -From: erouault <erouault>
10566 -Date: Wed, 11 Jan 2017 16:38:26 +0000
10567 -Subject: [PATCH] libtiff/tif_getimage.c: add explicit uint32 cast in putagreytile to
10568 - avoid UndefinedBehaviorSanitizer warning.
10569 - Patch by Nicolás Peña.
10570 - Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2658
10572 -Fixes CVE-2017-7592
10574 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10575 ----
10576 - libtiff/tif_getimage.c | 2 +-
10577 - 1 file changed, 8 insertions(+), 1 deletion(-)
10579 -diff --git a/libtiff/tif_getimage.c b/libtiff/tif_getimage.c
10580 -index fed31f1f..2fa1775c 100644
10581 ---- a/libtiff/tif_getimage.c
10582 -+++ b/libtiff/tif_getimage.c
10583 -@@ -1302,7 +1302,7 @@ DECLAREContigPutFunc(putagreytile)
10584 - while (h-- > 0) {
10585 - for (x = w; x-- > 0;)
10587 -- *cp++ = BWmap[*pp][0] & (*(pp+1) << 24 | ~A1);
10588 -+ *cp++ = BWmap[*pp][0] & ((uint32)*(pp+1) << 24 | ~A1);
10589 - pp += samplesperpixel;
10591 - cp += toskew;
10592 ---
10593 -2.11.0
10595 diff -Naurp buildroot-2017.05-rc2/package/tiff/0007-libtiff-tiffiop.h-tif_unix.c-tif_win32.c-tif_vms.c-a.patch buildroot-2017.05.2/package/tiff/0007-libtiff-tiffiop.h-tif_unix.c-tif_win32.c-tif_vms.c-a.patch
10596 --- buildroot-2017.05-rc2/package/tiff/0007-libtiff-tiffiop.h-tif_unix.c-tif_win32.c-tif_vms.c-a.patch 2017-05-17 10:27:16.013401440 +0200
10597 +++ buildroot-2017.05.2/package/tiff/0007-libtiff-tiffiop.h-tif_unix.c-tif_win32.c-tif_vms.c-a.patch 1970-01-01 01:00:00.000000000 +0100
10598 @@ -1,88 +0,0 @@
10599 -From d60332057b9575ada4f264489582b13e30137be1 Mon Sep 17 00:00:00 2001
10600 -From: erouault <erouault>
10601 -Date: Wed, 11 Jan 2017 19:02:49 +0000
10602 -Subject: [PATCH] * libtiff/tiffiop.h, tif_unix.c, tif_win32.c, tif_vms.c: add
10603 - _TIFFcalloc()
10605 -* libtiff/tif_read.c: TIFFReadBufferSetup(): use _TIFFcalloc() to zero
10606 -initialize tif_rawdata.
10607 -Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2651
10609 -Fixes CVE-2017-7593
10611 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10612 ----
10613 - libtiff/tif_read.c | 4 +++-
10614 - libtiff/tif_unix.c | 8 ++++++++
10615 - libtiff/tif_win32.c | 8 ++++++++
10616 - libtiff/tiffio.h | 1 +
10617 - 4 files changed, 36 insertions(+), 1 deletion(-)
10619 -diff --git a/libtiff/tif_read.c b/libtiff/tif_read.c
10620 -index 277fdd69..4535ccb3 100644
10621 ---- a/libtiff/tif_read.c
10622 -+++ b/libtiff/tif_read.c
10623 -@@ -985,7 +985,9 @@ TIFFReadBufferSetup(TIFF* tif, void* bp, tmsize_t size)
10624 - "Invalid buffer size");
10625 - return (0);
10627 -- tif->tif_rawdata = (uint8*) _TIFFmalloc(tif->tif_rawdatasize);
10628 -+ /* Initialize to zero to avoid uninitialized buffers in case of */
10629 -+ /* short reads (http://bugzilla.maptools.org/show_bug.cgi?id=2651) */
10630 -+ tif->tif_rawdata = (uint8*) _TIFFcalloc(1, tif->tif_rawdatasize);
10631 - tif->tif_flags |= TIFF_MYBUFFER;
10633 - if (tif->tif_rawdata == NULL) {
10634 -diff --git a/libtiff/tif_unix.c b/libtiff/tif_unix.c
10635 -index 7c7bc961..89dd32e8 100644
10636 ---- a/libtiff/tif_unix.c
10637 -+++ b/libtiff/tif_unix.c
10638 -@@ -316,6 +316,14 @@ _TIFFmalloc(tmsize_t s)
10639 - return (malloc((size_t) s));
10642 -+void* _TIFFcalloc(tmsize_t nmemb, tmsize_t siz)
10644 -+ if( nmemb == 0 || siz == 0 )
10645 -+ return ((void *) NULL);
10647 -+ return calloc((size_t) nmemb, (size_t)siz);
10650 - void
10651 - _TIFFfree(void* p)
10653 -diff --git a/libtiff/tif_win32.c b/libtiff/tif_win32.c
10654 -index d730b3ab..3e9001b7 100644
10655 ---- a/libtiff/tif_win32.c
10656 -+++ b/libtiff/tif_win32.c
10657 -@@ -360,6 +360,14 @@ _TIFFmalloc(tmsize_t s)
10658 - return (malloc((size_t) s));
10661 -+void* _TIFFcalloc(tmsize_t nmemb, tmsize_t siz)
10663 -+ if( nmemb == 0 || siz == 0 )
10664 -+ return ((void *) NULL);
10666 -+ return calloc((size_t) nmemb, (size_t)siz);
10669 - void
10670 - _TIFFfree(void* p)
10672 -diff --git a/libtiff/tiffio.h b/libtiff/tiffio.h
10673 -index 732da17f..fbd9171f 100644
10674 ---- a/libtiff/tiffio.h
10675 -+++ b/libtiff/tiffio.h
10676 -@@ -293,6 +293,7 @@ extern TIFFCodec* TIFFGetConfiguredCODECs(void);
10677 - */
10679 - extern void* _TIFFmalloc(tmsize_t s);
10680 -+extern void* _TIFFcalloc(tmsize_t nmemb, tmsize_t siz);
10681 - extern void* _TIFFrealloc(void* p, tmsize_t s);
10682 - extern void _TIFFmemset(void* p, int v, tmsize_t c);
10683 - extern void _TIFFmemcpy(void* d, const void* s, tmsize_t c);
10684 ---
10685 -2.11.0
10687 diff -Naurp buildroot-2017.05-rc2/package/tiff/0008-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch buildroot-2017.05.2/package/tiff/0008-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch
10688 --- buildroot-2017.05-rc2/package/tiff/0008-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch 2017-05-17 10:27:16.013401440 +0200
10689 +++ buildroot-2017.05.2/package/tiff/0008-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch 1970-01-01 01:00:00.000000000 +0100
10690 @@ -1,43 +0,0 @@
10691 -From 2ea32f7372b65c24b2816f11c04bf59b5090d05b Mon Sep 17 00:00:00 2001
10692 -From: erouault <erouault>
10693 -Date: Thu, 12 Jan 2017 19:23:20 +0000
10694 -Subject: [PATCH] * libtiff/tif_ojpeg.c: fix leak in
10695 - OJPEGReadHeaderInfoSecTablesQTable, OJPEGReadHeaderInfoSecTablesDcTable and
10696 - OJPEGReadHeaderInfoSecTablesAcTable
10698 -Fixes CVE-2017-7594
10700 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10701 ----
10702 - libtiff/tif_ojpeg.c | 6 ++++++
10703 - 1 file changed, 8 insertions(+), 1 deletion(-)
10705 -diff --git a/libtiff/tif_ojpeg.c b/libtiff/tif_ojpeg.c
10706 -index b92f0ebd..5f6c684c 100644
10707 ---- a/libtiff/tif_ojpeg.c
10708 -+++ b/libtiff/tif_ojpeg.c
10709 -@@ -1790,7 +1790,10 @@ OJPEGReadHeaderInfoSecTablesQTable(TIFF* tif)
10710 - TIFFSeekFile(tif,sp->qtable_offset[m],SEEK_SET);
10711 - p=(uint32)TIFFReadFile(tif,&ob[sizeof(uint32)+5],64);
10712 - if (p!=64)
10713 -+ {
10714 -+ _TIFFfree(ob);
10715 - return(0);
10716 -+ }
10717 - sp->qtable[m]=ob;
10718 - sp->sof_tq[m]=m;
10720 -@@ -1854,7 +1857,10 @@ OJPEGReadHeaderInfoSecTablesDcTable(TIFF* tif)
10721 - rb[sizeof(uint32)+5+n]=o[n];
10722 - p=(uint32)TIFFReadFile(tif,&(rb[sizeof(uint32)+21]),q);
10723 - if (p!=q)
10724 -+ {
10725 -+ _TIFFfree(rb);
10726 - return(0);
10727 -+ }
10728 - sp->dctable[m]=rb;
10729 - sp->sos_tda[m]=(m<<4);
10731 ---
10732 -2.11.0
10734 diff -Naurp buildroot-2017.05-rc2/package/tiff/0009-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch buildroot-2017.05.2/package/tiff/0009-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch
10735 --- buildroot-2017.05-rc2/package/tiff/0009-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch 2017-05-17 10:27:16.013401440 +0200
10736 +++ buildroot-2017.05.2/package/tiff/0009-libtiff-tif_ojpeg.c-fix-leak-in-OJPEGReadHeaderInfoS.patch 1970-01-01 01:00:00.000000000 +0100
10737 @@ -1,36 +0,0 @@
10738 -From 8283e4d1b7e53340684d12932880cbcbaf23a8c1 Mon Sep 17 00:00:00 2001
10739 -From: erouault <erouault>
10740 -Date: Thu, 12 Jan 2017 17:43:25 +0000
10741 -Subject: [PATCH] libtiff/tif_ojpeg.c: fix leak in
10742 - OJPEGReadHeaderInfoSecTablesAcTable when read fails.
10743 - Patch by Nicolás Peña.
10744 - Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2659
10745 -MIME-Version: 1.0
10746 -Content-Type: text/plain; charset=UTF-8
10747 -Content-Transfer-Encoding: 8bit
10749 -Fixes CVE-2017-7594
10751 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10752 ----
10753 - libtiff/tif_ojpeg.c | 3 +++
10754 - 1 file changed, 10 insertions(+)
10756 -diff --git a/libtiff/tif_ojpeg.c b/libtiff/tif_ojpeg.c
10757 -index f19e8fd0..b92f0ebd 100644
10758 ---- a/libtiff/tif_ojpeg.c
10759 -+++ b/libtiff/tif_ojpeg.c
10760 -@@ -1918,7 +1918,10 @@ OJPEGReadHeaderInfoSecTablesAcTable(TIFF* tif)
10761 - rb[sizeof(uint32)+5+n]=o[n];
10762 - p=(uint32)TIFFReadFile(tif,&(rb[sizeof(uint32)+21]),q);
10763 - if (p!=q)
10764 -+ {
10765 -+ _TIFFfree(rb);
10766 - return(0);
10767 -+ }
10768 - sp->actable[m]=rb;
10769 - sp->sos_tda[m]=(sp->sos_tda[m]|m);
10771 ---
10772 -2.11.0
10774 diff -Naurp buildroot-2017.05-rc2/package/tiff/0010-libtiff-tif_jpeg.c-avoid-integer-division-by-zero-in.patch buildroot-2017.05.2/package/tiff/0010-libtiff-tif_jpeg.c-avoid-integer-division-by-zero-in.patch
10775 --- buildroot-2017.05-rc2/package/tiff/0010-libtiff-tif_jpeg.c-avoid-integer-division-by-zero-in.patch 2017-05-17 10:27:16.013401440 +0200
10776 +++ buildroot-2017.05.2/package/tiff/0010-libtiff-tif_jpeg.c-avoid-integer-division-by-zero-in.patch 1970-01-01 01:00:00.000000000 +0100
10777 @@ -1,35 +0,0 @@
10778 -From 47f2fb61a3a64667bce1a8398a8fcb1b348ff122 Mon Sep 17 00:00:00 2001
10779 -From: erouault <erouault>
10780 -Date: Wed, 11 Jan 2017 12:15:01 +0000
10781 -Subject: [PATCH] * libtiff/tif_jpeg.c: avoid integer division by zero in
10782 - JPEGSetupEncode() when horizontal or vertical sampling is set to 0. Fixes
10783 - http://bugzilla.maptools.org/show_bug.cgi?id=2653
10785 -Fixes CVE-2017-7595
10787 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10788 ----
10789 - libtiff/tif_jpeg.c | 7 +++++++
10790 - 1 file changed, 13 insertions(+)
10792 -diff --git a/libtiff/tif_jpeg.c b/libtiff/tif_jpeg.c
10793 -index 38595f98..6c17c388 100644
10794 ---- a/libtiff/tif_jpeg.c
10795 -+++ b/libtiff/tif_jpeg.c
10796 -@@ -1626,6 +1626,13 @@ JPEGSetupEncode(TIFF* tif)
10797 - case PHOTOMETRIC_YCBCR:
10798 - sp->h_sampling = td->td_ycbcrsubsampling[0];
10799 - sp->v_sampling = td->td_ycbcrsubsampling[1];
10800 -+ if( sp->h_sampling == 0 || sp->v_sampling == 0 )
10801 -+ {
10802 -+ TIFFErrorExt(tif->tif_clientdata, module,
10803 -+ "Invalig horizontal/vertical sampling value");
10804 -+ return (0);
10805 -+ }
10807 - /*
10808 - * A ReferenceBlackWhite field *must* be present since the
10809 - * default value is inappropriate for YCbCr. Fill in the
10810 ---
10811 -2.11.0
10813 diff -Naurp buildroot-2017.05-rc2/package/tiff/0011-libtiff-tif_dirread.c-avoid-division-by-floating-poi.patch buildroot-2017.05.2/package/tiff/0011-libtiff-tif_dirread.c-avoid-division-by-floating-poi.patch
10814 --- buildroot-2017.05-rc2/package/tiff/0011-libtiff-tif_dirread.c-avoid-division-by-floating-poi.patch 2017-05-17 10:27:16.013401440 +0200
10815 +++ buildroot-2017.05.2/package/tiff/0011-libtiff-tif_dirread.c-avoid-division-by-floating-poi.patch 1970-01-01 01:00:00.000000000 +0100
10816 @@ -1,47 +0,0 @@
10817 -From 3cfd62d77c2a7e147a05bd678524c345fa9c2bb8 Mon Sep 17 00:00:00 2001
10818 -From: erouault <erouault>
10819 -Date: Wed, 11 Jan 2017 13:28:01 +0000
10820 -Subject: [PATCH] * libtiff/tif_dirread.c: avoid division by floating point 0
10821 - in TIFFReadDirEntryCheckedRational() and TIFFReadDirEntryCheckedSrational(),
10822 - and return 0 in that case (instead of infinity as before presumably)
10823 - Apparently some sanitizers do not like those divisions by zero. Fixes
10824 - http://bugzilla.maptools.org/show_bug.cgi?id=2644
10826 -Fixes CVE-2017-7598
10828 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10829 ----
10830 - libtiff/tif_dirread.c | 10 ++++++++--
10831 - 1 file changed, 16 insertions(+), 2 deletions(-)
10833 -diff --git a/libtiff/tif_dirread.c b/libtiff/tif_dirread.c
10834 -index 570d0c32..8a1e42aa 100644
10835 ---- a/libtiff/tif_dirread.c
10836 -+++ b/libtiff/tif_dirread.c
10837 -@@ -2872,7 +2872,10 @@ static enum TIFFReadDirEntryErr TIFFReadDirEntryCheckedRational(TIFF* tif, TIFFD
10838 - m.l = direntry->tdir_offset.toff_long8;
10839 - if (tif->tif_flags&TIFF_SWAB)
10840 - TIFFSwabArrayOfLong(m.i,2);
10841 -- if (m.i[0]==0)
10842 -+ /* Not completely sure what we should do when m.i[1]==0, but some */
10843 -+ /* sanitizers do not like division by 0.0: */
10844 -+ /* http://bugzilla.maptools.org/show_bug.cgi?id=2644 */
10845 -+ if (m.i[0]==0 || m.i[1]==0)
10846 - *value=0.0;
10847 - else
10848 - *value=(double)m.i[0]/(double)m.i[1];
10849 -@@ -2900,7 +2903,10 @@ static enum TIFFReadDirEntryErr TIFFReadDirEntryCheckedSrational(TIFF* tif, TIFF
10850 - m.l=direntry->tdir_offset.toff_long8;
10851 - if (tif->tif_flags&TIFF_SWAB)
10852 - TIFFSwabArrayOfLong(m.i,2);
10853 -- if ((int32)m.i[0]==0)
10854 -+ /* Not completely sure what we should do when m.i[1]==0, but some */
10855 -+ /* sanitizers do not like division by 0.0: */
10856 -+ /* http://bugzilla.maptools.org/show_bug.cgi?id=2644 */
10857 -+ if ((int32)m.i[0]==0 || m.i[1]==0)
10858 - *value=0.0;
10859 - else
10860 - *value=(double)((int32)m.i[0])/(double)m.i[1];
10861 ---
10862 -2.11.0
10864 diff -Naurp buildroot-2017.05-rc2/package/tiff/0012-libtiff-tif_jpeg.c-validate-BitsPerSample-in-JPEGSet.patch buildroot-2017.05.2/package/tiff/0012-libtiff-tif_jpeg.c-validate-BitsPerSample-in-JPEGSet.patch
10865 --- buildroot-2017.05-rc2/package/tiff/0012-libtiff-tif_jpeg.c-validate-BitsPerSample-in-JPEGSet.patch 2017-05-17 10:27:16.013401440 +0200
10866 +++ buildroot-2017.05.2/package/tiff/0012-libtiff-tif_jpeg.c-validate-BitsPerSample-in-JPEGSet.patch 1970-01-01 01:00:00.000000000 +0100
10867 @@ -1,35 +0,0 @@
10868 -From 0a76a8c765c7b8327c59646284fa78c3c27e5490 Mon Sep 17 00:00:00 2001
10869 -From: erouault <erouault>
10870 -Date: Wed, 11 Jan 2017 16:13:50 +0000
10871 -Subject: [PATCH] * libtiff/tif_jpeg.c: validate BitsPerSample in
10872 - JPEGSetupEncode() to avoid undefined behaviour caused by invalid shift
10873 - exponent. Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2648
10875 -Fixes CVE-2017-7601
10877 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10878 ----
10879 - libtiff/tif_jpeg.c | 7 +++++++
10880 - 1 file changed, 13 insertions(+)
10882 -diff --git a/libtiff/tif_jpeg.c b/libtiff/tif_jpeg.c
10883 -index 6c17c388..192989a9 100644
10884 ---- a/libtiff/tif_jpeg.c
10885 -+++ b/libtiff/tif_jpeg.c
10886 -@@ -1632,6 +1632,13 @@ JPEGSetupEncode(TIFF* tif)
10887 - "Invalig horizontal/vertical sampling value");
10888 - return (0);
10890 -+ if( td->td_bitspersample > 16 )
10891 -+ {
10892 -+ TIFFErrorExt(tif->tif_clientdata, module,
10893 -+ "BitsPerSample %d not allowed for JPEG",
10894 -+ td->td_bitspersample);
10895 -+ return (0);
10896 -+ }
10898 - /*
10899 - * A ReferenceBlackWhite field *must* be present since the
10900 ---
10901 -2.11.0
10903 diff -Naurp buildroot-2017.05-rc2/package/tiff/0013-libtiff-tif_read.c-avoid-potential-undefined-behavio.patch buildroot-2017.05.2/package/tiff/0013-libtiff-tif_read.c-avoid-potential-undefined-behavio.patch
10904 --- buildroot-2017.05-rc2/package/tiff/0013-libtiff-tif_read.c-avoid-potential-undefined-behavio.patch 2017-05-17 10:27:16.013401440 +0200
10905 +++ buildroot-2017.05.2/package/tiff/0013-libtiff-tif_read.c-avoid-potential-undefined-behavio.patch 1970-01-01 01:00:00.000000000 +0100
10906 @@ -1,56 +0,0 @@
10907 -From 66e7bd59520996740e4df5495a830b42fae48bc4 Mon Sep 17 00:00:00 2001
10908 -From: erouault <erouault>
10909 -Date: Wed, 11 Jan 2017 16:33:34 +0000
10910 -Subject: [PATCH] * libtiff/tif_read.c: avoid potential undefined behaviour on
10911 - signed integer addition in TIFFReadRawStrip1() in isMapped() case. Fixes
10912 - http://bugzilla.maptools.org/show_bug.cgi?id=2650
10914 -Fixes CVE-2017-7602
10916 -Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
10917 ----
10918 - libtiff/tif_read.c | 27 ++++++++++++++++++---------
10919 - 1 file changed, 24 insertions(+), 9 deletions(-)
10921 -diff --git a/libtiff/tif_read.c b/libtiff/tif_read.c
10922 -index 52bbf507..b7aacbda 100644
10923 ---- a/libtiff/tif_read.c
10924 -+++ b/libtiff/tif_read.c
10925 -@@ -420,16 +420,25 @@ TIFFReadRawStrip1(TIFF* tif, uint32 strip, void* buf, tmsize_t size,
10926 - return ((tmsize_t)(-1));
10928 - } else {
10929 -- tmsize_t ma,mb;
10930 -+ tmsize_t ma;
10931 - tmsize_t n;
10932 -- ma=(tmsize_t)td->td_stripoffset[strip];
10933 -- mb=ma+size;
10934 -- if ((td->td_stripoffset[strip] > (uint64)TIFF_TMSIZE_T_MAX)||(ma>tif->tif_size))
10935 -- n=0;
10936 -- else if ((mb<ma)||(mb<size)||(mb>tif->tif_size))
10937 -- n=tif->tif_size-ma;
10938 -- else
10939 -- n=size;
10940 -+ if ((td->td_stripoffset[strip] > (uint64)TIFF_TMSIZE_T_MAX)||
10941 -+ ((ma=(tmsize_t)td->td_stripoffset[strip])>tif->tif_size))
10942 -+ {
10943 -+ n=0;
10944 -+ }
10945 -+ else if( ma > TIFF_TMSIZE_T_MAX - size )
10946 -+ {
10947 -+ n=0;
10948 -+ }
10949 -+ else
10950 -+ {
10951 -+ tmsize_t mb=ma+size;
10952 -+ if (mb>tif->tif_size)
10953 -+ n=tif->tif_size-ma;
10954 -+ else
10955 -+ n=size;
10956 -+ }
10957 - if (n!=size) {
10958 - #if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
10959 - TIFFErrorExt(tif->tif_clientdata, module,
10960 ---
10961 -2.11.0
10963 diff -Naurp buildroot-2017.05-rc2/package/tiff/tiff.hash buildroot-2017.05.2/package/tiff/tiff.hash
10964 --- buildroot-2017.05-rc2/package/tiff/tiff.hash 2017-05-17 10:27:16.013401440 +0200
10965 +++ buildroot-2017.05.2/package/tiff/tiff.hash 2017-07-27 08:16:52.017486944 +0200
10966 @@ -1,2 +1,2 @@
10967 # Locally computed
10968 -sha256 9f43a2cfb9589e5cecaa66e16bf87f814c945f22df7ba600d63aac4632c4f019 tiff-4.0.7.tar.gz
10969 +sha256 59d7a5a8ccd92059913f246877db95a2918e6c04fb9d43fd74e5c3390dac2910 tiff-4.0.8.tar.gz
10970 diff -Naurp buildroot-2017.05-rc2/package/tiff/tiff.mk buildroot-2017.05.2/package/tiff/tiff.mk
10971 --- buildroot-2017.05-rc2/package/tiff/tiff.mk 2017-05-17 10:27:16.013401440 +0200
10972 +++ buildroot-2017.05.2/package/tiff/tiff.mk 2017-07-27 08:16:52.017486944 +0200
10973 @@ -4,7 +4,7 @@
10975 ################################################################################
10977 -TIFF_VERSION = 4.0.7
10978 +TIFF_VERSION = 4.0.8
10979 TIFF_SITE = http://download.osgeo.org/libtiff
10980 TIFF_LICENSE = tiff license
10981 TIFF_LICENSE_FILES = COPYRIGHT
10982 diff -Naurp buildroot-2017.05-rc2/package/tor/tor.hash buildroot-2017.05.2/package/tor/tor.hash
10983 --- buildroot-2017.05-rc2/package/tor/tor.hash 2017-05-17 10:27:16.013401440 +0200
10984 +++ buildroot-2017.05.2/package/tor/tor.hash 2017-07-27 08:16:52.017486944 +0200
10985 @@ -1,2 +1,2 @@
10986 # Locally computed
10987 -sha256 d611283e1fb284b5f884f8c07e7d3151016851848304f56cfdf3be2a88bd1341 tor-0.2.9.10.tar.gz
10988 +sha256 c1959bebff9a546a54cbedb58c8289a42441991af417d2d16f7b336be8903221 tor-0.2.9.11.tar.gz
10989 diff -Naurp buildroot-2017.05-rc2/package/tor/tor.mk buildroot-2017.05.2/package/tor/tor.mk
10990 --- buildroot-2017.05-rc2/package/tor/tor.mk 2017-05-17 10:27:16.013401440 +0200
10991 +++ buildroot-2017.05.2/package/tor/tor.mk 2017-07-27 08:16:52.017486944 +0200
10992 @@ -4,7 +4,7 @@
10994 ################################################################################
10996 -TOR_VERSION = 0.2.9.10
10997 +TOR_VERSION = 0.2.9.11
10998 TOR_SITE = https://dist.torproject.org
10999 TOR_LICENSE = BSD-3-Clause
11000 TOR_LICENSE_FILES = LICENSE
11001 diff -Naurp buildroot-2017.05-rc2/package/trinity/trinity.hash buildroot-2017.05.2/package/trinity/trinity.hash
11002 --- buildroot-2017.05-rc2/package/trinity/trinity.hash 2017-05-17 10:27:16.013401440 +0200
11003 +++ buildroot-2017.05.2/package/trinity/trinity.hash 2017-07-27 08:16:52.017486944 +0200
11004 @@ -3,3 +3,4 @@ sha256 4cb2bd4049ce523fdf47490c4c18b8eb7
11005 sha256 5601474b10973b99f6f4ecc67c8ac54000754d7110553cc81c7648bd7e73c810 b0e66a2d084ffc210bc1fc247efb4d177e9f7e3d.patch
11006 sha256 1974e473113b4e79fb2ff820e2b03f475a538e43343c24ca077a04214b9e0418 f447db18b389050ecc5e66dbf549d5953633e23e.patch
11007 sha256 9f9846a9c257b7df7e944c8b3ea956a8e8166bba67b3ea6c231382f095753312 87427256640f806710dd97fc807a9a896147c617.patch
11008 +sha256 e6e47e813424f6b92b5a2e8f56bbd3bae63db47b76ece81a934a9390e194cbfc 1d9af9d07ae111c253c92112fb50000adac47a0c.patch
11009 diff -Naurp buildroot-2017.05-rc2/package/trinity/trinity.mk buildroot-2017.05.2/package/trinity/trinity.mk
11010 --- buildroot-2017.05-rc2/package/trinity/trinity.mk 2017-05-17 10:27:16.013401440 +0200
11011 +++ buildroot-2017.05.2/package/trinity/trinity.mk 2017-07-27 08:16:52.017486944 +0200
11012 @@ -12,7 +12,8 @@ TRINITY_LICENSE_FILES = COPYING
11014 TRINITY_PATCH = https://github.com/kernelslacker/trinity/commit/b0e66a2d084ffc210bc1fc247efb4d177e9f7e3d.patch \
11015 https://github.com/kernelslacker/trinity/commit/f447db18b389050ecc5e66dbf549d5953633e23e.patch \
11016 - https://github.com/kernelslacker/trinity/commit/87427256640f806710dd97fc807a9a896147c617.patch
11017 + https://github.com/kernelslacker/trinity/commit/87427256640f806710dd97fc807a9a896147c617.patch \
11018 + https://github.com/kernelslacker/trinity/commit/1d9af9d07ae111c253c92112fb50000adac47a0c.patch
11020 ifeq ($(BR2_PACKAGE_BTRFS_PROGS),y)
11021 TRINITY_DEPENDENCIES += btrfs-progs
11022 diff -Naurp buildroot-2017.05-rc2/package/tslib/tslib.mk buildroot-2017.05.2/package/tslib/tslib.mk
11023 --- buildroot-2017.05-rc2/package/tslib/tslib.mk 2017-05-17 10:27:16.013401440 +0200
11024 +++ buildroot-2017.05.2/package/tslib/tslib.mk 2017-07-27 08:16:52.017486944 +0200
11025 @@ -7,7 +7,7 @@
11026 TSLIB_VERSION = 1.9
11027 TSLIB_SITE = https://github.com/kergoth/tslib/releases/download/$(TSLIB_VERSION)
11028 TSLIB_SOURCE = tslib-$(TSLIB_VERSION).tar.xz
11029 -TSLIB_LICENSE = GPL, LGPL
11030 +TSLIB_LICENSE = GPL-2.0+ (programs), LGPL-2.1+ (libraries)
11031 TSLIB_LICENSE_FILES = COPYING
11033 TSLIB_INSTALL_STAGING = YES
11034 diff -Naurp buildroot-2017.05-rc2/package/uboot-tools/uboot-tools.mk buildroot-2017.05.2/package/uboot-tools/uboot-tools.mk
11035 --- buildroot-2017.05-rc2/package/uboot-tools/uboot-tools.mk 2017-05-17 10:27:16.013401440 +0200
11036 +++ buildroot-2017.05.2/package/uboot-tools/uboot-tools.mk 2017-07-27 08:16:52.017486944 +0200
11037 @@ -23,7 +23,7 @@ UBOOT_TOOLS_MAKE_OPTS = CROSS_COMPILE="$
11039 # This option was added through an additional patch
11040 # and allows the disabling of a host python swig
11041 -# detect which as of 2017.5 assumes the host systems swig.
11042 +# detect which as of 2017.3 assumes the host systems swig.
11043 UBOOT_TOOLS_MAKE_OPTS += CONFIG_TOOLS_PYTHON_WRAPPER_DISABLE=y
11045 ifeq ($(BR2_PACKAGE_UBOOT_TOOLS_FIT_SUPPORT),y)
11046 @@ -92,6 +92,10 @@ HOST_UBOOT_TOOLS_MAKE_OPTS = HOSTCC="$(H
11047 HOSTCFLAGS="$(HOST_CFLAGS)" \
11048 HOSTLDFLAGS="$(HOST_LDFLAGS)"
11050 +# Workaround to disable building the host python libfdt module. See comment
11051 +# above when setting the target uboot-tools make options.
11052 +HOST_UBOOT_TOOLS_MAKE_OPTS += CONFIG_TOOLS_PYTHON_WRAPPER_DISABLE=y
11054 ifeq ($(BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT),y)
11055 HOST_UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y
11056 HOST_UBOOT_TOOLS_DEPENDENCIES += host-dtc
11057 diff -Naurp buildroot-2017.05-rc2/package/vlc/0013-codec-avcodec-check-avcodec-visible-sizes.patch buildroot-2017.05.2/package/vlc/0013-codec-avcodec-check-avcodec-visible-sizes.patch
11058 --- buildroot-2017.05-rc2/package/vlc/0013-codec-avcodec-check-avcodec-visible-sizes.patch 1970-01-01 01:00:00.000000000 +0100
11059 +++ buildroot-2017.05.2/package/vlc/0013-codec-avcodec-check-avcodec-visible-sizes.patch 2017-07-27 08:16:52.017486944 +0200
11060 @@ -0,0 +1,33 @@
11061 +From 6cc73bcad19da2cd2e95671173f2e0d203a57e9b Mon Sep 17 00:00:00 2001
11062 +From: Francois Cartegnie <fcvlcdev@free.fr>
11063 +Date: Thu, 29 Jun 2017 09:45:20 +0200
11064 +Subject: [PATCH] codec: avcodec: check avcodec visible sizes
11066 +refs #18467
11068 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11069 +---
11070 + modules/codec/avcodec/video.c | 6 ++++--
11071 + 1 file changed, 4 insertions(+), 2 deletions(-)
11073 +diff --git a/modules/codec/avcodec/video.c b/modules/codec/avcodec/video.c
11074 +index 1bcad21..ce52544 100644
11075 +--- a/modules/codec/avcodec/video.c
11076 ++++ b/modules/codec/avcodec/video.c
11077 +@@ -137,9 +137,11 @@ static inline picture_t *ffmpeg_NewPictBuf( decoder_t *p_dec,
11081 +- if( width == 0 || height == 0 || width > 8192 || height > 8192 )
11082 ++ if( width == 0 || height == 0 || width > 8192 || height > 8192 ||
11083 ++ width < p_context->width || height < p_context->height )
11085 +- msg_Err( p_dec, "Invalid frame size %dx%d.", width, height );
11086 ++ msg_Err( p_dec, "Invalid frame size %dx%d. vsz %dx%d",
11087 ++ width, height, p_context->width, p_context->height );
11088 + return NULL; /* invalid display size */
11090 + p_dec->fmt_out.video.i_width = width;
11091 +--
11092 +2.1.4
11094 diff -Naurp buildroot-2017.05-rc2/package/vlc/0014-decoder-check-visible-size-when-creating-buffer.patch buildroot-2017.05.2/package/vlc/0014-decoder-check-visible-size-when-creating-buffer.patch
11095 --- buildroot-2017.05-rc2/package/vlc/0014-decoder-check-visible-size-when-creating-buffer.patch 1970-01-01 01:00:00.000000000 +0100
11096 +++ buildroot-2017.05.2/package/vlc/0014-decoder-check-visible-size-when-creating-buffer.patch 2017-07-27 08:16:52.017486944 +0200
11097 @@ -0,0 +1,33 @@
11098 +From a38a85db58c569cc592d9380cc07096757ef3d49 Mon Sep 17 00:00:00 2001
11099 +From: Francois Cartegnie <fcvlcdev@free.fr>
11100 +Date: Thu, 29 Jun 2017 11:09:02 +0200
11101 +Subject: [PATCH] decoder: check visible size when creating buffer
11103 +early reject invalid visible size
11104 +mishandled by filters.
11106 +refs #18467
11108 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11109 +---
11110 + src/input/decoder.c | 4 +++-
11111 + 1 file changed, 3 insertions(+), 1 deletion(-)
11113 +diff --git a/src/input/decoder.c b/src/input/decoder.c
11114 +index 2c0823f..a216165 100644
11115 +--- a/src/input/decoder.c
11116 ++++ b/src/input/decoder.c
11117 +@@ -2060,7 +2060,9 @@ static picture_t *vout_new_buffer( decoder_t *p_dec )
11118 + vout_thread_t *p_vout;
11120 + if( !p_dec->fmt_out.video.i_width ||
11121 +- !p_dec->fmt_out.video.i_height )
11122 ++ !p_dec->fmt_out.video.i_height ||
11123 ++ p_dec->fmt_out.video.i_width < p_dec->fmt_out.video.i_visible_width ||
11124 ++ p_dec->fmt_out.video.i_height < p_dec->fmt_out.video.i_visible_height )
11126 + /* Can't create a new vout without display size */
11127 + return NULL;
11128 +--
11129 +2.1.4
11131 diff -Naurp buildroot-2017.05-rc2/package/vlc/vlc.hash buildroot-2017.05.2/package/vlc/vlc.hash
11132 --- buildroot-2017.05-rc2/package/vlc/vlc.hash 2017-05-17 10:27:16.013401440 +0200
11133 +++ buildroot-2017.05.2/package/vlc/vlc.hash 2017-07-27 08:16:52.017486944 +0200
11134 @@ -1,6 +1,2 @@
11135 -# From http://get.videolan.org/vlc/2.2.5.1/vlc-2.2.5.1.tar.xz.md5
11136 -md5 7ab63964ffec4c92a54deb018f23318b vlc-2.2.5.1.tar.xz
11137 -# From http://get.videolan.org/vlc/2.2.5.1/vlc-2.2.5.1.tar.xz.sha1
11138 -sha1 042962dba68e1414aa563883b0172ee121cf9555 vlc-2.2.5.1.tar.xz
11139 -# From http://get.videolan.org/vlc/2.2.5.1/vlc-2.2.5.1.tar.xz.sha256
11140 -sha256 b28b8a28f578c0c6cb1ebed293aca2a3cd368906cf777d1ab599e2784ddda1cc vlc-2.2.5.1.tar.xz
11141 +# From http://download.videolan.org/pub/videolan/vlc/2.2.6/vlc-2.2.6.tar.xz.sha256
11142 +sha256 c403d3accd9a400eb2181c958f3e7bc5524fe5738425f4253d42883b425a42a8 vlc-2.2.6.tar.xz
11143 diff -Naurp buildroot-2017.05-rc2/package/vlc/vlc.mk buildroot-2017.05.2/package/vlc/vlc.mk
11144 --- buildroot-2017.05-rc2/package/vlc/vlc.mk 2017-05-17 10:27:16.013401440 +0200
11145 +++ buildroot-2017.05.2/package/vlc/vlc.mk 2017-07-27 08:16:52.017486944 +0200
11146 @@ -4,7 +4,7 @@
11148 ################################################################################
11150 -VLC_VERSION = 2.2.5.1
11151 +VLC_VERSION = 2.2.6
11152 VLC_SITE = http://get.videolan.org/vlc/$(VLC_VERSION)
11153 VLC_SOURCE = vlc-$(VLC_VERSION).tar.xz
11154 VLC_LICENSE = GPL-2.0+, LGPL-2.1+
11155 diff -Naurp buildroot-2017.05-rc2/package/vpnc/Config.in buildroot-2017.05.2/package/vpnc/Config.in
11156 --- buildroot-2017.05-rc2/package/vpnc/Config.in 2017-05-17 10:27:16.013401440 +0200
11157 +++ buildroot-2017.05.2/package/vpnc/Config.in 2017-07-27 08:16:52.017486944 +0200
11158 @@ -1,6 +1,7 @@
11159 config BR2_PACKAGE_VPNC
11160 bool "vpnc"
11161 depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt
11162 + depends on !BR2_STATIC_LIBS # gnutls
11163 depends on BR2_USE_MMU # fork()
11164 depends on BR2_USE_WCHAR # gnutls
11165 select BR2_PACKAGE_LIBGCRYPT
11166 @@ -15,6 +16,6 @@ config BR2_PACKAGE_VPNC
11168 http://www.unix-ag.uni-kl.de/~massar/vpnc
11170 -comment "vpnc needs a toolchain w/ wchar"
11171 +comment "vpnc needs a toolchain w/ wchar, dynamic library"
11172 depends on BR2_USE_MMU
11173 - depends on !BR2_USE_WCHAR
11174 + depends on !BR2_USE_WCHAR || BR2_STATIC_LIBS
11175 diff -Naurp buildroot-2017.05-rc2/package/webkitgtk/0001-fix-gcc6-builds.patch buildroot-2017.05.2/package/webkitgtk/0001-fix-gcc6-builds.patch
11176 --- buildroot-2017.05-rc2/package/webkitgtk/0001-fix-gcc6-builds.patch 2017-05-17 10:27:16.013401440 +0200
11177 +++ buildroot-2017.05.2/package/webkitgtk/0001-fix-gcc6-builds.patch 1970-01-01 01:00:00.000000000 +0100
11178 @@ -1,53 +0,0 @@
11179 -[CMake] Build failure with GCC 6 (fatal error: stdlib.h: No such file or directory)
11181 -https://bugs.webkit.org/show_bug.cgi?id=161697
11183 -Reviewed by Michael Catanzaro.
11185 -Get the list of system includes from GCC and add it to the CMake
11186 -list of implicit includes. This way, CMake will filter any of this
11187 -directories from the list of includes when calling the compiler.
11189 -This avoids an issue with GCC 6 that causes build failures when
11190 -including the default include path as a system include (-isystem).
11192 -Upstream, from: https://trac.webkit.org/changeset/205672
11194 -Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
11196 -Index: trunk/Source/cmake/OptionsCommon.cmake
11197 -===================================================================
11198 ---- trunk/Source/cmake/OptionsCommon.cmake (revision 204084)
11199 -+++ trunk/Source/cmake/OptionsCommon.cmake (revision 205672)
11200 -@@ -36,4 +36,31 @@
11201 - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fcolor-diagnostics")
11202 - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fcolor-diagnostics")
11203 -+endif ()
11205 -+# Ensure that the default include system directories are added to the list of CMake implicit includes.
11206 -+# This workarounds an issue that happens when using GCC 6 and using system includes (-isystem).
11207 -+# For more details check: https://bugs.webkit.org/show_bug.cgi?id=161697
11208 -+macro(DETERMINE_GCC_SYSTEM_INCLUDE_DIRS _lang _compiler _flags _result)
11209 -+ file(WRITE "${CMAKE_BINARY_DIR}/CMakeFiles/dummy" "\n")
11210 -+ separate_arguments(_buildFlags UNIX_COMMAND "${_flags}")
11211 -+ execute_process(COMMAND ${_compiler} ${_buildFlags} -v -E -x ${_lang} -dD dummy
11212 -+ WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/CMakeFiles OUTPUT_QUIET
11213 -+ ERROR_VARIABLE _gccOutput)
11214 -+ file(REMOVE "${CMAKE_BINARY_DIR}/CMakeFiles/dummy")
11215 -+ if ("${_gccOutput}" MATCHES "> search starts here[^\n]+\n *(.+) *\n *End of (search) list")
11216 -+ set(${_result} ${CMAKE_MATCH_1})
11217 -+ string(REPLACE "\n" " " ${_result} "${${_result}}")
11218 -+ separate_arguments(${_result})
11219 -+ endif ()
11220 -+endmacro()
11222 -+if (CMAKE_COMPILER_IS_GNUCC)
11223 -+ DETERMINE_GCC_SYSTEM_INCLUDE_DIRS("c" "${CMAKE_C_COMPILER}" "${CMAKE_C_FLAGS}" SYSTEM_INCLUDE_DIRS)
11224 -+ set(CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES ${CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES} ${SYSTEM_INCLUDE_DIRS})
11225 -+endif ()
11227 -+if (CMAKE_COMPILER_IS_GNUCXX)
11228 -+ DETERMINE_GCC_SYSTEM_INCLUDE_DIRS("c++" "${CMAKE_CXX_COMPILER}" "${CMAKE_CXX_FLAGS}" SYSTEM_INCLUDE_DIRS)
11229 -+ set(CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES} ${SYSTEM_INCLUDE_DIRS})
11230 - endif ()
11232 diff -Naurp buildroot-2017.05-rc2/package/webkitgtk/Config.in buildroot-2017.05.2/package/webkitgtk/Config.in
11233 --- buildroot-2017.05-rc2/package/webkitgtk/Config.in 2017-05-17 10:27:16.013401440 +0200
11234 +++ buildroot-2017.05.2/package/webkitgtk/Config.in 2017-07-27 08:16:52.017486944 +0200
11235 @@ -9,6 +9,7 @@ config BR2_PACKAGE_WEBKITGTK_ARCH_SUPPOR
11236 # Disabled on SuperH because of segfault
11237 depends on BR2_USE_MMU # libglib2
11238 depends on BR2_TOOLCHAIN_HAS_SYNC_4
11239 + depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt
11241 comment "webkitgtk needs libgtk3 and a glibc toolchain w/ C++, gcc >= 4.9"
11242 depends on BR2_PACKAGE_WEBKITGTK_ARCH_SUPPORTS
11243 @@ -30,6 +31,7 @@ config BR2_PACKAGE_WEBKITGTK
11244 select BR2_PACKAGE_HARFBUZZ
11245 select BR2_PACKAGE_ICU
11246 select BR2_PACKAGE_JPEG
11247 + select BR2_PACKAGE_LIBGCRYPT
11248 select BR2_PACKAGE_LIBSECRET
11249 select BR2_PACKAGE_LIBSOUP
11250 select BR2_PACKAGE_LIBXML2
11251 @@ -49,11 +51,15 @@ if BR2_PACKAGE_WEBKITGTK
11253 config BR2_PACKAGE_WEBKITGTK_HTTPS
11254 bool "HTTPS support"
11255 + depends on !BR2_STATIC_LIBS # gnutls -> libsoup
11256 select BR2_PACKAGE_CA_CERTIFICATES # runtime
11257 select BR2_PACKAGE_LIBSOUP_SSL
11258 help
11259 Enable HTTPS protocol support.
11261 +comment "webkitgtk https support needs a toolchain w/ dynamic library"
11262 + depends on BR2_STATIC_LIBS
11264 config BR2_PACKAGE_WEBKITGTK_MULTIMEDIA
11265 bool "multimedia support"
11266 select BR2_PACKAGE_GSTREAMER1
11267 diff -Naurp buildroot-2017.05-rc2/package/webkitgtk/webkitgtk.hash buildroot-2017.05.2/package/webkitgtk/webkitgtk.hash
11268 --- buildroot-2017.05-rc2/package/webkitgtk/webkitgtk.hash 2017-05-17 10:27:16.013401440 +0200
11269 +++ buildroot-2017.05.2/package/webkitgtk/webkitgtk.hash 2017-07-27 08:16:52.017486944 +0200
11270 @@ -1,4 +1,4 @@
11271 -# From http://www.webkitgtk.org/releases/webkitgtk-2.12.5.tar.xz.sha1
11272 -sha1 2d73fd5b47c68c73aea8b3d7b88acc8e62bdb99c webkitgtk-2.12.5.tar.xz
11273 -# Calculated based on the hash above
11274 -sha256 6b147854b864a5f115fadb97b2b6200b2f696db015216a34e7298d11c88b1c40 webkitgtk-2.12.5.tar.xz
11275 +# From https://webkitgtk.org/releases/webkitgtk-2.16.6.tar.xz.sums
11276 +md5 0e2d142a586e4ff79cf0324f4fdbf20c webkitgtk-2.16.6.tar.xz
11277 +sha1 f7fca3fbac3dc99e39f353a6df250635e684c922 webkitgtk-2.16.6.tar.xz
11278 +sha256 fc23650df953123c59b9c0edf3855e7bd55bd107820997fc72375811e1ea4b21 webkitgtk-2.16.6.tar.xz
11279 diff -Naurp buildroot-2017.05-rc2/package/webkitgtk/webkitgtk.mk buildroot-2017.05.2/package/webkitgtk/webkitgtk.mk
11280 --- buildroot-2017.05-rc2/package/webkitgtk/webkitgtk.mk 2017-05-17 10:27:16.013401440 +0200
11281 +++ buildroot-2017.05.2/package/webkitgtk/webkitgtk.mk 2017-07-27 08:16:52.017486944 +0200
11282 @@ -4,7 +4,7 @@
11284 ################################################################################
11286 -WEBKITGTK_VERSION = 2.12.5
11287 +WEBKITGTK_VERSION = 2.16.6
11288 WEBKITGTK_SITE = http://www.webkitgtk.org/releases
11289 WEBKITGTK_SOURCE = webkitgtk-$(WEBKITGTK_VERSION).tar.xz
11290 WEBKITGTK_INSTALL_STAGING = YES
11291 @@ -13,7 +13,7 @@ WEBKITGTK_LICENSE_FILES = \
11292 Source/WebCore/LICENSE-APPLE \
11293 Source/WebCore/LICENSE-LGPL-2.1
11294 WEBKITGTK_DEPENDENCIES = host-ruby host-flex host-bison host-gperf \
11295 - enchant harfbuzz icu jpeg libgtk3 libsecret libsoup \
11296 + enchant harfbuzz icu jpeg libgcrypt libgtk3 libsecret libsoup \
11297 libxml2 libxslt sqlite webp
11298 WEBKITGTK_CONF_OPTS = \
11299 -DENABLE_API_TESTS=OFF \
11300 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xlib_libxshmfence/Config.in buildroot-2017.05.2/package/x11r7/xlib_libxshmfence/Config.in
11301 --- buildroot-2017.05-rc2/package/x11r7/xlib_libxshmfence/Config.in 2017-05-17 10:27:16.013401440 +0200
11302 +++ buildroot-2017.05.2/package/x11r7/xlib_libxshmfence/Config.in 2017-07-27 08:16:52.017486944 +0200
11303 @@ -1,5 +1,6 @@
11304 config BR2_PACKAGE_XLIB_LIBXSHMFENCE
11305 bool "libxshmfence"
11306 + depends on BR2_TOOLCHAIN_HAS_SYNC_4
11307 select BR2_PACKAGE_XPROTO_XPROTO
11308 help
11309 X.Org shmfence library
11310 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0001-sdksyms-gcc5.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0001-sdksyms-gcc5.patch
11311 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0001-sdksyms-gcc5.patch 1970-01-01 01:00:00.000000000 +0100
11312 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0001-sdksyms-gcc5.patch 2017-07-27 08:16:52.017486944 +0200
11313 @@ -0,0 +1,50 @@
11314 +From 21b896939c5bb242f3aacc37baf12379e43254b6 Mon Sep 17 00:00:00 2001
11315 +From: Egbert Eich <eich@freedesktop.org>
11316 +Date: Tue, 3 Mar 2015 16:27:05 +0100
11317 +Subject: symbols: Fix sdksyms.sh to cope with gcc5
11319 +Gcc5 adds additional lines stating line numbers before and
11320 +after __attribute__() which need to be skipped.
11322 +Downloaded from upstream commit
11323 +https://cgit.freedesktop.org/xorg/xserver/commit/hw/xfree86/sdksyms.sh?id=21b896939c5bb242f3aacc37baf12379e43254b6
11325 +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
11326 +Signed-off-by: Egbert Eich <eich@freedesktop.org>
11327 +Tested-by: Daniel Stone <daniels@collabora.com>
11328 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11330 +diff --git a/hw/xfree86/sdksyms.sh b/hw/xfree86/sdksyms.sh
11331 +index 2305073..05ac410 100755
11332 +--- a/hw/xfree86/sdksyms.sh
11333 ++++ b/hw/xfree86/sdksyms.sh
11334 +@@ -350,13 +350,25 @@ BEGIN {
11335 + if (sdk) {
11336 + n = 3;
11338 ++ # skip line numbers GCC 5 adds before __attribute__
11339 ++ while ($n == "" || $0 ~ /^# [0-9]+ "/) {
11340 ++ getline;
11341 ++ n = 1;
11342 ++ }
11344 + # skip attribute, if any
11345 + while ($n ~ /^(__attribute__|__global)/ ||
11346 + # skip modifiers, if any
11347 + $n ~ /^\*?(unsigned|const|volatile|struct|_X_EXPORT)$/ ||
11348 + # skip pointer
11349 +- $n ~ /^[a-zA-Z0-9_]*\*$/)
11350 ++ $n ~ /^[a-zA-Z0-9_]*\*$/) {
11351 + n++;
11352 ++ # skip line numbers GCC 5 adds after __attribute__
11353 ++ while ($n == "" || $0 ~ /^# [0-9]+ "/) {
11354 ++ getline;
11355 ++ n = 1;
11356 ++ }
11357 ++ }
11359 + # type specifier may not be set, as in
11360 + # extern _X_EXPORT unsigned name(...)
11361 +--
11362 +cgit v0.10.2
11364 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch
11365 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11366 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11367 @@ -0,0 +1,39 @@
11368 +From 05442de962d3dc624f79fc1a00eca3ffc5489ced Mon Sep 17 00:00:00 2001
11369 +From: Michal Srb <msrb@suse.com>
11370 +Date: Wed, 24 May 2017 15:54:39 +0300
11371 +Subject: [PATCH] Xi: Zero target buffer in SProcXSendExtensionEvent.
11373 +Make sure that the xEvent eventT is initialized with zeros, the same way as
11374 +in SProcSendEvent.
11376 +Some event swapping functions do not overwrite all 32 bytes of xEvent
11377 +structure, for example XSecurityAuthorizationRevoked. Two cooperating
11378 +clients, one swapped and the other not, can send
11379 +XSecurityAuthorizationRevoked event to each other to retrieve old stack data
11380 +from X server. This can be potentialy misused to go around ASLR or
11381 +stack-protector.
11383 +Signed-off-by: Michal Srb <msrb@suse.com>
11384 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11385 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11386 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11387 +---
11388 + Xi/sendexev.c | 2 +-
11389 + 1 file changed, 1 insertion(+), 1 deletion(-)
11391 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11392 +index 11d82029f..1cf118ab6 100644
11393 +--- a/Xi/sendexev.c
11394 ++++ b/Xi/sendexev.c
11395 +@@ -78,7 +78,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11397 + CARD32 *p;
11398 + int i;
11399 +- xEvent eventT;
11400 ++ xEvent eventT = { .u.u.type = 0 };
11401 + xEvent *eventP;
11402 + EventSwapPtr proc;
11404 +--
11405 +2.11.0
11407 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch
11408 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch 1970-01-01 01:00:00.000000000 +0100
11409 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch 2017-07-27 08:16:52.017486944 +0200
11410 @@ -0,0 +1,71 @@
11411 +From 215f894965df5fb0bb45b107d84524e700d2073c Mon Sep 17 00:00:00 2001
11412 +From: Michal Srb <msrb@suse.com>
11413 +Date: Wed, 24 May 2017 15:54:40 +0300
11414 +Subject: [PATCH] dix: Disallow GenericEvent in SendEvent request.
11416 +The SendEvent request holds xEvent which is exactly 32 bytes long, no more,
11417 +no less. Both ProcSendEvent and SProcSendEvent verify that the received data
11418 +exactly match the request size. However nothing stops the client from passing
11419 +in event with xEvent::type = GenericEvent and any value of
11420 +xGenericEvent::length.
11422 +In the case of ProcSendEvent, the event will be eventually passed to
11423 +WriteEventsToClient which will see that it is Generic event and copy the
11424 +arbitrary length from the receive buffer (and possibly past it) and send it to
11425 +the other client. This allows clients to copy unitialized heap memory out of X
11426 +server or to crash it.
11428 +In case of SProcSendEvent, it will attempt to swap the incoming event by
11429 +calling a swapping function from the EventSwapVector array. The swapped event
11430 +is written to target buffer, which in this case is local xEvent variable. The
11431 +xEvent variable is 32 bytes long, but the swapping functions for GenericEvents
11432 +expect that the target buffer has size matching the size of the source
11433 +GenericEvent. This allows clients to cause stack buffer overflows.
11435 +Signed-off-by: Michal Srb <msrb@suse.com>
11436 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11437 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11438 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11439 +---
11440 + dix/events.c | 6 ++++++
11441 + dix/swapreq.c | 7 +++++++
11442 + 2 files changed, 13 insertions(+)
11444 +diff --git a/dix/events.c b/dix/events.c
11445 +index 3e3a01ef9..d3a33ea3f 100644
11446 +--- a/dix/events.c
11447 ++++ b/dix/events.c
11448 +@@ -5366,6 +5366,12 @@ ProcSendEvent(ClientPtr client)
11449 + client->errorValue = stuff->event.u.u.type;
11450 + return BadValue;
11452 ++ /* Generic events can have variable size, but SendEvent request holds
11453 ++ exactly 32B of event data. */
11454 ++ if (stuff->event.u.u.type == GenericEvent) {
11455 ++ client->errorValue = stuff->event.u.u.type;
11456 ++ return BadValue;
11457 ++ }
11458 + if (stuff->event.u.u.type == ClientMessage &&
11459 + stuff->event.u.u.detail != 8 &&
11460 + stuff->event.u.u.detail != 16 && stuff->event.u.u.detail != 32) {
11461 +diff --git a/dix/swapreq.c b/dix/swapreq.c
11462 +index 719e9b81c..67850593b 100644
11463 +--- a/dix/swapreq.c
11464 ++++ b/dix/swapreq.c
11465 +@@ -292,6 +292,13 @@ SProcSendEvent(ClientPtr client)
11466 + swapl(&stuff->destination);
11467 + swapl(&stuff->eventMask);
11469 ++ /* Generic events can have variable size, but SendEvent request holds
11470 ++ exactly 32B of event data. */
11471 ++ if (stuff->event.u.u.type == GenericEvent) {
11472 ++ client->errorValue = stuff->event.u.u.type;
11473 ++ return BadValue;
11474 ++ }
11476 + /* Swap event */
11477 + proc = EventSwapVector[stuff->event.u.u.type & 0177];
11478 + if (!proc || proc == NotImplemented) /* no swapping proc; invalid event type? */
11479 +--
11480 +2.11.0
11482 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch
11483 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11484 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11485 @@ -0,0 +1,50 @@
11486 +From 8caed4df36b1f802b4992edcfd282cbeeec35d9d Mon Sep 17 00:00:00 2001
11487 +From: Michal Srb <msrb@suse.com>
11488 +Date: Wed, 24 May 2017 15:54:41 +0300
11489 +Subject: [PATCH] Xi: Verify all events in ProcXSendExtensionEvent.
11491 +The requirement is that events have type in range
11492 +EXTENSION_EVENT_BASE..lastEvent, but it was tested
11493 +only for first event of all.
11495 +Signed-off-by: Michal Srb <msrb@suse.com>
11496 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11497 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11498 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11499 +---
11500 + Xi/sendexev.c | 12 +++++++-----
11501 + 1 file changed, 7 insertions(+), 5 deletions(-)
11503 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11504 +index 1cf118ab6..5e63bfcca 100644
11505 +--- a/Xi/sendexev.c
11506 ++++ b/Xi/sendexev.c
11507 +@@ -117,7 +117,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11508 + int
11509 + ProcXSendExtensionEvent(ClientPtr client)
11511 +- int ret;
11512 ++ int ret, i;
11513 + DeviceIntPtr dev;
11514 + xEvent *first;
11515 + XEventClass *list;
11516 +@@ -141,10 +141,12 @@ ProcXSendExtensionEvent(ClientPtr client)
11517 + /* The client's event type must be one defined by an extension. */
11519 + first = ((xEvent *) &stuff[1]);
11520 +- if (!((EXTENSION_EVENT_BASE <= first->u.u.type) &&
11521 +- (first->u.u.type < lastEvent))) {
11522 +- client->errorValue = first->u.u.type;
11523 +- return BadValue;
11524 ++ for (i = 0; i < stuff->num_events; i++) {
11525 ++ if (!((EXTENSION_EVENT_BASE <= first[i].u.u.type) &&
11526 ++ (first[i].u.u.type < lastEvent))) {
11527 ++ client->errorValue = first[i].u.u.type;
11528 ++ return BadValue;
11529 ++ }
11532 + list = (XEventClass *) (first + stuff->num_events);
11533 +--
11534 +2.11.0
11536 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0005-Xi-Do-not-try-to-swap-GenericEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0005-Xi-Do-not-try-to-swap-GenericEvent.patch
11537 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.14.7/0005-Xi-Do-not-try-to-swap-GenericEvent.patch 1970-01-01 01:00:00.000000000 +0100
11538 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.14.7/0005-Xi-Do-not-try-to-swap-GenericEvent.patch 2017-07-27 08:16:52.017486944 +0200
11539 @@ -0,0 +1,45 @@
11540 +From ba336b24052122b136486961c82deac76bbde455 Mon Sep 17 00:00:00 2001
11541 +From: Michal Srb <msrb@suse.com>
11542 +Date: Wed, 24 May 2017 15:54:42 +0300
11543 +Subject: [PATCH] Xi: Do not try to swap GenericEvent.
11545 +The SProcXSendExtensionEvent must not attempt to swap GenericEvent because
11546 +it is assuming that the event has fixed size and gives the swapping function
11547 +xEvent-sized buffer.
11549 +A GenericEvent would be later rejected by ProcXSendExtensionEvent anyway.
11551 +Signed-off-by: Michal Srb <msrb@suse.com>
11552 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11553 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11554 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11555 +---
11556 + Xi/sendexev.c | 10 +++++++++-
11557 + 1 file changed, 9 insertions(+), 1 deletion(-)
11559 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11560 +index 5e63bfcca..5c2e0fc56 100644
11561 +--- a/Xi/sendexev.c
11562 ++++ b/Xi/sendexev.c
11563 +@@ -95,9 +95,17 @@ SProcXSendExtensionEvent(ClientPtr client)
11565 + eventP = (xEvent *) &stuff[1];
11566 + for (i = 0; i < stuff->num_events; i++, eventP++) {
11567 ++ if (eventP->u.u.type == GenericEvent) {
11568 ++ client->errorValue = eventP->u.u.type;
11569 ++ return BadValue;
11570 ++ }
11572 + proc = EventSwapVector[eventP->u.u.type & 0177];
11573 +- if (proc == NotImplemented) /* no swapping proc; invalid event type? */
11574 ++ /* no swapping proc; invalid event type? */
11575 ++ if (proc == NotImplemented) {
11576 ++ client->errorValue = eventP->u.u.type;
11577 + return BadValue;
11578 ++ }
11579 + (*proc) (eventP, &eventT);
11580 + *eventP = eventT;
11582 +--
11583 +2.11.0
11585 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch
11586 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11587 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0002-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11588 @@ -0,0 +1,39 @@
11589 +From 05442de962d3dc624f79fc1a00eca3ffc5489ced Mon Sep 17 00:00:00 2001
11590 +From: Michal Srb <msrb@suse.com>
11591 +Date: Wed, 24 May 2017 15:54:39 +0300
11592 +Subject: [PATCH] Xi: Zero target buffer in SProcXSendExtensionEvent.
11594 +Make sure that the xEvent eventT is initialized with zeros, the same way as
11595 +in SProcSendEvent.
11597 +Some event swapping functions do not overwrite all 32 bytes of xEvent
11598 +structure, for example XSecurityAuthorizationRevoked. Two cooperating
11599 +clients, one swapped and the other not, can send
11600 +XSecurityAuthorizationRevoked event to each other to retrieve old stack data
11601 +from X server. This can be potentialy misused to go around ASLR or
11602 +stack-protector.
11604 +Signed-off-by: Michal Srb <msrb@suse.com>
11605 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11606 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11607 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11608 +---
11609 + Xi/sendexev.c | 2 +-
11610 + 1 file changed, 1 insertion(+), 1 deletion(-)
11612 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11613 +index 11d82029f..1cf118ab6 100644
11614 +--- a/Xi/sendexev.c
11615 ++++ b/Xi/sendexev.c
11616 +@@ -78,7 +78,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11618 + CARD32 *p;
11619 + int i;
11620 +- xEvent eventT;
11621 ++ xEvent eventT = { .u.u.type = 0 };
11622 + xEvent *eventP;
11623 + EventSwapPtr proc;
11625 +--
11626 +2.11.0
11628 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch
11629 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch 1970-01-01 01:00:00.000000000 +0100
11630 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0003-dix-Disallow-GenericEvent-in-SendEvent-request.patch 2017-07-27 08:16:52.017486944 +0200
11631 @@ -0,0 +1,71 @@
11632 +From 215f894965df5fb0bb45b107d84524e700d2073c Mon Sep 17 00:00:00 2001
11633 +From: Michal Srb <msrb@suse.com>
11634 +Date: Wed, 24 May 2017 15:54:40 +0300
11635 +Subject: [PATCH] dix: Disallow GenericEvent in SendEvent request.
11637 +The SendEvent request holds xEvent which is exactly 32 bytes long, no more,
11638 +no less. Both ProcSendEvent and SProcSendEvent verify that the received data
11639 +exactly match the request size. However nothing stops the client from passing
11640 +in event with xEvent::type = GenericEvent and any value of
11641 +xGenericEvent::length.
11643 +In the case of ProcSendEvent, the event will be eventually passed to
11644 +WriteEventsToClient which will see that it is Generic event and copy the
11645 +arbitrary length from the receive buffer (and possibly past it) and send it to
11646 +the other client. This allows clients to copy unitialized heap memory out of X
11647 +server or to crash it.
11649 +In case of SProcSendEvent, it will attempt to swap the incoming event by
11650 +calling a swapping function from the EventSwapVector array. The swapped event
11651 +is written to target buffer, which in this case is local xEvent variable. The
11652 +xEvent variable is 32 bytes long, but the swapping functions for GenericEvents
11653 +expect that the target buffer has size matching the size of the source
11654 +GenericEvent. This allows clients to cause stack buffer overflows.
11656 +Signed-off-by: Michal Srb <msrb@suse.com>
11657 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11658 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11659 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11660 +---
11661 + dix/events.c | 6 ++++++
11662 + dix/swapreq.c | 7 +++++++
11663 + 2 files changed, 13 insertions(+)
11665 +diff --git a/dix/events.c b/dix/events.c
11666 +index 3e3a01ef9..d3a33ea3f 100644
11667 +--- a/dix/events.c
11668 ++++ b/dix/events.c
11669 +@@ -5366,6 +5366,12 @@ ProcSendEvent(ClientPtr client)
11670 + client->errorValue = stuff->event.u.u.type;
11671 + return BadValue;
11673 ++ /* Generic events can have variable size, but SendEvent request holds
11674 ++ exactly 32B of event data. */
11675 ++ if (stuff->event.u.u.type == GenericEvent) {
11676 ++ client->errorValue = stuff->event.u.u.type;
11677 ++ return BadValue;
11678 ++ }
11679 + if (stuff->event.u.u.type == ClientMessage &&
11680 + stuff->event.u.u.detail != 8 &&
11681 + stuff->event.u.u.detail != 16 && stuff->event.u.u.detail != 32) {
11682 +diff --git a/dix/swapreq.c b/dix/swapreq.c
11683 +index 719e9b81c..67850593b 100644
11684 +--- a/dix/swapreq.c
11685 ++++ b/dix/swapreq.c
11686 +@@ -292,6 +292,13 @@ SProcSendEvent(ClientPtr client)
11687 + swapl(&stuff->destination);
11688 + swapl(&stuff->eventMask);
11690 ++ /* Generic events can have variable size, but SendEvent request holds
11691 ++ exactly 32B of event data. */
11692 ++ if (stuff->event.u.u.type == GenericEvent) {
11693 ++ client->errorValue = stuff->event.u.u.type;
11694 ++ return BadValue;
11695 ++ }
11697 + /* Swap event */
11698 + proc = EventSwapVector[stuff->event.u.u.type & 0177];
11699 + if (!proc || proc == NotImplemented) /* no swapping proc; invalid event type? */
11700 +--
11701 +2.11.0
11703 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch
11704 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11705 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0004-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11706 @@ -0,0 +1,50 @@
11707 +From 8caed4df36b1f802b4992edcfd282cbeeec35d9d Mon Sep 17 00:00:00 2001
11708 +From: Michal Srb <msrb@suse.com>
11709 +Date: Wed, 24 May 2017 15:54:41 +0300
11710 +Subject: [PATCH] Xi: Verify all events in ProcXSendExtensionEvent.
11712 +The requirement is that events have type in range
11713 +EXTENSION_EVENT_BASE..lastEvent, but it was tested
11714 +only for first event of all.
11716 +Signed-off-by: Michal Srb <msrb@suse.com>
11717 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11718 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11719 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11720 +---
11721 + Xi/sendexev.c | 12 +++++++-----
11722 + 1 file changed, 7 insertions(+), 5 deletions(-)
11724 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11725 +index 1cf118ab6..5e63bfcca 100644
11726 +--- a/Xi/sendexev.c
11727 ++++ b/Xi/sendexev.c
11728 +@@ -117,7 +117,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11729 + int
11730 + ProcXSendExtensionEvent(ClientPtr client)
11732 +- int ret;
11733 ++ int ret, i;
11734 + DeviceIntPtr dev;
11735 + xEvent *first;
11736 + XEventClass *list;
11737 +@@ -141,10 +141,12 @@ ProcXSendExtensionEvent(ClientPtr client)
11738 + /* The client's event type must be one defined by an extension. */
11740 + first = ((xEvent *) &stuff[1]);
11741 +- if (!((EXTENSION_EVENT_BASE <= first->u.u.type) &&
11742 +- (first->u.u.type < lastEvent))) {
11743 +- client->errorValue = first->u.u.type;
11744 +- return BadValue;
11745 ++ for (i = 0; i < stuff->num_events; i++) {
11746 ++ if (!((EXTENSION_EVENT_BASE <= first[i].u.u.type) &&
11747 ++ (first[i].u.u.type < lastEvent))) {
11748 ++ client->errorValue = first[i].u.u.type;
11749 ++ return BadValue;
11750 ++ }
11753 + list = (XEventClass *) (first + stuff->num_events);
11754 +--
11755 +2.11.0
11757 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0005-Xi-Do-not-try-to-swap-GenericEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0005-Xi-Do-not-try-to-swap-GenericEvent.patch
11758 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.17.4/0005-Xi-Do-not-try-to-swap-GenericEvent.patch 1970-01-01 01:00:00.000000000 +0100
11759 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.17.4/0005-Xi-Do-not-try-to-swap-GenericEvent.patch 2017-07-27 08:16:52.017486944 +0200
11760 @@ -0,0 +1,45 @@
11761 +From ba336b24052122b136486961c82deac76bbde455 Mon Sep 17 00:00:00 2001
11762 +From: Michal Srb <msrb@suse.com>
11763 +Date: Wed, 24 May 2017 15:54:42 +0300
11764 +Subject: [PATCH] Xi: Do not try to swap GenericEvent.
11766 +The SProcXSendExtensionEvent must not attempt to swap GenericEvent because
11767 +it is assuming that the event has fixed size and gives the swapping function
11768 +xEvent-sized buffer.
11770 +A GenericEvent would be later rejected by ProcXSendExtensionEvent anyway.
11772 +Signed-off-by: Michal Srb <msrb@suse.com>
11773 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11774 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11775 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11776 +---
11777 + Xi/sendexev.c | 10 +++++++++-
11778 + 1 file changed, 9 insertions(+), 1 deletion(-)
11780 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11781 +index 5e63bfcca..5c2e0fc56 100644
11782 +--- a/Xi/sendexev.c
11783 ++++ b/Xi/sendexev.c
11784 +@@ -95,9 +95,17 @@ SProcXSendExtensionEvent(ClientPtr client)
11786 + eventP = (xEvent *) &stuff[1];
11787 + for (i = 0; i < stuff->num_events; i++, eventP++) {
11788 ++ if (eventP->u.u.type == GenericEvent) {
11789 ++ client->errorValue = eventP->u.u.type;
11790 ++ return BadValue;
11791 ++ }
11793 + proc = EventSwapVector[eventP->u.u.type & 0177];
11794 +- if (proc == NotImplemented) /* no swapping proc; invalid event type? */
11795 ++ /* no swapping proc; invalid event type? */
11796 ++ if (proc == NotImplemented) {
11797 ++ client->errorValue = eventP->u.u.type;
11798 + return BadValue;
11799 ++ }
11800 + (*proc) (eventP, &eventT);
11801 + *eventP = eventT;
11803 +--
11804 +2.11.0
11806 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0004-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0004-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch
11807 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0004-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11808 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0004-Xi-Zero-target-buffer-in-SProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11809 @@ -0,0 +1,39 @@
11810 +From 05442de962d3dc624f79fc1a00eca3ffc5489ced Mon Sep 17 00:00:00 2001
11811 +From: Michal Srb <msrb@suse.com>
11812 +Date: Wed, 24 May 2017 15:54:39 +0300
11813 +Subject: [PATCH] Xi: Zero target buffer in SProcXSendExtensionEvent.
11815 +Make sure that the xEvent eventT is initialized with zeros, the same way as
11816 +in SProcSendEvent.
11818 +Some event swapping functions do not overwrite all 32 bytes of xEvent
11819 +structure, for example XSecurityAuthorizationRevoked. Two cooperating
11820 +clients, one swapped and the other not, can send
11821 +XSecurityAuthorizationRevoked event to each other to retrieve old stack data
11822 +from X server. This can be potentialy misused to go around ASLR or
11823 +stack-protector.
11825 +Signed-off-by: Michal Srb <msrb@suse.com>
11826 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11827 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11828 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11829 +---
11830 + Xi/sendexev.c | 2 +-
11831 + 1 file changed, 1 insertion(+), 1 deletion(-)
11833 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11834 +index 11d82029f..1cf118ab6 100644
11835 +--- a/Xi/sendexev.c
11836 ++++ b/Xi/sendexev.c
11837 +@@ -78,7 +78,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11839 + CARD32 *p;
11840 + int i;
11841 +- xEvent eventT;
11842 ++ xEvent eventT = { .u.u.type = 0 };
11843 + xEvent *eventP;
11844 + EventSwapPtr proc;
11846 +--
11847 +2.11.0
11849 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0005-dix-Disallow-GenericEvent-in-SendEvent-request.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0005-dix-Disallow-GenericEvent-in-SendEvent-request.patch
11850 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0005-dix-Disallow-GenericEvent-in-SendEvent-request.patch 1970-01-01 01:00:00.000000000 +0100
11851 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0005-dix-Disallow-GenericEvent-in-SendEvent-request.patch 2017-07-27 08:16:52.017486944 +0200
11852 @@ -0,0 +1,71 @@
11853 +From 215f894965df5fb0bb45b107d84524e700d2073c Mon Sep 17 00:00:00 2001
11854 +From: Michal Srb <msrb@suse.com>
11855 +Date: Wed, 24 May 2017 15:54:40 +0300
11856 +Subject: [PATCH] dix: Disallow GenericEvent in SendEvent request.
11858 +The SendEvent request holds xEvent which is exactly 32 bytes long, no more,
11859 +no less. Both ProcSendEvent and SProcSendEvent verify that the received data
11860 +exactly match the request size. However nothing stops the client from passing
11861 +in event with xEvent::type = GenericEvent and any value of
11862 +xGenericEvent::length.
11864 +In the case of ProcSendEvent, the event will be eventually passed to
11865 +WriteEventsToClient which will see that it is Generic event and copy the
11866 +arbitrary length from the receive buffer (and possibly past it) and send it to
11867 +the other client. This allows clients to copy unitialized heap memory out of X
11868 +server or to crash it.
11870 +In case of SProcSendEvent, it will attempt to swap the incoming event by
11871 +calling a swapping function from the EventSwapVector array. The swapped event
11872 +is written to target buffer, which in this case is local xEvent variable. The
11873 +xEvent variable is 32 bytes long, but the swapping functions for GenericEvents
11874 +expect that the target buffer has size matching the size of the source
11875 +GenericEvent. This allows clients to cause stack buffer overflows.
11877 +Signed-off-by: Michal Srb <msrb@suse.com>
11878 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11879 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11880 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11881 +---
11882 + dix/events.c | 6 ++++++
11883 + dix/swapreq.c | 7 +++++++
11884 + 2 files changed, 13 insertions(+)
11886 +diff --git a/dix/events.c b/dix/events.c
11887 +index 3e3a01ef9..d3a33ea3f 100644
11888 +--- a/dix/events.c
11889 ++++ b/dix/events.c
11890 +@@ -5366,6 +5366,12 @@ ProcSendEvent(ClientPtr client)
11891 + client->errorValue = stuff->event.u.u.type;
11892 + return BadValue;
11894 ++ /* Generic events can have variable size, but SendEvent request holds
11895 ++ exactly 32B of event data. */
11896 ++ if (stuff->event.u.u.type == GenericEvent) {
11897 ++ client->errorValue = stuff->event.u.u.type;
11898 ++ return BadValue;
11899 ++ }
11900 + if (stuff->event.u.u.type == ClientMessage &&
11901 + stuff->event.u.u.detail != 8 &&
11902 + stuff->event.u.u.detail != 16 && stuff->event.u.u.detail != 32) {
11903 +diff --git a/dix/swapreq.c b/dix/swapreq.c
11904 +index 719e9b81c..67850593b 100644
11905 +--- a/dix/swapreq.c
11906 ++++ b/dix/swapreq.c
11907 +@@ -292,6 +292,13 @@ SProcSendEvent(ClientPtr client)
11908 + swapl(&stuff->destination);
11909 + swapl(&stuff->eventMask);
11911 ++ /* Generic events can have variable size, but SendEvent request holds
11912 ++ exactly 32B of event data. */
11913 ++ if (stuff->event.u.u.type == GenericEvent) {
11914 ++ client->errorValue = stuff->event.u.u.type;
11915 ++ return BadValue;
11916 ++ }
11918 + /* Swap event */
11919 + proc = EventSwapVector[stuff->event.u.u.type & 0177];
11920 + if (!proc || proc == NotImplemented) /* no swapping proc; invalid event type? */
11921 +--
11922 +2.11.0
11924 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0006-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0006-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch
11925 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0006-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 1970-01-01 01:00:00.000000000 +0100
11926 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0006-Xi-Verify-all-events-in-ProcXSendExtensionEvent.patch 2017-07-27 08:16:52.017486944 +0200
11927 @@ -0,0 +1,50 @@
11928 +From 8caed4df36b1f802b4992edcfd282cbeeec35d9d Mon Sep 17 00:00:00 2001
11929 +From: Michal Srb <msrb@suse.com>
11930 +Date: Wed, 24 May 2017 15:54:41 +0300
11931 +Subject: [PATCH] Xi: Verify all events in ProcXSendExtensionEvent.
11933 +The requirement is that events have type in range
11934 +EXTENSION_EVENT_BASE..lastEvent, but it was tested
11935 +only for first event of all.
11937 +Signed-off-by: Michal Srb <msrb@suse.com>
11938 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11939 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11940 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11941 +---
11942 + Xi/sendexev.c | 12 +++++++-----
11943 + 1 file changed, 7 insertions(+), 5 deletions(-)
11945 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
11946 +index 1cf118ab6..5e63bfcca 100644
11947 +--- a/Xi/sendexev.c
11948 ++++ b/Xi/sendexev.c
11949 +@@ -117,7 +117,7 @@ SProcXSendExtensionEvent(ClientPtr client)
11950 + int
11951 + ProcXSendExtensionEvent(ClientPtr client)
11953 +- int ret;
11954 ++ int ret, i;
11955 + DeviceIntPtr dev;
11956 + xEvent *first;
11957 + XEventClass *list;
11958 +@@ -141,10 +141,12 @@ ProcXSendExtensionEvent(ClientPtr client)
11959 + /* The client's event type must be one defined by an extension. */
11961 + first = ((xEvent *) &stuff[1]);
11962 +- if (!((EXTENSION_EVENT_BASE <= first->u.u.type) &&
11963 +- (first->u.u.type < lastEvent))) {
11964 +- client->errorValue = first->u.u.type;
11965 +- return BadValue;
11966 ++ for (i = 0; i < stuff->num_events; i++) {
11967 ++ if (!((EXTENSION_EVENT_BASE <= first[i].u.u.type) &&
11968 ++ (first[i].u.u.type < lastEvent))) {
11969 ++ client->errorValue = first[i].u.u.type;
11970 ++ return BadValue;
11971 ++ }
11974 + list = (XEventClass *) (first + stuff->num_events);
11975 +--
11976 +2.11.0
11978 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0007-Xi-Do-not-try-to-swap-GenericEvent.patch buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0007-Xi-Do-not-try-to-swap-GenericEvent.patch
11979 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/1.19.3/0007-Xi-Do-not-try-to-swap-GenericEvent.patch 1970-01-01 01:00:00.000000000 +0100
11980 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/1.19.3/0007-Xi-Do-not-try-to-swap-GenericEvent.patch 2017-07-27 08:16:52.017486944 +0200
11981 @@ -0,0 +1,45 @@
11982 +From ba336b24052122b136486961c82deac76bbde455 Mon Sep 17 00:00:00 2001
11983 +From: Michal Srb <msrb@suse.com>
11984 +Date: Wed, 24 May 2017 15:54:42 +0300
11985 +Subject: [PATCH] Xi: Do not try to swap GenericEvent.
11987 +The SProcXSendExtensionEvent must not attempt to swap GenericEvent because
11988 +it is assuming that the event has fixed size and gives the swapping function
11989 +xEvent-sized buffer.
11991 +A GenericEvent would be later rejected by ProcXSendExtensionEvent anyway.
11993 +Signed-off-by: Michal Srb <msrb@suse.com>
11994 +Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
11995 +Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
11996 +Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11997 +---
11998 + Xi/sendexev.c | 10 +++++++++-
11999 + 1 file changed, 9 insertions(+), 1 deletion(-)
12001 +diff --git a/Xi/sendexev.c b/Xi/sendexev.c
12002 +index 5e63bfcca..5c2e0fc56 100644
12003 +--- a/Xi/sendexev.c
12004 ++++ b/Xi/sendexev.c
12005 +@@ -95,9 +95,17 @@ SProcXSendExtensionEvent(ClientPtr client)
12007 + eventP = (xEvent *) &stuff[1];
12008 + for (i = 0; i < stuff->num_events; i++, eventP++) {
12009 ++ if (eventP->u.u.type == GenericEvent) {
12010 ++ client->errorValue = eventP->u.u.type;
12011 ++ return BadValue;
12012 ++ }
12014 + proc = EventSwapVector[eventP->u.u.type & 0177];
12015 +- if (proc == NotImplemented) /* no swapping proc; invalid event type? */
12016 ++ /* no swapping proc; invalid event type? */
12017 ++ if (proc == NotImplemented) {
12018 ++ client->errorValue = eventP->u.u.type;
12019 + return BadValue;
12020 ++ }
12021 + (*proc) (eventP, &eventT);
12022 + *eventP = eventT;
12024 +--
12025 +2.11.0
12027 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/Config.in buildroot-2017.05.2/package/x11r7/xserver_xorg-server/Config.in
12028 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/Config.in 2017-05-17 10:27:16.013401440 +0200
12029 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/Config.in 2017-07-27 08:16:52.017486944 +0200
12030 @@ -114,7 +114,8 @@ config BR2_PACKAGE_XSERVER_XORG_SERVER_M
12031 select BR2_PACKAGE_LIBDRM if (BR2_PACKAGE_XPROTO_XF86DRIPROTO || \
12032 BR2_PACKAGE_XPROTO_DRI2PROTO)
12033 select BR2_PACKAGE_LIBPCIACCESS
12034 - select BR2_PACKAGE_XLIB_LIBXSHMFENCE if BR2_PACKAGE_XPROTO_DRI3PROTO
12035 + select BR2_PACKAGE_XLIB_LIBXSHMFENCE if \
12036 + (BR2_PACKAGE_XPROTO_DRI3PROTO && BR2_TOOLCHAIN_HAS_SYNC_4)
12037 help
12038 This variant of the X.org server is the full-blown variant,
12039 as used by desktop GNU/Linux distributions. The drivers (for
12040 diff -Naurp buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/xserver_xorg-server.mk buildroot-2017.05.2/package/x11r7/xserver_xorg-server/xserver_xorg-server.mk
12041 --- buildroot-2017.05-rc2/package/x11r7/xserver_xorg-server/xserver_xorg-server.mk 2017-05-17 10:27:16.013401440 +0200
12042 +++ buildroot-2017.05.2/package/x11r7/xserver_xorg-server/xserver_xorg-server.mk 2017-07-27 08:16:52.017486944 +0200
12043 @@ -220,7 +220,7 @@ XSERVER_XORG_SERVER_CONF_OPTS += --enabl
12044 else
12045 XSERVER_XORG_SERVER_CONF_OPTS += --disable-dri2
12046 endif
12047 -ifeq ($(BR2_PACKAGE_XPROTO_DRI3PROTO),y)
12048 +ifeq ($(BR2_PACKAGE_XLIB_LIBXSHMFENCE)$(BR2_PACKAGE_XPROTO_DRI3PROTO),yy)
12049 XSERVER_XORG_SERVER_DEPENDENCIES += xlib_libxshmfence xproto_dri3proto
12050 XSERVER_XORG_SERVER_CONF_OPTS += --enable-dri3
12051 ifeq ($(BR2_PACKAGE_HAS_LIBGL)$(BR2_PACKAGE_LIBEPOXY),yy)
12052 diff -Naurp buildroot-2017.05-rc2/package/x264/x264.mk buildroot-2017.05.2/package/x264/x264.mk
12053 --- buildroot-2017.05-rc2/package/x264/x264.mk 2017-05-17 10:27:16.013401440 +0200
12054 +++ buildroot-2017.05.2/package/x264/x264.mk 2017-07-27 08:16:52.017486944 +0200
12055 @@ -10,7 +10,7 @@ X264_LICENSE = GPL-2.0+
12056 X264_DEPENDENCIES = host-pkgconf
12057 X264_LICENSE_FILES = COPYING
12058 X264_INSTALL_STAGING = YES
12059 -X264_CONF_OPTS = --disable-avs
12060 +X264_CONF_OPTS = --disable-avs --disable-lavf --disable-swscale
12062 ifeq ($(BR2_i386)$(BR2_x86_64),y)
12063 # yasm needed for assembly files
12064 diff -Naurp buildroot-2017.05-rc2/package/x265/x265.mk buildroot-2017.05.2/package/x265/x265.mk
12065 --- buildroot-2017.05-rc2/package/x265/x265.mk 2017-05-17 10:27:16.013401440 +0200
12066 +++ buildroot-2017.05.2/package/x265/x265.mk 2017-07-27 08:16:52.017486944 +0200
12067 @@ -16,6 +16,12 @@ ifeq ($(BR2_i386)$(BR2_x86_64),y)
12068 X265_DEPENDENCIES += host-yasm
12069 endif
12071 +# disable altivec, it has build issues
12072 +# https://bitbucket.org/multicoreware/x265/issues/320/
12073 +ifeq ($(BR2_powerpc64)$(BR2_powerpc64le),y)
12074 +X265_CONF_OPTS += -DENABLE_ALTIVEC=OFF
12075 +endif
12077 ifeq ($(BR2_SHARED_LIBS)$(BR2_SHARED_STATIC_LIBS),y)
12078 X265_CONF_OPTS += -DENABLE_SHARED=ON -DENABLE_PIC=ON
12079 else
12080 diff -Naurp buildroot-2017.05-rc2/package/xen/0007-tools-include-sys-sysmacros.h-on-Linux.patch buildroot-2017.05.2/package/xen/0007-tools-include-sys-sysmacros.h-on-Linux.patch
12081 --- buildroot-2017.05-rc2/package/xen/0007-tools-include-sys-sysmacros.h-on-Linux.patch 1970-01-01 01:00:00.000000000 +0100
12082 +++ buildroot-2017.05.2/package/xen/0007-tools-include-sys-sysmacros.h-on-Linux.patch 2017-07-27 08:16:52.017486944 +0200
12083 @@ -0,0 +1,52 @@
12084 +From 796dea37fb229c34740f98bf80f3263d7a4e3c6d Mon Sep 17 00:00:00 2001
12085 +From: Olaf Hering <olaf@aepfle.de>
12086 +Date: Wed, 15 Mar 2017 07:01:34 +0000
12087 +Subject: [PATCH] tools: include sys/sysmacros.h on Linux
12089 +Due to a bug in the glibc headers the macros makedev(), major() and
12090 +minor() where available by including sys/types.h. This bug was
12091 +addressed in glibc-2.25 by introducing a warning when these macros are
12092 +used. Since Xen is build with -Werror this new warning cause a compile
12093 +error.
12095 +Use sys/sysmacros.h to define these three macros.
12097 +blktap2 is already Linux specific. The kernel header which was used to
12098 +get makedev() does not provided it anymore, and it was wrong to use a
12099 +kernel header anyway.
12101 +Signed-off-by: Olaf Hering <olaf@aepfle.de>
12102 +Acked-by: Wei Liu <wei.liu2@citrix.com>
12103 +Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
12104 +---
12105 + tools/blktap2/control/tap-ctl-allocate.c | 1 +
12106 + tools/libxl/libxl_osdeps.h | 1 +
12107 + 2 files changed, 2 insertions(+)
12109 +diff --git a/tools/blktap2/control/tap-ctl-allocate.c b/tools/blktap2/control/tap-ctl-allocate.c
12110 +index 8a6471e987..187cadcde7 100644
12111 +--- a/tools/blktap2/control/tap-ctl-allocate.c
12112 ++++ b/tools/blktap2/control/tap-ctl-allocate.c
12113 +@@ -33,6 +33,7 @@
12114 + #include <string.h>
12115 + #include <getopt.h>
12116 + #include <libgen.h>
12117 ++#include <sys/sysmacros.h>
12118 + #include <sys/stat.h>
12119 + #include <sys/types.h>
12120 + #include <sys/ioctl.h>
12121 +diff --git a/tools/libxl/libxl_osdeps.h b/tools/libxl/libxl_osdeps.h
12122 +index a40d62066b..de1d24ecae 100644
12123 +--- a/tools/libxl/libxl_osdeps.h
12124 ++++ b/tools/libxl/libxl_osdeps.h
12125 +@@ -39,6 +39,7 @@
12126 + #define SYSFS_PCI_DEV "/sys/bus/pci/devices"
12127 + #define SYSFS_PCIBACK_DRIVER "/sys/bus/pci/drivers/pciback"
12128 + #define NETBACK_NIC_NAME "vif%u.%d"
12129 ++#include <sys/sysmacros.h>
12130 + #include <pty.h>
12131 + #include <uuid/uuid.h>
12132 + #elif defined(__sun__)
12133 +--
12134 +2.11.0
12136 diff -Naurp buildroot-2017.05-rc2/package/xen/0008-arm-fix-build-with-gcc-7.patch buildroot-2017.05.2/package/xen/0008-arm-fix-build-with-gcc-7.patch
12137 --- buildroot-2017.05-rc2/package/xen/0008-arm-fix-build-with-gcc-7.patch 1970-01-01 01:00:00.000000000 +0100
12138 +++ buildroot-2017.05.2/package/xen/0008-arm-fix-build-with-gcc-7.patch 2017-07-27 08:16:52.017486944 +0200
12139 @@ -0,0 +1,70 @@
12140 +From 9d3011bd1cd29f8f3841bf1b64d5ead9ed1434e8 Mon Sep 17 00:00:00 2001
12141 +From: Jan Beulich <jbeulich@suse.com>
12142 +Date: Fri, 19 May 2017 10:12:08 +0200
12143 +Subject: [PATCH] arm: fix build with gcc 7
12145 +The compiler dislikes duplicate "const", and the ones it complains
12146 +about look like they we in fact meant to be placed differently.
12148 +Also fix array_access_okay() (just like on x86), despite the construct
12149 +being unused on ARM: -Wint-in-bool-context, enabled by default in
12150 +gcc 7, doesn't like multiplication in conditional operators. "Hide" it,
12151 +at the risk of the next compiler version becoming smarter and
12152 +recognizing even that. (The hope is that added smartness then would
12153 +also better deal with legitimate cases like the one here.) The change
12154 +could have been done in access_ok(), but I think we better keep it at
12155 +the place the compiler is actually unhappy about.
12157 +Signed-off-by: Jan Beulich <jbeulich@suse.com>
12158 +Reviewed-by: Julien Grall <julien.grall@arm.com>
12159 +Release-acked-by: Julien Grall <julien.grall@arm.com>
12160 +Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
12161 +---
12162 + xen/arch/arm/platforms/brcm.c | 2 +-
12163 + xen/arch/arm/platforms/rcar2.c | 2 +-
12164 + xen/include/asm-arm/guest_access.h | 3 ++-
12165 + 3 files changed, 4 insertions(+), 3 deletions(-)
12167 +diff --git a/xen/arch/arm/platforms/brcm.c b/xen/arch/arm/platforms/brcm.c
12168 +index 6d8b5b9175..d481b2c60f 100644
12169 +--- a/xen/arch/arm/platforms/brcm.c
12170 ++++ b/xen/arch/arm/platforms/brcm.c
12171 +@@ -271,7 +271,7 @@ static __init int brcm_init(void)
12172 + return brcm_populate_plat_regs();
12175 +-static const char const *brcm_dt_compat[] __initconst =
12176 ++static const char *const brcm_dt_compat[] __initconst =
12178 + "brcm,bcm7445d0",
12179 + NULL
12180 +diff --git a/xen/arch/arm/platforms/rcar2.c b/xen/arch/arm/platforms/rcar2.c
12181 +index bb25751109..df0ac84709 100644
12182 +--- a/xen/arch/arm/platforms/rcar2.c
12183 ++++ b/xen/arch/arm/platforms/rcar2.c
12184 +@@ -46,7 +46,7 @@ static int __init rcar2_smp_init(void)
12185 + return 0;
12188 +-static const char const *rcar2_dt_compat[] __initdata =
12189 ++static const char *const rcar2_dt_compat[] __initconst =
12191 + "renesas,lager",
12192 + NULL
12193 +diff --git a/xen/include/asm-arm/guest_access.h b/xen/include/asm-arm/guest_access.h
12194 +index 5876988b23..421bca5f36 100644
12195 +--- a/xen/include/asm-arm/guest_access.h
12196 ++++ b/xen/include/asm-arm/guest_access.h
12197 +@@ -8,7 +8,8 @@
12198 + #define access_ok(addr,size) (1)
12200 + #define array_access_ok(addr,count,size) \
12201 +- (likely(count < (~0UL/size)) && access_ok(addr,count*size))
12202 ++ (likely((count) < (~0UL / (size))) && \
12203 ++ access_ok(addr, 0 + (count) * (size)))
12205 + unsigned long raw_copy_to_guest(void *to, const void *from, unsigned len);
12206 + unsigned long raw_copy_to_guest_flush_dcache(void *to, const void *from,
12207 +--
12208 +2.11.0
12210 diff -Naurp buildroot-2017.05-rc2/package/xen/xen.mk buildroot-2017.05.2/package/xen/xen.mk
12211 --- buildroot-2017.05-rc2/package/xen/xen.mk 2017-05-17 10:27:16.013401440 +0200
12212 +++ buildroot-2017.05.2/package/xen/xen.mk 2017-07-27 08:16:52.017486944 +0200
12213 @@ -8,7 +8,7 @@ XEN_VERSION = 4.8.1
12214 XEN_SITE = http://bits.xensource.com/oss-xen/release/$(XEN_VERSION)
12215 XEN_LICENSE = GPL-2.0
12216 XEN_LICENSE_FILES = COPYING
12217 -XEN_DEPENDENCIES = host-python
12218 +XEN_DEPENDENCIES = host-acpica host-python
12220 # Calculate XEN_ARCH
12221 ifeq ($(ARCH),aarch64)
12222 diff -Naurp buildroot-2017.05-rc2/package/xvisor/Config.in buildroot-2017.05.2/package/xvisor/Config.in
12223 --- buildroot-2017.05-rc2/package/xvisor/Config.in 2017-05-17 10:27:16.013401440 +0200
12224 +++ buildroot-2017.05.2/package/xvisor/Config.in 2017-07-27 08:16:52.017486944 +0200
12225 @@ -35,7 +35,7 @@ config BR2_PACKAGE_XVISOR_DEFCONFIG
12226 default "generic-v5" if BR2_ARM_CPU_ARMV5
12227 default "generic-v6" if BR2_ARM_CPU_ARMV6
12228 default "generic-v7" if BR2_ARM_CPU_ARMV7A
12229 - default "generic-v8" if BR2_AARCH64
12230 + default "generic-v8" if BR2_aarch64
12231 default "x86_64_generic" if BR2_x86_64
12232 depends on BR2_PACKAGE_XVISOR_USE_DEFCONFIG
12233 help
12234 diff -Naurp buildroot-2017.05-rc2/package/xvisor/xvisor.mk buildroot-2017.05.2/package/xvisor/xvisor.mk
12235 --- buildroot-2017.05-rc2/package/xvisor/xvisor.mk 2017-05-17 10:27:16.013401440 +0200
12236 +++ buildroot-2017.05.2/package/xvisor/xvisor.mk 2017-07-27 08:16:52.017486944 +0200
12237 @@ -26,8 +26,20 @@ XVISOR_KCONFIG_FILE = $(call qstrip,$(BR
12238 endif
12239 XVISOR_KCONFIG_EDITORS = menuconfig
12241 +ifeq ($(BR2_x86_64),y)
12242 +XVISOR_ARCH = x86
12243 +else ifeq ($(BR2_arm)$(BR2_aarch64),y)
12244 +XVISOR_ARCH = arm
12245 +endif
12247 +ifeq ($(BR2_PACKAGE_XVISOR)$(BR_BUILDING),yy)
12248 +ifeq ($(XVISOR_ARCH),)
12249 +$(error "Architecture not supported by XVisor")
12250 +endif
12251 +endif
12253 XVISOR_MAKE_ENV = \
12254 - ARCH=$(if $(BR2_x86_64),x86,$(BR2_ARCH)) \
12255 + ARCH=$(XVISOR_ARCH) \
12256 CROSS_COMPILE=$(TARGET_CROSS)
12258 XVISOR_MAKE_OPTS = $(if $(VERBOSE),VERBOSE=1)
12259 diff -Naurp buildroot-2017.05-rc2/support/misc/Vagrantfile buildroot-2017.05.2/support/misc/Vagrantfile
12260 --- buildroot-2017.05-rc2/support/misc/Vagrantfile 2017-05-17 10:27:16.013401440 +0200
12261 +++ buildroot-2017.05.2/support/misc/Vagrantfile 2017-07-27 08:16:52.017486944 +0200
12262 @@ -5,7 +5,7 @@
12263 ################################################################################
12265 # Buildroot version to use
12266 -RELEASE='2017.02'
12267 +RELEASE='2017.05'
12269 ### Change here for more memory/cores ###
12270 VM_MEMORY=2048
12271 diff -Naurp buildroot-2017.05-rc2/support/scripts/mkusers buildroot-2017.05.2/support/scripts/mkusers
12272 --- buildroot-2017.05-rc2/support/scripts/mkusers 2017-05-17 10:27:16.013401440 +0200
12273 +++ buildroot-2017.05.2/support/scripts/mkusers 2017-07-27 08:16:52.017486944 +0200
12274 @@ -219,12 +219,12 @@ add_one_group() {
12277 # Remove any previous instance of this group, and re-add the new one
12278 - sed -i -e '/^'"${group}"':.*/d;' "${GROUP}"
12279 + sed -i --follow-symlinks -e '/^'"${group}"':.*/d;' "${GROUP}"
12280 printf "%s:x:%d:\n" "${group}" "${gid}" >>"${GROUP}"
12282 # Ditto for /etc/gshadow if it exists
12283 if [ -f "${GSHADOW}" ]; then
12284 - sed -i -e '/^'"${group}"':.*/d;' "${GSHADOW}"
12285 + sed -i --follow-symlinks -e '/^'"${group}"':.*/d;' "${GSHADOW}"
12286 printf "%s:*::\n" "${group}" >>"${GSHADOW}"
12289 @@ -263,7 +263,8 @@ add_user_to_group() {
12291 for _f in "${GROUP}" "${GSHADOW}"; do
12292 [ -f "${_f}" ] || continue
12293 - sed -r -i -e 's/^('"${group}"':.*:)(([^:]+,)?)'"${username}"'(,[^:]+*)?$/\1\2\4/;' \
12294 + sed -r -i --follow-symlinks \
12295 + -e 's/^('"${group}"':.*:)(([^:]+,)?)'"${username}"'(,[^:]+*)?$/\1\2\4/;' \
12296 -e 's/^('"${group}"':.*)$/\1,'"${username}"'/;' \
12297 -e 's/,+/,/' \
12298 -e 's/:,/:/' \
12299 @@ -303,7 +304,7 @@ add_one_user() {
12301 # Remove any previous instance of this user
12302 for _f in "${PASSWD}" "${SHADOW}"; do
12303 - sed -r -i -e '/^'"${username}"':.*/d;' "${_f}"
12304 + sed -r -i --follow-symlinks -e '/^'"${username}"':.*/d;' "${_f}"
12305 done
12307 _gid="$( get_gid "${group}" )"
12308 diff -Naurp buildroot-2017.05-rc2/support/scripts/scancpan buildroot-2017.05.2/support/scripts/scancpan
12309 --- buildroot-2017.05-rc2/support/scripts/scancpan 2017-05-17 10:27:16.013401440 +0200
12310 +++ buildroot-2017.05.2/support/scripts/scancpan 2017-07-27 08:16:52.017486944 +0200
12311 @@ -521,7 +521,7 @@ my %deps_runtime; # name -> list o
12312 my %deps_optional; # name -> list of optional target dependencies
12313 my %license_files; # name -> list of license files
12314 my %checksum; # author -> list of checksum
12315 -my $mcpan = MetaCPAN::API::Tiny->new();
12316 +my $mcpan = MetaCPAN::API::Tiny->new(base_url => 'http://fastapi.metacpan.org/v1');
12317 my $ua = HTTP::Tiny->new();
12319 sub get_checksum {
12320 @@ -538,7 +538,7 @@ sub get_checksum {
12322 sub get_manifest {
12323 my ($author, $distname, $version) = @_;
12324 - my $url = qq{http://api.metacpan.org/source/${author}/${distname}-${version}/MANIFEST};
12325 + my $url = qq{http://fastapi.metacpan.org/source/${author}/${distname}-${version}/MANIFEST};
12326 my $response = $ua->get($url);
12327 return $response->{content};
12329 diff -Naurp buildroot-2017.05-rc2/support/scripts/setlocalversion buildroot-2017.05.2/support/scripts/setlocalversion
12330 --- buildroot-2017.05-rc2/support/scripts/setlocalversion 2017-05-17 10:27:16.013401440 +0200
12331 +++ buildroot-2017.05.2/support/scripts/setlocalversion 2017-07-27 08:16:52.017486944 +0200
12332 @@ -54,7 +54,7 @@ fi
12334 # Check for mercurial and a mercurial repo.
12335 if hgid=`hg id 2>/dev/null`; then
12336 - tag=`printf '%s' "$hgid" | cut -d' ' -f2`
12337 + tag=`printf '%s' "$hgid" | cut -d' ' -f2 --only-delimited`
12339 # Do we have an untagged version?
12340 if [ -z "$tag" -o "$tag" = tip ]; then
12341 diff -Naurp buildroot-2017.05-rc2/support/testing/infra/builder.py buildroot-2017.05.2/support/testing/infra/builder.py
12342 --- buildroot-2017.05-rc2/support/testing/infra/builder.py 2017-05-17 10:27:16.013401440 +0200
12343 +++ buildroot-2017.05.2/support/testing/infra/builder.py 2017-07-27 08:16:52.017486944 +0200
12344 @@ -8,16 +8,12 @@ class Builder(object):
12345 def __init__(self, config, builddir, logtofile):
12346 self.config = config
12347 self.builddir = builddir
12348 - self.logtofile = logtofile
12349 + self.logfile = infra.open_log_file(builddir, "build", logtofile)
12351 def build(self):
12352 if not os.path.isdir(self.builddir):
12353 os.makedirs(self.builddir)
12355 - log = "{}-build.log".format(self.builddir)
12356 - if not self.logtofile:
12357 - log = None
12359 config_file = os.path.join(self.builddir, ".config")
12360 with open(config_file, "w+") as cf:
12361 cf.write(self.config)
12362 @@ -25,14 +21,12 @@ class Builder(object):
12363 cmd = ["make",
12364 "O={}".format(self.builddir),
12365 "olddefconfig"]
12366 - with infra.smart_open(log) as log_fh:
12367 - ret = subprocess.call(cmd, stdout=log_fh, stderr=log_fh)
12368 + ret = subprocess.call(cmd, stdout=self.logfile, stderr=self.logfile)
12369 if ret != 0:
12370 raise SystemError("Cannot olddefconfig")
12372 cmd = ["make", "-C", self.builddir]
12373 - with infra.smart_open(log) as log_fh:
12374 - ret = subprocess.call(cmd, stdout=log_fh, stderr=log_fh)
12375 + ret = subprocess.call(cmd, stdout=self.logfile, stderr=self.logfile)
12376 if ret != 0:
12377 raise SystemError("Build failed")
12379 diff -Naurp buildroot-2017.05-rc2/support/testing/infra/emulator.py buildroot-2017.05.2/support/testing/infra/emulator.py
12380 --- buildroot-2017.05-rc2/support/testing/infra/emulator.py 2017-05-17 10:27:16.013401440 +0200
12381 +++ buildroot-2017.05.2/support/testing/infra/emulator.py 2017-07-27 08:16:52.017486944 +0200
12382 @@ -14,9 +14,7 @@ class Emulator(object):
12383 self.__tn = None
12384 self.downloaddir = downloaddir
12385 self.log = ""
12386 - self.log_file = "{}-run.log".format(builddir)
12387 - if logtofile is None:
12388 - self.log_file = None
12389 + self.logfile = infra.open_log_file(builddir, "run", logtofile)
12391 # Start Qemu to boot the system
12393 @@ -72,9 +70,8 @@ class Emulator(object):
12394 if kernel_cmdline:
12395 qemu_cmd += ["-append", " ".join(kernel_cmdline)]
12397 - with infra.smart_open(self.log_file) as lfh:
12398 - lfh.write("> starting qemu with '%s'\n" % " ".join(qemu_cmd))
12399 - self.qemu = subprocess.Popen(qemu_cmd, stdout=lfh, stderr=lfh)
12400 + self.logfile.write("> starting qemu with '%s'\n" % " ".join(qemu_cmd))
12401 + self.qemu = subprocess.Popen(qemu_cmd, stdout=self.logfile, stderr=self.logfile)
12403 # Wait for the telnet port to appear and connect to it.
12404 while True:
12405 @@ -88,8 +85,7 @@ class Emulator(object):
12406 def __read_until(self, waitstr, timeout=5):
12407 data = self.__tn.read_until(waitstr, timeout)
12408 self.log += data
12409 - with infra.smart_open(self.log_file) as lfh:
12410 - lfh.write(data)
12411 + self.logfile.write(data)
12412 return data
12414 def __write(self, wstr):
12415 @@ -100,8 +96,7 @@ class Emulator(object):
12416 def login(self, password=None):
12417 self.__read_until("buildroot login:", 10)
12418 if "buildroot login:" not in self.log:
12419 - with infra.smart_open(self.log_file) as lfh:
12420 - lfh.write("==> System does not boot")
12421 + self.logfile.write("==> System does not boot")
12422 raise SystemError("System does not boot")
12424 self.__write("root\n")
12425 diff -Naurp buildroot-2017.05-rc2/support/testing/infra/__init__.py buildroot-2017.05.2/support/testing/infra/__init__.py
12426 --- buildroot-2017.05-rc2/support/testing/infra/__init__.py 2017-05-17 10:27:16.013401440 +0200
12427 +++ buildroot-2017.05.2/support/testing/infra/__init__.py 2017-07-27 08:16:52.017486944 +0200
12428 @@ -8,24 +8,17 @@ from urllib2 import urlopen, HTTPError,
12430 ARTIFACTS_URL = "http://autobuild.buildroot.net/artefacts/"
12432 -@contextlib.contextmanager
12433 -def smart_open(filename=None):
12434 +def open_log_file(builddir, stage, logtofile=True):
12436 - Return a file-like object that can be written to using the 'with'
12437 - keyword, as in the example:
12438 - with infra.smart_open("test.log") as outfile:
12439 - outfile.write("Hello, world!\n")
12440 + Open a file for logging and return its handler.
12441 + If logtofile is True, returns sys.stdout. Otherwise opens a file
12442 + with a suitable name in the build directory.
12444 - if filename and filename != '-':
12445 - fhandle = open(filename, 'a+')
12446 + if logtofile:
12447 + fhandle = open("{}-{}.log".format(builddir, stage), 'a+')
12448 else:
12449 fhandle = sys.stdout
12451 - try:
12452 - yield fhandle
12453 - finally:
12454 - if fhandle is not sys.stdout:
12455 - fhandle.close()
12456 + return fhandle
12458 def filepath(relpath):
12459 return os.path.join(os.getcwd(), "support/testing", relpath)
12460 @@ -77,6 +70,16 @@ def get_file_arch(builddir, prefix, fpat
12461 return get_elf_arch_tag(builddir, prefix, fpath, "Tag_CPU_arch")
12463 def get_elf_prog_interpreter(builddir, prefix, fpath):
12464 + """
12465 + Runs the cross readelf on 'fpath' to extract the program interpreter
12466 + name and returns it.
12467 + Example:
12468 + >>> get_elf_prog_interpreter('br-tests/TestExternalToolchainLinaroArm',
12469 + 'arm-linux-gnueabihf',
12470 + 'bin/busybox')
12471 + /lib/ld-linux-armhf.so.3
12472 + >>>
12473 + """
12474 cmd = ["host/usr/bin/{}-readelf".format(prefix),
12475 "-l", os.path.join("target", fpath)]
12476 out = subprocess.check_output(cmd, cwd=builddir, env={"LANG": "C"})
12477 diff -Naurp buildroot-2017.05-rc2/support/testing/run-tests buildroot-2017.05.2/support/testing/run-tests
12478 --- buildroot-2017.05-rc2/support/testing/run-tests 2017-05-17 10:27:16.013401440 +0200
12479 +++ buildroot-2017.05.2/support/testing/run-tests 2017-07-27 08:16:52.017486944 +0200
12480 @@ -10,17 +10,17 @@ def main():
12481 parser = argparse.ArgumentParser(description='Run Buildroot tests')
12482 parser.add_argument('testname', nargs='*',
12483 help='list of test cases to execute')
12484 - parser.add_argument('--list', '-l', action='store_true',
12485 + parser.add_argument('-l', '--list', action='store_true',
12486 help='list of available test cases')
12487 - parser.add_argument('--all', '-a', action='store_true',
12488 + parser.add_argument('-a', '--all', action='store_true',
12489 help='execute all test cases')
12490 - parser.add_argument('--stdout', '-s', action='store_true',
12491 + parser.add_argument('-s', '--stdout', action='store_true',
12492 help='log everything to stdout')
12493 - parser.add_argument('--output', '-o',
12494 + parser.add_argument('-o', '--output',
12495 help='output directory')
12496 - parser.add_argument('--download', '-d',
12497 + parser.add_argument('-d', '--download',
12498 help='download directory')
12499 - parser.add_argument('--keep', '-k',
12500 + parser.add_argument('-k', '--keep',
12501 help='keep build directories',
12502 action='store_true')
12504 diff -Naurp buildroot-2017.05-rc2/support/testing/tests/fs/test_ext.py buildroot-2017.05.2/support/testing/tests/fs/test_ext.py
12505 --- buildroot-2017.05-rc2/support/testing/tests/fs/test_ext.py 2017-05-17 10:27:16.013401440 +0200
12506 +++ buildroot-2017.05.2/support/testing/tests/fs/test_ext.py 2017-07-27 08:16:52.017486944 +0200
12507 @@ -21,10 +21,10 @@ def dumpe2fs_run(builddir, image):
12508 return ret.strip().splitlines()
12510 def dumpe2fs_getprop(out, prop):
12511 - for lines in out:
12512 - lines = lines.split(": ")
12513 - if lines[0] == prop:
12514 - return lines[1].strip()
12515 + for line in out:
12516 + fields = line.split(": ")
12517 + if fields[0] == prop:
12518 + return fields[1].strip()
12520 def boot_img_and_check_fs_type(emulator, builddir, fs_type):
12521 img = os.path.join(builddir, "images", "rootfs.{}".format(fs_type))
12522 @@ -86,6 +86,7 @@ BR2_TARGET_ROOTFS_EXT2_3=y
12523 out = dumpe2fs_run(self.builddir, "rootfs.ext3")
12524 self.assertEqual(dumpe2fs_getprop(out, REVISION_PROP), "1 (dynamic)")
12525 self.assertIn("has_journal", dumpe2fs_getprop(out, FEATURES_PROP))
12526 + self.assertNotIn("extent", dumpe2fs_getprop(out, FEATURES_PROP))
12528 exit_code = boot_img_and_check_fs_type(self.emulator,
12529 self.builddir, "ext3")
12530 diff -Naurp buildroot-2017.05-rc2/support/testing/tests/toolchain/test_external.py buildroot-2017.05.2/support/testing/tests/toolchain/test_external.py
12531 --- buildroot-2017.05-rc2/support/testing/tests/toolchain/test_external.py 2017-05-17 10:27:16.013401440 +0200
12532 +++ buildroot-2017.05.2/support/testing/tests/toolchain/test_external.py 2017-07-27 08:16:52.017486944 +0200
12533 @@ -7,7 +7,7 @@ BR2_TARGET_ROOTFS_CPIO=y
12534 # BR2_TARGET_ROOTFS_TAR is not set
12537 -def check_broken_links(path):
12538 +def has_broken_links(path):
12539 for root, dirs, files in os.walk(path):
12540 for f in files:
12541 fpath = os.path.join(root, f)
12542 @@ -20,9 +20,9 @@ class TestExternalToolchain(infra.basete
12543 # Check for broken symlinks
12544 for d in ["lib", "usr/lib"]:
12545 path = os.path.join(self.builddir, "staging", d)
12546 - self.assertFalse(check_broken_links(path))
12547 + self.assertFalse(has_broken_links(path))
12548 path = os.path.join(self.builddir, "target", d)
12549 - self.assertFalse(check_broken_links(path))
12550 + self.assertFalse(has_broken_links(path))
12552 interp = infra.get_elf_prog_interpreter(self.builddir,
12553 self.toolchain_prefix,
12554 diff -Naurp buildroot-2017.05-rc2/toolchain/Config.in buildroot-2017.05.2/toolchain/Config.in
12555 --- buildroot-2017.05-rc2/toolchain/Config.in 2017-05-17 10:27:16.013401440 +0200
12556 +++ buildroot-2017.05.2/toolchain/Config.in 2017-07-27 08:16:52.017486944 +0200
12557 @@ -28,7 +28,7 @@ config BR2_TOOLCHAIN_USES_MUSL
12558 select BR2_TOOLCHAIN_HAS_THREADS
12559 select BR2_TOOLCHAIN_HAS_THREADS_DEBUG
12560 select BR2_TOOLCHAIN_HAS_THREADS_NPTL
12561 - select BR2_TOOLCHAIN_SUPPORTS_PIE
12562 + select BR2_TOOLCHAIN_SUPPORTS_PIE if !BR2_STATIC_LIBS
12564 choice
12565 prompt "Toolchain type"
12566 diff -Naurp buildroot-2017.05-rc2/toolchain/toolchain/toolchain.mk buildroot-2017.05.2/toolchain/toolchain/toolchain.mk
12567 --- buildroot-2017.05-rc2/toolchain/toolchain/toolchain.mk 2017-05-17 10:27:16.013401440 +0200
12568 +++ buildroot-2017.05.2/toolchain/toolchain/toolchain.mk 2017-07-27 08:16:52.017486944 +0200
12569 @@ -21,8 +21,10 @@ TOOLCHAIN_ADD_TOOLCHAIN_DEPENDENCY = NO
12570 # IFF_DORMANT and IFF_ECHO, add another macro to suppress them in the
12571 # kernel header, and avoid macro/enum conflict.
12573 +# Kernel version 3.12 introduced the libc-compat.h header.
12575 # [1] http://www.openwall.com/lists/musl/2015/10/08/2
12576 -ifeq ($(BR2_TOOLCHAIN_USES_MUSL),y)
12577 +ifeq ($(BR2_TOOLCHAIN_USES_MUSL)$(BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_12),yy)
12578 define TOOLCHAIN_MUSL_KERNEL_HEADERS_COMPATIBILITY_HACK
12579 $(SED) 's/^#if defined(__GLIBC__)$$/#if 1/' \
12580 $(STAGING_DIR)/usr/include/linux/libc-compat.h
12581 diff -Naurp buildroot-2017.05-rc2/toolchain/toolchain-common.in buildroot-2017.05.2/toolchain/toolchain-common.in
12582 --- buildroot-2017.05-rc2/toolchain/toolchain-common.in 2017-05-17 10:27:16.013401440 +0200
12583 +++ buildroot-2017.05.2/toolchain/toolchain-common.in 2017-07-27 08:16:52.017486944 +0200
12584 @@ -7,6 +7,11 @@ source "package/gdb/Config.in.host"
12586 comment "Toolchain Generic Options"
12588 +# https://sourceware.org/bugzilla/show_bug.cgi?id=19615
12589 +# Affect toolchains built with binutils 2.26 (fixed in binutils 2.26.1).
12590 +config BR2_TOOLCHAIN_HAS_BINUTILS_BUG_19615
12591 + bool
12593 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64735
12594 # exception_ptr, nested_exception, and future from libstdc++ are not
12595 # available for architectures not supporting always lock-free atomic
12596 diff -Naurp buildroot-2017.05-rc2/toolchain/toolchain-external/pkg-toolchain-external.mk buildroot-2017.05.2/toolchain/toolchain-external/pkg-toolchain-external.mk
12597 --- buildroot-2017.05-rc2/toolchain/toolchain-external/pkg-toolchain-external.mk 2017-05-17 10:27:16.013401440 +0200
12598 +++ buildroot-2017.05.2/toolchain/toolchain-external/pkg-toolchain-external.mk 2017-07-27 08:16:52.017486944 +0200
12599 @@ -476,11 +476,13 @@ endef
12600 # With the musl C library, the libc.so library directly plays the role
12601 # of the dynamic library loader. We just need to create a symbolic
12602 # link to libc.so with the appropriate name.
12603 -ifeq ($(BR2_TOOLCHAIN_EXTERNAL_MUSL),y)
12604 +ifeq ($(BR2_TOOLCHAIN_EXTERNAL_MUSL):$(BR2_STATIC_LIBS),y:)
12605 ifeq ($(BR2_i386),y)
12606 MUSL_ARCH = i386
12607 else ifeq ($(BR2_ARM_EABIHF),y)
12608 MUSL_ARCH = armhf
12609 +else ifeq ($(BR2_mips):$(BR2_SOFT_FLOAT),y:y)
12610 +MUSL_ARCH = mips-sf
12611 else ifeq ($(BR2_mipsel):$(BR2_SOFT_FLOAT),y:y)
12612 MUSL_ARCH = mipsel-sf
12613 else ifeq ($(BR2_sh),y)
12614 diff -Naurp buildroot-2017.05-rc2/toolchain/toolchain-external/toolchain-external-codesourcery-amd64/Config.in buildroot-2017.05.2/toolchain/toolchain-external/toolchain-external-codesourcery-amd64/Config.in
12615 --- buildroot-2017.05-rc2/toolchain/toolchain-external/toolchain-external-codesourcery-amd64/Config.in 2017-05-17 10:27:16.013401440 +0200
12616 +++ buildroot-2017.05.2/toolchain/toolchain-external/toolchain-external-codesourcery-amd64/Config.in 2017-07-27 08:16:52.017486944 +0200
12617 @@ -11,6 +11,7 @@ config BR2_TOOLCHAIN_EXTERNAL_CODESOURCE
12618 select BR2_HOSTARCH_NEEDS_IA32_LIBS
12619 select BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_7
12620 select BR2_TOOLCHAIN_GCC_AT_LEAST_6
12621 + select BR2_TOOLCHAIN_HAS_BINUTILS_BUG_19615 # based-on binutils-2.26
12622 help
12623 Sourcery CodeBench toolchain for the amd64 (x86_64)
12624 architectures, from Mentor Graphics. It uses gcc 6.2,