summaryrefslogtreecommitdiffstats
path: root/thirdparty/thorvg/update-thorvg.sh
diff options
context:
space:
mode:
Diffstat (limited to 'thirdparty/thorvg/update-thorvg.sh')
-rwxr-xr-xthirdparty/thorvg/update-thorvg.sh31
1 files changed, 22 insertions, 9 deletions
diff --git a/thirdparty/thorvg/update-thorvg.sh b/thirdparty/thorvg/update-thorvg.sh
index 804d3b76db..c36c6e9eaa 100755
--- a/thirdparty/thorvg/update-thorvg.sh
+++ b/thirdparty/thorvg/update-thorvg.sh
@@ -1,14 +1,25 @@
#!/bin/bash -e
-VERSION=0.10.7
+VERSION=0.11.0
+cd thirdparty/thorvg/ || true
rm -rf AUTHORS LICENSE inc/ src/ *.zip *.tar.gz tmp/
mkdir tmp/ && pushd tmp/
+# Release
curl -L -O https://github.com/thorvg/thorvg/archive/v$VERSION.tar.gz
+# Current Github main branch tip
+#curl -L -O https://github.com/thorvg/thorvg/archive/refs/heads/main.tar.gz
+
tar --strip-components=1 -xvf *.tar.gz
rm *.tar.gz
+
+# Install from local git checkout "thorvg-git" in the same directory
+# as godot git checkout.
+#d="../../../../thorvg-git"
+#cp -r ${d}/AUTHORS ${d}/inc ${d}/LICENSE ${d}/src .
+
find . -type f -name 'meson.build' -delete
# Fix newline at end of file.
@@ -24,24 +35,26 @@ cat << EOF > ../inc/config.h
#define THORVG_CONFIG_H
#define THORVG_SW_RASTER_SUPPORT
-
#define THORVG_SVG_LOADER_SUPPORT
+// For internal debugging:
+//#define THORVG_LOG_ENABLED
+
#define THORVG_VERSION_STRING "$VERSION"
#endif
EOF
mkdir ../src
-cp -rv src/lib src/utils ../src/
+cp -rv src/common ../src
+cp -rv src/renderer ../src/
+
# Only sw_engine is enabled.
-rm -rfv ../src/lib/gl_engine
+rm -rfv ../src/renderer/gl_engine
-# Only svg loader is enabled.
+# Only svg (+raw) loader is enabled.
mkdir ../src/loaders
cp -rv src/loaders/svg src/loaders/raw ../src/loaders/
-# Future versions
-# cp -rv src/utils ../src
-
popd
-rm -rf tmp/
+rm -rf tmp
+