]>
Commit | Line | Data |
---|---|---|
9ff462c7 JB |
1 | # TODO: |
2 | # - mediaServer should have init-scripts, user, etc, etc... | |
32fd5524 JB |
3 | # - package test apps (?) |
4 | # | |
5 | # Conditional build: | |
6 | %bcond_without static_libs # static libraries | |
7d2b9f2b | 7 | %bcond_without atomic_flag # C++20 std::atomic_flag functionality |
32fd5524 | 8 | |
fe23064d JB |
9 | Summary: LIVE555 streaming media server |
10 | Summary(pl.UTF-8): LIVE555 - serwer strumieni multimedialnych | |
fff7b9fc | 11 | Name: live |
7d2b9f2b | 12 | Version: 2024.02.28 |
22ca2a6f | 13 | Release: 1 |
357826c0 | 14 | Epoch: 2 |
0eb9cb7c | 15 | License: LGPL v2.1+ |
daad9eff | 16 | Group: Applications/Multimedia |
767bfffd | 17 | Source0: http://www.live555.com/liveMedia/public/%{name}.%{version}.tar.gz |
7d2b9f2b | 18 | # Source0-md5: 8c4a142349abbdf6e5e24813c7a15501 |
57b898d4 | 19 | Source1: http://www.live555.com/liveMedia/public/changelog.txt |
7d2b9f2b | 20 | # Source1-md5: 000f6435ea418b0365f68d83edd7a361 |
fe23064d | 21 | Patch0: %{name}-link.patch |
30dc04f0 AM |
22 | # from debian |
23 | Patch1: %{name}-pkgconfig.patch | |
767bfffd | 24 | URL: http://www.live555.com/liveMedia/ |
7d2b9f2b JB |
25 | %if %{with atomic_flag} |
26 | BuildRequires: libstdc++-devel >= 6:11 | |
27 | %else | |
be100c98 | 28 | BuildRequires: libstdc++-devel |
7d2b9f2b | 29 | %endif |
fa75e603 | 30 | BuildRequires: openssl-devel |
be100c98 | 31 | BuildRequires: sed >= 4.0 |
9dd1fc5d | 32 | Requires: %{name}-libs = %{epoch}:%{version}-%{release} |
fff7b9fc | 33 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
34 | ||
1f653ac8 | 35 | %define specflags -fno-strict-aliasing |
a2d10620 JB |
36 | # circular symbol dependencies with libBasicUsageEnvironment |
37 | %define skip_post_check_so .*%{_libdir}/libUsageEnvironment\.so.* | |
45ee8107 | 38 | |
fff7b9fc | 39 | %description |
fe23064d | 40 | LIVE555 streaming media server. |
c855b1af | 41 | |
9f4ccf7a | 42 | %description -l pl.UTF-8 |
fe23064d | 43 | LIVE555 - serwer strumieni multimedialnych. |
fff7b9fc | 44 | |
1f653ac8 | 45 | %package libs |
011ec5da | 46 | Summary: Shared LIVE555 libraries for streaming media |
fe23064d JB |
47 | Summary(pl.UTF-8): Biblioteki współdzielone LIVE555 do strumieni multimedialnych |
48 | Group: Libraries | |
1f653ac8 PG |
49 | |
50 | %description libs | |
9dd1fc5d | 51 | Shared LIVE555 libraries for streaming media. |
1f653ac8 | 52 | |
fe23064d JB |
53 | %description libs -l pl.UTF-8 |
54 | Biblioteki współdzielone LIVE555 do strumieni multimedialnych. | |
55 | ||
e8f768dc | 56 | %package devel |
011ec5da ER |
57 | Summary: Header files for developing programs using LIVE555 |
58 | Summary(pl.UTF-8): Pliki nagłówkowe do biblioteki LIVE555 | |
59 | Group: Development/Libraries | |
60 | Requires: %{name}-libs = %{epoch}:%{version}-%{release} | |
fe23064d | 61 | Requires: libstdc++-devel |
011ec5da | 62 | Obsoletes: live < 2:2009.07.09-2.5 |
e8f768dc PG |
63 | |
64 | %description devel | |
65 | Header files for developing programs using LIVE555. | |
66 | ||
67 | %description devel -l pl.UTF-8 | |
68 | Pliki nagłówkowe do biblioteki LIVE555 | |
69 | ||
70 | %package static | |
fe23064d JB |
71 | Summary: Static LIVE555 libraries for streaming media |
72 | Summary(pl.UTF-8): Biblioteki statyczne LIVE555 do strumieni multimedialnych | |
011ec5da ER |
73 | Group: Development/Libraries |
74 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
e8f768dc PG |
75 | |
76 | %description static | |
fe23064d | 77 | Static LIVE555 libraries for streaming media. |
e8f768dc PG |
78 | |
79 | %description static -l pl.UTF-8 | |
fe23064d | 80 | Biblioteki statyczne LIVE555 do strumieni multimedialnych. |
e8f768dc | 81 | |
011ec5da | 82 | %prep |
32fd5524 | 83 | %setup -q -c |
4e0e02bd | 84 | %patch0 -p1 |
30dc04f0 | 85 | %patch1 -p1 |
32fd5524 JB |
86 | |
87 | # disable building test programs | |
88 | %{__sed} -i -e '/cd \$(TESTPROGS_DIR)/d' live/Makefile.tail | |
89 | ||
90 | # out-of-source builds not supported, so clone sources for shared and static build | |
91 | %if %{with static_libs} | |
92 | cp -pPR live live-static | |
93 | %endif | |
94 | %{__mv} live live-shared | |
95 | ||
fe23064d | 96 | cp -af %{SOURCE1} ChangeLog.txt |
22b1675a | 97 | |
fff7b9fc | 98 | %build |
32fd5524 JB |
99 | %if %{with static_libs} |
100 | cd live-static | |
fff7b9fc | 101 | ./genMakefiles linux |
22b1675a JB |
102 | %{__make} \ |
103 | C_COMPILER="%{__cc}" \ | |
104 | CPLUSPLUS_COMPILER="%{__cxx}" \ | |
7d2b9f2b | 105 | CPPFLAGS="%{rpmcppflags} %{!?with_atomic_flag:-DNO_STD_LIB}" \ |
32fd5524 | 106 | CFLAGS="%{rpmcflags} -fPIC" \ |
493e8507 | 107 | CXXFLAGS="%{rpmcxxflags} -fPIC %{?with_atomic_flag:-std=c++20}" |
32fd5524 JB |
108 | cd .. |
109 | %endif | |
fff7b9fc | 110 | |
32fd5524 JB |
111 | cd live-shared |
112 | ./genMakefiles linux-with-shared-libraries | |
e8f768dc | 113 | %{__make} \ |
b8c94401 JB |
114 | C_COMPILER="%{__cc}" \ |
115 | CPLUSPLUS_COMPILER="%{__cxx}" \ | |
7d2b9f2b | 116 | CPPFLAGS="%{rpmcppflags} %{!?with_atomic_flag:-DNO_STD_LIB}" \ |
32fd5524 | 117 | CFLAGS="%{rpmcflags}" \ |
493e8507 | 118 | CXXFLAGS="%{rpmcxxflags} %{?with_atomic_flag:-std=c++20}" \ |
32fd5524 | 119 | LIBRARY_LINK="%{__cxx} -o" |
e8f768dc | 120 | |
fff7b9fc | 121 | %install |
122 | rm -rf $RPM_BUILD_ROOT | |
c855b1af | 123 | |
32fd5524 JB |
124 | %if %{with static_libs} |
125 | # static first so that binaries will be overwritten by shared version | |
126 | %{__make} -C live-static install \ | |
127 | PREFIX=%{_prefix} \ | |
30dc04f0 AM |
128 | LIBDIR=%{_libdir} \ |
129 | DESTDIR=$RPM_BUILD_ROOT | |
32fd5524 JB |
130 | %endif |
131 | ||
132 | %{__make} -C live-shared install \ | |
133 | PREFIX=%{_prefix} \ | |
134 | LIBDIR=%{_libdir} \ | |
135 | DESTDIR=$RPM_BUILD_ROOT | |
136 | ||
fff7b9fc | 137 | %clean |
138 | rm -rf $RPM_BUILD_ROOT | |
139 | ||
fe23064d JB |
140 | %post libs -p /sbin/ldconfig |
141 | %postun libs -p /sbin/ldconfig | |
e8f768dc | 142 | |
fff7b9fc | 143 | %files |
144 | %defattr(644,root,root,755) | |
fa75e603 | 145 | %attr(755,root,root) %{_bindir}/live555HLSProxy |
9dd1fc5d | 146 | %attr(755,root,root) %{_bindir}/live555MediaServer |
32fd5524 | 147 | %attr(755,root,root) %{_bindir}/live555ProxyServer |
1f653ac8 PG |
148 | |
149 | %files libs | |
150 | %defattr(644,root,root,755) | |
32fd5524 | 151 | %attr(755,root,root) %{_libdir}/libBasicUsageEnvironment.so.*.*.* |
0ce6abe6 | 152 | %attr(755,root,root) %ghost %{_libdir}/libBasicUsageEnvironment.so.2 |
32fd5524 JB |
153 | %attr(755,root,root) %{_libdir}/libUsageEnvironment.so.*.*.* |
154 | %attr(755,root,root) %ghost %{_libdir}/libUsageEnvironment.so.3 | |
155 | %attr(755,root,root) %{_libdir}/libgroupsock.so.*.*.* | |
51445b36 | 156 | %attr(755,root,root) %ghost %{_libdir}/libgroupsock.so.30 |
32fd5524 | 157 | %attr(755,root,root) %{_libdir}/libliveMedia.so.*.*.* |
7d2b9f2b | 158 | %attr(755,root,root) %ghost %{_libdir}/libliveMedia.so.112 |
e8f768dc PG |
159 | |
160 | %files devel | |
161 | %defattr(644,root,root,755) | |
57b898d4 | 162 | %doc ChangeLog.txt |
2deb76aa AM |
163 | %attr(755,root,root) %{_libdir}/libBasicUsageEnvironment.so |
164 | %attr(755,root,root) %{_libdir}/libUsageEnvironment.so | |
165 | %attr(755,root,root) %{_libdir}/libgroupsock.so | |
166 | %attr(755,root,root) %{_libdir}/libliveMedia.so | |
32fd5524 JB |
167 | %{_includedir}/BasicUsageEnvironment |
168 | %{_includedir}/UsageEnvironment | |
169 | %{_includedir}/groupsock | |
fe23064d | 170 | %{_includedir}/liveMedia |
30dc04f0 | 171 | %{_pkgconfigdir}/live555.pc |
e8f768dc | 172 | |
32fd5524 | 173 | %if %{with static_libs} |
e8f768dc PG |
174 | %files static |
175 | %defattr(644,root,root,755) | |
9dd1fc5d PG |
176 | %{_libdir}/libBasicUsageEnvironment.a |
177 | %{_libdir}/libUsageEnvironment.a | |
178 | %{_libdir}/libgroupsock.a | |
179 | %{_libdir}/libliveMedia.a | |
32fd5524 | 180 | %endif |