This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: GCC/Linux to produce exe files for Windows
- From: Enrico Migliore <enrico dot migliore at fatti dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Wed, 15 Feb 2006 14:00:06 +0100
- Subject: Re: GCC/Linux to produce exe files for Windows
- Reply-to: enrico dot migliore at fatti dot com
> I would like to compile a C program on GCC/Linux, and would like
> GCC to produce an executable file for Windows (no Cygwin). Is that
> possible?
Sure, you will just need to build a mingw cross compiler. You will need
to install headers and import libraries from mingw.org and then build
binutils and gcc as a cross compiler. Some distros (e.g. Debian) have
binary packages pre-built.
Brian
Hi Brian,
thanks for your prompt answer.
Actually, I got a Linux application and would like to build it
for Windows. The application is pure C and makes use of quite
a few libraries that Windows doesn't have, like popt and so on.
I already built the application with Cygwin but when I ran it,
within Cygwin, I got a segmentation fault signal, which DDD says,
it is issued by a pthread function.
That's why I'm trying to see if GCC can build direclty the .exe format,
from within Linux.
Enrico