Home Building OSRail Windows
Building OSRail for Windows Print
Written by Samuel E. Henley   
Saturday, 05 April 2008 16:40

Install the SDKs for these 3rd party libraries and required tools.

Create Working Directory

    This directory should be at the top of the OSRail development tree and will contain the downloaded third party software. Create a working directory (c:/working) and for convenience add a directory for downloads (c:/working/download).

7z

TortoiseSVN

  • Version Control System client.

  • Download from http://tortoisesvn.net

  • Run TortoiseSVN-1.7.0-RC1-win32-svn-1.7.0-RC1.msi

 

Platform SDK

  • Win32 API - Microsoft Windows SDK for Windows 7.1 and Net Framework 3.5 SP1

  • Download from http://download.microsoft.com

  • Run winsdk_web.exe

  • Add Microsoft Windows SDK for Windows 7.1 - add to environment (computer properties, advanced, environment variables)
    set WindowsSDKDir to Microsoft Windows SDK for Windows 7.1 location (C:\Program Files\Microsoft SDKs\Windows\v7.1\) and add
    %WindowsSDKDir%Lib; to LIB; %WindowsSDKDir%Include to INCLUDE and add %WindowsSDKDir%Utilities\Bin\ to PATH.

DirectX

  • Graphics, Input, Sound - DXSDK_Jun10.exe

  • Download or Install from http://download.microsoft.com

  • Add Microsoft DirectX SDK (June 2010) - add to environment (computer properties, advanced, environment variables)
    %DXSDK_DIR%lib\x86 to LIB; %DXSDK_DIR%Include to INCLUDE

PoEdit

Doxygen

Graphviz (dot)

MinGW

Open Command Window Here

Pkg-config

  • Download in cygwin directory - cygwin-1.7.9-1.tar.bz2 and pkg-config-0.23b-10.tar.bz2 from a mirror site on
    http://cygwin.com/mirrors.html go to the release directory.

  • Use 7Z and extract pkg-config.exe and cygwin1.dll (in the /usr/bin directories) into the mingw bin directory (c:\mingw\bin)

  • Test pkg-config with pkg-config --version. (use a command line anywhere other then C:/MinGW/bin)

Python

  • Used for Unit Testing (cxxtest) of OSRail http://www.python.org

  • Run Python-2.7.2.msi (Any version 2.xx will do, as long as it has a windows installer (.msi)).

Build wxWidgets

  • Get current version of wxWidgets from wxWidgets http://svn.wxWidgets.org/wx/wxWidgets/tags/WX_2_9_2.

  • Check out to the source to C:\WX_2_9_2

  • Build in wxWidgets in C:\WX_2_9_2 \build\msw

  • mingw32-make -f makefile.gcc MONOLITHIC=1 SHARED=1 UNICODE=1 USE_OPENGL=1 BUILD=release .

  • mingw32-make -f makefile.gcc MONOLITHIC=1 SHARED=1 UNICODE=1 USE_OPENGL=1 BUILD=debug .

  • Add WXWIN=C:\WX_2_9_2\ to the enviroment and add %WXWIN%\lib\gcc_dll to the PATH (computer properties, advanced, environment variables).

Build wxrc

  • Get command line in directory %WXWIN%\utils\wxrc.

  • mingw32-make -f makefile.gcc MONOLITHIC=1 SHARED=1 UNICODE=1 USE_OPENGL=1 BUILD=release

Install CodeBlocks

  • Download codeblocks-8.10.05-setup.exe from http://www.codeblocks.org

  • Run codeblocks-8.10.05-setup.exe.

  • If using the nightly build load it over the CodeBlocks directory (C:\Program Files\CodeBlocks).

  • Run CodeBlocks.

  • Set the "wx" variable: Menu: Setting, Global Variable Editor, Select variable wx, and set the "base" to "$(WXWIN)".
    - only setting Base is required.

  • Goto menu Settings->Environment and uncheck "one running instance"
    Settings->Compiler&Debugger->Debugger Settings and uncheck "Catch C++ Exceptions"

  • Add C:\Program Files\CodeBlocks to your PATH in the environment: (Computer Properties – Advance – Environment)

Test CodeBlocks & wxWidgets

  • Run CodeBlocks

  • File -> new project -> wxWidgets project

  • Go, next, 2.9.x, title=wxtest

  • Author = etc.

  • none, frame based

  • $(#wx) is OK

  • Create a release and debug configuration.

  • Use wxWidgets DLL, Create PCH, MONOLITHIC

  • Finish

  • Build workspace

  • Run workspace

libcurl

  • Get libcurl from http://curl.haxx.se/ use download wizard - Curl Download Wizard -libcurl - win32 -  Generic

  • Use 7Z to install curl-7.21.7-devel-mingw32.zip in the working directory (c:/working/curl)

  • Copy the program curl.exe and its dlls in archive at c:\working\curl\bin to Windows/system32.

OSRail Repository

  • Browse Repository with TortoiseSVN at: http://wush.net/svn/sehenley/simulator

  • Create a path in home: working/simulator/trunk

  • Select trunk and checkout to .../workspace/simulator/trunk

  • If committing changes, request a password and user name for the svn site from This e-mail address is being protected from spambots. You need JavaScript enabled to view it

CMake (Special version with a CodeBlocks generator – source in vendor sub-directory)

  • Get cmake from http://www.cmake.org/cmake/resources/software.html

  • Download and run cmake-2.8.5-win32-x86.exe, Select a install path of C:\Program Files\CMake

  • Get a command prompt in directory .../working/trunk/vendor/cmake

  • cmake -G"MinGW Makefiles"

  • mingw32-make

  • mingw32-make install

  • Insure that the modified version is on the path with the command cmake --copyright.

  • Use TortoiseSVN to revert any changes to the cmake source
    ( right click on c:/working/trunk/vendor/cmake, TortoiseSVN, revert... )

Build GDAL/OGR

  • Get Gdal from from svn https://svn.osgeo.org/gdal/tags/1.7.3/gdal

  • Checkout to "c:/working/gdal"

  • In "c:/working/gdal" create directory "CODEBLOCKS".

  • Get a commandline in "CODEBLOCKS"

  • cmake -G"CodeBlocks" c:/working/simulator/trunk/src/builds/gdalogr

  • Go to the CODEBLOCKS directory and open GdalOgr.workspace with the CodeBlocks IDE.

  • Build both a Release and Debug version of the workspace. Sometimes requires 2 builds - phasing error.

CG Toolkit

  • Download: CG Toolkit from http://developer.nvidia.com/object/cg_download version for Windows

  • Run Cg-3.0_February2011_Setup.exe (Requires an account)

 

 

Install Ogre

  • Download, open with 7z and run OgreSDK_mingw_v1-7-2.exe from http://www.ogre3d.org/ , move to the default location (c:/OgreSDK_mingw_v1-7-2)

  • Set environment variables (Computer Properties – Advance – Environment) OGRE_HOME=c:\OgreSDK_mingw_v1-7-1 and add
    %OGRE_HOME%\bin\debug;%OGRE_HOME%\bin\release to PATH.

boost

Open-Soft (OpenAL)

GetText

Subversion Client

  • Download from http://subversion.apache.org, Collab Net (must register) CollabNetSubversion-client-1.6.17-1.win32.exe
  • Run CollabNetSubversion-client-1.6.17-1.win32.exe

Building OSRail under Windows with CodeBlocks

To build a CODEBLOCKS build under Windows, create a directory CODEBLOCKS in the "/branch/tag or trunk directory" and get a command prompt in the CODEBLOCKS sub-directory, type the command: "cmake -GCodeBlocks .. ". The cmake scripts will check that all 3rd party libraries are installed and build some required utilities for OSRail. The cmake script will create the workspace file OSRail.workspace.

Building OSRail under Windows with mingw32-make

To build a mingw32-make build under Windows, create a directory MINGW in the "/branch/tag or trunk directory" and get a command prompt in the MINGW sub-directory, type the command: "cmake -G"MinGW Makefiles" .. ". The cmake scripts will check that all 3rd party libraries are installed and build some required utilities for OSRail. The cmake script will create Makefile. Run mingw32-make in the MINGW sub-directory.

Last Updated on Wednesday, 26 October 2011 05:29