commit 8a6de75421a23c75fb18ff1a46ff2b0b31d5e575 Author: ABF Date: Fri Jul 30 07:48:29 2021 +0000 Automatic import for version 0.10.1-1 diff --git a/.abf.yml b/.abf.yml new file mode 100644 index 0000000..0157c06 --- /dev/null +++ b/.abf.yml @@ -0,0 +1,2 @@ +sources: + "hidapi-0.10.1.tar.gz": b89bb4b6c12f697bb4336e57ea12d0b462601d0e diff --git a/hidapi.spec b/hidapi.spec new file mode 100644 index 0000000..255fde2 --- /dev/null +++ b/hidapi.spec @@ -0,0 +1,89 @@ +%define major 0 +%define libhidraw %mklibname %{name}-hidraw %{major} +%define libusb %mklibname %{name}-libusb %{major} +%define devname %mklibname %{name} -d + +Summary: Library for communicating with USB and Bluetooth HID devices +Name: hidapi +Version: 0.10.1 +Release: 1 +License: GPLv3 +Group: Communications +Url: https://github.com/libusb/hidapi +Source0: https://github.com/libusb/hidapi/archive/%{name}-%{version}.tar.gz +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: libtool +BuildRequires: m4 +BuildRequires: pkgconfig(libusb) +BuildRequires: pkgconfig(udev) + +%description +HIDAPI is a multi-platform library which allows an application to interface +with USB and Bluetooth HID-class devices on Windows, Linux, FreeBSD and Mac OS +X. On Linux, either the hidraw or the libusb back-end can be used. There are +trade-offs and the functionality supported is slightly different. + +#------------------------------------------------------------------ + +%package -n %{libhidraw} +Summary: Library files for hidapi +Group: System/Libraries + +%description -n %{libhidraw} +This package contains library files for hidapi which provides access to +USB and Bluetooth HID-class devices. + +%files -n %{libhidraw} +%doc AUTHORS.txt README.md +%{_libdir}/libhidapi-hidraw.so.%{major}* + +#------------------------------------------------------------------ + +%package -n %{libusb} +Summary: Library files for hidapi +Group: System/Libraries + +%description -n %{libusb} +This package contains library files for hidapi which provides access to +USB and Bluetooth HID-class devices. + +%files -n %{libusb} +%doc AUTHORS.txt README.md +%{_libdir}/libhidapi-libusb.so.%{major}* + +#------------------------------------------------------------------ + +%package -n %{devname} +Summary: Development files for hidapi +Group: System/Libraries +Requires: %{libhidraw} = %{EVRD} +Requires: %{libusb} = %{EVRD} +Provides: %{name}-devel = %{EVRD} + +%description -n %{devname} +This package contains development files for hidapi which provides access to +USB and Bluetooth HID-class devices. + +%files -n %{devname} +%{_includedir}/hidapi +%{_libdir}/libhidapi-*.so +%{_libdir}/pkgconfig/hidapi-*.pc + +#------------------------------------------------------------------ + +%prep +%setup -qn %{name}-%{name}-%{version} +%apply_patches + +%build +autoreconf -fi +%configure \ + --disable-testgui \ + --disable-static +%make + +%install +%makeinstall_std + +rm -rf %{buildroot}%{_defaultdocdir}/%{name}