diff --git a/recipes-musicians/lsp-plugins/files/0002-Fix-fonts-for-locales-as-en_US.utf8.patch b/recipes-musicians/lsp-plugins/files/0002-Fix-fonts-for-locales-as-en_US.utf8.patch new file mode 100644 index 0000000..a8b83b2 --- /dev/null +++ b/recipes-musicians/lsp-plugins/files/0002-Fix-fonts-for-locales-as-en_US.utf8.patch @@ -0,0 +1,41 @@ +From 58d45693b42953c6d85d3d1dcf665796bb6db084 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Sat, 27 Apr 2019 23:02:21 +0200 +Subject: [PATCH] Fix fonts for locales as 'en_US.utf8' +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This should fix [1] + +[1] https://github.com/sadko4u/lsp-plugins/issues/17#issuecomment-487228134 + +Signed-off-by: Andreas Müller +--- + src/core/io/charset.cpp | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/src/core/io/charset.cpp b/src/core/io/charset.cpp +index 4ff9c7f9..c044b18d 100644 +--- a/src/core/io/charset.cpp ++++ b/src/core/io/charset.cpp +@@ -517,7 +517,16 @@ namespace lsp + // Get system locale + current = setlocale(LC_CTYPE, ""); + if (current != NULL) ++ { + current = strchr(current, '.'); ++ if (current != NULL) ++ { ++ // For locale e.g 'en_US.utf8' iconv won't understand '.utf8' ++ if((!strcmp(current, ".utf8")) || (!strcmp(current, ".UTF8"))) ++ // UTF-8 is default anyway - see below ++ current = NULL; ++ } ++ } + + // Scan for character set + if (current != NULL) +-- +2.20.1 + diff --git a/recipes-musicians/lsp-plugins/lsp-plugins.bb b/recipes-musicians/lsp-plugins/lsp-plugins.bb index f43ce02..98e5077 100644 --- a/recipes-musicians/lsp-plugins/lsp-plugins.bb +++ b/recipes-musicians/lsp-plugins/lsp-plugins.bb @@ -1,6 +1,6 @@ require ${BPN}.inc -inherit distro_features_check pack_audio_plugins +inherit distro_features_check pack_audio_plugins qemu-ext REQUIRED_DISTRO_FEATURES = "x11" @@ -14,6 +14,7 @@ DEPENDS += " \ libsndfile1 \ ladspa-sdk \ lv2 \ + libglu \ " SRC_URI += " \ @@ -37,15 +38,30 @@ LSP_TARGET_ARCH_aarch64 = "aarch64" LSP_TARGET_ARCH_x86 = "i586" LSP_TARGET_ARCH_x86-64 = "x86_64" +# Uncomment for trace output +#CFLAGS+="-DLSP_TRACE" +#CXXFLAGS+="-DLSP_TRACE" + EXTRA_OEMAKE += " \ BUILD_PLATFORM=Linux \ BUILD_PROFILE=${LSP_TARGET_ARCH} \ PREFIX=${prefix} \ " -do_compile_prepend() { +do_compile() { export CC_ARCH="${CXXFLAGS}" export LD_ARCH="`echo $LDFLAGS | sed 's:-Wl,::g'`" + + # uncomment to build/run unittest + #UNIT_TEST="1" + if [ "${UNIT_TEST}" = "1" ]; then + oe_runmake clean + oe_runmake test + echo "QEMU unittest..." + ${@qemu_run_binary_local(d, '${STAGING_DIR_TARGET}', '.build/lsp-plugins-test')} utest --verbose core.lspstring || echo "ERROR: QEMU unittest failed!" + oe_runmake clean + fi + oe_runmake } do_install() { diff --git a/recipes-musicians/lsp-plugins/lsp-plugins.inc b/recipes-musicians/lsp-plugins/lsp-plugins.inc index 2c22579..41df24b 100644 --- a/recipes-musicians/lsp-plugins/lsp-plugins.inc +++ b/recipes-musicians/lsp-plugins/lsp-plugins.inc @@ -4,8 +4,9 @@ LICENSE = "BSD-3-Clause" LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3000208d539ec061b899bce1d9ce9404" SRC_URI = " \ - git://github.com/sadko4u/lsp-plugins.git \ + gitsm://github.com/sadko4u/lsp-plugins.git \ file://0001-Remove-RPATHs.patch \ + file://0002-Fix-fonts-for-locales-as-en_US.utf8.patch \ " SRCREV = "04cc45a4aee3bd3a46ecbd0a9160d0d87f8f8a32" S = "${WORKDIR}/git"