-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfigure.ac
76 lines (63 loc) · 1.68 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
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.50])
AC_INIT(pubcFS, 0.1, [email protected])
AC_CONFIG_AUX_DIR([config])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE
AC_CONFIG_SRCDIR([src/fuse_operations.h])
AC_CONFIG_HEADERS([config.h])
AC_LANG_C
AC_PREFIX_DEFAULT(/usr/local)
# Checks for programs.
AC_PROG_CC
AC_PROG_CXX
AC_PROG_LIBTOOL
AM_PROG_CC_C_O
AC_PROG_INSTALL
CFLAGS="-D_FILE_OFFSET_BITS=64 -Wall -g"
LDFLAGS="-L/usr/lib -L/usr/local/lib"
# Checks for libraries.
AC_CHECK_LIB(fuse,fuse_main,
[FUSE_LIBS="-lfuse"],
[AC_MSG_ERROR([ fuse library not found: use -L in LDFLAGS for configure
the search path (for example: "export LDFLAGS=-L/usr/lib" ])],)
AC_SUBST(FUSE_LIBS)
AC_CHECK_LIB(m,ceil,
[MATH_LIBS="-lm"],
[AC_MSG_ERROR([ math library not found: use -L in LDFLAGS for configure
the search path (for example: "export LDFLAGS=-L/usr/lib" ])],)
AC_SUBST(MATH_LIBS)
AC_CHECK_LIB(crypto,EVP_EncryptInit_ex,
[CRYPTO_LIBS="-lcrypto"],
[AC_MSG_ERROR([ crypto library not found: use -L in LDFLAGS for configure
the search path (for example: "export LDFLAGS=-L/usr/lib" ])],)
AC_SUBST(CRYPTO_LIBS)
# Checks for header files.
AC_CHECK_HEADERS([ \
fuse.h \
sys/types.h \
sys/stat.h \
errno.h \
unistd.h \
fcntl.h \
stdint.h \
stdlib.h \
string.h \
openssl/evp.h \
openssl/aes.h
])
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_TYPE_INT8_T
AC_TYPE_OFF_T
AC_TYPE_SIZE_T
AC_TYPE_UINT8_T
# Checks for library functions.
AC_FUNC_MALLOC
AC_CHECK_FUNCS([memset])
AC_CONFIG_FILES([
Makefile
src/Makefile
])
AC_OUTPUT