]>
Commit | Line | Data |
---|---|---|
454ce508 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # stqatic library | |
4 | ||
1af4acd6 | 5 | Summary: Basic API for running protocol decoders |
454ce508 | 6 | Summary(pl.UTF-8): Podstawowe API do uruchamiana dekoderów protokołów |
1af4acd6 | 7 | Name: libsigrokdecode |
5e728119 | 8 | Version: 0.5.3 |
dbefe7ed | 9 | Release: 1 |
1af4acd6 AM |
10 | License: GPL v3+ |
11 | Group: Libraries | |
5e728119 JB |
12 | Source0: https://sigrok.org/download/source/libsigrokdecode/%{name}-%{version}.tar.gz |
13 | # Source0-md5: 7ba4ed4ef1f06ae96979751e096c2821 | |
14 | URL: https://sigrok.org/wiki/Libsigrokdecode | |
36d12350 JB |
15 | BuildRequires: autoconf >= 2.63 |
16 | BuildRequires: automake >= 1:1.11 | |
5e728119 JB |
17 | # for unit tests |
18 | #BuildRequires: check >= 0.9.4 | |
1af4acd6 | 19 | BuildRequires: doxygen |
7088be08 | 20 | BuildRequires: gcc >= 6:4.0 |
5e728119 | 21 | BuildRequires: glib2-devel >= 1:2.34.0 |
321e036a | 22 | BuildRequires: graphviz |
17916784 | 23 | BuildRequires: libstdc++-devel |
36d12350 | 24 | BuildRequires: libtool >= 2:2 |
7088be08 JB |
25 | BuildRequires: pkgconfig >= 1:0.22 |
26 | BuildRequires: python3-devel >= 1:3.2 | |
27 | BuildRequires: python3-modules >= 1:3.2 | |
321e036a | 28 | BuildRequires: rpm-pythonprov |
5e728119 JB |
29 | Requires: glib2 >= 1:2.34.0 |
30 | Requires: python3-modules >= 1:3.2 | |
3e68a4b4 | 31 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
1af4acd6 AM |
32 | |
33 | %description | |
454ce508 JB |
34 | libsigrokdecode is a shared library written in C which provides the |
35 | basic API for running sigrok protocol decoders. The protocol decoders | |
36 | themselves are written in Python. | |
37 | ||
38 | %description -l pl.UTF-8 | |
39 | libsigrokdecode to napisana w C biblioteka współdzielona | |
40 | udostępniająca podstawowe API do uruchamiania dekoderów protokołów | |
41 | sigrok. Same dekodery protokołów są napisane w Pythonie. | |
1af4acd6 AM |
42 | |
43 | %package devel | |
454ce508 JB |
44 | Summary: Development files for libsigrokdecode |
45 | Summary(pl.UTF-8): Pliki programistyczne biblioteki libsigrokdecode | |
1af4acd6 AM |
46 | Group: Development/Libraries |
47 | Requires: %{name} = %{version}-%{release} | |
5e728119 | 48 | Requires: glib2-devel >= 1:2.34.0 |
7088be08 | 49 | Requires: python3-devel >= 1:3.2 |
1af4acd6 AM |
50 | |
51 | %description devel | |
454ce508 JB |
52 | This package contains the header files for developing applications |
53 | that use libsigrokdecode. | |
54 | ||
55 | %description devel -l pl.UTF-8 | |
56 | Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji | |
57 | wykorzystujących bibliotekę libsigrokdecode. | |
58 | ||
59 | %package static | |
60 | Summary: Static libsigrokdecode library | |
61 | Summary(pl.UTF-8): Statyczna biblioteka libsigrokdecode | |
62 | Group: Development/Libraries | |
63 | Requires: %{name}-devel = %{version}-%{release} | |
64 | ||
65 | %description static | |
66 | Static libsigrokdecode library. | |
67 | ||
68 | %description static -l pl.UTF-8 | |
69 | Statyczna biblioteka libsigrokdecode. | |
1af4acd6 AM |
70 | |
71 | %prep | |
72 | %setup -q | |
73 | ||
74 | %build | |
3de4ce63 | 75 | %{__libtoolize} |
36d12350 | 76 | %{__aclocal} -I m4 |
3de4ce63 JR |
77 | %{__autoconf} |
78 | %{__autoheader} | |
79 | %{__automake} | |
1af4acd6 | 80 | %configure \ |
92efd278 | 81 | LDFLAGS="-lpython3 %{rpmldflags}" \ |
454ce508 JB |
82 | --disable-silent-rules \ |
83 | %{!?with_static_libs:--disable-static} | |
1af4acd6 AM |
84 | |
85 | %{__make} | |
86 | ||
87 | # This builds documentation for the -doc package | |
88 | doxygen Doxyfile | |
89 | ||
1af4acd6 AM |
90 | %install |
91 | rm -rf $RPM_BUILD_ROOT | |
1af4acd6 AM |
92 | %{__make} install \ |
93 | DESTDIR=$RPM_BUILD_ROOT | |
94 | ||
321e036a ER |
95 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libsigrokdecode.la |
96 | ||
1af4acd6 AM |
97 | %clean |
98 | rm -rf $RPM_BUILD_ROOT | |
99 | ||
17916784 ER |
100 | %post -p /sbin/ldconfig |
101 | %postun -p /sbin/ldconfig | |
1af4acd6 AM |
102 | |
103 | %files | |
104 | %defattr(644,root,root,755) | |
7088be08 | 105 | %doc ChangeLog NEWS README |
1af4acd6 | 106 | %attr(755,root,root) %{_libdir}/libsigrokdecode.so.*.*.* |
66af9bf7 | 107 | %attr(755,root,root) %ghost %{_libdir}/libsigrokdecode.so.4 |
1af4acd6 AM |
108 | %{_datadir}/libsigrokdecode |
109 | ||
110 | %files devel | |
111 | %defattr(644,root,root,755) | |
7088be08 | 112 | %doc doxy/html-api/* |
1af4acd6 | 113 | %attr(755,root,root) %{_libdir}/libsigrokdecode.so |
454ce508 | 114 | %{_includedir}/libsigrokdecode |
1af4acd6 | 115 | %{_pkgconfigdir}/libsigrokdecode.pc |
454ce508 JB |
116 | |
117 | %if %{with static_libs} | |
118 | %files static | |
119 | %defattr(644,root,root,755) | |
120 | %{_libdir}/libsigrokdecode.a | |
121 | %endif |