libusbx v1.0.9-rc4 is now available

Xiaofan Chen xiaofanc at gmail.com
Fri Mar 30 05:34:07 EDT 2012


On Fri, Mar 30, 2012 at 7:58 AM, Xiaofan Chen <xiaofanc at gmail.com> wrote:
> On Fri, Mar 30, 2012 at 7:54 AM, Pete Batard <pete at akeo.ie> wrote:
>> From git [1] as well as a tarball [2].
>> [1] http://libusbx.git.sourceforge.net/git/gitweb.cgi?p=libusbx/libusbx;a=shortlog
>> [2] https://sourceforge.net/projects/libusbx/files/releases/1.0.9/source/
>
>> Note that the fact that autotools were ran from Windows/MinGW should be
>> irrelevant, especially as I did test that configure/make worked fine on
>> Linux. Of course, it won't hurt to confirm it.
>
> I will carry out some tests of the tar-ball under Windows/Linux/Mac OSX
> and OpenBSD to see if there are any problems. I should be able to
> do the tests over this weekend.
>

First test is carried out under Mac OS X.

Two issues.

1) one compiler warning, better fix
2) not so sure why xusb example default to debug log mode.

mymacmini:libusbx-1.0.9-rc4 xiaofanc$ ./configure --enable-examples-build
checking for a BSD-compatible install... /usr/local/bin/ginstall -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/local/bin/gmkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking build system type... x86_64-apple-darwin11.3.0
checking host system type... x86_64-apple-darwin11.3.0
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc...
/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
checking if the linker
(/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) is GNU
ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm
checking the name lister (/usr/bin/nm) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-apple-darwin11.3.0 file names to
x86_64-apple-darwin11.3.0 format... func_convert_file_noop
checking how to convert x86_64-apple-darwin11.3.0 file names to
toolchain format... func_convert_file_noop
checking for /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
option to reload object files... -r
checking for objdump... no
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm output from gcc object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking for dsymutil... dsymutil
checking for nmedit... nmedit
checking for lipo... lipo
checking for otool... otool
checking for otool64... no
checking for -single_module linker flag... yes
checking for -exported_symbols_list linker flag... yes
checking for -force_load linker flag... yes
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fno-common -DPIC
checking if gcc PIC flag -fno-common -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker
(/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) supports
shared libraries... yes
checking dynamic linker characteristics... darwin11.3.0 dyld
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for windres... no
checking for inline... inline
checking whether gcc and cc understand -c and -o together... yes
checking operating system... Darwin/Mac OS X
checking poll.h usability... yes
checking poll.h presence... yes
checking for poll.h... yes
checking for nfds_t... yes
checking sys/timerfd.h usability... no
checking sys/timerfd.h presence... no
checking for sys/timerfd.h... no
checking whether TFD_NONBLOCK is declared... no
checking whether to use timerfd for timing... no (header not available)
checking for struct timespec... yes
checking for sigaction... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
configure: creating ./config.status
config.status: creating libusb-1.0.pc
config.status: creating Makefile
config.status: creating libusb/Makefile
config.status: creating examples/Makefile
config.status: creating doc/Makefile
config.status: creating doc/doxygen.cfg
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
mymacmini:libusbx-1.0.9-rc4 xiaofanc$ make
make  all-recursive
Making all in libusb
 CC     libusb_1_0_la-core.lo
 CC     libusb_1_0_la-descriptor.lo
 CC     libusb_1_0_la-io.lo
 CC     libusb_1_0_la-sync.lo
 CC     libusb_1_0_la-darwin_usb.lo
os/darwin_usb.c: In function 'darwin_async_io_callback':
os/darwin_usb.c:1550: warning: cast from pointer to integer of different size
 CC     libusb_1_0_la-threads_posix.lo
 CCLD   libusb-1.0.la
Making all in doc
make[2]: Nothing to be done for `all'.
Making all in examples
 CC     listdevs.o
 CCLD   listdevs
 CC     xusb.o
 CCLD   xusb
 CC     dpfp.o
 CCLD   dpfp
 CC     dpfp_threaded-dpfp_threaded.o
 CCLD   dpfp_threaded
make[2]: Nothing to be done for `all-am'.

mymacmini:examples xiaofanc$ ./listdevs
05ac:8006 (bus 250, device 1)
0424:2513 (bus 250, device 2)
04f2:0760 (bus 250, device 5)
05e3:0606 (bus 250, device 4)
04d8:0033 (bus 250, device 6)
046d:c054 (bus 250, device 7)
046d:c52b (bus 250, device 9)
05ac:8006 (bus 253, device 1)
0424:2513 (bus 253, device 2)
05ac:8242 (bus 253, device 3)
0ac8:3420 (bus 253, device 4)

mymacmini:examples xiaofanc$ ./xusb 04d8:0033
Opening device...
libusb:info [process_new_device] allocating new device for location 0xfa000000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 1 at
001-05ac-8006-09-00
libusb:info [process_new_device] allocating new device for location 0xfa100000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 2 at
002-0424-2513-09-00
libusb:info [process_new_device] allocating new device for location 0xfa110000
libusb:info [process_new_device] allocating new device for location 0xfa120000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 5 at
005-04f2-0760-00-00
libusb:info [process_new_device] allocating new device for location 0xfa113000
libusb:warning [darwin_cache_device_descriptor] could not retrieve
device descriptor 05ac:8281: device not responding. skipping device
libusb:info [process_new_device] allocating new device for location 0xfa130000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 4 at
004-05e3-0606-09-00
libusb:info [process_new_device] allocating new device for location 0xfa131000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 6 at
006-04d8-0033-00-00
libusb:info [process_new_device] allocating new device for location 0xfa134000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 7 at
007-046d-c054-00-00
libusb:info [process_new_device] allocating new device for location 0xfa132000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 9 at
009-046d-c52b-00-00
libusb:info [process_new_device] allocating new device for location 0xfd000000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 1 at
001-05ac-8006-09-00
libusb:info [process_new_device] allocating new device for location 0xfd100000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 2 at
002-0424-2513-09-00
libusb:info [process_new_device] allocating new device for location 0xfd110000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 3 at
003-05ac-8242-00-00
libusb:info [process_new_device] allocating new device for location 0xfd130000
libusb:info [darwin_check_configuration] active config: 1, first config: 1
libusb:info [process_new_device] found device with address 4 at
004-0ac8-3420-ef-02
libusb:info [darwin_open] device open for access
speed: 12 Mbit/s (USB 1.0 FullSpeed)

Reading device descriptor:
           length: 18
     device class: 0
              S/N: 3
          VID:PID: 04D8:0033
        bcdDevice: 0002
  iMan:iProd:iSer: 1:2:3
         nb confs: 2

Reading configuration descriptors:
            nb interfaces: 1
             interface[0]: id = 0
interface[0].altsetting[0]: num endpoints = 2
  Class.SubClass.Protocol: 03.00.00
      endpoint[0].address: 81
          max packet size: 0040
         polling interval: 01
      endpoint[1].address: 01
          max packet size: 0040
         polling interval: 01

Claiming interface 0...
libusb:error [darwin_claim_interface] USBInterfaceOpen: another
process has device opened for exclusive access
  Failed.

Reading string descriptors:
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
  String (0x01): "Microchip Technology Inc."
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
  String (0x02): "PICkit 2 Microcontroller Programmer"
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
  String (0x03): "pk2new"
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0
libusb:info [darwin_async_io_callback] an async io operation has completed
libusb:info [op_handle_events] checking fd 4 with revents = 0
libusb:info [op_handle_events] checking fd 6 with revents = 1
libusb:info [darwin_handle_callback] handling control completion with
kernel status 0

Releasing interface 0...
Closing device...
libusb:info [event_thread_main] thread exiting


-- 
Xiaofan



More information about the libusbx mailing list