Bug#991060: mlpost FTBFS with imagemagick with the #987504 change
Control: tag -1 patch
The attached patch should fix this.
Regards,
Dennis Filder
Description: Override ImageMagick policy
Derive an appropriate policy from the too strict default one.
Author: Dennis Filder <d.filder@web.de>
Last-Update: 2021-07-16
Bug-Debian: https://bugs.debian.org/991060
--- a/ocamlbuild.Makefile
+++ b/ocamlbuild.Makefile
@@ -44,6 +44,7 @@
EXTDLL = .so
DLL := backend/dllmlpost_ft$(EXTDLL) backend/libmlpost_ft.a
+POLFILE = "/etc/$(shell convert -version|sed -n '/^Version: /s@Version: ImageMagick \([[:digit:]]\+\)\..*@ImageMagick-\1@p')"/policy.xml
ifeq "$(OCAMLBEST)" "opt"
all:
@@ -195,7 +196,10 @@
.PHONY: doc
doc:
rm -f doc
+ test -d $(HOME)/.magick || mkdir -p $(HOME)/.magick
+ sed -e '/<policy domain="coder" rights="none" pattern="PS" .>/s@"none"@"read|write"@' $(POLFILE) > $(HOME)/.magick/policy.xml
$(OCAMLBUILD) doc/index.html
+ rm -Rf $(HOME)/.magick
ln -s _build/doc doc
# clean
Reply to: