Building OpenSG 1.x using Visual Studio 2003/2005 and scons
Supported compilers are Visual Studio 2003 and 2005.
The image libs (jpeg, png, tiff) are automatically unzipped into OpenSG/../supportlibs and linked into
- Install python from http://www.python.org/ (the windows installer is fine)
Install scons from http://www.scons.org/ (the windows installer is fine)
- Add the python install directory (e.g. C:\Python24) to the PATH environment variable. (You can do this locally in the command-shell if you don't want to change your global settings.)
Visual Studio 2003
Open a cmd shell and go into the OpenSG directory and type ".\scons compiler=msvc71"
The headers, libs and examples are installed in OpenSG/Build/win32-msvc71/installed
Visual Studio 2005
Open a cmd shell and go into the OpenSG directory and type ".\scons compiler=msvc80"
The headers, libs and examples are installed in OpenSG/Build/win32-msvc80/installed
In the Visual Studio 2005 Express edition the platform sdk is missing so
it is necessary to install the platform sdk from
If you have trouble compiling because of the missing openexr_vc80.lib, you can unpack
the dist\win\supportlibs.zip and add the directory to your scons command line,
e.g. "exr=unpackdir". This will only work for the release build. If you have trouble
just set "exr=no". Read here as well for more info:
Visual Studio 2008
The same instructions as for VS 2005 apply, just use ".\scons compiler=msvc90" to start the scons build.
- Type ".\scons -h" to see all possible options.
- Use ".\scons type=both" to get both degug and release versions.
If you run cygwin, be sure to use ".\scons.bat" to start the right file.
- Use ".\scons -j 2" for a dual core system, or ".\scons -j N" for an N-core system.
strike-through lines are only necessary if you build OpenSG 1.6.