aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTing-Wei Lan <lantw44@gmail.com>2015-05-26 02:14:45 +0800
committerTing-Wei Lan <lantw44@gmail.com>2015-05-26 02:14:45 +0800
commit034798ec442308e71ad34b9636412a09f1f1703e (patch)
tree2472e9a31dfebc3a5e9992db428ffae84e57d994
parentd16f3fdd8785413fa341335f0e24a707ddfabc9e (diff)
downloadcopr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar.gz
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar.bz2
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar.lz
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar.xz
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.tar.zst
copr-rpm-spec-034798ec442308e71ad34b9636412a09f1f1703e.zip
chromium: Workaround GCC 5.1 issues by compiling with clang on Fedora 22
-rw-r--r--chromium/chromium/chromium.spec35
1 files changed, 32 insertions, 3 deletions
diff --git a/chromium/chromium/chromium.spec b/chromium/chromium/chromium.spec
index d87ae58..5e26efb 100644
--- a/chromium/chromium/chromium.spec
+++ b/chromium/chromium/chromium.spec
@@ -8,7 +8,7 @@
Name: chromium
Version: 43.0.2357.65
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: An open-source project that aims to build a safer, faster, and more stable browser
Group: Applications/Internet
@@ -24,6 +24,12 @@ Source2: chromium-browser.desktop
# I don't have time to test whether it work on other architectures
ExclusiveArch: x86_64
+# Chromium cannot be compiled by GCC 5.1
+# https://code.google.com/p/chromium/issues/detail?id=466760
+# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65801
+%if 0%{?fedora} >= 22
+BuildRequires: clang
+%endif
# Basic tools and libraries
BuildRequires: ninja-build, bison, gperf
BuildRequires: libgcc(x86-32), glibc(x86-32)
@@ -41,8 +47,10 @@ BuildRequires: jsoncpp-devel
BuildRequires: libevent-devel
BuildRequires: libjpeg-turbo-devel
BuildRequires: libpng-devel
-# libvpx 1.3.0 is still too old to build chromium
-# BuildRequires: libvpx-devel
+# Chromium requires libvpx 1.4
+%if 0%{?fedora} >= 23
+BuildRequires: libvpx-devel
+%endif
BuildRequires: libwebp-devel
BuildRequires: openssl-devel
BuildRequires: opus-devel
@@ -78,7 +86,11 @@ Requires: hicolor-icon-theme
-Duse_system_libevent=1 \
-Duse_system_libjpeg=1 \
-Duse_system_libpng=1 \
+%if 0%{?fedora} >= 23
+ -Duse_system_libvpx=1 \
+%else
-Duse_system_libvpx=0 \
+%endif
-Duse_system_libwebp=1 \
-Duse_system_opus=1 \
-Duse_system_snappy=1 \
@@ -87,6 +99,10 @@ Requires: hicolor-icon-theme
find third_party/icu -type f '!' -regex '.*\.\(gyp\|gypi\|isolate\)' -delete
+%if 0%{?fedora} >= 22
+export CC=clang CXX=clang++
+%endif
+
GYP_GENERATORS=ninja ./build/gyp_chromium --depth=. \
-Duse_system_expat=1 \
-Duse_system_flac=1 \
@@ -96,7 +112,11 @@ GYP_GENERATORS=ninja ./build/gyp_chromium --depth=. \
-Duse_system_libevent=1 \
-Duse_system_libjpeg=1 \
-Duse_system_libpng=1 \
+%if 0%{?fedora} >= 23
+ -Duse_system_libvpx=1 \
+%else
-Duse_system_libvpx=0 \
+%endif
-Duse_system_libwebp=1 \
-Duse_system_opus=1 \
-Duse_system_snappy=1 \
@@ -114,7 +134,12 @@ GYP_GENERATORS=ninja ./build/gyp_chromium --depth=. \
-Dlinux_link_pulseaudio=1 \
-Dicu_use_data_file_flag=0 \
-Dlibspeechd_h_prefix=speech-dispatcher/ \
+%if 0%{?fedora} >= 22
+ -Dclang=1 \
+ -Dclang_use_chrome_plugins=0 \
+%else
-Dclang=0 \
+%endif
-Dwerror= \
-Ddisable_fatal_linker_warnings=1 \
-Dgoogle_api_key=AIzaSyCcK3laItm4Ik9bm6IeGFC6tVgy4eut0_o \
@@ -200,6 +225,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%changelog
+* Tue May 26 2015 - Ting-Wei Lan <lantw44@gmail.com> - 43.0.2357.65-2
+- Workaround GCC 5.1 issues by compiling with clang on Fedora 22 or later
+- Unbundle libvpx on Fedora 23 or later
+
* Wed May 20 2015 - Ting-Wei Lan <lantw44@gmail.com> - 43.0.2357.65-1
- Update to 43.0.2357.65