Skip to contentSkip to conversation

librav1e: Drop need for a dependency on libgit2

PATCH New Khem Raj 1 participant 1 message Aug 4

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 librav1e: Drop need for a dependency on libgit2

rav1e's default features include git_version, which pulls built/git2 and thus libgit2-sys into build.rs -- a *build-dependency*, so it is probed and linked for the build host. cargo_common exports LIBGIT2_NO_VENDOR, so libgit2-sys probes pkg-config, which points at the target sysroot, and the host link then picks up the target's libm.so linker script. That script names absolute target paths (/usr/lib/libm.so.6), which only resolve on the build host when host and target architectures differ enough for ld to skip the script as incompatible, so this breaks on aarch64 hosts building aarch64 targets. git_version only embeds a git hash in the version string, which is meaningless here, so drop it and keep the rest of the default feature set.

---
 meta-multimedia/recipes-multimedia/rav1e/librav1e_p20250902.bb | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
meta-multimedia/recipes-multimedia/rav1e/librav1e_p20250902.bb +2 -1
index 740918bd18..13f417008b 100644
@@ -7,7 +7,8 @@ inherit cargo_c pkgconfig cargo-update-recipe-crates
 
 require ${PN}-crates.inc
 
-DEPENDS = "libgit2"
+CARGO_BUILD_FLAGS += "--no-default-features --features binaries,asm,threading,signal_support"
+
 DEPENDS:append:x86 = " nasm-native"
 DEPENDS:append:x86-64 = " nasm-native"