From e9772efbd1ad76708935b977a705c13bfd31d09c Mon Sep 17 00:00:00 2001 From: Shinwoo Kim Date: Tue, 15 Dec 2020 16:21:18 +0900 Subject: [PATCH] wasm: work with log option The wasm is using the ThorVG output starting whith "SVG:" to show unsupported element and attribute of svg file. This patch updates wasm_build.sh to make ThorVG prints log, and removes build errors. - Following commit needs to include 'algorithm' 1ed6113 common sw_engine: code refactoring & stabilizing. - Following commit needs to include 'string' 5481633 svg_loader XmlParser: Print unsupported elements, ... --- src/lib/sw_engine/tvgSwImage.cpp | 4 ++-- src/loaders/svg/tvgXmlParser.cpp | 2 +- wasm_build.sh | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib/sw_engine/tvgSwImage.cpp b/src/lib/sw_engine/tvgSwImage.cpp index 2968cb16..342a28a5 100644 --- a/src/lib/sw_engine/tvgSwImage.cpp +++ b/src/lib/sw_engine/tvgSwImage.cpp @@ -19,7 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ -#include +#include #include "tvgSwCommon.h" /************************************************************************/ @@ -172,4 +172,4 @@ bool imageGenOutline(SwImage* image, const Picture* pdata, unsigned tid, const M void imageFree(SwImage* image) { rleFree(image->rle); -} \ No newline at end of file +} diff --git a/src/loaders/svg/tvgXmlParser.cpp b/src/loaders/svg/tvgXmlParser.cpp index 9c384974..1da937e6 100644 --- a/src/loaders/svg/tvgXmlParser.cpp +++ b/src/loaders/svg/tvgXmlParser.cpp @@ -21,7 +21,7 @@ */ #include -#include +#include #ifdef _WIN32 #include #else diff --git a/wasm_build.sh b/wasm_build.sh index ae819605..ccd659e4 100755 --- a/wasm_build.sh +++ b/wasm_build.sh @@ -8,7 +8,7 @@ fi if [ ! -d "./builddir_wasm" ]; then sed "s|EMSDK:|$1|g" wasm_cross.txt > /tmp/.wasm_cross.txt - meson -Dbindings=[''] -Db_lto=true -Ddefault_library=static --cross-file /tmp/.wasm_cross.txt builddir_wasm + meson -Dbindings=[''] -Db_lto=true -Ddefault_library=static -Dlog=true --cross-file /tmp/.wasm_cross.txt builddir_wasm cp ./test/wasm_test.html builddir_wasm/src/index.html fi