summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2017-06-09 09:54:13 +0200
committerRemi Collet <remi@remirepo.net>2017-06-09 09:54:13 +0200
commit18e92a27903816b6db19122eb03ddcfb8c29afdd (patch)
treedafbeb245ec9156ab36d8b58a875d680c87a9a75
parente2294b75aa58f8b67b2da18510ccacbb73f0705d (diff)
use GCC 6.2 from devtoolset-6 on EL-7
-rw-r--r--libmustache.spec24
1 files changed, 22 insertions, 2 deletions
diff --git a/libmustache.spec b/libmustache.spec
index 877b440..f006848 100644
--- a/libmustache.spec
+++ b/libmustache.spec
@@ -19,7 +19,7 @@
Name: %{libname}
Version: 0.4.3
-Release: 1%{?dist}
+Release: 2%{?dist}
Group: System Environment/Libraries
Summary: Mustache C++ library
@@ -33,7 +33,11 @@ BuildRequires: automake
BuildRequires: libtool
BuildRequires: libyaml-devel
BuildRequires: libstdc++-devel
+%if 0%{?rhel} == 7
+BuildRequires: devtoolset-6-toolchain
+%else
BuildRequires: gcc-c++
+%endif
%description
@@ -63,26 +67,39 @@ This package provides mustache command line tool split off %{libname}.
%prep
%setup -qn %{gh_project}-%{gh_commit} -a1
+%if 0%{?rhel} == 7
+source /opt/rh/devtoolset-6/enable
+g++ --version
+%endif
rmdir spec
mv %{spec_project}-%{spec_commit} spec
-
autoreconf -fiv
%build
+%if 0%{?rhel} == 7
+source /opt/rh/devtoolset-6/enable
+%endif
+
%configure
make %{?_smp_mflags}
%install
+%if 0%{?rhel} == 7
+source /opt/rh/devtoolset-6/enable
+%endif
make install DESTDIR=%{buildroot}
rm %{buildroot}%{_libdir}/*.{a,la}
%check
+%if 0%{?rhel} == 7
+source /opt/rh/devtoolset-6/enable
+%endif
make test
@@ -105,5 +122,8 @@ make test
%changelog
+* Fri Jun 9 2017 Remi Collet <remi@remirepo.net> - 0.4.3-2
+- use GCC 6.2 from devtoolset-6 on EL-7
+
* Thu Jun 8 2017 Remi Collet <remi@remirepo.net> - 0.4.3-1
- initial package