Cling

# Build Instructions

This page is shows how to download and build the project cling as a standalone C++ interpreter in few steps..

### Build script

You can download and run this build script.

### Building with CMake

Prerequisites
- See Getting Started with the LLVM System - Requirements
- Note also that Python is needed for running the test suite.
And extra for Windows
- cmake - http://www.cmake.org/cmake/resources/software.html
- Python - http://www.python.org/download/
- GnuWin32 Tools - http://getgnuwin32.sourceforge.net/
- Visual Studio - VS Express should work as well

Start by checking out llvm, clang and cling:

    git clone http://root.cern.ch/git/llvm.git src
    cd src
    git checkout cling-patches
    cd tools
    git clone http://root.cern.ch/git/cling.git
    git clone http://root.cern.ch/git/clang.git
    cd clang
    git checkout cling-patches

Now follow the procedure described at the clang web page for ./configure --enable-cxx11; make- or CMake-based build instructions. Don't forget to make install. You will get a binary called cling: that's your interactive C++ interpreter!

Then use CMake to configure & build cling:

    mkdir obj
    cd obj
    cmake -DCMAKE_INSTALL_PREFIX=[Install Path] ..\src
    cmake --build . --config [Release/Debug] --target cling