[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: windows programming with g++
From: |
Guy Harrison |
Subject: |
Re: windows programming with g++ |
Date: |
Mon, 26 Apr 2004 13:54:10 +0100 |
User-agent: |
KNode/0.7.7 |
cppaddict wrote:
> Hi,
>
> I'm trying to learn Windows programming and I'd like to use g++
> instead of Visual Studio.
>
> I come from a UNIX background, and have written lots of console apps
> using g++. I'm comfortable with using a text editor, makefiles, and a
> command line compiler. Is there any way to write windows programs
> this way?
http://www.mingw.org
http://www/cygwin.com
> I just tried compiling a sample windows programming using g++,
Likely you're using one of the above. More tools in MSYS for mingw. Peruse
setup.exe packages for cygwin.
> but I
> got an error saying it could not find the header file "afxwin.h",
> which I assume is a windows-specific library file that obvioulsy
> wouldn't come with g++.
Headers prefixed with afx are typically Microsoft Foundation Classes. For
sure <afxwin.h> is MFC. It's appearance will pretty much tie you to VC
compiler (same as VCL code ties you to Borland). You may get MFC ideas from
www.winehq.org but seriously consider if cross-platform solution such as
www.wxwindows.org (there are others) would be better use of your time.
> Perhaps there's a way to get all the
> necessary windows library files and put them where g++ can find them?
> Or am I walking down the wrong path?
>
> Any thoughts or advice would be much appreciated.
Avoid MFC ;-)
--
Guy Harrison