1 # TODO: soname for libm4systems(?)
2 # - use system mozilla includes
3 # - ./configure[692]: wx-config: not found
4 # - ./configure[693]: wx-config: not found
12 %bcond_without freetype
20 Summary: GPAC - an implementation of the MPEG-4 Systems standard (ISO/IEC 14496-1)
21 Summary(pl): GPAC - implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1)
27 Source0: http://dl.sourceforge.net/gpac/%{name}-%{version}.tar.gz
28 # Source0-md5: a8b4b3206cabda946850240f1e7aea93
29 Source1: http://www.3gpp.org/ftp/Specs/archive/26_series/26.073/26073-530.zip
30 # Source1-md5: 705f6993fbf890e92eb7a331e7c716d1
31 Patch0: %{name}-install.patch
32 Patch1: %{name}-wxWidgets.patch
33 Patch2: %{name}-amd64.patch
34 Patch3: %{name}-libdir.patch
35 URL: http://gpac.sourceforge.net/
36 BuildRequires: SDL-devel
37 %{?with_faad:BuildRequires: faad2-devel}
38 %{?with_ffmpeg:BuildRequires: ffmpeg-devel}
39 %{?with_freetype:BuildRequires: freetype-devel}
40 %{?with_js:BuildRequires: js-devel}
41 %{?with_jpeg:BuildRequires: libjpeg-devel}
42 %{?with_mad:BuildRequires: libmad-devel}
43 %{?with_png:BuildRequires: libpng-devel}
44 BuildRequires: libxml2-devel
45 BuildRequires: rpmbuild(macros) >= 1.236
46 %{?with_wx:BuildRequires: wxGTK2-devel >= 2.5.4}
47 %{?with_xvid:BuildRequires: xvid-devel}
49 %{?with_faad:Requires: faad2}
50 %{?with_ffmpeg:Requires: ffmpeg}
51 %{?with_freetype:Requires: freetype}
52 %{?with_js:Requires: js}
53 %{?with_jpeg:Requires: libjpeg}
54 %{?with_mad:Requires: libmad}
55 %{?with_png:Requires: libpng}
56 %{?with_xvid:Requires: xvid}
57 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59 %define _noautoreq libm4systems.so
60 %define _plugindir %{_libdir}/browser-plugins
63 GPAC is an implementation of the MPEG-4 Systems standard (ISO/IEC
64 14496-1) developed from scratch in ANSI C.
66 The main development goal is to provide a clean (a.k.a. readable by as
67 many people as possible), small and flexible alternative to the MPEG-4
68 Systems reference software (known as IM1 and distributed in ISO/IEC
69 14496-5). The MPEG-4 Reference software is indeed a very large piece
70 of software, designed to verify the standard rather than provide a
71 small, production-stable software. GPAC is written in ANSI C for
72 portability reasons (embedded platforms and DSPs) with a simple goal:
73 keep the memory footprint as low as possible. The project will at term
74 provide player(s), systems encoders and publishing tools for content
78 GPAC to implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1)
79 stworzona od zera w ANSI C.
81 G³ównym celem tworzenia jej jest dostarczenie czystej (tzn. czytelnej
82 dla jak najwiêkszej liczby ludzi), ma³ej i elastycznej alternatywy dla
83 wzorcowego oprogramowania MPEG-4 Systems (znanego jako IM1 i
84 rozprowadzanego w ISO/IEC 14496-5). Wzorcowe oprogramowanie MPEG-4
85 jest bardzo du¿± porcj± kodu, zaprojektowan± raczej do zweryfikowania
86 standardu ni¿ dostarczenia ma³ej, stabilnej wersji produkcyjnej. GPAC
87 jest pisany w ANSI C ze wzglêdu na przeno¶no¶æ (platformy wbudowane i
88 DSP) z prostym celem: wymagaæ tak ma³o pamiêci, jak to tylko mo¿liwe.
89 Projekt docelowo dostarczy odtwarzacz(e), kodery systemowe i narzêdzia
90 do publikacji w celu dystrybucji materia³ów.
92 %package -n browser-plugin-%{name}
93 Summary: GPAC browser plugin
94 Summary(pl): Wtyczka GPAC do przegl±derek WWW
96 Requires: %{name} = %{version}-%{release}
97 Requires: browser-plugins(%{_target_cpu})
99 %define browsers mozilla, mozilla-firefox
101 %description -n browser-plugin-%{name}
102 GPAC plugin for Netscape-compatible WWW browsers.
104 Supported browsers: %{browsers}.
106 %description -n browser-plugin-%{name} -l pl
107 Wtyczka GPAC dla przegl±darek WWW zgodnych z Netscape.
109 Obs³ugiwane przegl±darki: %{browsers}.
114 %{?with_wx:%patch1 -p1}
118 mkdir -p Plugins/amr_dec/AMR_NB
119 cd Plugins/amr_dec/AMR_NB
121 unzip -j 26073-530_ANSI_C_source_code.zip
126 # files for w32 and Linux were swapped
127 rm -rf applications/osmozilla/nsIOsmozilla.xpt_linux
128 mv applications/osmozilla/nsIOsmozilla.xpt_w32 applications/osmozilla/nsIOsmozilla.xpt_linux
132 --extra-cflags="-fPIC" \
133 --extra-ldflags="-fPIC" \
135 %{?with_amr:--enable-amr-nb} \
136 %{!?with_faad:--disable-faad} \
137 %{!?with_ffmpeg:--disable-ffmpeg} \
138 %{!?with_freetype:--disable-ft} \
139 %{!?with_jpeg:--disable-jpeg} \
140 %{!?with_js:--disable-js} \
141 %{!?with_mad:--disable-mad} \
142 %{!?with_png:--disable-png} \
143 %{!?with_xvid:--disable-xvid}
146 XLIBDIR="/usr/X11R6/%{_lib}" \
147 DESTDIR=$RPM_BUILD_ROOT
150 rm -rf $RPM_BUILD_ROOT
153 bindir=$RPM_BUILD_ROOT%{_bindir} \
154 libdir=$RPM_BUILD_ROOT%{_libdir} \
155 mandir=$RPM_BUILD_ROOT%{_mandir} \
156 plugdir=$RPM_BUILD_ROOT%{_libdir}/gpac \
157 real_plugdir=%{_libdir}/gpac \
158 prefix=$RPM_BUILD_ROOT%{_prefix} \
159 MOZILLA_DIR=$RPM_BUILD_ROOT%{_plugindir}
162 rm -rf $RPM_BUILD_ROOT
164 %post -p /sbin/ldconfig
165 %postun -p /sbin/ldconfig
167 %triggerin -n browser-plugin-%{name} -- mozilla-firefox
168 %nsplugin_install -d %{_libdir}/mozilla-firefox/plugins nposmozilla.so nposmozilla.xpt
170 %triggerun -n browser-plugin-%{name} -- mozilla-firefox
171 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins nposmozilla.so nposmozilla.xpt
173 %triggerin -n browser-plugin-%{name} -- mozilla-firefox-bin
174 %nsplugin_install -d %{_libdir}/mozilla-firefox-bin/plugins nposmozilla.so nposmozilla.xpt
176 %triggerun -n browser-plugin-%{name} -- mozilla-firefox-bin
177 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox-bin/plugins nposmozilla.so nposmozilla.xpt
179 %triggerin -n browser-plugin-%{name} -- mozilla
180 %nsplugin_install -d %{_libdir}/mozilla/plugins nposmozilla.so nposmozilla.xpt
181 if [ -d /usr/%{_lib}/mozilla ]; then
183 rm -f /usr/%{_lib}/mozilla/components/{compreg,xpti}.dat
184 if [ -x /usr/bin/regxpcom ]; then
185 MOZILLA_FIVE_HOME=/usr/%{_lib}/mozilla /usr/bin/regxpcom
189 %triggerun -n browser-plugin-%{name} -- mozilla
190 %nsplugin_uninstall -d %{_libdir}/mozilla/plugins nposmozilla.so nposmozilla.xpt
191 if [ -d /usr/%{_lib}/mozilla ]; then
193 rm -f /usr/%{_lib}/mozilla/components/{compreg,xpti}.dat
194 if [ -x /usr/bin/regxpcom ]; then
195 MOZILLA_FIVE_HOME=/usr/%{_lib}/mozilla /usr/bin/regxpcom
200 %defattr(644,root,root,755)
201 %doc AUTHORS BUGS Changelog README TODO
202 %attr(755,root,root) %{_bindir}/*
203 %attr(755,root,root) %{_libdir}/lib*.so
205 %attr(755,root,root) %{_libdir}/gpac/*.so
208 %files -n browser-plugin-%{name}
209 %defattr(644,root,root,755)
210 %attr(755,root,root) %{_plugindir}/nposmozilla.so
211 %{_plugindir}/nposmozilla.xpt