This repository has been archived by the owner on Jan 14, 2025. It is now read-only.
forked from otatebe/chfs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigure.ac
123 lines (108 loc) · 3.56 KB
/
configure.ac
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.69])
AC_INIT([CHFS], [1.0.0])
AM_INIT_AUTOMAKE([-Wall -Werror foreign])
AC_CONFIG_SRCDIR([README.md])
AC_CONFIG_HEADERS([lib/config.h])
AC_CONFIG_MACRO_DIRS([m4])
# Checks for programs.
AC_PROG_CC
AM_PROG_CC_C_O
AM_PROG_AR
LT_INIT
AC_CHECK_PROG([PANDOC], [pandoc], [yes])
AM_CONDITIONAL([HAVE_PANDOC], [test x$PANDOC = xyes])
AC_MSG_CHECKING([whether xattr is used for metadata])
AC_ARG_ENABLE([xattr],
[AS_HELP_STRING([--enable-xattr],
[use xattr for metadata @<:@default=no@:>@])],
[], [enableval=no])
AC_MSG_RESULT([$enableval])
if test x$enableval != xno; then
AC_DEFINE([USE_XATTR], [1], [Use xattr for metadata])
fi
AC_MSG_CHECKING([whether port number is included to hash])
AC_ARG_ENABLE([hash-port],
[AS_HELP_STRING([--enable-hash-port],
[include port number to hash @<:@default=no@:>@])],
[], [enableval=no])
AC_MSG_RESULT([$enableval])
if test x$enableval != xno; then
AC_DEFINE([ENABLE_HASH_PORT], [1], [Include port number to hash])
fi
AC_MSG_CHECKING([whether zero copy read rdma is used])
AC_ARG_ENABLE([zero-copy-read-rdma],
[AS_HELP_STRING([--enable-zero-copy-read-rdma],
[use zero copy read rdma @<:@default=no@:>@])],
[], [enableval=no])
AC_MSG_RESULT([$enableval])
if test x$enableval != xno; then
AC_DEFINE([USE_ZERO_COPY_READ_RDMA], [1], [Use zero copy read rdma])
fi
# Checks for libraries.
PKG_CHECK_MODULES([MARGO], [margo])
PKG_CHECK_MODULES([OPENSSL], [openssl])
PKG_CHECK_MODULES([FUSE], [fuse])
AC_MSG_CHECKING([pmemkv])
AC_ARG_WITH([pmemkv],
[AS_HELP_STRING([--with-pmemkv],
[use pmemkv @<:@default=no@:>@])],
[], [with_pmemkv=no])
AC_MSG_RESULT([$with_pmemkv])
AM_CONDITIONAL([USE_PMEMKV], [test x$with_pmemkv != xno])
if test x$with_pmemkv != xno; then
AC_DEFINE([USE_PMEMKV], [1], [Use pmemkv])
PKG_CHECK_MODULES([LIBPMEMKV], [libpmemkv])
fi
AC_MSG_CHECKING([abt-io])
AC_ARG_WITH([abt-io],
[AS_HELP_STRING([--with-abt-io],
[use abt-io @<:@default=no@:>@])],
[], [with_abt_io=no])
AC_MSG_RESULT([$with_abt_io])
AM_CONDITIONAL([USE_ABT_IO], [test x$with_abt_io != xno])
if test x$with_abt_io != xno; then
AC_DEFINE([USE_ABT_IO], [1], [Use abt-io])
PKG_CHECK_MODULES([ABT_IO], [abt-io])
fi
AC_MSG_CHECKING([digest-murmur3])
AC_ARG_WITH([digest-murmur3],
[AS_HELP_STRING([--with-digest-murmur3],
[use murmur3 digest @<:@default=no@:>@])],
[], [with_digest_murmur3=no])
AC_MSG_RESULT([$with_digest_murmur3])
if test x$with_digest_murmur3 != xno; then
AC_DEFINE([USE_DIGEST_MURMUR3], [1], [Use murmur3 digest])
fi
AC_MSG_CHECKING([daos])
AC_ARG_WITH([daos],
[AS_HELP_STRING([--with-daos],
[use daos @<:@default=no@:>@])],
[], [with_daos=no])
AC_MSG_RESULT([$with_daos])
AM_CONDITIONAL([USE_DAOS], [test x$with_daos != xno])
if test x$with_daos != xno; then
AC_DEFINE([USE_DAOS], [1], [Use daos])
# v1.2 has no pc file... so, configure and check manually
PKG_CHECK_MODULES([DAOS], [daos])
PKG_CHECK_MODULES([UUID], [uuid])
fi
# Checks for header files.
AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h netinet/in.h stddef.h stdlib.h string.h syslog.h unistd.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_C_INLINE
AC_TYPE_INT32_T
AC_TYPE_MODE_T
AC_TYPE_OFF_T
AC_TYPE_SIZE_T
AC_TYPE_SSIZE_T
AC_TYPE_UINT32_T
AC_TYPE_UINT64_T
AC_TYPE_UINT8_T
# Checks for library functions.
AC_FUNC_MALLOC
AC_FUNC_REALLOC
AC_CHECK_FUNCS([memset mkdir rmdir strchr strdup strerror])
AC_CONFIG_FILES([Makefile lib/Makefile chfsd/Makefile client/Makefile client/chfsctl doc/Makefile])
AC_OUTPUT