forked from politza/pdf-tools
-
Notifications
You must be signed in to change notification settings - Fork 1
/
configure.ac
55 lines (44 loc) · 1.71 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
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.67])
AC_INIT([pdf-tools], [0.20], [[email protected]])
AM_INIT_AUTOMAKE([-Wall -Wno-override foreign])
AC_CONFIG_SRCDIR([src/epdfinfo.h])
AC_CONFIG_HEADERS([src/config.h])
# Checks for programs.
AC_PROG_CC
AC_PROG_CXX
AM_PATH_LISPDIR dnl Sets EMACS
# Checks for libraries.
HAVE_POPPLER_FIND_OPTS="no (requires poppler-glib >= 0.22)"
HAVE_POPPLER_ANNOT_WRITE="no (requires poppler-glib >= 0.19.4)"
PKG_CHECK_MODULES([glib], [glib-2.0])
PKG_CHECK_MODULES([poppler], [poppler])
PKG_CHECK_MODULES([poppler_glib], [poppler-glib >= 0.16.0])
PKG_CHECK_EXISTS([poppler-glib >= 0.22], [HAVE_POPPLER_FIND_OPTS=yes])
PKG_CHECK_EXISTS([poppler-glib >= 0.19.4], [HAVE_POPPLER_ANNOT_WRITE=yes])
PKG_CHECK_MODULES([zlib], [zlib])
if test "$HAVE_POPPLER_FIND_OPTS" = yes; then
AC_DEFINE([HAVE_POPPLER_FIND_OPTS],1,
[Define to 1 to enable case sensitive searching (requires poppler-glib >= 0.22).])
fi
if test "$HAVE_POPPLER_ANNOT_WRITE" = yes; then
AC_DEFINE([HAVE_POPPLER_ANNOT_WRITE],1,
[Define to 1 to enable writing of annotations (requires poppler-glib >= 0.19.4).])
fi
# Checks for header files.
AC_CHECK_HEADERS([stdlib.h string.h strings.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_TYPE_SIZE_T
AC_TYPE_SSIZE_T
AC_CHECK_TYPES([ptrdiff_t])
# Checks for library functions.
AC_FUNC_ERROR_AT_LINE
AC_FUNC_STRTOD
AC_CHECK_FUNCS([strcspn strtol])
AC_CONFIG_FILES([Makefile src/Makefile])
AC_OUTPUT
echo
echo "Is case-sensitive searching enabled ? ${HAVE_POPPLER_FIND_OPTS}"
echo "Is writing annotations enabled ? ${HAVE_POPPLER_ANNOT_WRITE}"
echo