From: "Andrey Grozin" <grozin@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-visualization/gle/files/, sci-visualization/gle/
Date: Fri, 16 May 2025 12:29:53 +0000 (UTC) [thread overview]
Message-ID: <1747398573.7d9ef11296003ad536c8c8081bb49a15debdb9bb.grozin@gentoo> (raw)
commit: 7d9ef11296003ad536c8c8081bb49a15debdb9bb
Author: Andrey Grozin <grozin <AT> gentoo <DOT> org>
AuthorDate: Fri May 16 12:29:33 2025 +0000
Commit: Andrey Grozin <grozin <AT> gentoo <DOT> org>
CommitDate: Fri May 16 12:29:33 2025 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7d9ef112
sci-visualization/gle: ebuild improvements
Signed-off-by: Andrey Grozin <grozin <AT> gentoo.org>
sci-visualization/gle/files/latexmk.patch | 21 ++++++
sci-visualization/gle/files/top_dir.patch | 13 ++++
sci-visualization/gle/gle-4.3.6-r1.ebuild | 110 ++++++++++++++++++++++++++++++
3 files changed, 144 insertions(+)
diff --git a/sci-visualization/gle/files/latexmk.patch b/sci-visualization/gle/files/latexmk.patch
new file mode 100644
index 000000000000..7b723a9bf2ba
--- /dev/null
+++ b/sci-visualization/gle/files/latexmk.patch
@@ -0,0 +1,21 @@
+diff '--color=auto' -r -U3 gle-manual-4.3.6.orig/Makefile.gcc gle-manual-4.3.6/Makefile.gcc
+--- gle-manual-4.3.6.orig/Makefile.gcc 2025-04-05 03:19:08.000000000 +0700
++++ gle-manual-4.3.6/Makefile.gcc 2025-05-14 11:54:38.311675981 +0700
+@@ -52,7 +52,7 @@
+
+ ifneq ($(UNAME_S),Darwin)
+ pdf: defs.tex
+- pdflatex gle-manual.tex
++ latexmk -pdf gle-manual.tex
+ else
+ # define the APPLE command to elimnate the countour plots for macOS in utilities\countour.tex
+ # the coutour figures cause a seg fault in GLE and this workaround eliminates
+@@ -63,7 +63,7 @@
+
+
+ dvi:
+- latex gle-manual.tex
++ latexmk -dvi gle-manual.tex
+
+ index:
+ makeindex gle-manual
diff --git a/sci-visualization/gle/files/top_dir.patch b/sci-visualization/gle/files/top_dir.patch
new file mode 100644
index 000000000000..97e36517fc1b
--- /dev/null
+++ b/sci-visualization/gle/files/top_dir.patch
@@ -0,0 +1,13 @@
+diff '--color=auto' -r -U3 src.orig/gle/config.cpp src/gle/config.cpp
+--- src.orig/gle/config.cpp 2025-04-04 21:33:02.000000000 +0700
++++ src/gle/config.cpp 2025-05-16 18:50:23.693366144 +0700
+@@ -666,8 +666,7 @@
+ has_config = try_load_config_sub(conf_name, triedLocations);
+ }
+ #else
+- GLE_TOP_DIR = exe_name;
+- StripPathComponents(&GLE_TOP_DIR, 2);
++ GLE_TOP_DIR = "/usr/share/gle";
+ #endif
+ } else {
+ // The user will see as error message: "$GLE_TOP/some_file" not found.
diff --git a/sci-visualization/gle/gle-4.3.6-r1.ebuild b/sci-visualization/gle/gle-4.3.6-r1.ebuild
new file mode 100644
index 000000000000..556ca1825fc2
--- /dev/null
+++ b/sci-visualization/gle/gle-4.3.6-r1.ebuild
@@ -0,0 +1,110 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_BUILD_TYPE=Release
+inherit cmake elisp-common flag-o-matic
+
+DESCRIPTION="Graphics Layout Engine"
+HOMEPAGE="https://glx.sourceforge.io/ https://github.com/vlabella/GLE/"
+SRC_URI="https://github.com/vlabella/GLE/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
+ https://github.com/vlabella/gle-library/archive/refs/tags/v${PV}.tar.gz -> ${PN}-library-${PV}.tar.gz
+ doc? ( https://github.com/vlabella/gle-manual/archive/refs/tags/v${PV}.tar.gz -> ${PN}-manual-${PV}.tar.gz )
+ emacs? ( https://dev.gentoo.org/~grozin/gle-mode.el.gz )"
+S="${WORKDIR}"/GLE-${PV}/src
+LICENSE="BSD gui? ( GPL-2+ )"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="doc emacs gui manip"
+
+DEPEND="app-text/ghostscript-gpl
+ app-text/poppler
+ dev-libs/boost
+ media-libs/libjpeg-turbo
+ media-libs/libpng
+ media-libs/tiff
+ sys-libs/zlib
+ x11-libs/cairo
+ x11-libs/pixman
+ gui? (
+ media-libs/freeglut
+ media-libs/glu
+ dev-qt/qtcore:5
+ dev-qt/qtdbus:5
+ dev-qt/qtgui:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtopengl:5
+ dev-qt/qtwidgets:5
+ )
+ manip? ( sys-libs/ncurses:0 )
+ emacs? ( app-editors/emacs:* )"
+RDEPEND="${DEPEND}
+ virtual/latex-base"
+BDEPEND="kde-frameworks/extra-cmake-modules
+ doc? ( virtual/latex-base )"
+
+PATCHES=(
+ "${FILESDIR}"/cmake-cmp0177.patch
+ "${FILESDIR}"/install-dirs.patch
+ "${FILESDIR}"/top_dir.patch
+ "${FILESDIR}"/zstd-shared.patch
+)
+SITEFILE="64${PN}-gentoo.el"
+
+src_prepare() {
+ cmake_src_prepare
+ if use doc; then
+ pushd "$WORKDIR"/gle-manual-${PV} > /dev/null || die "pushd gle_manual failed"
+ eapply "${FILESDIR}"/latexmk.patch
+ popd > /dev/null
+ fi
+}
+
+src_configure() {
+ # -Werror=odr
+ # https://bugs.gentoo.org/927779
+ # https://github.com/vlabella/GLE/issues/35
+ filter-lto
+
+ local mycmakeargs=(
+ -DGLEDOC=share/doc/${PF}
+ -DGLE_EXAMPLES_LIBRARY_PATH="${WORKDIR}"/gle-library-${PV}
+ -DBUILD_GUI=$(usex gui)
+ -DBUILD_MANIP=$(usex manip)
+ )
+ cmake_src_configure
+}
+
+src_compile() {
+ cmake_src_compile
+ use emacs && elisp-compile "${WORKDIR}"/*.el
+
+ # I don't really understand why is this hack needed
+ sed -e 's/|+//' -i "${BUILD_DIR}"/gle/cmake_install.cmake
+}
+
+src_install() {
+ export GLE_TOP="${D}"/usr/share/gle
+ cmake_src_install
+ #GLE_TOP="${D}"/usr/share/${PN} "${D}"/usr/bin/gle.bin -mkinittex
+ if use doc; then
+ pushd "$WORKDIR"/gle-manual-${PV} > /dev/null || die "pushd gle_manual failed"
+ export PATH="${D}"/usr/bin:${PATH}
+ make -f Makefile.gcc GLE="${D}"/usr/bin/gle
+ dodoc gle-manual.pdf
+ popd > /dev/null
+ fi
+ if use emacs; then
+ elisp-install ${PN} "${WORKDIR}"/*.el "${WORKDIR}"/*.elc
+ elisp-site-file-install "${FILESDIR}/${SITEFILE}"
+ fi
+}
+
+pkg_postinst() {
+ use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+ use emacs && elisp-site-regen
+}
next reply other threads:[~2025-05-16 12:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-16 12:29 Andrey Grozin [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-12-24 6:21 [gentoo-commits] repo/gentoo:master commit in: sci-visualization/gle/files/, sci-visualization/gle/ Andrey Grozin
2022-12-21 16:01 Andrey Grozin
2018-01-13 8:18 Andrey Grozin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1747398573.7d9ef11296003ad536c8c8081bb49a15debdb9bb.grozin@gentoo \
--to=grozin@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox