[Clfs-support] Linking issue

Lance Chou LChou at PLXTech.com
Fri Jul 17 21:51:42 PDT 2009


I have attached libiconv.la and the output of executing the command you asked me to do.
To help debug this issue, I check my environment again.
Environment 1: (Follow Current Embedded Development 1.x)
  Platform: ARM
  Execution Format: eabi
  FPU: soft-float (I append --with-float=soft while building binutils and gcc)
  C Library: uClibc
Environment 2: (Follow Current Sysroot Development 1.x)
  Platform: ARM
  Execution Format: eabi
  FPU : soft-float (I append --with-float=soft while building binutils and gcc)
  C Library: glibc

I found when I build httpd-2.2.9 on the uClibc environment, I got the error messages as shown as my previous e-mail. I google on the Internet and somebody says I can modify the Makefile and append "-shared" to the gcc when linking to solve this issue. After modifying the Makefile, I can build httpd successfully. But I got segmentation fault when running it.

When I build httpd-2.2.9 on the glibc environment, the build completes. But when I run it, I got "unexpected reloc type 0x03".

If I build httpd-2.2.9 with cross-compiler, the httpd could be run normally. So, I guess there must be something wrong with my target compiler.
Anything I can do to help find out the root cause? I have built my target compiler with different parameters again and again, and I don't know what else I can do to figure it out.
Please help. Thanks


-----Original Message-----
From: clfs-support-bounces at lists.cross-lfs.org [mailto:clfs-support-bounces at lists.cross-lfs.org] On Behalf Of Joe Ciccone
Sent: Friday, July 17, 2009 8:25 PM
To: CLFS Support
Subject: Re: [Clfs-support] Linking issue

Lance Chou wrote:
>
> Dear All,
>
>  
>
>   I’m building my system by following Current Sysroot Development 1.x.
> My platform is ARM and I have built the cross toolchain successfully.
> I use the toolchain to build everything I need for my system. After
> the system can boot up, I use the toolchain to build a compiler that
> is directly run on my platform. At first, I thought it’s OK because
> when I write some simple program, it can be compiled and run
> successfully. But when I tries to build apache (httpd-2.2.9) directly
> on the board, it fails at linking stage. The error messages are shown
> as following
>
And one last thing,

Could you also provide the output this test prints to the console?

echo "int main() {}" | gcc -x c - -v -Wl,--verbose
_______________________________________________
Clfs-support mailing list
Clfs-support at lists.cross-lfs.org
http://lists.cross-lfs.org/listinfo.cgi/clfs-support-cross-lfs.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: libiconv.la
Type: application/octet-stream
Size: 884 bytes
Desc: libiconv.la
URL: <http://lists.clfs.org/pipermail/clfs-support-clfs.org/attachments/20090717/6bf02912/attachment-0004.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc_verbose
Type: application/octet-stream
Size: 14635 bytes
Desc: gcc_verbose
URL: <http://lists.clfs.org/pipermail/clfs-support-clfs.org/attachments/20090717/6bf02912/attachment-0005.obj>


More information about the Clfs-support mailing list