1 |
# eu-strip crashes on chrome binary from this build |
2 |
%define _enable_debug_packages %{nil} |
3 |
%global debug_package %{nil} |
4 |
%global __debug_install_post %{nil} |
5 |
|
6 |
%define crname chromium-browser |
7 |
%define _crdir %{_libdir}/%{crname} |
8 |
%define __requires_exclude_from ^%{_crdir}/libwidevinecdmadapter.so$ |
9 |
|
10 |
# eol 'fix' corrupts some .bin |
11 |
%define dont_fix_eol 1 |
12 |
|
13 |
# Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys |
14 |
# Note: these are for Mageia use ONLY. |
15 |
# For your own builds, please get your own set of keys. |
16 |
%define google_api_key AIzaSyDhhIHB_kQZodiWr8yDAm8E3GwEyiXmuDU |
17 |
%define google_default_client_id 1039996407057-q599ngv7i6ni4sbkd2fsns30246r9s9v.apps.googleusercontent.com |
18 |
%define google_default_client_secret mRHXPjlS4cLpp1beCiXoYbLZ |
19 |
|
20 |
Name: chromium-browser-stable |
21 |
Version: 70.0.3538.67 |
22 |
Release: %mkrel 2 |
23 |
Summary: A fast webkit-based web browser |
24 |
Group: Networking/WWW |
25 |
License: BSD, LGPL |
26 |
URL: http://www.chromium.org/Home |
27 |
# http://omahaproxy.appspot.com/ |
28 |
# http://googlechromereleases.blogspot.com/ |
29 |
Source0: http://commondatastorage.googleapis.com/chromium-browser-official/chromium-%{version}.tar.xz |
30 |
Source1: chromium-wrapper |
31 |
Source2: chromium-browser.desktop |
32 |
Source4: widevine_cdm_version.h.in |
33 |
# from gentoo: compiler setup |
34 |
Patch1: chromium-compiler-r4.patch |
35 |
# fix googleisms in man page |
36 |
Patch2: chromium-mageia.patch |
37 |
# (cjw) Recognize mimetypes for matroska (.mkv) and AVI (.avi) formats (video/x-matroska and audio/x-matroska, video/x-msvideo) + handle A52 "AC3" and DTS compressed audio. |
38 |
Patch6: chromium-55-extra-media.patch |
39 |
# (cjw) Recognize mimetypes for WMV (.wmv), FLV (.flv) and MPEG (.mpg) videos |
40 |
Patch7: chromium-40-wmvflvmpg.patch |
41 |
# (cjw) disable external components -- this stops chromium from downloading hotword stuff, for example |
42 |
Patch10: chromium-45-no-external-components.patch |
43 |
# (debian) disable third party cookies by default |
44 |
Patch11: chromium-third-party-cookies-off-by-default.patch |
45 |
# (cjw) fix webrtc build with system ffmpeg |
46 |
Patch18: chromium-50-system-ffmpeg-3.patch |
47 |
# (cjw) fix build error due to android-specific code |
48 |
Patch19: chromium-50-codec-warnings.patch |
49 |
# (cjw) remove assertion on "chromium" branding in combination with enabled "proprietary codecs" |
50 |
Patch22: chromium-54-proprietary-codecs-assert.patch |
51 |
# (cjw) disable werror for a compilation warning that causes the build to fail |
52 |
Patch23: chromium-53-bignum-werror-fix.patch |
53 |
# (cjw) add -Wno-error=depecated-declarations because ffmpeg deprecations cause the build to fail |
54 |
Patch24: chromium-53-ffmpeg-no-deprecation-errors.patch |
55 |
# (cjw) link several libraries directly instead of loading them using dlopen() |
56 |
Patch27: chromium-53-link-libgio-libpci-libudev-libbrlapi.patch |
57 |
# (cjw) add missing unbundle gn files (1) |
58 |
Patch28: chromium-53-gn-system-icu-jsoncpp.patch |
59 |
# (cjw) add missing unbundle gn files (2) |
60 |
Patch29: chromium-53-gn-system-opus.patch |
61 |
# (cjw) build pdfium with system libtiff and libpng |
62 |
Patch30: chromium-52-pdfium-system-libtiff-libpng.patch |
63 |
# (cjw) fix build with current glib... |
64 |
Patch36: chromium-58-glib.patch |
65 |
# (cjw) use system nodejs to fix build |
66 |
Patch37: chromium-58-system-nodejs.patch |
67 |
# |
68 |
Patch40: chromium-59-gcc5.patch |
69 |
# system libvpx |
70 |
Patch42: chromium-60-system-libvpx.patch |
71 |
# clang builtin subtract functions, scoped enum |
72 |
Patch47: chromium-61-gcc5.patch |
73 |
# enum compared with anonymous enum => warning |
74 |
Patch52: chromium-62-gcc5.patch |
75 |
# (cjw) fix coding errors resulting in gcc 7 warning |
76 |
Patch54: chromium-62-gcc7.patch |
77 |
# (cjw) fix gcc errors and warnings |
78 |
Patch177: chromium-64-gcc7.patch |
79 |
# (cjw) fix even more gcc warnings |
80 |
Patch179: chromium-65-gcc7.patch |
81 |
# (cjw) fix yet mmore gcc warnings |
82 |
Patch182: chromium-66-gcc7.patch |
83 |
# (cjw) try to get widevine binary plugin to work (must be taken from a chrome download bundle), v2 |
84 |
Patch183: chromium-67-widevine.patch |
85 |
# (cjw) fix a few more gcc warnings |
86 |
Patch184: chromium-67-gcc7.patch |
87 |
# (cjw) more gcc warnings |
88 |
Patch186: chromium-68-gcc7.patch |
89 |
# (cjw) moore gcc warnings |
90 |
Patch188: chromium-68-gcc8.patch |
91 |
# (cjw) and more gcc warnings |
92 |
Patch189: chromium-69-gcc7.patch |
93 |
# (cjw) fix gn bootstrapping with gcc |
94 |
Patch190: chromium-69-gn-bootstrap.patch |
95 |
# (cjw) mooore gcc warnings |
96 |
Patch191: chromium-69-gcc8.patch |
97 |
# (cjw) moooore gcc warnings |
98 |
Patch192: chromium-70-gcc8.patch |
99 |
# (cjw) build fixes for 64-bit arm |
100 |
Patch193: chromium-70-aarch64.patch |
101 |
# (cjw) add back support for gtk2 builds |
102 |
Patch194: chromium-70-gtk2.patch |
103 |
# (joequant) fix crash on cinnamon |
104 |
Patch195: chromium-69-cinnamon.patch |
105 |
|
106 |
|
107 |
Provides: %{crname} |
108 |
Obsoletes: chromium-browser-unstable < 26.0.1410.51 |
109 |
Obsoletes: chromium-browser-beta < 26.0.1410.51 |
110 |
Obsoletes: chromium-browser < 1:9.0.597.94 |
111 |
BuildRequires: bison |
112 |
BuildRequires: flex |
113 |
BuildRequires: gperf |
114 |
BuildRequires: icu |
115 |
BuildRequires: ninja |
116 |
BuildRequires: yasm |
117 |
BuildRequires: bzip2-devel |
118 |
BuildRequires: cups-devel |
119 |
BuildRequires: elfutils-devel |
120 |
BuildRequires: ffmpeg-devel |
121 |
BuildRequires: glib2-devel |
122 |
BuildRequires: gtk2-devel |
123 |
BuildRequires: libatomic-devel |
124 |
#BuildRequires: libevent-devel |
125 |
BuildRequires: libmesagl-devel |
126 |
BuildRequires: libpam-devel |
127 |
BuildRequires: libpulseaudio-devel |
128 |
%if %mgaver >= 6 |
129 |
BuildRequires: nodejs |
130 |
%endif |
131 |
BuildRequires: osmesa-devel |
132 |
#BuildRequires: protobuf-devel |
133 |
BuildRequires: snappy-devel |
134 |
BuildRequires: perl(Switch) |
135 |
BuildRequires: pkgconfig(alsa) |
136 |
BuildRequires: pkgconfig(atk) |
137 |
BuildRequires: pkgconfig(dbus-glib-1) |
138 |
BuildRequires: pkgconfig(expat) |
139 |
BuildRequires: pkgconfig(flac) |
140 |
BuildRequires: pkgconfig(fontconfig) |
141 |
BuildRequires: pkgconfig(freetype2) |
142 |
BuildRequires: pkgconfig(glu) |
143 |
BuildRequires: pkgconfig(gnome-keyring-1) |
144 |
BuildRequires: pkgconfig(gnutls) |
145 |
%if %mgaver >= 7 |
146 |
BuildRequires: pkgconfig(harfbuzz) |
147 |
%endif |
148 |
BuildRequires: pkgconfig(icu-i18n) |
149 |
BuildRequires: pkgconfig(jsoncpp) |
150 |
BuildRequires: pkgconfig(libcap) |
151 |
BuildRequires: pkgconfig(libdrm) |
152 |
BuildRequires: pkgconfig(libexif) |
153 |
BuildRequires: pkgconfig(libjpeg) |
154 |
BuildRequires: pkgconfig(libopenjp2) |
155 |
BuildRequires: pkgconfig(libpci) |
156 |
BuildRequires: pkgconfig(libpng) |
157 |
BuildRequires: pkgconfig(libtiff-4) |
158 |
BuildRequires: pkgconfig(libusb-1.0) |
159 |
%if %mgaver >= 7 |
160 |
BuildRequires: pkgconfig(libvpx) |
161 |
%endif |
162 |
BuildRequires: pkgconfig(libwebp) |
163 |
BuildRequires: pkgconfig(libxml-2.0) |
164 |
BuildRequires: pkgconfig(libxslt) |
165 |
BuildRequires: pkgconfig(minizip) |
166 |
BuildRequires: pkgconfig(nspr) |
167 |
BuildRequires: pkgconfig(nss) |
168 |
BuildRequires: pkgconfig(opus) |
169 |
BuildRequires: pkgconfig(speech-dispatcher) |
170 |
BuildRequires: pkgconfig(speex) |
171 |
BuildRequires: pkgconfig(udev) |
172 |
BuildRequires: pkgconfig(xscrnsaver) |
173 |
BuildRequires: pkgconfig(xt) |
174 |
BuildRequires: pkgconfig(xtst) |
175 |
BuildRequires: pkgconfig(zlib) |
176 |
# Unused but building gn wants it to be present |
177 |
BuildRequires: pkgconfig(gconf-2.0) |
178 |
BuildRequires: pkgconfig(gtk+-3.0) |
179 |
BuildRequires: git |
180 |
ExclusiveArch: i586 x86_64 aarch64 |
181 |
# armv5tl armv7hl |
182 |
|
183 |
%description |
184 |
Chromium is a browser that combines a minimal design with sophisticated |
185 |
technology to make the web faster, safer, and easier. |
186 |
|
187 |
For certain media playback features - AAC decoding - this package |
188 |
currently assumes decoder support is available, while that is only true if |
189 |
the 'tainted' variety of the libavcodec package is installed. When the 'core' |
190 |
variety of libavcodec is installed, chromium may output noise for AAC audio. |
191 |
|
192 |
%ifarch %{ix86} |
193 |
The i586 build of this package does not work on machines that do not |
194 |
support the SSE2 instruction set extension. |
195 |
%endif |
196 |
|
197 |
%package -n chromium-browser |
198 |
Summary: A fast webkit-based web browser (transition package) |
199 |
Epoch: 1 |
200 |
Group: Networking/WWW |
201 |
Requires: %{name} = %{version}-%{release} |
202 |
|
203 |
%description -n chromium-browser |
204 |
Chromium is a browser that combines a minimal design with sophisticated |
205 |
technology to make the web faster, safer, and easier. |
206 |
|
207 |
This is a transition package that installs the stable channel Chromium |
208 |
browser. |
209 |
|
210 |
%prep |
211 |
%setup -q -n chromium-%{version} |
212 |
%autopatch -p1 |
213 |
|
214 |
# files we do not want from upstream source bundles |
215 |
rm -rf breakpad/src/processor/testdata/ |
216 |
rm -rf chrome/app/test_data/dlls/ |
217 |
rm -rf chrome/common/extensions/docs/ |
218 |
rm -rf chrome/test/data/{android,app_shim,apptest,ash,autofill,automation,automation_proxy_snapshot,banners,bookmark_html_reader,bookmarks,captive_portal,chromedriver,chrome_endure,chromeos,chromeproxy,cld2_component,click_modifier,components,constrained_files,content,content_setting_bubble,devtools,diagnostics,dom_automation,dom_checker,dom_distiller,downloads,drive_first_run,dromaeo,durable,edge_database_reader,edge_profile,encoding_tests,extensions,fast_shutdown,fast_tab_close,favicon,feeds,file_select_helper,find_in_page,firefox320_profile,firefox35_profile,firefox3_nss,firefox3_nss_mac,firefox3_profile,firefox_profile,firefox_searchplugins,focus,frame_dom_access,frame_tree,ftp,fullscreen_mouselock,geolocation,google,gpu,History,image_decoding,image_search,import,indexeddb,inspector,installer,interstitial_page,keyboard,login,native_messaging,navigation_interception,notifications,page_cycler,page_load_metrics,panels,password,pdf,pepper,perf,permissions,plugin_power_saver,policy,popup_blocker,predictor,prefs,pref_service,prerender,printing,profiles,push_messaging,referrer_policy,requirements_checker,safe_browsing,SafeBrowsing,save_page,scroll,sdch,search,session_history,session_restore,sessions,settings,speech,ssl,subresource_filter,sunspider,sync,template_url_scraper,textinput,third_party,top_sites,translate,unit,v8_benchmark_v6,viewsource,web_app_info,webapps,webrtc,websocket,webui_test_resources.grd,whitelists,workers} |
219 |
rm -rf chrome/test/data/nacl/{pnacl_error_handling,cross_origin,irt_exception,pnacl_request_header,nonsfi,pnacl_url_loader,pnacl_hw_eh_disabled,pnacl_nmf_options,pnacl_dyncode_syscall_disabled,extension_mime_handler,ppapi_test_lib,bad,ppapi,ppapi/ppb_instance,ppapi/ppp_instance,ppapi/ppb_core,manifest,manifest/mdir,manifest/ndir,pnacl_debug_url,nacl_test_data.gyp,extension_validation_cache,exit_status,progress_events,manifest_file,sysconf_nprocessors_onln,crash,pnacl_mime_type} |
220 |
rmdir chrome/test/data/webui/{settings,extensions}/a11y |
221 |
rmdir chrome/test/data/webui/{engagement,extensions,media_router,print_preview,cr_elements,settings,md_bookmarks,md_downloads,md_history,md_user_manager,net_internals} |
222 |
rm -rf chrome/tools/test/reference_build/chrome_linux/ |
223 |
rm -rf components/test/data/component_updater/jebgalgnebhfojomionfpkfelancnnkf/component1.dll |
224 |
rm -rf content/test/data/ |
225 |
#rm -rf net/data/ |
226 |
# v the root BUILD.gn includes files from this dir |
227 |
#rm -rf ppapi/examples/ |
228 |
rm -rf ppapi/native_client/tests/ |
229 |
rm -rf third_party/apache-win32/ |
230 |
rm -rf third_party/binutils/ |
231 |
rm -rf third_party/expat/files/ |
232 |
rm -rf third_party/ffmpeg/*/* |
233 |
rm -rf third_party/ffmpeg/*.[ch] |
234 |
rm -rf third_party/flac/{include,src} |
235 |
#rm -rf third_party/freetype/{src,include} |
236 |
rm -rf third_party/icu/{android,linux,mac,patches,public,source,windows} |
237 |
rm -rf third_party/jsoncpp/source |
238 |
rm -rf third_party/lcov |
239 |
#rm -rf base/third_party/libevent/*/* |
240 |
#rm -rf base/third_party/libevent/*.[ch] |
241 |
%if %mgaver >= 7 |
242 |
rm -rf third_party/libvpx/source/{libvpx,config} |
243 |
%endif |
244 |
rm -rf third_party/libexif/sources |
245 |
rm -rf third_party/libjpeg/*.[ch] |
246 |
rm -rf third_party/libjpeg_turbo/*.[ch] |
247 |
rm -rf third_party/libpng/*.[ch] |
248 |
rm -rf third_party/libxslt/{libexslt,libxslt,linux,mac,win32} |
249 |
#rm -rf third_party/mesa/src/src |
250 |
rm -rf third_party/swig |
251 |
rm -rf third_party/WebKit/LayoutTests/ |
252 |
rm -rf third_party/WebKit/Tools/Scripts/ |
253 |
rm -rf third_party/xdg-utils/tests/ |
254 |
rm -rf third_party/yasm/source/ |
255 |
rm -rf third_party/zlib/{*.[ch],contrib/minizip} |
256 |
rm -rf tools/gyp/test/ |
257 |
#rm -rf v8/test/ |
258 |
rm -f third_party/pdfium/third_party/libjpeg/*.[ch] |
259 |
rm -f third_party/pdfium/third_party/libopenjpeg20/*.[ch] |
260 |
rm -rf third_party/pdfium/third_party/libpng16 |
261 |
rm -f third_party/pdfium/third_party/libtiff/*.[ch] |
262 |
rm -rf third_party/pdfium/third_party/zlib_v128 |
263 |
|
264 |
rm -f third_party/skia/platform_tools/android/apps/gradle/wrapper/gradle-wrapper.jar |
265 |
rm -f third_party/WebKit/Source/devtools/scripts/jsdoc-validator/jsdoc-validator.jar |
266 |
rm -f third_party/WebKit/Source/devtools/scripts/closure/compiler.jar |
267 |
rm -f third_party/WebKit/Source/devtools/scripts/compiler-runner/closure-runner.jar |
268 |
rm -rf third_party/sfntly/src/java/lib |
269 |
rm -f third_party/haha/haha-2.0.2.jar |
270 |
rm -f third_party/android_platform/webview/frameworks_5.1.0_r1.jar |
271 |
rm -f third_party/android_platform/webview/frameworks_6.0.jar |
272 |
rm -f third_party/libphonenumber/dist/tools/java/java-build/target/java-build-1.0-SNAPSHOT-jar-with-dependencies.jar |
273 |
rm -f third_party/libphonenumber/dist/tools/java/cpp-build/target/cpp-build-1.0-SNAPSHOT-jar-with-dependencies.jar |
274 |
rm -rf third_party/libphonenumber/dist/java/demo/war/WEB-INF/lib |
275 |
rm -rf third_party/libphonenumber/dist/java/lib |
276 |
rm -f third_party/webrtc/examples/androidapp/third_party/autobanh/autobanh.jar |
277 |
rm -rf third_party/cacheinvalidation/src/example-app-build/libs |
278 |
rm -f third_party/closure_compiler/runner/runner.jar |
279 |
rm -f third_party/closure_compiler/compiler/compiler.jar |
280 |
rm -rf third_party/proguard/lib |
281 |
rm -f third_party/checkstyle/checkstyle-6.5-all.jar |
282 |
rm -rf third_party/sfntly/src/cpp/ext |
283 |
|
284 |
# Remove bundled ICU; its header files appear to get picked up instead of |
285 |
# the system ones, leading to errors during the final link stage. |
286 |
# https://groups.google.com/a/chromium.org/d/topic/chromium-packagers/BNGvJc08B6Q |
287 |
find third_party/icu -type f \! -regex '.*\.\(gn\|gni\|isolate\)' -delete |
288 |
|
289 |
# Hard code extra version |
290 |
FILE=chrome/common/channel_info_posix.cc |
291 |
sed -i.orig -re 's/char\s*\*(.*)getenv\("CHROME_VERSION_EXTRA"\)/char const *\1"%{product_vendor} %{product_version}"/' $FILE |
292 |
cmp $FILE $FILE.orig && exit 1 |
293 |
|
294 |
# version taken from: strings opt/google/chrome-unstable/chrome | grep -C 1 " (version:" |
295 |
%define widevine_version 1.4.8.1008 |
296 |
for chrome_arch in ia32 x64; do |
297 |
mkdir -p third_party/widevine/cdm/linux/${chrome_arch} |
298 |
sed -e "s/@WIDEVINE_VERSION@/%{widevine_version}/" %{SOURCE4} > third_party/widevine/cdm/linux/${chrome_arch}/widevine_cdm_version.h |
299 |
done |
300 |
|
301 |
%build |
302 |
%if %mgaver >= 7 |
303 |
%define system_gn_list ffmpeg flac libwebp libxml libxslt snappy yasm libvpx libpng icu zlib jsoncpp opus libdrm |
304 |
%else |
305 |
%define system_gn_list ffmpeg flac libwebp libxml libxslt snappy yasm libpng icu zlib jsoncpp opus libdrm freetype |
306 |
%endif |
307 |
# handled by upstream regular build scripts? : freetype harfbuzz-ng |
308 |
# libevent mesa |
309 |
|
310 |
# v NO TABS IN HERE! |
311 |
%define gn_config use_sysroot=false \ |
312 |
system_libdir="%{_lib}" \ |
313 |
icu_use_data_file=true \ |
314 |
enable_nacl=false \ |
315 |
is_nacl_glibc=false \ |
316 |
binutils_path="%{_bindir}" \ |
317 |
linux_use_bundled_binutils=false \ |
318 |
use_gold=true \ |
319 |
custom_toolchain="//build/toolchain/linux/unbundle:default" \ |
320 |
host_toolchain="//build/toolchain/linux/unbundle:default" \ |
321 |
proprietary_codecs=true \ |
322 |
linux_link_libudev = true \ |
323 |
linux_link_libspeechd = true \ |
324 |
enable_ac3_eac3_audio_demuxing=true \ |
325 |
enable_mse_mpeg2ts_stream_parser=true \ |
326 |
enable_hevc_demuxing=true \ |
327 |
use_system_libjpeg=true \ |
328 |
use_libjpeg_turbo=false \ |
329 |
enable_widevine=true \ |
330 |
pdf_enable_xfa=true \ |
331 |
use_pulseaudio=true \ |
332 |
use_allocator="none" \ |
333 |
gtk_version=2 \ |
334 |
fatal_linker_warnings=false \ |
335 |
use_libpci = true \ |
336 |
is_debug=false \ |
337 |
is_clang=false \ |
338 |
use_system_freetype=true \ |
339 |
use_system_harfbuzz=true \ |
340 |
use_system_libpng=true \ |
341 |
use_custom_libcxx=false \ |
342 |
google_api_key="%{google_api_key}" \ |
343 |
google_default_client_id="%{google_default_client_id}" \ |
344 |
google_default_client_secret="%{google_default_client_secret}" |
345 |
|
346 |
|
347 |
# enable_browser_cdms=true \ |
348 |
|
349 |
build/linux/unbundle/replace_gn_files.py --system-libraries %{system_gn_list} |
350 |
third_party/libaddressinput/chromium/tools/update-strings.py |
351 |
|
352 |
%setup_compile_flags |
353 |
CC=%{__cc}; export CC |
354 |
CXX=%{__cxx}; export CXX |
355 |
AR=%{__ar}; export AR |
356 |
NM=%{__nm}; export NM |
357 |
LD=%{__cxx}; export LD |
358 |
|
359 |
# filter out -g from CFLAGS and CXXFLAGS to fix builds |
360 |
CFLAGS=$(echo "$CFLAGS"|sed -e 's/-g //') |
361 |
CXXFLAGS=$(echo "$CXXFLAGS"|sed -e 's/-g //') |
362 |
CXXFLAGS="$CXXFLAGS -Wno-attributes -Wno-error=class-memaccess" |
363 |
|
364 |
%ifarch %{ix86} |
365 |
CFLAGS="$CFLAGS -msse2" |
366 |
CXXFLAGS="$CXXFLAGS -msse2" |
367 |
%endif |
368 |
|
369 |
python tools/gn/bootstrap/bootstrap.py --gn-gen-args='%{gn_config}' |
370 |
|
371 |
out/Release/gn gen --args='%{gn_config}' out/Release |
372 |
|
373 |
pushd out/Release |
374 |
ninja %{_smp_mflags} chrome chrome_sandbox |
375 |
popd |
376 |
|
377 |
# man page |
378 |
sed -e "s/@@PACKAGE@@/chromium/" -e "s/@@MENUNAME@@/Chromium Web Browser/" chrome/app/resources/manpage.1.in >out/Release/chromium.1 |
379 |
|
380 |
%install |
381 |
ls out/Release |
382 |
mkdir -p %{buildroot}%{_bindir} |
383 |
mkdir -p %{buildroot}%{_crdir}/locales |
384 |
mkdir -p %{buildroot}%{_crdir}/themes |
385 |
mkdir -p %{buildroot}%{_crdir}/default_apps |
386 |
mkdir -p %{buildroot}%{_mandir}/man1 |
387 |
install -m 755 %{_sourcedir}/chromium-wrapper %{buildroot}%{_crdir}/ |
388 |
install -m 755 out/Release/chrome %{buildroot}%{_crdir}/ |
389 |
install -m 4755 out/Release/chrome_sandbox %{buildroot}%{_crdir}/chrome-sandbox |
390 |
install -m 644 out/Release/chromium.1 %{buildroot}%{_mandir}/man1/%{crname}.1 |
391 |
install -m 644 out/Release/chrome_100_percent.pak %{buildroot}%{_crdir}/ |
392 |
install -m 644 out/Release/chrome_200_percent.pak %{buildroot}%{_crdir}/ |
393 |
install -m 644 out/Release/resources.pak %{buildroot}%{_crdir}/ |
394 |
install -m 644 out/Release/natives_blob.bin %{buildroot}%{_crdir}/ |
395 |
install -m 644 out/Release/snapshot_blob.bin %{buildroot}%{_crdir}/ |
396 |
install -m 755 out/Release/mksnapshot %{buildroot}%{_crdir}/ |
397 |
install -m 644 out/Release/locales/*.pak %{buildroot}%{_crdir}/locales/ |
398 |
install -m 644 chrome/browser/resources/default_apps/* %{buildroot}%{_crdir}/default_apps/ |
399 |
install -m 644 out/Release/v8_context_snapshot.bin %{buildroot}%{_crdir}/ |
400 |
ln -s %{_crdir}/chromium-wrapper %{buildroot}%{_bindir}/%{crname} |
401 |
|
402 |
%ifarch %{ix86} x86_64 |
403 |
mkdir -p %{buildroot}%{_crdir}/swiftshader |
404 |
install -m 755 out/Release/swiftshader/*.so %{buildroot}%{_crdir}/swiftshader/ |
405 |
%endif |
406 |
|
407 |
find out/Release/resources/ -name "*.d" -exec rm {} \; |
408 |
cp -r out/Release/resources %{buildroot}%{_crdir} |
409 |
|
410 |
# desktop file |
411 |
mkdir -p %{buildroot}%{_datadir}/applications |
412 |
install -m 644 %{_sourcedir}/%{crname}.desktop %{buildroot}%{_datadir}/applications/ |
413 |
|
414 |
# symlink to ICU data file |
415 |
ICUDATADIR=$(icuinfo | grep \"icudata.path\" | sed -re 's/^.*>(.*)<.*$/\1/') |
416 |
ICUDATANAME=$(icuinfo | grep \"icudata.name\" | sed -re 's/^.*>(.*)<.*$/\1/') |
417 |
ICUDATAFILE=$(realpath --relative-to=%{_crdir}/ ${ICUDATADIR}/${ICUDATANAME}.dat) |
418 |
ln -s ${ICUDATAFILE} %{buildroot}%{_crdir}/icudtl.dat |
419 |
|
420 |
# icon |
421 |
for i in 22 24 48 64 128 256; do |
422 |
mkdir -p %{buildroot}%{_iconsdir}/hicolor/${i}x${i}/apps |
423 |
install -m 644 chrome/app/theme/chromium/product_logo_$i.png \ |
424 |
%{buildroot}%{_iconsdir}/hicolor/${i}x${i}/apps/%{crname}.png |
425 |
done |
426 |
|
427 |
for i in 16 32; do |
428 |
mkdir -p %{buildroot}%{_iconsdir}/hicolor/${i}x${i}/apps |
429 |
install -m 644 chrome/app/theme/default_100_percent/chromium/product_logo_$i.png \ |
430 |
%{buildroot}%{_iconsdir}/hicolor/${i}x${i}/apps/%{crname}.png |
431 |
done |
432 |
|
433 |
%files -n chromium-browser |
434 |
|
435 |
%files |
436 |
%{_bindir}/%{crname} |
437 |
%dir %{_crdir} |
438 |
%{_crdir}/chromium-wrapper |
439 |
%{_crdir}/chrome |
440 |
%attr(4755,root,root) %{_crdir}/chrome-sandbox |
441 |
%{_crdir}/icudtl.dat |
442 |
%{_crdir}/locales |
443 |
%{_crdir}/natives_blob.bin |
444 |
%{_crdir}/snapshot_blob.bin |
445 |
%{_crdir}/chrome_100_percent.pak |
446 |
%{_crdir}/chrome_200_percent.pak |
447 |
%{_crdir}/resources.pak |
448 |
%{_crdir}/resources |
449 |
%{_crdir}/mksnapshot |
450 |
%{_crdir}/themes |
451 |
%{_crdir}/default_apps |
452 |
%ifarch %{ix86} x86_64 |
453 |
%{_crdir}/swiftshader |
454 |
%endif |
455 |
%{_crdir}/v8_context_snapshot.bin |
456 |
%{_mandir}/man1/%{crname}* |
457 |
%{_datadir}/applications/*.desktop |
458 |
%{_iconsdir}/hicolor/*/apps/%{crname}.png |