Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "PTP/rdt-setup"

< PTP
(How to build and run RDT (Remote Development Tools))
(How to build and run RDT (Remote Development Tools))
Line 1: Line 1:
 +
== How to d run RDT (Remote Development Tools) from the Milestone builds==
 +
 
== How to build and run RDT (Remote Development Tools) ==
 
== How to build and run RDT (Remote Development Tools) ==
  

Revision as of 12:14, 20 September 2008

How to d run RDT (Remote Development Tools) from the Milestone builds

How to build and run RDT (Remote Development Tools)

RDT, Remote Development Tools, allows the use of CDT on remote projects and files. In this discussion, the local machine is the one running eclipse, the remote machine (indicated by [Remote] below) is the one to connect to for remote files, etc.

Here is how to set it up and run.

Note that much of this will be automated soon, so it's a bit tedious here.

  1. Get Eclipse 3.4 (Ganymede) and CDT 5.0.1
  2. Get RSE Server
    • From RSE download page at http://download.eclipse.org/dsdp/tm/downloads/ - click on version 3.0
    • on the "TM Release Build:3.0" page, scroll down to "DStore Server Runtime" section and get rseserver-3.0-<platform> file, zip or tar, for your remote machine's platform.
    • [Remote] Untar it on the remote machine, for example in a directory named 'rseserver'
  3. Go to org.eclipse.ptp.rdt.core.remotejars project and use the .jardesc files to build all the jars
    • In CVS Repository exploring perspective, connect to dev.eclipse.org:/cvsroot/tools
    • Under HEAD, expand org.eclipse.ptp project, and expand 'rdt' folder
    • Check out all the rdt projects if you like - for this step you need the remotejars project - you don't need projects ending in 'test' or 'tests' however.
    • Expand the org.eclipse.ptp.rdt.core.remotejars project
    • Rightmouse on one of the *.jardesc files, and select "Open JAR Packager" - in here, select the export destination - where it will write the jar file.
    • Click 'Finish' and it will generate the jar file. It will also prompt you to save/overwrite the .jardesc file.
    • After setting this up, later you can rightmouse on the .jardesc file and just select "Create JAR" if you don't need to change anything.
    • It should build these jars:
      • cdtminer.jar
      • cdtmodel.jar
      • cdtparser.jar
      • stubs.jar
  4. [Remote] Copy those jars to remote machine, e.g. in the 'rseserver' directory as in the example above
  5. [Remote] Copy the eclipse jars for org.eclipse.equinox.common, org.eclipse.core.runtime, and org.eclipse.core.filesystem to remote machine, again into the 'rseserver' directory
    • They should be in your <eclipse-install>/eclipse/plugins directory (either on the local machine, or if eclipse SDK is on remote machine, can copy them from there. They are not platform-specific.)
    • for example
      • cp eclipse/plugins/org.eclipse.equinox.common_*.jar ~/rseserver
      • cp eclipse/plugins/org.eclipse.core.runtime_*.jar ~/rseserver
      • cp eclipse/plugins/org.eclipse.core.filesystem_*.jar ~/rseserver
  6. [Remote] In the rseserver directory:
    • Add a line to minerFile.dat that has org.eclipse.ptp.internal.rdt.core.miners.CDTMiner in it
    • Edit the server script file (e.g. server.sh or server.pl) to add all the jars you copied over to the CLASSPATH. So the CLASSPATH line looks something like:
      • CLASSPATH=.:dstore_extra_server.jar:dstore_core.jar:dstore_miners.jar:clientserver.jar:cdtminer.jar:cdtmodel.jar:cdtparser.jar:org.eclipse.core.runtime_3.4.0.v20080421-1805.jar:org.eclipse.equinox.common_3.4.0.v20080421-2006.jar:org.eclipse.core.filesystem_1.2.0.v20080421-1805.jar:stubs.jar:$CLASSPATH;
      • where the qualifier in the names of the eclipse jars matches what you copied in the previous step (the version/date/timestamp info in the filename)
  7. Back on your local (eclipse) development workbench, get the RDT plugins from CVS as described in a previous step.
  8. Launch a runtime workbench with CDT and RDT
  9. Create a connection to the remote machine:
    • Open the Remote System Explorer Perspective
    • In Remote Systems view, right mouse and select New Connection...
    • Select Linux for type of connection and select a hostname/IP address, and give the connection a name, select Next
      • Note: for AIX use 'Unix' for type of connection
    • Click Finish to accept the defaults.
    • Now expand the connection item, you will see Files, Processes, etc.
    • Rightmouse on Files, choose Properties
      • On left, select Server Launcher Settings and select "Connect to running server"
      • On left, select Subsystem and change the port number to what you will use on remote system, e.g. 4242
        • Note: to type in the port number field, click the triangle next to it to enable text entry.
      • Click OK to close the Files Properties dialog
  10. [Remote] Now start the server on the remote machine with an argument indicating the port number
    • Example: > ./server.pl 4242
    • Note: you now have only about a minute to connect from the local machine, or it will time out, so postpone this if you want
    • Server messages should include: Extended schema from CDTMiner
    • If this doesn't look right, confirm the CLASSPATH is set correctly in the server script so it can find all the jars
  11. Now back on the local eclipse workbench, Create a project
    • Switch to the C/C++ Perspective
    • New, Project, New Remote C/C++ Project click Next
    • In the New Remote C++ Project dialog:
      • Give the project a name e.g. MyRemoteProject
      • Uncheck 'Use default location'
      • Choose file system: RSE
      • Location: Browse ... which opens the Browse for Folder dialog
        • For Connection, select the connection appropriate for your remote machine (the one you created above)
        • Expand home directory to find location for remote project
          • [First time] You will be prompted to login with User ID and password -- Make sure remote server is started before you do this
          • Select folder which will hold the files for the remote project [For now, choose an empty folder]
      • Back in 'New Remote C++ project' dialot, you should see the project name, location and file system indicating the selections you just made.
      • Under project types, choose Remote Makefile Project
      • Select Next, Next, Next until you get to the "Configure Services" page to set up the Remote Services.
        • Click on Build, and Configure..
          • Select Provider: RSE and Connection: your connection; Hit OK
        • Click on C/C++ Indexing, and Configure... and choose the remote host (your connection name)
        • [Note: if you select Configure... again the dialogs may default back to initial state, but your selections are there.]
        • Click Finish to end the 'New Remote C++ Project' Wizard
        • Note: You can also set up the Remote Services in the Properties of the project.
      • Now you can create files in that project, including copy and paste from other (local or remote) projects or other places on your local filesystem.

.. need to complete to show remote indexing: basically, the outline works for a source file, and a call hierarchy view too.

Back to the top