[PATCH 0 of 5] Build and configure cleanups

This patch set started out as just a change to check for a new-enough version of libvirt on the installed system. It evolved into cleaning up a bunch of the package checks in aclocal.m4, a couple of configure cleanups, and a bunch of changes #include statements to account for changes in how we include package directories (which is correct, as of this set, IMHO). Comments and testing on a variety of platforms would be appreciated.

# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1196970729 28800 # Node ID 0a1c811ef3bdc9651166a6259562b7b95f4f7838 # Parent 25193cc30daf4db213e989ee04573b7765785405 [RFC] Cleanup libvirt checks in acinclude.m4 This changes the existing (hard to follow, debug, and change) libvirt detection code with the standard pkg-config method. This gives us an easy version check, as well as access to the package-specified information about CPPFLAGS and LDFLAGS. It also makes us obey the system package search path. Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r 25193cc30daf -r 0a1c811ef3bd acinclude.m4 --- a/acinclude.m4 Thu Dec 06 10:18:26 2007 -0800 +++ b/acinclude.m4 Thu Dec 06 11:52:09 2007 -0800 @@ -297,67 +297,12 @@ AC_DEFUN([CHECK_LIBCU], ] ) -dnl -dnl The check for the libvirt library -dnl Sets the LIBVIRTDIR variable -dnl - -AC_DEFUN([_CHECK_LIBVIRT], -[ - AC_MSG_CHECKING($1) - AC_TRY_LINK( - [ - #include <libvirt.h> - #include <virterror.h> - ], - [ - virConnectPtr connectPtr; - ], - [ - have_LIBVIRT=yes - dnl AC_MSG_RESULT(yes) - ], - [ - have_LIBVIRT=no - dnl AC_MSG_RESULT(no) - ]) -]) - AC_DEFUN([CHECK_LIBVIRT], [ - AC_MSG_CHECKING(for libvirt package) - LIBVIRT_CPP_FLAGS="$CPPFLAGS" - dnl The standard include paths worked. - _CHECK_LIBVIRT(standard) - if test x"$LIBVIRTDIR" == x ; then - _DIRS_="/usr/include/libvirt \ - /usr/local/include/libvirt" - else - _DIRS_="$LIBVIRTDIR/include/libvirt" - fi - for _DIR_ in $_DIRS_ - do - _cppflags=$CPPFLAGS - _include_LIBVIRT="$_DIR_" - CPPFLAGS="$CPPFLAGS -I$_include_LIBVIRT" - _CHECK_LIBVIRT($_DIR_) - if test "$have_LIBVIRT" == "yes"; then - dnl Found it - AC_MSG_RESULT(yes) - dnl Save the new -I parameter - LIBVIRT_CPP_FLAGS="$CPPFLAGS" - LIBLIBVIRT=-lvirt - break - fi - CPPFLAGS=$_cppflags - done - CPPFLAGS=$LIBVIRT_CPP_FLAGS - AC_SUBST(LIBLIBVIRT) - if test "$have_LIBVIRT" == "no"; then - AC_MSG_ERROR(no. The required libvirt package is missing.) - fi - ] -) + PKG_CHECK_MODULES([LIBVIRT], [libvirt >= 0.3.2]) + CPPFLAGS="$CPPFLAGS $LIBVIRT_CFLAGS" + LDFLAGS="$LDFLAGS $LIBVIRT_LIBS" + ]) dnl dnl The check for the SBLIM test suite diff -r 25193cc30daf -r 0a1c811ef3bd autoconfiscate.sh --- a/autoconfiscate.sh Thu Dec 06 10:18:26 2007 -0800 +++ b/autoconfiscate.sh Thu Dec 06 11:52:09 2007 -0800 @@ -18,5 +18,3 @@ autoconf --force && autoconf --force && echo "You may now run ./configure" -echo "You may now run ./configure LIBVIRTDIR=/usr/local" - diff -r 25193cc30daf -r 0a1c811ef3bd configure.ac --- a/configure.ac Thu Dec 06 10:18:26 2007 -0800 +++ b/configure.ac Thu Dec 06 11:52:09 2007 -0800 @@ -31,7 +31,6 @@ AC_ARG_VAR([CIMSERVER],[the target CIM s ]) AC_ARG_VAR([PROVIDERDIR],[the directory where the CMPI providers will be install ed.]) -AC_ARG_VAR([LIBVIRTDIR],[the directory where the libvirt package is installed.]) AC_ARG_VAR([TESTSUITEDIR],[the directory where the SBLIM testsuite is installed. ]) @@ -179,7 +178,6 @@ echo "The following configuration option echo "The following configuration options have been selected:" echo " CIMSERVER: " $CIMSERVER echo " PROVIDERDIR: " $PROVIDERDIR -echo " LIBVIRTDIR: " $LIBVIRTDIR echo " TESTSUITE_SUPPORT: " $TESTSUITE_SUPPORT if test x"$TESTSUITEDIR" != x; then echo " TESTSUITEDIR: " $TESTSUITEDIR

# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1196982077 28800 # Node ID 19fe21b48ba3b5841b80a3a6cccdefd6f3ea5e8d # Parent 0a1c811ef3bdc9651166a6259562b7b95f4f7838 Change libcmpiutil check in configure to use pkg-config Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r 0a1c811ef3bd -r 19fe21b48ba3 acinclude.m4 --- a/acinclude.m4 Thu Dec 06 11:52:09 2007 -0800 +++ b/acinclude.m4 Thu Dec 06 15:01:17 2007 -0800 @@ -259,43 +259,12 @@ AC_DEFUN([CHECK_LIBXML2], ] ) -AC_DEFUN([_CHECK_LIBCU_PC], - [ - if pkg-config --exists libcmpiutil; then - CPPFLAGS="$CPPFLAGS `pkg-config --cflags libcmpiutil`" - LDFLAGS="$LDFLAGS `pkg-config --libs libcmpiutil`" - found_libcu=yes - fi - ] -) - -AC_DEFUN([_CHECK_LIBCU_NOPC], - [ - DIRS="/usr /usr/local" - for dir in $DIRS; do - if test -f "${dir}/include/libcmpiutil/libcmpiutil.h"; then - CPPFLAGS="$CPPFLAGS -I${dir}/include/libcmpiutil" - LDFLAGS="$LDFLAGS -lcmpiutil -L${dir}/lib" - found_libcu=yes - fi - done - ] -) - AC_DEFUN([CHECK_LIBCU], [ - _CHECK_LIBCU_PC - if test "x$found_libcu" != "xyes"; then - _CHECK_LIBCU_NOPC - fi - AC_CHECK_LIB(cmpiutil, cu_check_args, [], [ - AC_MSG_ERROR(libcmpiutil not found) - ]) - AC_CHECK_HEADER([libcmpiutil.h], [], [ - AC_MSG_ERROR([libcmpiutil.h not found]) - ]) - ] -) + PKG_CHECK_MODULES([LIBCU], [libcmpiutil >= 0.1]) + CPPFLAGS="$CPPFLAGS $LIBCU_CFLAGS" + LDFLAGS="$LDFLAGS $LIBCU_LIBS" + ]) AC_DEFUN([CHECK_LIBVIRT], [

# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1196982080 28800 # Node ID d54e71e6c9e2729d8ce7a5074a1ac50dc0dddb40 # Parent 19fe21b48ba3b5841b80a3a6cccdefd6f3ea5e8d Make libxml2 check use pkg-config as well Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r 19fe21b48ba3 -r d54e71e6c9e2 acinclude.m4 --- a/acinclude.m4 Thu Dec 06 15:01:17 2007 -0800 +++ b/acinclude.m4 Thu Dec 06 15:01:20 2007 -0800 @@ -221,43 +221,12 @@ AC_DEFUN([CHECK_CIMSERVER], ] ) -dnl -dnl The check for the libxml2 library -dnl Sets the LIBXML2DIR variable -dnl - -AC_DEFUN([_CHECK_LIBXML2], -[ - AC_MSG_CHECKING($1) - AC_TRY_LINK( - [ - #include <libxml/tree.h> - ], - [ - xmlNodePtr nodeptr; - ], - [ - have_LIBXML2=yes - dnl AC_MSG_RESULT(yes) - ], - [ - have_LIBXML2=no - dnl AC_MSG_RESULT(no) - ]) -]) - AC_DEFUN([CHECK_LIBXML2], [ - AC_MSG_CHECKING(for libxml2 package) - CPPFLAGS="$CPPFLAGS `xml2-config --cflags` " - LDFLAGS="$LDFLAGS `xml2-config --libs` " - dnl The standard include paths worked. - _CHECK_LIBXML2(standard) - if test "$have_LIBXML2" == "no"; then - AC_MSG_ERROR(no. The required libxml2 package is missing.) - fi - ] -) + PKG_CHECK_MODULES([LIBXML], [libxml-2.0]) + CPPFLAGS="$CPPFLAGS $LIBXML_CFLAGS" + LDFLAGS="$LDFLAGS $LIBXML_LDFLAGS" + ]) AC_DEFUN([CHECK_LIBCU], [

# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1196982083 28800 # Node ID 2b0424012e491d751198cd590b03fcf99c0d6978 # Parent d54e71e6c9e2729d8ce7a5074a1ac50dc0dddb40 Clean up configure a little bit Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r d54e71e6c9e2 -r 2b0424012e49 acinclude.m4 --- a/acinclude.m4 Thu Dec 06 15:01:20 2007 -0800 +++ b/acinclude.m4 Thu Dec 06 15:01:23 2007 -0800 @@ -242,47 +242,6 @@ AC_DEFUN([CHECK_LIBVIRT], LDFLAGS="$LDFLAGS $LIBVIRT_LIBS" ]) -dnl -dnl The check for the SBLIM test suite -dnl Sets the TESTSUITEDIR variable and the TESTSUITE conditional -dnl - -AC_DEFUN([CHECK_TESTSUITE], - [ - AC_MSG_CHECKING(for SBLIM testsuite) - _DIRS="$datadir/sblim-testsuite" - save_exec_prefix=${exec_prefix} - save_prefix=${prefix} - if test xNONE == x${prefix}; then - prefix=/usr/local - fi - if test xNONE == x${exec_prefix}; then - exec_prefix=$prefix - fi - for _name in $_DIRS - do - AC_MSG_CHECKING( $_name ) - _xname=`eval echo $_name` - if test -x $_xname/run.sh ; then - dnl Found it - AC_MSG_RESULT(yes) - if test x"$TESTSUITEDIR" == x; then - TESTSUITEDIR=$_name - fi - AC_SUBST(TESTSUITEDIR) - break; - fi - done - if test x"$TESTSUITEDIR" == x ; then - AC_MSG_RESULT(no) - fi - AM_CONDITIONAL(TESTSUITE,[test x"$TESTSUITEDIR" != x]) - exec_prefix=$save_exec_prefix - prefix=$save_prefix - ] -) - - # A convenience macro that spits out a fail message for a particular test # # AC_CHECK_FAIL($LIBNAME,$PACKAGE_SUGGEST,$URL,$EXTRA) diff -r d54e71e6c9e2 -r 2b0424012e49 configure.ac --- a/configure.ac Thu Dec 06 15:01:20 2007 -0800 +++ b/configure.ac Thu Dec 06 15:01:23 2007 -0800 @@ -3,7 +3,6 @@ AC_INIT(libvirt CMPI provider, 0.1, danm AC_INIT(libvirt CMPI provider, 0.1, danms@us.ibm.com, libvirt-cim) AC_CONFIG_SRCDIR([src/Virt_ComputerSystem.c]) -#AC_CONFIG_FILES([xen-kvm-cmpi.spec]) AC_CHECK_HEADERS([stdarg.h errno.h]) AC_CHECK_FUNCS([popen pclose fgets asprintf vfprintf fprintf snprintf sscanf]) @@ -31,8 +30,6 @@ AC_ARG_VAR([CIMSERVER],[the target CIM s ]) AC_ARG_VAR([PROVIDERDIR],[the directory where the CMPI providers will be install ed.]) -AC_ARG_VAR([TESTSUITEDIR],[the directory where the SBLIM testsuite is installed. -]) AC_ARG_WITH([kvm-max-nics], AC_HELP_STRING([--with-kvm-max-nics=X], @@ -98,38 +95,12 @@ AC_CONFIG_FILES([ AM_INIT_AUTOMAKE -# Check for the required C compiler AC_PROG_CC - -# Check for LEX/YACC -AC_PROG_LEX -AC_PROG_YACC - -# Check if the C compiler supports 'const' AC_C_CONST - -# Check for the required libtool AC_PROG_LIBTOOL - -# Check for the required install program AC_PROG_INSTALL - -# Check for some common required headers AC_CHECK_HEADERS([stdlib.h string.h unistd.h]) - -# Check if the system headers conform to ANSI C AC_HEADER_STDC - -# Check for specific add on libraries that we know we'll need -# - libuuid -#AC_CHECK_LIB([uuid], [uuid_generate], [have_uuid=yes], [ -# AC_CHECK_FAIL(libuuid,e2fsprogs-devel) -# ]) - -# - libxenstore -#AC_CHECK_LIB([xenstore], [xs_read], [have_xen=yes], [ -# AC_CHECK_FAIL(libxenstore,xen-devel) -# ]) # Check for the required CMPI header files (this macro is defined in acinclude.m4) CHECK_CMPI @@ -141,25 +112,12 @@ CHECK_PROVIDERDIR # Check for presense of a CIM server (this macro is defined in acinclude.m4) CHECK_CIMSERVER -# Check for presense of libxml2 (this macro defined in acinclude.m4) -AC_CHECK_PROG([found_xml2_config],[xml2-config],[yes]) -AM_CONDITIONAL([found_xml2_config], [test x$found_xml2_config = xyes]) +# Check for presence of libraries +CHECK_LIBVIRT CHECK_LIBXML2 - -# Check for presense of libvirt (this macro is defined in acinclude.m4) -CHECK_LIBVIRT - -# Check for the SBLIM testsuite (this macro is defined in acinclude.m4) -CHECK_TESTSUITE -if test x"$TESTSUITEDIR" == x; then - TESTSUITE_SUPPORT=Disabled -else - TESTSUITE_SUPPORT=Enabled -fi +CHECK_LIBCU CFLAGS_STRICT="-Werror" - -CHECK_LIBCU AC_ARG_ENABLE([werror], [ --enable-werror enable werror on builds [[default=yes]]], @@ -178,10 +136,6 @@ echo "The following configuration option echo "The following configuration options have been selected:" echo " CIMSERVER: " $CIMSERVER echo " PROVIDERDIR: " $PROVIDERDIR -echo " TESTSUITE_SUPPORT: " $TESTSUITE_SUPPORT -if test x"$TESTSUITEDIR" != x; then - echo " TESTSUITEDIR: " $TESTSUITEDIR -fi echo " CPPFLAGS:" $CPPFLAGS echo echo "You can override these values by setting the corresponding" @@ -193,4 +147,3 @@ AC_OUTPUT(libvirt-cim.spec) AC_OUTPUT(libvirt-cim.spec) echo "You may now run make" -

# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1196982085 28800 # Node ID b748848e59942b5c47e1a288ee9070306b138a89 # Parent 2b0424012e491d751198cd590b03fcf99c0d6978 Fixes to header includes for configure changes Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r 2b0424012e49 -r b748848e5994 libxkutil/cs_util_instance.c --- a/libxkutil/cs_util_instance.c Thu Dec 06 15:01:23 2007 -0800 +++ b/libxkutil/cs_util_instance.c Thu Dec 06 15:01:25 2007 -0800 @@ -31,7 +31,7 @@ #include <cmpimacs.h> #include "cs_util.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> int get_domain_list(virConnectPtr conn, virDomainPtr **_list) { diff -r 2b0424012e49 -r b748848e5994 libxkutil/device_parsing.c --- a/libxkutil/device_parsing.c Thu Dec 06 15:01:23 2007 -0800 +++ b/libxkutil/device_parsing.c Thu Dec 06 15:01:25 2007 -0800 @@ -28,7 +28,7 @@ #include <libxml/parser.h> #include <libxml/xpath.h> -#include <libcmpiutil.h> +#include <libcmpiutil/libcmpiutil.h> #include "device_parsing.h" #include "xmlgen.h" diff -r 2b0424012e49 -r b748848e5994 libxkutil/misc_util.c --- a/libxkutil/misc_util.c Thu Dec 06 15:01:23 2007 -0800 +++ b/libxkutil/misc_util.c Thu Dec 06 15:01:25 2007 -0800 @@ -32,8 +32,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "cs_util.h" diff -r 2b0424012e49 -r b748848e5994 libxkutil/misc_util.h --- a/libxkutil/misc_util.h Thu Dec 06 15:01:23 2007 -0800 +++ b/libxkutil/misc_util.h Thu Dec 06 15:01:25 2007 -0800 @@ -31,8 +31,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include <libcmpiutil.h> -#include <std_association.h> +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> /* Check if the provider is reponsible for the given class: * e.g. Xen is running on the system and KVM_... is asked for, diff -r 2b0424012e49 -r b748848e5994 libxkutil/xmlgen.c --- a/libxkutil/xmlgen.c Thu Dec 06 15:01:23 2007 -0800 +++ b/libxkutil/xmlgen.c Thu Dec 06 15:01:25 2007 -0800 @@ -29,7 +29,7 @@ #ifndef TEST #include "misc_util.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "cmpimacs.h" #endif diff -r 2b0424012e49 -r b748848e5994 src/Virt_AllocationCapabilities.c --- a/src/Virt_AllocationCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_AllocationCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -25,8 +25,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ComputerSystem.c --- a/src/Virt_ComputerSystem.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ComputerSystem.c Thu Dec 06 15:01:25 2007 -0800 @@ -28,13 +28,13 @@ #include <cmpift.h> #include <cmpimacs.h> -#include <libvirt.h> +#include <libvirt/libvirt.h> #include "cs_util.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_invokemethod.h" -#include "std_instance.h" +#include <libcmpiutil/std_invokemethod.h> +#include <libcmpiutil/std_instance.h> #include "Virt_ComputerSystem.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ComputerSystemIndication.c --- a/src/Virt_ComputerSystemIndication.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ComputerSystemIndication.c Thu Dec 06 15:01:25 2007 -0800 @@ -32,9 +32,9 @@ #include <libvirt/libvirt.h> -#include <libcmpiutil.h> +#include <libcmpiutil/libcmpiutil.h> #include <misc_util.h> -#include <std_indication.h> +#include <libcmpiutil/std_indication.h> #include <cs_util.h> #include "config.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_Device.c --- a/src/Virt_Device.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_Device.c Thu Dec 06 15:01:25 2007 -0800 @@ -29,8 +29,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "cs_util.h" #include "misc_util.h" #include "device_parsing.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_DevicePool.c --- a/src/Virt_DevicePool.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_DevicePool.c Thu Dec 06 15:01:25 2007 -0800 @@ -38,8 +38,8 @@ #include "hostres.h" #include "device_parsing.h" -#include <libcmpiutil.h> -#include <std_instance.h> +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "Virt_DevicePool.h" #include "svpc_types.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_DevicePool.h --- a/src/Virt_DevicePool.h Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_DevicePool.h Thu Dec 06 15:01:25 2007 -0800 @@ -22,8 +22,8 @@ #define __VIRT_DEVICE_POOL_H #include <cmpidt.h> -#include <libvirt.h> -#include <libcmpiutil.h> +#include <libvirt/libvirt.h> +#include <libcmpiutil/libcmpiutil.h> #include <stdint.h> extern char *device_pool_names[]; diff -r 2b0424012e49 -r b748848e5994 src/Virt_ElementAllocatedFromPool.c --- a/src/Virt_ElementAllocatedFromPool.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ElementAllocatedFromPool.c Thu Dec 06 15:01:25 2007 -0800 @@ -27,8 +27,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "cs_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ElementCapabilities.c --- a/src/Virt_ElementCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ElementCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -28,9 +28,9 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_association.h" +#include <libcmpiutil/std_association.h> #include "Virt_VirtualSystemManagementCapabilities.h" #include "Virt_EnabledLogicalElementCapabilities.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ElementConformsToProfile.c --- a/src/Virt_ElementConformsToProfile.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ElementConformsToProfile.c Thu Dec 06 15:01:25 2007 -0800 @@ -29,10 +29,10 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" #include "profiles.h" -#include "std_association.h" +#include <libcmpiutil/std_association.h> #include "config.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ElementSettingData.c --- a/src/Virt_ElementSettingData.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ElementSettingData.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "Virt_VSSD.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_EnabledLogicalElementCapabilities.c --- a/src/Virt_EnabledLogicalElementCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_EnabledLogicalElementCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" #include "cs_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_HostSystem.c --- a/src/Virt_HostSystem.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_HostSystem.c Thu Dec 06 15:01:25 2007 -0800 @@ -27,8 +27,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_HostedDependency.c --- a/src/Virt_HostedDependency.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_HostedDependency.c Thu Dec 06 15:01:25 2007 -0800 @@ -27,8 +27,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "Virt_ComputerSystem.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_HostedResourcePool.c --- a/src/Virt_HostedResourcePool.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_HostedResourcePool.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,11 +26,11 @@ #include<cmpift.h> #include<cmpimacs.h> -#include <libvirt.h> +#include <libvirt/libvirt.h> -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_association.h" +#include <libcmpiutil/std_association.h> #include "Virt_HostSystem.h" #include "Virt_DevicePool.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_HostedService.c --- a/src/Virt_HostedService.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_HostedService.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "Virt_HostSystem.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_RASD.c --- a/src/Virt_RASD.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_RASD.c Thu Dec 06 15:01:25 2007 -0800 @@ -28,8 +28,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include <libcmpiutil.h> -#include <std_instance.h> +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "device_parsing.h" #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_RegisteredProfile.c --- a/src/Virt_RegisteredProfile.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_RegisteredProfile.c Thu Dec 06 15:01:25 2007 -0800 @@ -29,8 +29,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "cs_util.h" #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ResourceAllocationFromPool.c --- a/src/Virt_ResourceAllocationFromPool.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ResourceAllocationFromPool.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "cs_util.h" #include "device_parsing.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ResourcePoolConfigurationCapabilities.c --- a/src/Virt_ResourcePoolConfigurationCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ResourcePoolConfigurationCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_ResourcePoolConfigurationService.c --- a/src/Virt_ResourcePoolConfigurationService.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_ResourcePoolConfigurationService.c Thu Dec 06 15:01:25 2007 -0800 @@ -22,9 +22,9 @@ #include "cmpift.h" #include "cmpimacs.h" -#include <libcmpiutil.h> -#include <std_invokemethod.h> -#include <std_instance.h> +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_invokemethod.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_SettingsDefineCapabilities.c --- a/src/Virt_SettingsDefineCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_SettingsDefineCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,7 +26,7 @@ #include <sys/vfs.h> #include <errno.h> -#include <libvirt.h> +#include <libvirt/libvirt.h> #include "config.h" @@ -34,9 +34,9 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_association.h" +#include <libcmpiutil/std_association.h> #include "device_parsing.h" #include "svpc_types.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_SettingsDefineState.c --- a/src/Virt_SettingsDefineState.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_SettingsDefineState.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "device_parsing.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_SystemDevice.c --- a/src/Virt_SystemDevice.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_SystemDevice.c Thu Dec 06 15:01:25 2007 -0800 @@ -29,11 +29,11 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "device_parsing.h" #include "misc_util.h" #include "cs_util.h" -#include "std_association.h" +#include <libcmpiutil/std_association.h> #include "Virt_ComputerSystem.h" #include "Virt_Device.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VSMigrationCapabilities.c --- a/src/Virt_VSMigrationCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VSMigrationCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,9 +26,9 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_instance.h" +#include <libcmpiutil/std_instance.h> #include "Virt_VSMigrationCapabilities.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VSMigrationService.c --- a/src/Virt_VSMigrationService.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VSMigrationService.c Thu Dec 06 15:01:25 2007 -0800 @@ -22,16 +22,16 @@ #include <stdlib.h> #include <string.h> -#include <libvirt.h> +#include <libvirt/libvirt.h> #include <cmpidt.h> #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" +#include <libcmpiutil/libcmpiutil.h> #include "misc_util.h" -#include "std_instance.h" -#include "std_invokemethod.h" +#include <libcmpiutil/std_instance.h> +#include <libcmpiutil/std_invokemethod.h> #include "Virt_VSMigrationService.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VSSD.c --- a/src/Virt_VSSD.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VSSD.c Thu Dec 06 15:01:25 2007 -0800 @@ -27,8 +27,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "cs_util.h" #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VSSDComponent.c --- a/src/Virt_VSSDComponent.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VSSDComponent.c Thu Dec 06 15:01:25 2007 -0800 @@ -25,8 +25,8 @@ #include "cmpift.h" #include "cmpimacs.h" -#include "libcmpiutil.h" -#include "std_association.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_association.h> #include "misc_util.h" #include "device_parsing.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VirtualSystemManagementCapabilities.c --- a/src/Virt_VirtualSystemManagementCapabilities.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VirtualSystemManagementCapabilities.c Thu Dec 06 15:01:25 2007 -0800 @@ -26,8 +26,8 @@ #include <cmpift.h> #include <cmpimacs.h> -#include "libcmpiutil.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/Virt_VirtualSystemManagementService.c --- a/src/Virt_VirtualSystemManagementService.c Thu Dec 06 15:01:23 2007 -0800 +++ b/src/Virt_VirtualSystemManagementService.c Thu Dec 06 15:01:25 2007 -0800 @@ -35,10 +35,10 @@ #include "device_parsing.h" #include "xmlgen.h" -#include "libcmpiutil.h" -#include "std_invokemethod.h" -#include "std_indication.h" -#include "std_instance.h" +#include <libcmpiutil/libcmpiutil.h> +#include <libcmpiutil/std_invokemethod.h> +#include <libcmpiutil/std_indication.h> +#include <libcmpiutil/std_instance.h> #include "misc_util.h" diff -r 2b0424012e49 -r b748848e5994 src/svpc_types.h --- a/src/svpc_types.h Thu Dec 06 15:01:23 2007 -0800 +++ b/src/svpc_types.h Thu Dec 06 15:01:25 2007 -0800 @@ -32,7 +32,7 @@ /* Vendor-specific extension; should be documented somewhere */ #define CIM_VSSD_RECOVERY_PRESERVE 123 -#include <libcmpiutil.h> +#include <libcmpiutil/libcmpiutil.h> #include <string.h> static inline char *vssd_recovery_action_str(int action)

Dan Smith wrote:
This patch set started out as just a change to check for a new-enough version of libvirt on the installed system. It evolved into cleaning up a bunch of the package checks in aclocal.m4, a couple of configure cleanups, and a bunch of changes #include statements to account for changes in how we include package directories (which is correct, as of this set, IMHO).
Comments and testing on a variety of platforms would be appreciated.
_______________________________________________ Libvirt-cim mailing list Libvirt-cim@redhat.com https://www.redhat.com/mailman/listinfo/libvirt-cim
Seriously good stuff. As usual, the build/configure stuff isn't really my area of expertise, but taking out a whole pile of m4 macros is always a good thing, and offloading the responsibility to pkg-config seems like a terrific idea. The include cleanups looked good too. +1 -- -Jay
participants (2)
-
Dan Smith
-
Jay Gagnon