feather/contrib/depends/patches/libusb/fix-c11-check.patch
tobtoht 3b9412fece
Some checks are pending
ci/gh-actions/build / build-ubuntu-without-scanner (push) Waiting to run
ci/gh-actions/guix / cache-sources (push) Waiting to run
ci/gh-actions/guix / x86_64-w64-mingw32 (push) Blocked by required conditions
ci/gh-actions/guix / bundle-logs (push) Blocked by required conditions
ci/gh-actions/guix / x86_64-linux-gnu.no-tor-bundle (push) Blocked by required conditions
ci/gh-actions/guix / x86_64-linux-gnu.pack (push) Blocked by required conditions
ci/gh-actions/guix / x86_64-linux-gnu (push) Blocked by required conditions
ci/gh-actions/guix / x86_64-w64-mingw32.installer (push) Blocked by required conditions
ci/gh-actions/guix / aarch64-linux-gnu (push) Blocked by required conditions
ci/gh-actions/guix / arm-linux-gnueabihf (push) Blocked by required conditions
ci/gh-actions/guix / arm64-apple-darwin (push) Blocked by required conditions
ci/gh-actions/guix / i686-linux-gnu (push) Blocked by required conditions
ci/gh-actions/guix / riscv64-linux-gnu (push) Blocked by required conditions
ci/gh-actions/guix / x86_64-apple-darwin (push) Blocked by required conditions
guix: use llvm17 toolchain for macos
2024-11-02 18:55:52 +01:00

22 lines
990 B
Diff

diff --git a/configure.ac b/configure.ac
index 6dc7c698..eebe10a1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -46,7 +46,7 @@ dnl note that we don't just check if the compiler accepts '-std=x11'
dnl but also that it supports the _Thread_local keyword because some compilers
dnl (e.g. gcc 4.8) accept the command line option but do not implement TLS
saved_CFLAGS="${CFLAGS}"
-CFLAGS="-std=gnu11"
+CFLAGS="${saved_CFLAGS} -std=gnu11"
AC_MSG_CHECKING([if $CC supports -std=gnu11])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([_Thread_local int x;], [x = 42;])],
[AC_MSG_RESULT([yes])
@@ -55,7 +55,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([_Thread_local int x;], [x = 42;])],
c_dialect=])
if test "x$c_dialect" != xgnu; then
dnl fallback check for -std=c11 compiler support (required)
- CFLAGS="-std=c11"
+ CFLAGS="${saved_CFLAGS} -std=c11"
AC_MSG_CHECKING([if $CC supports -std=c11])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([_Thread_local int x;], [x = 42;])],
[AC_MSG_RESULT([yes])],