From c32baae979b9f79d965765a3839e8cf4e9ffff02 Mon Sep 17 00:00:00 2001 From: Thomas Kuehne Date: Dec 11 2021 20:33:18 +0000 Subject: Don't hardcode paths to utilities incorporate patch from Gentoo: (See https://bugs.gentoo.org/828520 too) From: Sam James Date: Wed, 10 Nov 2021 04:53:33 +0000 Subject: [PATCH] Don't hardcode paths to utilities The path to e.g. links at build time is not necessarily the same as the path at runtime. TODO: Could chop out the checks from configure but this package is fragile enough. Leaving it for now. (cherry picked from commit 85cbe37bb85c8234317f6f2b547155cb1af43663) --- diff --git a/xmlto.in b/xmlto.in index aed5458..fbf2254 100755 --- a/xmlto.in +++ b/xmlto.in @@ -272,13 +272,13 @@ then USE_BACKEND=DEFAULT fi -LINKS_PATH=@LINKS@ -W3M_PATH=@W3M@ -LYNX_PATH=@LYNX@ -GCP_PATH=@GCP@ -SED_PATH=@SED@ -GREP_PATH=@GREP@ -ZIP_PATH=@ZIP@ +LINKS_PATH=$(command -v elinks || command -v links) +W3M_PATH=$(command -v w3m) +LYNX_PATH=$(command -v lynx) +GCP_PATH=$(command -v cp) +SED_PATH=$(command -v sed) +GREP_PATH=$(command -v grep) +ZIP_PATH=$(command -v zip) # Process any options ARGS=$(${GETOPT} \