Re: Linux build in Windows
From: Robert Heller (heller_at_deepsoft.com)
Date: 09/18/05
- Next message: Robert Heller: "Re: Linux build in Windows"
- Previous message: Madhusudan Singh: "Re: Been a While What Distro do I get?"
- Maybe in reply to: Peter T. Breuer: "Re: Linux build in Windows"
- Next in thread: Robert Heller: "Re: Linux build in Windows"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 18 Sep 2005 17:49:44 +0200
"googler" <pinaki_m77@yahoo.com>,
In a message on 17 Sep 2005 15:10:56 -0700, wrote :
"> I need to compile a program for both Linux and Windows environments.
"> I'm working on a Windows machine and want to perform both these builds
"> on this same computer. How can I perform a compilation for Linux
"> environment in Windows?
">
"> I thought Cygwin is able to perform this task, but after reading from
"> their website, it appeared that it generates the executable for
"> Windows. Is that right? I want the binaries for Linux.
Cygwin is built to build UNIX programs to run *natively* under
MS-Windows (using POSIX libraries), using GNU build tools (gcc/g++ +
binutils + other gnu tools: make, libtool, auto{conf,make,scan}, etc.).
You build gcc and binutils (and maybe some additional libraries) as a
cross-build environment under Cygwin, from the *sources* for gcc and
binutils (and the libraries you need). You are probably NOT going to
find these as pre-built binaries. Just find and download the sources
for gcc (gcc-<mumble>.tar.gz and binutils-<mumble>.tar.gz), unpack them
and study the READMEs. You'll want *hardcopies* of the READMEs --
building the cross-build environment is a non trivial task -- there are
a number of steps in the process. You might need to fetch some bits
and pieces from a real Linux environment as well (libraries and header
files) -- way back when (don't ask) I needed to build a gcc cross
compiler and there were some bits that had to be native built (somehow)
-- some low-level libraries (libgcc.a I think). I don't know if that
is still the case or if it was because the underlying processors were
different (a 680xx compiler for a 68020 SBC with some embeded UNIX-ish
O/S, on a SparcStation runing SunOS 3.x or 4.x). When I (much more
recently) built a Mgwin32-based cross build for MS-Windows on a Linux
box, it included installing a pile of pre-built .dlls/.libs.
It is (of course) easier to build a cross-build environment for
MS-WIndows under Linux, using Mgwin32...
Even easier would be to use a dual boot box or a second (cheap/older) PC
running Linux. The linux box can be headless even -- you can just
slogin in from the Windows box. Cygwin comes with a basic X server
even.
">
"> Thanks in advance.
">
">
\/
Robert Heller ||InterNet: heller@cs.umass.edu
http://vis-www.cs.umass.edu/~heller || heller@deepsoft.com
http://www.deepsoft.com /\FidoNet: 1:321/153
- Next message: Robert Heller: "Re: Linux build in Windows"
- Previous message: Madhusudan Singh: "Re: Been a While What Distro do I get?"
- Maybe in reply to: Peter T. Breuer: "Re: Linux build in Windows"
- Next in thread: Robert Heller: "Re: Linux build in Windows"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|