forked from linuxwacom/libwacom
-
Notifications
You must be signed in to change notification settings - Fork 0
/
configure.ac
67 lines (54 loc) · 1.98 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
# Initialize Autoconf
AC_PREREQ([2.60])
AC_INIT([libwacom], [1.4.1]) # change meson.build as well
AC_CONFIG_HEADERS([config.h])
# Initialize Automake
AM_INIT_AUTOMAKE([foreign dist-bzip2 no-dist-gzip check-news])
AM_MAINTAINER_MODE([enable])
# Enable silent build when available (Automake 1.11)
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
# Do not modify this, use symbol versioning instead.
LIBWACOM_LT_VERSION=8:1:6
AC_SUBST(LIBWACOM_LT_VERSION)
# Initialize libtool
AC_PROG_LIBTOOL
# Checks for programs.
AC_PROG_CC
AC_PROG_CC_C99
AC_PROG_INSTALL
PKG_PROG_PKG_CONFIG
AC_CHECK_PROG(HAVE_DOXYGEN, [doxygen], [yes], [no])
AM_CONDITIONAL(HAVE_DOXYGEN, test "x$HAVE_DOXYGEN" = xyes)
AC_CHECK_LIB([dl], [dlsym])
AC_SUBST(DL_LIBS)
PKG_CHECK_MODULES(GLIB, glib-2.0 gudev-1.0)
PKG_CHECK_MODULES(LIBXML, libxml-2.0 glib-2.0, HAVE_LIBXML="yes", HAVE_LIBXML="no")
AM_CONDITIONAL(HAVE_LIBXML, test x$HAVE_LIBXML = xyes)
PKG_CHECK_MODULES(GTK2, librsvg-2.0 glib-2.0 gtk+-2.0, HAVE_GTK2="yes", HAVE_GTK2="no")
AM_CONDITIONAL(HAVE_GTK2, test x$HAVE_GTK2 = xyes)
PKG_CHECK_MODULES(GLIB_236, [glib-2.0 >= 2.36], HAVE_GLIB236="yes", HAVE_GLIB236="no")
if test "x$HAVE_GLIB236" != "xyes"; then
AC_DEFINE(NEED_G_TYPE_INIT, 1, [Need g_type_init() call])
fi
udev_dir_default="$libdir/udev"
AC_ARG_WITH(udev-dir,
AS_HELP_STRING([--with-udev-dir=DIR],
[udev base directory [[default=$udev_dir_default]]]),
[],
[with_udev_dir="yes"])
AS_CASE($with_udev_dir,
[no|""], [AC_MSG_ERROR([You must define a udev base directory])],
[yes], [udevdir="$udev_dir_default"],
[udevdir="$with_udev_dir"])
UDEV_DIR=${udevdir}
AC_SUBST(UDEV_DIR)
AC_CONFIG_FILES([Makefile
data/Makefile
data/layouts/Makefile
doc/Makefile
test/Makefile
tools/Makefile
tools/65-libwacom.rules
libwacom/Makefile
libwacom.pc])
AC_OUTPUT