Fossil SCM

fossil-scm / configure.ac
Blame History Raw 56 lines
1
dnl Process this file with autoconf to produce a configure script.
2
AC_PREREQ(2.61)
3
AC_INIT([fossil], [20110528], [[email protected]])
4
AC_CONFIG_SRCDIR([src/schema.c])
5
AC_CONFIG_AUX_DIR([autoconf])
6
AC_CONFIG_MACRO_DIR([autoconf])
7
AC_CONFIG_HEADER(autoconfig.h)
8
9
AC_CANONICAL_HOST
10
11
# Checks for programs.
12
AC_PROG_MAKE_SET
13
AC_PROG_CC
14
15
case $host_os in
16
dragonfly|freebsd|netbsd|openbsd) AC_DEFINE([USE_PREAD], [1], [Use pread/pwrite system calls in place of seek + read/write])
17
esac
18
19
AC_CHECK_LIB(z, inflateEnd, [zlib_cv_libz=yes], [zlib_cv_libz=no])
20
AC_CHECK_HEADER(zlib.h, [zlib_cv_zlib_h=yes], [zlib_cv_zlib_h=no])
21
22
if test "$zlib_cv_libz" != yes || test "$zlib_cv_zlib_h" != yes; then
23
AC_MSG_ERROR(zlib not found, please install it or add the necessary flags to CPPFLAGS / LDFLAGS)
24
fi
25
LIBS="$LIBS -lz"
26
27
enable_openssl=check
28
AC_ARG_ENABLE([openssl], [AS_HELP_STRING([--enable-openssl], [Include HTTPS support using for OpenSSL])], [enable_openssl=yes], [enable_openssl=no])
29
if test "$enable_openssl" != no; then
30
AX_CHECK_OPENSSL([AC_DEFINE([FOSSIL_ENABLE_SSL], [1], [Support HTTPS])],
31
[ if test "$enable_openssl" = yes; then
32
AC_MSG_RESULT(failed)
33
AC_MSG_ERROR(HTTPS support requested, but OpenSSL not found)
34
fi
35
]
36
)
37
fi
38
39
# Network functions on Solaris
40
AC_SEARCH_LIBS([gethostbyname], [nsl network])
41
AC_SEARCH_LIBS([socket],
42
[socket],
43
[],
44
[AC_CHECK_LIB([socket],
45
[socket],
46
[LIBS="-lsocket -lnsl $LIBS"],
47
[],
48
[-lnsl])])
49
50
51
# Check for getpassphrase() for Solaris 10 where getpass() truncates to 10 chars
52
AC_CHECK_FUNCS(getpassphrase)
53
54
AC_CONFIG_FILES([Makefile])
55
AC_OUTPUT
56

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button