mirror of
https://gitlab.freedesktop.org/upower/upower.git
synced 2026-02-04 06:00:26 +01:00
Add initial GObject introspection support
This commit is contained in:
parent
e93895a257
commit
0d7bf34ed6
3 changed files with 34 additions and 5 deletions
|
|
@ -1,5 +1,7 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
ACLOCAL_AMFLAGS = -I m4
|
||||
|
||||
SUBDIRS = devkit-power-gobject src doc tools policy po $(UDEV_RULES)
|
||||
|
||||
DIST_SUBDIRS = devkit-power-gobject src doc tools policy po rules
|
||||
|
|
@ -32,7 +34,7 @@ pkgconfigdir = $(libdir)/pkgconfig
|
|||
pkgconfig_DATA = devkit-power-gobject.pc
|
||||
|
||||
# xsltproc barfs on 'make distcheck'; disable for now
|
||||
DISTCHECK_CONFIGURE_FLAGS=--disable-man-pages --disable-gtk-doc
|
||||
DISTCHECK_CONFIGURE_FLAGS=--disable-man-pages --disable-gtk-doc --enable-introspection
|
||||
|
||||
clean-local :
|
||||
rm -f *~
|
||||
|
|
|
|||
|
|
@ -1,10 +1,13 @@
|
|||
dnl Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_PREREQ(2.59c)
|
||||
AC_PREREQ(2.62)
|
||||
AC_INIT(DeviceKit-power, 015, http://lists.freedesktop.org/mailman/listinfo/devkit-devel)
|
||||
AM_INIT_AUTOMAKE(DeviceKit-power, 015)
|
||||
AM_CONFIG_HEADER(config.h)
|
||||
AM_MAINTAINER_MODE
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
|
||||
GOBJECT_INTROSPECTION_CHECK([0.6.7])
|
||||
|
||||
# enable nice build output on automake1.11
|
||||
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
|
||||
|
|
@ -53,7 +56,7 @@ AC_PATH_PROG([XSLTPROC], [xsltproc])
|
|||
fi
|
||||
AM_CONDITIONAL(MAN_PAGES_ENABLED, test x$enable_man_pages = xyes)
|
||||
|
||||
GTK_DOC_CHECK([1.3])
|
||||
GTK_DOC_CHECK([1.9])
|
||||
|
||||
# udev rules go in /lib, not /usr/lib
|
||||
if test "$prefix" = "/usr" -o "$prefix" = "/usr/local" ; then
|
||||
|
|
|
|||
|
|
@ -8,6 +8,11 @@ INCLUDES = \
|
|||
-DPACKAGE_DATA_DIR=\""$(datadir)"\" \
|
||||
-DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\"
|
||||
|
||||
-include $(INTROSPECTION_MAKEFILE)
|
||||
INTROSPECTION_GIRS =
|
||||
INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir)
|
||||
INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir)
|
||||
|
||||
lib_LTLIBRARIES = \
|
||||
libdevkit-power-gobject.la
|
||||
|
||||
|
|
@ -62,8 +67,27 @@ libdevkit_power_gobject_la_CFLAGS = \
|
|||
EXTRA_DIST = \
|
||||
dkp-version.h.in
|
||||
|
||||
CLEANFILES = $(BUILT_SOURCES)
|
||||
|
||||
if HAVE_INTROSPECTION
|
||||
introspection_sources = $(libdevkit_power_gobject_la_SOURCES)
|
||||
|
||||
DeviceKitPowerGlib-1.0.gir: libdevkit-power-gobject.la
|
||||
DeviceKitPowerGlib_1_0_gir_INCLUDES = GObject-2.0 Gio-2.0
|
||||
DeviceKitPowerGlib_1_0_gir_CFLAGS = $(INCLUDES) -DI_KNOW_THE_DEVICEKIT_POWER_API_IS_SUBJECT_TO_CHANGE
|
||||
DeviceKitPowerGlib_1_0_gir_LIBS = libdevkit-power-gobject.la
|
||||
DeviceKitPowerGlib_1_0_gir_FILES = $(addprefix $(srcdir)/,$(introspection_sources))
|
||||
INTROSPECTION_GIRS += DeviceKitPowerGlib-1.0.gir
|
||||
|
||||
girdir = $(datadir)/gir-1.0
|
||||
dist_gir_DATA = $(INTROSPECTION_GIRS)
|
||||
|
||||
typelibdir = $(libdir)/girepositry-1.0
|
||||
typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
|
||||
|
||||
CLEANFILES += $(dist_gir_DATA) $(typelib_DATA)
|
||||
endif
|
||||
|
||||
clean-local:
|
||||
rm -f *~
|
||||
|
||||
CLEANFILES = $(BUILT_SOURCES)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue