]> git.pld-linux.org Git - packages/ortp.git/blob - ortp.spec
9931751c5036383808863cbfe29995b969cdfcee
[packages/ortp.git] / ortp.spec
1 #
2 # Conditional build:
3 %bcond_without  static_libs     # Static library
4 #
5 Summary:        RTP/RTCP protocol library
6 Summary(pl.UTF-8):      Biblioteka obsługująca protokół RTP/RTCP
7 Name:           ortp
8 Version:        4.5.15
9 Release:        1
10 License:        GPL v3+
11 Group:          Libraries
12 #Source0Download: https://gitlab.linphone.org/BC/public/ortp/tags
13 Source0:        https://gitlab.linphone.org/BC/public/ortp/-/archive/%{version}/%{name}-%{version}.tar.bz2
14 # Source0-md5:  e03716372f79b5fdcd1c5e9c3918fcde
15 Patch0:         %{name}-am.patch
16 Patch1:         %{name}-pc.patch
17 URL:            http://www.linphone.org/technical-corner/ortp
18 BuildRequires:  bctoolbox-devel >= 0.2.0
19 BuildRequires:  cmake >= 3.1
20 BuildRequires:  doxygen
21 BuildRequires:  libstdc++-devel
22 BuildRequires:  openssl-devel
23 BuildRequires:  pkgconfig
24 BuildRequires:  rpm-build >= 4.6
25 BuildRequires:  rpmbuild(macros) >= 1.605
26 Requires:       bctoolbox >= 0.2.0
27 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
29 %define         specflags       -fno-strict-aliasing
30
31 %description
32 ortp is a library for handling RTP protocol (RFC 3550).
33
34 %description -l pl.UTF-8
35 ortp to biblioteka obsługująca protokół RTP (RFC 3550).
36
37 %package devel
38 Summary:        Header files to develop applications using ortp
39 Summary(pl.UTF-8):      Pliki nagłówkowe do tworzenia aplikacji używających ortp
40 Group:          Development/Libraries
41 Requires:       %{name} = %{version}-%{release}
42 Requires:       bctoolbox-devel >= 0.2.0
43 Requires:       libstdc++-devel
44 Requires:       openssl-devel
45
46 %description devel
47 Header files for the ortp library.
48
49 %description devel -l pl.UTF-8
50 Pliki nagłówkowe dla biblioteki ortp.
51
52 %package static
53 Summary:        Static ortp library
54 Summary(pl.UTF-8):      Statyczna biblioteka ortp
55 Group:          Development/Libraries
56 Requires:       %{name}-devel = %{version}-%{release}
57
58 %description static
59 Static ortp library.
60
61 %description static -l pl.UTF-8
62 Statyczna biblioteka ortp.
63
64 %package apidocs
65 Summary:        API documentation for ortp library
66 Summary(pl.UTF-8):      Dokumentacja API biblioteki ortp
67 Group:          Documentation
68 BuildArch:      noarch
69
70 %description apidocs
71 API documentation for ortp library.
72
73 %description apidocs -l pl.UTF-8
74 Dokumentacja API biblioteki ortp.
75
76 %prep
77 %setup -q
78 %patch0 -p1
79 %patch1 -p1
80
81 %build
82 # use cmake instead of autotools:
83 # - to get cmake target files for other linphone projects
84 # - configure.ac seems outdated (version 1.0.1, soname 13)
85 install -d build
86 cd build
87 %cmake .. \
88         %{!?with_static_libs:-DENABLE_STATIC=NO} \
89         -DENABLE_STRICT=NO
90 %{__make}
91
92 %install
93 rm -rf $RPM_BUILD_ROOT
94
95 %{__make} -C build install \
96         DESTDIR=$RPM_BUILD_ROOT
97
98 # packaged as %doc
99 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/ortp-.
100 # packaged as %doc in -apidocs
101 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/ortp-4.5.0
102
103 # disable completeness check incompatible with split packaging
104 %{__sed} -i -e '/^foreach(target .*IMPORT_CHECK_TARGETS/,/^endforeach/d; /^unset(_IMPORT_CHECK_TARGETS)/d' $RPM_BUILD_ROOT%{_libdir}/cmake/ortp/ortpTargets.cmake
105
106 %clean
107 rm -rf $RPM_BUILD_ROOT
108
109 %post   -p /sbin/ldconfig
110 %postun -p /sbin/ldconfig
111
112 %files
113 %defattr(644,root,root,755)
114 %doc AUTHORS.md CHANGELOG.md README.md
115 %attr(755,root,root) %{_libdir}/libortp.so.15
116
117 %files devel
118 %defattr(644,root,root,755)
119 %attr(755,root,root) %{_libdir}/libortp.so
120 %{_includedir}/ortp
121 %{_pkgconfigdir}/ortp.pc
122 %{_libdir}/cmake/ortp
123
124 %if %{with static_libs}
125 %files static
126 %defattr(644,root,root,755)
127 %{_libdir}/libortp.a
128 %endif
129
130 %files apidocs
131 %defattr(644,root,root,755)
132 %doc build/doc/html/*.{css,html,js,png}
This page took 0.064666 seconds and 2 git commands to generate.