]> git.pld-linux.org Git - packages/opera.git/blob - opera.spec
- create symlink instead of removing wrapper
[packages/opera.git] / opera.spec
1 #
2 # There're some problems with "shared" version
3 #
4 %bcond_with     shared
5
6 %define ver             7.23
7 %define dirrel          20031119
8 %define shared_rel      %{dirrel}.5
9 %define static_rel      %{dirrel}.1
10 %if %{with shared}
11 %define rel             %{shared_rel}
12 %define type            shared
13 %else
14 %define rel             %{static_rel}
15 %define type            static
16 %endif
17 Summary:        World fastest web browser
18 Summary(pl):    Najszybsza przegl±darka WWW na ¶wiecie
19 Name:           opera
20 Version:        %{ver}.%{rel}
21 Release:        2
22 License:        Restricted, see file LICENSE
23 Group:          X11/Applications/Networking
24 Source0:        ftp://ftp.opera.com/pub/opera/linux/723/final/en/i386/static/%{name}-%{ver}-%{static_rel}-static-qt.i386-en.tar.bz2
25 Source1:        ftp://ftp.opera.com/pub/opera/linux/723/final/en/sparc/static/%{name}-%{ver}-%{static_rel}-static-qt.sparc-en.tar.bz2
26 Source2:        ftp://ftp.opera.com/pub/opera/linux/723/final/en/ppc/static/%{name}-%{ver}-%{static_rel}-static-qt.ppc-en.tar.bz2
27 # polish language file (taken from where?)
28 Source3:        %{name}-2887.lng
29 Source4:        %{name}.desktop
30 Source20:       ftp://ftp.opera.com/pub/opera/linux/723/final/en/i386/shared/%{name}-%{ver}-%{shared_rel}-shared-qt.i386-en.tar.bz2
31 Source21:       ftp://ftp.opera.com/pub/opera/linux/723/final/en/sparc/shared/gcc-2.95/%{name}-%{ver}-%{dirrel}.2-shared-qt.sparc-en.tar.bz2
32 Source22:       ftp://ftp.opera.com/pub/opera/linux/723/final/en/ppc/shared/gcc-2.95/%{name}-%{ver}-%{dirrel}.2-shared-qt.ppc-en.tar.bz2
33 NoSource:       0
34 NoSource:       1
35 NoSource:       2
36 NoSource:       20
37 NoSource:       21
38 NoSource:       22
39 URL:            http://www.opera.com/
40 ExclusiveArch:  %{ix86} ppc sparc sparc64
41 Requires:       freetype >= 2
42 Requires:       openmotif >= 2
43 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44
45 %define         _plugindir      %{_libdir}/opera/plugins
46 %define         _operadocdir    %{_docdir}/%{name}-%{ver}.%{rel}
47 %define         configfile      %{_datadir}/opera/config/opera6rc
48
49 %description
50 Opera is world fastest web browser. It supports most of nowaday
51 extensions of HTML. And it is quite stable. Only disadvantage are
52 advertisements on the top of its window. Version static linked with
53 qt.
54
55 %description -l pl
56 Opera jest najszybsz± przegl±dark± WWW na ¶wiecie. Obs³uguje wiêkszo¶æ
57 dzisiejszych rozszerzeñ HTMLa. Dodatkowo jest w miarê stabilna. Jedyn±
58 niedogodno¶ci± s± reklamy ukazuj±ce siê w górze okna. Wersja
59 statycznie skonsolidowana z qt.
60
61 %prep
62 %ifarch %{ix86}
63 %setup -q %{?_with_shared:-T -b 20} -n %{name}-%{ver}-%{rel}-%{type}-qt.i386-en
64 %endif
65 %ifarch sparc sparc64
66 %setup -q -T -b %{?_with_shared:2}1 -n %{name}-%{ver}-%{rel}-%{type}-qt.sparc-en
67 %endif
68 %ifarch ppc
69 %setup -q -T -b %{?_with_shared:2}2 -n %{name}-%{ver}-%{rel}-%{type}-qt.ppc-en
70 %endif
71
72 %install
73 rm -rf $RPM_BUILD_ROOT
74
75 install -d $RPM_BUILD_ROOT{/etc,%{_mandir}/man1,%{_pixmapsdir},%{_desktopdir}}
76
77 cat install.sh | sed 's|/etc|$RPM_BUILD_ROOT%{_sysconfdir}|' > install2.sh
78 mv install2.sh install.sh
79
80 echo y |\
81 sh install.sh \
82   --prefix=$RPM_BUILD_ROOT%{_prefix} \
83   --wrapperdir=$RPM_BUILD_ROOT%{_bindir} \
84   --docdir=$RPM_BUILD_ROOT%{_operadocdir} \
85   --sharedir=$RPM_BUILD_ROOT%{_datadir}/opera \
86   --exec_prefix=$RPM_BUILD_ROOT%{_datadir}/opera/bin \
87   --plugindir=$RPM_BUILD_ROOT%{_plugindir}
88
89 # Polish locale
90 install %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/opera/locale/
91
92 # man install
93 install man/opera.1 $RPM_BUILD_ROOT%{_mandir}/man1
94
95 # wrapper correction
96 sed s#$RPM_BUILD_ROOT## > $RPM_BUILD_ROOT%{_bindir}/opera2 $RPM_BUILD_ROOT%{_bindir}/opera
97 mv $RPM_BUILD_ROOT%{_bindir}/opera2 $RPM_BUILD_ROOT%{_bindir}/opera
98
99 # install in kde etc.
100 install images/opera.xpm $RPM_BUILD_ROOT%{_pixmapsdir}
101
102 install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}
103
104 # symlink który niweluje burkanie siê opery :>
105 #ln -sf %{_datadir}/opera/ $RPM_BUILD_ROOT/usr/share/
106 #ln -sf %{_libdir}/opera $RPM_BUILD_ROOT/usr/lib/
107
108 sed -i -e "s#$RPM_BUILD_ROOT##g" $RPM_BUILD_ROOT%{_datadir}/opera/java/*.policy
109
110 # always use wrapper linked with libXm.so.3
111 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/operamotifwrapper
112 ln -sf operamotifwrapper-3 $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/operamotifwrapper
113
114 %clean
115 rm -rf $RPM_BUILD_ROOT
116
117 %files
118 %defattr(644,root,root,755)
119 %doc LICENSE bugreport help
120 %attr(755,root,root) %{_bindir}/*
121 %dir %{_datadir}/opera
122 %dir %{_datadir}/opera/bin
123 %attr(755,root,root) %{_datadir}/opera/bin/*
124 %{_datadir}/opera/config
125 %{_datadir}/opera/help
126 %{_datadir}/opera/images
127 %{_datadir}/opera/java
128 %{_datadir}/opera/locale
129 %{_datadir}/opera/skin
130 %{_datadir}/opera/styles
131 %{_datadir}/opera/ini
132 %{_datadir}/opera/search.ini
133 %{_datadir}/opera/*.html
134 %{_datadir}/opera/*.ssr
135 %{_datadir}/opera/*.txt
136 %ifarch %{ix86}
137 %attr(755,root,root) %{_datadir}/opera/chartables.bin
138 %endif
139 %ifarch ppc
140 %attr(755,root,root) %{_datadir}/opera/chartables-be.bin
141 %endif
142 %attr(755,root,root) %{_datadir}/opera/opera6.adr
143 %dir %{_libdir}/opera
144 %dir %{_plugindir}
145 %attr(755,root,root) %{_plugindir}/*
146
147 %{_pixmapsdir}/opera.xpm
148 %{_desktopdir}/*.desktop
149
150 %{_mandir}/man1/opera.1*
This page took 0.413933 seconds and 4 git commands to generate.