]>
Commit | Line | Data |
---|---|---|
16219ea0 | 1 | # TODO: |
663e8377 JB |
2 | # - Platinum UPnP: http://www.plutinosoft.com/platinum (for platinum module) |
3 | # - OpenSVCDecoder: http://opensvcdecoder.sourceforge.net/ (for opensvc_dec module) | |
4 | # - libopenhevc: https://github.com/OpenHEVC/openHEVC (for openhevc_dec module, replaces ffmpeg_in module) | |
4979ec52 | 5 | # |
cee2dd04 | 6 | # Conditional build: |
0f42ec7c | 7 | %bcond_with amr # AMR-NB and AMR-WB (floating-point) support |
663e8377 | 8 | %bcond_without avcap # AVCap module |
7ba98f2a | 9 | %bcond_with directfb # DirectFB support |
13701c20 JB |
10 | %bcond_without faad # AAC decoding support |
11 | %bcond_without ffmpeg # ffmpeg support | |
663e8377 | 12 | %bcond_without freenect # freenect (MS Kinect driver) module |
13701c20 JB |
13 | %bcond_without freetype # freetype support |
14 | %bcond_without jpeg # JPEG support | |
663e8377 | 15 | %bcond_with js # JavaScript support in Osmo4 and modules |
13701c20 JB |
16 | %bcond_without mad # MP3 support |
17 | %bcond_without png # PNG support | |
18 | %bcond_without xvid # xvid support | |
663e8377 | 19 | %bcond_with mozilla # Mozilla (xulrunner/firefox/iceweasel, NPAPI+XPCOM based) plugin |
cee2dd04 | 20 | # |
f6687443 | 21 | %ifarch x32 |
663e8377 | 22 | %undefine with_mozilla |
f6687443 | 23 | %endif |
3f319749 | 24 | # |
b2995149 | 25 | Summary: GPAC - an implementation of the MPEG-4 Systems standard (ISO/IEC 14496-1) |
5dbd083d | 26 | Summary(pl.UTF-8): GPAC - implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1) |
5f694ea5 | 27 | Name: gpac |
d1c04050 | 28 | Version: 2.2.1 |
d31320f1 | 29 | Release: 1 |
13701c20 JB |
30 | License: LGPL v2+ |
31 | Group: Applications/Multimedia | |
663e8377 JB |
32 | #Source0Download: https://github.com/gpac/gpac/releases |
33 | Source0: https://github.com/gpac/gpac/archive/v%{version}/%{name}-%{version}.tar.gz | |
d1c04050 JR |
34 | # Source0-md5: a1a4a6c7f1525431b211b5ba47253ed0 |
35 | Patch0: ffmpeg6.patch | |
663e8377 | 36 | URL: http://www.gpac.io/ |
57e5083b | 37 | %{?with_directfb:BuildRequires: DirectFB-devel} |
2c7550ba | 38 | BuildRequires: OpenGL-GLU-devel |
f0a57dca | 39 | BuildRequires: SDL-devel |
13701c20 | 40 | BuildRequires: a52dec-libs-devel |
663e8377 | 41 | %{?with_avcap:BuildRequires: avcap-devel} |
13701c20 | 42 | BuildRequires: alsa-lib-devel >= 0.9 |
0f42ec7c JB |
43 | %{?with_amr:BuildRequires: amrnb-devel} |
44 | %{?with_amr:BuildRequires: amrwb-devel} | |
cee2dd04 | 45 | %{?with_faad:BuildRequires: faad2-devel} |
9c5072f3 | 46 | %{?with_ffmpeg:BuildRequires: ffmpeg-devel >= 0.6} |
cee2dd04 | 47 | %{?with_freetype:BuildRequires: freetype-devel} |
13701c20 | 48 | BuildRequires: jack-audio-connection-kit-devel |
62f5b1b8 | 49 | %{?with_js:BuildRequires: js-devel < 2:1.8.5} |
663e8377 | 50 | %{?with_freenect:BuildRequires: libfreenect-devel} |
cee2dd04 JB |
51 | %{?with_jpeg:BuildRequires: libjpeg-devel} |
52 | %{?with_mad:BuildRequires: libmad-devel} | |
13701c20 | 53 | BuildRequires: libogg-devel |
cee2dd04 | 54 | %{?with_png:BuildRequires: libpng-devel} |
13701c20 JB |
55 | BuildRequires: libtheora-devel |
56 | BuildRequires: libvorbis-devel | |
6dcdf31e | 57 | BuildRequires: libxml2-devel |
d31320f1 | 58 | BuildRequires: openjpeg2-devel |
16219ea0 | 59 | BuildRequires: openssl-devel |
2c7550ba | 60 | BuildRequires: pkgconfig |
13701c20 | 61 | BuildRequires: pulseaudio-devel |
60486834 | 62 | BuildRequires: rpmbuild(macros) >= 1.357 |
0f42ec7c | 63 | BuildRequires: sed >= 4.0 |
b676b63c | 64 | BuildRequires: unzip |
a8c7bdfb | 65 | BuildRequires: xmlrpc-c-server-devel |
13701c20 JB |
66 | BuildRequires: xorg-lib-libXext-devel |
67 | BuildRequires: xorg-lib-libXv-devel | |
663e8377 | 68 | %{?with_mozilla:BuildRequires: xulrunner-devel >= 2:9.0.0} |
cee2dd04 | 69 | %{?with_xvid:BuildRequires: xvid-devel} |
663e8377 | 70 | BuildRequires: xz-devel |
16219ea0 | 71 | BuildRequires: zlib-devel |
d31320f1 | 72 | Obsoletes: gpac-gui < 1.0.1-1 |
5f694ea5 | 73 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
74 | ||
75 | %description | |
b2995149 | 76 | GPAC is an implementation of the MPEG-4 Systems standard (ISO/IEC |
77 | 14496-1) developed from scratch in ANSI C. | |
5f694ea5 | 78 | |
b2995149 | 79 | The main development goal is to provide a clean (a.k.a. readable by as |
80 | many people as possible), small and flexible alternative to the MPEG-4 | |
81 | Systems reference software (known as IM1 and distributed in ISO/IEC | |
82 | 14496-5). The MPEG-4 Reference software is indeed a very large piece | |
83 | of software, designed to verify the standard rather than provide a | |
84 | small, production-stable software. GPAC is written in ANSI C for | |
85 | portability reasons (embedded platforms and DSPs) with a simple goal: | |
86 | keep the memory footprint as low as possible. The project will at term | |
87 | provide player(s), systems encoders and publishing tools for content | |
88 | distribution. | |
5f694ea5 | 89 | |
80b9bf8c | 90 | %description -l pl.UTF-8 |
cee2dd04 JB |
91 | GPAC to implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1) |
92 | stworzona od zera w ANSI C. | |
93 | ||
80b9bf8c JR |
94 | Głównym celem tworzenia jej jest dostarczenie czystej (tzn. czytelnej |
95 | dla jak największej liczby ludzi), małej i elastycznej alternatywy dla | |
cee2dd04 JB |
96 | wzorcowego oprogramowania MPEG-4 Systems (znanego jako IM1 i |
97 | rozprowadzanego w ISO/IEC 14496-5). Wzorcowe oprogramowanie MPEG-4 | |
80b9bf8c JR |
98 | jest bardzo dużą porcją kodu, zaprojektowaną raczej do zweryfikowania |
99 | standardu niż dostarczenia małej, stabilnej wersji produkcyjnej. GPAC | |
100 | jest pisany w ANSI C ze względu na przenośność (platformy wbudowane i | |
101 | DSP) z prostym celem: wymagać tak mało pamięci, jak to tylko możliwe. | |
102 | Projekt docelowo dostarczy odtwarzacz(e), kodery systemowe i narzędzia | |
103 | do publikacji w celu dystrybucji materiałów. | |
cee2dd04 | 104 | |
9cf5dcbc JB |
105 | %package devel |
106 | Summary: Header files for GPAC library | |
107 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GPAC | |
108 | Group: Development/Libraries | |
109 | Requires: %{name} = %{version}-%{release} | |
110 | ||
111 | %description devel | |
112 | Header files for GPAC library. | |
113 | ||
114 | %description devel -l pl.UTF-8 | |
115 | Pliki nagłówkowe biblioteki GPAC. | |
116 | ||
16219ea0 JB |
117 | %package static |
118 | Summary: Static GPAC library | |
119 | Summary(pl.UTF-8): Statyczna biblioteka GPAC | |
120 | Group: Development/Libraries | |
121 | Requires: %{name}-devel = %{version}-%{release} | |
122 | ||
123 | %description static | |
124 | Static GPAC library. | |
125 | ||
126 | %description static -l pl.UTF-8 | |
127 | Statyczna biblioteka GPAC. | |
128 | ||
84d02762 | 129 | %package -n browser-plugin-%{name} |
130 | Summary: GPAC browser plugin | |
5dbd083d | 131 | Summary(pl.UTF-8): Wtyczka GPAC do przegląderek WWW |
84d02762 | 132 | Group: X11/Libraries |
133 | Requires: %{name} = %{version}-%{release} | |
60486834 ER |
134 | Requires: browser-plugins >= 2.0 |
135 | Requires: browser-plugins(%{_target_base_arch}) | |
84d02762 | 136 | |
137 | %description -n browser-plugin-%{name} | |
138 | GPAC plugin for Netscape-compatible WWW browsers. | |
139 | ||
80b9bf8c JR |
140 | %description -n browser-plugin-%{name} -l pl.UTF-8 |
141 | Wtyczka GPAC dla przeglądarek WWW zgodnych z Netscape. | |
84d02762 | 142 | |
5f694ea5 | 143 | %prep |
ebe39204 | 144 | %setup -q |
f0a57dca | 145 | %patch0 -p1 |
ebe39204 | 146 | |
663e8377 JB |
147 | %if %{without avcap} |
148 | %{__sed} -i -e 's,has_avcap="yes",has_avcap="no",' configure | |
149 | %endif | |
e25a2665 | 150 | chmod a+x configure |
5f694ea5 | 151 | |
5f694ea5 | 152 | %build |
16219ea0 JB |
153 | # not autoconf configure |
154 | ./configure \ | |
ebe39204 | 155 | --verbose \ |
16219ea0 JB |
156 | --prefix=%{_prefix} \ |
157 | --libdir=%{_lib} \ | |
158 | --mandir=%{_mandir} \ | |
13701c20 JB |
159 | --X11-path=/usr \ |
160 | --cc="%{__cc}" \ | |
663e8377 | 161 | --cxx="%{__cxx}" \ |
13701c20 | 162 | --disable-opt \ |
0f42ec7c | 163 | %{?with_amr:--enable-amr} \ |
13701c20 | 164 | --enable-pic \ |
d31320f1 | 165 | --extra-cflags="%{rpmcflags}" \ |
13701c20 | 166 | --extra-ldflags="%{rpmldflags}" \ |
663e8377 JB |
167 | %{?with_mozilla:--mozdir=%{_browserpluginsdir}} \ |
168 | %{?with_mozilla:--xulsdk-path="/usr/include/xulrunner -I/usr/include/nspr"} \ | |
13701c20 JB |
169 | %{!?with_faad:--use-faad=no} \ |
170 | %{!?with_ffmpeg:--use-ffmpeg=no} \ | |
663e8377 | 171 | %{!?with_freenect:--use-freenect=no} \ |
13701c20 JB |
172 | %{!?with_freetype:--use-ft=no} \ |
173 | %{!?with_jpeg:--use-jpeg=no} \ | |
13701c20 JB |
174 | %{!?with_mad:--use-mad=no} \ |
175 | %{!?with_png:--use-png=no} \ | |
176 | %{!?with_xvid:--use-xvid=no} \ | |
f6687443 | 177 | --enable-joystick |
5f694ea5 | 178 | |
57e5083b KK |
179 | %{!?with_directfb: sed -i 's/CONFIG_DIRECTFB.*/CONFIG_DIRECTFB=no/' config.mak} |
180 | ||
d1c04050 | 181 | %{__make} |
5f694ea5 | 182 | |
183 | %install | |
184 | rm -rf $RPM_BUILD_ROOT | |
16219ea0 | 185 | install -d $RPM_BUILD_ROOT%{_pkgconfigdir} |
5f694ea5 | 186 | |
f2e9b0f0 | 187 | %{__make} -j1 install install-lib \ |
16219ea0 JB |
188 | DESTDIR=$RPM_BUILD_ROOT |
189 | ||
f2e9b0f0 | 190 | %{__make} -j1 -C applications install \ |
13701c20 | 191 | DESTDIR=$RPM_BUILD_ROOT \ |
60486834 | 192 | MOZILLA_DIR=$RPM_BUILD_ROOT%{_browserpluginsdir} |
5f694ea5 | 193 | |
5f694ea5 | 194 | %clean |
195 | rm -rf $RPM_BUILD_ROOT | |
196 | ||
197 | %post -p /sbin/ldconfig | |
198 | %postun -p /sbin/ldconfig | |
199 | ||
60486834 ER |
200 | %post -n browser-plugin-%{name} |
201 | %update_browser_plugins | |
84d02762 | 202 | |
60486834 ER |
203 | %postun -n browser-plugin-%{name} |
204 | if [ "$1" = 0 ]; then | |
205 | %update_browser_plugins | |
84d02762 | 206 | fi |
207 | ||
5f694ea5 | 208 | %files |
209 | %defattr(644,root,root,755) | |
d31320f1 | 210 | %doc Changelog README.md |
13701c20 | 211 | %attr(755,root,root) %{_bindir}/MP4Box |
d31320f1 | 212 | %attr(755,root,root) %{_bindir}/gpac |
16219ea0 | 213 | %attr(755,root,root) %{_libdir}/libgpac.so.*.*.* |
d1c04050 | 214 | %attr(755,root,root) %ghost %{_libdir}/libgpac.so.12 |
4979ec52 | 215 | %dir %{_libdir}/gpac |
13701c20 JB |
216 | %attr(755,root,root) %{_libdir}/gpac/gm_*.so |
217 | %{_datadir}/gpac | |
218 | %{_mandir}/man1/gpac.1* | |
d31320f1 | 219 | %{_mandir}/man1/gpac-filters.1* |
13701c20 | 220 | %{_mandir}/man1/mp4box.1* |
d31320f1 | 221 | %{_desktopdir}/gpac.desktop |
d1c04050 | 222 | %{_iconsdir}/hicolor/*x*/apps/gpac.png |
84d02762 | 223 | |
9cf5dcbc JB |
224 | %files devel |
225 | %defattr(644,root,root,755) | |
16219ea0 | 226 | %attr(755,root,root) %{_libdir}/libgpac.so |
9cf5dcbc | 227 | %{_includedir}/gpac |
16219ea0 JB |
228 | %{_pkgconfigdir}/gpac.pc |
229 | ||
230 | %files static | |
231 | %defattr(644,root,root,755) | |
232 | %{_libdir}/libgpac_static.a | |
9cf5dcbc | 233 | |
663e8377 | 234 | %if %{with mozilla} |
84d02762 | 235 | %files -n browser-plugin-%{name} |
236 | %defattr(644,root,root,755) | |
60486834 ER |
237 | %attr(755,root,root) %{_browserpluginsdir}/nposmozilla.so |
238 | %{_browserpluginsdir}/nposmozilla.xpt | |
f6687443 | 239 | %endif |