Difference between revisions of "Compiling wxWidgets 2.4.2 to develop Code::Blocks (MSW)"

From Code::Blocks
Line 50: Line 50:
 
== Build wxWidgets ==
 
== Build wxWidgets ==
  
Under construction.
+
NOTE: We're assumming you installed under C:\wxWindows-2.4.2 .
 +
Before anything, let me warn you: wxWidgets compilation is SLOW. And by SLOW I mean the time equivalent to one or two evolution cycles, like from Triasic to Jurasic, but doubled. So make sure there's a nice show on the TV, or you could invite a friend to play cards. OR you could start preparing the coffee :)
  
 +
Now, open up your MSYS prompt, and change to the wxWidgets src/msw directory:
 +
 +
: <tt>'''cd /c/wxWindows-2.4.2/src/msw'''</tt>
 +
 +
And proceed to the build:
 +
 +
: <tt>'''mingw32-make -f makefile.g95 FINAL=1 UNICODE=0 WXMAKINGDLL=1'''</tt>
 +
 +
If no "mingw32-make" is found, try this:
 +
 +
: <tt>'''make -f makefile.g95 FINAL=1 UNICODE=0 WXMAKINGDLL=1'''</tt>
 +
 +
Now it's time to enjoy your coffee :-)
  
 
== Build the STC library ==
 
== Build the STC library ==

Revision as of 04:49, 25 May 2005

These are the instructions to Install and compile wxWidgets 2.4.2 so you can later compile Code::Blocks on your own.

NOTE: The instructions are MS Windows (TM) specific, but some could be applied to other platforms as well

NOTE: This article is under construction. More info can be found in the forums.

Install MinGW

If you don't have the Code::Blocks+MinGW bundle, grab the latest MINGW stuff (including MSYS) from the MINGW site and install it under a directory you like. In this tutorial we're assumming you're installing MINGW under C:\MINGW.

If you DO have the Code::Blocks + MinGW bundle, or have already installed MINGW on your own, you can skip this section.

NOTE: The files are compressed in the tar.gz format. You need a third-party extraction utility to unzip them.

The files I (Rick) have installed are:

After you install, make sure you have the following directories under your path:

  • C:\MINGW\bin;
  • C:\MINGW\mingw32\bin;

(I'm assumming you installed under C:\MINGW)

Set up MSYS

The MSYS package (NOT included in the Code::Blocks+MinGW bundle) allows you to run unix scripts with Mingw. Think of it as a "mini-linux emulator". When you run the executable installer, it will provide a link to msys.bat. If it doesn't appear in your desktop, search for it in your programs menu.

The wxWidgets 2.4.2 compilation must be run from inside MSYS. Drive C is found under /c/, drive D under /d/ and so on.

Download and Install the wxWidgets source code

The wxWidgets 2.4.2 distribution can be found at the wxWidgets site. (Note that there's also a winhelp file available). You can choose to install either the setup version or the plain zip version (which I find ridiculous, because the setup version is zipped too!).

If you use the plain zip version, make sure to unzip using the full path. Otherwise the directories won't be created correctly. On a second thought, you might like to use the setup version :P

I have my wxWidgets installed in C:\wxWindows-2.4.2 . Under MSYS, that should be /c/wxWindows-2.4.2 .

And now that you have all the ingredients, it's time to compile :)

Build wxWidgets

NOTE: We're assumming you installed under C:\wxWindows-2.4.2 . Before anything, let me warn you: wxWidgets compilation is SLOW. And by SLOW I mean the time equivalent to one or two evolution cycles, like from Triasic to Jurasic, but doubled. So make sure there's a nice show on the TV, or you could invite a friend to play cards. OR you could start preparing the coffee :)

Now, open up your MSYS prompt, and change to the wxWidgets src/msw directory:

cd /c/wxWindows-2.4.2/src/msw

And proceed to the build:

mingw32-make -f makefile.g95 FINAL=1 UNICODE=0 WXMAKINGDLL=1

If no "mingw32-make" is found, try this:

make -f makefile.g95 FINAL=1 UNICODE=0 WXMAKINGDLL=1

Now it's time to enjoy your coffee :-)

Build the STC library

Under construction.


Build the XRC library

Under construction.


Copy the files to your mingw directory or set up the paths

Under construction.