I'm tinkering with setting up a Windows development environment and looking for suggestions. I'm primarily a Linux guy so been looking at Cygwin which I used years ago and liked, and see there is also MinGW.
Anyone use either of these and mind a pro/con of either? I use C primarily and C++ only for interfacing with Nalimov egtb code.
Had also thought about trying Visual Studio Free edition, but I'm so engrained with using bash + gcc + vi + make that the last time I tried any VS I had a hard time figuring out how to do a simple non GUI C application and all the build options, added files into my code base and such.
-Josh
Windows GCC Development
Moderators: hgm, Rebel, chrisw
-
- Posts: 1342
- Joined: Wed Mar 08, 2006 9:41 pm
- Location: Morgantown, WV, USA
-
- Posts: 319
- Joined: Fri Dec 18, 2009 11:40 am
- Location: Naperville, IL
Re: Windows GCC Development
MinGW is nice for building native Windows executables. If that's your main goal, you can actually set it up as a cross-compiler on Linux (the easiest method depends on your distro) and build with, say, CC=i686-pc-mingw32-gcc CXX=i686-pc-mingw32-g++.
-
- Posts: 4675
- Joined: Mon Mar 13, 2006 7:43 pm
Re: Windows GCC Development
Due to MS bungling the underlying Win32 support, the Cygwin implementation of the select() library routine is a horrorshow underneath and should be avoided. Also with Cygwin, don't expect any support for Unix specific calls which reference user IDs, special file types, timers, some thread functions, etc.
-
- Posts: 27790
- Joined: Fri Mar 10, 2006 10:06 am
- Location: Amsterdam
- Full name: H G Muller
Re: Windows GCC Development
I always use gcc+cygwin for making the binaries of WinBoard and Polyglot that go into the WinBoard releases. That has never given me any problems.
There is one peculiarity in printing (long long int): the printf in the mcrts DLL that will eventually be called in a -mno-cygwin compile does interpret the formats in a non-standard way, which leads to spurious warnings on format-argument type mismatch by gcc, which does make the assumption the format means what the standard prescribes.
There is one peculiarity in printing (long long int): the printf in the mcrts DLL that will eventually be called in a -mno-cygwin compile does interpret the formats in a non-standard way, which leads to spurious warnings on format-argument type mismatch by gcc, which does make the assumption the format means what the standard prescribes.
-
- Posts: 3232
- Joined: Mon May 31, 2010 1:29 pm
- Full name: lucasart
Re: Windows GCC Development
isn't it much easier to develop on linux, and compile with gcc for linux and windows with mingw, still on a linux machine ? that's what i do anyway: codelite for an IDE and gcc/mingw to compile for linix/windows.jshriver wrote:I'm tinkering with setting up a Windows development environment and looking for suggestions. I'm primarily a Linux guy so been looking at Cygwin which I used years ago and liked, and see there is also MinGW.
Anyone use either of these and mind a pro/con of either? I use C primarily and C++ only for interfacing with Nalimov egtb code.
Had also thought about trying Visual Studio Free edition, but I'm so engrained with using bash + gcc + vi + make that the last time I tried any VS I had a hard time figuring out how to do a simple non GUI C application and all the build options, added files into my code base and such.
-Josh
-
- Posts: 4366
- Joined: Fri Mar 10, 2006 5:23 am
- Location: http://www.arasanchess.org
Re: Windows GCC Development
I have used cygwin but it's not my primary dev environment on Windows.
You can get the Windows SDK from Microsoft as a free download. (http://en.wikipedia.org/wiki/Microsoft_Windows_SDK). This is basically the command-line version of the Visual Studio compiler. It contains all the header files needed for native Windows app development. Note though this compiler lacks a few features such as PGO and does not include a profiler.
Microsoft NMAKE is not even remotely close to Gnu Make, and a lot less powerful. I have had to maintain two Makefiles, one for GCC or ICC, and one for Microsoft builds using Visual C++.
You can get the Windows SDK from Microsoft as a free download. (http://en.wikipedia.org/wiki/Microsoft_Windows_SDK). This is basically the command-line version of the Visual Studio compiler. It contains all the header files needed for native Windows app development. Note though this compiler lacks a few features such as PGO and does not include a profiler.
Microsoft NMAKE is not even remotely close to Gnu Make, and a lot less powerful. I have had to maintain two Makefiles, one for GCC or ICC, and one for Microsoft builds using Visual C++.
-
- Posts: 153
- Joined: Fri Sep 30, 2011 7:48 am
Re: Windows GCC Development
I usually prefer an IDE with a debugger, that is the primary reason why I develop mostly in visual studio. I used mingw a lot a few years ago and mainly concentrated on getting things to compile in the terminal, I found most of the projects I downloaded would work on both linux and windows with a bit of makefile hacking. Mingw seemed to run most of my programs very fast, perhaps some extra safety checking in MSVC was to blame. CodeBlock's is a good IDE that supports mingw if you want to use a debugger.
-
- Posts: 1383
- Joined: Fri Jul 14, 2006 7:56 am
- Location: London, England
- Full name: Jim Ablett
Re: Windows GCC Development
You can find the very latest official versions & 'bleeding edge' binaries of GCC for Windows here >
http://www.equation.com/servlet/equation.cmd?fa=fortran
Jim.
http://www.equation.com/servlet/equation.cmd?fa=fortran
Jim.
-
- Posts: 5106
- Joined: Tue Apr 29, 2008 4:27 pm
Re: Windows GCC Development
I make my komodo windows binaries from linux using mingw. Very easy and convenient and very portable. So there is no need to soil your hands or compromise your integrity or be seen using Windows if you do not have to do so.jshriver wrote:I'm tinkering with setting up a Windows development environment and looking for suggestions. I'm primarily a Linux guy so been looking at Cygwin which I used years ago and liked, and see there is also MinGW.
Anyone use either of these and mind a pro/con of either? I use C primarily and C++ only for interfacing with Nalimov egtb code.
Had also thought about trying Visual Studio Free edition, but I'm so engrained with using bash + gcc + vi + make that the last time I tried any VS I had a hard time figuring out how to do a simple non GUI C application and all the build options, added files into my code base and such.
-Josh
-
- Posts: 3232
- Joined: Mon May 31, 2010 1:29 pm
- Full name: lucasart
Re: Windows GCC Development
me too, and i cannot agree more with your comments about WindowsDon wrote:I make my komodo windows binaries from linux using mingw. Very easy and convenient and very portable. So there is no need to soil your hands or compromise your integrity or be seen using Windows if you do not have to do so.jshriver wrote:I'm tinkering with setting up a Windows development environment and looking for suggestions. I'm primarily a Linux guy so been looking at Cygwin which I used years ago and liked, and see there is also MinGW.
Anyone use either of these and mind a pro/con of either? I use C primarily and C++ only for interfacing with Nalimov egtb code.
Had also thought about trying Visual Studio Free edition, but I'm so engrained with using bash + gcc + vi + make that the last time I tried any VS I had a hard time figuring out how to do a simple non GUI C application and all the build options, added files into my code base and such.
-Josh