3 %bcond_with license_agreement # generates package
5 %define base_name acroread
6 Summary: Adobe Acrobat Reader
7 Summary(pl.UTF-8): Adobe Acrobat Reader - czytnik plików PDF
8 Summary(ru.UTF-8): Программа для чтения документов в формате PDF от Adobe
9 Summary(uk.UTF-8): Програма для читання документів у форматі PDF від Adobe
10 %if %{with license_agreement}
13 Name: %{base_name}-installer
17 Release: %{_rel}%{?with_license_agreement:wla}
19 License: distribution restricted (http://www.adobe.com/products/acrobat/distribute.html)
21 # - not distributable on public sites (only linking to adobe.com permitted)
22 # - distribution on CD requires signing Distribution Agreement (see URL above)
23 Group: X11/Applications/Graphics
24 %if %{with license_agreement}
25 Source0: http://ardownload.adobe.com/pub/adobe/reader/unix/8.x/%{version}/enu/AdobeReader_enu-%{version}-1.i486.tar.gz
26 # NoSource0-md5: e7630311c597feff26024c3383eab110
28 Source0: license-installer.sh
30 # please update @COPYSOURCES@ below if you add more Sources or Patches.
31 Source1: %{base_name}.desktop
32 Source2: %{base_name}.png
33 URL: http://www.adobe.com/products/acrobat/
34 %if %{with license_agreement}
35 BuildRequires: rpmbuild(macros) >= 1.236
36 Requires: openldap-libs >= 2.3
38 Requires: rpm-build-tools
40 ExclusiveArch: %{ix86}
41 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43 %define _plugindir %{_libdir}/browser-plugins
45 # TODO: galeon and skipstone, konqueror, opera.
46 # use macro, otherwise extra LF inserted along with the ifarch
47 %define browsers mozilla, mozilla-firefox, seamonkey
49 %define platform intellinux
50 %define tar0 ILINXR.TAR
51 %define tar1 COMMON.TAR
53 %define _noautostrip .*\.api
54 %define _noautoreq '^lib.*\.so$' '^lib.*\(VERSION\)$'
57 Adobe(R) Reader(R) is free software that lets you view and print PDF
58 files (Portable Document Format) on a variety of hardware and
59 operating system platforms.
61 %description -l pl.UTF-8
62 Adobe(R) Reader(R) jest darmowym oprogramowaniem umożliwiającym
63 oglądanie oraz drukowanie plików PDF (Portable Document Format) na
64 różnych platformach sprzętowych oraz różnych systemach operacyjnych.
66 %description -l ru.UTF-8
67 Программа для чтения документов в формате Portable Document Format
68 (PDF), сгенерированных Adobe Acrobat'ом.
70 %description -l uk.UTF-8
71 Програма для читання документів у форматі Portable Document Format
72 (PDF), згенерованих Adobe Acrobat'ом.
74 %package -n browser-plugin-%{name}
75 Summary: PDF plugin for Mozilla compatible browsers
76 Summary(pl.UTF-8): Wtyczka PDF dla przeglądarek zgodnych Mozilla
77 Group: X11/Applications
78 Requires: %{base_name} = %{epoch}:%{version}-%{release}
79 Requires: browser-plugins(%{_target_base_arch})
80 Obsoletes: acroread-plugin
81 Obsoletes: mozilla-plugin-acroread
83 %description -n browser-plugin-%{name}
84 A Mozilla plugin for displaying PDF (Portable Document Format) files.
86 %description -n browser-plugin-%{name} -l pl.UTF-8
87 Wtyczka Mozilli do wyświetlania plików PDF (Portable Document Format).
90 %if %{with license_agreement}
98 rm -rf $RPM_BUILD_ROOT
99 %if %{without license_agreement}
100 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
103 s/@BASE_NAME@/%{base_name}/g
104 s/@TARGET_CPU@/%{_target_cpu}/g
105 s-@VERSION@-%{version}-g
106 s-@RELEASE@-%{release}-g
107 s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g
108 s,@DATADIR@,%{_datadir}/%{base_name},g
109 s/@COPYSOURCES@/%{base_name}{.desktop,.png,-{expr,scim,gtk}.patch}/g
110 ' %{SOURCE0} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
112 install %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
113 install %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/%{base_name}
114 install %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/%{base_name}
117 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}/%{base_name},%{_plugindir}} \
118 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
120 # note: there're also AdobeReader/Adobe/Help{,Viewer}
121 cd AdobeReader/Adobe/Reader8
122 cp -a Reader Resource $RPM_BUILD_ROOT%{_libdir}/%{base_name}
123 awk -v INSTDIR=%{_libdir}/%{base_name}/Reader \
124 '/^install_dir=/ {print "install_dir="INSTDIR; next} \
126 bin/%{base_name} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}
127 install Browser/%{platform}/* $RPM_BUILD_ROOT%{_plugindir}
128 install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
129 install %{SOURCE2} $RPM_BUILD_ROOT%{_pixmapsdir}
131 rm -rf $RPM_BUILD_ROOT%{_libdir}/%{base_name}/Reader/Patch
133 ln -sf /usr/lib/liblber-2.3.so.0 $RPM_BUILD_ROOT%{_libdir}/%{base_name}/Reader/%{platform}/lib/liblber.so
134 ln -sf /usr/lib/libldap-2.3.so.0 $RPM_BUILD_ROOT%{_libdir}/%{base_name}/Reader/%{platform}/lib/libldap.so
135 ln -sf /usr/share/ssl/ca-bundle.crt $RPM_BUILD_ROOT%{_libdir}/%{base_name}/Reader/Cert/curl-ca-bundle.crt
137 chmod a-x $RPM_BUILD_ROOT%{_libdir}/%{base_name}/Reader/%{platform}/lib/*.so.*
141 rm -rf $RPM_BUILD_ROOT
143 %if %{without license_agreement}
145 %{_bindir}/%{base_name}.install
149 %triggerin -n browser-plugin-%{name} -- mozilla-firefox
150 %nsplugin_install -d %{_libdir}/mozilla-firefox/plugins nppdf.so
152 %triggerun -n browser-plugin-%{name} -- mozilla-firefox
153 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins nppdf.so
155 %triggerin -n browser-plugin-%{name} -- mozilla
156 %nsplugin_install -d %{_libdir}/mozilla/plugins nppdf.so
158 %triggerun -n browser-plugin-%{name} -- mozilla
159 %nsplugin_uninstall -d %{_libdir}/mozilla/plugins nppdf.so
161 %triggerin -n browser-plugin-%{name} -- seamonkey
162 %nsplugin_install -d %{_libdir}/seamonkey/plugins nppdf.so
164 %triggerun -n browser-plugin-%{name} -- seamonkey
165 %nsplugin_uninstall -d %{_libdir}/seamonkey/plugins nppdf.so
167 # % triggerin -n browser-plugin-%{name} -- konqueror
168 # % nsplugin_install -d %{_libdir}/kde3/plugins/konqueror nppdf.so
170 # % triggerun -n browser-plugin-%{name} -- konqueror
171 # % nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror nppdf.so
173 # % triggerin -n browser-plugin-%{name} -- opera
174 # % nsplugin_install -d %{_libdir}/opera/plugins nppdf.so
176 # % triggerun -n browser-plugin-%{name} -- opera
177 # % nsplugin_uninstall -d %{_libdir}/opera/plugins nppdf.so
179 # as rpm removes the old obsoleted package files after the triggers
180 # above are ran, add another trigger to make the links there.
181 %triggerpostun -n browser-plugin-%{name} -- mozilla-plugin-acroread, acroread-plugin
182 %nsplugin_install -f -d %{_libdir}/mozilla/plugins nppdf.so
187 %defattr(644,root,root,755)
188 %if %{without license_agreement}
189 %attr(755,root,root) %{_bindir}/%{base_name}.install
190 %{_datadir}/%{base_name}
192 %doc AdobeReader/{LICREAD.TXT,ReadMe.htm}
193 %attr(755,root,root) %{_bindir}/*
194 %dir %{_libdir}/%{base_name}
195 %{_libdir}/%{base_name}/Resource
196 %dir %{_libdir}/%{base_name}/Reader
197 %{_libdir}/%{base_name}/Reader/help
198 %{_libdir}/%{base_name}/Reader/AcroVersion
199 %{_libdir}/%{base_name}/Reader/BeyondReader
200 %{_libdir}/%{base_name}/Reader/Cert
201 %{_libdir}/%{base_name}/Reader/GlobalPrefs
202 %{_libdir}/%{base_name}/Reader/HowTo
203 %{_libdir}/%{base_name}/Reader/IDTemplates
204 %{_libdir}/%{base_name}/Reader/JavaScripts
205 %{_libdir}/%{base_name}/Reader/Legal
206 %{_libdir}/%{base_name}/Reader/Tracker
207 %{_libdir}/%{base_name}/Reader/PDFSigQFormalRep.pdf
208 %{_libdir}/%{base_name}/Reader/pmd.cer
209 %dir %{_libdir}/%{base_name}/Reader/%{platform}
210 %dir %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins
211 %dir %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/Multimedia
212 %dir %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/Multimedia/MPP
213 %dir %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins3d
214 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/SPPlugins
215 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/bin
216 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/lib
217 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/*.api
218 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins3d/*.x3d
219 %attr(755,root,root) %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/Multimedia/MPP/Real.mpp
220 %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/AcroForm
221 %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins/Annotations
222 %{_libdir}/%{base_name}/Reader/%{platform}/plug_ins3d/prc
223 %{_desktopdir}/acroread.desktop
226 %files -n browser-plugin-%{name}
227 %defattr(644,root,root,755)
228 %attr(755,root,root) %{_plugindir}/*