From dd92b9f88ccb272dcb3720b9fe6d7e8eca89a056 Mon Sep 17 00:00:00 2001 From: Marcus Comstedt Date: Tue, 17 May 2022 15:30:22 +0200 Subject: [PATCH] Configure: Fix failure of FSEvents to configure with --disable-binary FSEvents uses AC_CHECK_DECLS in its configure script. AC_CHECK_DECLS has an internal test where it tries to figure out what flag to pass to the compiler to make compilation of a certain piece of code _fail_. But nobinary_dummy "succeeds" at compiling anything, which makes it impossible for this configure test to succeed. Work around the issue by pre-seeding the cache with the desired outcome for the internal test. Also, fix the incorrect test guarding the assignment of CC to $BINDIR/nobinary_dummy. --- src/aclocal.m4 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/aclocal.m4 b/src/aclocal.m4 index 0755f76b97..4e56e79fcb 100644 --- a/src/aclocal.m4 +++ b/src/aclocal.m4 @@ -271,11 +271,12 @@ define([MY_AC_PROG_CC], AC_PROG_CC undefine([ac_cv_prog_CC]) AC_PROG_CPP - if test "x$enable_binary" = "no"; then + if test "x$enable_binary" = x"no"; then # Do the check above even when --disable-binary is used, since we # need a real $CPP, and AC_PROG_CPP wants AC_PROG_CC to be called # earlier. CC="$BINDIR/nobinary_dummy cc" + ac_cv_c_undeclared_builtin_options='none needed' fi ])