Subject: Re: cross compiling of bash for 8xx

From: Marcus Sundberg <[email-masked]>
Date: 20 May 2000 22:04:56 +0200

"RAJESH.B.V" <[email-masked]> writes:

> Hi All,
> I'm a newbie entered into this Linux world and working on mbx860...
> i'm able to build the kernel and succeeded in running it.
> But when i try to compile the applications like Bash and all i'm getting
> some problem with shared libraries.
> i'm using the compiler  powerpc-linux-gcc with version 2.95.2 and glibc
> with version 1.99
> if i compile with static libraries it is fine.
> When compiling   Bash-2.03 when i try to configure with the command
> " CC=powerpc-linux-gcc ./configure --target=860 " it is giving error when
> it is searching to configure for  "getpgrep".
> so the configure is exiting..

--target is wrong here.

--build is the environment you are compiling on.
--host is the environment the program(s) will run on.
--target is afaik only applicable for binutils, gcc and gdb, and
specifies the system to generate code for (debug in the case of gdb).

> And when i compile the ping application it is compiling well and when i try
> to run it on my mbx860 board it is displaying an error that
> "shared library libc.s0.6 is not found. failed to open libc.so.6"
> but actually that lib file is there in the /lib path.
>
> can any one suggest me the solutions for the above..
> Is there any site providing  the minimal root file system Disk Image with
> libc-6 to download.

The ping problem sounds like either a broken development environment
and/or a broken runtime environment, hard to tell what the problem
is there. strace and LD_DEBUG=help are your friends.

As for cross compiling bash and other autoconf using applications
I've been using a handy little wrapper script for configure. It's
attached to this mail.

//Marcus

--
-------------------------------+-----------------------------------
        Marcus Sundberg        |       Phone: +46 707 452062
  Embedded Systems Consultant  |      Email: [email-masked]
       Cendio Systems AB       |       http://www.cendio.com