AnsweredAssumed Answered

cannot find crt1.o

Question asked by Kirill Brilliantov on May 23, 2016
Latest reply on May 24, 2016 by Kirill Brilliantov

Hello!

I build toolchain for iMX6 from GitHub - Freescale/fsl-community-bsp-platform: BSP platform manifest

Follow my steps:

- mkdir /yocto && cd /yocto

- repo init -u https://github.com/Freescale/fsl-community-bsp-platform -b jethro && repo sync

- ./setup-environment /yocto/build

- cd /yocto/build

- bitbake meta-toolchain

- cd tmp/deploy/sdk && ./poky-glibc-x86_64-meta-toolchain-cortexa9hf-vfp-neon-toolchain-2.0.1.sh -y

Tollchain install in /opt/poky/2.0.1, after this I export variables from /opt/poky/2.0.1/environment-setup-cortexa9hf-vfp-neon-poky-linux-gnueabi, file attached.

Now I try compile iperf3:

- cd iperf3

- CC=$(CROSS_COMPILE)gcc ./configure --prefix=/usr --host=arm-poky-linux-gnueabi

Unfortunately configuration failed, follow part configure.log file:

configure:3253: arm-poky-linux-gnueabi-gcc -qversion >&5

arm-poky-linux-gnueabi-gcc: error: unrecognized command line option '-qversion'

arm-poky-linux-gnueabi-gcc: fatal error: no input files

compilation terminated.

configure:3264: $? = 1

configure:3284: checking whether the C compiler works

configure:3306: arm-poky-linux-gnueabi-gcc  -O2 -pipe -g -feliminate-unused-debu

g-types  -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c  >&5

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find crt1.o: No such file or d

irectory

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find crti.o: No such file or d

irectory

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find crtbegin.o: No such file

or directory

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find -lgcc

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find -lgcc_s

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find -lc

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find -lgcc

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find -lgcc_s

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find crtend.o: No such file or

directory

/opt/poky/2.0.1/sysroots/x86_64-pokysdk-linux/usr/libexec/arm-poky-linux-gnueabi

/gcc/arm-poky-linux-gnueabi/5.2.0/real-ld: cannot find crtn.o: No such file or d

irectory

collect2: error: ld returned 1 exit status

I check file system and found crt1.o:

$ find /opt/poky/2.0.1 -name crt1.o

/opt/poky/2.0.1/sysroots/cortexa9hf-vfp-neon-poky-linux-gnueabi/usr/lib/crt1.o

Why ld can't found crt1.o and how can I solve this problem?

Thank you and excuse my bad english.

Original Attachment has been moved to: environment-setup-cortexa9hf-vfp-neon-poky-linux-gnueabi.zip

Outcomes