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