From 599089de80617ff75ac76937e933fcc9950e4798 Mon Sep 17 00:00:00 2001 From: David Adam Date: Sun, 11 Dec 2016 16:58:13 +0800 Subject: [PATCH] fish.spec: add dependency on newer GCC on old platforms Moving to C++11 requires a newer compiler on old systems; our Open Build Service repository has a newer version available for RHEL 5 & 6 builds. --- fish.spec.in | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/fish.spec.in b/fish.spec.in index 89ce0314b..18a05d3aa 100644 --- a/fish.spec.in +++ b/fish.spec.in @@ -11,6 +11,10 @@ URL: http://fishshell.com/ Source0: %{name}_@VERSION@.orig.tar.gz BuildRequires: ncurses-devel gettext gcc-c++ autoconf +%if 0%{?opensuse_bs} && 0%{?rhel} && 0%{?rhel} < 7 +BuildRequires: gcc48 gcc48-c++ +%endif + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: bc @@ -34,6 +38,10 @@ is simple but incompatible with other shell languages. %setup -q -n %{name}-@VERSION@ %build +%if 0%{?opensuse_bs} && 0%{?rhel} && 0%{?rhel} < 7 +export CC=gcc48 +export CXX=g++48 +%endif %configure make %{?_smp_mflags}