]> git.pld-linux.org Git - packages/adobe-flash.git/blob - adobe-flash.spec
- avoid duplicate NoSource0-md5
[packages/adobe-flash.git] / adobe-flash.spec
1 #
2 # Conditional build:
3 %bcond_with     license_agreement       # generates package
4 #
5 %define         _ver_major      9
6 %define         _ver_minor      0
7 %define         _ver_patch      48
8 %define         _ver_serial     0
9 %define         base_name       adobe-flash
10 Summary:        Flash plugin for Netscape-compatible WWW browsers
11 Summary(pl.UTF-8):      Wtyczka Flash dla przeglądarek WWW zgodnych z Netscape
12 %if %{with license_agreement}
13 Name:           %{base_name}
14 %else
15 Name:           %{base_name}-installer
16 %endif
17 %define         _rel 1
18 Version:        %{_ver_major}.%{_ver_minor}.%{_ver_patch}.%{_ver_serial}
19 Release:        %{_rel}%{?with_license_agreement:wla}
20 License:        Free to use, non-distributable
21 Group:          X11/Applications/Multimedia
22 %if %{with license_agreement}
23 Source0:        http://fpdownload.macromedia.com/get/flashplayer/current/install_flash_player_9_linux.tar.gz
24 # NoSource0-md5:        821cc72359a937caef85bb4cc74ef5cd
25 %else
26 Source1:        license-installer.sh
27 %endif
28 URL:            http://www.adobe.com/products/flashplayer/
29 %if %{with license_agreement}
30 BuildRequires:  rpmbuild(macros) >= 1.357
31 Requires:       browser-plugins >= 2.0
32 # apparently dlopened by player
33 Requires:       libasound.so.2
34 %else
35 Requires:       rpm-build-tools
36 %endif
37 Provides:       macromedia-flash
38 Provides:       browser(flash)
39 Obsoletes:      flash-plugin
40 Obsoletes:      konqueror-plugin-macromedia-flash
41 Obsoletes:      macromedia-flash
42 Obsoletes:      mozilla-firefox-plugin-macromedia-flash
43 Obsoletes:      mozilla-plugin-macromedia-flash
44 ExclusiveArch:  %{ix86}
45 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47 %define         _sysconfdir     /etc/adobe
48
49 %description
50 Adobe(R) Flash(R) Player 9 for Linux - the next-generation client
51 runtime for engaging with Flash content and applications on Linux.
52
53 %description -l pl.UTF-8
54 Adobe(R) Flash(R) Player - środowisko nowej generacji do obsługi
55 treści i aplikacji we Flashu pod Linuksem.
56
57 %prep
58 %if %{with license_agreement}
59 %setup -q -n install_flash_player_%{_ver_major}_linux
60 %endif
61
62 %install
63 rm -rf $RPM_BUILD_ROOT
64 %if %{without license_agreement}
65 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
66
67 sed -e '
68         s/@BASE_NAME@/%{base_name}/g
69         s/@TARGET_CPU@/%{_target_cpu}/g
70         s-@VERSION@-%{version}-g
71         s-@RELEASE@-%{release}-g
72         s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g
73 ' %{SOURCE1} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
74
75 install %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
76
77 %else
78
79 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_browserpluginsdir}}
80 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/mms.cfg
81 # http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=16701594
82 AutoUpdateDisable=1
83 AutoUpdateInterval=0
84 EOF
85 install *.so $RPM_BUILD_ROOT%{_browserpluginsdir}
86
87 %endif
88
89 %clean
90 rm -rf $RPM_BUILD_ROOT
91
92 %if %{without license_agreement}
93 %post
94 %{_bindir}/%{base_name}.install
95 %else
96 %post
97 %update_browser_plugins
98
99 %postun
100 if [ "$1" = 0 ]; then
101         %update_browser_plugins
102 fi
103 %endif
104
105 %files
106 %defattr(644,root,root,755)
107 %if %{without license_agreement}
108 %attr(755,root,root) %{_bindir}/%{base_name}.install
109 %{_datadir}/%{base_name}
110 %else
111 %dir %{_sysconfdir}
112 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mms.cfg
113 %attr(755,root,root) %{_browserpluginsdir}/*.so
114 %endif
This page took 0.124299 seconds and 3 git commands to generate.