examples: Enable all examples to build on all platforms
authorChris Dickens <christopher.a.dickens@gmail.com>
Tue, 15 Sep 2020 21:15:00 +0000 (14:15 -0700)
committerChris Dickens <christopher.a.dickens@gmail.com>
Tue, 10 Nov 2020 22:13:12 +0000 (14:13 -0800)
commitf69548c3b3340f3e4d9d6f6192451e533ccb2b70
treec500604d062f8d667f1fa66bc3446878e651e94e
parent851ff404003a26c1e3428b9a1332227173cc124b
examples: Enable all examples to build on all platforms

Prior to this change, the dpfp and sam3u_benchmark examples were only
built on POSIX platforms due to a dependency on sigaction(). Furthermore
the dpfp_threaded example only worked with POSIX threads.

Lift this limitation by breaking the dependence on sigaction(). Also
provide a minimal threading abstraction so that dpfp_threaded can be
built on Windows as well.

Also merge the sources for dpfp and dpfp_threaded. The only difference
between the two is how libusb's event handling functions are called and
this can be easily handled within a single source file.

Signed-off-by: Chris Dickens <christopher.a.dickens@gmail.com>
configure.ac
examples/Makefile.am
examples/dpfp.c
examples/dpfp_threaded.c [deleted file]
examples/sam3u_benchmark.c
examples/testlibusb.c [changed mode: 0755->0644]
libusb/version_nano.h