2 # TODO: package kde4 component
5 %bcond_with license_agreement # generates package
7 %define ver32 11.2.202.236
8 %define ver64 11.2.202.236
11 %define version %{ver32}
12 %define libmark %{nil}
15 %define version %{ver64}
16 %define libmark ()(64bit)
19 %define base_name adobe-flash
21 Summary: Flash plugin for Netscape-compatible WWW browsers
22 Summary(pl.UTF-8): Wtyczka Flash dla przeglądarek WWW zgodnych z Netscape
23 %if %{with license_agreement}
26 Name: %{base_name}-installer
29 Release: %{rel}%{?with_license_agreement:wla}
31 License: Free to use, non-distributable
32 Group: X11/Applications/Multimedia
33 %if %{with license_agreement}
34 Source0: http://fpdownload.macromedia.com/get/flashplayer/pdc/%{ver32}/install_flash_player_11_linux.i386.tar.gz#/flash-%{version}.tgz
35 # NoSourceSource0-md5: 9f0e97cae13bae7a490b0505a543b373
37 Source1: http://fpdownload.macromedia.com/get/flashplayer/pdc/%{ver64}/install_flash_player_11_linux.x86_64.tar.gz#/flash64-%{version}.tgz
38 # NoSourceSource1-md5: d508ebb81be22585bf79df75908247c7
41 Source3: http://svn.pld-linux.org/svn/license-installer/license-installer.sh
42 # Source3-md5: 329c25f457fea66ec502b7ef70cb9ede
45 URL: http://www.adobe.com/products/flashplayer/
47 %if %{with license_agreement}
48 BuildRequires: rpmbuild(macros) >= 1.357
49 BuildRequires: sed >= 4.0
50 Requires: browser-plugins >= 2.0
51 Requires: hicolor-icon-theme
53 Requires: libasound.so.2%{libmark}
54 Requires: libcurl.so.4%{libmark}
56 Requires: rpm-build-tools >= 4.4.37
57 Requires: rpmbuild(macros) >= 1.544
59 Provides: browser(flash)
60 Provides: macromedia-flash
61 Obsoletes: flash-plugin
62 Obsoletes: konqueror-plugin-macromedia-flash
63 Obsoletes: macromedia-flash
64 Obsoletes: mozilla-firefox-plugin-macromedia-flash
65 Obsoletes: mozilla-plugin-macromedia-flash
66 ExclusiveArch: %{ix86} %{x8664}
67 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
69 %define _sysconfdir /etc/adobe
71 # So that building package on AC system won't write package name dep that Th system can't understand (libstdc++4)
72 %define _noautoreqdep libstdc++.so.6
74 # No debuginfo to be stored
75 %define _enable_debug_packages 0
78 Adobe(R) Flash(R) Player for Linux - the next-generation client
79 runtime for engaging with Flash content and applications on Linux.
81 %description -l pl.UTF-8
82 Adobe(R) Flash(R) Player - środowisko nowej generacji do obsługi
83 treści i aplikacji we Flashu pod Linuksem.
86 %if %{with license_agreement}
95 s=$(echo 'LNX %{version}' | tr . ,)
96 v=$(strings libflashplayer.so | grep '^LNX ')
97 if [ "$v" != "$s" ]; then
104 rm -rf $RPM_BUILD_ROOT
105 %if %{without license_agreement}
106 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
109 s/@BASE_NAME@/%{base_name}/g
110 s/@TARGET_CPU@/%{_target_cpu}/g
111 s-@VERSION@-%{version}-g
112 s-@RELEASE@-%{release}-g
113 s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g
114 s,@DATADIR@,%{_datadir}/%{base_name},g
115 ' %{SOURCE3} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
117 cp -p %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
121 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_browserpluginsdir},%{_bindir},%{_desktopdir},%{_iconsdir}}
122 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/mms.cfg
123 install -p *.so $RPM_BUILD_ROOT%{_browserpluginsdir}
124 install usr/bin/flash-player-properties $RPM_BUILD_ROOT%{_bindir}
125 install usr/share/applications/flash-player-properties.desktop $RPM_BUILD_ROOT%{_desktopdir}/flash-player-properties.desktop
126 cp -a usr/share/icons/* $RPM_BUILD_ROOT%{_iconsdir}
130 rm -rf $RPM_BUILD_ROOT
132 %if %{without license_agreement}
134 %{_bindir}/%{base_name}.install
137 %update_browser_plugins
138 %update_icon_cache hicolor
141 if [ "$1" = 0 ]; then
142 %update_browser_plugins
144 %update_icon_cache hicolor
148 %defattr(644,root,root,755)
149 %if %{without license_agreement}
150 %attr(755,root,root) %{_bindir}/%{base_name}.install
151 %{_datadir}/%{base_name}
154 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mms.cfg
155 %attr(755,root,root) %{_bindir}/flash-player-properties
156 %attr(755,root,root) %{_browserpluginsdir}/*.so
157 %{_desktopdir}/flash-player-properties.desktop
158 %{_iconsdir}/hicolor/*/apps/*.png