summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Schmaus <flow@gentoo.org>2024-02-28 20:49:36 +0100
committerFlorian Schmaus <flow@gentoo.org>2024-02-28 20:50:51 +0100
commit42f56cac75be75e6a7641217bb634b1d50b9c7f7 (patch)
tree2d8e870ad8fdb27838ab94ceafa1c530783ce4a4
parentdev-texlive/texlive-humanities: conditionally make and patch to respect flags (diff)
downloadtex-overlay-42f56cac75be75e6a7641217bb634b1d50b9c7f7.tar.gz
tex-overlay-42f56cac75be75e6a7641217bb634b1d50b9c7f7.tar.bz2
tex-overlay-42f56cac75be75e6a7641217bb634b1d50b9c7f7.zip
dev-texlive/texlive-humanities: use pkg-config
Signed-off-by: Florian Schmaus <flow@gentoo.org>
-rw-r--r--dev-texlive/texlive-humanities/files/texlive-humanities-2023-opbible-improve-Makefile-respect-user-flags.patch12
-rw-r--r--dev-texlive/texlive-humanities/texlive-humanities-2023_p68465.ebuild7
2 files changed, 14 insertions, 5 deletions
diff --git a/dev-texlive/texlive-humanities/files/texlive-humanities-2023-opbible-improve-Makefile-respect-user-flags.patch b/dev-texlive/texlive-humanities/files/texlive-humanities-2023-opbible-improve-Makefile-respect-user-flags.patch
index 462965d..1cc2754 100644
--- a/dev-texlive/texlive-humanities/files/texlive-humanities-2023-opbible-improve-Makefile-respect-user-flags.patch
+++ b/dev-texlive/texlive-humanities/files/texlive-humanities-2023-opbible-improve-Makefile-respect-user-flags.patch
@@ -1,4 +1,4 @@
-From 34552399a8de874344ae095cd5533232449ccc0a Mon Sep 17 00:00:00 2001
+From 2352b7c243be8b816511ff45377da26f7228fa72 Mon Sep 17 00:00:00 2001
From: Florian Schmaus <flo@geekplace.eu>
Date: Wed, 28 Feb 2024 20:03:49 +0100
Subject: [PATCH] opbible: improve Makefile, respect user's CXX, C(P|XX)FLAGS,
@@ -13,8 +13,10 @@ The Makefile not respecting user variables was initially report by
Gentoo's CI and the following two downstream bugs:
- https://bugs.gentoo.org/925710
- https://bugs.gentoo.org/925711
---- a/texmf-dist/doc/luatex/opbible/txs-gen/Makefile
-+++ b/texmf-dist/doc/luatex/opbible/txs-gen/Makefile
+
+Also use pkg-config to determine sword's flags and libraries.
+--- a/txs-gen/Makefile
++++ b/txs-gen/Makefile
@@ -5,35 +5,19 @@
## definitions
@@ -24,11 +26,11 @@ Gentoo's CI and the following two downstream bugs:
-LIBS = -lsword
-LDFLAGS = $(LIBS)
-CXXFLAGS = -I/usr/include/sword
-+LDLIBS = -lsword
++LDLIBS = $(shell pkg-config --libs sword)
-target = mod2tex
-objects = mod2tex.o
-+CXXFLAGS += -I/usr/include/sword
++CXXFLAGS += $(shell pkg-config --cflags sword)
## static rules
diff --git a/dev-texlive/texlive-humanities/texlive-humanities-2023_p68465.ebuild b/dev-texlive/texlive-humanities/texlive-humanities-2023_p68465.ebuild
index 34caf32..065f60b 100644
--- a/dev-texlive/texlive-humanities/texlive-humanities-2023_p68465.ebuild
+++ b/dev-texlive/texlive-humanities/texlive-humanities-2023_p68465.ebuild
@@ -164,6 +164,9 @@ RDEPEND="
DEPEND="
${COMMON_DEPEND}
"
+BDEPEND="
+ doc? ( virtual/pkgconfig )
+"
TEXLIVE_MODULE_BINSCRIPTS="
texmf-dist/scripts/diadia/diadia.lua
@@ -173,10 +176,14 @@ src_prepare() {
default
if use doc; then
+ pushd texmf-dist/doc/luatex/opbible &> /dev/null || die
+
# https://github.com/olsak/OpBible/pull/1
eapply "${FILESDIR}"/${PN}-2023-opbible-improve-Makefile-respect-user-flags.patch
# Remove the binary, so that it is rebuild.
rm texmf-dist/doc/luatex/opbible/txs-gen/mod2tex || die
+
+ popd &> /dev/null || die
fi
}