0001-fix-nopthread.patch 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. Fix pthread detection
  2. configure.in always calls AC_CHECK_COMP_OPT(pthread) which succeeds with the
  3. toolchain used although it does not contain thread support:
  4. checking for mutex_lock in -lthread ... no
  5. checking for pthread_mutex_lock in -lpthread... no
  6. checking for pthread_mutex_lock in -lc... no
  7. checking if compiler accepts -pthread... yes
  8. checking for pthread_mutex_lock in -lc... no
  9. checking for pthread_mutex_lock in -lpthread... no
  10. This positive configure check leads to
  11. CFLAGS="$CFLAGS -pthread"
  12. in ./configure, line 15757 which causes a compilation bug
  13. /home/br/br4/output/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/4.8.3/../../../../arm-buildroot-linux-uclibcgnueab
  14. using this defconfig
  15. http://autobuild.buildroot.net/results/e86/e86e97ff7887f1bdc6bf913498392ff50f56ea88/defconfig
  16. This patch disables the freebsd-only code path. Patching configure directly
  17. prevents the need for autoreconf.
  18. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  19. diff -uNr unixODBC-2.3.2.org/configure unixODBC-2.3.2/configure
  20. --- unixODBC-2.3.2.org/configure 2013-10-08 10:56:03.000000000 +0200
  21. +++ unixODBC-2.3.2/configure 2015-03-13 21:19:59.210429211 +0100
  22. @@ -15746,7 +15746,7 @@
  23. fi
  24. - if test "x$gotthread" = "xno"; then
  25. + if test "x$gotthread" = "xnot_needed_for_buildroot"; then
  26. if test "x$ac_cv_c_compiler_gnu" = "xyes"; then
  27. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -pthread" >&5
  28. $as_echo_n "checking if compiler accepts -pthread... " >&6; }