]> git.pld-linux.org Git - packages/adobe-flash.git/blob - adobe-flash.spec
9e42cf6673dece7056be1cb2f3d62b28c36b4b2d
[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      21
8 %define         _ver_serial     78
9 %define         base_name       macromedia-flash
10 Summary:        Flash plugin for Netscape-compatible WWW browsers
11 Summary(pl):    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 2
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://download.macromedia.com/pub/labs/flashplayer9_update/FP9_plugin_beta_101806.tar.gz
24 Source0:        http://download.macromedia.com/pub/labs/flashplayer9_update/FP9_plugin_beta_112006.tar.gz
25 # NoSource0-md5:        3ab408f85ae6d8180cc913edf97bf3eb
26 %else
27 Source0:        license-installer.sh
28 # NoSource0-md5:        3ab408f85ae6d8180cc913edf97bf3eb
29 %endif
30 URL:            http://www.adobe.com/products/flashplayer/
31 %if %{with license_agreement}
32 BuildRequires:  rpmbuild(macros) >= 1.236
33 Requires:       browser-plugins(%{_target_base_arch})
34 %else
35 Requires:       rpm-build-tools
36 %endif
37 Obsoletes:      flash-plugin
38 Obsoletes:      konqueror-plugin-macromedia-flash
39 Obsoletes:      mozilla-firefox-plugin-macromedia-flash
40 Obsoletes:      mozilla-plugin-macromedia-flash
41 ExclusiveArch:  %{ix86}
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %define         _plugindir      %{_libdir}/browser-plugins
45
46 # TODO: galeon and skipstone.
47 # use macro, otherwise extra LF inserted along with the ifarch
48 %define browsers mozilla, mozilla-firefox, mozilla-firefox-bin, konqueror, opera, seamonkey
49
50 %description
51 Adobe(R) Flash(R) Player is the high-performance, lightweight, highly expressive
52 client runtime that delivers powerful and consistent user experiences across
53 major operating systems, browsers, mobile phones, and devices. Installed on
54 over 700 million Internet-connected desktops and mobile devices, Flash Player
55 enables organizations and individuals to build and deliver great digital
56 experiences to their end users.
57
58 Supported browsers: %{browsers}.
59
60 %description -l pl
61 Wtyczka Flash dla przegl±darek WWW zgodnych z Netscape.
62
63 Obs³ugiwane przegl±darki: %{browsers}.
64
65 %prep
66 %if %{with license_agreement}
67 %setup -q -n flash-player-plugin-%{_ver_major}.%{_ver_minor}.%{_ver_patch}.%{_ver_serial}
68 %endif
69
70 %install
71 rm -rf $RPM_BUILD_ROOT
72 %if !%{with license_agreement}
73 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
74
75 sed -e '
76         s/@BASE_NAME@/%{base_name}/g
77         s/@TARGET_CPU@/%{_target_cpu}/g
78         s-@VERSION@-%{version}-g
79         s-@RELEASE@-%{release}-g
80         s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g
81 ' %{SOURCE0} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
82
83 install %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
84
85 %else
86
87 install -d $RPM_BUILD_ROOT%{_plugindir}
88 install *.so $RPM_BUILD_ROOT%{_plugindir}
89
90 %endif
91
92 %clean
93 rm -rf $RPM_BUILD_ROOT
94
95 %if !%{with license_agreement}
96 %post
97 %{_bindir}/%{base_name}.install
98
99 %else
100
101 %triggerin -- mozilla-firefox
102 %nsplugin_install -d %{_libdir}/mozilla-firefox/plugins libflashplayer.so
103
104 %triggerun -- mozilla-firefox
105 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox/plugins libflashplayer.so
106
107 %triggerin -- mozilla-firefox-bin
108 %nsplugin_install -d %{_libdir}/mozilla-firefox-bin/plugins libflashplayer.so
109
110 %triggerun -- mozilla-firefox-bin
111 %nsplugin_uninstall -d %{_libdir}/mozilla-firefox-bin/plugins libflashplayer.so
112
113 %triggerin -- mozilla
114 %nsplugin_install -d %{_libdir}/mozilla/plugins libflashplayer.so
115
116 %triggerun -- mozilla
117 %nsplugin_uninstall -d %{_libdir}/mozilla/plugins libflashplayer.so
118
119 %triggerin -- konqueror
120 %nsplugin_install -d %{_libdir}/kde3/plugins/konqueror libflashplayer.so
121
122 %triggerun -- konqueror
123 %nsplugin_uninstall -d %{_libdir}/kde3/plugins/konqueror libflashplayer.so
124
125 %triggerin -- opera
126 %nsplugin_install -d %{_libdir}/opera/plugins libflashplayer.so
127
128 %triggerun -- opera
129 %nsplugin_uninstall -d %{_libdir}/opera/plugins libflashplayer.so
130
131 %triggerin -- seamonkey
132 %nsplugin_install -d %{_libdir}/seamonkey/plugins libflashplayer.so
133
134 %triggerun -- seamonkey
135 %nsplugin_uninstall -d %{_libdir}/seamonkey/plugins libflashplayer.so
136
137 # as rpm removes the old obsoleted package files after the triggers
138 # above are ran, add another trigger to make the links there.
139 %triggerpostun -- mozilla-firefox-plugin-macromedia-flash
140 %nsplugin_install -f -d %{_libdir}/mozilla-firefox/plugins libflashplayer.so flashplayer.xpt
141
142 %triggerpostun -- mozilla-plugin-macromedia-flash
143 %nsplugin_install -f -d %{_libdir}/mozilla/plugins libflashplayer.so flashplayer.xpt
144
145 %triggerpostun -- konqueror-plugin-macromedia-flash
146 %nsplugin_install -f -d %{_libdir}/kde3/plugins/konqueror libflashplayer.so
147 %endif
148
149 %files
150 %defattr(644,root,root,755)
151
152 %if !%{with license_agreement}
153 %attr(755,root,root) %{_bindir}/%{base_name}.install
154 %{_datadir}/%{base_name}
155
156 %else
157 %doc *.txt
158 %attr(755,root,root) %{_plugindir}/*.so
159 %endif
This page took 0.041203 seconds and 3 git commands to generate.