• [gentoo-dev] [PATCH 1/2] latex-package.eclass: use edo

    From Florian Schmaus@21:1/5 to All on Mon Feb 24 11:00:01 2025
    Signed-off-by: Florian Schmaus <flow@gentoo.org>
    ---
    eclass/latex-package.eclass | 10 ++++++----
    1 file changed, 6 insertions(+), 4 deletions(-)

    diff --git a/eclass/latex-package.eclass b/eclass/latex-package.eclass
    index dfef7fc2836f..f23897d4315c 100644
    --- a/eclass/latex-package.eclass
    +++ b/eclass/latex-package.eclass
    @@ -1,4 +1,4 @@
    -# Copyright 1999-2024 Gentoo Authors
    +# Copyright 1999-2025 Gentoo Authors
    # Distributed under the terms of the GNU General Public License v2

    # @ECLASS: latex-package.eclass
    @@ -60,6 +60,8 @@ esac
    if [[ -z ${_LATEX_PACKAGE_ECLASS} ]]; then
    _LATEX_PACKAGE_ECLASS=1

    +inherit edo
    +
    RDEPEND="virtual/latex-base"
    BDEPEND="${RDEPEND}
    >=sys-apps/texinfo-4.2-r5"
    @@ -145,11 +147,11 @@ latex-package_src_doinstall() {
    "${i}"
    )
    # some macros need compiler called twice, do it here.
    - if "${mypdflatex[@]}"; then
    - "${mypdflatex[@]}"
    + if nonfatal edo "${mypdflatex[@]}"; then
    + edo "${mypdflatex[@]}"
    else
    einfo "pdflatex failed, trying t
  • From Florian Schmaus@21:1/5 to All on Mon Feb 24 11:00:01 2025
    Closes: https://bugs.gentoo.org/950021
    Signed-off-by: Florian Schmaus <flow@gentoo.org>
    ---
    eclass/latex-package.eclass | 14 +++++++++++++-
    1 file changed, 13 insertions(+), 1 deletion(-)

    diff --git a/eclass/latex-package.eclass b/eclass/latex-package.eclass
    index f23897d4315c..e35da30e1b44 100644
    --- a/eclass/latex-package.eclass
    +++ b/eclass/latex-package.eclass
    @@ -79,6 +79,12 @@ TEXMF="/usr/share/texmf-site"
    # DESCRIPTION above)
    SUPPLIER="misc"

    +# @ECLASS_VARIABLE: LATEX_ENGINE
    +# @DESCRIPTION:
    +# When compiling documentation (.tex/.dtx), use the specified engine,
    +# e.g., lualatex, to build the documention. Defaults to pdflatex.
    +: "${LATEX_ENGINE:=pdflatex}"
    +
    # @ECLASS_VARIABLE: LATEX_DOC_ARGUMENTS
    # @DESCRIPTION:
    # When compiling documentation (.tex/.dtx), this variable will be passed
    @@ -140,12 +146,18 @@ latex-package_src_doinstall() {

    einfo "Making documentation: ${i}"
    local mypdflatex=(
    - pdflatex
    + ${LATEX_ENGINE}
    ${LATEX_DOC_ARGUMENTS}
    --halt-on-error
    --interaction=nonstopmode
    "${i}"