http://bugs.winehq.org/show_bug.cgi?id=33780
Bug #: 33780 Summary: configure --without-xml --with-dbus fails because of bad AC_REQUIRE logic Product: Wine Version: 1.6-rc1 Platform: x86-64 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: build-env AssignedTo: wine-bugs@winehq.org ReportedBy: tetromino@gentoo.org Classification: Unclassified
(originally reported at https://bugs.gentoo.org/show_bug.cgi?id=470172)
WINE_PACKAGE_FLAGS is defined in aclocal.m4 as
AC_DEFUN([WINE_PACKAGE_FLAGS], [AC_REQUIRE([WINE_PATH_PKG_CONFIG])dnl AC_ARG_VAR([$1]_CFLAGS, [C compiler flags for $2, overriding pkg-config])dnl ...
Now, AC_REQUIRE expands its argument *only on the first occurrence of the macro*. In other words, WINE_PATH_PKG_CONFIG gets expanded only once - at the first invocation of WINE_PACKAGE_FLAGS! And that invocation happens to be inside a shell conditional expression.
The logic in configure is essentially
if test "x$with_xml" != "xno"; then WINE_PACKAGE_FLAGS(XML2, ...) fi if test "x$with_dbus" != "xno"; then WINE_PACKAGE_FLAGS(DBUS, ...) fi
which gets expanded to
if test "x$with_xml" != "xno"; then <check for pkg-config and set PKG_CONFIG> <check for libxml-2.0.pc using $PKG_CONFIG> fi if test "x$with_dbus" != "xno"; then <check for dbus-1.pc using $PKG_CONFIG> fi
As a result, ./configure --without-xml --with-dbus always fails:
checking dbus/dbus.h presence... no checking for dbus/dbus.h... no configure: error: libdbus development files not found, no dynamic device support. This is an error since --with-dbus was requested.
http://bugs.winehq.org/show_bug.cgi?id=33780
Alexandre Rostovtsev tetromino@gentoo.org changed:
What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.gentoo.org/sho | |w_bug.cgi?id=470172
http://bugs.winehq.org/show_bug.cgi?id=33780
--- Comment #1 from Alexandre Rostovtsev tetromino@gentoo.org 2013-06-10 22:40:09 CDT --- Created attachment 44746 --> http://bugs.winehq.org/attachment.cgi?id=44746 proposed patch
http://bugs.winehq.org/show_bug.cgi?id=33780
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |21f2c0e6e709cccadf2db4dd45f | |edc478fc91e6b Status|UNCONFIRMED |RESOLVED Resolution| |FIXED
--- Comment #2 from Austin English austinenglish@gmail.com 2013-06-11 14:42:43 CDT --- http://source.winehq.org/git/wine.git/commitdiff/21f2c0e6e709cccadf2db4dd45f...
thanks!
http://bugs.winehq.org/show_bug.cgi?id=33780
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #3 from Alexandre Julliard julliard@winehq.org 2013-06-14 13:24:55 CDT --- Closing bugs fixed in 1.6-rc2.