This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Compiling Cygwin on Linux

Robert Eckhoff wrote:

> /*rant
> I've been trying to boot strap a cygwin/gcc system for essentially 3 
> weeks now.  I am _frustrated_.  I have copied files around, linked 
> directories from gcc into cygwin, linked directories from cygwin into 
> gcc.  I have copied include files from various places into other various 
> places.  I have flat out removed lines of code that seem to be keeping 
> cygwin from building.
> */rant

Is this supposed to make us want to help you more?  You're doing
something bizarre and silly and as a consequence you're finding it
difficult.  I can assure you that many of us cross compile Cygwin on
Linux regularly without having to worry about any of this -- in fact
there's a fair chance that every Cygwin DLL on every mirror for the last
decade or so has been crosscompiled, because it's so much faster, and it
just plain works.  The difference is that nobody tries to bootstrap from
scratch, you first create a working toolchain using existing sysroot
files, then you use that to rebuild Cygwin.

> config.log says that  i686-pc-cygwin-gcc is complaining that crt0.o is
> not available.  A compiled cygwin is supposed to have crt0.o.  Therefore
> shouldn't require crt0.o to compile.  This is a chicken and the egg
> problem.  What are the right commands to pass to the cygwin source tree
> (configure/make) to compile and install crt0.o, and all other startup
> files?  As an aside, with all my attempts, newlib seems to always
> compile fine, it is winsup that has issues.

I don't understand why you assume that this should work.  You need a
working compiler that can link executables in order to run the configure
tests.  In order to link executables you need startup objects, which are
part of Cygwin.  So, yes, chicken and egg.  But Cygwin is quite old and
stable, there is no scarcity of binary packages, and there are virtually
no adjustable knobs or config variables to tune (unlike, say, linux
embedded systems), so the need to bootstrap from nothing is essentially
nonexistant unless you just like being pedantic or are feeling
masochistic.  Certainly we don't support it.  For $deity's sake just use
a sysroot; the Cygwin binary package conveniently provides everything
necessary in one simple wget-able tarball that unpacks to the perfect
directory structure.  There's even a step by step tutorial on the
website.  If you want to feel like you built everything yourself you can
delete it after the first time and repopulate it with the copy you just

You can probably get around the link tests by supplying the cached
answers (ac_cv_*) when invoking configure.  This assumes you know the
correct answers beforehand, as from a previous run.


Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]