How to use LCSim in Eclipse

In order to write your own drivers it is usefull to use an integrated development environment (IDE). Eclipse is a java based open source IDE which provides development environments for all programming languages (and other things) through plug-ins.

Installing Eclipse

  • Download the latest Eclipse with JDK version and unpack.
  • Add the eclipse directory to your PATH variable.
Warning, important Installing eclipse through a linux package manager can lead to problems when adding plug-ins later because of missing root priviliges.

Plug-ins

Maven

The Maven project management tool is required to build LCSim and GeomConverter.
All recent versions of eclipse come with this plug-in.

SVN (optional)

LCSim and GeomConverter are CVS repositories, so you only need SVN if your own projects will be part an SVN repository (which is very good idea). Possible SVN plug-ins for eclipse are: Both can be found in the eclipse market place (Help->Eclipse Marketplace). The installation also requires the installation of SVN bindings, which eclipse will offer during the installation.
  • SVNKit is a pure java implementation of svn (recommended)
  • JavaHL provides access to the usual svn libraries through JNI bindings

Getting LCSim and GeomConverter into Eclipse

Since your drivers will depend on classes which are either in LCSim or in GeomConverter it is usefull to have both projects available in your workspace. This will allow code completion and browsing of code.
  • go to File->New->Project and select CVS->Projects fromCVS
  • create a new repository location :pserver:anonymous@cvs.freehep.org/cvs/lcd
  • select use an existing module and browse for GeomConverter
  • select Check out as a project in the workspace and choose a project name
  • click finish
  • right click on the project and select Configure->Convert to Maven project
  • to build the project select from the run configurations Maven build or Maven install
  • in order to make the dependencies visible to depending projects right click on the project and select Properties. Go to Java Build Path->Order and Export and tick Maven Classpath Container.
  • repeat for LCSim

Starting your own Project

  • go to File->New->Java Project and enter a project name
  • add GeomConverter and LCSim to the Projects tab
  • click finish
  • now the code completion (ctrl+space) should work for classes from org.lcsim

FAQ

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r3 - 2012-07-06 - ChristianGrefe
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    CLIC All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback