[oe] LPC3250, helloworld-image, configure: error: cannot run C compiled programs
Dmitry Vinokurov
d.vinokuroff at gmail.com
Thu Aug 20 18:42:03 UTC 2009
Holger Hans Peter Freyther wrote:
> I think you should explore using the external-toolchain. This way you will
> have to set the PATH to the toolchain and make "external-toolchain" the
> default provider...
>
> And for the old way have you seen this:
> http://docs.openembedded.org/usermanual/html/commonuse_prebuilt_toolchain.html?
>
> z.
Yes, I've seen manual and seems like I did everything that was told
there. By the way I meant that I want to use exactly external toolchain.
I used LTIB building system earlier and wanted to use toolchain from there.
> On Thursday 20 August 2009 15:01:59 Dmitry Vinokurov wrote:
>
>
>> By the way, I don't understand why bitbake build gcc-cross-initial when
>> I use external toolchain. Maybe I've configured something wrong and OE
>> tries to build it's own toolchain, but seems like config is correct
>> according to manual.
>>
>
> To figure out why OE is building the toolchain you can do
>
> bitbake -g helloworld
>
> and then look at the generated depends.dot. Looking at slugos.inc you will
> need to set more ASSUMED_PROVIDED or go the external-toolchain route (which
> sadly has not much documentation...)
>
> z.
>
I've tested it (removed tmp dir and built from scratch): 'bitbake
helloworld' doesn't try to build toolchain, looks like it use toolchain
that I pointed. At least at the build log (I used -D) I can see
'CC=/opt/nxp/gcc-4.3.2-glibc-2.7/arm-vfp-linux-gnu/../bin/arm-vfp-linux-gnu-gcc',
build commands with this compiler and similar. Configure scripts found
toolchain too. But the way how toolchain is used is really strange,
strings like following are in many packages (binutils-cross-2.18-r8.1,
gcc-cross-initial-4.2.4-r7.1 and maybe some other, that I haven't seen):
--------
checking for i686-linux-ar... ar
checking for i686-linux-strip...
/opt/nxp/gcc-4.3.2-glibc-2.7/arm-vfp-linux-gnu/../bin/arm-vfp-linux-gnu-strip
checking for i686-linux-ranlib... ranlib
--------
or
--------
checking for i686-linux-gcc...
/opt/nxp/gcc-4.3.2-glibc-2.7/arm-vfp-linux-gnu/../bin/arm-vfp-linux-gnu-gcc
--------
I.e. some utils are X86-native, other are cross. In the first example
above configure use ARM strip, though I've got strip on my Debian system.
This mess lead to error, that I described in first letter of this chain:
--------
checking for i686-linux-gcc...
/opt/nxp/gcc-4.3.2-glibc-2.7/arm-vfp-linux-gnu/../bin/arm-vfp-linux-gnu-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... configure: error: cannot run C
compiled programs.
--------
--
Best Regards,
Dmitry Vinokurov
<d.vinokuroff at gmail.com>
More information about the Openembedded-devel
mailing list