Hello community, here is the log from the commit of package libgusb for openSUSE:Factory checked in at 2015-07-05 18:00:17 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libgusb (Old) and /work/SRC/openSUSE:Factory/.libgusb.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libgusb" Changes: -------- --- /work/SRC/openSUSE:Factory/libgusb/libgusb.changes 2015-02-27 11:04:06.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.libgusb.new/libgusb.changes 2015-07-05 18:00:19.000000000 +0200 @@ -1,0 +2,9 @@ +Thu Jun 18 13:43:34 UTC 2015 - zai...@opensuse.org + +- Update to version 0.2.5: + + Add g_usb_device_get_custom_index(). + + Allow setting the GMainContext when used for sync methods. + + Include all the USB device class codes. + + Use symbol versioning. + +------------------------------------------------------------------- Old: ---- libgusb-0.2.4.tar.xz New: ---- libgusb-0.2.5.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libgusb.spec ++++++ --- /var/tmp/diff_new_pack.aDteDR/_old 2015-07-05 18:00:19.000000000 +0200 +++ /var/tmp/diff_new_pack.aDteDR/_new 2015-07-05 18:00:19.000000000 +0200 @@ -17,7 +17,7 @@ Name: libgusb -Version: 0.2.4 +Version: 0.2.5 Release: 0 Summary: GObject-based library for libusb1 License: LGPL-2.1+ ++++++ libgusb-0.2.4.tar.xz -> libgusb-0.2.5.tar.xz ++++++ ++++ 2895 lines of diff (skipped) ++++ retrying with extended exclude list diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/NEWS new/libgusb-0.2.5/NEWS --- old/libgusb-0.2.4/NEWS 2015-01-09 16:39:59.000000000 +0100 +++ new/libgusb-0.2.5/NEWS 2015-05-28 10:38:40.000000000 +0200 @@ -1,6 +1,16 @@ +Version 0.2.5 +~~~~~~~~~~~~~ +Released: 2015-05-28 + +New Features: + - Add g_usb_device_get_custom_index() (Richard Hughes) + - Allow setting the GMainContext when used for sync methods (Richard Hughes) + - Include all the USB device class codes (Richard Hughes) + - Use symbol versioning (Pass Automated Testing Suite) + Version 0.2.4 ~~~~~~~~~~~~~ -Released: 2014-01-09 +Released: 2015-01-09 Notes: - Bump glib build requirement to 2.38 (Ignacio Casal Quinteiro) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/build-aux/compile new/libgusb-0.2.5/build-aux/compile --- old/libgusb-0.2.4/build-aux/compile 2015-01-09 16:40:01.000000000 +0100 +++ new/libgusb-0.2.5/build-aux/compile 2015-04-29 10:49:03.000000000 +0200 @@ -3,7 +3,7 @@ scriptversion=2012-10-14.11; # UTC -# Copyright (C) 1999-2013 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # Written by Tom Tromey <tro...@cygnus.com>. # # This program is free software; you can redistribute it and/or modify diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/build-aux/missing new/libgusb-0.2.5/build-aux/missing --- old/libgusb-0.2.4/build-aux/missing 2015-01-09 16:40:01.000000000 +0100 +++ new/libgusb-0.2.5/build-aux/missing 2015-04-29 10:49:03.000000000 +0200 @@ -3,7 +3,7 @@ scriptversion=2013-10-28.13; # UTC -# Copyright (C) 1996-2013 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard <pin...@iro.umontreal.ca>, 1996. # This program is free software; you can redistribute it and/or modify diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/build-aux/test-driver new/libgusb-0.2.5/build-aux/test-driver --- old/libgusb-0.2.4/build-aux/test-driver 2015-01-09 16:40:01.000000000 +0100 +++ new/libgusb-0.2.5/build-aux/test-driver 2015-04-29 10:49:03.000000000 +0200 @@ -3,7 +3,7 @@ scriptversion=2013-07-13.22; # UTC -# Copyright (C) 2011-2013 Free Software Foundation, Inc. +# Copyright (C) 2011-2014 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -106,11 +106,14 @@ # Test script is run here. "$@" >$log_file 2>&1 estatus=$? + if test $enable_hard_errors = no && test $estatus -eq 99; then - estatus=1 + tweaked_estatus=1 +else + tweaked_estatus=$estatus fi -case $estatus:$expect_failure in +case $tweaked_estatus:$expect_failure in 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; 0:*) col=$grn res=PASS recheck=no gcopy=no;; 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; @@ -119,6 +122,12 @@ *:*) col=$red res=FAIL recheck=yes gcopy=yes;; esac +# Report the test outcome and exit status in the logs, so that one can +# know whether the test passed or failed simply by looking at the '.log' +# file, without the need of also peaking into the corresponding '.trs' +# file (automake bug#11814). +echo "$res $test_name (exit status: $estatus)" >>$log_file + # Report outcome to console. echo "${col}${res}${std}: $test_name" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/config.h new/libgusb-0.2.5/config.h --- old/libgusb-0.2.4/config.h 2015-01-09 16:40:03.000000000 +0100 +++ new/libgusb-0.2.5/config.h 2015-04-29 10:49:08.000000000 +0200 @@ -45,7 +45,7 @@ #define PACKAGE_NAME "libgusb" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "libgusb 0.2.4" +#define PACKAGE_STRING "libgusb 0.2.5" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "libgusb" @@ -54,10 +54,10 @@ #define PACKAGE_URL "" /* Define to the version of this package. */ -#define PACKAGE_VERSION "0.2.4" +#define PACKAGE_VERSION "0.2.5" /* Define to 1 if you have the ANSI C header files. */ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.2.4" +#define VERSION "0.2.5" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/configure.ac new/libgusb-0.2.5/configure.ac --- old/libgusb-0.2.4/configure.ac 2015-01-09 16:39:43.000000000 +0100 +++ new/libgusb-0.2.5/configure.ac 2015-05-28 10:37:45.000000000 +0200 @@ -3,7 +3,7 @@ m4_define([gusb_major_version], [0]) m4_define([gusb_minor_version], [2]) -m4_define([gusb_micro_version], [4]) +m4_define([gusb_micro_version], [5]) m4_define([gusb_version], [gusb_major_version.gusb_minor_version.gusb_micro_version]) @@ -41,7 +41,7 @@ # REVISION If the API and ABI remains the same, but bugs are fixed. # AGE Don't use. LT_CURRENT=2 -LT_REVISION=8 +LT_REVISION=9 LT_AGE=0 AC_SUBST(LT_CURRENT) AC_SUBST(LT_REVISION) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/gusb-sections.txt new/libgusb-0.2.5/docs/api/gusb-sections.txt --- old/libgusb-0.2.4/docs/api/gusb-sections.txt 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/gusb-sections.txt 2015-05-28 10:39:50.000000000 +0200 @@ -31,6 +31,7 @@ GUsbDeviceRecipient GUsbDeviceError GUsbDeviceClaimInterfaceFlags +GUsbDeviceClassCode GUsbDevice GUsbDeviceClass g_usb_device_error_quark @@ -50,6 +51,7 @@ g_usb_device_get_manufacturer_index g_usb_device_get_product_index g_usb_device_get_serial_number_index +g_usb_device_get_custom_index g_usb_device_open g_usb_device_close g_usb_device_reset diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/GUsbContext.html new/libgusb-0.2.5/docs/api/html/GUsbContext.html --- old/libgusb-0.2.4/docs/api/html/GUsbContext.html 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/GUsbContext.html 2015-05-28 10:39:50.000000000 +0200 @@ -152,12 +152,12 @@ <tr> <td class="signal_type"><span class="returnvalue">void</span></td> <td class="signal_name"><a class="link" href="GUsbContext.html#GUsbContext-device-added" title="The “device-added” signal">device-added</a></td> -<td class="signal_flags">Run Last</td> +<td class="signal_flags"><a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></td> </tr> <tr> <td class="signal_type"><span class="returnvalue">void</span></td> <td class="signal_name"><a class="link" href="GUsbContext.html#GUsbContext-device-removed" title="The “device-removed” signal">device-removed</a></td> -<td class="signal_flags">Run Last</td> +<td class="signal_flags"><a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></td> </tr> </tbody> </table></div> @@ -319,7 +319,7 @@ g_usb_context_set_debug (<em class="parameter"><code><a class="link" href="GUsbContext.html" title="GUsbContext"><span class="type">GUsbContext</span></a> *context</code></em>, <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Message-Logging.html#GLogLevelFlags"><span class="type">GLogLevelFlags</span></a> flags</code></em>);</pre> <p>Sets the debug flags which control what is logged to the console.</p> -<p>Using <code class="literal">G_LOG_LEVEL_INFO</code> will output to standard out, and everything +<p>Using <a href="https://developer.gnome.org/glib/unstable/glib-Message-Logging.html#G-LOG-LEVEL-INFO:CAPS"><code class="literal">G_LOG_LEVEL_INFO</code></a> will output to standard out, and everything else logs to standard error.</p> <div class="refsect3"> <a name="id-1.3.3.10.6.6"></a><h4>Parameters</h4> @@ -337,7 +337,7 @@ </tr> <tr> <td class="parameter_name"><p>flags</p></td> -<td class="parameter_description"><p>a GLogLevelFlags such as <code class="literal">G_LOG_LEVEL_ERROR</code> | <code class="literal">G_LOG_LEVEL_INFO</code>, or 0</p></td> +<td class="parameter_description"><p>a GLogLevelFlags such as <a href="https://developer.gnome.org/glib/unstable/glib-Message-Logging.html#G-LOG-LEVEL-ERROR:CAPS"><code class="literal">G_LOG_LEVEL_ERROR</code></a> | <a href="https://developer.gnome.org/glib/unstable/glib-Message-Logging.html#G-LOG-LEVEL-INFO:CAPS"><code class="literal">G_LOG_LEVEL_INFO</code></a>, or 0</p></td> <td class="parameter_annotations"> </td> </tr> </tbody> @@ -623,7 +623,7 @@ </tbody> </table></div> </div> -<p>Flags: Run Last</p> +<p>Flags: <a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></p> </div> <hr> <div class="refsect2"> @@ -660,7 +660,7 @@ </tbody> </table></div> </div> -<p>Flags: Run Last</p> +<p>Flags: <a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></p> </div> </div> </div> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/GUsbDevice.html new/libgusb-0.2.5/docs/api/html/GUsbDevice.html --- old/libgusb-0.2.4/docs/api/html/GUsbDevice.html 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/GUsbDevice.html 2015-05-28 10:39:50.000000000 +0200 @@ -177,6 +177,14 @@ </tr> <tr> <td class="function_type"> +<a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="returnvalue">guint8</span></a> +</td> +<td class="function_name"> +<a class="link" href="GUsbDevice.html#g-usb-device-get-custom-index" title="g_usb_device_get_custom_index ()">g_usb_device_get_custom_index</a> <span class="c_punctuation">()</span> +</td> +</tr> +<tr> +<td class="function_type"> <a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> </td> <td class="function_name"> @@ -376,6 +384,10 @@ <td class="function_name"><a class="link" href="GUsbDevice.html#GUsbDeviceClaimInterfaceFlags" title="enum GUsbDeviceClaimInterfaceFlags">GUsbDeviceClaimInterfaceFlags</a></td> </tr> <tr> +<td class="datatype_keyword">enum</td> +<td class="function_name"><a class="link" href="GUsbDevice.html#GUsbDeviceClassCode" title="enum GUsbDeviceClassCode">GUsbDeviceClassCode</a></td> +</tr> +<tr> <td class="datatype_keyword">struct</td> <td class="function_name"><a class="link" href="GUsbDevice.html#GUsbDevice-struct" title="struct GUsbDevice">GUsbDevice</a></td> </tr> @@ -707,7 +719,7 @@ <a name="g-usb-device-get-device-class"></a><h3>g_usb_device_get_device_class ()</h3> <pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="returnvalue">guint8</span></a> g_usb_device_get_device_class (<em class="parameter"><code><a class="link" href="GUsbDevice.html" title="GUsbDevice"><span class="type">GUsbDevice</span></a> *device</code></em>);</pre> -<p>Gets the device class.</p> +<p>Gets the device class, typically a <a class="link" href="GUsbDevice.html#GUsbDeviceClassCode" title="enum GUsbDeviceClassCode"><span class="type">GUsbDeviceClassCode</span></a>.</p> <div class="refsect3"> <a name="id-1.3.5.9.13.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> @@ -874,6 +886,60 @@ </div> <hr> <div class="refsect2"> +<a name="g-usb-device-get-custom-index"></a><h3>g_usb_device_get_custom_index ()</h3> +<pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="returnvalue">guint8</span></a> +g_usb_device_get_custom_index (<em class="parameter"><code><a class="link" href="GUsbDevice.html" title="GUsbDevice"><span class="type">GUsbDevice</span></a> *device</code></em>, + <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="type">guint8</span></a> class_id</code></em>, + <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="type">guint8</span></a> subclass_id</code></em>, + <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#guint8"><span class="type">guint8</span></a> protocol_id</code></em>, + <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> +<p>Gets the string index from the vendor class interface descriptor.</p> +<div class="refsect3"> +<a name="id-1.3.5.9.19.5"></a><h4>Parameters</h4> +<div class="informaltable"><table width="100%" border="0"> +<colgroup> +<col width="150px" class="parameters_name"> +<col class="parameters_description"> +<col width="200px" class="parameters_annotations"> +</colgroup> +<tbody> +<tr> +<td class="parameter_name"><p>device</p></td> +<td class="parameter_description"><p>a <a class="link" href="GUsbDevice.html" title="GUsbDevice"><span class="type">GUsbDevice</span></a></p></td> +<td class="parameter_annotations"> </td> +</tr> +<tr> +<td class="parameter_name"><p>class_id</p></td> +<td class="parameter_description"><p>a device class, e.g. 0xff for VENDOR</p></td> +<td class="parameter_annotations"> </td> +</tr> +<tr> +<td class="parameter_name"><p>subclass_id</p></td> +<td class="parameter_description"><p>a device subclass</p></td> +<td class="parameter_annotations"> </td> +</tr> +<tr> +<td class="parameter_name"><p>protocol_id</p></td> +<td class="parameter_description"><p>a protocol number</p></td> +<td class="parameter_annotations"> </td> +</tr> +<tr> +<td class="parameter_name"><p>error</p></td> +<td class="parameter_description"><p>a <a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a>, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td> +<td class="parameter_annotations"> </td> +</tr> +</tbody> +</table></div> +</div> +<div class="refsect3"> +<a name="id-1.3.5.9.19.6"></a><h4>Returns</h4> +<p> a non-zero index, or 0x00 for failure</p> +<p></p> +</div> +<p class="since">Since 0.2.5</p> +</div> +<hr> +<div class="refsect2"> <a name="g-usb-device-open"></a><h3>g_usb_device_open ()</h3> <pre class="programlisting"><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_usb_device_open (<em class="parameter"><code><a class="link" href="GUsbDevice.html" title="GUsbDevice"><span class="type">GUsbDevice</span></a> *device</code></em>, @@ -881,7 +947,7 @@ <p>Opens the device for use.</p> <p>Warning: this function is synchronous.</p> <div class="refsect3"> -<a name="id-1.3.5.9.19.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.20.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -903,7 +969,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.19.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.20.7"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -917,7 +983,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Closes the device when it is no longer required.</p> <div class="refsect3"> -<a name="id-1.3.5.9.20.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.21.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -939,7 +1005,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.20.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.21.6"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -957,7 +1023,7 @@ rediscovered.</p> <p>This is a blocking function which usually incurs a noticeable delay.</p> <div class="refsect3"> -<a name="id-1.3.5.9.21.7"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.22.7"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -979,7 +1045,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.21.8"></a><h4>Returns</h4> +<a name="id-1.3.5.9.22.8"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -993,7 +1059,7 @@ <p>Get the bConfigurationValue for the active configuration of the device.</p> <p>Warning: this function is synchronous.</p> <div class="refsect3"> -<a name="id-1.3.5.9.22.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.23.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1015,7 +1081,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.22.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.23.7"></a><h4>Returns</h4> <p> The bConfigurationValue of the active config, or -1 on error</p> <p></p> </div> @@ -1031,7 +1097,7 @@ <p>Set the active bConfigurationValue for the device.</p> <p>Warning: this function is synchronous.</p> <div class="refsect3"> -<a name="id-1.3.5.9.23.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.24.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1058,7 +1124,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.23.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.24.7"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1074,7 +1140,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Claim an interface of the device.</p> <div class="refsect3"> -<a name="id-1.3.5.9.24.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.25.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1106,7 +1172,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.24.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.25.6"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1122,7 +1188,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Release an interface of the device.</p> <div class="refsect3"> -<a name="id-1.3.5.9.25.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.26.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1154,7 +1220,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.25.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.26.6"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1170,7 +1236,7 @@ <p>Get a string descriptor from the device. The returned string should be freed with <a href="https://developer.gnome.org/glib/unstable/glib-Memory-Allocation.html#g-free"><code class="function">g_free()</code></a> when no longer needed.</p> <div class="refsect3"> -<a name="id-1.3.5.9.26.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.27.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1192,7 +1258,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.26.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.27.6"></a><h4>Returns</h4> <p> a newly-allocated string holding the descriptor, or NULL on error.</p> <p></p> </div> @@ -1218,7 +1284,7 @@ <p>Perform a USB control transfer.</p> <p>Warning: this function is synchronous, and cannot be cancelled.</p> <div class="refsect3"> -<a name="id-1.3.5.9.27.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.28.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1288,7 +1354,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.27.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.28.7"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1309,7 +1375,7 @@ <p>Perform a USB bulk transfer.</p> <p>Warning: this function is synchronous, and cannot be cancelled.</p> <div class="refsect3"> -<a name="id-1.3.5.9.28.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.29.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1364,7 +1430,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.28.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.29.7"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1385,7 +1451,7 @@ <p>Perform a USB interrupt transfer.</p> <p>Warning: this function is synchronous, and cannot be cancelled.</p> <div class="refsect3"> -<a name="id-1.3.5.9.29.6"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.30.6"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1440,7 +1506,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.29.7"></a><h4>Returns</h4> +<a name="id-1.3.5.9.30.7"></a><h4>Returns</h4> <p> <a href="https://developer.gnome.org/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success</p> <p></p> </div> @@ -1465,7 +1531,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre> <p>Do an async control transfer</p> <div class="refsect3"> -<a name="id-1.3.5.9.30.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.31.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1526,7 +1592,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Gets the result from the asynchronous function.</p> <div class="refsect3"> -<a name="id-1.3.5.9.31.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.32.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1553,7 +1619,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.31.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.32.6"></a><h4>Returns</h4> <p> the actual number of bytes sent, or -1 on error.</p> <p></p> </div> @@ -1573,7 +1639,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre> <p>Do an async bulk transfer</p> <div class="refsect3"> -<a name="id-1.3.5.9.32.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.33.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1639,7 +1705,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Gets the result from the asynchronous function.</p> <div class="refsect3"> -<a name="id-1.3.5.9.33.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.34.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1666,7 +1732,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.33.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.34.6"></a><h4>Returns</h4> <p> the actual number of bytes sent, or -1 on error.</p> <p></p> </div> @@ -1686,7 +1752,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre> <p>Do an async interrupt transfer</p> <div class="refsect3"> -<a name="id-1.3.5.9.34.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.35.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1753,7 +1819,7 @@ <em class="parameter"><code><a href="https://developer.gnome.org/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> <p>Gets the result from the asynchronous function.</p> <div class="refsect3"> -<a name="id-1.3.5.9.35.5"></a><h4>Parameters</h4> +<a name="id-1.3.5.9.36.5"></a><h4>Parameters</h4> <div class="informaltable"><table width="100%" border="0"> <colgroup> <col width="150px" class="parameters_name"> @@ -1780,7 +1846,7 @@ </table></div> </div> <div class="refsect3"> -<a name="id-1.3.5.9.35.6"></a><h4>Returns</h4> +<a name="id-1.3.5.9.36.6"></a><h4>Returns</h4> <p> the actual number of bytes sent, or -1 on error.</p> <p></p> </div> @@ -1985,6 +2051,128 @@ </table></div> </div> </div> +<hr> +<div class="refsect2"> +<a name="GUsbDeviceClassCode"></a><h3>enum GUsbDeviceClassCode</h3> +<p>The USB device class.</p> +<div class="refsect3"> +<a name="id-1.3.5.10.8.4"></a><h4>Members</h4> +<div class="informaltable"><table width="100%" border="0"> +<colgroup> +<col width="300px" class="enum_members_name"> +<col class="enum_members_description"> +<col width="200px" class="enum_members_annotations"> +</colgroup> +<tbody> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-INTERFACE-DESC:CAPS"></a>G_USB_DEVICE_CLASS_INTERFACE_DESC</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-AUDIO:CAPS"></a>G_USB_DEVICE_CLASS_AUDIO</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-COMMUNICATIONS:CAPS"></a>G_USB_DEVICE_CLASS_COMMUNICATIONS</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-HID:CAPS"></a>G_USB_DEVICE_CLASS_HID</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-PHYSICAL:CAPS"></a>G_USB_DEVICE_CLASS_PHYSICAL</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-IMAGE:CAPS"></a>G_USB_DEVICE_CLASS_IMAGE</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-PRINTER:CAPS"></a>G_USB_DEVICE_CLASS_PRINTER</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-MASS-STORAGE:CAPS"></a>G_USB_DEVICE_CLASS_MASS_STORAGE</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-HUB:CAPS"></a>G_USB_DEVICE_CLASS_HUB</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-CDC-DATA:CAPS"></a>G_USB_DEVICE_CLASS_CDC_DATA</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-SMART-CARD:CAPS"></a>G_USB_DEVICE_CLASS_SMART_CARD</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-CONTENT-SECURITY:CAPS"></a>G_USB_DEVICE_CLASS_CONTENT_SECURITY</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-VIDEO:CAPS"></a>G_USB_DEVICE_CLASS_VIDEO</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-PERSONAL-HEALTHCARE:CAPS"></a>G_USB_DEVICE_CLASS_PERSONAL_HEALTHCARE</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-AUDIO-VIDEO:CAPS"></a>G_USB_DEVICE_CLASS_AUDIO_VIDEO</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-BILLBOARD:CAPS"></a>G_USB_DEVICE_CLASS_BILLBOARD</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-DIAGNOSTIC:CAPS"></a>G_USB_DEVICE_CLASS_DIAGNOSTIC</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-WIRELESS-CONTROLLER:CAPS"></a>G_USB_DEVICE_CLASS_WIRELESS_CONTROLLER</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-MISCELLANEOUS:CAPS"></a>G_USB_DEVICE_CLASS_MISCELLANEOUS</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-APPLICATION-SPECIFIC:CAPS"></a>G_USB_DEVICE_CLASS_APPLICATION_SPECIFIC</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +<tr> +<td class="enum_member_name"><p><a name="G-USB-DEVICE-CLASS-VENDOR-SPECIFIC:CAPS"></a>G_USB_DEVICE_CLASS_VENDOR_SPECIFIC</p></td> +<td class="enum_member_description"> </td> +<td class="enum_member_annotations"> </td> +</tr> +</tbody> +</table></div> +</div> +</div> <hr> <div class="refsect2"> <a name="GUsbDevice-struct"></a><h3>struct GUsbDevice</h3> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/GUsbDeviceList.html new/libgusb-0.2.5/docs/api/html/GUsbDeviceList.html --- old/libgusb-0.2.4/docs/api/html/GUsbDeviceList.html 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/GUsbDeviceList.html 2015-05-28 10:39:50.000000000 +0200 @@ -113,12 +113,12 @@ <tr> <td class="signal_type"><span class="returnvalue">void</span></td> <td class="signal_name"><a class="link" href="GUsbDeviceList.html#GUsbDeviceList-device-added" title="The “device-added” signal">device-added</a></td> -<td class="signal_flags">Run Last</td> +<td class="signal_flags"><a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></td> </tr> <tr> <td class="signal_type"><span class="returnvalue">void</span></td> <td class="signal_name"><a class="link" href="GUsbDeviceList.html#GUsbDeviceList-device-removed" title="The “device-removed” signal">device-removed</a></td> -<td class="signal_flags">Run Last</td> +<td class="signal_flags"><a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></td> </tr> </tbody> </table></div> @@ -415,7 +415,7 @@ </tbody> </table></div> </div> -<p>Flags: Run Last</p> +<p>Flags: <a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></p> </div> <hr> <div class="refsect2"> @@ -452,7 +452,7 @@ </tbody> </table></div> </div> -<p>Flags: Run Last</p> +<p>Flags: <a href="https://developer.gnome.org/gobject/unstable/gobject-Signals.html#G-SIGNAL-RUN-LAST:CAPS">Run Last</a></p> </div> </div> </div> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/gusb-gusb-version.html new/libgusb-0.2.5/docs/api/html/gusb-gusb-version.html --- old/libgusb-0.2.4/docs/api/html/gusb-gusb-version.html 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/gusb-gusb-version.html 2015-05-28 10:39:50.000000000 +0200 @@ -101,7 +101,7 @@ <hr> <div class="refsect2"> <a name="G-USB-MICRO-VERSION:CAPS"></a><h3>G_USB_MICRO_VERSION</h3> -<pre class="programlisting">#define G_USB_MICRO_VERSION (4) +<pre class="programlisting">#define G_USB_MICRO_VERSION (5) </pre> <p>The compile-time micro version</p> </div> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/gusb.devhelp2 new/libgusb-0.2.5/docs/api/html/gusb.devhelp2 --- old/libgusb-0.2.4/docs/api/html/gusb.devhelp2 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/gusb.devhelp2 2015-05-28 10:39:50.000000000 +0200 @@ -63,6 +63,7 @@ <keyword type="function" name="g_usb_device_get_manufacturer_index ()" link="GUsbDevice.html#g-usb-device-get-manufacturer-index" since="0.1.0"/> <keyword type="function" name="g_usb_device_get_product_index ()" link="GUsbDevice.html#g-usb-device-get-product-index" since="0.1.0"/> <keyword type="function" name="g_usb_device_get_serial_number_index ()" link="GUsbDevice.html#g-usb-device-get-serial-number-index" since="0.1.0"/> + <keyword type="function" name="g_usb_device_get_custom_index ()" link="GUsbDevice.html#g-usb-device-get-custom-index" since="0.2.5"/> <keyword type="function" name="g_usb_device_open ()" link="GUsbDevice.html#g-usb-device-open" since="0.1.0"/> <keyword type="function" name="g_usb_device_close ()" link="GUsbDevice.html#g-usb-device-close"/> <keyword type="function" name="g_usb_device_reset ()" link="GUsbDevice.html#g-usb-device-reset"/> @@ -86,6 +87,7 @@ <keyword type="enum" name="enum GUsbDeviceRecipient" link="GUsbDevice.html#GUsbDeviceRecipient"/> <keyword type="enum" name="enum GUsbDeviceError" link="GUsbDevice.html#GUsbDeviceError"/> <keyword type="enum" name="enum GUsbDeviceClaimInterfaceFlags" link="GUsbDevice.html#GUsbDeviceClaimInterfaceFlags"/> + <keyword type="enum" name="enum GUsbDeviceClassCode" link="GUsbDevice.html#GUsbDeviceClassCode"/> <keyword type="struct" name="struct GUsbDevice" link="GUsbDevice.html#GUsbDevice-struct"/> <keyword type="struct" name="struct GUsbDeviceClass" link="GUsbDevice.html#GUsbDeviceClass"/> <keyword type="struct" name="GUsbDevicePrivate" link="GUsbDevice.html#GUsbDevicePrivate"/> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/index.html new/libgusb-0.2.5/docs/api/html/index.html --- old/libgusb-0.2.4/docs/api/html/index.html 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/index.html 2015-05-28 10:39:50.000000000 +0200 @@ -23,7 +23,7 @@ </p></div></div> </div></div></div> <div><p class="releaseinfo"> - for GUsb 0.2.4 + for GUsb 0.2.5 </p></div> <div><p class="copyright">Copyright © 2011 Richard Hughes</p></div> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/html/index.sgml new/libgusb-0.2.5/docs/api/html/index.sgml --- old/libgusb-0.2.4/docs/api/html/index.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/html/index.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -64,6 +64,7 @@ <ANCHOR id="g-usb-device-get-manufacturer-index" href="gusb/GUsbDevice.html#g-usb-device-get-manufacturer-index"> <ANCHOR id="g-usb-device-get-product-index" href="gusb/GUsbDevice.html#g-usb-device-get-product-index"> <ANCHOR id="g-usb-device-get-serial-number-index" href="gusb/GUsbDevice.html#g-usb-device-get-serial-number-index"> +<ANCHOR id="g-usb-device-get-custom-index" href="gusb/GUsbDevice.html#g-usb-device-get-custom-index"> <ANCHOR id="g-usb-device-open" href="gusb/GUsbDevice.html#g-usb-device-open"> <ANCHOR id="g-usb-device-close" href="gusb/GUsbDevice.html#g-usb-device-close"> <ANCHOR id="g-usb-device-reset" href="gusb/GUsbDevice.html#g-usb-device-reset"> @@ -88,6 +89,7 @@ <ANCHOR id="GUsbDeviceRecipient" href="gusb/GUsbDevice.html#GUsbDeviceRecipient"> <ANCHOR id="GUsbDeviceError" href="gusb/GUsbDevice.html#GUsbDeviceError"> <ANCHOR id="GUsbDeviceClaimInterfaceFlags" href="gusb/GUsbDevice.html#GUsbDeviceClaimInterfaceFlags"> +<ANCHOR id="GUsbDeviceClassCode" href="gusb/GUsbDevice.html#GUsbDeviceClassCode"> <ANCHOR id="GUsbDevice-struct" href="gusb/GUsbDevice.html#GUsbDevice-struct"> <ANCHOR id="GUsbDeviceClass" href="gusb/GUsbDevice.html#GUsbDeviceClass"> <ANCHOR id="GUsbDevicePrivate" href="gusb/GUsbDevice.html#GUsbDevicePrivate"> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-context.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-context.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-context.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-context.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-device-list.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-device-list.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-device-list.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-device-list.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-device.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-device.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-device.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-device.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> @@ -80,6 +78,33 @@ @G_USB_DEVICE_CLAIM_INTERFACE_BIND_KERNEL_DRIVER: +<!-- ##### ENUM GUsbDeviceClassCode ##### --> +<para> + +</para> + +@G_USB_DEVICE_CLASS_INTERFACE_DESC: +@G_USB_DEVICE_CLASS_AUDIO: +@G_USB_DEVICE_CLASS_COMMUNICATIONS: +@G_USB_DEVICE_CLASS_HID: +@G_USB_DEVICE_CLASS_PHYSICAL: +@G_USB_DEVICE_CLASS_IMAGE: +@G_USB_DEVICE_CLASS_PRINTER: +@G_USB_DEVICE_CLASS_MASS_STORAGE: +@G_USB_DEVICE_CLASS_HUB: +@G_USB_DEVICE_CLASS_CDC_DATA: +@G_USB_DEVICE_CLASS_SMART_CARD: +@G_USB_DEVICE_CLASS_CONTENT_SECURITY: +@G_USB_DEVICE_CLASS_VIDEO: +@G_USB_DEVICE_CLASS_PERSONAL_HEALTHCARE: +@G_USB_DEVICE_CLASS_AUDIO_VIDEO: +@G_USB_DEVICE_CLASS_BILLBOARD: +@G_USB_DEVICE_CLASS_DIAGNOSTIC: +@G_USB_DEVICE_CLASS_WIRELESS_CONTROLLER: +@G_USB_DEVICE_CLASS_MISCELLANEOUS: +@G_USB_DEVICE_CLASS_APPLICATION_SPECIFIC: +@G_USB_DEVICE_CLASS_VENDOR_SPECIFIC: + <!-- ##### STRUCT GUsbDevice ##### --> <para> @@ -261,6 +286,19 @@ @Returns: +<!-- ##### FUNCTION g_usb_device_get_custom_index ##### --> +<para> + +</para> + +@device: +@class_id: +@subclass_id: +@protocol_id: +@error: +@Returns: + + <!-- ##### FUNCTION g_usb_device_open ##### --> <para> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-source.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-source.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-source.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-source.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-unused.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-unused.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-unused.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-unused.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -0,0 +1,6 @@ +<!-- ##### MACRO G_USB_DEVICE_CLASS_VENDOR ##### --> +<para> + +</para> + + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-util.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-util.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-util.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-util.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/tmpl/gusb-version.sgml new/libgusb-0.2.5/docs/api/tmpl/gusb-version.sgml --- old/libgusb-0.2.4/docs/api/tmpl/gusb-version.sgml 2015-01-09 16:40:49.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/tmpl/gusb-version.sgml 2015-05-28 10:39:50.000000000 +0200 @@ -9,13 +9,11 @@ </para> - <!-- ##### SECTION See_Also ##### --> <para> </para> - <!-- ##### SECTION Stability_Level ##### --> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/docs/api/version.xml new/libgusb-0.2.5/docs/api/version.xml --- old/libgusb-0.2.4/docs/api/version.xml 2015-01-09 16:40:02.000000000 +0100 +++ new/libgusb-0.2.5/docs/api/version.xml 2015-05-28 10:38:50.000000000 +0200 @@ -1 +1 @@ -0.2.4 +0.2.5 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/Makefile.am new/libgusb-0.2.5/gusb/Makefile.am --- old/libgusb-0.2.4/gusb/Makefile.am 2015-01-08 12:21:18.000000000 +0100 +++ new/libgusb-0.2.5/gusb/Makefile.am 2015-04-29 17:38:29.000000000 +0200 @@ -45,7 +45,7 @@ -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \ -export-dynamic \ -no-undefined \ - -export-symbols-regex '^g_usb_.*' + -Wl,--version-script=$(top_srcdir)/gusb/libgusb.ver libgusb_la_CFLAGS = \ $(WARNINGFLAGS_C) @@ -109,6 +109,7 @@ endif EXTRA_DIST = \ + libgusb.ver \ gusb-version.h.in \ gusb.pc.in diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-context.c new/libgusb-0.2.5/gusb/gusb-context.c --- old/libgusb-0.2.4/gusb/gusb-context.c 2015-01-08 12:21:18.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-context.c 2015-05-26 22:00:16.000000000 +0200 @@ -55,6 +55,7 @@ **/ struct _GUsbContextPrivate { + GMainContext *main_ctx; GPtrArray *devices; GHashTable *dict_usb_ids; GThread *thread_event; @@ -102,6 +103,7 @@ priv->hotplug_poll_id = 0; } + g_clear_pointer (&priv->main_ctx, g_main_context_unref); g_clear_pointer (&priv->devices, g_ptr_array_unref); g_clear_pointer (&priv->dict_usb_ids, g_hash_table_unref); g_clear_pointer (&priv->ctx, libusb_exit); @@ -399,6 +401,44 @@ return TRUE; } + +/** + * g_usb_context_get_main_context: + * @context: a #GUsbContext + * + * Gets the internal GMainContext to use for syncronous methods. + * By default the value is set to the value of g_main_context_default() + * + * Return value: (transfer none): the #GMainContext + * + * Since: 0.2.5 + **/ +GMainContext * +g_usb_context_get_main_context (GUsbContext *context) +{ + GUsbContextPrivate *priv = context->priv; + return priv->main_ctx; +} + + +/** + * g_usb_context_set_main_context: + * @context: a #GUsbContext + * + * Sets the internal GMainContext to use for syncronous methods. + * + * Since: 0.2.5 + **/ +void +g_usb_context_set_main_context (GUsbContext *context, GMainContext *main_ctx) +{ + GUsbContextPrivate *priv = context->priv; + if (main_ctx != priv->main_ctx){ + g_main_context_unref (priv->main_ctx); + priv->main_ctx = g_main_context_ref (main_ctx); + } +} + /** * g_usb_context_enumerate: * @context: a #GUsbContext @@ -473,6 +513,7 @@ return FALSE; } + priv->main_ctx = g_main_context_ref (g_main_context_default ()); priv->ctx = ctx; priv->thread_event_run = 1; priv->thread_event = g_thread_new ("GUsbEventThread", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-context.h new/libgusb-0.2.5/gusb/gusb-context.h --- old/libgusb-0.2.4/gusb/gusb-context.h 2015-01-05 17:01:56.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-context.h 2015-05-26 21:55:38.000000000 +0200 @@ -71,6 +71,9 @@ G_DEPRECATED GUsbSource *g_usb_context_get_source (GUsbContext *context, GMainContext *main_ctx); +GMainContext *g_usb_context_get_main_context (GUsbContext *context); +void g_usb_context_set_main_context (GUsbContext *context, + GMainContext *main_ctx); void g_usb_context_enumerate (GUsbContext *context); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-device.c new/libgusb-0.2.5/gusb/gusb-device.c --- old/libgusb-0.2.4/gusb/gusb-device.c 2015-01-08 12:21:18.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-device.c 2015-05-26 21:58:09.000000000 +0200 @@ -420,6 +420,64 @@ } /** + * g_usb_device_get_custom_index: + * @device: a #GUsbDevice + * @class_id: a device class, e.g. 0xff for VENDOR + * @subclass_id: a device subclass + * @protocol_id: a protocol number + * @error: a #GError, or %NULL + * + * Gets the string index from the vendor class interface descriptor. + * + * Return value: a non-zero index, or 0x00 for failure + * + * Since: 0.2.5 + **/ +guint8 +g_usb_device_get_custom_index (GUsbDevice *device, + guint8 class_id, + guint8 subclass_id, + guint8 protocol_id, + GError **error) +{ + const struct libusb_interface_descriptor *ifp; + gint rc; + guint8 idx = 0x00; + guint i; + struct libusb_config_descriptor *config; + + rc = libusb_get_active_config_descriptor (device->priv->device, &config); + if (!g_usb_device_libusb_error_to_gerror (device, rc, error)) + return NULL; + + /* find the right data */ + for (i = 0; i < config->bNumInterfaces; i++) { + ifp = &config->interface[i].altsetting[0]; + if (ifp->bInterfaceClass != class_id) + continue; + if (ifp->bInterfaceSubClass != subclass_id) + continue; + if (ifp->bInterfaceProtocol != protocol_id) + continue; + idx = ifp->iInterface; + break; + } + + /* nothing matched */ + if (idx == 0x00) { + g_set_error (error, + G_USB_DEVICE_ERROR, + G_USB_DEVICE_ERROR_NOT_SUPPORTED, + "no vendor descriptor for class 0x%02x, " + "subclass 0x%02x and protocol 0x%02x", + class_id, subclass_id, protocol_id); + } + + libusb_free_config_descriptor (config); + return idx; +} + +/** * g_usb_device_close: * @device: a #GUsbDevice * @error: a #GError, or %NULL @@ -742,7 +800,7 @@ GUsbSyncHelper helper; helper.ret = -1; - helper.context = g_main_context_new (); + helper.context = g_usb_context_get_main_context (device->priv->context); helper.loop = g_main_loop_new (helper.context, FALSE); helper.error = error; helper.finish_func = g_usb_device_control_transfer_finish; @@ -805,7 +863,7 @@ GUsbSyncHelper helper; helper.ret = -1; - helper.context = g_main_context_new (); + helper.context = g_usb_context_get_main_context (device->priv->context); helper.loop = g_main_loop_new (helper.context, FALSE); helper.error = error; helper.finish_func = g_usb_device_bulk_transfer_finish; @@ -863,7 +921,7 @@ GUsbSyncHelper helper; helper.ret = -1; - helper.context = g_main_context_new (); + helper.context = g_usb_context_get_main_context (device->priv->context); helper.loop = g_main_loop_new (helper.context, FALSE); helper.error = error; helper.finish_func = g_usb_device_interrupt_transfer_finish; @@ -1555,7 +1613,7 @@ * g_usb_device_get_device_class: * @device: a #GUsbDevice * - * Gets the device class. + * Gets the device class, typically a #GUsbDeviceClassCode. * * Return value: a device class number, e.g. 0x09 is a USB hub. * diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-device.h new/libgusb-0.2.5/gusb/gusb-device.h --- old/libgusb-0.2.4/gusb/gusb-device.h 2015-01-05 21:00:28.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-device.h 2015-05-05 16:01:11.000000000 +0200 @@ -100,6 +100,35 @@ G_USB_DEVICE_CLAIM_INTERFACE_BIND_KERNEL_DRIVER = 1 << 0, } GUsbDeviceClaimInterfaceFlags; +/** + * GUsbDeviceClassCode: + * + * The USB device class. + **/ +typedef enum { + G_USB_DEVICE_CLASS_INTERFACE_DESC = 0x00, + G_USB_DEVICE_CLASS_AUDIO = 0x01, + G_USB_DEVICE_CLASS_COMMUNICATIONS = 0x02, + G_USB_DEVICE_CLASS_HID = 0x03, + G_USB_DEVICE_CLASS_PHYSICAL = 0x05, + G_USB_DEVICE_CLASS_IMAGE = 0x06, + G_USB_DEVICE_CLASS_PRINTER = 0x07, + G_USB_DEVICE_CLASS_MASS_STORAGE = 0x08, + G_USB_DEVICE_CLASS_HUB = 0x09, + G_USB_DEVICE_CLASS_CDC_DATA = 0x0a, + G_USB_DEVICE_CLASS_SMART_CARD = 0x0b, + G_USB_DEVICE_CLASS_CONTENT_SECURITY = 0x0d, + G_USB_DEVICE_CLASS_VIDEO = 0x0e, + G_USB_DEVICE_CLASS_PERSONAL_HEALTHCARE = 0x0f, + G_USB_DEVICE_CLASS_AUDIO_VIDEO = 0x10, + G_USB_DEVICE_CLASS_BILLBOARD = 0x11, + G_USB_DEVICE_CLASS_DIAGNOSTIC = 0xdc, + G_USB_DEVICE_CLASS_WIRELESS_CONTROLLER = 0xe0, + G_USB_DEVICE_CLASS_MISCELLANEOUS = 0xef, + G_USB_DEVICE_CLASS_APPLICATION_SPECIFIC = 0xfe, + G_USB_DEVICE_CLASS_VENDOR_SPECIFIC = 0xff +} GUsbDeviceClassCode; + struct _GUsbDevice { GObject parent; @@ -139,6 +168,11 @@ guint8 g_usb_device_get_manufacturer_index (GUsbDevice *device); guint8 g_usb_device_get_product_index (GUsbDevice *device); guint8 g_usb_device_get_serial_number_index (GUsbDevice *device); +guint8 g_usb_device_get_custom_index (GUsbDevice *device, + guint8 class_id, + guint8 subclass_id, + guint8 protocol_id, + GError **error); gboolean g_usb_device_open (GUsbDevice *device, GError **error); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-self-test.c new/libgusb-0.2.5/gusb/gusb-self-test.c --- old/libgusb-0.2.4/gusb/gusb-self-test.c 2015-01-08 12:24:33.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-self-test.c 2015-05-26 21:58:43.000000000 +0200 @@ -464,6 +464,65 @@ g_object_unref (ctx); } +static void +gusb_device_ch2_func (void) +{ + GError *error = NULL; + GUsbContext *ctx; + GUsbDevice *device; + gboolean ret; + gchar *tmp = NULL; + guint8 idx; + + ctx = g_usb_context_new (&error); + g_assert_no_error (error); + g_assert (ctx != NULL); + + g_usb_context_set_debug (ctx, G_LOG_LEVEL_ERROR); + + /* coldplug, and get the ColorHug */ + device = g_usb_context_find_by_vid_pid (ctx, + 0x273f, + 0x1004, + &error); + if (device == NULL && + error->domain == G_USB_DEVICE_ERROR && + error->code == G_USB_DEVICE_ERROR_NO_DEVICE) { + g_print ("No device detected!\n"); + g_error_free (error); + goto out; + } + g_assert_no_error (error); + g_assert (device != NULL); + + /* open */ + ret = g_usb_device_open (device, &error); + g_assert_no_error (error); + g_assert (ret); + + /* get vendor data */ + idx = g_usb_device_get_custom_index (device, + G_USB_DEVICE_CLASS_VENDOR_SPECIFIC, + 'F', 'W', &error); + g_assert_no_error (error); + g_assert_cmpint (idx, ==, 3); + + /* get the firmware version */ + tmp = g_usb_device_get_string_descriptor (device, idx, &error); + g_assert_no_error (error); + g_assert_cmpstr (tmp, ==, "2.0.3"); + g_free (tmp); + + /* close */ + ret = g_usb_device_close (device, &error); + g_assert_no_error (error); + g_assert (ret); + + g_object_unref (device); +out: + g_object_unref (ctx); +} + int main (int argc, char **argv) @@ -479,6 +538,7 @@ g_test_add_func ("/gusb/device", gusb_device_func); g_test_add_func ("/gusb/device[huey]", gusb_device_huey_func); g_test_add_func ("/gusb/device[munki]", gusb_device_munki_func); + g_test_add_func ("/gusb/device[colorhug2]", gusb_device_ch2_func); return g_test_run (); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/gusb-version.h new/libgusb-0.2.5/gusb/gusb-version.h --- old/libgusb-0.2.4/gusb/gusb-version.h 2015-01-09 16:40:02.000000000 +0100 +++ new/libgusb-0.2.5/gusb/gusb-version.h 2015-05-28 10:38:50.000000000 +0200 @@ -53,7 +53,7 @@ * * The compile-time micro version */ -#define G_USB_MICRO_VERSION (4) +#define G_USB_MICRO_VERSION (5) /** * G_USB_CHECK_VERSION: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/libgusb-0.2.4/gusb/libgusb.ver new/libgusb-0.2.5/gusb/libgusb.ver --- old/libgusb-0.2.4/gusb/libgusb.ver 1970-01-01 01:00:00.000000000 +0100 +++ new/libgusb-0.2.5/gusb/libgusb.ver 2015-04-29 17:38:29.000000000 +0200 @@ -0,0 +1,40 @@ +LIBGUSB_0.1.0 { + global: + g_usb_*; + local: *; +}; + +LIBGUSB_0.1.1 { + global: + g_usb_device_get_platform_id; +} LIBGUSB_0.1.0; + +LIBGUSB_0.1.7 { + global: + g_usb_device_get_device_class; +} LIBGUSB_0.1.1; + +LIBGUSB_0.2.2 { + global: + g_usb_context_enumerate; + g_usb_context_find_by_bus_address; + g_usb_context_find_by_vid_pid; + g_usb_context_get_devices; +} LIBGUSB_0.1.7; + +LIBGUSB_0.2.4 { + global: + g_usb_device_get_parent; + g_usb_device_get_children; + g_usb_device_get_port_number; + g_usb_device_get_vid_as_str; + g_usb_device_get_pid_as_str; + g_usb_device_get_device_subclass; + g_usb_device_get_device_protocol; + g_usb_context_find_by_platform_id; +} LIBGUSB_0.2.2; + +LIBGUSB_0.2.5 { + global: + g_usb_device_get_custom_index; +} LIBGUSB_0.2.4;