From ee3e48825f885e35f32657d6f9807bae30f1357e Mon Sep 17 00:00:00 2001 From: tuibuilder_pel7x64builder0 Date: Thu, 14 Oct 2021 13:58:19 +0200 Subject: [PATCH] hidapi package createion Signed-off-by: tuibuilder_pel7x64builder0 --- SPECS/hidapi.spec | 65 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 SPECS/hidapi.spec diff --git a/SPECS/hidapi.spec b/SPECS/hidapi.spec new file mode 100644 index 0000000..29b3bd9 --- /dev/null +++ b/SPECS/hidapi.spec @@ -0,0 +1,65 @@ +Name: hidapi +Version: 0.10.0 +Release: 1%{?dist} +Summary: Library for communicating with USB and Bluetooth HID devices +License: GPLv3 or BSD +URL: https://github.com/libusb/hidapi +Source0: https://github.com/libusb/hidapi/archive/%{name}-%{version}.tar.gz +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: gcc +BuildRequires: libtool +BuildRequires: libudev-devel +BuildRequires: libusb1-devel +BuildRequires: m4 +BuildRequires: make + + +%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 devel +Summary: Development files for hidapi +Requires: %{name}%{?_isa} = %{version}-%{release} +%description -n hidapi-devel +This package contains development files for hidapi which provides access to +USB and Bluetooth HID-class devices. + + +%prep +%autosetup -n %{name}-%{name}-%{version} + + +%build +autoreconf -vif +%configure --disable-testgui --disable-static +make %{?_smp_mflags} V=1 + + +%install +make install DESTDIR=%{buildroot} +rm -f %{buildroot}%{_libdir}/*.la +rm -rf %{buildroot}%{_defaultdocdir}/%{name} + +%post -p /sbin/ldconfig +%postun -p /sbin/ldconfig + + +%files +%doc AUTHORS.txt README.md LICENSE*.txt +%{_libdir}/libhidapi-*.so.* + + +%files devel +%{_includedir}/hidapi +%{_libdir}/libhidapi-hidraw.so +%{_libdir}/libhidapi-libusb.so +%{_libdir}/pkgconfig/hidapi-hidraw.pc +%{_libdir}/pkgconfig/hidapi-libusb.pc + + +%changelog