]> git.pld-linux.org Git - packages/adobe-flash.git/blob - adobe-flash.spec
- up to labs version 11.2.202.19
[packages/adobe-flash.git] / adobe-flash.spec
1 #
2 # TODO: package kde4 component
3 #
4 # Conditional build:
5 %bcond_with     license_agreement       # generates package
6
7 %define         ver32   11.2.202.19
8 %define         ver64   11.2.202.19
9
10 %ifarch %{ix86}
11 %define         version %{ver32}
12 %define         libmark %{nil}
13 %endif
14 %ifarch %{x8664}
15 %define         version %{ver64}
16 %define         libmark ()(64bit)
17 %endif
18
19 %define         base_name       adobe-flash
20 %define         rel 1
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}
24 Name:           %{base_name}
25 %else
26 Name:           %{base_name}-installer
27 %endif
28 Version:        %{version}
29 Release:        %{rel}%{?with_license_agreement:wla}
30 Epoch:          1
31 License:        Free to use, non-distributable
32 Group:          X11/Applications/Multimedia
33 %if %{with license_agreement}
34 Source0:        http://download.macromedia.com/pub/labs/flashplatformruntimes/flashplayer11-2/flashplayer11-2_p1_install_lin_32_102611.tar.gz
35 # NoSourceSource0-md5:  4e85ea589dc9ca6fc128380f64e21b70
36 NoSource:       0
37 Source1:        http://download.macromedia.com/pub/labs/flashplatformruntimes/flashplayer11-2/flashplayer11-2_p1_install_lin_64_102611.tar.gz
38 # NoSourceSource1-md5:  0569d9bef0025f3804b026f7a996e082
39 NoSource:       1
40 Source2:        mms.cfg
41 %else
42 Source3:        http://svn.pld-linux.org/svn/license-installer/license-installer.sh
43 # Source3-md5:  329c25f457fea66ec502b7ef70cb9ede
44 %endif
45 URL:            http://www.adobe.com/products/flashplayer/
46 %if %{with license_agreement}
47 BuildRequires:  rpmbuild(macros) >= 1.357
48 BuildRequires:  sed >= 4.0
49 Requires:       browser-plugins >= 2.0
50 # dlopened by player
51 Requires:       libasound.so.2%{libmark}
52 Requires:       libcurl.so.4%{libmark}
53 Requires:       hicolor-icon-theme
54 %else
55 Requires:       rpm-build-tools >= 4.4.37
56 Requires:       rpmbuild(macros) >= 1.544
57 %endif
58 Provides:       browser(flash)
59 Provides:       macromedia-flash
60 Obsoletes:      flash-plugin
61 Obsoletes:      konqueror-plugin-macromedia-flash
62 Obsoletes:      macromedia-flash
63 Obsoletes:      mozilla-firefox-plugin-macromedia-flash
64 Obsoletes:      mozilla-plugin-macromedia-flash
65 ExclusiveArch:  %{ix86} %{x8664}
66 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
67
68 %define         _sysconfdir     /etc/adobe
69
70 # So that building package on AC system won't write package name dep that Th system can't understand (libstdc++4)
71 %define         _noautoreqdep   libstdc++.so.6
72
73 # No debuginfo to be stored
74 %define         _enable_debug_packages  0
75
76 %description
77 Adobe(R) Flash(R) Player for Linux - the next-generation client
78 runtime for engaging with Flash content and applications on Linux.
79
80 %description -l pl.UTF-8
81 Adobe(R) Flash(R) Player - środowisko nowej generacji do obsługi
82 treści i aplikacji we Flashu pod Linuksem.
83
84 %prep
85 %if %{with license_agreement}
86 %ifarch %{x8664}
87 %setup -q -T -c -b 1
88 %else
89 %setup -q -T -c -b 0
90 %endif
91
92 %build
93 s=$(echo 'LNX %{version}' | tr . ,)
94 v=$(strings libflashplayer.so | grep '^LNX ')
95 if [ "$v" != "$s" ]; then
96         : wrong version
97         exit 1
98 fi
99 %endif
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103 %if %{without license_agreement}
104 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
105
106 sed -e '
107         s/@BASE_NAME@/%{base_name}/g
108         s/@TARGET_CPU@/%{_target_cpu}/g
109         s-@VERSION@-%{version}-g
110         s-@RELEASE@-%{release}-g
111         s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g
112         s,@DATADIR@,%{_datadir}/%{base_name},g
113 ' %{SOURCE3} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
114
115 cp -p %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
116
117 %else
118
119 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_browserpluginsdir},%{_bindir},%{_desktopdir},%{_iconsdir}}
120 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/mms.cfg
121 install -p *.so $RPM_BUILD_ROOT%{_browserpluginsdir}
122 #install usr/bin/flash-player-properties $RPM_BUILD_ROOT%{_bindir}
123 #install usr/share/applications/flash-player-properties.desktop $RPM_BUILD_ROOT%{_desktopdir}/flash-player-properties.desktop
124 #cp -a usr/share/icons/* $RPM_BUILD_ROOT%{_iconsdir}
125 %endif
126
127 %clean
128 rm -rf $RPM_BUILD_ROOT
129
130 %if %{without license_agreement}
131 %post
132 %{_bindir}/%{base_name}.install
133 %else
134 %post
135 %update_browser_plugins
136 %update_icon_cache hicolor
137
138 %postun
139 if [ "$1" = 0 ]; then
140         %update_browser_plugins
141 fi
142 %update_icon_cache hicolor
143 %endif
144
145 %files
146 %defattr(644,root,root,755)
147 %if %{without license_agreement}
148 %attr(755,root,root) %{_bindir}/%{base_name}.install
149 %{_datadir}/%{base_name}
150 %else
151 %dir %{_sysconfdir}
152 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mms.cfg
153 #%attr(755,root,root) %{_bindir}/flash-player-properties
154 %attr(755,root,root) %{_browserpluginsdir}/*.so
155 #%{_desktopdir}/flash-player-properties.desktop
156 #%{_iconsdir}/hicolor/*/apps/*.png
157 %endif
This page took 0.034331 seconds and 3 git commands to generate.