]>
Commit | Line | Data |
---|---|---|
581c6399 JB |
1 | # |
2 | # Conditional build: | |
beede8b7 | 3 | %bcond_without dtls_srtp # DTLS SRTP support |
581c6399 JB |
4 | %bcond_without static_libs # static libraries |
5 | ||
beede8b7 JB |
6 | %if %{with dtls_srtp} |
7 | %define mbedtls_ver 2.26.0-2 | |
8 | %else | |
9 | %define mbedtls_ver 2 | |
10 | %endif | |
82032e80 | 11 | Summary: Utility library for software from Belledonne Communications |
581c6399 | 12 | Summary(pl.UTF-8): Biblioteka narzędziowa dla oprogramowania firmy Belledonne Communications |
82032e80 | 13 | Name: bctoolbox |
beede8b7 JB |
14 | Version: 4.5.15 |
15 | Release: 1 | |
232d9ea8 | 16 | License: GPL v3+ |
82032e80 | 17 | Group: Libraries |
232d9ea8 JB |
18 | #Source0Download: https://gitlab.linphone.org/BC/public/bctoolbox/tags |
19 | Source0: https://gitlab.linphone.org/BC/public/bctoolbox/-/archive/%{version}/%{name}-%{version}.tar.bz2 | |
beede8b7 | 20 | # Source0-md5: 479fd5eaa6242d8622f957744794f541 |
82032e80 | 21 | URL: https://linphone.org/ |
232d9ea8 JB |
22 | # with junit xml support |
23 | BuildRequires: bcunit-devel >= 3.0.2-3.20200822 | |
581c6399 | 24 | BuildRequires: cmake >= 2.8.12 |
232d9ea8 | 25 | BuildRequires: libdecaf-devel |
581c6399 | 26 | BuildRequires: libstdc++-devel >= 6:4.7 |
beede8b7 | 27 | BuildRequires: mbedtls-devel >= %{mbedtls_ver} |
581c6399 | 28 | BuildRequires: sed >= 4.0 |
beede8b7 | 29 | Requires: mbedtls >= %{mbedtls_ver} |
82032e80 AM |
30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
31 | ||
32 | %description | |
33 | Utilities library used by Belledonne Communications softwares like | |
34 | belle-sip, mediastreamer2 and linphone. | |
35 | ||
581c6399 JB |
36 | %description -l pl.UTF-8 |
37 | Biblioteka narzędziowa używana w oprogramowaniu firmy Belledonne | |
38 | Communications, takim jak belle-sip, mediastreamer2 czy linphone. | |
39 | ||
82032e80 | 40 | %package devel |
581c6399 JB |
41 | Summary: Header files for bctoolbox libraries |
42 | Summary(pl.UTF-8): Pliki nagłówkowe bibliotek bctoolbox | |
82032e80 | 43 | Group: Development/Libraries |
581c6399 | 44 | Requires: %{name} = %{version}-%{release} |
232d9ea8 | 45 | Requires: libdecaf-devel |
beede8b7 | 46 | Requires: mbedtls-devel >= %{mbedtls_ver} |
82032e80 AM |
47 | |
48 | %description devel | |
581c6399 JB |
49 | Header files for bctoolbox libraries. |
50 | ||
51 | %description devel -l pl.UTF-8 | |
52 | Pliki nagłówkowe bibliotek bctoolbox. | |
53 | ||
54 | %package static | |
55 | Summary: Static bctoolbox libraries | |
56 | Summary(pl.UTF-8): Statyczne biblioteki bctoolbox | |
57 | Group: Development/Libraries | |
58 | Requires: %{name}-devel = %{version}-%{release} | |
59 | ||
60 | %description static | |
61 | Static bctoolbox libraries. | |
62 | ||
63 | %description static -l pl.UTF-8 | |
64 | Statyczne biblioteki bctoolbox. | |
82032e80 AM |
65 | |
66 | %prep | |
67 | %setup -q | |
68 | ||
69 | %build | |
70 | install -d build | |
71 | cd build | |
581c6399 | 72 | %cmake .. \ |
ef607d11 JB |
73 | %{!?with_static_libs:-DENABLE_STATIC=OFF} \ |
74 | -DENABLE_STRICT=OFF | |
82032e80 AM |
75 | |
76 | %{__make} | |
77 | ||
78 | %install | |
79 | rm -rf $RPM_BUILD_ROOT | |
80 | ||
81 | %{__make} -C build install \ | |
82 | DESTDIR=$RPM_BUILD_ROOT | |
83 | ||
581c6399 | 84 | # disable completeness check incompatible with split packaging |
232d9ea8 | 85 | %{__sed} -i -e '/^foreach(target .*IMPORT_CHECK_TARGETS/,/^endforeach/d; /^unset(_IMPORT_CHECK_TARGETS)/d' $RPM_BUILD_ROOT%{_datadir}/bctoolbox/cmake/bctoolboxTargets.cmake |
581c6399 | 86 | |
82032e80 AM |
87 | %clean |
88 | rm -rf $RPM_BUILD_ROOT | |
89 | ||
581c6399 JB |
90 | %post -p /sbin/ldconfig |
91 | %postun -p /sbin/ldconfig | |
82032e80 AM |
92 | |
93 | %files | |
94 | %defattr(644,root,root,755) | |
232d9ea8 | 95 | %doc CHANGELOG.md README.md |
581c6399 JB |
96 | %attr(755,root,root) %{_libdir}/libbctoolbox.so.1 |
97 | %attr(755,root,root) %{_libdir}/libbctoolbox-tester.so.1 | |
82032e80 AM |
98 | |
99 | %files devel | |
100 | %defattr(644,root,root,755) | |
101 | %attr(755,root,root) %{_libdir}/libbctoolbox.so | |
102 | %attr(755,root,root) %{_libdir}/libbctoolbox-tester.so | |
103 | %{_includedir}/bctoolbox | |
104 | %{_pkgconfigdir}/bctoolbox.pc | |
105 | %{_pkgconfigdir}/bctoolbox-tester.pc | |
581c6399 JB |
106 | %dir %{_datadir}/bctoolbox |
107 | %{_datadir}/bctoolbox/cmake | |
108 | ||
109 | %if %{with static_libs} | |
110 | %files static | |
111 | %defattr(644,root,root,755) | |
112 | %{_libdir}/libbctoolbox.a | |
113 | %{_libdir}/libbctoolbox-tester.a | |
114 | %endif |