From cfcb0000a924dcd8be26a7445fe678f496d5ffd7 Mon Sep 17 00:00:00 2001 From: zdohnal Date: Sun, 19 Feb 2023 12:49:38 +0100 Subject: [PATCH] configure.ac: Add configure option for musicxml file support (#6) musicxml file support requires lou_translate and Freedots programs, where the latter is not available on some distributions. This configuration option will adjust MIME convs and types in case a maintainer can't ship non-functional filter when Freedots program is missing. --- Makefile.am | 6 +++++- configure.ac | 20 +++++++++++++++++++- mime/{braille.convs => braille.convs.in} | 2 +- mime/{braille.types => braille.types.in} | 2 +- 4 files changed, 26 insertions(+), 4 deletions(-) rename mime/{braille.convs => braille.convs.in} (98%) rename mime/{braille.types => braille.types.in} (96%) diff --git a/Makefile.am b/Makefile.am index d20df5185..11a8454e6 100644 --- a/Makefile.am +++ b/Makefile.am @@ -147,6 +147,10 @@ endif # ====================== genfilterscripts = pkgfilter_SCRIPTS = $(genfilterscripts) +if ENABLE_MUSICXML +musicxmlscripts = filter/musicxmltobrf +endif + if ENABLE_BRAILLE nodist_pkgfilter_SCRIPTS = \ driver/generic/brftoembosser \ @@ -158,7 +162,7 @@ nodist_pkgfilter_SCRIPTS = \ filter/vectortobrf \ filter/texttobrf \ filter/brftopagedbrf \ - filter/musicxmltobrf + $(musicxmlscripts) endif distclean-local: diff --git a/configure.ac b/configure.ac index b1dd110a9..cf73a070c 100644 --- a/configure.ac +++ b/configure.ac @@ -188,6 +188,21 @@ PKG_CHECK_EXISTS([liblouis], [ AM_CONDITIONAL(ENABLE_BRAILLE, test "x$enable_braille" = xyes) AC_SUBST(TABLESDIR) +# ================ +# musicxml support +# ================ +AC_ARG_ENABLE(musicxml, AS_HELP_STRING([--enable-musicxml],[enable musicxml file support, requires Freedots and lou_translate]), + enable_musicxml=$enableval,enable_musicxml=no) +if test "x$enable_musicxml" = "xyes" +then + MUSICXML_CONV="application/vnd.recordare.musicxml+xml application/vnd.cups-brf 30 musicxmltobrf" + MUSICXML_TYPE="application/vnd.recordare.musicxml+xml xml contains(0,1000,\"