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

Marc-André Lureau marcandre.lureau at gmail.com
Mon May 21 15:37:47 PDT 2012


Hi

On Sun, May 20, 2012 at 6:34 PM, Uri Lublin <uril at redhat.com> wrote:
> For windows GUDEV is not required
>
> - GUDEV is alwasy checked as part of USBREDIR, and fails
>  if USBREDIR but no GUDEV on non-windows.

misc spelling alwasy/always

> - Added GUDEV env-variables in gtk/Makefile.am

It's a Makefile variable.


> +  # require GUDEV unless os_win32 is true
> +  PKG_CHECK_MODULES([GUDEV],
> +                    [gudev-1.0],
> +                    [have_gudev=yes],
> +                    [have_gudev=no])
> +  if test "x$have_gudev" = "xyes"; then
> +    AC_DEFINE(USE_GUDEV, [1], [Define if supporting gudev])
> +  fi

I guess you could do the check only on non-win32.

>  AM_CONDITIONAL([WITH_USBREDIR], [test "x$have_usbredir" = "xyes"])
> +AM_CONDITIONAL([WITH_GUDEV], [test "x$have_gudev" = "xyes"])

This conditional is 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.

-- 
Marc-André Lureau


More information about the Spice-devel mailing list