Importing OpenMigrate into Eclipse with ANT - tsgrp/OpenMigrate GitHub Wiki

Importing OpenMigrate instance

To import an OpenMigrate instance form the file system into Eclipse, follow the next steps:

  1. Create a new Java Project under the "File" header menu.
  2. Give the project a name.
  3. Un-check the "Use default location" option and instead browse for the location of the code folder for the instance of OpenMigrate that you would like to import. ex: C:\dev\trunks\OpenMigrate\code
  4. If you would like all modules to be present for this instance of OpenMigrate (for a copy of trunk for instance) click on the "Finish" button, otherwise click on the "Next" button and follow the instructions for configuring a project's build path.

Configuring the project's Build Path

Configuring a project's build path will instruct Eclipse to only import a certain subset of OpenMigrate resources, namely the resources required by this project. Usually, when importing OpenMigrate into Eclipse only a few modules are required for the migration, so excluding all other modules and referenced libraries makes the project cleaner.

To configure an OpenMigrate project's Build Path in Eclipse, follow the next steps:

  1. If you are importing a project for the first time, you should be looking at the Java Build Settings menu. If not, right click on the existing project and select the option "Build Path" -> "Configure Build Path".
  2. Select all of the folders that start with the path modules/ or web-modules/. Using the ctrl button, click on the modules that you would like to keep on this Eclipse project (usually core, plus one or two more).
  3. Right click on the selected modules (all modules that are not desired for this project) and select the option "Remove from Build Path". You should now see only the modules that you require for this project on the Build Path.
  4. Navigate to the libraries tab. Select all jars under this tab (be careful not to select the "JRE System Library [eclipse]" option) and click on the "Remove" button. You should be left with only the JRE system library reference.
  5. Click on the "Add JARs..." button. Navigate down the project to the modules/core/lib directory. Select all of the JAR files inside this folder and click on the OK button. Do this for the lib-test directory as well.
  6. Repeat step 5 for all other modules that you would like to have in this project. Note that some modules may have other "lib" directories that need to be imported, such as the case of the lib-test directory in the core module.
  7. Click on the "Finish" button to complete the Java Build Path configurations for this OpenMigrate project.