Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

Prerequisites

Here's how to set up Eclipse to work with a Marlin Processor, including debugger.
These instructions are for Eclipse Indigo. The instructions at https://twiki.cern.ch/twiki/bin/view/CLIC/LCSimEclipse may be a starting point to set up Eclipse, although they are for a different version.
Either

  • Check out the Marlin Project and build it
    1. source /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/init_ilcsoft.sh
    2. cmake -C $ILCSOFT/ILCSoft.cmake ..

or

  • Create a new SVN project in eclipse and "Configure Project using New Project Wizard". Use the wizard to create a new C++ project.
    Note
    titleWorkspace Imports

    When creating a new C++ Project from existing sources, the existing sources MAY NOT be in the eclipse Workdir.

    Adding Marlin sources

    Once you have the Project configured as a C++ project in Eclipse, Marlin sources are made available like this
  1. Add the ILCSoft include paths, e.g.
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/LCFIVertex/v00-06/include
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/ilcutil/v00-02/include
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/lcio/v02-00/include
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ROOT/v5-30-00/include
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/MarlinUtil/v01-04/include
    • /afs/cern.ch/eng/clic/software/x86_64-slc5-gcc41/ILCSOFT/v01-12/Marlin/v01-01/include
    • They should show up under Properties -> C++ General -> Paths and Symbols -> Includes Tab -> GNU C++. You may be able to add them right there, but for me I had to
    1. Enable Generate Makefiles automatically in Properties -> C/C++ Build
    2. Add these paths under Properties -> C/C++ Build -> Settings -> Tool Settings Tab
    3. Disable Generate Makefiles automatically in Properties -> C/C++ Build
  2. Some parts of the code may be wrapped in #ifdef. Define the symbol for this #ifdef (e.g. USEROOT) under Properties -> C++ General -> Paths and Symbols -> Symbols Tab -> GNU C++
  3. Specify the build location of your Makefile. In Properties -> C/C++ Build, in the build location field, add /build within the curly braces after the name of your project.

Now your done and should have code completion available.
You can add Run and Debug configurations by specifying the location of the Marlin executable and adding the necessary MARLIN_DLL and LD_LIBRARY_PATH environment configurations. Details to be put here upon request.