aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac5
-rw-r--r--vapi/Makefile.am22
-rw-r--r--vapi/ModemManager-1.0.metadata0
-rw-r--r--vapi/libmm-glib.deps1
5 files changed, 29 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 59accbff..96850e24 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,5 +1,5 @@
-SUBDIRS = . build-aux data include libqcdm libwmc libmm-glib src plugins cli introspection uml290 po test docs
+SUBDIRS = . build-aux data include libqcdm libwmc libmm-glib src plugins cli vapi introspection uml290 po test docs
DISTCHECK_CONFIGURE_FLAGS = \
--with-udev-base-dir="$$dc_install_base" \
diff --git a/configure.ac b/configure.ac
index 4e029aff..39751af6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -113,6 +113,9 @@ AC_SUBST(GLIB_MKENUMS)
# GObject Introspection
GOBJECT_INTROSPECTION_CHECK([0.9.6])
+# Vala bindings
+VAPIGEN_CHECK(0.18)
+
# DBus system directory
AC_ARG_WITH(dbus-sys-dir, AS_HELP_STRING([--with-dbus-sys-dir=DIR], [where D-BUS system.d directory is]))
if test -n "$with_dbus_sys_dir" ; then
@@ -294,6 +297,7 @@ docs/reference/libmm-glib/version.xml
libmm-glib/Makefile
libmm-glib/generated/Makefile
libmm-glib/tests/Makefile
+vapi/Makefile
cli/Makefile
])
AC_OUTPUT
@@ -312,6 +316,7 @@ echo "
PolicyKit support: ${with_polkit}
GObject Introspection: ${found_introspection}
+ Vala Bindings: ${enable_vala}
Documentation: ${enable_gtk_doc}
MBIM support: ${with_mbim}
QMI support: ${with_qmi}
diff --git a/vapi/Makefile.am b/vapi/Makefile.am
new file mode 100644
index 00000000..70c063b0
--- /dev/null
+++ b/vapi/Makefile.am
@@ -0,0 +1,22 @@
+VAPIGEN_VAPIS = libmm-glib.vapi
+
+if ENABLE_VAPIGEN
+include $(VAPIGEN_MAKEFILE)
+
+libmm-glib.vapi: $(top_builddir)/libmm-glib/ModemManager-1.0.gir libmm-glib.deps ModemManager-1.0.metadata
+
+libmm_glib_vapi_METADATADIRS = $(srcdir)
+libmm_glib_vapi_FILES = $(top_builddir)/libmm-glib/ModemManager-1.0.gir
+libmm_glib_vapi_VAPIDIRS = $(builddir)
+libmm_glib_vapi_DEPS = gio-2.0
+
+vapidir = $(datadir)/vala/vapi
+vapi_DATA = $(VAPIGEN_VAPIS) $(VAPIGEN_VAPIS:.vapi=.deps)
+
+endif
+
+CLEANFILES = $(VAPIGEN_VAPIS)
+
+EXTRA_DIST = \
+ ModemManager-1.0.metadata \
+ libmm-glib.deps
diff --git a/vapi/ModemManager-1.0.metadata b/vapi/ModemManager-1.0.metadata
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/vapi/ModemManager-1.0.metadata
diff --git a/vapi/libmm-glib.deps b/vapi/libmm-glib.deps
new file mode 100644
index 00000000..cd10dfde
--- /dev/null
+++ b/vapi/libmm-glib.deps
@@ -0,0 +1 @@
+gio-2.0