wx/wxprec.h: No such file or directory

Do you have a question about makefiles, a compiler or IDE you are using and need to know how to set it up for wxWidgets or why it doesn't compile but other IDE's do ? Post your questions here.
Post Reply
furries
Experienced Solver
Experienced Solver
Posts: 53
Joined: Wed Jun 29, 2005 3:45 pm

wx/wxprec.h: No such file or directory

Post by furries »

Hello,

I'm using Eclipse to develop on WindowsXP (using MinGW and Msys).

I used Msys to compile wxWidgets and that all worked ok...
../configure --with-msw --enable-debug --enable-debug_gdb --disable-shared <-- this is what I typed and it all worked fine :-)

Then I did "make" and that all worked fine and the minimal sample worked fine too! :-)

Now I load into Eclipse, (which I have already tested the hello world app and that worked). I add "#include wx/wxprec.h" to the top of my code and try a simple wxMessageDialog(etc...). I try to compile and get

"wx/wxprec.h: No such file or directory"

What have I forgotten to do? I'm sure it simple but I've not managed to find it.

Any other info on getting wxWidgets working in Eclipse would be most helpful. I'm trying to compile a sample to run on Pocket PC (wince) and PalmOS but so far I can only get the wince version working in eVC4 and I can only get PalmOS working in the PalmOS developer suite (eclipse).

Thanks for all you help,

Jon
User avatar
Ryan Norton
wxWorld Domination!
wxWorld Domination!
Posts: 1319
Joined: Mon Aug 30, 2004 6:01 pm

Re: wx/wxprec.h: No such file or directory

Post by Ryan Norton »

furries wrote: What have I forgotten to do? I'm sure it simple but I've not managed to find it.
Add the wxwidgets include directory to your project's include path, also add the correct lib directory to link too also
[Mostly retired moderator, still check in to clean up some stuff]
furries
Experienced Solver
Experienced Solver
Posts: 53
Joined: Wed Jun 29, 2005 3:45 pm

Post by furries »

Thanks for the swift reply.
That solved that one nicely but now I'm getting:

:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\mingw32\bin\ld.exe: cannot find -lC:\eclipse\wxWidgetsEclipse\include\wx\msw\wince\setup.h
collect2: ld returned 1 exit status
make: *** [HelloWorld.exe] Error 1

I bet this is similarly easy to solve just by adding a directory somewhere.

Thanks again.
Post Reply