2 # - move translations into a separate, noarch package
4 %bcond_without shared # static or shared version
5 %bcond_without distributable # distributable or not
6 %bcond_without incall # include all tarballs into src.rpm (but splitted into shared/static)
7 %bcond_with snap # snap version
11 %define dirrel 20040824
12 %define reltype Preview-1
15 %define dirrel 20040803
19 %define shver %(echo %{ver} | tr -d .)
20 %define x86_shared_rel %{dirrel}.5
21 %define x86_static_rel %{dirrel}.1
22 %define sparc_shared_rel %{dirrel}.2
23 %define sparc_static_rel %{dirrel}.1
24 %define ppc_shared_rel %{dirrel}.2
25 %define ppc_static_rel %{dirrel}.1
28 # We should be able to build src.rpm also on not supported archs
29 %define rel %{x86_shared_rel}
31 %define rel %{sparc_shared_rel}
34 %define rel %{ppc_shared_rel}
38 %define rel %{x86_static_rel}
40 %define rel %{sparc_static_rel}
43 %define rel %{ppc_static_rel}
53 %define need_ix86_shared_snap 1
54 %define need_sparc_shared_snap 1
55 %define need_ppc_shared_snap 1
58 %define need_ix86_static_snap 1
59 %define need_sparc_static_snap 1
60 %define need_ppc_static_snap 1
62 # with shared; [endif]
67 %define need_ix86_shared 1
68 %define need_sparc_shared 1
69 %define need_ppc_shared 1
72 %define need_ix86_static 1
73 %define need_sparc_static 1
74 %define need_ppc_static 1
76 # with shared; [endif]
87 %define need_ix86_shared_snap 1
90 %define need_ix86_static_snap 1
92 # with shared; [endif]
97 %define need_ix86_shared 1
100 %define need_ix86_static 1
102 # with shared; [endif]
107 %ifarch sparc sparc64
113 %define need_sparc_shared_snap 1
115 # with shared: [else]
116 %define need_sparc_static_snap 1
118 # with shared; [endif]
123 %define need_sparc_shared 1
125 # with shared: [else]
126 %define need_sparc_static 1
128 # with shared; [endif]
139 %define need_ppc_shared_snap 1
141 # with shared: [else]
142 %define need_ppc_static_snap 1
144 # with shared; [endif]
149 %define need_ppc_shared 1
151 # with shared: [else]
152 %define need_ppc_static 1
154 # with shared; [endif
160 # with incall; [endif]
162 Summary: World fastest web browser
163 Summary(pl): Najszybsza przegl±darka WWW na ¶wiecie
165 Version: %{ver}%{?with_snap:.%{rel}}
168 License: Distributable for PLD until 31 Dec 2006 - http://distribute.opera.com/ (otherwise restricted, see file LICENSE)
169 Group: X11/Applications/Networking
171 %if %{need_ix86_static}
172 Source0: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/i386/static/%{name}-%{ver}-%{x86_static_rel}-static-qt.i386-en.tar.bz2
173 # Source0-md5: 0a7e933ef593d4b7a897041c9f87bba2
174 %{!?with_distributable:NoSource: 0}
177 %if %{need_ix86_static_snap}
178 Source100: http://snapshot.opera.com/unix/%{ver}-%{reltype}/intel-linux/en/%{name}-%{ver}-%{x86_static_rel}-static-qt.i386-en.tar.bz2
179 %{!?with_distributable:NoSource: 100}
182 %if %{need_sparc_static}
183 Source1: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/sparc/static/%{name}-%{ver}-%{sparc_static_rel}-static-qt.sparc-en.tar.bz2
184 # Source1-md5: 04976a6ace7a4345ce5e4cf763159939
185 %{!?with_distributable:NoSource: 1}
188 %if %{need_sparc_static_snap}
189 #Source101: http://snapshot.opera.com/unix/%{ver}-%{reltype}/sparc-linux/en/%{name}-%{ver}-%{sparc_static_rel}-static-qt.sparc-en.tar.bz2
190 %{!?with_distributable:NoSource: 101}
193 %if %{need_ppc_static}
194 Source2: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/ppc/static/%{name}-%{ver}-%{ppc_static_rel}-static-qt.ppc-en.tar.bz2
195 # Source2-md5: c11a4c78d18bdaa4bd338b4c0dc27f38
196 %{!?with_distributable:NoSource: 2}
199 %if %{need_ppc_static_snap}
200 Source102: http://snapshot.opera.com/unix/%{ver}-%{reltype}/ppc-linux/en/%{name}-%{ver}-%{ppc_static_rel}-static-qt.ppc-en.tar.bz2
201 %{!?with_distributable:NoSource: 102}
204 %if %{need_ix86_shared}
205 Source20: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/i386/shared/%{name}-%{ver}-%{x86_shared_rel}-shared-qt.i386-en.tar.bz2
206 # Source20-md5: 0e407a050f3aa4559011a3cea707cd20
207 %{!?with_distributable:NoSource: 20}
210 %if %{need_ix86_shared_snap}
211 Source1020: http://snapshot.opera.com/unix/%{ver}-%{reltype}/intel-linux/en/%{name}-%{ver}-%{x86_shared_rel}-shared-qt.i386-en.tar.bz2
212 # Source1020-md5: da4df3c5d65057eac4e063b4359fafa6
213 %{!?with_distributable:NoSource: 1020}
216 %if %{need_sparc_shared}
217 Source21: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/sparc/shared/gcc-2.95/%{name}-%{ver}-%{sparc_shared_rel}-shared-qt.sparc-en.tar.bz2
218 # Source21-md5: d8635013dac0c98c680997fcc9dd66c4
219 %{!?with_distributable:NoSource: 21}
222 %if %{need_ix86_shared_snap}
223 #Source1021: http://snapshot.opera.com/unix/%{ver}-%{reltype}/sparc-linux/en/%{name}-%{ver}-%{sparc_shared_rel}-shared-qt.sparc-en.tar.bz2
224 %{!?with_distributable:NoSource: 1021}
227 %if %{need_ppc_shared}
228 Source22: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{reltype}/en/ppc/shared/gcc-2.95/%{name}-%{ver}-%{ppc_shared_rel}-shared-qt.ppc-en.tar.bz2
229 # Source22-md5: 516992e68c5a710d795a1ecc791c7f4d
230 %{!?with_distributable:NoSource: 22}
233 %if %{need_ppc_shared_snap}
234 Source1022: http://snapshot.opera.com/unix/%{ver}-%{reltype}/ppc-linux/en/%{name}-%{ver}-%{ppc_shared_rel}-shared-qt.ppc-en.tar.bz2
235 # Source1022-md5: 6496d9871a2ca7337377ed3ecc298559
236 %{!?with_distributable:NoSource: 1022}
239 Source4: %{name}.desktop
241 URL: http://www.opera.com/
242 ExclusiveArch: %{ix86} ppc sparc sparc64
243 Requires: freetype >= 2
244 Requires: openmotif >= 2
245 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
247 %define _plugindir %{_libdir}/opera/plugins
248 %define _operadocdir %{_docdir}/%{name}-%{ver}.%{rel}
249 %define configfile %{_datadir}/opera/config/opera6rc
252 Opera is world fastest web browser. It supports most of nowaday
253 extensions of HTML. And it is quite stable. Only disadvantage are
254 advertisements on the top of its window. Version static linked with
258 Opera jest najszybsz± przegl±dark± WWW na ¶wiecie. Obs³uguje wiêkszo¶æ
259 dzisiejszych rozszerzeñ HTML-a. Dodatkowo jest w miarê stabilna. Jedyn±
260 niedogodno¶ci± s± reklamy ukazuj±ce siê w górze okna. Wersja
261 statycznie skonsolidowana z qt.
265 %setup -q -T -b %{?with_snap:10}%{?with_shared:2}0 -n %{name}-%{ver}-%{rel}-%{type}-qt.i386-en
267 %ifarch sparc sparc64
268 %setup -q -T -b %{?with_snap:10}%{?with_shared:2}1 -n %{name}-%{ver}-%{rel}-%{type}-qt.sparc-en
271 %setup -q -T -b %{?with_snap:10}%{?with_shared:2}2 -n %{name}-%{ver}-%{rel}-%{type}-qt.ppc-en
275 rm -rf $RPM_BUILD_ROOT
277 install -d $RPM_BUILD_ROOT{/etc,%{_mandir}/man1,%{_pixmapsdir},%{_desktopdir}}
279 cat install.sh | sed 's|/etc|$RPM_BUILD_ROOT%{_sysconfdir}|' > install2.sh
280 mv install2.sh install.sh
284 --prefix=$RPM_BUILD_ROOT%{_prefix} \
285 --wrapperdir=$RPM_BUILD_ROOT%{_bindir} \
286 --docdir=$RPM_BUILD_ROOT%{_operadocdir} \
287 --sharedir=$RPM_BUILD_ROOT%{_datadir}/opera \
288 --exec_prefix=$RPM_BUILD_ROOT%{_datadir}/opera/bin \
289 --plugindir=$RPM_BUILD_ROOT%{_plugindir}
292 install man/opera.1 $RPM_BUILD_ROOT%{_mandir}/man1
295 sed s#$RPM_BUILD_ROOT## > $RPM_BUILD_ROOT%{_bindir}/opera2 $RPM_BUILD_ROOT%{_bindir}/opera
296 mv $RPM_BUILD_ROOT%{_bindir}/opera2 $RPM_BUILD_ROOT%{_bindir}/opera
298 # install in kde etc.
299 install images/opera.xpm $RPM_BUILD_ROOT%{_pixmapsdir}
301 install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}
303 # symlink który niweluje burkanie siê opery :>
304 #ln -sf %{_datadir}/opera/ $RPM_BUILD_ROOT/usr/share/
305 #ln -sf %{_libdir}/opera $RPM_BUILD_ROOT/usr/lib/
307 sed -i -e "s#$RPM_BUILD_ROOT##g" $RPM_BUILD_ROOT%{_datadir}/opera/java/*.policy
309 # always use wrapper linked with libXm.so.3
310 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/operamotifwrapper
311 ln -sf operamotifwrapper-3 $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/operamotifwrapper-2
312 ln -sf operamotifwrapper-3 $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/operamotifwrapper-1
314 # %{_libdir} is not the best place for it but opera doesn't search for it in better
316 install lib/spellcheck.so $RPM_BUILD_ROOT%{_libdir}
319 rm -rf $RPM_BUILD_ROOT
322 %defattr(644,root,root,755)
323 %doc LICENSE bugreport help
324 %attr(755,root,root) %{_bindir}/*
325 %dir %{_datadir}/opera
326 %dir %{_datadir}/opera/bin
327 %attr(755,root,root) %{_datadir}/opera/bin/*
328 %{_datadir}/opera/config
329 %{_datadir}/opera/help
330 %{_datadir}/opera/images
331 %{_datadir}/opera/java
332 %{_datadir}/opera/skin
333 %{_datadir}/opera/styles
334 %{_datadir}/opera/ini
335 %{_datadir}/opera/search.ini
336 %{_datadir}/opera/*.html
337 %{_datadir}/opera/*.ssr
338 %{_datadir}/opera/*.txt
340 %attr(755,root,root) %{_datadir}/opera/chartables.bin
343 %attr(755,root,root) %{_datadir}/opera/chartables-be.bin
345 %attr(755,root,root) %{_datadir}/opera/opera6.adr
346 %attr(755,root,root) %{_libdir}/*.so
347 %dir %{_libdir}/opera
349 %attr(755,root,root) %{_plugindir}/*
351 %dir %{_datadir}/opera/locale
352 %{_datadir}/opera/locale/en
353 %{_datadir}/opera/locale/english.lng
355 %{_pixmapsdir}/opera.xpm
356 %{_desktopdir}/*.desktop
358 %{_mandir}/man1/opera.1*