Gentoo Archives: gentoo-commits

From: Agostino Sarubbo <ago@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-editors/scite/
Date: Fri, 15 Feb 2019 15:04:15
Message-Id: 1550243040.ec786164484f592edf7bb7404ff734bc2659c009.ago@gentoo
1 commit: ec786164484f592edf7bb7404ff734bc2659c009
2 Author: Ervin Peters <coder <AT> ervnet <DOT> de>
3 AuthorDate: Sun Jan 13 18:13:06 2019 +0000
4 Commit: Agostino Sarubbo <ago <AT> gentoo <DOT> org>
5 CommitDate: Fri Feb 15 15:04:00 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ec786164
7
8 app-editors/scite: Version bump scite-4.1.3
9
10 additionally see PR #10562 for previous Version and cleanup
11
12 Signed-off-by: Ervin Peters <ervin.peters <AT> ervnet.de>
13 Package-Manager: Portage-2.3.51, Repoman-2.3.11
14 Signed-off-by: Agostino Sarubbo <ago <AT> gentoo.org>
15
16 app-editors/scite/Manifest | 1 +
17 app-editors/scite/scite-4.1.3.ebuild | 119 +++++++++++++++++++++++++++++++++++
18 2 files changed, 120 insertions(+)
19
20 diff --git a/app-editors/scite/Manifest b/app-editors/scite/Manifest
21 index ac744de0d36..661060c12fb 100644
22 --- a/app-editors/scite/Manifest
23 +++ b/app-editors/scite/Manifest
24 @@ -1,3 +1,4 @@
25 +DIST scite-4.1.3.tgz 2546247 BLAKE2B 9c0cd767e6aff861bb706500eebf5fa431d5ce608f37a9b19d2af7d558698eb3073a33fcdd0900abb549aa9ed65981a9f217dc1dae4b21be919c380d20d4ee8f SHA512 875dd44785e9c96a264df9061830c7ab51296061da7765084ec4445d7f529dabecebcfadc5a1d8cab9074ffd588903ca056ed5de0ae974d60a5c57b13d61550d
26 DIST scite355.tgz 2302137 BLAKE2B 5b36c68a5447b7fd0dd2fce51fc09cec0ee4a86be10f4f32fa7bf47354c56424cbead6cdfe819c8014be75e843c867ccaa137c5f7e32c3f9b0dabb6b9a5a9cb3 SHA512 cdd9d3aa621f5d31632cfb9f71524255a4b47b70a654bf4bc8a25a76f8a2dbe098a48e0cd4587ced8ca8455be7e809973e212fcbcde5b62087aa0f9528f7f40d
27 DIST scite365.tgz 2391190 BLAKE2B 0cd2b1b24bcd15815357125725b1453935dc944ca1ddbd77772923ceeb249b3182dc47cb1e1097a4e0942b3a5c7528d0e80fe2314ed9d3d2b7f4e960a0f17ff2 SHA512 193dcb1f8787a7c7d520ce62462e5c95e7b6bcaf79f4ab23f9885474fb0444dbc5a69a0d45eafc592e5fff2a2e746a9aba599799e847e3c74d3436eed26580a9
28 DIST scite402.tgz 2424648 BLAKE2B 84a331865310058d26ca45a25b99d98a7c3374d0463024e31694e2ebbd519a20e8e368dc1dfabc2534e8f015fc95ca53382bc223476b882a7be543ffdc44ae2b SHA512 97898cbb8675d013dd91828792de1c71e3f013b21c59c5112ddc00e7ee35c2ba8cc29e2c3256b91171e052145a25cddfd0034505e3c185999c734504bb702283
29
30 diff --git a/app-editors/scite/scite-4.1.3.ebuild b/app-editors/scite/scite-4.1.3.ebuild
31 new file mode 100644
32 index 00000000000..fd4938711af
33 --- /dev/null
34 +++ b/app-editors/scite/scite-4.1.3.ebuild
35 @@ -0,0 +1,119 @@
36 +# Copyright 1999-2019 Gentoo Authors
37 +# Distributed under the terms of the GNU General Public License v2
38 +
39 +EAPI=6
40 +
41 +inherit gnome2-utils toolchain-funcs xdg-utils
42 +
43 +MY_PV=${PV//./}
44 +DESCRIPTION="A very powerful, highly configurable, small editor with syntax coloring"
45 +HOMEPAGE="http://www.scintilla.org/SciTE.html"
46 +SRC_URI="https://www.scintilla.org/${PN}${MY_PV}.tgz -> ${P}.tgz"
47 +
48 +LICENSE="HPND lua? ( MIT )"
49 +SLOT="0"
50 +KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux"
51 +IUSE="lua"
52 +
53 +RDEPEND="
54 + dev-libs/glib:=
55 + x11-libs/cairo
56 + x11-libs/gdk-pixbuf
57 + x11-libs/gtk+:3=
58 + x11-libs/pango
59 + lua? ( >=dev-lang/lua-5:= )
60 +"
61 +
62 +DEPEND="${RDEPEND}
63 + virtual/pkgconfig"
64 +
65 +S="${WORKDIR}/${PN}/gtk"
66 +
67 +pkg_pretend() {
68 + if tc-is-clang ; then
69 + # need c++17 features
70 + [[ "${MERGE_TYPE}" != "binary" &&
71 + $(clang-major-version) -lt 5 ]] &&
72 + die "Sorry, SCiTE uses C++17 Features and needs >sys-devel/clang-5
73 + ($(clang-major-version))."
74 +
75 + elif tc-is-gcc; then
76 + # older gcc is not supported
77 + [[ "${MERGE_TYPE}" != "binary" &&
78 + $(gcc-major-version) -lt 7 ]] &&
79 + die "Sorry, Scite uses C++17 Features, need >sys-devel/gcc-7."
80 + else
81 + die "Either gcc or clang should be configured for building scite"
82 + fi
83 +}
84 +
85 +src_prepare() {
86 + # remove hardcoded CC, Optimizations and clang unknown flags
87 + sed -i "${WORKDIR}/scintilla/gtk/makefile" \
88 + -e "s#^CC = gcc#CC = ${CC}#" \
89 + -e "s#^CC = clang#CC = ${CC}#" \
90 + -e "s#^CXX = clang++#CC = ${CXX}#" \
91 + -e "s#-Os##" \
92 + -e "s#-Wno-misleading-indentation##" \
93 + || die "error patching /scintilla/gtk/makefile"
94 +
95 + sed -i "${S}/makefile" \
96 + -e "s#^CC = clang#CC = ${CC}#" \
97 + -e "s#^CXX = clang++#CC = ${CXX}#" \
98 + -e "s#-rdynamic#-rdynamic ${LDFLAGS}#" \
99 + -e "s#-Os##" \
100 + || die "error patching gtk/makefile"
101 +
102 + # repair and enhance the .desktop file
103 + sed -i "${S}/SciTE.desktop" \
104 + -e "s#text/plain#text/\*;application/xhtml+xml#" \
105 + -e "s#^Categories=\(.*\)#Categories=Development;#" \
106 + || die "error patching /scite/gtk/SciTe.desktop"
107 +
108 + # add the ebuild suffix as shell type for working with ebuilds
109 + sed -i "${WORKDIR}/scite/src/perl.properties" \
110 + -e "s#\*.sh;\*.bsh;#\*.ebuild;\*.sh;\*.bsh;#" \
111 + || die "error patching /scite/src/perl.prperties"
112 +
113 + # it seems that pwd here is ${S}, but user patches are relative to ${workdir}
114 + # Bug #576162
115 +
116 + cd "${WORKDIR}" || die "couldn't cd into ${WORKDIR}"
117 + eapply_user
118 +}
119 +
120 +src_compile() {
121 + # prepare make options
122 + local emake_pars="GTK3=1"
123 +
124 + if tc-is-clang ; then
125 + emake_pars+=" CLANG=1"
126 + fi
127 +
128 + if ! use lua; then
129 + emake_pars+=" NO_LUA=1"
130 + fi
131 +
132 + emake -C "${WORKDIR}/scintilla/gtk" "${emake_pars}"
133 + emake "${emake_pars}"
134 +}
135 +
136 +src_install() {
137 + emake DESTDIR="${ED}" install
138 +
139 + # we have to keep this because otherwise it'll break upgrading
140 + mv "${ED}/usr/bin/SciTE" "${ED}/usr/bin/scite" || die
141 + dosym scite /usr/bin/SciTE
142 + doman ../doc/scite.1
143 + dodoc ../README
144 +}
145 +
146 +pkg_postinst() {
147 + gnome2_icon_cache_update
148 + xdg_desktop_database_update
149 +}
150 +
151 +pkg_postrm() {
152 + gnome2_icon_cache_update
153 + xdg_desktop_database_update
154 +}