]> git.pld-linux.org Git - packages/opera.git/blame - opera.spec
up to 12.15
[packages/opera.git] / opera.spec
CommitLineData
a79ddb02
AM
1# BRANCHES:
2# - HEAD - stable version
3# - DEVEL - development version
083d2812 4# - WEEKLY - weekly development version
ad7d3ceb 5# - NEXT - opera next
083d2812
AM
6#
7# NOTE: to avoid creating unreadable/unmaintainable spec:
8# - don't put static version here, create STATIC branch for that for example
9# - don't create useless bconds that for example limit SourceX: to current arch only
10#
edbbe593 11
02bb2221 12%define ver 12.15
083d2812 13%define shver %(echo %{ver} | tr -d .)
02bb2221 14%define buildid 1748
5422068c 15
40d43d2d 16Summary: World fastest web browser
048a8afa 17Summary(hu.UTF-8): A világ leggyorsabb webböngészője
0580138e 18Summary(pl.UTF-8): Najszybsza przeglądarka WWW na świecie
40d43d2d 19Name: opera
37147bb6 20Version: %{ver}
28875c85 21Release: 3
94132831 22Epoch: 2
ae712f51 23License: Distributable
40d43d2d 24Group: X11/Applications/Networking
f486f8e4 25Source10: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{name}-%{version}-%{buildid}.i386.linux.tar.xz
02bb2221 26# Source10-md5: 5a18cce4635fd2930be54649b4dabaee
f486f8e4 27Source11: ftp://ftp.opera.com/pub/opera/linux/%{shver}/%{name}-%{version}-%{buildid}.x86_64.linux.tar.xz
02bb2221 28# Source11-md5: 59e1bb087e5861126a296ef0a68df8a4
083d2812 29Source0: %{name}.desktop
35677f25 30Patch0: %{name}-wrapper.patch
25718300
AM
31Patch1: %{name}-desktop.patch
32Patch2: %{name}-pluginpath.patch
8cb331c2 33URL: http://www.opera.com/
55fc796b 34BuildRequires: rpm >= 4.4.9-56
f6dbdb8e 35BuildRequires: rpmbuild(macros) >= 1.356
6eebcb83 36BuildRequires: sed >= 4.0
f486f8e4 37BuildRequires: xz
ea04865f
AF
38Requires(post,postun): gtk-update-icon-cache
39Requires(post,postun): hicolor-icon-theme
9c325492 40Requires(post,postun): shared-mime-info
f6dbdb8e 41Requires: browser-plugins >= 2.0
c33af227 42Requires: desktop-file-utils
2f4fa75a 43Requires: freetype >= 2
9c325492
AM
44Suggests: gstreamer-theora
45Suggests: gstreamer-vorbis
3b8cc5d5 46Provides: wwwbrowser
37147bb6 47Obsoletes: opera-i18n
9c325492 48ExclusiveArch: %{ix86} %{x8664}
8cb331c2 49BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
1e3271ab 50
0539d577
AM
51%define _enable_debug_packages 0
52
141de986
ER
53%define _noautoreq 'libcurl.so.4\\(CURL_OPENSSL_3\\)'
54
fa79b8f2 55%define _plugindir %{_libdir}/opera/plugins
7e80713c 56%define _operadocdir %{_docdir}/%{name}-%{ver}
083d2812
AM
57# alternative arch for plugin32
58%define alt_arch i386
8cb331c2 59
60%description
61Opera is world fastest web browser. It supports most of nowaday
55fc796b
ER
62extensions of HTML. And it is quite stable. This version is linked
63with shared version of Qt.
8cb331c2 64
048a8afa
ZU
65%description -l hu.UTF-8
66Opera a világ leggyorsabb webböngészője. A manapság elterjedt
67HTML-kiterjesztések túlnyomó többségét támogatja. És elég stabili is.
68Ez a verzió a Qt megosztott verziójához linkelődik.
69
14283174
JR
70%description -l pl.UTF-8
71Opera jest najszybszą przeglądarką WWW na świecie. Obsługuje większość
72dzisiejszych rozszerzeń HTML-a. Dodatkowo jest w miarę stabilna. Ta
083d2812 73wersja jest skonsolidowana dynamicznie z Qt.
37147bb6
AM
74
75%package plugin32
76Summary: Opera 32-bit plugins support
048a8afa 77Summary(hu.UTF-8): Opera 32-bites plugin támogatás
37147bb6
AM
78Summary(pl.UTF-8): Obsługa 32-bitowych wtyczek Opery
79Group: X11/Applications/Networking
80Requires: %{name} = %{epoch}:%{version}-%{release}
083d2812 81Requires: browser-plugins >= 2.0
37147bb6
AM
82
83%description plugin32
84Opera 32-bit plugins support.
85
048a8afa
ZU
86%description plugin32 -l hu.UTF-8
87Opera 32-bites plugin támogatás.
88
37147bb6
AM
89%description plugin32 -l pl.UTF-8
90Obsługa 32-bitowych wtyczek Opery.
58d714bb 91
8cb331c2 92%prep
643785f9 93%ifarch %{ix86}
07d1040c 94%setup -q -T -b 10 -n %{name}-%{version}-%{buildid}.i386.linux
e789f1d0 95%endif
07d1040c 96
083d2812 97%ifarch %{x8664}
07d1040c 98%setup -q -T -b 11 -n %{name}-%{version}-%{buildid}.x86_64.linux
3009d733 99%endif
07d1040c 100
e77215ac 101%{__sed} -i -e '
25718300
AM
102 s,@@{PREFIX},%{_prefix},g
103 s,@@{SUFFIX},,
104 s,@@{_SUFFIX},,
105' share/{applications/*.desktop,mime/packages/*.xml}
106
e77215ac 107%{__sed} -i -e 's,kfmclient exec,xdg-open,' share/opera/defaults/filehandler.ini
25718300 108
35677f25 109%patch0 -p1
25718300
AM
110%patch1 -p1
111
112# remove lib32/lib64 paths so patch2 can apply (i386 build contained lib64 as well, oh well)
113%{__sed} -i -e '/lib32\|lib64/d;$d' share/opera/defaults/pluginpath.ini
114%patch2 -p1
115
116mv lib/opera/plugins/README README.plugins
117mv share/opera/defaults/license.txt .
118mv share/doc/opera/* .
119
120# nobody wants scalable huge icons
121rm -rf share/icons/hicolor/scalable
122
123# opera packaging tools we don't need runtime
65c4880d 124mv share/opera/package-id.ini .
8cb331c2 125
e77215ac
ER
126# cleanup backups after patching
127find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
128
8cb331c2 129%install
130rm -rf $RPM_BUILD_ROOT
07d1040c 131install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},%{_datadir},%{_pixmapsdir},%{_desktopdir},%{_sysconfdir}}
8cb331c2 132
f6dbdb8e
ER
133%browser_plugins_add_browser %{name} -p %{_libdir}/%{name}/plugins -b <<'EOF'
134# opera does not use for .xpt files
135*.xpt
6ab3a1e1
ER
136
137# use mplayerplug-in-opera instead
138mplayerplug-in*
f6dbdb8e
ER
139EOF
140
07d1040c
AM
141install -p opera* $RPM_BUILD_ROOT%{_bindir}
142cp -a lib/opera $RPM_BUILD_ROOT%{_libdir}
143cp -a share/* $RPM_BUILD_ROOT%{_datadir}
28875c85 144ln -s %{_docdir}/%{name}-%{version}/LICENSE $RPM_BUILD_ROOT%{_datadir}/%{name}/defaults/license.txt
25718300 145#cp -a etc/*.ini $RPM_BUILD_ROOT%{_sysconfdir}
6239047a 146
07d1040c 147sed -i -e 's#/usr/lib/opera#%{_libdir}/opera#g' $RPM_BUILD_ROOT%{_bindir}/opera
72b0ae2b 148
0539d577
AM
149cat << 'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/operaprefs_default.ini
150[ISP]
151Id="DISTRO"
152EOF
153
201511be
AM
154%if "%{pld_release}" == "ti"
155sed -i -e 's#DISTRO#PLD/Titanium#g' $RPM_BUILD_ROOT/etc/operaprefs_default.ini
156%else
157%if "%{pld_release}" == "ac"
158sed -i -e 's#DISTRO#PLD/2.0 (Ac)#g' $RPM_BUILD_ROOT/etc/operaprefs_default.ini
159%else
160sed -i -e 's#DISTRO#PLD/3.0 (Th)#g' $RPM_BUILD_ROOT/etc/operaprefs_default.ini
161%endif
162%endif
201511be 163
8cb331c2 164%clean
165rm -rf $RPM_BUILD_ROOT
166
f6dbdb8e 167%post
25718300
AM
168%update_mime_database
169%update_icon_cache hicolor
170%update_desktop_database_post
f6dbdb8e
ER
171%update_browser_plugins
172
173%postun
25718300
AM
174%update_mime_database
175%update_icon_cache hicolor
176%update_desktop_database_postun
f6dbdb8e
ER
177if [ "$1" = 0 ]; then
178 %update_browser_plugins
179fi
180
083d2812
AM
181%post plugin32
182%update_browser_plugins
183
184%postun plugin32
185if [ "$1" = 0 ]; then
186 %update_browser_plugins
187fi
188
8cb331c2 189%files
190%defattr(644,root,root,755)
c2ef0548 191%doc LICENSE
9c325492 192%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/opera*ini
f6dbdb8e
ER
193
194# browser plugins v2
07d1040c
AM
195%{_browserpluginsconfdir}/browsers.d/%{name}.*
196%config(noreplace) %verify(not md5 mtime size) %{_browserpluginsconfdir}/blacklist.d/%{name}.*.blacklist
9c325492 197
07d1040c 198%attr(755,root,root) %{_bindir}/opera
65c4880d 199#%attr(755,root,root) %{_bindir}/opera-widget-manager
1e3271ab 200%dir %{_libdir}/opera
37147bb6 201%ifarch %{x8664}
654f5fb1 202%exclude %{_libdir}/opera/pluginwrapper/*-ia32-*
37147bb6 203%endif
07d1040c
AM
204%attr(755,root,root) %{_libdir}/opera/*.so
205%attr(755,root,root) %{_libdir}/opera/opera*
a8b69975 206%dir %{_libdir}/opera/pluginwrapper
50496054 207%attr(755,root,root) %{_libdir}/opera/pluginwrapper/*
1e3271ab 208%dir %{_plugindir}
07d1040c
AM
209%dir %{_libdir}/opera/gstreamer
210%dir %{_libdir}/opera/gstreamer/plugins
211%attr(755,root,root) %{_libdir}/opera/gstreamer/plugins/libgstoperamatroska.so
212%attr(755,root,root) %{_libdir}/opera/gstreamer/plugins/libgstoperavp8.so
a5b49fac 213%dir %{_datadir}/opera
9c325492 214%{_datadir}/mime/packages/opera-extension.xml
a5b49fac 215%{_datadir}/opera/*.*
628633e1
AM
216%{_datadir}/opera/defaults
217%{_datadir}/opera/extra
a5b49fac 218%{_datadir}/opera/skin
9c325492 219#%{_datadir}/opera/scripts
a5b49fac 220%{_datadir}/opera/styles
628633e1 221%{_datadir}/opera/ui
65c4880d 222#%{_datadir}/opera/unite
f8b4ca83 223%dir %{_datadir}/opera/locale
224%{_datadir}/opera/locale/en
ad7d3ceb 225%lang(af) %{_datadir}/opera/locale/af
65c4880d 226%lang(ar) %{_datadir}/opera/locale/ar
ad7d3ceb 227%lang(az) %{_datadir}/opera/locale/az
37147bb6
AM
228%lang(be) %{_datadir}/opera/locale/be
229%lang(bg) %{_datadir}/opera/locale/bg
ad7d3ceb 230%lang(bn) %{_datadir}/opera/locale/bn
37147bb6
AM
231%lang(cs) %{_datadir}/opera/locale/cs
232%lang(da) %{_datadir}/opera/locale/da
233%lang(de) %{_datadir}/opera/locale/de
234%lang(el) %{_datadir}/opera/locale/el
235%lang(en_GB) %{_datadir}/opera/locale/en-GB
07d1040c 236%lang(es_ES) %{_datadir}/opera/locale/es-ES
37147bb6 237%lang(es_LA) %{_datadir}/opera/locale/es-LA
bd7f9e14 238%lang(et) %{_datadir}/opera/locale/et
65c4880d 239%lang(fa) %{_datadir}/opera/locale/fa
37147bb6
AM
240%lang(fi) %{_datadir}/opera/locale/fi
241%lang(fr) %{_datadir}/opera/locale/fr
242%lang(fr_CA) %{_datadir}/opera/locale/fr-CA
243%lang(fy) %{_datadir}/opera/locale/fy
9c325492 244%lang(gd) %{_datadir}/opera/locale/gd
65c4880d 245%lang(he) %{_datadir}/opera/locale/he
37147bb6
AM
246%lang(hi) %{_datadir}/opera/locale/hi
247%lang(hr) %{_datadir}/opera/locale/hr
248%lang(hu) %{_datadir}/opera/locale/hu
ff88e30e 249%lang(id) %{_datadir}/opera/locale/id
37147bb6
AM
250%lang(it) %{_datadir}/opera/locale/it
251%lang(ja) %{_datadir}/opera/locale/ja
252%lang(ka) %{_datadir}/opera/locale/ka
65c4880d 253%lang(kk) %{_datadir}/opera/locale/kk
37147bb6
AM
254%lang(ko) %{_datadir}/opera/locale/ko
255%lang(lt) %{_datadir}/opera/locale/lt
8f8f9fc6 256%lang(lt) %{_datadir}/opera/locale/lv
ad7d3ceb 257%lang(me) %{_datadir}/opera/locale/me
37147bb6 258%lang(mk) %{_datadir}/opera/locale/mk
ad7d3ceb 259%lang(ms) %{_datadir}/opera/locale/ms
37147bb6
AM
260%lang(nb) %{_datadir}/opera/locale/nb
261%lang(nl) %{_datadir}/opera/locale/nl
262%lang(nn) %{_datadir}/opera/locale/nn
ad7d3ceb 263%lang(pa) %{_datadir}/opera/locale/pa
37147bb6
AM
264%lang(pl) %{_datadir}/opera/locale/pl
265%lang(pt) %{_datadir}/opera/locale/pt
266%lang(pt_BR) %{_datadir}/opera/locale/pt-BR
628633e1 267%lang(ro) %{_datadir}/opera/locale/ro
37147bb6 268%lang(ru) %{_datadir}/opera/locale/ru
628633e1
AM
269%lang(sk) %{_datadir}/opera/locale/sk
270%lang(sr) %{_datadir}/opera/locale/sr
37147bb6 271%lang(sv) %{_datadir}/opera/locale/sv
ad7d3ceb 272%lang(sw) %{_datadir}/opera/locale/sw
bd7f9e14
AM
273%lang(ta) %{_datadir}/opera/locale/ta
274%lang(te) %{_datadir}/opera/locale/te
ad7d3ceb
AM
275%lang(th) %{_datadir}/opera/locale/th
276%lang(tl) %{_datadir}/opera/locale/tl
37147bb6 277%lang(tr) %{_datadir}/opera/locale/tr
ff88e30e 278%lang(uk) %{_datadir}/opera/locale/uk
65c4880d 279%lang(ur) %{_datadir}/opera/locale/ur
ad7d3ceb 280%lang(uz) %{_datadir}/opera/locale/uz
66f1ccb5 281%lang(vi) %{_datadir}/opera/locale/vi
37147bb6 282%lang(zh_CN) %{_datadir}/opera/locale/zh-cn
9c325492 283#%lang(zh_HK) %{_datadir}/opera/locale/zh-hk
37147bb6 284%lang(zh_TW) %{_datadir}/opera/locale/zh-tw
ad7d3ceb 285%lang(zu) %{_datadir}/opera/locale/zu
2fd32239 286%{_datadir}/opera/region
65c4880d 287#%{_datadir}/mime/packages/opera-widget.xml
288#%{_datadir}/mime/packages/opera-unite-application.xml
7b1a5f81 289%{_desktopdir}/*.desktop
1e3271ab 290%{_mandir}/man1/opera.1*
65c4880d 291#%{_mandir}/man1/opera-widget-manager.1*
9c325492 292#%{_pixmapsdir}/opera.xpm
07d1040c 293%{_iconsdir}/hicolor/*/*/*.png
671735f8
AM
294
295%ifarch %{x8664}
296%files plugin32
297%defattr(644,root,root,755)
654f5fb1 298%attr(755,root,root) %{_libdir}/opera/pluginwrapper/*-ia32-*
671735f8 299%endif
This page took 0.142522 seconds and 4 git commands to generate.