Skip to content
masel0 edited this page Dec 17, 2021 · 13 revisions

The build process of OCE (with Visualisation) under Windows 64bit will be explained using the MinGW-w64/MSYS toolchain. It has been tested successfully with the Mingw-builds release of MinGW-w64. It provides a convenient installer where SEH exceptions and POSIX Threads have been selected and successfully compiled so far. We will use this configuration as a basis for our explanation. Other MinGW-w64 builds and options might work, but are untested.

Prerequisites

The following prerequisites must be installed/downloaded:

Building

Running CMake

Start CMake and complete the following steps:

  • Point "Where is the source code:" to your local copy of OCE
  • Build the binaries in a new specific build folder within OCE
  • Hit Configure
  • Choose "MSYS Makefiles" (NOT "MinGW Makefiles"!) with default native compilers
  • When required: Point CMAKE_MAKE_PROGRAM to /bin/make.exe in your MSYS directory and configure again.
  • Check OCE_USE_BUNDLE_SOURCE
  • Check OCE_WITH_FREEIMAGE
  • Check OCE_WITH_GL2PS
  • Check OCE_VISUALISATION
  • Use OPENMP as OCE_MULTITHREAD_LIBRARY
  • Select your Installation directory with OCE_INSTALL_PREFIX
  • Configure
  • Select the directory of your oce-win-bundle clone with OCE_BUNDLE_ROOT_PATH
  • Select your required build type (RELEASE,DEBUG..)
  • Configure (and no entries should be red afterwards..)
  • and Generate.

Run MSYS and make

  • Start msys.bat in your MSYS directory (as an Administrator)
  • cd into your build directory
  • run make

Compilation is now running. It can take several hours, depending on your machine.

Install

  • run make install

If you want to compile as DEBUG, you might have to compile twice, once as RELEASE and once as DEBUG to obtain the required release and debug libraries.