Building the Dependencies - Windows & Microsoft Visual Studio

This tutorial is aimed for users wishing to compile Delta3D's depdencies using Microsoft Visual Studio. It was written with MVSC++ 7.1, but it should be edited to included special remarks for 8.0 as well.

*** Note: the following external dependency information hasn't been updated for awhile. Its left here for historical purposes. Click here for updated information.***

The Dependencies' Dependencies

Some of these libaries have a few dependencies of their own. I will address these as we get to them. That being said, you at least need a toolset to compile source code.

On Windows this usually means the Microsoft Visual Studio IDE (or even their Microsoft Visual C++ Toolkit). Ocassionally MinGW/MSYS or Cygwin will be supported as well, but those paths will not be convered in this tutorial (however, feel free to submit directions and they will be posted! ;).


It is assumed you have basic proficiency in Visual Studio and know where to find common options.

It is assumed you have downloaded the pacakges already and unzipped them somewhere. You can find download site and version numbers over here. All directories for each depedency will simply be referenced as their folder name. It is assumed that you unzipped them to your favorite directory and can navigate there easily.

At several points you may need to add directories to Visual Studio's search paths for include files and library files. These can be set per-project in the project settings dialogs or globally:

  1. Choose the Tools menu
  2. Select Options
  3. Click the Projects folder
  4. Choose VC++ Directories
  5. In the combo box labeled Show directories for: select either Include files or Library files
  6. Click on the new folder icon
  7. Add your directory

The packages are listed alphabetically, but be careful, there are some inter-dependencies. Under the header for each package will be a note about its depedenices including links to other sections of this page.

Oh and note that I will use the following terms interchangeably:

  • MSVC++ 7.0: MSVC++ 2002
  • MSVC++ 7.1: MSVC++ 2003
  • MSVC++ 8.0: MSVC++ 2005

OK, let's go!


Latest Recommended Version: 2.4.2

This package is very easy to install. Just head over to their download page and grab an installer.

There is one catch: the Python installer neglects to setup the correct environment variables. Boost.Python and Delta3D keys off these so it's best to set them now.

  • PYTHON_ROOT, which points to the root of your Python installation (usually C:\Python24).
  • PYTHON_VERSION, which contains the major and minor numbers of the Python version (e.g. 2.4)
  • PYTHON_INCLUDES, the path to Python headers (usually %PYTHON_ROOT%\include).
  • PYTHON_LIB_PATH, the path to Python libraries (usually %PYTHON_ROOT%\libs). Eventually %DELTA_ROOT%\bin should be added to this variable as well.


Latest Recommended Version: 1.33.1
Dependencies: bjam, Python

Boost is a set of stable, rigorously tested, and highly confusing libraries. Most are written to exploit the bastard offspring of C++ called template metaprogramming. Delta3D currently has two uses for Boost. First, the GameNetworkingEngine (GNE) library uses Boost's shared_ptr and weak_ptr templates for reference counting. These templates are not specialized until GNE uses the headers, so there is no need to actually compile Boost just for GNE. The second reason for using Boost with Delta3D is Boost.Python. This library allows our C++ API to be reflected into Python. Boost.Python needs to be compiled against the Python/C API

There are a couple of gotchas concerning building Boost correctly on Windows. Let me highly recommend to use bjam from the command line instead of VisualStudio directly. Boost 1.33 and onward introduced a new naming convention for their libraries. That's all well and good, but the VisualStudio project for Boost.Python fail to conform to this convention. Even more confusing, a selective compile of Boost.Python by bjam also screws up the output filenames. Only a full build as outlined below produced the correct filenames.

  1. Make sure bjam can be accessed from boost_1_33_1
  2. Open a cmd terminal (click Start, Run..., type cmd).
  3. Navigate to boost_1_33_1.
  4. Type bjam stage. This will build all the libraries to the directory boost_1_33_1\stage. Without any options it will likely guess your correct platform, but if it does not you can use a compile option. For example, use bjam -sTOOLS=vc-8_0 for VS2005. For more information see Boost's Getting Started guide.
  5. Finally add the proper search paths to Visual Studio. Use boost_1_33_1 for include files and boost_1_33_1\stage\lib for library files.


Latest Recommended Version: 0.10.0

The only special note about CAL3D is that run-time type information (RTTI) is turned off by default. While this would normally be a good thing, Delta3D needs to use dynamic_cast a fair amount, so make sure to enable RTTI.

  1. Open cal3d-0.10.0\cal3d.dsw
  2. Change Enable Run-Time Type Info to Yes for both Debug and Release configuations of the project Cal3D
  3. Build the Debug and Release configurations of the project Cal3D


Latest Recommended Version: 1.10.2

Just open cppunit-1.10.2\src\CppUnitLibraries.sln and build.


Latest Recommended Version: 1.1.7

Open one of their many solutions...

  • MSVC++ 6.0: fltk-1.1.7\visualc\fltk.sln
  • MSVC++ 7.1: fltk-1.1.7\vcnet\fltk.sln
  • MSVC++ 8.0: fltk-1.1.7\vc2005\fltk.sln
  • ...

FLTK will build as a static library by default. If you would like a shared library instead make sure to change the settings for the fltk project. Otherwise, build and enjoy.


Latest Recommended Version: 1.3.1

This library has a ton of optional dependencies. None of them are necessary for Delta3D. Rather than duplicating a tutorial, I will refer you to GDAL's official tutorial on how to build from source. However, you may want to change the default configuration from Debug to Optimized. Open up the file gdal-1.3.1\nmake.opt and around line 22 you'll find:

    #OPTFLAGS=	/nologo /MD /GX /Ox
    OPTFLAGS=	/nologo /MD /GX /Zi /Fd$(GDAL_ROOT)\gdal.pdb
Change them to:
    OPTFLAGS=	/nologo /MD /GX /Ox
    #OPTFLAGS=	/nologo /MD /GX /Zi /Fd$(GDAL_ROOT)\gdal.pdb
Delta3D links both Debug and Release configuration to the optimizied output library gdal_i.lib.

InterSense Interface Libraries SDK

Latest Recommended Version: 3.83

This depedency supports the dtCore::Tracker class, which is design to interface with InterSense tracking devices. The InterSense SDK has two pruposes: it provides runtime driver support as well as the actual development SDK. The Windows binary shipped with the SDK does not provide the library isense.lib that Delta3D needs to build against.

To build the InterSense SDK library:

  1. Create a new VC++ project for a DLL
  2. Add the files isense.h and isense.c
  3. Build!


Latest Recommended Version: 0.5

ODE's build system (as of 0.5) on Windows is not exactly clean. There are has been much development on the UNSTABLE branch of ODE's CVS repository since the last release, so if you run into problems, I suggest you start by grabbing a newer snapshot off CVS.

That being said, do not use the MSVC++ 7.0 solution in ode-0.5\contrib\msvc7\ode.sln. Personally I cannot get that thing to work. Instead follow these steps to convert the MSVC++ 6.0 .dsw.

  1. Go to the directory ode-0.5\VC6
  2. Run the batch file configure-single-trimesh.bat
  3. The open and convert the file odeDLL.dsw
  4. Build away


Latest Recommended Version: 1.4.2

Open OSG_OP_OT-1.0\OpenThreads\win32_src\OpenThreads.dsw and build.


Latest Recommended Version: 1.0.1
Dependencies: OpenThreads.

Make sure OpenThreads is built in the same OSG_OP_OT-1.0 directrory, and then open the suitable solution and compile.

  • MSVC++ 6.0: OSG_OP_OT-1.0\Producer\VC++6.0\Producer.sln
  • MSVC++ 7.0: OSG_OP_OT-1.0\Producer\VC++7\Producer.sln


Latest Recommended Version: 1.0.0
Dependencies: GDAL, FreeType, libjpeg, libpng, libtiff, libungif, zlib.

The dependencies for OpenSceneGraph are mostly related to plugin support. You can find much more information about its dependencies from their website. There are pre-built binaries for "Win32", but that probably means MSVC++ 7.1. However, I would give them a shot before building any of your own. Big gotcha: GDAL is a requirement for building osgTerrain as well as the GDAL plugin. osgTerrain is not used in Delta3D, but the GDAL plugin is (osgdb_gdal.dll). You can use the version distributed with OSG's 3rdParty Win32 binaries, but be careful! You must build Delta3D again the same version of GDAL that you build OSG against. If you do not then you'll get runtime errors looking for the wrong DLLs. If you use your own version of GDAL then you must be careful to remove the GDAL that OSG distributes with their 3rdParty binaries before building. And of course, if you need to point OSG to an external GDAL then you must add the include and library paths (this is not necessary if you use the 3rdParty binaries).

Make sure OpenThreads and Producer are built in the same OSG_OP_OT-1.0 directrory, then open OSG_OP_OT-1.0\OpenSceneGraph\VisualStudio\OpenSceneGraph.dsw and build.


Latest Recommended Version: 0.0.8 (Specification 1.1)

Using the OpenAL 1.1 SDK from Creative Labs seems to work OK as long as you replace the broken ALUT libraries that it shipes with. Follow the directions for FreeALUT below.


Latest Recommended Version: 1.0.0
Dependencies: OpenAL.

  1. Download FreeALUT Win32 binaries
  2. Find the directory that the SDK was installed to and replace the following files with ones from the freealut binary package: alut.dll, alut.lib,alut.h


Latest Recommended Version: 1.8.4

Open and plib-1.8.4\plib.dsw and build. Delta3D only uses the js and js modules. All PLIB headers are referenced in code like so:

So after you've built the libraries you'll need to put the headers to a directory called plib.


Latest Recommended Version: 2006-01-17
Dependencies: CAL3D, OpenSceneGraph.

Just open replicantbody/VisualStudio/ReplicantBody.sln (they only have MSVC++ 7.x projects) and build. Make sure the headers and library for CAL3D and OpenSceneGraph can be found by ReplicantBody.


Latest Recommended Version: 2.6.0

Xerces-C++ 2.7.0 will work fine with Delta3D, but with that release they introduced a new warning by comparing unsigned and signed intergers without an explicit conversion. Since I don't like seeing miles of warnings, I stick with 2.6.0 for now.

But anyways, navigate to xerces-c-src_2_6_0\Projects\Win32 and select project files from your platform's directory:

  • BCB6: Borland C++Builder6
  • BCC.551: Borland C++ Compiler v5.5.1 (5.6.2 should work as well)
  • CodeWarrior: Metrowerks CodeWarrior
  • VC6: Microsoft Visual Studio 6.0
  • VC7: Microsoft Visual Studio 7.x

Crazy Eddie's GUI System

Latest Recommended Version: 0.4.1
Dependencies: FreeType, Xerces-C++, GLUT (optional for CEGUI demos), DevIL (optional image loader library).

The CEGUI project is very good at providing binaries for various Windows configurations. Currently they support MSVC++ 6.0 (with or without STLPort), MSVC++ 2002 (with or without STLPort), MSVC++ 2003, and MSVC++ 2005. If you wish to install the binaries, you'll need three downloads: the CEGUI SDK, the Core Library Win32 Dependency, and the Xercse-C dependency package (unless you build it on your own as outlined below).

Of course, you can always build from source instead. You can use the depdency binaries mentioned above, or build them from source as well. Once the dependency are setup, navigate to cegui_mk2\makefiles\win32. You will find there three directories of VisualStudio project files:

  • VC++6: Microsoft Visual Studio 6.0
  • VC++7.0: Microsoft Visual Studio 7.0
  • VC++7.1: Microsoft Visual Studio 7.1

Contained within you will find CEGUI.sln (or CEGUI.dsw for VS++6) that will build the entire library. Make sure the CEGUI projects can find the dependencies!

If you want to build from CEGUI's SVN head and use this to build Delta3D's GUI support, then you will need to follow these steps:

  • Build the FreeType library that you will be using to build Delta3D with, which CEGUI also requires.
  • Build the PCRE library for CEGUI, since they stopped doing this for us after the 0.4 release.
    • If you are using windows, this is a little tricky. Digging throught the documentation finally points you to a website that lists user contributions, including instructions for building with Visual Studio. I've found these to be most helpful, with instructions here.
    • It appears the project files you see when unpacking the package mentioned above needs a little help. The preprocessor command 'PCRE_DEFINITION' needs to be defined. This will allow the DLL export symbols to be inserted into the library, and allows CEGUI to link.
  • Install the premake program, and put it into your %PATH%
  • Run the Visual Studio premake scripts found under CEGUI's makefiles/premake folder.
  • Modify the project settings in the CEGUIBase project to find the include and lib paths for the PCRE and FreeType dependencies.

Hawk Networking Library

Latest Recommended Version: 1.68

We recommend building HawkNL as a static library. The Game Networking Engine (build on top of HawkNL) is much more stable as a static library, so it makes since to make HawkNL and dtNET static as well. This one is pretty easy. Just open the file HawkNL1.68\HawkNL.dsw and build the project called HawkNL_static.

Game Networking Engine

Latest Recommended Version: 0.70
Dependencies: HawkNL, Boost.

Note GNE does not support MSVC++ 6.0 (neither does Delta3D, so that shouldn't be an issue :). Open the solution gnelib-0.70\gne.sln. Make sure the HawkNL headers and libraries can be found by the gne project. Also ensure the Boost headers are visible to the gne project. Then, go ahead and build gne.


Latest Recommended Version: 4.0.1

Dependencies: QtWin/Free Patch.

Qt is not technically requireed for Delt3D at the moment, but our flagship application (STAGE) uses it as will all forthcoming official Delta3D utilities, so it's a good idea to get it setup now. However with MSVC++, there's a few hoops you must jump through. The problem boils down to this: Trolltech generously decided to release Qt 4 under an open-source license, but unfortunately they only provided makefile support for MinGW. While we love MinGW, there is no support for building the Delta3D libraries with it. So we had to find a way to compile Qt with MSVC++. Luckily the QtWin/Free project did this already!

  1. Grab the appropriate patch from the QtWin/Free site for your compiler.
  2. Extract the QtWin/Free patch inside your Qt directory. Overwrite any files with the ones from the patch.
  3. Follow instructions for the patch with its readme.
  4. After many many hours, it should be all compiled and happy.


Trackback URL for this entry:

No trackback comments for this entry.


There are no upcoming events