Browse Source

package/libusb: needs gcc >= 4.9

libusb depends on gcc >= 4.9 because of _Thread_local since version
1.0.24 and
https://github.com/libusb/libusb/commit/9a1bc8cafb904c20a869c74ad6d657686a1c4bb1

Fixes:
 - http://autobuild.buildroot.org/results/7b7f4b31095f8a7eecb347b574391003a2def8bc

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
Fabrice Fontaine 4 years ago
parent
commit
8a26801c9f
50 changed files with 236 additions and 80 deletions
  1. 4 3
      package/acsccid/Config.in
  2. 4 2
      package/apcupsd/Config.in
  3. 4 2
      package/avrdude/Config.in
  4. 5 2
      package/cc-tool/Config.in
  5. 4 2
      package/ccid/Config.in
  6. 4 2
      package/dfu-util/Config.in
  7. 4 0
      package/dfu-util/Config.in.host
  8. 4 2
      package/dump1090/Config.in
  9. 4 0
      package/gr-osmosdr/Config.in
  10. 4 2
      package/hackrf/Config.in
  11. 5 2
      package/hidapi/Config.in
  12. 3 2
      package/hplip/Config.in
  13. 4 2
      package/imx-usb-loader/Config.in
  14. 5 0
      package/imx-usb-loader/Config.in.host
  15. 4 0
      package/kodi/Config.in
  16. 4 2
      package/libftdi/Config.in
  17. 4 2
      package/libftdi1/Config.in
  18. 4 2
      package/libgphoto2/Config.in
  19. 4 2
      package/libhid/Config.in
  20. 4 2
      package/libiio/Config.in
  21. 4 2
      package/libiqrf/Config.in
  22. 4 2
      package/libnfc/Config.in
  23. 4 3
      package/libphidget/Config.in
  24. 4 2
      package/librtlsdr/Config.in
  25. 4 2
      package/libusb/Config.in
  26. 5 0
      package/mfgtools/Config.in.host
  27. 5 0
      package/mxsldr/Config.in.host
  28. 4 2
      package/omxplayer/Config.in
  29. 5 2
      package/openfpgaloader/Config.in
  30. 5 2
      package/openjdk/Config.in
  31. 23 5
      package/openocd/Config.in
  32. 4 0
      package/openocd/Config.in.host
  33. 4 0
      package/pcsc-lite/Config.in
  34. 4 3
      package/phidgetwebservice/Config.in
  35. 4 2
      package/python-libusb1/Config.in
  36. 4 2
      package/python-nfc/Config.in
  37. 4 2
      package/python-pylibftdi/Config.in
  38. 4 2
      package/python-pyusb/Config.in
  39. 4 0
      package/qemu/Config.in.host
  40. 5 0
      package/raspberrypi-usbboot/Config.in.host
  41. 4 2
      package/sispmctl/Config.in
  42. 4 2
      package/sunxi-tools/Config.in
  43. 5 0
      package/sunxi-tools/Config.in.host
  44. 5 0
      package/tegrarcm/Config.in.host
  45. 12 0
      package/uhd/Config.in
  46. 4 2
      package/uhubctl/Config.in
  47. 4 2
      package/upower/Config.in
  48. 4 2
      package/usb_modeswitch/Config.in
  49. 4 2
      package/usb_modeswitch_data/Config.in
  50. 4 2
      package/usbredir/Config.in

+ 4 - 3
package/acsccid/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_ACSCCID
 config BR2_PACKAGE_ACSCCID
 	bool "acsccid"
 	bool "acsccid"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # pcsc-lite, libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # pcsc-lite, libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_USE_MMU # pcsc-lite
 	depends on BR2_USE_MMU # pcsc-lite
 	depends on !BR2_STATIC_LIBS # pcsc-lite
 	depends on !BR2_STATIC_LIBS # pcsc-lite
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
@@ -14,7 +15,7 @@ config BR2_PACKAGE_ACSCCID
 
 
 	  http://acsccid.sourceforge.net/
 	  http://acsccid.sourceforge.net/
 
 
-comment "acsccid needs a toolchain w/ threads, dynamic library"
+comment "acsccid needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
-		BR2_STATIC_LIBS
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/apcupsd/Config.in

@@ -28,14 +28,16 @@ config BR2_PACKAGE_APCUPSD_MODBUS
 config BR2_PACKAGE_APCUPSD_MODBUS_USB
 config BR2_PACKAGE_APCUPSD_MODBUS_USB
 	bool "modbus usb"
 	bool "modbus usb"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_APCUPSD_MODBUS
 	select BR2_PACKAGE_APCUPSD_MODBUS
 	help
 	help
 	  Compile MODBUS/USB driver code
 	  Compile MODBUS/USB driver code
 
 
-comment "modbus usb support needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "modbus usb support needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 config BR2_PACKAGE_APCUPSD_NET
 config BR2_PACKAGE_APCUPSD_NET
 	bool "net"
 	bool "net"

+ 4 - 2
package/avrdude/Config.in

@@ -4,6 +4,7 @@ config BR2_PACKAGE_AVRDUDE
 	depends on BR2_USE_WCHAR # elfutils
 	depends on BR2_USE_WCHAR # elfutils
 	depends on !BR2_STATIC_LIBS # elfutils
 	depends on !BR2_STATIC_LIBS # elfutils
 	depends on BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_GLIBC # elfutils
 	depends on BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_GLIBC # elfutils
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_ELFUTILS
 	select BR2_PACKAGE_ELFUTILS
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
@@ -14,6 +15,7 @@ config BR2_PACKAGE_AVRDUDE
 
 
 	  https://github.com/kcuzner/avrdude
 	  https://github.com/kcuzner/avrdude
 
 
-comment "avrdude needs a uClibc or glibc toolchain w/ threads, wchar, dynamic library"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR || BR2_STATIC_LIBS \
+comment "avrdude needs a uClibc or glibc toolchain w/ threads, wchar, dynamic library, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR \
+		|| BR2_STATIC_LIBS || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 \
 		|| !(BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_GLIBC)
 		|| !(BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_GLIBC)

+ 5 - 2
package/cc-tool/Config.in

@@ -3,6 +3,7 @@ config BR2_PACKAGE_CC_TOOL
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_USE_WCHAR # boost-filesystem
 	depends on BR2_USE_WCHAR # boost-filesystem
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_BOOST
 	select BR2_PACKAGE_BOOST
 	select BR2_PACKAGE_BOOST_PROGRAM_OPTIONS
 	select BR2_PACKAGE_BOOST_PROGRAM_OPTIONS
@@ -16,5 +17,7 @@ config BR2_PACKAGE_CC_TOOL
 
 
 	  https://github.com/dashesy/cc-tool/
 	  https://github.com/dashesy/cc-tool/
 
 
-comment "cc-tool needs a toolchain w/ C++, threads, wchar"
-	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR
+comment "cc-tool needs a toolchain w/ C++, threads, wchar, gcc >= 4.9 "
+	depends on !BR2_INSTALL_LIBSTDCPP || \
+		!BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/ccid/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_CCID
 config BR2_PACKAGE_CCID
 	bool "ccid"
 	bool "ccid"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_USE_MMU # pcsc-lite
 	depends on BR2_USE_MMU # pcsc-lite
 	depends on !BR2_STATIC_LIBS # pcsc-lite
 	depends on !BR2_STATIC_LIBS # pcsc-lite
 	select BR2_PACKAGE_PCSC_LITE
 	select BR2_PACKAGE_PCSC_LITE
@@ -10,6 +11,7 @@ config BR2_PACKAGE_CCID
 
 
 	  https://ccid.apdu.fr/
 	  https://ccid.apdu.fr/
 
 
-comment "ccid needs a toolchain w/ threads, dynamic library"
+comment "ccid needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/dfu-util/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_DFU_UTIL
 config BR2_PACKAGE_DFU_UTIL
 	bool "dfu-util"
 	bool "dfu-util"
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Dfu-util is the host side implementation of the DFU 1.0
 	  Dfu-util is the host side implementation of the DFU 1.0
@@ -9,5 +10,6 @@ config BR2_PACKAGE_DFU_UTIL
 
 
 	  http://dfu-util.sourceforge.net/
 	  http://dfu-util.sourceforge.net/
 
 
-comment "dfu-util needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "dfu-util needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 0
package/dfu-util/Config.in.host

@@ -1,8 +1,12 @@
 config BR2_PACKAGE_HOST_DFU_UTIL
 config BR2_PACKAGE_HOST_DFU_UTIL
 	bool "host dfu-util"
 	bool "host dfu-util"
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  Dfu-util is the host side implementation of the DFU 1.0
 	  Dfu-util is the host side implementation of the DFU 1.0
 	  specification of the USB forum. DFU is intended to download
 	  specification of the USB forum. DFU is intended to download
 	  and upload firmware to devices connected over USB.
 	  and upload firmware to devices connected over USB.
 
 
 	  http://dfu-util.sourceforge.net/
 	  http://dfu-util.sourceforge.net/
+
+comment "host dfu-util needs a toolchain w/ host gcc >= 4.9"
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 4 - 2
package/dump1090/Config.in

@@ -1,11 +1,13 @@
 config BR2_PACKAGE_DUMP1090
 config BR2_PACKAGE_DUMP1090
 	bool "dump1090"
 	bool "dump1090"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # librtlsdr
 	depends on BR2_TOOLCHAIN_HAS_THREADS # librtlsdr
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # librtlsdr -> libusb
 	select BR2_PACKAGE_LIBRTLSDR
 	select BR2_PACKAGE_LIBRTLSDR
 	help
 	help
 	  Dump1090 is a simple Mode S decoder for RTLSDR devices
 	  Dump1090 is a simple Mode S decoder for RTLSDR devices
 
 
 	  https://github.com/MalcolmRobb/dump1090
 	  https://github.com/MalcolmRobb/dump1090
 
 
-comment "dump1090 needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "dump1090 needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 0
package/gr-osmosdr/Config.in

@@ -25,10 +25,14 @@ config BR2_PACKAGE_GR_OSMOSDR_IQFILE
 
 
 config BR2_PACKAGE_GR_OSMOSDR_RTLSDR
 config BR2_PACKAGE_GR_OSMOSDR_RTLSDR
 	bool "Osmocom RTLSDR support"
 	bool "Osmocom RTLSDR support"
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # librtlsdr -> libusb
 	select BR2_PACKAGE_LIBRTLSDR
 	select BR2_PACKAGE_LIBRTLSDR
 	help
 	help
 	  Enable Osmocom RTLSDR support
 	  Enable Osmocom RTLSDR support
 
 
+comment "Osmocom RTLSDR support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_GR_OSMOSDR_RTLSDR_TCP
 config BR2_PACKAGE_GR_OSMOSDR_RTLSDR_TCP
 	bool "RTLSDR TCP Client support"
 	bool "RTLSDR TCP Client support"
 	help
 	help

+ 4 - 2
package/hackrf/Config.in

@@ -2,6 +2,7 @@ config BR2_PACKAGE_HACKRF
 	bool "hackrf"
 	bool "hackrf"
 	depends on !BR2_STATIC_LIBS
 	depends on !BR2_STATIC_LIBS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_FFTW
 	select BR2_PACKAGE_FFTW
 	select BR2_PACKAGE_FFTW_SINGLE
 	select BR2_PACKAGE_FFTW_SINGLE
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
@@ -10,5 +11,6 @@ config BR2_PACKAGE_HACKRF
 
 
 	  https://github.com/mossmann/hackrf/tree/master/host
 	  https://github.com/mossmann/hackrf/tree/master/host
 
 
-comment "hackrf needs a toolchain w/ threads, dynamic library"
-	depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS
+comment "hackrf needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
+	depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 5 - 2
package/hidapi/Config.in

@@ -2,6 +2,7 @@ config BR2_PACKAGE_HIDAPI
 	bool "hidapi"
 	bool "hidapi"
 	depends on BR2_PACKAGE_HAS_UDEV
 	depends on BR2_PACKAGE_HAS_UDEV
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBGUDEV
 	select BR2_PACKAGE_LIBGUDEV
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
@@ -14,5 +15,7 @@ config BR2_PACKAGE_HIDAPI
 
 
 	  http://github.com/libusb/hidapi/
 	  http://github.com/libusb/hidapi/
 
 
-comment "hidapi needs udev /dev management and a toolchain w/ NPTL threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || !BR2_PACKAGE_HAS_UDEV
+comment "hidapi needs udev /dev management and a toolchain w/ NPTL, threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
+		!BR2_PACKAGE_HAS_UDEV || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 3 - 2
package/hplip/Config.in

@@ -3,6 +3,7 @@ config BR2_PACKAGE_HPLIP
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_PACKAGE_CUPS
 	depends on BR2_PACKAGE_CUPS
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on !BR2_STATIC_LIBS # libdl
 	depends on !BR2_STATIC_LIBS # libdl
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_JPEG
 	select BR2_PACKAGE_JPEG
@@ -17,7 +18,7 @@ config BR2_PACKAGE_HPLIP
 
 
 	  http://hplipopensource.com/
 	  http://hplipopensource.com/
 
 
-comment "hplip needs a toolchain w/ C++, threads, dynamic library"
+comment "hplip needs a toolchain w/ C++, threads, dynamic library, gcc >= 4.9"
 	depends on BR2_PACKAGE_CUPS
 	depends on BR2_PACKAGE_CUPS
 	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \
 	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \
-		BR2_STATIC_LIBS
+		BR2_STATIC_LIBS || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/imx-usb-loader/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_IMX_USB_LOADER
 config BR2_PACKAGE_IMX_USB_LOADER
 	bool "imx-usb-loader"
 	bool "imx-usb-loader"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  This package contains tools to download and execute code
 	  This package contains tools to download and execute code
@@ -9,5 +10,6 @@ config BR2_PACKAGE_IMX_USB_LOADER
 
 
 	  https://github.com/boundarydevices/imx_usb_loader
 	  https://github.com/boundarydevices/imx_usb_loader
 
 
-comment "imx-usb-loader needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "imx-usb-loader needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 5 - 0
package/imx-usb-loader/Config.in.host

@@ -1,9 +1,14 @@
 config BR2_PACKAGE_HOST_IMX_USB_LOADER
 config BR2_PACKAGE_HOST_IMX_USB_LOADER
 	bool "host imx-usb-loader"
 	bool "host imx-usb-loader"
 	depends on BR2_arm || BR2_aarch64
 	depends on BR2_arm || BR2_aarch64
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  This package contains tools to download and execute code
 	  This package contains tools to download and execute code
 	  on Freescale i.MX5x/6x/7x/8x and Vybrid SoCs through the
 	  on Freescale i.MX5x/6x/7x/8x and Vybrid SoCs through the
 	  Serial Download Protocol.
 	  Serial Download Protocol.
 
 
 	  https://github.com/boundarydevices/imx_usb_loader
 	  https://github.com/boundarydevices/imx_usb_loader
+
+comment "host imx-usb-loader needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm || BR2_aarch64
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 4 - 0
package/kodi/Config.in

@@ -258,11 +258,15 @@ config BR2_PACKAGE_KODI_LIBUSB
 	# https://github.com/xbmc/xbmc/blob/Jarvis/configure.ac#L1554
 	# https://github.com/xbmc/xbmc/blob/Jarvis/configure.ac#L1554
 	# "if libudev is available, we don't need libusb"
 	# "if libudev is available, we don't need libusb"
 	depends on !BR2_PACKAGE_HAS_UDEV
 	depends on !BR2_PACKAGE_HAS_UDEV
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
 	  Enable libusb support.
 	  Enable libusb support.
 
 
+comment "usb support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_KODI_LIBVA
 config BR2_PACKAGE_KODI_LIBVA
 	bool "va"
 	bool "va"
 	depends on \
 	depends on \

+ 4 - 2
package/libftdi/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBFTDI
 config BR2_PACKAGE_LIBFTDI
 	bool "libftdi"
 	bool "libftdi"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -23,5 +24,6 @@ comment "libftdi C++ bindings need a toolchain w/ wchar, C++"
 
 
 endif # BR2_PACKAGE_LIBFTDI
 endif # BR2_PACKAGE_LIBFTDI
 
 
-comment "libftdi needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libftdi needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libftdi1/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBFTDI1
 config BR2_PACKAGE_LIBFTDI1
 	bool "libftdi1"
 	bool "libftdi1"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Userspace access to FTDI USB interface chips (version 1.x)
 	  Userspace access to FTDI USB interface chips (version 1.x)
@@ -33,5 +34,6 @@ config BR2_PACKAGE_LIBFTDI1_FDTI_EEPROM
 
 
 endif # BR2_PACKAGE_LIBFTDI1
 endif # BR2_PACKAGE_LIBFTDI1
 
 
-comment "libftdi1 needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libftdi1 needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libgphoto2/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBGPHOTO2
 config BR2_PACKAGE_LIBGPHOTO2
 	bool "libgphoto2"
 	bool "libgphoto2"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBTOOL
 	select BR2_PACKAGE_LIBTOOL
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBXML2
 	select BR2_PACKAGE_LIBXML2
@@ -10,5 +11,6 @@ config BR2_PACKAGE_LIBGPHOTO2
 
 
 	  http://gphoto.org/proj/libgphoto2/
 	  http://gphoto.org/proj/libgphoto2/
 
 
-comment "libgphoto needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libgphoto needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libhid/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBHID
 config BR2_PACKAGE_LIBHID
 	bool "libhid"
 	bool "libhid"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -8,5 +9,6 @@ config BR2_PACKAGE_LIBHID
 
 
 	  https://directory.fsf.org/wiki/Libhid
 	  https://directory.fsf.org/wiki/Libhid
 
 
-comment "libhid needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libhid needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libiio/Config.in

@@ -33,13 +33,15 @@ config BR2_PACKAGE_LIBIIO_USB_BACKEND
 	bool "USB backend"
 	bool "USB backend"
 	default y
 	default y
 	depends on BR2_TOOLCHAIN_HAS_THREADS # from libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # from libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBIIO_XML_BACKEND
 	select BR2_PACKAGE_LIBIIO_XML_BACKEND
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable the USB backend of the library.
 	  Enable the USB backend of the library.
 
 
-comment "The USB backend needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "The USB backend needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 config BR2_PACKAGE_LIBIIO_SERIAL_BACKEND
 config BR2_PACKAGE_LIBIIO_SERIAL_BACKEND
 	bool "Serial backend"
 	bool "Serial backend"

+ 4 - 2
package/libiqrf/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBIQRF
 config BR2_PACKAGE_LIBIQRF
 	bool "libiqrf"
 	bool "libiqrf"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  This library implement specific protocol
 	  This library implement specific protocol
@@ -10,5 +11,6 @@ config BR2_PACKAGE_LIBIQRF
 
 
 	  https://github.com/nandra/libiqrf
 	  https://github.com/nandra/libiqrf
 
 
-comment "libiqrf needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libiqrf needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libnfc/Config.in

@@ -24,13 +24,15 @@ comment "acr122_pcsc driver needs a toolchain w/ threads, dynamic library"
 config BR2_PACKAGE_LIBNFC_ACR122_USB
 config BR2_PACKAGE_LIBNFC_ACR122_USB
 	bool "acr122_usb driver"
 	bool "acr122_usb driver"
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
 	  support for acr122_usb driver
 	  support for acr122_usb driver
 
 
-comment "acr122_usb driver needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "acr122_usb driver needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 config BR2_PACKAGE_LIBNFC_ACR122S
 config BR2_PACKAGE_LIBNFC_ACR122S
 	bool "acr122s driver"
 	bool "acr122s driver"

+ 4 - 3
package/libphidget/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBPHIDGET
 config BR2_PACKAGE_LIBPHIDGET
 	bool "libphidget"
 	bool "libphidget"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on !BR2_STATIC_LIBS
 	depends on !BR2_STATIC_LIBS
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
@@ -23,6 +24,6 @@ config BR2_PACKAGE_LIBPHIDGET
 
 
 	  http://phidgets.com/
 	  http://phidgets.com/
 
 
-comment "libphidget needs a toolchain w/ threads, dynamic library"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
-	depends on BR2_STATIC_LIBS
+comment "libphidget needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/librtlsdr/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBRTLSDR
 config BR2_PACKAGE_LIBRTLSDR
 	bool "librtlsdr"
 	bool "librtlsdr"
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Library and command line programs for accessing
 	  Library and command line programs for accessing
@@ -28,5 +29,6 @@ config BR2_PACKAGE_LIBRTLSDR_ZEROCOPY
 
 
 endif
 endif
 
 
-comment "librtlsdr needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "librtlsdr needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/libusb/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LIBUSB
 config BR2_PACKAGE_LIBUSB
 	bool "libusb"
 	bool "libusb"
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # _Thread_local
 	help
 	help
 	  Userspace library for accessing USB devices
 	  Userspace library for accessing USB devices
 
 
@@ -13,5 +14,6 @@ config BR2_PACKAGE_LIBUSB_EXAMPLES
 
 
 endif
 endif
 
 
-comment "libusb needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "libusb needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 5 - 0
package/mfgtools/Config.in.host

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_HOST_MFGTOOLS
 config BR2_PACKAGE_HOST_MFGTOOLS
 	bool "host mfgtools"
 	bool "host mfgtools"
 	depends on BR2_arm
 	depends on BR2_arm
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  This package contains the Freescale manufacturing tool.
 	  This package contains the Freescale manufacturing tool.
 	  It is designed to program firmware to i.MX boards during
 	  It is designed to program firmware to i.MX boards during
@@ -8,3 +9,7 @@ config BR2_PACKAGE_HOST_MFGTOOLS
 	  Freescale UTP protocol.
 	  Freescale UTP protocol.
 
 
 	  https://github.com/codeauroraforum/mfgtools
 	  https://github.com/codeauroraforum/mfgtools
+
+comment "host mfgtools needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 5 - 0
package/mxsldr/Config.in.host

@@ -1,9 +1,14 @@
 config BR2_PACKAGE_HOST_MXSLDR
 config BR2_PACKAGE_HOST_MXSLDR
 	bool "host mxsldr"
 	bool "host mxsldr"
 	depends on BR2_arm || BR2_armeb
 	depends on BR2_arm || BR2_armeb
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  This package contains tools to download and execute code on
 	  This package contains tools to download and execute code on
 	  Freescale i.MX23 and i.MX28 SoC's through the Serial
 	  Freescale i.MX23 and i.MX28 SoC's through the Serial
 	  Download Protocol.
 	  Download Protocol.
 
 
 	  https://gitlab.denx.de/denx/mxsldr
 	  https://gitlab.denx.de/denx/mxsldr
+
+comment "host mxsldr needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm || BR2_armeb
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 4 - 2
package/omxplayer/Config.in

@@ -5,6 +5,7 @@ config BR2_PACKAGE_OMXPLAYER
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS # ffmpeg
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS # ffmpeg
 	depends on BR2_INSTALL_LIBSTDCPP # boost
 	depends on BR2_INSTALL_LIBSTDCPP # boost
 	depends on BR2_TOOLCHAIN_HAS_THREADS # alsa-lib, boost, libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # alsa-lib, boost, libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_USE_WCHAR # boost
 	depends on BR2_USE_WCHAR # boost
 	depends on BR2_PACKAGE_RPI_USERLAND
 	depends on BR2_PACKAGE_RPI_USERLAND
 	select BR2_PACKAGE_ALSA_LIB
 	select BR2_PACKAGE_ALSA_LIB
@@ -25,10 +26,11 @@ config BR2_PACKAGE_OMXPLAYER
 
 
 	  https://github.com/popcornmix/omxplayer
 	  https://github.com/popcornmix/omxplayer
 
 
-comment "omxplayer needs rpi-userland and a toolchain w/ C++, threads, wchar, dynamic library"
+comment "omxplayer needs rpi-userland and a toolchain w/ C++, threads, wchar, dynamic library, gcc >= 4.9"
 	depends on BR2_arm
 	depends on BR2_arm
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on !BR2_PACKAGE_RPI_USERLAND
 	depends on !BR2_PACKAGE_RPI_USERLAND
 	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \
 	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \
-		|| !BR2_USE_WCHAR || BR2_STATIC_LIBS
+		|| !BR2_USE_WCHAR || BR2_STATIC_LIBS \
+		|| !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 5 - 2
package/openfpgaloader/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_OPENFPGALOADER
 config BR2_PACKAGE_OPENFPGALOADER
 	bool "openfpgaloader"
 	bool "openfpgaloader"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi1
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi1
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libftdi1 -> libusb
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_INSTALL_LIBSTDCPP
 	select BR2_PACKAGE_LIBFTDI1
 	select BR2_PACKAGE_LIBFTDI1
 	help
 	help
@@ -8,5 +9,7 @@ config BR2_PACKAGE_OPENFPGALOADER
 
 
 	  https://github.com/trabucayre/openFPGALoader/
 	  https://github.com/trabucayre/openFPGALoader/
 
 
-comment "openfpgaloader needs a toolchain w/ threads, C++"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_INSTALL_LIBSTDCPP
+comment "openfpgaloader needs a toolchain w/ threads, C++, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_INSTALL_LIBSTDCPP || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 5 - 2
package/openjdk/Config.in

@@ -20,6 +20,7 @@ config BR2_PACKAGE_OPENJDK
 	depends on !BR2_STATIC_LIBS # glibc
 	depends on !BR2_STATIC_LIBS # glibc
 	depends on BR2_INSTALL_LIBSTDCPP # cups
 	depends on BR2_INSTALL_LIBSTDCPP # cups
 	depends on BR2_TOOLCHAIN_HAS_THREADS # alsa-lib, cups, libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # alsa-lib, cups, libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_TOOLCHAIN_USES_GLIBC
 	depends on BR2_TOOLCHAIN_USES_GLIBC
 	depends on BR2_USE_MMU # cups
 	depends on BR2_USE_MMU # cups
 	depends on BR2_PACKAGE_XORG7
 	depends on BR2_PACKAGE_XORG7
@@ -151,12 +152,14 @@ comment "openjdk needs X.Org"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
 	depends on !BR2_PACKAGE_XORG7
 	depends on !BR2_PACKAGE_XORG7
 
 
-comment "openjdk needs glibc, and a toolchain w/ wchar, dynamic library, threads, C++"
+comment "openjdk needs glibc, and a toolchain w/ wchar, dynamic library, threads, C++, gcc >= 4.9"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
 	depends on BR2_PACKAGE_OPENJDK_ARCH_SUPPORTS
 	depends on BR2_PACKAGE_OPENJDK_ARCH_SUPPORTS
 	depends on BR2_PACKAGE_HOST_OPENJDK_BIN_ARCH_SUPPORTS
 	depends on BR2_PACKAGE_HOST_OPENJDK_BIN_ARCH_SUPPORTS
 	depends on BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || \
 	depends on BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || \
-		!BR2_TOOLCHAIN_HAS_THREADS || !BR2_TOOLCHAIN_USES_GLIBC
+		!BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_USES_GLIBC || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 comment "openjdk does not support soft float configurations"
 comment "openjdk does not support soft float configurations"
 	depends on BR2_PACKAGE_OPENJDK_ARCH_SUPPORTS
 	depends on BR2_PACKAGE_OPENJDK_ARCH_SUPPORTS

+ 23 - 5
package/openocd/Config.in

@@ -13,6 +13,7 @@ comment "Adapters"
 config BR2_PACKAGE_OPENOCD_CMSIS_DAP
 config BR2_PACKAGE_OPENOCD_CMSIS_DAP
 	bool "CMSIS-DAP compliant debuggers"
 	bool "CMSIS-DAP compliant debuggers"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
@@ -24,6 +25,7 @@ config BR2_PACKAGE_OPENOCD_CMSIS_DAP
 config BR2_PACKAGE_OPENOCD_FTDI
 config BR2_PACKAGE_OPENOCD_FTDI
 	bool "MPSSE mode of FTDI based devices"
 	bool "MPSSE mode of FTDI based devices"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the MPSSE mode of FTDI
 	  Enable building support for the MPSSE mode of FTDI
@@ -32,6 +34,7 @@ config BR2_PACKAGE_OPENOCD_FTDI
 config BR2_PACKAGE_OPENOCD_STLINK
 config BR2_PACKAGE_OPENOCD_STLINK
 	bool "ST-Link JTAG Programmer"
 	bool "ST-Link JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the ST-Link JTAG
 	  Enable building support for the ST-Link JTAG
@@ -40,6 +43,7 @@ config BR2_PACKAGE_OPENOCD_STLINK
 config BR2_PACKAGE_OPENOCD_TI_ICDI
 config BR2_PACKAGE_OPENOCD_TI_ICDI
 	bool "TI ICDI JTAG Programmer"
 	bool "TI ICDI JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the TI ICDI JTAG
 	  Enable building support for the TI ICDI JTAG
@@ -48,6 +52,7 @@ config BR2_PACKAGE_OPENOCD_TI_ICDI
 config BR2_PACKAGE_OPENOCD_ULINK
 config BR2_PACKAGE_OPENOCD_ULINK
 	bool "Keil ULINK JTAG Programmer"
 	bool "Keil ULINK JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the Keil ULINK JTAG
 	  Enable building support for the Keil ULINK JTAG
@@ -56,6 +61,7 @@ config BR2_PACKAGE_OPENOCD_ULINK
 config BR2_PACKAGE_OPENOCD_UBLASTER2
 config BR2_PACKAGE_OPENOCD_UBLASTER2
 	bool "Altera USB-Blaster II Compatible"
 	bool "Altera USB-Blaster II Compatible"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the Altera USB-Blaster
 	  Enable building support for the Altera USB-Blaster
@@ -64,6 +70,7 @@ config BR2_PACKAGE_OPENOCD_UBLASTER2
 config BR2_PACKAGE_OPENOCD_JLINK
 config BR2_PACKAGE_OPENOCD_JLINK
 	bool "Segger J-Link JTAG Programmer"
 	bool "Segger J-Link JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Segger J-Link JTAG Programmer and clone such as Atmel
 	  Segger J-Link JTAG Programmer and clone such as Atmel
@@ -72,6 +79,7 @@ config BR2_PACKAGE_OPENOCD_JLINK
 config BR2_PACKAGE_OPENOCD_OSDBM
 config BR2_PACKAGE_OPENOCD_OSDBM
 	bool "OSDBM JTAG (only) Programmer"
 	bool "OSDBM JTAG (only) Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the OSBDM (JTAG only)
 	  Enable building support for the OSBDM (JTAG only)
@@ -80,6 +88,7 @@ config BR2_PACKAGE_OPENOCD_OSDBM
 config BR2_PACKAGE_OPENOCD_OPENDOUS
 config BR2_PACKAGE_OPENOCD_OPENDOUS
 	bool "eStick/opendous JTAG Programmer"
 	bool "eStick/opendous JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the eStick/opendous JTAG
 	  Enable building support for the eStick/opendous JTAG
@@ -89,6 +98,7 @@ config BR2_PACKAGE_OPENOCD_AICE
 	bool "Andes JTAG Programmer"
 	bool "Andes JTAG Programmer"
 	depends on BR2_USE_MMU # use fork()
 	depends on BR2_USE_MMU # use fork()
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Enable building support for the Andes JTAG
 	  Enable building support for the Andes JTAG
@@ -97,6 +107,7 @@ config BR2_PACKAGE_OPENOCD_AICE
 config BR2_PACKAGE_OPENOCD_VSLLINK
 config BR2_PACKAGE_OPENOCD_VSLLINK
 	bool "Versaloon-Link JTAG Programmer"
 	bool "Versaloon-Link JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb-compat -> libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -106,6 +117,7 @@ config BR2_PACKAGE_OPENOCD_VSLLINK
 config BR2_PACKAGE_OPENOCD_USBPROG
 config BR2_PACKAGE_OPENOCD_USBPROG
 	bool "USBProg JTAG Programmer"
 	bool "USBProg JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb-compat -> libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -115,6 +127,7 @@ config BR2_PACKAGE_OPENOCD_USBPROG
 config BR2_PACKAGE_OPENOCD_RLINK
 config BR2_PACKAGE_OPENOCD_RLINK
 	bool "Raisonance RLink JTAG Programmer"
 	bool "Raisonance RLink JTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb-compat -> libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -124,6 +137,7 @@ config BR2_PACKAGE_OPENOCD_RLINK
 config BR2_PACKAGE_OPENOCD_ARMEW
 config BR2_PACKAGE_OPENOCD_ARMEW
 	bool "Olimex ARM-JTAG-EW Programmer"
 	bool "Olimex ARM-JTAG-EW Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb-compat -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb-compat -> libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -143,6 +157,7 @@ config BR2_PACKAGE_OPENOCD_VPI
 config BR2_PACKAGE_OPENOCD_UBLASTER
 config BR2_PACKAGE_OPENOCD_UBLASTER
 	bool "Altera USB-Blaster"
 	bool "Altera USB-Blaster"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libftdi -> libusb
 	select BR2_PACKAGE_LIBFTDI1
 	select BR2_PACKAGE_LIBFTDI1
 	help
 	help
 	  Enable building support for the Altera USB-Blaster
 	  Enable building support for the Altera USB-Blaster
@@ -183,6 +198,7 @@ config BR2_PACKAGE_OPENOCD_GW16012
 config BR2_PACKAGE_OPENOCD_PRESTO
 config BR2_PACKAGE_OPENOCD_PRESTO
 	bool "ASIX Presto Programmer"
 	bool "ASIX Presto Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libftdi -> libusb
 	select BR2_PACKAGE_LIBFTDI1
 	select BR2_PACKAGE_LIBFTDI1
 	help
 	help
 	  Enable building support for ASIX Presto Programmer
 	  Enable building support for ASIX Presto Programmer
@@ -191,6 +207,7 @@ config BR2_PACKAGE_OPENOCD_PRESTO
 config BR2_PACKAGE_OPENOCD_OPENJTAG
 config BR2_PACKAGE_OPENOCD_OPENJTAG
 	bool "OpenJTAG Programmer"
 	bool "OpenJTAG Programmer"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libftdi -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libftdi -> libusb
 	select BR2_PACKAGE_LIBFTDI1
 	select BR2_PACKAGE_LIBFTDI1
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT # needs usb.h
 	select BR2_PACKAGE_LIBUSB_COMPAT # needs usb.h
@@ -209,10 +226,11 @@ config BR2_PACKAGE_OPENOCD_SYSFS
 	  Enable building support for programming driven via
 	  Enable building support for programming driven via
 	  sysfs gpios.
 	  sysfs gpios.
 
 
-# Many adapters need libusb or libusb-compat, which require threads,
-# but we don't want to duplicate this comment for all adapters that
-# select libusb or libusb-compat.
-comment "many openocd adapters needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+# Many adapters need libusb or libusb-compat, which require threads and
+# gcc >= 4.9 but we don't want to duplicate this comment for all
+# adapters that select libusb or libusb-compat.
+comment "many openocd adapters needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 endif # BR2_PACKAGE_OPENOCD
 endif # BR2_PACKAGE_OPENOCD

+ 4 - 0
package/openocd/Config.in.host

@@ -1,6 +1,10 @@
 config BR2_PACKAGE_HOST_OPENOCD
 config BR2_PACKAGE_HOST_OPENOCD
 	bool "host openocd"
 	bool "host openocd"
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  OpenOCD - Open On-Chip Debugger
 	  OpenOCD - Open On-Chip Debugger
 
 
 	  http://openocd.org/
 	  http://openocd.org/
+
+comment "host openocd needs a toolchain w/ host gcc >= 4.9"
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 4 - 0
package/pcsc-lite/Config.in

@@ -13,10 +13,14 @@ if BR2_PACKAGE_PCSC_LITE
 config BR2_PACKAGE_PCSC_LITE_FORCE_LIBUSB
 config BR2_PACKAGE_PCSC_LITE_FORCE_LIBUSB
 	bool "use libusb"
 	bool "use libusb"
 	depends on !BR2_PACKAGE_HAS_UDEV
 	depends on !BR2_PACKAGE_HAS_UDEV
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Select Y if you want to support usb smart card readers.
 	  Select Y if you want to support usb smart card readers.
 
 
+comment "libusb support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_PCSC_LITE_DEBUGATR
 config BR2_PACKAGE_PCSC_LITE_DEBUGATR
 	bool "enable ATR debug messages"
 	bool "enable ATR debug messages"
 	help
 	help

+ 4 - 3
package/phidgetwebservice/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_PHIDGETWEBSERVICE
 config BR2_PACKAGE_PHIDGETWEBSERVICE
 	bool "phidgetwebservice"
 	bool "phidgetwebservice"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb, libphidget
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb, libphidget
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libphidget -> libusb
 	depends on !BR2_STATIC_LIBS # libphidget
 	depends on !BR2_STATIC_LIBS # libphidget
 	select BR2_PACKAGE_LIBPHIDGET
 	select BR2_PACKAGE_LIBPHIDGET
 	help
 	help
@@ -17,6 +18,6 @@ config BR2_PACKAGE_PHIDGETWEBSERVICE
 
 
 	  http://phidgets.com/
 	  http://phidgets.com/
 
 
-comment "phidgetwebservice needs a toolchain w/ threads, dynamic library"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
-	depends on BR2_STATIC_LIBS
+comment "phidgetwebservice needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/python-libusb1/Config.in

@@ -1,11 +1,13 @@
 config BR2_PACKAGE_PYTHON_LIBUSB1
 config BR2_PACKAGE_PYTHON_LIBUSB1
 	bool "python-libusb1"
 	bool "python-libusb1"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Pure-python wrapper for libusb-1.0.
 	  Pure-python wrapper for libusb-1.0.
 
 
 	  http://github.com/vpelletier/python-libusb1
 	  http://github.com/vpelletier/python-libusb1
 
 
-comment "python-libusb1 needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "python-libusb1 needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/python-nfc/Config.in

@@ -2,6 +2,7 @@ config BR2_PACKAGE_PYTHON_NFC
 	bool "python-nfc"
 	bool "python-nfc"
 	depends on BR2_PACKAGE_PYTHON
 	depends on BR2_PACKAGE_PYTHON
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	select BR2_PACKAGE_LIBUSB_COMPAT
 	help
 	help
@@ -9,6 +10,7 @@ config BR2_PACKAGE_PYTHON_NFC
 
 
 	  https://launchpad.net/nfcpy
 	  https://launchpad.net/nfcpy
 
 
-comment "python-nfc needs a toolchain w/ threads"
+comment "python-nfc needs a toolchain w/ threads, gcc >= 4.9"
 	depends on BR2_PACKAGE_PYTHON
 	depends on BR2_PACKAGE_PYTHON
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/python-pylibftdi/Config.in

@@ -1,11 +1,13 @@
 config BR2_PACKAGE_PYTHON_PYLIBFTDI
 config BR2_PACKAGE_PYTHON_PYLIBFTDI
 	bool "python-pylibftdi"
 	bool "python-pylibftdi"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libftdi -> libusb
 	select BR2_PACKAGE_LIBFTDI
 	select BR2_PACKAGE_LIBFTDI
 	help
 	help
 	  This package contains the python language binding libftdi.
 	  This package contains the python language binding libftdi.
 
 
 	  https://pypi.python.org/pypi/pylibftdi
 	  https://pypi.python.org/pypi/pylibftdi
 
 
-comment "python-pylibftdi needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "python-pylibftdi needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/python-pyusb/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_PYTHON_PYUSB
 config BR2_PACKAGE_PYTHON_PYUSB
 	bool "python-pyusb"
 	bool "python-pyusb"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  The PyUSB module provides easy access to the Universal
 	  The PyUSB module provides easy access to the Universal
@@ -8,5 +9,6 @@ config BR2_PACKAGE_PYTHON_PYUSB
 
 
 	  http://sourceforge.net/apps/trac/pyusb/
 	  http://sourceforge.net/apps/trac/pyusb/
 
 
-comment "python-pyusb needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "python-pyusb needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 0
package/qemu/Config.in.host

@@ -88,7 +88,11 @@ config BR2_PACKAGE_HOST_QEMU_VIRTFS
 
 
 config BR2_PACKAGE_HOST_QEMU_USB
 config BR2_PACKAGE_HOST_QEMU_USB
 	bool "USB passthrough support"
 	bool "USB passthrough support"
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  Enables USB passthrough support from guest to host.
 	  Enables USB passthrough support from guest to host.
 
 
+comment "USB passthrough support needs a toolchain w/ host gcc >= 4.9"
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9
+
 endif
 endif

+ 5 - 0
package/raspberrypi-usbboot/Config.in.host

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_HOST_RASPBERRYPI_USBBOOT
 config BR2_PACKAGE_HOST_RASPBERRYPI_USBBOOT
 	bool "host raspberrypi-usbboot"
 	bool "host raspberrypi-usbboot"
 	depends on BR2_arm
 	depends on BR2_arm
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  This package builds and install the "rpiboot" tool for the
 	  This package builds and install the "rpiboot" tool for the
 	  host machine. This tool allows to boot the Broadcom BCM
 	  host machine. This tool allows to boot the Broadcom BCM
@@ -10,3 +11,7 @@ config BR2_PACKAGE_HOST_RASPBERRYPI_USBBOOT
 	  built into the Compute module).
 	  built into the Compute module).
 
 
 	  https://github.com/raspberrypi/usbboot
 	  https://github.com/raspberrypi/usbboot
+
+comment "host raspberrypi-usbboot needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 4 - 2
package/sispmctl/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_SISPMCTL
 config BR2_PACKAGE_SISPMCTL
 	bool "sispmctl"
 	bool "sispmctl"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_USE_WCHAR
 	depends on BR2_USE_WCHAR
 	depends on BR2_USE_MMU # fork()
 	depends on BR2_USE_MMU # fork()
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
@@ -13,6 +14,7 @@ config BR2_PACKAGE_SISPMCTL
 
 
 	  http://sispmctl.sourceforge.net/
 	  http://sispmctl.sourceforge.net/
 
 
-comment "sispmctl needs a toolchain w/ threads, wchar"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR
+comment "sispmctl needs a toolchain w/ threads, wchar, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU

+ 4 - 2
package/sunxi-tools/Config.in

@@ -24,14 +24,16 @@ config BR2_PACKAGE_SUNXI_TOOLS_BOOTINFO
 config BR2_PACKAGE_SUNXI_TOOLS_FEL
 config BR2_PACKAGE_SUNXI_TOOLS_FEL
 	bool "sunxi-fel"
 	bool "sunxi-fel"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  The sunxi-fel command can interact with a sunxi device in
 	  The sunxi-fel command can interact with a sunxi device in
 	  fel mode. This allows do download code to memory and execute
 	  fel mode. This allows do download code to memory and execute
 	  it.
 	  it.
 
 
-comment "sunxi-fel needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "sunxi-fel needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 config BR2_PACKAGE_SUNXI_TOOLS_NAND_PART
 config BR2_PACKAGE_SUNXI_TOOLS_NAND_PART
 	bool "sunxi-nand-part"
 	bool "sunxi-nand-part"

+ 5 - 0
package/sunxi-tools/Config.in.host

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_HOST_SUNXI_TOOLS
 config BR2_PACKAGE_HOST_SUNXI_TOOLS
 	bool "host sunxi-tools"
 	bool "host sunxi-tools"
 	depends on BR2_arm
 	depends on BR2_arm
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  Tools for Allwinner A10 (aka sun4i) and A13 (aka sun5i)
 	  Tools for Allwinner A10 (aka sun4i) and A13 (aka sun5i)
 	  based devices. This includes fex2bin which can be used to
 	  based devices. This includes fex2bin which can be used to
@@ -10,3 +11,7 @@ config BR2_PACKAGE_HOST_SUNXI_TOOLS
 	  mainline Linux kernel version.
 	  mainline Linux kernel version.
 
 
 	  http://linux-sunxi.org/Sunxi-tools
 	  http://linux-sunxi.org/Sunxi-tools
+
+comment "host sunxi-tools needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 5 - 0
package/tegrarcm/Config.in.host

@@ -1,8 +1,13 @@
 config BR2_PACKAGE_HOST_TEGRARCM
 config BR2_PACKAGE_HOST_TEGRARCM
 	bool "host tegrarcm"
 	bool "host tegrarcm"
 	depends on BR2_arm || BR2_armeb
 	depends on BR2_arm || BR2_armeb
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-libusb
 	help
 	help
 	  This program is used to send code to a Tegra device in
 	  This program is used to send code to a Tegra device in
 	  recovery mode.
 	  recovery mode.
 
 
 	  https://github.com/NVIDIA/tegrarcm
 	  https://github.com/NVIDIA/tegrarcm
+
+comment "host tegrarcm needs a toolchain w/ host gcc >= 4.9"
+	depends on BR2_arm || BR2_armeb
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9

+ 12 - 0
package/uhd/Config.in

@@ -33,16 +33,24 @@ if BR2_PACKAGE_UHD
 
 
 config BR2_PACKAGE_UHD_B100
 config BR2_PACKAGE_UHD_B100
 	bool "b100 support"
 	bool "b100 support"
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_UHD_USB
 	select BR2_PACKAGE_UHD_USB
 	help
 	help
 	  enable B100 support
 	  enable B100 support
 
 
+comment "B100 support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_UHD_B200
 config BR2_PACKAGE_UHD_B200
 	bool "b200 support"
 	bool "b200 support"
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_UHD_USB
 	select BR2_PACKAGE_UHD_USB
 	help
 	help
 	  enable B200 support
 	  enable B200 support
 
 
+comment "B200 support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_UHD_E300
 config BR2_PACKAGE_UHD_E300
 	bool "E300 support"
 	bool "E300 support"
 	select BR2_PACKAGE_UHD_MPMD
 	select BR2_PACKAGE_UHD_MPMD
@@ -72,8 +80,12 @@ config BR2_PACKAGE_UHD_RFNOC
 
 
 config BR2_PACKAGE_UHD_USB
 config BR2_PACKAGE_UHD_USB
 	bool "USB support"
 	bool "USB support"
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  enable UHD USB support
 	  enable UHD USB support
 
 
+comment "USB support needs a toolchain w/ gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 endif
 endif

+ 4 - 2
package/uhubctl/Config.in

@@ -1,11 +1,13 @@
 config BR2_PACKAGE_UHUBCTL
 config BR2_PACKAGE_UHUBCTL
 	bool "uhubctl"
 	bool "uhubctl"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  Control USB power per-port on smart USB hubs.
 	  Control USB power per-port on smart USB hubs.
 
 
 	  https://github.com/mvp/uhubctl
 	  https://github.com/mvp/uhubctl
 
 
-comment "uhubctl needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "uhubctl needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/upower/Config.in

@@ -2,6 +2,7 @@ config BR2_PACKAGE_UPOWER
 	bool "upower"
 	bool "upower"
 	depends on BR2_PACKAGE_HAS_UDEV
 	depends on BR2_PACKAGE_HAS_UDEV
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libgudev, libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libgudev, libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_USE_MMU # libgudev
 	depends on BR2_USE_MMU # libgudev
 	depends on BR2_USE_WCHAR # libgudev
 	depends on BR2_USE_WCHAR # libgudev
 	select BR2_PACKAGE_LIBGUDEV
 	select BR2_PACKAGE_LIBGUDEV
@@ -22,6 +23,7 @@ comment "upower needs udev /dev management"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
 	depends on !BR2_PACKAGE_HAS_UDEV
 	depends on !BR2_PACKAGE_HAS_UDEV
 
 
-comment "upower needs a toolchain w/ threads, wchar"
+comment "upower needs a toolchain w/ threads, wchar, gcc >= 4.9"
 	depends on BR2_USE_MMU
 	depends on BR2_USE_MMU
-	depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
+	depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/usb_modeswitch/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_USB_MODESWITCH
 config BR2_PACKAGE_USB_MODESWITCH
 	bool "usb_modeswitch"
 	bool "usb_modeswitch"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_JIMTCL if !BR2_PACKAGE_TCL || BR2_PACKAGE_TCL_SHLIB_ONLY
 	select BR2_PACKAGE_JIMTCL if !BR2_PACKAGE_TCL || BR2_PACKAGE_TCL_SHLIB_ONLY
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
@@ -20,5 +21,6 @@ config BR2_PACKAGE_USB_MODESWITCH
 
 
 	  http://www.draisberghof.de/usb_modeswitch/
 	  http://www.draisberghof.de/usb_modeswitch/
 
 
-comment "usb_modeswitch needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "usb_modeswitch needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/usb_modeswitch_data/Config.in

@@ -1,6 +1,7 @@
 config BR2_PACKAGE_USB_MODESWITCH_DATA
 config BR2_PACKAGE_USB_MODESWITCH_DATA
 	bool "usb_modeswitch_data"
 	bool "usb_modeswitch_data"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # usb_modeswitch -> libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # usb_modeswitch -> libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # usb_modeswitch -> libusb
 	select BR2_PACKAGE_USB_MODESWITCH
 	select BR2_PACKAGE_USB_MODESWITCH
 	help
 	help
 	  USB mode switch data
 	  USB mode switch data
@@ -9,5 +10,6 @@ config BR2_PACKAGE_USB_MODESWITCH_DATA
 
 
 	  http://www.draisberghof.de/usb_modeswitch/
 	  http://www.draisberghof.de/usb_modeswitch/
 
 
-comment "usb_modeswitch_data needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "usb_modeswitch_data needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

+ 4 - 2
package/usbredir/Config.in

@@ -1,9 +1,11 @@
-comment "usbredir needs a toolchain w/ threads"
-	depends on !BR2_TOOLCHAIN_HAS_THREADS
+comment "usbredir needs a toolchain w/ threads, gcc >= 4.9"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 
 
 config BR2_PACKAGE_USBREDIR
 config BR2_PACKAGE_USBREDIR
 	bool "usbredir"
 	bool "usbredir"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBUSB
 	help
 	help
 	  usbredir is the name of a network protocol for sending usb
 	  usbredir is the name of a network protocol for sending usb