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)
7 %bcond_with amr # AMR-NB and AMR-WB (floating-point) support
8 %bcond_without avcap # AVCap module
9 %bcond_without directfb # DirectFB support
10 %bcond_without faad # AAC decoding support
11 %bcond_without ffmpeg # ffmpeg support
12 %bcond_without freenect # freenect (MS Kinect driver) module
13 %bcond_without freetype # freetype support
14 %bcond_without jpeg # JPEG support
15 %bcond_with js # JavaScript support in Osmo4 and modules
16 %bcond_without mad # MP3 support
17 %bcond_without png # PNG support
18 %bcond_without xvid # xvid support
19 %bcond_without wx # wxWidgets support
20 %bcond_with mozilla # Mozilla (xulrunner/firefox/iceweasel, NPAPI+XPCOM based) plugin
23 %undefine with_mozilla
26 Summary: GPAC - an implementation of the MPEG-4 Systems standard (ISO/IEC 14496-1)
27 Summary(pl.UTF-8): GPAC - implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1)
32 Group: Applications/Multimedia
33 #Source0Download: https://github.com/gpac/gpac/releases
34 Source0: https://github.com/gpac/gpac/archive/v%{version}/%{name}-%{version}.tar.gz
35 # Source0-md5: 06ecb86b4da83e2d38e108f513c2ed8a
36 Patch0: %{name}-install.patch
37 Patch1: %{name}-cxx.patch
39 Patch3: %{name}-install-is-not-clean.patch
40 Patch4: %{name}-flags.patch
41 Patch5: wxWidgets3.patch
43 Patch7: %{name}-apps.patch
45 Patch11: dont-err-build-on-uknown-system.patch
46 URL: http://www.gpac.io/
47 %{?with_directfb:BuildRequires: DirectFB-devel}
48 BuildRequires: OpenGL-GLU-devel
49 BuildRequires: SDL-devel
50 BuildRequires: a52dec-libs-devel
51 %{?with_avcap:BuildRequires: avcap-devel}
52 BuildRequires: alsa-lib-devel >= 0.9
53 %{?with_amr:BuildRequires: amrnb-devel}
54 %{?with_amr:BuildRequires: amrwb-devel}
55 %{?with_faad:BuildRequires: faad2-devel}
56 %{?with_ffmpeg:BuildRequires: ffmpeg-devel >= 0.6}
57 %{?with_freetype:BuildRequires: freetype-devel}
58 %{?with_wx:BuildRequires: gtk+2-devel >= 2:2.20.1}
59 BuildRequires: jack-audio-connection-kit-devel
60 %{?with_js:BuildRequires: js-devel < 2:1.8.5}
61 %{?with_freenect:BuildRequires: libfreenect-devel}
62 %{?with_jpeg:BuildRequires: libjpeg-devel}
63 %{?with_mad:BuildRequires: libmad-devel}
64 BuildRequires: libogg-devel
65 %{?with_png:BuildRequires: libpng-devel}
66 BuildRequires: libtheora-devel
67 BuildRequires: libvorbis-devel
68 BuildRequires: libxml2-devel
69 BuildRequires: openjpeg-devel >= 1.5
70 BuildRequires: openssl-devel
71 BuildRequires: pkgconfig
72 BuildRequires: pulseaudio-devel
73 BuildRequires: rpmbuild(macros) >= 1.357
74 BuildRequires: sed >= 4.0
76 %{?with_wx:BuildRequires: wxGTK2-unicode-devel >= 2.6.0}
77 BuildRequires: xmlrpc-c-server-devel
78 BuildRequires: xorg-lib-libXext-devel
79 BuildRequires: xorg-lib-libXv-devel
80 %{?with_mozilla:BuildRequires: xulrunner-devel >= 2:9.0.0}
81 %{?with_xvid:BuildRequires: xvid-devel}
82 BuildRequires: xz-devel
83 BuildRequires: zlib-devel
84 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
87 GPAC is an implementation of the MPEG-4 Systems standard (ISO/IEC
88 14496-1) developed from scratch in ANSI C.
90 The main development goal is to provide a clean (a.k.a. readable by as
91 many people as possible), small and flexible alternative to the MPEG-4
92 Systems reference software (known as IM1 and distributed in ISO/IEC
93 14496-5). The MPEG-4 Reference software is indeed a very large piece
94 of software, designed to verify the standard rather than provide a
95 small, production-stable software. GPAC is written in ANSI C for
96 portability reasons (embedded platforms and DSPs) with a simple goal:
97 keep the memory footprint as low as possible. The project will at term
98 provide player(s), systems encoders and publishing tools for content
101 %description -l pl.UTF-8
102 GPAC to implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1)
103 stworzona od zera w ANSI C.
105 Głównym celem tworzenia jej jest dostarczenie czystej (tzn. czytelnej
106 dla jak największej liczby ludzi), małej i elastycznej alternatywy dla
107 wzorcowego oprogramowania MPEG-4 Systems (znanego jako IM1 i
108 rozprowadzanego w ISO/IEC 14496-5). Wzorcowe oprogramowanie MPEG-4
109 jest bardzo dużą porcją kodu, zaprojektowaną raczej do zweryfikowania
110 standardu niż dostarczenia małej, stabilnej wersji produkcyjnej. GPAC
111 jest pisany w ANSI C ze względu na przenośność (platformy wbudowane i
112 DSP) z prostym celem: wymagać tak mało pamięci, jak to tylko możliwe.
113 Projekt docelowo dostarczy odtwarzacz(e), kodery systemowe i narzędzia
114 do publikacji w celu dystrybucji materiałów.
117 Summary: Header files for GPAC library
118 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GPAC
119 Group: Development/Libraries
120 Requires: %{name} = %{version}-%{release}
123 Header files for GPAC library.
125 %description devel -l pl.UTF-8
126 Pliki nagłówkowe biblioteki GPAC.
129 Summary: Static GPAC library
130 Summary(pl.UTF-8): Statyczna biblioteka GPAC
131 Group: Development/Libraries
132 Requires: %{name}-devel = %{version}-%{release}
137 %description static -l pl.UTF-8
138 Statyczna biblioteka GPAC.
141 Summary: wxWidgets-based GUI for GPAC
142 Summary(pl.UTF-8): Oparty na wxWidgets graficzny interfejs do GPAC
143 Group: X11/Applications/Multimedia
144 Requires: %{name} = %{version}-%{release}
147 Osmo4 - wxWidgets-based GUI for GPAC.
149 %description gui -l pl.UTF-8
150 Osmo4 - oparty na wxWidgets graficzny interfejs do GPAC.
152 %package -n browser-plugin-%{name}
153 Summary: GPAC browser plugin
154 Summary(pl.UTF-8): Wtyczka GPAC do przegląderek WWW
156 Requires: %{name} = %{version}-%{release}
157 Requires: browser-plugins >= 2.0
158 Requires: browser-plugins(%{_target_base_arch})
160 %description -n browser-plugin-%{name}
161 GPAC plugin for Netscape-compatible WWW browsers.
163 %description -n browser-plugin-%{name} -l pl.UTF-8
164 Wtyczka GPAC dla przeglądarek WWW zgodnych z Netscape.
179 %{__sed} -i -e 's/wx-config/wx-gtk2-unicode-config/' configure
181 %{__sed} -i -e 's,has_avcap="yes",has_avcap="no",' configure
186 # not autoconf configure
189 --prefix=%{_prefix} \
191 --mandir=%{_mandir} \
196 %{!?with_wx:--disable-wx} \
197 %{?with_amr:--enable-amr} \
199 --extra-cflags="%{rpmcflags} -I/usr/include/openjpeg-1.5" \
200 --extra-ldflags="%{rpmldflags}" \
201 %{?with_mozilla:--mozdir=%{_browserpluginsdir}} \
202 %{?with_mozilla:--xulsdk-path="/usr/include/xulrunner -I/usr/include/nspr"} \
203 %{!?with_faad:--use-faad=no} \
204 %{!?with_ffmpeg:--use-ffmpeg=no} \
205 %{!?with_freenect:--use-freenect=no} \
206 %{!?with_freetype:--use-ft=no} \
207 %{!?with_jpeg:--use-jpeg=no} \
208 %{!?with_js:--use-js=no} \
209 %{!?with_mad:--use-mad=no} \
210 %{!?with_png:--use-png=no} \
211 %{!?with_xvid:--use-xvid=no} \
214 %{!?with_directfb: sed -i 's/CONFIG_DIRECTFB.*/CONFIG_DIRECTFB=no/' config.mak}
219 rm -rf $RPM_BUILD_ROOT
220 install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
222 %{__make} -j1 install install-lib \
223 DESTDIR=$RPM_BUILD_ROOT
225 %{__make} -j1 -C applications install \
226 DESTDIR=$RPM_BUILD_ROOT \
227 MOZILLA_DIR=$RPM_BUILD_ROOT%{_browserpluginsdir}
230 %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/{win32,wince}
233 rm -rf $RPM_BUILD_ROOT
235 %post -p /sbin/ldconfig
236 %postun -p /sbin/ldconfig
238 %post -n browser-plugin-%{name}
239 %update_browser_plugins
241 %postun -n browser-plugin-%{name}
242 if [ "$1" = 0 ]; then
243 %update_browser_plugins
247 %defattr(644,root,root,755)
248 %doc AUTHORS BUGS Changelog README.md TODO
249 %attr(755,root,root) %{_bindir}/MP42TS
250 %attr(755,root,root) %{_bindir}/MP4Box
251 %attr(755,root,root) %{_bindir}/MP4Client
252 %attr(755,root,root) %{_libdir}/libgpac.so.*.*.*
253 %attr(755,root,root) %ghost %{_libdir}/libgpac.so.8
255 %attr(755,root,root) %{_libdir}/gpac/gm_*.so
257 %{_mandir}/man1/gpac.1*
258 %{_mandir}/man1/mp4box.1*
259 %{_mandir}/man1/mp4client.1*
262 %defattr(644,root,root,755)
263 %attr(755,root,root) %{_libdir}/libgpac.so
265 %{_pkgconfigdir}/gpac.pc
268 %defattr(644,root,root,755)
269 %{_libdir}/libgpac_static.a
273 %defattr(644,root,root,755)
274 %attr(755,root,root) %{_bindir}/DashCast
275 %attr(755,root,root) %{_bindir}/Osmo4
279 %files -n browser-plugin-%{name}
280 %defattr(644,root,root,755)
281 %attr(755,root,root) %{_browserpluginsdir}/nposmozilla.so
282 %{_browserpluginsdir}/nposmozilla.xpt