]> git.pld-linux.org Git - packages/libu2f-host.git/blob - libu2f-host.spec
927c464a8dea56bd3bbcc62fdb4ccea6e1092098
[packages/libu2f-host.git] / libu2f-host.spec
1 #
2 # Conditional build:
3 %bcond_without  apidocs         # gtk-doc API documentation
4 %bcond_without  static_libs     # static library
5 #
6 Summary:        Yubico Universal 2nd Factor (U2F) Host C Library
7 Summary(pl.UTF-8):      Biblioteka C hosta Universal 2nd Factor (U2F) Yubico
8 Name:           libu2f-host
9 Version:        1.1.6
10 Release:        1
11 License:        LGPL v2.1+ (library and tool), GPL v3+ (tests)
12 Group:          Libraries
13 Source0:        https://developers.yubico.com/libu2f-host/Releases/%{name}-%{version}.tar.xz
14 # Source0-md5:  2af0c9df26e290bb35b7f154b835ce8c
15 URL:            https://developers.yubico.com/libu2f-host/
16 BuildRequires:  gtk-doc >= 1.1
17 BuildRequires:  help2man
18 BuildRequires:  hidapi-devel >= 0.8.0
19 BuildRequires:  json-c-devel
20 BuildRequires:  pkgconfig
21 BuildRequires:  tar >= 1:1.22
22 BuildRequires:  udev-devel >= 1:188
23 BuildRequires:  xz
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %description
27 Libu2f-host provides a C library and command-line tool that implements
28 the host-side of the U2F protocol. There are APIs to talk to a U2F
29 device and perform the U2F Register and U2F Authenticate operations.
30
31 %description -l pl.UTF-8
32 Ten pakiet zawiera bibliotekę C libu2f-host oraz narzędzie linii
33 poleceń implementujące stronę hosta protokołu U2F. Biblioteka zawiera
34 API do komunikacji z urządzeniem U2F oraz wykonywania operacji U2F
35 Register i U2F Authenticate.
36
37 %package devel
38 Summary:        Header files for libu2f-host library
39 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki libu2f-host
40 License:        LGPL v2.1+
41 Group:          Development/Libraries
42 Requires:       %{name} = %{version}-%{release}
43
44 %description devel
45 Header files for libu2f-host library.
46
47 %description devel -l pl.UTF-8
48 Pliki nagłówkowe biblioteki libu2f-host.
49
50 %package static
51 Summary:        Static libu2f-host library
52 Summary(pl.UTF-8):      Statyczna biblioteka libu2f-host
53 License:        LGPL v2.1+
54 Group:          Development/Libraries
55 Requires:       %{name}-devel = %{version}-%{release}
56
57 %description static
58 Static libu2f-host library.
59
60 %description static -l pl.UTF-8
61 Statyczna biblioteka libu2f-host.
62
63 %package apidocs
64 Summary:        API documentation for libu2f-host library
65 Summary(pl.UTF-8):      Dokumentacja API biblioteki libu2f-host
66 License:        LGPL v2.1+
67 Group:          Documentation
68 %if "%{_rpmversion}" >= "5"
69 BuildArch:      noarch
70 %endif
71
72 %description apidocs
73 API documentation for libu2f-host library.
74
75 %description apidocs -l pl.UTF-8
76 Dokumentacja API biblioteki libu2f-host.
77
78 %prep
79 %setup -q
80
81 %build
82 %configure \
83         --disable-silent-rules \
84         %{!?with_static_libs:--disable-static} \
85         --with-html-dir=%{_gtkdocdir} \
86         --with-udevrulesdir=/lib/udev/rules.d
87 %{__make}
88
89 %install
90 rm -rf $RPM_BUILD_ROOT
91
92 %{__make} install \
93         DESTDIR=$RPM_BUILD_ROOT
94
95 # obsoleted by pkg-config
96 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libu2f-host.la
97
98 %clean
99 rm -rf $RPM_BUILD_ROOT
100
101 %post   -p /sbin/ldconfig
102 %postun -p /sbin/ldconfig
103
104 %files
105 %defattr(644,root,root,755)
106 %doc AUTHORS ChangeLog NEWS README THANKS doc/*.adoc
107 %attr(755,root,root) %{_bindir}/u2f-host
108 %attr(755,root,root) %{_libdir}/libu2f-host.so.*.*.*
109 %attr(755,root,root) %ghost %{_libdir}/libu2f-host.so.0
110 /lib/udev/rules.d/70-u2f.rules
111 %{_mandir}/man1/u2f-host.1*
112
113 %files devel
114 %defattr(644,root,root,755)
115 %attr(755,root,root) %{_libdir}/libu2f-host.so
116 %{_includedir}/u2f-host
117 %{_pkgconfigdir}/u2f-host.pc
118
119 %if %{with static_libs}
120 %files static
121 %defattr(644,root,root,755)
122 %{_libdir}/libu2f-host.a
123 %endif
124
125 %if %{with apidocs}
126 %files apidocs
127 %defattr(644,root,root,755)
128 %{_gtkdocdir}/u2f-host
129 %endif
This page took 0.062623 seconds and 2 git commands to generate.