List Info

Thread: Re: running a simple Hello World




Re: running a simple Hello World
country flaguser name
United States
2008-05-18 19:49:00

--- In ts-7000%40yahoogroups.com">ts-7000yahoogroups.com, Anssi Kolehmainen <anssi...> wrote:
&gt;
> On Sun, May 18, 2008 at 10:11:51PM +0100, Martin Guy wrote:
&gt; > On 5/18/08, research_labs80 <[1]sgtdano...> wrote:
&gt; > > then i made a simple hello.cc and i builded it with the
crosstool, so
> > > i get an hello executable.
> > >
>; > > ./hello: error while loading shared libraries: libstdc3;+.so.6:
cannot
> > > open shared object file: Noy
> > >
>; > > of course! the libstc+;+.so.6 is in my crosstool but not in my debian
&gt; > > nfs, which has the libstc+;+.so.3.
> >
> > A candidate for "most frequently asked question&quot;
> >
> > The answer is usually either to link staticallt ("-static")
> ... which generates huge executable.
>
> > or copy the missing libraries from your crosscompiling environment to
> > the target board (and run "ldconfig")
> ... which might mess things up since you would be mixing core library
> versions.
>
> So either use toolchain (~crosstool) with correct kernel+;libc versions
> or upgrade the OS on the board.
&gt;
> --
> Anssi Kolehmainen
> anssi.kolehmainen...
>; 040-5085390
>

yes i think to copy the missing files, by hand, on the nfs. but i have
already the gcc libs on different version. besides, the /lib on the
crosstool is up to 60 Mb so copying on the NFS will augment too much
the disk usage (i still hope to copy all the needed in a 256 MB CF

so, the way i like to solve this is using the same version of
libraries in the crosstool and the debian nfs.

i mention that i use the debian woody, which has the libstc+;+.so.3. i
discover that the debian-sarge-1.12 has libstc+;+.so.5, which is closer
to the .6 that i need.

the good thing is that crosstool-linux-gcc-3.3-glibc-2.2.5 has the
libstc++.so.5! so i think this will match with the debian libs...

... but... i have another type of problem with sarge 1.12:

this message appears every 1 minutes, aprox:

"modprobe: Can't open dependencies file
/lib/modules/2.4.26-vrs1-cirrus-1-2-1-ts8/modules.dep (No such file )

...

INIT: Id "1&quot; respawning too fast: disabled for 5 minutes "

the actual directory on the debian-sarge.1.12 which has the module.dep is:

/lib/modules/2.4.26-ts11

please, note that i'm new on this, but i can reach documentation by
links ;)

so, what can i do?

thanks very much for the previous answer.

__._,_.___
.

__,_._,___
Re: Re: running a simple Hello World
country flaguser name
United States
2008-05-19 07:37:57

On 5/19/08, research_labs80 < sgtdano%40gmail.com">sgtdanogmail.com> wrote:
&gt; i mention that i use the debian woody, which has the libstc+;+.so.3. i
> discover that the debian-sarge-1.12 has libstc+;+.so.5, which is closer
&gt; to the .6 that i need.
&gt;
> the good thing is that crosstool-linux-gcc-3.3-glibc-2.2.5 has the
> libstc+;+.so.5! so i think this will match with the debian libs...

It's not just the file name - for reliable operation you want the same
minor version, since the header files you compiled against may define
things differently from what is appropriate for the libs on the board.
Indeed, there may be subtly different things in the library itself
from version to version, so I suggest you use the exact version of the
shared library on your target board.
I dunno how you would find out the exact minor version from the
lib*.so.X file, but that path is fraught with woe - there are other
issues to do with the ABI: which floating point method is used, which
CPU model it is compiled for, whether functions have thumb
interworking enabled and so on.
The *.so.5 - *.so.6 filename changes happen at majorly incompatible
system-wide ABI changes, such as happened between gcc-3.3 and gcc-3.4

> this message appears every 1 minutes, aprox:
&gt;
> "modprobe: Can't open dependencies file
>; /lib/modules/2.4.26-vrs1-cirrus-1-2-1-ts8/modules.dep (No such file )

It's trying to load kernel modules, probably to drive some device.
There needs to be /lib/modules/2.4.26-vrs1-cirrus-1-2-1-ts8 directory
into the same place on your target board - you should be able to find
this on whatever system your kernel came from.

> INIT: Id "1&quot; respawning too fast: disabled for 5 minutes "
Looks like some terminal driver. An alternative is to comment out the
&quot;1:" line in /etc/inittab and "kill -1 1"

> the actual directory on the debian-sarge.1.12 which has the module.dep is:
>
> /lib/modules/2.4.26-ts11
It needs to match the version of the kernel that is running,
obtainable from "uname -r"

> thanks very much for the previous answer.
You're welcome. Good luck!

M

__._,_.___
.

__,_._,___
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )