Add check for glob.h
[pazpar2-moved-to-github.git] / configure.ac
1 ## -*- Autoconf -*-
2 ## This file is part of Pazpar2.
3 ## Process this file with autoconf to produce a configure script.
4
5 # Autoconf and automake setup
6 AC_PREREQ(2.60)
7 AC_INIT([pazpar2],[1.1.1],[pazpar2-help@indexdata.dk])
8
9 AC_CONFIG_HEADERS(src/config.h)
10
11 AC_CONFIG_SRCDIR([configure.ac]) 
12 AC_CONFIG_AUX_DIR([config])
13 AC_CANONICAL_SYSTEM
14
15 AM_INIT_AUTOMAKE([1.9])
16
17 AC_PROG_CC
18 AC_PROG_RANLIB
19
20 AC_LANG(C)
21
22 YAZ_INIT([static icu threads],[3.0.39])
23 if test -z "$YAZLIB"; then
24         AC_MSG_ERROR([YAZ development libraries missing])
25 fi
26 YAZ_DOC
27
28 AC_CHECK_HEADERS([sys/time.h sys/socket.h unistd.h netinet/in.h netdb.h arpa/inet.h glob.h])
29 AC_CHECK_FUNCS([getaddrinfo])
30
31 if test -d ${srcdir}/.git; then
32         sha=`git show --pretty=format:%H|head -1`
33 else
34         sha=`head -1 ${srcdir}/ChangeLog|awk '{print $2}'`
35 fi
36 AC_DEFINE_UNQUOTED([PAZPAR2_VERSION_SHA1], ["$sha"], [Git SHA1])
37
38 AC_CONFIG_FILES([
39         Doxyfile
40         Makefile
41         src/Makefile
42         test/Makefile
43         js/Makefile
44         doc/Makefile
45         doc/local.ent
46         doc/common/Makefile
47         doc/common/print.dsl
48         win/version.nsi
49 ])
50
51 AC_OUTPUT
52
53
54 echo \
55 "------------------------------------------------------------------------
56
57   Package:                    ${PACKAGE}
58   Version:                    ${VERSION}
59   Source code location:       ${srcdir}
60   C Preprocessor:             ${CPP}
61   C Preprocessor flags:       ${CPPFLAGS}
62   C Compiler:                 ${CC}
63   C Compiler flags:           ${CFLAGS}
64   Linker flags:               ${LDFLAGS}
65   Linked libs:                ${LIBS}
66   Host System Type:           ${host}
67   Install path:               ${prefix}
68   Automake:                   ${AUTOMAKE}
69   Archiver:                   ${AR}
70   Ranlib:                     ${RANLIB}
71   YAZ Version:                ${YAZVERSION}
72   YAZ Include:                ${YAZINC}
73   YAZ La Lib:                 ${YAZLALIB}
74   YAZ Lib:                    ${YAZLIB}
75   Bugreport:                  ${PACKAGE_BUGREPORT}
76
77 ------------------------------------------------------------------------"
78
79 dnl Local Variables:
80 dnl mode:shell-script
81 dnl sh-indentation:2
82 dnl sh-basic-offset: 4
83 dnl End: