package version up
[platform/upstream/libSM.git] / configure.ac
1
2 # Initialize Autoconf
3 AC_PREREQ(2.60)
4 AC_INIT([libSM], [1.2.2],
5         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libSM])
6 AC_CONFIG_SRCDIR([Makefile.am])
7 AC_CONFIG_HEADERS([config.h])
8
9 # Initialize Automake
10 AM_INIT_AUTOMAKE([foreign dist-bzip2])
11
12 # Initialize libtool
13 AC_PROG_LIBTOOL
14
15 # Require xorg-macros minimum of 1.12 for DocBook external references
16 m4_ifndef([XORG_MACROS_VERSION],
17           [m4_fatal([must install xorg-macros 1.12 or later before running autoconf/autogen])])
18 XORG_MACROS_VERSION(1.12)
19 XORG_DEFAULT_OPTIONS
20 XORG_ENABLE_DOCS
21 XORG_WITH_XMLTO(0.0.22)
22 XORG_WITH_FOP
23 XORG_WITH_XSLTPROC
24 XORG_CHECK_SGML_DOCTOOLS(1.8)
25
26 # Obtain compiler/linker options for depedencies
27 PKG_CHECK_MODULES(SM, [ice >= 1.0.5] xproto xtrans)
28
29 # Needed to check for TCP & IPv6 support and set flags appropriately
30 XTRANS_CONNECTION_FLAGS
31
32 AC_ARG_WITH(libuuid, AS_HELP_STRING([--with-libuuid], [Build with libuuid support for client IDs]))
33
34 AC_CHECK_FUNCS([uuid_create], [], [
35     if test x"$with_libuuid" != xno && test x"$have_system_uuid" != xyes; then
36         PKG_CHECK_MODULES(LIBUUID, uuid, [HAVE_LIBUUID=yes], [HAVE_LIBUUID=no])
37     fi
38     if test x"$with_libuuid" = xyes && test x"$HAVE_LIBUUID" = xno; then
39         AC_MSG_ERROR([requested libuuid support but uuid.pc not found])
40     fi
41 ])
42
43 AM_CONDITIONAL(WITH_LIBUUID, test x"$HAVE_LIBUUID" = xyes)
44
45 AC_CONFIG_FILES([Makefile
46                 doc/Makefile
47                 src/Makefile
48                 sm.pc])
49 AC_OUTPUT