2.3.3.1. Building OpenFAST on Windows with Visual Studio

These instructions are specifically for the standalone Visual Studio project at openfast/vs-build. Separate CMake documentation is provided for Windows users at Section 2.3.6.

2.3.3.1.1. Prerequisites

  1. A version of Visual Studio (VS).

    • Currently VS 2013 Professional and VS 2015 Community Edition have been tested with OpenFAST.

    • A list of Intel Fortran compatible VS versions and specific installation notes are found here.

    • The included C/C++ project files for MAP++ and the Registry are compatible with VS 2013, but will upgrade seemlessly to a newer version of VS.

    • If you download and install Visual Studio 2015 Community Edition, you will need to be sure and select the C/C++ component using the Customize option.

  2. Intel Fortran Compiler

    • Currently only version 2017.1 has been tested with OpenFAST, but any newer version should be compatible.

    • You can download an Intel Fortran compiler here.

    • Only install Intel Fortran after you have completed your Visual Studio installation.

  3. Git for Windows

    • Download and install git for Windows.

  4. Python 3.x for Windows (for regression/unit testing)

    • The testing framework of OpenFAST requires the use of Python.

    • Please see Section 5 on testing OpenFAST for further information on this topic.

    • We have been working with Continuum’s Anaconda installation of Python 3.6 for Windows.

2.3.3.1.2. Compiling OpenFAST

  1. Open A command prompt, or git bash shell from the Start menu

  2. Create a directory where you will clone OpenFAST repository (change code to your preferred name)

    mkdir code
    cd code
    
  3. Clone the OpenFAST repository

    git clone https://github.com/openfast/openfast.git
    

This will create a directory called openfast within the code directory.

  1. Using Windows Explorer, navigate to the directory openfast\vs-build\FAST and double-click on the FAST.sln Visual Studio solution file. This will open Visual Studio with the FAST solution and its associated projects.

NOTE: If you are using Visual Studio 2015 or newer, you will be asked to upgrade both the Fast_Registry.vcxproj and the MAP_dll.vcxproj files to a newer format. Go ahead and accept the upgrade on those files.

  1. Select the desired Solution Configuration, such as Release, and the desired Solution Platform, such as x64 by using the drop down boxes located below the menubar.

  2. Build the solution using the Build->Build Solution menu option.

  3. If the solution built without errors, the executable will be located under the openfast\build\bin folder.