This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Fw: CrossCompiling
- From: René Berber <r dot berber at computer dot org>
- To: cygwin at cygwin dot com
- Date: Mon, 19 Dec 2005 19:43:27 -0600
- Subject: Re: Fw: CrossCompiling
- Openpgp: url=ldap://keyserver.pgp.com
- References: <005501c604ff$1e68e400$6301a8c0@eliteprodigy3>
Jay C. wrote:
[snip]
> On compiling, it throws the following error.
>
> /opt/crosstool/gcc-3.4.1-glibc-2.3.2/i686-unknown-linux-gnu/lib/gcc/i686-unknown-linux-gnu/3.4.1/../../../../i686-unknown-linux-gnu/bin/ld:
> cannot find -lgcc_s
Just what it says: the linker cannot find library libgcc_s.a (or libgcc_s.so if
using shared libraries).
In general your compiler can tell you where are the libraries it is using:
$ gcc -print-libgcc-file-name
/usr/lib/gcc/i686-pc-cygwin/3.4.4/libgcc.a
$ gcc -print-file-name=libgcc.a
/usr/lib/gcc/i686-pc-cygwin/3.4.4/libgcc.a
$ gcc -print-file-name=libgcc_s.a
libgcc_s.a
The 3rd test did not find libgcc_s.a and the compiler doesn't show a path but in
a way is saying "I'll use it if I find it right here in this directory".
> I have glib, glib2, glib-devel, glib2-devel and any other glib packages
> I could find installed for Cygwin.
If you are cross-compiling those will not work, you need the target libraries
(notice the difference between my libgcc and the one your linker was looking
for: .../i686-pc-cygwin/... vs .../i686-unknown-linux/...).
In other words, your setup is not complete for doing the cross-compilation you
are trying to do.
HTH
--
René Berber
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/