From d9daa00faed1c89b34351ad3db33520977d277f0 Mon Sep 17 00:00:00 2001 From: skjnldsv Date: Thu, 21 May 2026 11:24:58 +0200 Subject: [PATCH] fix: replace sed -i with perl -pi for macOS compatibility macOS BSD sed requires a backup extension with -i (e.g. sed -i ''), while GNU sed does not accept an empty extension. The merge-folders target used sed -i -e which fails on macOS with: sed: 1: "": invalid command code . Replace with perl -pi -e which is portable across both platforms. Fixes #13186 Signed-off-by: skjnldsv --- user_manual/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/user_manual/Makefile b/user_manual/Makefile index 240d4c7d19d..c2972d79178 100644 --- a/user_manual/Makefile +++ b/user_manual/Makefile @@ -68,8 +68,8 @@ merge-folders: cd $(BUILDDIR)/html/ && rm -rf `find -type d -name _images` mv ./_static $(BUILDDIR)/html/ mv ./_images $(BUILDDIR)/html/ - cd $(BUILDDIR)/html/ && find ./ -type f -exec sed -i -e 's/_images/..\/_images/g' {} \; - cd $(BUILDDIR)/html/ && find ./ -type f -exec sed -i -e 's/_static/..\/_static/g' {} \; + cd $(BUILDDIR)/html/ && find ./ -type f -exec perl -pi -e 's|_images|../_images|g' {} \; + cd $(BUILDDIR)/html/ && find ./ -type f -exec perl -pi -e 's|_static|../_static|g' {} \; dirhtml: $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml