Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 105 lines (84 sloc) 3.08 kb
034833a Require Vala for building
Martin Pitt authored
1 # Copyright (C) 2012-2013 Canonical Ltd.
30e9d68 Add preload library and initial build system
Martin Pitt authored
2 # Author: Martin Pitt <martin.pitt@ubuntu.com>
3 #
4 # umockdev is free software; you can redistribute it and/or modify it
5 # under the terms of the GNU Lesser General Public License as published by
6 # the Free Software Foundation; either version 2.1 of the License, or
7 # (at your option) any later version.
8 #
9 # umockdev is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # Lesser General Public License for more details.
13 #
14 # You should have received a copy of the GNU Lesser General Public License
15 # along with this program; If not, see <http://www.gnu.org/licenses/>.
16
17 AC_PREREQ([2.64])
18 AC_INIT([umockdev],
38fb28f configure.ac: Determine version number from NEWS
Martin Pitt authored
19 m4_esyscmd([head -n1 NEWS | cut -f1 -d' ' | tr -d '\n']),
30e9d68 Add preload library and initial build system
Martin Pitt authored
20 [https://github.com/martinpitt/umockdev/issues],
21 [umockdev],
22 [https://github.com/martinpitt/umockdev])
23
24 AC_CONFIG_MACRO_DIR([m4])
25 AC_CONFIG_AUX_DIR([build-aux])
26 AC_CONFIG_SRCDIR([src/umockdev-wrapper])
27 AC_CONFIG_HEADERS([config.h])
28
29 AC_SYS_LARGEFILE
30
31 AM_SILENT_RULES([yes])
627e7c7 Disable automake portability warnings
Martin Pitt authored
32 AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Werror -Wno-portability silent-rules subdir-objects tar-pax no-dist-gzip dist-xz])
b7bbaf8 Add UMockdevTestbed library
Martin Pitt authored
33 AM_PROG_CC_C_O
93d0f1c Christopher James Halse Rogers Build with C99 support
RAOF authored
34 AC_PROG_CC_C99
f07e93c Peter Hutterer Fix errors with automake 1.12
whot authored
35 AM_PROG_AR
30e9d68 Add preload library and initial build system
Martin Pitt authored
36
37 LT_PREREQ(2.2)
38 LT_INIT
39
ffb0d48 Add gtk-doc documentation
Martin Pitt authored
40 # check for gtk-doc
41 m4_ifdef([GTK_DOC_CHECK], [
42 GTK_DOC_CHECK([1.14],[--flavour no-tmpl])
43 ],[
44 AM_CONDITIONAL([ENABLE_GTK_DOC], false)
45 ])
46
47 # check for gobject-introspection
6855b18 Add gobject-introspection support
Martin Pitt authored
48 m4_ifdef([GOBJECT_INTROSPECTION_CHECK],
49 [GOBJECT_INTROSPECTION_CHECK([1.32])],
50 [AM_CONDITIONAL([HAVE_INTROSPECTION], [false])])
51
52
b7bbaf8 Add UMockdevTestbed library
Martin Pitt authored
53 AC_SEARCH_LIBS([dlsym], [dl], [], [AC_MSG_ERROR([Dynamic linking loader library not found])])
ef78859 Add recording of Unix stream sockets
Martin Pitt authored
54 PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.32.0 gobject-2.0 >= 2.32.0 gio-2.0 >= 2.32.0 gio-unix-2.0 >= 2.32.0])
77a4e1b Add umockdev_testbed_uevent()
Martin Pitt authored
55 PKG_CHECK_MODULES([LIBUDEV], [libudev])
b7bbaf8 Add UMockdevTestbed library
Martin Pitt authored
56 PKG_CHECK_MODULES([GUDEV], [gudev-1.0])
57
e841d64 Port UMockdev class and library to Vala
Martin Pitt authored
58
6e97ff9 Add test for introspection binding
Martin Pitt authored
59 # if we have Python 2 or 3, run the GI test (they will skip if gi.repository is
60 # not available)
61 AC_CHECK_PROGS(PYTHON, [python3 python])
62 AM_CONDITIONAL(HAVE_PYTHON, [test x$PYTHON != x])
63
034833a Require Vala for building
Martin Pitt authored
64 AC_CHECK_PROGS(VALAC, [valac])
304aa0c Fix building with vala 0.16.1
Martin Pitt authored
65 AM_PROG_VALAC([0.16.1])
bc27179 Add Vala binding and test cases
Martin Pitt authored
66
8cb9b62 Add code coverage reporting with gcov and lcov
Martin Pitt authored
67 # code coverage support
68 AC_MSG_CHECKING(for GNOME code coverage support)
69 m4_ifdef([GNOME_CODE_COVERAGE],
70 [AC_MSG_RESULT(yes)
71 GNOME_CODE_COVERAGE],
72 [AC_MSG_RESULT(no)
73 GNOME_CODE_COVERAGE_RULES=''
74 AC_SUBST([GNOME_CODE_COVERAGE_RULES])
75 enable_code_coverage="no"])
76
77 CFLAGS="$CFLAGS $CODE_COVERAGE_CFLAGS"
78 LDFLAGS="$LDFLAGS $CODE_COVERAGE_CFLAGS"
79
30e9d68 Add preload library and initial build system
Martin Pitt authored
80 AC_CONFIG_FILES([
81 Makefile
b7bbaf8 Add UMockdevTestbed library
Martin Pitt authored
82 src/umockdev-1.0.pc
ffb0d48 Add gtk-doc documentation
Martin Pitt authored
83 docs/reference/Makefile
84 docs/reference/version.xml
30e9d68 Add preload library and initial build system
Martin Pitt authored
85 ])
86
87 AC_OUTPUT
6855b18 Add gobject-introspection support
Martin Pitt authored
88
89 AC_MSG_RESULT([
90 $PACKAGE_NAME $VERSION
91
92 CPPFLAGS: ${CPPFLAGS}
93 CFLAGS: ${CFLAGS}
94 LDFLAGS: ${LDFLAGS}
bc27179 Add Vala binding and test cases
Martin Pitt authored
95
8cb9b62 Add code coverage reporting with gcov and lcov
Martin Pitt authored
96 gobject-introspection support: ${enable_introspection}
97 code coverage support: ${enable_code_coverage}])
6d1b93b Add umockdump tool
Martin Pitt authored
98
99 if test x$PYTHON != x; then
bc27179 Add Vala binding and test cases
Martin Pitt authored
100 AC_MSG_RESULT([ Python: ${PYTHON}])
6d1b93b Add umockdump tool
Martin Pitt authored
101 else
bc27179 Add Vala binding and test cases
Martin Pitt authored
102 AC_MSG_RESULT([
52fcf6c configure.ac: Clarify impact if no Python is available
Martin Pitt authored
103 WARNING! No Python interpreter found. Some tests cannot be run.])
6d1b93b Add umockdump tool
Martin Pitt authored
104 fi
Something went wrong with that request. Please try again.