mirror of
https://github.com/libvirt/libvirt.git
synced 2025-01-24 15:26:40 -06:00
Fix Win32 build by linking to ole32
The CoTaskMemFree function requires the ole32 DLL to be linked against. Currently this is only done for the VirtualBox driver. Also add it to libvirt_util.la * configure.ac: Unconditionally add ole32 DLL to Win32 * src/Makefile.am: Link old32 to libvirt_util.la
This commit is contained in:
parent
94618eb66a
commit
7cd77b6b2f
14
configure.ac
14
configure.ac
@ -554,12 +554,6 @@ AC_DEFINE_UNQUOTED([VBOX_XPCOMC_DIR], ["$vbox_xpcomc_dir"],
|
||||
[Location of directory containing VirtualBox XPCOMC library])
|
||||
|
||||
if test "x$with_vbox" = "xyes"; then
|
||||
case "$host" in
|
||||
*-*-mingw* | *-*-msvc*) MSCOM_LIBS="-lole32 -loleaut32" ;;
|
||||
*) MSCOM_LIBS= ;;
|
||||
esac
|
||||
AC_SUBST([MSCOM_LIBS])
|
||||
|
||||
AC_DEFINE_UNQUOTED([WITH_VBOX], 1, [whether VirtualBox driver is enabled])
|
||||
fi
|
||||
AM_CONDITIONAL([WITH_VBOX], [test "$with_vbox" = "yes"])
|
||||
@ -2364,16 +2358,23 @@ MINGW_EXTRA_LDFLAGS=
|
||||
WIN32_EXTRA_CFLAGS=
|
||||
LIBVIRT_SYMBOL_FILE=libvirt.syms
|
||||
LIBVIRT_QEMU_SYMBOL_FILE='$(srcdir)/libvirt_qemu.syms'
|
||||
MSCOM_LIBS=
|
||||
case "$host" in
|
||||
*-*-cygwin*)
|
||||
CYGWIN_EXTRA_LDFLAGS="-no-undefined"
|
||||
CYGWIN_EXTRA_LIBADD="${INTLLIBS}"
|
||||
MSCOM_LIBS="-lole32 -loleaut32"
|
||||
|
||||
if test "x$PYTHON_VERSION" != "x"; then
|
||||
CYGWIN_EXTRA_PYTHON_LIBADD="-L/usr/lib/python${PYTHON_VERSION}/config -lpython${PYTHON_VERSION}"
|
||||
fi
|
||||
;;
|
||||
*-*-mingw*)
|
||||
MINGW_EXTRA_LDFLAGS="-no-undefined"
|
||||
MSCOM_LIBS="-lole32 -loleaut32"
|
||||
;;
|
||||
*-*-msvc*)
|
||||
MSCOM_LIBS="-lole32 -loleaut32"
|
||||
;;
|
||||
esac
|
||||
case "$host" in
|
||||
@ -2406,6 +2407,7 @@ AC_SUBST([WIN32_EXTRA_CFLAGS])
|
||||
AC_SUBST([LIBVIRT_SYMBOL_FILE])
|
||||
AC_SUBST([LIBVIRT_QEMU_SYMBOL_FILE])
|
||||
AC_SUBST([VERSION_SCRIPT_FLAGS])
|
||||
AC_SUBST([MSCOM_LIBS])
|
||||
|
||||
|
||||
dnl Look for windres to build a Windows icon resource.
|
||||
|
@ -583,7 +583,7 @@ libvirt_util_la_CFLAGS = $(CAPNG_CFLAGS) $(YAJL_CFLAGS) $(LIBNL_CFLAGS) \
|
||||
$(DBUS_CFLAGS)
|
||||
libvirt_util_la_LIBADD = $(CAPNG_LIBS) $(YAJL_LIBS) $(LIBNL_LIBS) \
|
||||
$(THREAD_LIBS) $(AUDIT_LIBS) $(DEVMAPPER_LIBS) \
|
||||
$(RT_LIBS) $(DBUS_LIBS)
|
||||
$(RT_LIBS) $(DBUS_LIBS) $(MSCOM_LIBS)
|
||||
|
||||
|
||||
noinst_LTLIBRARIES += libvirt_conf.la
|
||||
|
Loading…
Reference in New Issue
Block a user