User Tools

Site Tools


A Win32 console programm

Start the Pelles C ide first.

Use 'File' –> 'New' –> 'Project' to start the 'New Project' dialog.

  1. Select 'Console application wizard' to get a little help.
  2. Select your working directory under 'Location'.
  3. Give your project a 'Name', say 'test'.
  4. Click 'ok' to use these settings.

A subfolder 'test' is created by the wizard in your working directory. There is also a file named 'main.c' which will compile to 'test.exe'. Last but not least there is a project file created with the name 'test.ppj'.

'main.c' includes the following source code:

#include <stdio.h>
int main(int argc, char *argv[])
    printf("Hello, world!\n");
    return 0;

Now you can change some project settings. Select 'Project' –> 'Project Options':

  • In the 'Compiler' tab, 'Optimizations' change 'Maximize speed' to 'None'. The Pelles C optimizer has some errors. This is not helpfull to beginners. So we don't use them.
  • To use the debugger to step through your code, select 'Debug information' –> 'Full' in the 'Compiler' tab and 'Debug information' –> 'CodeView COFF format' in the 'Linker' tab.
  • Click 'ok' to leave the 'Project Options' dialog.

Now you can use 'Project' –> 'Build' (or 'Rebuild') to compile your project.

Then it is possible to use 'Project' –> 'Execute' to run 'test.exe' or to use 'Project' –> 'Debug' to start the debugger.

That's it!

command.txt · Last modified: 2015/01/06 18:41 by czerny