aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac22
1 files changed, 18 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index f20b632..dde224e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5,7 +5,7 @@ AC_CONFIG_HEADERS([config.h])
AC_PROG_CC
AC_LANG(C)
-AC_PROG_LIBTOOL
+LT_INIT
# --enable and --with options
AC_ARG_ENABLE([debug-output],
@@ -35,9 +35,23 @@ AM_CONDITIONAL([INSTALL_MACOS_FS_LINK], [case $build_os in darwin* ) test x"$ena
# _BSD_SOURCE is for stat() nanosecond precision and lutimes().
# _DEFAULT_SOURCE is the new non-deprecated version of _BSD_SOURCE.
# _DARWIN_BETTER_REALPATH fixes MacOS realpath() broken around Catalina (#83).
-my_CPPFLAGS="-D_REENTRANT -D_FILE_OFFSET_BITS=64 -D_XOPEN_SOURCE=700 -D__BSD_VISIBLE=1 -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_DARWIN_BETTER_REALPATH"
-
-my_CFLAGS="-std=c99 -Wall -Wextra -Wpedantic -fno-common"
+# _DARWIN_C_SOURCE for DT_LNK (#163)
+my_CPPFLAGS="-D_REENTRANT -D_FILE_OFFSET_BITS=64 -D_XOPEN_SOURCE=700 -D__BSD_VISIBLE=1 -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_DARWIN_BETTER_REALPATH -D_DARWIN_C_SOURCE"
+
+dnl libfuse >=3.17 started requiring gnu11 from the C compiler
+AS_IF([test "x$with_fuse2" == "xyes"], [
+ my_std=c99
+], [
+ my_std=gnu11
+])
+
+my_CFLAGS="-std=${my_std} -Wall -Wextra -Wpedantic -fno-common"
+case $build_os in
+ darwin* )
+ # For MacFuse 5.x (2025-06-08)
+ my_CFLAGS="${my_CFLAGS} -Wno-language-extension-token -Wno-dollar-in-identifier-extension -DFUSE_DARWIN_ENABLE_EXTENSIONS=0"
+ ;;
+esac
my_LDFLAGS="-pthread"
AC_SUBST([my_CPPFLAGS])
AC_SUBST([my_CFLAGS])