blob: 92e66b1b160c2d0f9c7e3d39ed46d7b28010bfa4 [file] [log] [blame]
Andrew Geissler82c905d2020-04-13 13:39:40 -05001SUMMARY = "Userspace library to access USB (version 1.0)"
Andrew Geissler90fd73c2021-03-05 15:25:55 -06002DESCRIPTION = "A cross-platform library to access USB devices from Linux, \
3macOS, Windows, OpenBSD/NetBSD, Haiku and Solaris userspace."
Andrew Geissler82c905d2020-04-13 13:39:40 -05004HOMEPAGE = "http://libusb.sf.net"
5BUGTRACKER = "http://www.libusb.org/report"
6SECTION = "libs"
7
8LICENSE = "LGPLv2.1+"
9LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
10
11BBCLASSEXTEND = "native nativesdk"
12
13SRC_URI = "${SOURCEFORGE_MIRROR}/libusb/libusb-${PV}.tar.bz2 \
14 file://run-ptest \
15 "
16
Andrew Geisslerd1e89492021-02-12 15:35:20 -060017SRC_URI[sha256sum] = "7efd2685f7b327326dcfb85cee426d9b871fd70e22caa15bb68d595ce2a2b12a"
Andrew Geissler82c905d2020-04-13 13:39:40 -050018
19S = "${WORKDIR}/libusb-${PV}"
20
21inherit autotools pkgconfig ptest
22
23PACKAGECONFIG_class-target ??= "udev"
24PACKAGECONFIG[udev] = "--enable-udev,--disable-udev,udev"
25
26EXTRA_OECONF = "--libdir=${base_libdir}"
27
28do_install_append() {
29 install -d ${D}${libdir}
30 if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
31 mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
32 fi
33}
34
35do_compile_ptest() {
36 oe_runmake -C tests stress
37}
38
39do_install_ptest() {
40 install -m 755 ${B}/tests/.libs/stress ${D}${PTEST_PATH}
41}
42
43FILES_${PN} += "${base_libdir}/*.so.*"
44
45FILES_${PN}-dev += "${base_libdir}/*.so ${base_libdir}/*.la"