0

I want to cross compile the C code from Linux Ubuntu PC to Beagle Bone Black using "arm-cortexa8-linux-gnueabihf-gcc compiler.

But I face following error:

root@ubuntu:/home/teqlinux/HMI_SCADA/GenLogic/glg_bb/glg/examples_c_cpp/misc/Blinking# make -f makefile 
( /home/teqlinux/Phytec_Wega/ToolChain/arm-cortexa8-linux-gnueabihf/gcc-4.7.3-glibc-2.16.0-binutils-2.22-kernel-3.6-sanitized/bin/arm-cortexa8-linux-gnueabihf-gcc -L/home/teqlinux/HMI_SCADA/GenLogic/glg_bb/glg/lib  -L. -o GlgBlinkingExampleG GlgBlinkingExampleG.o  \
    -lglg_int -lglg -lglg_map_stub  \
    -lXm -lXt -lX11  \
                -lXft -lfontconfig -lfreetype -lz -ljpeg -lpng \
                 -lm -ldl -lpthread \
    || ( rm GlgBlinkingExampleG ; exit 1 ) )
/home/teqlinux/Phytec_Wega/ToolChain/arm-cortexa8-linux-gnueabihf/gcc-4.7.3-glibc-2.16.0-binutils-2.22-kernel-3.6-sanitized/bin/arm-cortexa8-linux-gnueabihf-gcc: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
rm: cannot remove 'GlgBlinkingExampleG': No such file or directory
makefile:127: recipe for target 'GlgBlinkingExampleG' failed
make: *** [GlgBlinkingExampleG] Error 1
  • How did you install the armhf compiler / toolchain? it looks like the installation is incomplete or misconfigured (i.e. the armhf version of libc is missing or the linker doesn't know its location) – steeldriver Dec 28 '18 at 15:17
  • hi @steeldriver I am download from Phytec site. – Milav Soni Dec 31 '18 at 10:25
  • Hello @steeldriver I execute following command .. # ldd arm-cortexa8-linux-gnueabihf-ld and the answer is linux-gate.so.1 => (0xf7f42000) libdl.so.2 => /lib32/libdl.so.2 (0xf7f1f000) /lib/ld-linux.so.2 (0xf7f44000) libc.so.6 => not found libc.so.6 => not found what should i do for libc.so.6? – Milav Soni Dec 31 '18 at 11:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.