[go: up one dir, main page]

File: configure.ac

package info (click to toggle)
fuse-posixovl 1.3-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 552 kB
  • sloc: ansic: 1,634; sh: 1,303; makefile: 29
file content (53 lines) | stat: -rw-r--r-- 1,551 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
AC_INIT([posixovl], [1.3])
AC_PREREQ([2.61])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_HEADERS([config.h])
AC_PROG_INSTALL
AM_INIT_AUTOMAKE([-Wall foreign subdir-objects])
AC_PROG_CC
AM_PROG_CC_C_O

regular_CPPFLAGS="-D_FORTIFY_SOURCE=2 -D_LARGEFILE_SOURCE=1 -D_LARGE_FILES \
	-D_FILE_OFFSET_BITS=64 -D_REENTRANT";
regular_CFLAGS="-std=c99 -Wall -Waggregate-return \
	-Wmissing-declarations -Wmissing-prototypes -Wredundant-decls \
	-Wshadow -Wstrict-prototypes -Winline -pipe"
AC_SUBST([regular_CPPFLAGS])
AC_SUBST([regular_CFLAGS])

AC_CHECK_HEADERS([attr/xattr.h sys/xattr.h])

# FUSE >= 2.7.0 got subtype name support.
# 2.6.5 does not, but has a similar thing.
PKG_CHECK_MODULES([libfuse], [fuse >= 2.7.0], [], [
	PKG_CHECK_MODULES([libfuse], [fuse >= 2.6.5], [
		AC_DEFINE([HAVE_JUST_FUSE_2_6_5], [1],
			[Define if you have a FUSE version >= 2.6.5 but < 2.7.0])
	])
])

# Minium requirements for utimensat(): Linux 2.6.22-rc1 and Glibc 2.6
AC_MSG_CHECKING([for utimensat()])
#
# We need to check for __NR_utimensat too, because Glibc would
# offer a wrapper otherwise.
#
AC_LINK_IFELSE([AC_LANG_SOURCE([
		#define _ATFILE_SOURCE 1
		#include <sys/stat.h>
		#include <fcntl.h>
		#include <asm/unistd.h>
		static unsigned int x = __NR_utimensat;
		static int (*y)(int, const char *, const struct timespec *,
			int) = utimensat;
		int main(void) { return 0; }
	])], [
		AC_DEFINE([HAVE_UTIMENSAT], [1],
			[Define if utimensat() function is available])
		AC_MSG_RESULT([yes])
	], [
		AC_MSG_RESULT([no])
	])

AC_CONFIG_FILES([Makefile])
AC_OUTPUT