Skip to content

detailed Eclipse build instructions

walambert edited this page Aug 30, 2020 · 2 revisions

How to build the CQL IDE using the Eclipse IDE for Java Developers

  1. Download and install a JDK; I used OpenJDK 11 LTS and HotSpot JVM: https://adoptopenjdk.net/
  2. git clone https://github.com/CategoricalData/CQL.git
    • Don't clone this into Eclipse's workspace folder, bad things happen.
  3. Open Eclipse > click File > open New Java Project
  4. Project Name = cql
  5. Click Finish, do not create modules
  6. Right click on cql in the "Package Explorer" window > click Properties
  7. Select Java Build Path > click on Source > click Link Source
  8. In the Link Source menu click Browse and navigate to the cloned cql github folder > go to src/main/java and click Open
  9. Follow step 7 and beginning of step 8 but this time in the cloned cql github folder go into the resources folder then click Open
  10. Still inside the Java Build Path menu after linking the above two folders, click Libraries (you were in the Source tab, now click on the Libraries tab)
  11. In the Libraries tab select Classpath then click Add External JARs...
  12. In the file menu that opens, navigate to your cloned cql github folder > go into the lib folder > select all items in that folder > click Open
  13. In the Java Build Path menu where you've been working, you'll see a button labelled Apply and Close > click Apply and Close
  14. Look at the Eclipse menubar / toolbar for Run > select Run > click on Run Configurations...
  15. In the Run Configurations menu left panel / menuarea go into Java Application and select IDE
  16. In the IDE menu ensure that the Project is cql (or whatever you've named the project if that's different) > ensure that the Main class: is set to catdata.ide.IDE
  17. The above two options in 16 were already set for me when I opened the IDE menu, I didn't have to browse or search for anything, your mileage may vary though. Once you have the correct options selected for Project and Main class: > click Apply > then click Run
  18. Congrats! If everything worked well the CQL IDE will open shortly.
    • If it doesn't, the error probably came from steps 6-13 when you were linking sources and adding the external JARs. By default in the Link Source menu the "Ignore nesting conflicts" option is selected...if your compilation wasn't successful try linking sources with the other option ("Update exclusion filters in other source folders to solve nesting") selected.
  19. If you right click on the newly created CQL IDE's icon in your OSes dock, taskbar, etc. and "add to dock", "create shortcut", "pin to panel", etc. (this option will reflect your OSes terminology for that function, I've mentioned a few common ones) then you'll be able to click on the created shortcut to open the CQL IDE like it's a normal application.