Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This page describes how to setup Eclipse, and run Zong! and its automated tests. Please follow the steps carefully.

Table of Contents
maxLevel1

 

Setup Eclipse

Before The following video demonstates how Zong! can be imported into Eclipse, please make sure the following requirements are met.

  1. Install Eclipse 4.4 (Luna) or higher. The main development is currently done in Eclipse 4.4 SR1. Java 1.8.0_20 (or higher) must be the default JRE in the workspace.
  2. Install GWT 2.7.0 (or higher), including the GWT Eclipse plugin. This is necessary for the gwt-utils and webapp modules, which provide HTML5/JS code generated from Java code. If you are not interested in the HTML5/JS apps, you can also skip this step and close the GWT projects in your Eclipse workspace later.

Setup the workspace

After Zong! was downloaded, it can be opened in the Eclipse IDE. This section describes the steps for getting Zong! up and running.

...

Image Removed
 

Import the projects
Zong! consists of many subprojects, called modules. These have to be imported once.
Choose "File → Import...". In the following dialog, select "General → Existing Projects into Workspace" and click on "Next >".

...

Image Removed

...

Download or update the external libraries
As you will notice, Zong! is still not ready for compiling. A lot of errors appear in the Problems view of Eclipse. We need to download some external libraries, which are not part of the git repository (since we do not want to store large binary files there, to keep the repository small). Downloading or updating the libraries is easy: Just right click the Ant script file lib.update.xml in the lib project, then select "Run As → Ant Build". All required libraries will be downloaded.

Tip

Each time when you update (pull) your local repository, and when you get classpath errors when compiling, repeat this step and the later step "Import user libraries". Probably the libraries were changed or updated to newer versions.

Info

Notice that this step is not needed for building Zong! using the gradle build script. Gradle will download and update the needed libraries automatically.

...

Import user libraries
At this point we have downloaded the required libraries, but Eclipse does not know them yet. We have to import the so-called "user libraries".
In "Window → Preferences", select "Java → Build Path → User Libraries". The following dialog appears:

...

That's it. Zong! should be compiling now (smile)
If you have problems, please let us know, so that we can help you and update this guide.

 

Run Zong! in Eclipse

Currently, the following runnable components exist within the Zong! project. They can be started by right-clicking the corresponding ".launch"-file and selecting "Run As → (app name)".

  • Zong! Player: project "player", file "Player.launch"
  • Zong! demo apps: project "demos"
    • MinimalDemo
    • SimpleGuiDemo

 

Run automated tests in Eclipse

Zong! and the Xenoage Utils project contain a lot of unit tests.

The unit tests of Zong! are bundled in the project named "test", within the directory named "test". To run them, simply right click on a this folder and select "Run As → JUnit Test".

The unit tests of Xenoage Utils are bundled in the project named "utils-test".

 

 

 

 

 opened, run and tested within the Eclipse IDE. We tested it with version 4.5 (Mars).

If you have problems or questions, which are not answered in this video, please tell us.

Note

Don't forget to install Lombok in Eclipse by starting the lombok-{version}.jar file which is downloaded by Gradle.

Widget Connector
urlhttps://www.youtube.com/watch?v=EIdf4FJlQ5I