From 7bd421feb741efe5e29b3883c34094ba4142f841 Mon Sep 17 00:00:00 2001 From: Jakub Bogusz Date: Sun, 20 May 2018 20:48:42 +0200 Subject: [PATCH] - new; requires openssl 1.1.0 --- libfido2.spec | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 libfido2.spec diff --git a/libfido2.spec b/libfido2.spec new file mode 100644 index 0000000..62f7ac0 --- /dev/null +++ b/libfido2.spec @@ -0,0 +1,77 @@ +Summary: Library functionality for FIDO 2.0, including communication with a device over USB +Summary(pl.UTF-8): Biblioteka funkcji dla FIDO 2.0, wraz z komunikacją z urządzeniem po USB +Name: libfido2 +Version: 0.1.0 +Release: 1 +License: BSD +Group: Libraries +#Source0Download: https://github.com/Yubico/libfido2/releases +Source0: https://github.com/Yubico/libfido2/archive/%{version}/%{name}-%{version}.tar.gz +# Source0-md5: ff1fe068892d16c5922f4774252d94d2 +URL: https://developers.yubico.com/libfido2/ +BuildRequires: cmake >= 3.0 +BuildRequires: hidapi-devel >= 0.8.0 +BuildRequires: libcbor-devel +BuildRequires: openssl-devel >= 1.1.0 +BuildRequires: pkgconfig +Requires: openssl >= 1.1.0 +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) + +%description +This package provides library functionality for communicating with a +FIDO device over USB as well as verifying attestation and assertion +signatures. + +%description -l pl.UTF-8 +Ten pakiet zawiera bibliotekę funkcji do komunikacji z urządzeniami +FIDO po USB, a także weryfikowania podpisów poświadczeń i zapewnień. + +%package devel +Summary: Header files for FIDO2 library +Summary(pl.UTF-8): Pliki nagłówkowe biblioteki FIDO2 +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} +Requires: openssl-devel >= 1.1.0 +Requires: hidapi-devel >= 0.8.0 + +%description devel +Header files for FIDO2 library. + +%description devel -l pl.UTF-8 +Pliki nagłówkowe biblioteki FIDO2. + +%prep +%setup -q + +%build +install -d build +cd build +# note: exects CMAKE_INSTALL_LIBDIR relative to prefix +%cmake .. \ + -DCMAKE_INSTALL_LIBDIR=%{_lib} + +%{__make} + +%install +rm -rf $RPM_BUILD_ROOT + +%{__make} -C build install \ + DESTDIR=$RPM_BUILD_ROOT + +%clean +rm -rf $RPM_BUILD_ROOT + +%post -p /sbin/ldconfig +%postun -p /sbin/ldconfig + +%files +%defattr(644,root,root,755) +%doc LICENSE README.adoc +%attr(755,root,root) %{_libdir}/libfido2.so.*.*.* + +%files devel +%defattr(644,root,root,755) +%attr(755,root,root) %{_libdir}/libfido2.so +%{_includedir}/fido +%{_includedir}/fido.h +%{_pkgconfigdir}/libfido2.pc -- 2.43.0