From 7f8b6520c6386e66a610d61767a98bf8a0a8bfbf Mon Sep 17 00:00:00 2001 From: Arnaud Ferraris Date: Tue, 6 Oct 2020 17:34:32 +0200 Subject: [PATCH] postprocess: allow using dcraw_emu from Debian As `dcraw_emu` is an example program, Debian doesn't install it to `/usr/bin`, but to `/usr/lib/libraw` instead, meaning it can't be found the usual way. This patch checks for `/usr/lib/libraw/dcraw_emu` if `command` can't find it. Additionnally, cascaded if's are replaced with if..elif statements, so we stop searching as soon as a matching program (preferably `dcraw_emu`) is found. --- postprocess.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/postprocess.sh b/postprocess.sh index 06b00c7..a589758 100755 --- a/postprocess.sh +++ b/postprocess.sh @@ -40,8 +40,11 @@ then DCRAW=dcraw_emu # -fbdd 1 Raw denoising with FBDD set -- -fbdd 1 -fi -if command -v "dcraw" > /dev/null +elif [ -x "/usr/lib/libraw/dcraw_emu" ]; then + DCRAW=/usr/lib/libraw/dcraw_emu + # -fbdd 1 Raw denoising with FBDD + set -- -fbdd 1 +elif command -v "dcraw" > /dev/null then DCRAW=dcraw TIFF_EXT="tiff"