[OE-core] [PATCH] iputils: Fix postinst to run on cross rootfs generation

Saul Wold sgw at linux.intel.com
Thu Aug 23 03:42:40 UTC 2012


On 08/22/2012 06:31 PM, Khem Raj wrote:
> rpm shows error messages like /bin/traceroute6 not found
> when building cross rootfs
>
> Yocto # 2894
>
> Signed-off-by: Khem Raj <raj.khem at gmail.com>
> ---
>   meta/recipes-extended/iputils/iputils_s20101006.bb |    6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/meta/recipes-extended/iputils/iputils_s20101006.bb b/meta/recipes-extended/iputils/iputils_s20101006.bb
> index 62e2b5e..856bde4 100644
> --- a/meta/recipes-extended/iputils/iputils_s20101006.bb
> +++ b/meta/recipes-extended/iputils/iputils_s20101006.bb
> @@ -59,15 +59,15 @@ ALTERNATIVE_${PN}-ping6 = "ping6"
>   ALTERNATIVE_LINK_NAME[ping6] = "${base_bindir}/ping6"
>
>   pkg_postinst_${PN}-ping () {
> -       chmod 4555 ${base_bindir}/ping
> +       chmod 4555 $D${base_bindir}/ping
So that's the magic!  I was trying to figure out what the right prefix 
was in there.  I think we need to do an audit of all pkg_postinst, 
because I saw other places where ${xxx} was used or even worse "/etc/..."

Sau!

>   }
>
>   pkg_postinst_${PN}-ping6 () {
> -       chmod 4555 ${base_bindir}/ping6
> +       chmod 4555 $D${base_bindir}/ping6
>   }
>
>   pkg_postinst_${PN}-traceroute6 () {
> -	chmod 4555 ${base_bindir}/traceroute6
> +	chmod 4555 $D${base_bindir}/traceroute6
>   }
>
>   PACKAGES += "${PN}-ping ${PN}-ping6 ${PN}-arping ${PN}-tracepath ${PN}-tracepath6 ${PN}-traceroute6"
>




More information about the Openembedded-core mailing list