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