Difference between revisions of "Nightly Cookbook"

From Code::Blocks
Line 39: Line 39:
 
The nighly builds are unicode versions, containing the core and contributed plug-ins.
 
The nighly builds are unicode versions, containing the core and contributed plug-ins.
 
Just unpack the 7-zip file to any directory you like (eg : C:\CodeBlocksTempNightly).
 
Just unpack the 7-zip file to any directory you like (eg : C:\CodeBlocksTempNightly).
Go ahead, start up that Code:Blocks, it should discover the MingW compiler we installed just before.
+
Go ahead, start up that Code::Blocks, it should discover the MingW compiler we installed just before.
 
+
Well, one more thing. Code::Blocks needs one more dll to work correclty, th wx widgets dll, you can also download it at the nightly builds forum. Just unzip it in the same directory as where you unpacked the Code::Blocks nightly build. To be really honest, it also needs the mingwm10.dll, but don't worry, we already have it : it's in the bin directory of our MingW installation. So make sure the bin directory of your MingW installation is in the path.
  
 
TO BE CONTINUED
 
TO BE CONTINUED

Revision as of 12:31, 14 February 2006

This page is under construction by 'killerbot'. Just be patient, some day it will be finished.

Introduction

This article will describe the process used in creating the nightly builds, and can be used as a guideline if you want to build Code::Blocks yourself. It is described as a sequence of 'manual' actions, it is surely possible to script automate several of these tasks. But that's beyond the scope of the original article. Current limitation : Windows unicode build.


Shopping List

In order to perform our build tasks, we will need several tools. Let's create an ingredient list for our cooking experiments :

  • a compiler
  • an initial build system
  • the Code::Blocks sources
  • zip program
  • svn (version control system)
  • wxWidgets

While we are at it, maybe someday we want to debug our programs, so let's add a debugger to the list :

  • debugger

Shopping Time

Compiler

Let's start by shopping for our first item on the list, a compiler. Several compilers are available, some free, some expensive. Since Code::Blocks is being build by the developers with GCC, we might as well use that one. It is very standard conformant, though not the fastest one around. GCC on windows is available in several flavors, there are CygWin ports, MingW ports. The most easiest and cleanest port is MingW, once again this is what Code::Blocks distributes itself, when you download the official package (the one including the compiler). We can find MingW at www.mingw.org. This other post in the wiki describes what you need. Here we also stick to the 3.4.4 version, which works nicely. Though let's put a very small explanation :

  • gcc-core : the core of the GCC suite
  • gcc-g++ : the c++ compiler
  • mingw Runtime : implementation of the run time libraries
  • mingw utils : several utilities (implementation of smaller programs that GCC uses itself)
  • win32Api : if you want to create Windows programs, here's the headers/API.
  • binutils : several utilities used in build environments
  • make : the Gnu make program, so you can build from make files
  • GDB : the Gnu debugger : for hunting those nasty bugs

I would also suggest to extract (and install for the GDB) everything in C:\MingW, the remainder of this article will assume this is where you have put it. In case you already had an installation of Code::Blocks (for example RC2) and you installed the version coming with MingW, I still would like to advice you to install MingW as described here. A compiler does not belong under the directory tree of an IDE, it are 2 seperate things. Code::Blocks just brings it along in the official versions, so the average user does not need to bother, but since you are reading this, you are no longer an average user. :-)

Initial Build System

We could try to build Code::Blocks by using makefiles, but we can do this way nicer : let's build Code::Blocks by using ........ Code::Blocks. So no chicken and egg problem. All we need to do, is get hold of a pre-build Code::Blocks. Well, just download a nightly build, make your selection from [/index.php?board=20.0 here]. The nighly builds are unicode versions, containing the core and contributed plug-ins. Just unpack the 7-zip file to any directory you like (eg : C:\CodeBlocksTempNightly). Go ahead, start up that Code::Blocks, it should discover the MingW compiler we installed just before. Well, one more thing. Code::Blocks needs one more dll to work correclty, th wx widgets dll, you can also download it at the nightly builds forum. Just unzip it in the same directory as where you unpacked the Code::Blocks nightly build. To be really honest, it also needs the mingwm10.dll, but don't worry, we already have it : it's in the bin directory of our MingW installation. So make sure the bin directory of your MingW installation is in the path.

TO BE CONTINUED