Skip to content
This repository
Fetching contributors…

Cannot retrieve contributors at this time

file 88 lines (70 sloc) 2.51 kb
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 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88
# Copyright (C) 2012-2013 Canonical Ltd.
# Author: Martin Pitt <martin.pitt@ubuntu.com>
#
# umockdev is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# umockdev is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with this program; If not, see <http://www.gnu.org/licenses/>.

AC_PREREQ([2.64])
AC_INIT([umockdev],
        [0.1],
        [https://github.com/martinpitt/umockdev/issues],
        [umockdev],
[https://github.com/martinpitt/umockdev])

AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_SRCDIR([src/umockdev-wrapper])
AC_CONFIG_HEADERS([config.h])

AC_SYS_LARGEFILE

AM_SILENT_RULES([yes])
AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Werror silent-rules subdir-objects tar-pax no-dist-gzip dist-xz])
AM_PROG_CC_C_O

LT_PREREQ(2.2)
LT_INIT

# check for gtk-doc
m4_ifdef([GTK_DOC_CHECK], [
GTK_DOC_CHECK([1.14],[--flavour no-tmpl])
],[
AM_CONDITIONAL([ENABLE_GTK_DOC], false)
])

# check for gobject-introspection
m4_ifdef([GOBJECT_INTROSPECTION_CHECK],
[GOBJECT_INTROSPECTION_CHECK([1.32])],
[AM_CONDITIONAL([HAVE_INTROSPECTION], [false])])


AC_SEARCH_LIBS([dlsym], [dl], [], [AC_MSG_ERROR([Dynamic linking loader library not found])])
PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.24.0 gobject-2.0 >= 2.24.0 gio-2.0 >= 2.24.0])
PKG_CHECK_MODULES([LIBUDEV], [libudev])
PKG_CHECK_MODULES([GUDEV], [gudev-1.0])


# if we have Python 2 or 3, run the GI test (they will skip if gi.repository is
# not available)
AC_CHECK_PROGS(PYTHON, [python3 python])
AM_CONDITIONAL(HAVE_PYTHON, [test x$PYTHON != x])

AC_CHECK_PROGS(VALAC, [valac])
AM_PROG_VALAC([0.16])

AC_CONFIG_FILES([
Makefile
src/umockdev-1.0.pc
docs/reference/Makefile
docs/reference/version.xml
])

AC_OUTPUT

AC_MSG_RESULT([
  $PACKAGE_NAME $VERSION
  
  CPPFLAGS: ${CPPFLAGS}
  CFLAGS: ${CFLAGS}
  LDFLAGS: ${LDFLAGS}

  gobject-introspection support: ${enable_introspection}])

if test x$PYTHON != x; then
  AC_MSG_RESULT([ Python: ${PYTHON}])
else
  AC_MSG_RESULT([
  WARNING! No Python interpreter found. Some tests cannot be run.])
fi
Something went wrong with that request. Please try again.