[Buildroot] iproute2 failing for x86_64 with ext. toolchain

Gustavo Zacarias gustavo at zacarias.com.ar
Thu Dec 9 17:33:25 UTC 2010


On 12/09/10 14:28, Pkun wrote:

> 2010/12/9 Heiko Zuerker <heiko at zuerker.org <mailto:heiko at zuerker.org>>
> 
>     Quoting Gustavo Zacarias <gustavo at zacarias.com.ar
>     <mailto:gustavo at zacarias.com.ar>>:
> 
>         On 12/07/10 19:21, Heiko Zuerker wrote:
> 
>             Hey,
> 
>             the iproute2 compile fails with:
>             -------------------
>             /data/devil-linux/../x-tools/x86_64-unknown-linux-gnu/bin/x86_64-unknown-linux-gnu-gcc
>             --sysroot=/data/devil-linux/output/staging
>             -Wl,-export-dynamic  ip.o
>             ipaddress.o ipaddrlabel.o iproute.o iprule.o rtm_map.o
>             iptunnel.o
>             ip6tunnel.o tunnel.o ipneigh.o ipntable.o iplink.o ipmaddr.o
>             ipmonitor.o
>             ipmroute.o ipprefix.o iptuntap.o ipxfrm.o xfrm_state.o
>             xfrm_policy.o
>             xfrm_monitor.o iplink_vlan.o link_veth.o link_gre.o iplink_can.o
>             iplink_macvlan.o ../lib/libnetlink.a ../lib/libutil.a
>              -lresolv -L../lib
>             -lnetlink -lutil -ldl -o ip
>             ../lib/libnetlink.a: could not read symbols: Archive has no
>             index; run
>             ranlib to add one
>             collect2: ld returned 1 exit status
>             ------------------------
> 
> 
>         Can you upload a full build log of the relevant (iproute2) part
>         somewhere?
>         Thanks.
> 
> 
>     It's on pastebin: http://pastebin.com/hRhJKpkN
> 
> 
>     -- 
> 
>     Regards
>      Heiko Zuerker
>      http://www.devil-linux.org
> 
>  
> I think that 'ar' is used from the host but not your
> x86_64-unknown-linux-gnu-ar. It can be uncompatible I suppose.

Yes, that's the problem, even if they were similar it shouldn't be used.
Try changing...
$(MAKE) CC="$(TARGET_CC)" -C $(@D)
to
$(MAKE) CC="$(TARGET_CC)" AR="$(TARGET_AR)" -C $(@D)
in package/iproute/iproute2.mk

Regards.




More information about the buildroot mailing list