From 775817648f00275eb2f63be163e617de4eeefd99 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sat, 14 May 2022 22:06:57 +0200 Subject: gnu: emacs: Don't error on missing commands. This is a follow-up to commit 64557bc695f074af3fcf1eeed8f6696921ef18c5. Inputs lacking from emacs proper may not be present in emacs-minimal, thus throwing an error on lookup. This error is already anticipated in the handling code. * gnu/packages/emacs.scm (emacs)[patch-program-file-names]: Wrap search-input-file in false-if-exception. --- gnu/packages/emacs.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 255c8ee864..441c810ff4 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -148,9 +148,10 @@ (format #f "~s" (search-input-file inputs "/bin/sh")))) (substitute* "lisp/doc-view.el" (("\"(gs|dvipdf|ps2pdf|pdftotext)\"" all what) - (let ((replacement (search-input-file - inputs - (string-append "/bin/" what)))) + (let ((replacement (false-if-exception + (search-input-file + inputs + (string-append "/bin/" what))))) (if replacement (string-append "\"" replacement "\"") all)))) -- cgit v1.2.3