summaryrefslogtreecommitdiff
path: root/scite-fedora
diff options
context:
space:
mode:
authorB Stack <bgstack15@gmail.com>2019-06-11 14:26:58 -0400
committerB Stack <bgstack15@gmail.com>2019-06-11 14:26:58 -0400
commitb70260c51a56f4c8c013b1417631aa0f61bcae7a (patch)
treebdf348d4d9a7991194bb9ff525f48d07abd1b6fd /scite-fedora
parentMerge branch 'palemoon-bump' into 'master' (diff)
downloadstackrpms-b70260c51a56f4c8c013b1417631aa0f61bcae7a.tar.gz
stackrpms-b70260c51a56f4c8c013b1417631aa0f61bcae7a.tar.bz2
stackrpms-b70260c51a56f4c8c013b1417631aa0f61bcae7a.zip
scite 4.1.6 and merged rpm specs
Diffstat (limited to 'scite-fedora')
-rw-r--r--scite-fedora/scite.spec59
1 files changed, 46 insertions, 13 deletions
diff --git a/scite-fedora/scite.spec b/scite-fedora/scite.spec
index d5b5686..ac52a51 100644
--- a/scite-fedora/scite.spec
+++ b/scite-fedora/scite.spec
@@ -1,9 +1,18 @@
-%global tarballversion 415
+# el is on 3.x, fc is on 4.x
+%global pkgversion 4.1.6
+%define tarballversion %( echo %pkgversion | tr -d '.' )
+
+%define scl_env %{nil}
+%define scl_buildreq coreutils
+%if 0%{?el6}
+ %define scl_env devtoolset-7
+ %define scl_buildreq devtoolset-7-toolchain
+%endif
Name: scite
-Version: 4.1.5
+Version: %{pkgversion}
Release: 1%{?dist}
-Summary: SCIntilla based GTK2 text editor
+Summary: SCIntilla-based GTK text editor
License: MIT
Group: Applications/Editors
Url: http://www.scintilla.org/SciTE.html
@@ -12,14 +21,15 @@ Packager: B Stack <bgstack15@gmail.com>
Source0: https://www.scintilla.org/scite%{tarballversion}.tgz
Patch0: scite-utf8.patch
-%if 0%{?fedora}
+BuildRequires: desktop-file-utils
BuildRequires: gcc-c++
+BuildRequires: %{scl_buildreq}
+%if 0%{?el6}
+BuildRequires: gtk2-devel
+%else
BuildRequires: gtk3-devel
%endif
-BuildRequires: gtk2-devel
-BuildRequires: desktop-file-utils
-
Provides: bundled(scintilla) = %{version}
%description
@@ -34,11 +44,26 @@ building and running programs.
rm -rf scite/lua
%build
-make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
- CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" GTK3=1 DEBUG=1 -C scintilla/gtk
-#Build without lua support
-make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
- CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" GTK3=1 DEBUG=1 NO_LUA=1 -C scite/gtk
+
+%if 0%{?el6}
+ %if "%{?scl_env}" != ""
+ scl enable %{scl_env} /bin/bash <<'EOFSCL'
+ %endif
+ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
+ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" DEBUG=1 -C scintilla/gtk
+ #Build without lua support
+ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
+ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" DEBUG=1 NO_LUA=1 -C scite/gtk
+ %if "%{?scl_env}" != ""
+EOFSCL
+ %endif
+%else
+ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
+ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" GTK3=1 DEBUG=1 -C scintilla/gtk
+ #Build without lua support
+ make %{?_smp_mflags} LDFLAGS="%{?__global_ldflags}" \
+ CFLAGS="%{optflags}" CXXFLAGS="%{optflags}" GTK3=1 DEBUG=1 NO_LUA=1 -C scite/gtk
+%endif
%install
make DESTDIR=%{buildroot} -C scite/gtk install
@@ -53,11 +78,16 @@ desktop-file-install --delete-original \
--remove-key Encoding \
%{buildroot}%{_datadir}/applications/SciTE.desktop
+%if 0%{?fedora}
+%posttrans
+/usr/bin/update-desktop-database &> /dev/null || :
+%else
%post
/usr/bin/update-desktop-database &> /dev/null || :
%postun
/usr/bin/update-desktop-database &> /dev/null || :
+%endif
%files
%doc scite/License.txt
@@ -69,7 +99,10 @@ desktop-file-install --delete-original \
%{_datadir}/applications/*
%changelog
-* Mon May 06 2019 B Stack <bgstack15@gmail.com> - 4.1.5-1
+* Tue Jun 6 2019 B Stack <bgstack15@gmail.com> - 4.1.6-1/3.7.5-1
+- Rewritten to build Fedora and Enterprise Linux versions from a single spec with minor flags changed
+
+* Mon May 6 2019 B Stack <bgstack15@gmail.com> - 4.1.5-1
- Brought to latest version
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.7.5-3
bgstack15