Setting up a development environment
Getting the source
Short story: The source is at Github, . If you need more information, read on.
Using GIT and Eclipse (recommended)
- Install Eclipse (classic is ok)
- Follow the tutorial at  to "Install EGIT" and "3.2 Clone an existing project"
- Import the javaclient project
For read-only accounts (default), use git://github.com/mahogny/Endrov.git
If you have write-access, use https://github.com/mahogny/Endrov.git You have to set up SSH keys in Eclipse; It is in Window -> Preferences -> Network -> SSH. The keys also have to be registered at GitHub.
More information if you have write-access and an alternative tutorial: http://wiki.eclipse.org/EGit/User_Guide#Github_Tutorial
If you are using Linux, install dependencies. See Installing Endrov on Linux.
Ubuntu 9.10 + Eclipse bug If buttons do not respond when you click on them then run $ export GDK_NATIVE_WINDOWS=1 before starting Eclipse
Working with Eclipse
Getting it to compile
Set up the indentation rules (optional, recommended for editing)
- Download Indentation rules for Eclipse settings (may have to right-click and save as)
- Project properties -> Java Code Style -> Formatter -> Configure workspace settings -> Import
- Select in list, Ok
Ensure proper character encoding (optional)
- Project properties -> Resource -> text file encoding -> UTF-8
If you are not on Mac, disable some plugins (needed)
- Look up endrov.macBinding, right-click -> build path -> remove from build path
Get rid of additional compilation problems (not always needed)
- Missing references: Try to add library jars (right-click -> build path -> add to build path). The libraries are in libs/. It doesn't make a big difference which platform, e.g. on Linux you can use the Mac jars.
- Other missing references: If it's just a few missing references or compilation references left, you can disable these files (right-click -> build path -> remove from build path).
To run Endrov from Eclipse
- Should always work: right-click endrov/starter/startGUI and select Run as...Java Application. It detects the jar-files automatically
Use auto-complete for quick documentation
Eclipse allows you to see the documentation for a given class quickly. If you have e.g. Imageset im=new Imageset(); then you can write im. and then press ctrl+space. All methods and variables will be listed, with comments.
Dealing with platform specific code
If some code does not work on your platform (for example Mac-only code, and you are on PC), then this code can be excluded in a way that does not interfere with CVS: Right-click on the nasty plugin directory (e.g. macBinding), -> Build Path -> Exclude. That's it.
The Package Explorer list can be made much shorter if you go into the menu, Package Presentation, Hierarchial. Once everything initially compiles you can get rid of some warnings by excluding for example script.parser from the build path (the .class-files will still be used).
Compiling without Eclipse
To compile, enter the root directory and type
some error messages are expected e.g. mac specific code does not compile on Linux.
- May have trouble starting it - using startEndrov.jar is usually safe. Should document precise possible errors.
- Running in debug mode - problematic using the standard instructions, I never use it. Needs work