[ Home | Docs | News | Resources | Download]
GAUL Documentation: Compilation with MS Visual C++

Instructions for compilation on MS Windows with .NET / Visual C++

This document contains abbreviated instructions for compiling your own GAUL libraries and executables with Microsoft Visual C++ and .NET. They were tested with MS VC++ with .NET 1.x, but they should also work with other similar setups.

Corresponding instructions for the Bloodshed Dev-C++ IDE are provided separately.

Compilation

PART 0: Download and unpack the Windows-specific version of the source code from the download page.

PART I: Create a WinGaul .NET solution as follows:

  1. Select File->New->Blank Solution
  2. Name it "WinGaul"
  3. click OK

PART II: Create gaul-util library.

  1. Create a "gaul-util" project to compile a static library:
    • select the menu "File->New->Project",
    • click the "Win32 Project" icon under Visual C++ Projects,
    • type "gaul-util" in the "Name:" text box,
    • select "Add to Solution"
    • click the "OK" button.
    • select "Application Setting"
      i. select "Static library"
      ii. uncheck "Precompiled header"
    • click the "Finish" button.
  2. Add all C source files from the GAUL subdirectory "util" to the gaul-util project source files.
    • Select File->Save All so that solution directory and subdirectory will be created.
    • copy all the files and subdirectories from the GAUL subdirectory util/ to the gaul-util project folder
    • select gaul-util/Source Files->Add->Add Existing Item and select all the source files
    • select gaul-util/Header Files->Add->Add Existing Item and select all the header files

PART III: Create gaul-devel library.

  1. Create a "gaul-devel" project to compile a static library:
    • select the menu "File->New->Project",
    • click the "Win32 Project" icon under Visual C++ Projects,
    • type "gaul-devel" in the "Name:" text box,
    • Select "Add to Solution"
    • click the "OK" button.
    • select "Application Setting"
      i. select "Static library"
      ii. uncheck "Precompiled header"
    • click the "Finish" button.
  2. Add all C source files from the GAUL subdirectory "src" to the gaul-devel project source files.
    • Select File->Save All so as to create gaul-devel directory
    • copy all the files and subdirectories from the GAUL subdirectory src/ to the gaul-devel project folder
    • select gaul-devel/Source Files->Add->Add Existing Item and select all the source files
    • select gaul-devel/Header Files->Add->Add Existing Item and select all the header files
  3. Add "../gaul-util" to Additional Include directories for gaul-devel project
    • right click on gaul-util project-> Properties->C/C++ and enter ../gaul-util for Additional Include Directories
    • Click OK

PART IV: example programs.

These instructions are for the "struggle" example, but all examples are compiled in a similar way.

  1. Create a "Struggle" project to compile a console application:
    • select the menu "File->New->Project",
    • click the "Win32 Console Application" icon,
    • type "Struggle" in the "Name:" text box,
    • click the "OK" button.
    • click the "Finish" button.
  2. Remove the Struggle.cpp and replace/Add the relevent C source files from the GAUL subdirectory "examples".
    • Delete the Struggle.cpp from the project (right click on Struggle.cpp -> Remove)
    • Copy the relevent C source file from the GAUL subdirectory "examples" to the location of Struggle.cpp
    • select Struggle/Source Files->Add->Add Existing Item and select the source file copied
  3. Struggle->Set As StartUp Project
  4. Set Struggle project not to use precompiled headers:
    • Right click on Stuggle Project->Properties->C/C++->Precompiled Headers and change Create/Use Precompiled Header to "Not Using Precompiled Headers"
  5. Right click on Stuggle Project->Properties->C/C++->General->Additional Include Directories and enter ../gaul-devel; ../gaul-util
  6. Set Project Dependencies:
    • Right Click Solution WinGaul -> Properties->Project Dependences
    • Stuggle depends upon gaul-devel and gaul-util
    • gaul-devel depends upon gaul-util

Compile the .NET solution.

[ Home | Docs | News | Resources | Download]
Hosted by:
SourceForge Logo
GAUL Button Valid HTML 4.01!

© 2005, "Stewart Adcock" <stewart@linux-domain.com> All rights reserved.
All trademarks on this page are probably owned by their respective companies. You can insert you own favourite disclaimer here.