Merge branch 'nd/fileno-may-be-macro'
[gitweb.git] / Makefile
index 0e13a5b4698a02e93c9f2c95e06b4193fe229567..af7e809ced694635d1281dbcf3f0ab234ce3c137 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -433,6 +433,8 @@ all::
 #
 # Define HAVE_GETDELIM if your system has the getdelim() function.
 #
+# Define FILENO_IS_A_MACRO if fileno() is a macro, not a real function.
+#
 # Define PAGER_ENV to a SP separated VAR=VAL pairs to define
 # default environment variables to be passed when a pager is spawned, e.g.
 #
@@ -1800,6 +1802,11 @@ ifdef HAVE_WPGMPTR
        BASIC_CFLAGS += -DHAVE_WPGMPTR
 endif
 
+ifdef FILENO_IS_A_MACRO
+       COMPAT_CFLAGS += -DFILENO_IS_A_MACRO
+       COMPAT_OBJS += compat/fileno.o
+endif
+
 ifeq ($(TCLTK_PATH),)
 NO_TCLTK = NoThanks
 endif