[Spice-devel] [spice-gtk Win32 v2 PATCH 2/5] Windows mingw: usb: configure.ac: do not require GUDEV for USBREDIR

Marc-André Lureau mlureau at redhat.com
Thu May 24 09:36:49 PDT 2012


Hi

----- Mensaje original -----
> What's your point ? This line can be removed from the log message ?
> Before gudev was part of USBREDIR, now it has it's own variables.


Before it was Linux only. Now the gudev check isn't needed for Windows.

> > I guess you could do the check only on non-win32.
> I can, and set have_gudev to "no".
> What's the benefit, smaller running time of configure ?  better
> separation between different tests ?

Configure-time is irrelevant. Running only the necessary checks,
better separation between the various systems checks.

> >> +AM_CONDITIONAL([WITH_GUDEV], [test "x$have_gudev" = "xyes"])
> > This conditional is not needed.
> 
> OK.
> What is the different between WITH_FOO and USE_FOO ?

It's not important. We may use WITH, HAVE, USE or something else.

In general, we use WITH prefix for --with configure checks, and USE
for the rest I think.

In general, WITH is related to a dependency, and USE
is rather for a feature or an enhancement.

Sometime the distinction isn't obvious, sometime it's expressed
differently..

> The rational was "if USBREDIR has one, GUDEV will have one too".

Ok, but there is no automake conditionnal using WITH_GUDEV, hence
it's not needed.

> >> +# for non-win32 usbredir requires gudev
> >> +if test "x$have_usbredir" = "xyes"&&  test "x$have_gudev" =
> >> "xno"&&  \
> >> +  test "x$os_win32" = "xno"; then
> >> +  AC_MSG_ERROR([usbredir requested but required gudev is not
> >> available])
> >> +fi
> >>
> >> If you move the check above, you can print an error there.
> 
> I can do that. What's the benefit ?

Same simplification as described above.


More information about the Spice-devel mailing list