summaryrefslogtreecommitdiffstats
path: root/src/mtab.c
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2022-11-06 11:52:49 -0500
committerTavian Barnes <tavianator@tavianator.com>2022-11-06 16:37:14 -0500
commit46387a7dcda93e7df9f5baa3ead753c0feeff122 (patch)
tree73223994a7fb667d88df4849a5056696e203bb63 /src/mtab.c
parent0a5a80c98cc7e5d8735b615fa197a6cff2bb08cc (diff)
downloadbfs-46387a7dcda93e7df9f5baa3ead753c0feeff122.tar.xz
util: Get rid of BFS_HAS_INCLUDE() wrapper for __has_include()
Since __has_include() needs special preprocessing rules (e.g. not expanding `linux` in `__has_include(<linux/stat.h>)`, macros that expand to __has_include() do not necessarily behave correctly. Instead, we have to directly test `#if __has_include(...)`. See https://bugs.llvm.org/show_bug.cgi?id=37990 for more details.
Diffstat (limited to 'src/mtab.c')
-rw-r--r--src/mtab.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mtab.c b/src/mtab.c
index adc3f58..a9f5b41 100644
--- a/src/mtab.c
+++ b/src/mtab.c
@@ -26,11 +26,11 @@
#include <string.h>
#include <sys/types.h>
-#if BFS_HAS_SYS_PARAM
+#if BFS_USE_SYS_PARAM_H
# include <sys/param.h>
#endif
-#if BFS_HAS_MNTENT
+#if BFS_USE_MNTENT_H
# define BFS_MNTENT 1
#elif BSD
# define BFS_MNTINFO 1