]>
Commit | Line | Data |
---|---|---|
6e8c327a JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # static library | |
4 | # | |
5 | Summary: Belledonne Communications' language recognition library | |
6 | Summary(pl.UTF-8): Biblioteka rozpoznawania języków Belledonne Communications | |
7 | Name: belr | |
8 | Version: 0.1.3 | |
9 | Release: 1 | |
10 | License: GPL v2+ | |
11 | Group: Libraries | |
12 | Source0: https://linphone.org/releases/sources/belr/%{name}-%{version}.tar.gz | |
13 | # Source0-md5: 91dc921d48db2b8337bab56996fe8800 | |
14 | Patch0: %{name}-pc.patch | |
15 | URL: https://linphone.org/ | |
16 | BuildRequires: autoconf >= 2.63 | |
17 | BuildRequires: automake | |
18 | BuildRequires: bctoolbox-devel >= 0.0.3 | |
19 | BuildRequires: libstdc++-devel >= 6:4.7 | |
20 | BuildRequires: libtool >= 2:2 | |
21 | BuildRequires: pkgconfig | |
22 | Requires: bctoolbox >= 0.0.3 | |
23 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
24 | ||
25 | %description | |
26 | Belr is Belledonne Communications' language recognition library. It | |
27 | aims at parsing any input formatted according to a language defined by | |
28 | an ABNF grammar, such as the protocols standardized at IETF. | |
29 | ||
30 | It is based on finite state machine theory and heavily relies on | |
31 | recursivity from an implementation standpoint. | |
32 | ||
33 | %description -l pl.UTF-8 | |
34 | Belr to biblioteka do rozpoznawania języków Belledonne Communications. | |
35 | Jej celem jest analiza dowolnego wejścia sformatowanego zgodnie z | |
36 | językiem zdefiniowanym przez gramatykę ABNF, np. protokołów | |
37 | standaryzowanych przez IETF. | |
38 | ||
39 | Biblioteka jest oparta na teorii automatów skończonych, implementacja | |
40 | znacząco wykorzystuje rekusywność. | |
41 | ||
42 | %package devel | |
43 | Summary: Header files for belr library | |
44 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki belr | |
45 | Group: Development/Libraries | |
46 | Requires: %{name} = %{version}-%{release} | |
47 | Requires: libstdc++-devel >= 6:4.7 | |
48 | ||
49 | %description devel | |
50 | Header files for belr library. | |
51 | ||
52 | %description devel -l pl.UTF-8 | |
53 | Pliki nagłówkowe biblioteki belr. | |
54 | ||
55 | %package static | |
56 | Summary: Static belr library | |
57 | Summary(pl.UTF-8): Statyczna biblioteka belr | |
58 | Group: Development/Libraries | |
59 | Requires: %{name}-devel = %{version}-%{release} | |
60 | ||
61 | %description static | |
62 | Static belr library. | |
63 | ||
64 | %description static -l pl.UTF-8 | |
65 | Statyczna biblioteka belr. | |
66 | ||
67 | %prep | |
68 | %setup -q -n %{name}-%{version}-0 | |
69 | %patch0 -p1 | |
70 | ||
71 | %build | |
72 | %{__libtoolize} | |
73 | %{__aclocal} -I m4 | |
74 | %{__autoconf} | |
75 | %{__autoheader} | |
76 | %{__automake} | |
77 | %configure \ | |
78 | --disable-silent-rules \ | |
79 | %{?with_static_libs:--enable-static} | |
80 | ||
81 | %{__make} | |
82 | ||
83 | %install | |
84 | rm -rf $RPM_BUILD_ROOT | |
85 | ||
86 | %{__make} install \ | |
87 | DESTDIR=$RPM_BUILD_ROOT | |
88 | ||
89 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libbelr.la | |
90 | ||
91 | %clean | |
92 | rm -rf $RPM_BUILD_ROOT | |
93 | ||
94 | %post -p /sbin/ldconfig | |
95 | %postun -p /sbin/ldconfig | |
96 | ||
97 | %files | |
98 | %defattr(644,root,root,755) | |
99 | %doc NEWS README.md | |
100 | %attr(755,root,root) %{_bindir}/belr-parse | |
101 | %attr(755,root,root) %{_libdir}/libbelr.so.*.*.* | |
102 | %attr(755,root,root) %ghost %{_libdir}/libbelr.so.0 | |
103 | ||
104 | %files devel | |
105 | %defattr(644,root,root,755) | |
106 | %attr(755,root,root) %{_libdir}/libbelr.so | |
107 | %{_includedir}/belr | |
108 | %{_pkgconfigdir}/belr.pc | |
109 | ||
110 | %if %{with static_libs} | |
111 | %files static | |
112 | %defattr(644,root,root,755) | |
113 | %{_libdir}/libbelr.a | |
114 | %endif |