build: fetch git dependency submodules (libplacebo glad)

This commit is contained in:
david
2026-09-30 16:22:53 +02:00
parent 9fca848d9b
commit 8bc2416da0
+4 -1
View File
@@ -115,9 +115,12 @@ function gettar {
}
# Clone a git dependency at a pinned tag (shallow, tag-checked-out).
# Submodules are fetched shallow too: libplacebo needs its bundled `glad`,
# ffmpeg/dav1d/others carry submodules needed for the build.
function gitpin {
local url=$1 dest=$2 tag=$3
[ -d "$dest" ] || git clone --depth=1 --branch "$tag" "$url" "$dest"
[ -d "$dest" ] || git clone --depth=1 --branch "$tag" \
--recurse-submodules --shallow-submodules "$url" "$dest"
pushd "$dest"
git checkout --quiet "$tag"
popd