For some reason, when I try to compile the default program that comes with the wxWidgets template for Dev-C++, I get a bunch of errors: click
Here's the code for the default program that comes up when the wxWidgets template is selected: http://rafb.net/p/Y9jycW49.html
I was following the DevPak setup instructions from here.
Yes, I remembered to add the appropriate directories for the "Includes" and "Libraries":
Library: C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\lib
Includes: C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\include
C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\lib\wx\include\msw-ansi-release-static-2.8\
Just like it says in the commented instructions from the default program:
One thing to note though that in the DevPak setup instructions is that where it says:
There's one mistake in the templates, easy to fix. Note: this has now been fixed in the latest DevPak for wxWidgets (2003-05-16).
* Open dev-cpp\Templates\WxWindows.template in a text editor (notepad) and go to the [Project] section.
* Copy the line Compiler=--pipe -D...etc and paste just below.
* Change pasted line to CppCompiler=--pipe -D.... etc and save the file.
I could find WxWindows.template, but I did find WxWidgets.template. I Also couldn't find the line mentioned in the instructions, but I did find:
CppCompiler=-D__WXMSW__ -DNO_GCC_PRAGMA -fno-rtti -fno-exceptions
And I didn't do anything to that line.
BTW, here's the link for the wxWidgets DevPak I downloaded: http://www.andre-simon.de/zip/download.html#devpak
And here's the link for the imagelib DevPak I downloaded: http://old.devpaks.org/show.php?devpak=105
Afterwards, I found another place to download the wxWidgets DevPak - http://bloodshed.net/dev/packages/wxwindows.html . Maybe I should have downloaded from there?
Also, here's a screenshot of Dev-C++'s Package Manager, in case that helps: http://img258.imageshack.us/img258/2577/devcppbad2ux6.png
Here's the code for the default program that comes up when the wxWidgets template is selected: http://rafb.net/p/Y9jycW49.html
I was following the DevPak setup instructions from here.
Yes, I remembered to add the appropriate directories for the "Includes" and "Libraries":
Library: C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\lib
Includes: C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\include
C:\Dev-Cpp\wxWidgets-2.8.0-msw-static\lib\wx\include\msw-ansi-release-static-2.8\
Just like it says in the commented instructions from the default program:
Quote:
BEFORE YOU HIT COMPILE:
You have to add some include paths to your environment before
compiling the project:
1. Open "Project-> Project Options-> Directories"
2. In the Libraries section, add
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\lib"
3. In the C++-Includes section, add
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\include"
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\lib\wx\include\msw-ansi-release-static-2.8"
4. Make sure you use mingw32-make to compile your projects.
<Dev-Cpp-Root> is your Dev-Cpp installation directory (like E:\Dev-Cpp).
EDIT: It seems to generate these same errors no matter what program I use, as long as it has #include "wx/wx.h" in its code.
You have to add some include paths to your environment before
compiling the project:
1. Open "Project-> Project Options-> Directories"
2. In the Libraries section, add
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\lib"
3. In the C++-Includes section, add
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\include"
"<Dev-Cpp-Root>\wxWidgets-2.8.x-msw-static\lib\wx\include\msw-ansi-release-static-2.8"
4. Make sure you use mingw32-make to compile your projects.
<Dev-Cpp-Root> is your Dev-Cpp installation directory (like E:\Dev-Cpp).
One thing to note though that in the DevPak setup instructions is that where it says:
Quote:
There's one mistake in the templates, easy to fix. Note: this has now been fixed in the latest DevPak for wxWidgets (2003-05-16).
* Open dev-cpp\Templates\WxWindows.template in a text editor (notepad) and go to the [Project] section.
* Copy the line Compiler=--pipe -D...etc and paste just below.
* Change pasted line to CppCompiler=--pipe -D.... etc and save the file.
I could find WxWindows.template, but I did find WxWidgets.template. I Also couldn't find the line mentioned in the instructions, but I did find:
CppCompiler=-D__WXMSW__ -DNO_GCC_PRAGMA -fno-rtti -fno-exceptions
And I didn't do anything to that line.
BTW, here's the link for the wxWidgets DevPak I downloaded: http://www.andre-simon.de/zip/download.html#devpak
And here's the link for the imagelib DevPak I downloaded: http://old.devpaks.org/show.php?devpak=105
Afterwards, I found another place to download the wxWidgets DevPak - http://bloodshed.net/dev/packages/wxwindows.html . Maybe I should have downloaded from there?
Also, here's a screenshot of Dev-C++'s Package Manager, in case that helps: http://img258.imageshack.us/img258/2577/devcppbad2ux6.png