Re: [Dev-C++] Problem getting wxWindows-app to compile
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: <cg...@wo...> - 2002-12-08 17:05:28
|
You must define __GNUWIN32__ (two underscores each), perhaps UNICODE or _UNICODE, depending on you are using it or not. The best for compile wxwindows was saidtwo months ago, make a makefile with CFLAGS= INC= LIB= TARGET= OBJS= $(TARGET) : $(OBJS) !include makeprog.g95. Jonatan wrote: >Hello! > >I'm currently looking into the wxWindows-framework. >Using the latest 4.9.7.0 IDE, I get 394 errors upon compiling a very simple program. >This is how my simple program looks like (taken from a tutorial at http://www.codelearn.com/cpp/icpp_wx1.html): > >main.cpp: >--------- >#include <wx/wx.h> >#include "basic.h" > >IMPLEMENT_APP(BasicApplication) > >bool BasicApplication::OnInit() >{ > BasicFrame > *frame = new BasicFrame("Basic", 50, 50, 450, 300); > > frame->Show(TRUE); > SetTopWindow(frame); > return TRUE; >} > >BasicFrame::BasicFrame > (const wxChar *title, > int xpos, int ypos, > int width, int height) > : wxFrame > ( (wxFrame *) NULL, > -1, > title, > wxPoint(xpos, ypos), > wxSize(width, height) > ) >{ > >} > >BasicFrame::~BasicFrame() >{ > >} > >basic.h >------- >#ifndef BASIC_H >#define BASIC_H > >class BasicApplication : public wxApp >{ > public: > virtual bool OnInit(); >}; > >class BasicFrame : public wxFrame >{ > public: > BasicFrame( const wxChar *title, > int xpos, int ypos, > int width, int height); > ~BasicFrame(); > >}; >#endif > >This program is pretty straightforward. >I've added the include paths, so the wx-headers are found. My first error is > >*** 320 C:\DEV-CPP\include\wx\defs.h >redeclaration of C++ built-in type `bool'*** > >I also get errors like: > >*** 6 C:\DEV-CPP\include\wx\wxchar.h:429 >#error "Please define string case-insensitive compare for your OS/compiler" *** > >and > >*** 99 C:\DEV-CPP\include\wx\font.h >virtual outside class declaration *** > >Is there some option(s) I should activate/deactivate in Dev-C++ that I've missed? Should I reinstall wxWindows or does it not work with 4.9.7.0? > >Hopefully you've had the same problems and there is some silly thing I've missed... > >TIA > >//Jonatan > > > >------------------------------------------------------- >This sf.net email is sponsored by:ThinkGeek >Welcome to geek heaven. >http://thinkgeek.com/sf >_______________________________________________ >Dev-cpp-users mailing list >Dev...@li... >TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm >https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > |