]> git.pld-linux.org Git - packages/bzrtp.git/blame - bzrtp.spec
- switched build to cmake to get cmake target files (but still keep .pc file)
[packages/bzrtp.git] / bzrtp.spec
CommitLineData
ff5ec0a1
JB
1#
2# Conditional build:
3%bcond_without static_libs # static library
4#
5Summary: Open source implementation of ZRTP keys exchange protocol
6Summary(pl.UTF-8): Mająca otwarte źródła implementacja protokołu wymiany kluczy ZRTP
7Name: bzrtp
04364f58
JB
8Version: 4.5.15
9Release: 1
1e49e9a9 10License: GPL v3+
ff5ec0a1 11Group: Libraries
1e49e9a9
JB
12#Source0Download: https://gitlab.linphone.org/BC/public/bzrtp/tags
13Source0: https://gitlab.linphone.org/BC/public/bzrtp/-/archive/%{version}/%{name}-%{version}.tar.bz2
04364f58 14# Source0-md5: 67af666eeef27ec7ff6717eb7d0f02c7
0232972c 15Patch0: %{name}-static.patch
ff5ec0a1
JB
16URL: http://www.linphone.org/
17BuildRequires: CUnit
1e49e9a9 18BuildRequires: bctoolbox-devel >= 4.4.0
0232972c 19BuildRequires: cmake >= 3.1
ff5ec0a1 20BuildRequires: libxml2-devel >= 2.0
ff5ec0a1 21BuildRequires: pkgconfig
1e49e9a9 22BuildRequires: rpmbuild(macros) >= 1.748
867d29df 23BuildRequires: sqlite3-devel >= 3.6.0
1e49e9a9 24Requires: bctoolbox >= 4.4.0
867d29df 25Requires: sqlite3 >= 3.6.0
ff5ec0a1
JB
26BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28%description
29bzrtp is an opensource implementation of ZRTP keys exchange protocol.
30The library written in C 89 is fully portable and can be executed on
31many platforms including both ARM processor and x86.
32
33%description -l pl.UTF-8
34bzrtp to mająca otwarte źródła implementacja protokołu wymiany kluczy
35ZRTP. Napisana w C 89 biblioteka jest w pełni przenośna i może być
36wykonywana na wielu platformach, w tym ARM oraz x86.
37
38%package devel
39Summary: Header file for bzrtp library
40Summary(pl.UTF-8): Plik nagłówkowy biblioteki bzrtp
41Group: Development/Libraries
42Requires: %{name} = %{version}-%{release}
43
44%description devel
45Header file for bzrtp library.
46
47%description devel -l pl.UTF-8
48Plik nagłówkowy biblioteki bzrtp.
49
50%package static
51Summary: Static bzrtp library
52Summary(pl.UTF-8): Statyczna biblioteka bzrtp
53Group: Development/Libraries
54Requires: %{name}-devel = %{version}-%{release}
55
56%description static
57Static bzrtp library.
58
59%description static -l pl.UTF-8
60Statyczna biblioteka bzrtp.
61
62%prep
63%setup -q
0232972c 64%patch0 -p1
ff5ec0a1
JB
65
66%build
0232972c
JB
67install -d build
68cd build
69%cmake .. \
70 %{!?with_static_libs:-DENABLE_STATIC=OFF}
ff5ec0a1
JB
71
72%{__make}
73
74%install
75rm -rf $RPM_BUILD_ROOT
76
0232972c 77%{__make} -C build install \
ff5ec0a1
JB
78 DESTDIR=$RPM_BUILD_ROOT
79
0232972c
JB
80# disable completeness check incompatible with split packaging
81%{__sed} -i -e '/^foreach(target .*IMPORT_CHECK_TARGETS/,/^endforeach/d; /^unset(_IMPORT_CHECK_TARGETS)/d' $RPM_BUILD_ROOT%{_datadir}/bzrtp/cmake/bzrtpTargets.cmake
82
83# missing from cmake
84test ! -f $RPM_BUILD_ROOT%{_pkgconfigdir}/libbzrtp.pc
85install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
86%{__sed} -e 's,@prefix@,%{_prefix},' \
87 -e 's,@exec_prefix@,%{_exec_prefix},' \
88 -e 's,@includedir@,%{_includedir},' \
89 -e 's,@PACKAGE_VERSION@,%{version},' \
90 -e 's,@libdir@,%{_libdir},' libbzrtp.pc.in >$RPM_BUILD_ROOT%{_pkgconfigdir}/libbzrtp.pc
ff5ec0a1
JB
91
92%clean
93rm -rf $RPM_BUILD_ROOT
94
95%post -p /sbin/ldconfig
96%postun -p /sbin/ldconfig
97
98%files
99%defattr(644,root,root,755)
1e49e9a9 100%doc CHANGELOG.md README.md
0232972c 101%attr(755,root,root) %{_libdir}/libbzrtp.so.0
ff5ec0a1
JB
102
103%files devel
104%defattr(644,root,root,755)
105%attr(755,root,root) %{_libdir}/libbzrtp.so
106%{_includedir}/bzrtp
107%{_pkgconfigdir}/libbzrtp.pc
0232972c
JB
108%dir %{_datadir}/bzrtp
109%{_datadir}/bzrtp/cmake
ff5ec0a1
JB
110
111%if %{with static_libs}
112%files static
113%defattr(644,root,root,755)
114%{_libdir}/libbzrtp.a
115%endif
This page took 0.112129 seconds and 4 git commands to generate.