From 3f132d5eef83beb4bb0a8820c86e527494da6d75 Mon Sep 17 00:00:00 2001 From: B Stack Date: Sun, 5 May 2019 18:04:27 -0400 Subject: add scl for el6, el7 --- scite/scite.spec | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'scite') diff --git a/scite/scite.spec b/scite/scite.spec index df70755..7072223 100644 --- a/scite/scite.spec +++ b/scite/scite.spec @@ -1,5 +1,12 @@ %global tarballversion 415 +%define scl_env %{nil} +%define scl_buildreq coreutils +%if 0%{?el6}%{?el7} + %define scl_env devtoolset-7 + %define scl_buildreq devtoolset-7-toolchain +%endif + Name: scite Version: 4.1.5 Release: 1%{?dist} @@ -13,8 +20,9 @@ Source0: https://www.scintilla.org/scite%{tarballversion}.tgz Patch0: scite-utf8.patch %if 0%{?fedora}%{?el7} -BuildRequires: gcc-c++ +BuildRequires: gcc-c++ BuildRequires: gtk3-devel +BuildRequires: %{scl_buildreq} %endif BuildRequires: gtk2-devel @@ -34,6 +42,9 @@ building and running programs. rm -rf scite/lua %build +%if "%{?scl_env}" != "" + scl enable %{scl_env} /bin/bash <<'EOFSCL' +%endif %if 0%{?el6} make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" DEBUG=1 -C scintilla/gtk @@ -49,6 +60,10 @@ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" GTK3=1 DEBUG=1 NO_LUA=1 -C scite/gtk %endif +: +%if "%{?scl_env}" != "" +EOFSCL +%endif %install make DESTDIR=%{buildroot} -C scite/gtk install -- cgit