Re: [libvirt-designer][PATCH v2 3/4] examples: Create an example of usage program

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 10, 2012 at 03:58:27PM +0200, Michal Privoznik wrote:
> diff --git a/configure.ac b/configure.ac
> index 795990f..bdee845 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -13,6 +13,7 @@ AM_SILENT_RULES([yes])
>  LIBOSINFO_REQUIRED=0.0.5
>  LIBVIRT_GCONFIG_REQUIRED=0.0.9
>  GOBJECT_INTROSPECTION_REQUIRED=0.10.8
> +LIBVIRT_REQUIRED=0.9.0
>  
>  LIBVIRT_DESIGNER_MAJOR_VERSION=`echo $VERSION | awk -F. '{print $1}'`
>  LIBVIRT_DESIGNER_MINOR_VERSION=`echo $VERSION | awk -F. '{print $2}'`
> @@ -30,6 +31,12 @@ AC_SUBST([LIBVIRT_DESIGNER_VERSION_NUMBER])
>  
>  AC_PROG_CC
>  AM_PROG_CC_C_O
> +AC_CHECK_FUNCS([strchr])
> +AC_CHECK_FUNCS([strrchr])
> +AC_CHECK_FUNCS([uname])
> +AC_PROG_CXX
> +AC_PROG_RANLIB
> +AC_TYPE_SIZE_T
>  
>  AC_LIBTOOL_WIN32_DLL
>  AC_PROG_LIBTOOL
> @@ -40,6 +47,7 @@ LIBVIRT_DESIGNER_COMPILE_WARNINGS
>  
>  PKG_CHECK_MODULES(LIBOSINFO, libosinfo-1.0 >= $LIBOSINFO_REQUIRED)
>  PKG_CHECK_MODULES(LIBVIRT_GCONFIG, libvirt-gconfig-1.0 >= $LIBVIRT_GCONFIG_REQUIRED)
> +PKG_CHECK_MODULES(LIBVIRT, libvirt >= $LIBVIRT_REQUIRED)
>  
>  LIBVIRT_DESIGNER_GETTEXT
>  LIBVIRT_DESIGNER_GTK_MISC
> @@ -51,7 +59,8 @@ LIBVIRT_DESIGNER_INTROSPECTION
>  AC_OUTPUT(Makefile
>            libvirt-designer/Makefile
>            libvirt-designer.spec
> -          libvirt-designer-1.0.pc)
> +          libvirt-designer-1.0.pc
> +          examples/Makefile)
>  
>  AC_MSG_NOTICE([])
>  AC_MSG_NOTICE([Configuration summary])
> @@ -62,4 +71,5 @@ AC_MSG_NOTICE([ Libraries:])
>  AC_MSG_NOTICE([])
>  AC_MSG_NOTICE([       LIBOSINFO: $LIBOSINFO_CFLAGS $LIBOSINFO_LIBS])
>  AC_MSG_NOTICE([ LIBVIRT_GCONFIG: $LIBVIRT_GCONFIG_CFLAGS $LIBVIRT_GCONFIG_LIBS])
> +AC_MSG_NOTICE([         LIBVIRT: $LIBVIRT_CFLAGS $LIBVIRT_LIBS])
>  AC_MSG_NOTICE([])

As an enhancement it'd be nice to add a '--enable/disable-examples' argument so
that we keep the ability to build this without needing libvirt available. Indeed
if we make it optional, there's no reason not to use libvirt-gobject for the
example programs - only the library needs to avoid a libvirt/libvirt-gobject
dependency.

Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]