Skip to contentSkip to conversation

attr: use u-a for setfattr

PATCH New Martin Jansa 1 participant 1 message Sep 10, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 attr: use u-a for setfattr

setfattr is now provided also by busybox since 1.29.2 upgrade and do_rootfs is failing with:
update-alternatives: Error: not linking usr/bin/setfattr to /bin/busybox.nosuid since usr/bin/setfattr exists and is not a link

---
 meta/recipes-support/attr/attr.inc | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
meta/recipes-support/attr/attr.inc +5 -1
index 24ef5adfd3..9fc0f33cce 100644
@@ -23,7 +23,11 @@ do_install_append() {
 	    s,^libdir=\'${base_libdir}\'$,libdir=\'${libdir}\',
 }
 
-inherit ptest
+inherit ptest update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "setfattr"
+ALTERNATIVE_TARGET[setfattr] = "${bindir}/setfattr"
 
 do_install_ptest() {
 	tar -c --exclude=ext test/ | ( cd ${D}${PTEST_PATH} && tar -xf - )
Signature · 1 line
2.17.1