diff options
Diffstat (limited to 'app-editors/scite')
-rw-r--r-- | app-editors/scite/Manifest | 4 | ||||
-rw-r--r-- | app-editors/scite/metadata.xml | 2 | ||||
-rw-r--r-- | app-editors/scite/scite-5.1.1.ebuild | 115 |
3 files changed, 119 insertions, 2 deletions
diff --git a/app-editors/scite/Manifest b/app-editors/scite/Manifest index a27a80610b50..60f969b064a8 100644 --- a/app-editors/scite/Manifest +++ b/app-editors/scite/Manifest @@ -1,3 +1,5 @@ DIST scite-4.4.4.tgz 2775628 BLAKE2B a7607b53bf529c56f6525d44b052a08c914d8aa1d90d475dcf46927ac5ce83c06d68b70e8d8e8969c77c367240ba1e7ac10d599c77002575e84b9baf6445d03b SHA512 1e8529286206d542e0c07353b73ab38aa9ee2e2256ed8e15328965e00a33eb026f79bd7d330253e8743cf5503fadb32c64162973ad21da16993f11e124842ec0 +DIST scite-5.1.1.tgz 3374717 BLAKE2B b7a45a86008eb592adacc8fde90cb637cc7cac821f339bb65920aaf912ee10d52badde3ed2e71118a7ce4690a0536b298c5fe5f673b886902ad4634b3a1ffaa6 SHA512 4d6c9b3ca4caed4fcb70a6b1c86a2ace13b023241f16d6faa01b3f692bcbfa14e0ce186bb08776ee0cf62768b2b77c4ffcae610ddbb6b04dcb7584fd8b3f27bb EBUILD scite-4.4.4-r10.ebuild 2975 BLAKE2B d11639ddcede16d0bb062f824f483e7148799cb4a690a457102d5d85714eb4a271f200da5b76f76315c08de078873c5f5e9695245aca01747c41944d68a11f87 SHA512 8436c3c2129dc22ef640534214691a4ba56242ea784141f81f04f53a0f93ca7603a4f551fc9f08c074091eb15b6ad38fc201224d7eb7c6226cf78926eadb6d03 -MISC metadata.xml 476 BLAKE2B 8f16ea1b891813a88b9a94e6c9b543ed8cfaed30a098582344d5d4337d905d88a8216a16de405f45892a95fa27a77b2f02c82727f9490cb157a01a841b480676 SHA512 fceeca0a2879cb5dcd2fafd67be9bae09fdfdec389f0adbaf4c012a4c17ad592ca0b4b4f689e080063f36be510651bd15999055c426c95258ed132cb6333be44 +EBUILD scite-5.1.1.ebuild 2900 BLAKE2B d836630201e801fa18100bb6b0f1093a30c17cf91e111c5d5fc0909f37b1f89f86a9d4948f59112c275ed76b8236177368bcbbe4b19b99e553e677a6811d1dfc SHA512 281092e5f2b8c76391cbd82540bb12474edc62a5e614d787dfdb52f5ead3f455a5e3b7b90bfa64d6cf76e693344ec4c8771a5839905df53901eea57a382157a1 +MISC metadata.xml 477 BLAKE2B 6b4ee233530c91bd81cb7aaec6533f9d4f917765d372e8e84bed225da07b0db5e94f00d34644d9496a3d7321c8a16dc6e65b993263901ab8e58b65664f50458c SHA512 b7329399a31e6e514cebc509b048943a4cce7fca1affc7ac9f401420e885d51a7af6f60d61bc5405326c54a2d1207583f066e3b77ab4b08d00333b6ec43cdc0d diff --git a/app-editors/scite/metadata.xml b/app-editors/scite/metadata.xml index 856d6746499b..7694337e8744 100644 --- a/app-editors/scite/metadata.xml +++ b/app-editors/scite/metadata.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> <maintainer type="person" proxied="yes"> <email>ervin.peters@ervnet.de</email> diff --git a/app-editors/scite/scite-5.1.1.ebuild b/app-editors/scite/scite-5.1.1.ebuild new file mode 100644 index 000000000000..d206fb1266de --- /dev/null +++ b/app-editors/scite/scite-5.1.1.ebuild @@ -0,0 +1,115 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-1 ) + +inherit lua-single toolchain-funcs xdg + +DESCRIPTION="A very powerful, highly configurable, small editor with syntax coloring" +HOMEPAGE="https://www.scintilla.org/SciTE.html" +SRC_URI="https://www.scintilla.org/${PN}${PV//./}.tgz -> ${P}.tgz" + +LICENSE="HPND lua? ( MIT )" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~arm-linux ~x86-linux" +IUSE="lua" + +REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} )" + +RDEPEND=" + dev-libs/atk + dev-libs/glib:2 + x11-libs/cairo + x11-libs/gdk-pixbuf:2 + x11-libs/gtk+:3 + x11-libs/pango + lua? ( ${LUA_DEPS} )" + +DEPEND="${RDEPEND}" + +BDEPEND=" + virtual/pkgconfig" + +DOCS=("../README") + +S="${WORKDIR}/${PN}/gtk" + +pkg_pretend() { + if tc-is-clang ; then + # need c++17 features + [[ "${MERGE_TYPE}" != "binary" && + $(clang-major-version) -lt 5 ]] && + die "Sorry, SCiTE uses C++17 Features and needs >sys-devel/clang-5 + ($(clang-major-version))." + + elif tc-is-gcc; then + # older gcc is not supported + [[ "${MERGE_TYPE}" != "binary" && + $(gcc-major-version) -lt 7 ]] && + die "Sorry, Scite uses C++17 Features, need >sys-devel/gcc-7." + else + die "Either gcc or clang should be configured for building scite" + fi +} + +pkg_setup() { + use lua && lua-single_pkg_setup +} + +src_prepare() { + tc-export AR CC CXX RANLIB + + # remove hardcoded CC, Optimizations and clang unknown flags + sed -i "${WORKDIR}/scintilla/gtk/makefile" \ + -e "s#^CC = gcc#CC = ${CC}#" \ + -e "s#^CC = clang#CC = ${CC}#" \ + -e "s#^CXX = clang++#CXX = ${CXX}#" \ + -e "s#-Os##" \ + -e "s#-Wno-misleading-indentation##" \ + || die "error patching /scintilla/gtk/makefile" + + sed -i "${S}/makefile" \ + -e "s#^CC = clang#CC = ${CC}#" \ + -e "s#^CXX = clang++#CXX = ${CXX}#" \ + -e "s#-rdynamic#-rdynamic ${LDFLAGS}#" \ + -e "s#-Os##" \ + || die "error patching gtk/makefile" + + # repair and enhance the .desktop file + sed -i "${S}/SciTE.desktop" \ + -e "s#text/plain#text/\*;application/xhtml+xml#" \ + -e "s#^Categories=\(.*\)#Categories=Development;#" \ + || die "error patching /scite/gtk/SciTe.desktop" + + # add the ebuild suffix as shell type for working with ebuilds + sed -i "${WORKDIR}/scite/src/perl.properties" \ + -e "s#\*.sh;\*.bsh;#\*.ebuild;\*.sh;\*.bsh;#" \ + || die "error patching /scite/src/perl.properties" + + # it seems that pwd here is ${S}, but user patches are relative to ${workdir} + # Bug #576162 + + cd "${WORKDIR}" || die "couldn't cd into ${WORKDIR}" + eapply_user +} + +src_compile() { + # prepare make options + local emake_pars=("GTK3=1") + + tc-is-clang && emake_pars+=("CLANG=1") + use !lua && emake_pars+=("NO_LUA=1") + + emake -C "${WORKDIR}/lexilla/src" "${emake_pars[@]}" + emake -C "${WORKDIR}/scintilla/gtk" "${emake_pars[@]}" + emake "${emake_pars[@]}" +} + +# want to use the base src_install() as base_src_install() + +src_install() { + default + dosym SciTE /usr/bin/scite +} |