Skip to content

Compiling IFCOpenShell

Charence edited this page Sep 19, 2017 · 16 revisions

You will need a 3D Repo fork of IFCOpenShell as we have done yet again some modifications and fixes necessary to make it run with 3D Repo core engine. You will also need to install and compile dependencies in the following order:

  1. FreeType library (use version 2.5.5): https://www.freetype.org/download.html
  2. TCL library: http://www.activestate.com/activetcl/downloads
  3. OCCT: https://github.com/3drepo/occt
  4. IFCOpenShell: https://github.com/3drepo/IfcOpenShell

Windows

There are pre-built Windows binaries for both FreeType and TCL. Make sure to use 64-bit versions.

OCCT

Once downloaded, run CMake on OCCT and point the following to the right location:

  • 3RDPARTY_FREETYPE_DIR
  • 3RDPARTY_TLC_* should be populated automatically given you did a system-wide installation
  • INSTALL_DIR needs to point somewhere where the command line has write privileges

Upon installation, copy or simlink DLLs from the bin folder into the lib folder so that Qt can find the required libraries when running from IDE.

IFCOpenShell

Finally, build IFCOpenShell using CMake (there is CMake folder in the top-level directory). You might need to set the following variables:

  • BOOST_LIBRARYDIR
  • OCC_INCLUDE_DIR
  • OCC_LIBRARY_DIR (eg \occt\win64\vc12\lib)
  • CMAKE_INSTALL_PREFIX needs to point somewhere where the command line has write privileges

Also, make sure to disable the following:

  • COLLADA_SUPPORT
  • BUILD_IFCPYTHON
  • UNICODE_SUPPORT (unless you need special characters in which case you also need ICU library, see also https://wiki.qt.io/Qt_5_ICU)

OSX/MacOS

Homebrew (https://brew.sh) is recommended on OSX/macOS.

Install FreeType:

brew install freetype

Install TCL:

brew install tcl-tk

Do the following:

mkdir build && cd build
cmake ..
make

Install the project:

sudo make install

Clone this wiki locally