Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
PTP/environment setup 60
Contents
- 1 Setup for development of PTP 6.0
- 2 To check out PTP projects:
- 3 old info
- 4 PTP developer: API baseline and code formatter
- 5 Copy Remote Tools Dstore server jar
- 6 Launching a runtime workbench running the code you checked out into your workspace
- 7 Compiling XML Schema (XSD) into Java classes using the JAXB compiler (xjc)
Setup for development of PTP 6.0
THIS IS IN THE PROCESS OF BEING UPDATED FOR GIT
Git reference info: Links to Git info
These instructions describe using the HEAD version of the repository. Please let us know (e.g. on ptp-dev mailing list) if these instructions need updating.
PTP 6.0 needs Eclipse 3.7/Indigo (or Eclipse 4.2/Juno), CDT 8.0 or above, and RSE 3.3 (at least)
Download Eclipse 4.2 (Juno) here: http://www.eclipse.org/downloads/index-developer.php
- as of 11/2 M3 is available here: http://download.eclipse.org/eclipse/downloads/drops4/S-4.2M3-201110281100/index.php - should probably be on above site soon. "Eclipse Classic" is a good hoice.
- as of now, Eclipse 3.7.1 (Indigo) should still work on 6.0 and can be found here: http://eclipse.org/downloads/ for your platform. "Eclipse Classic" is a good choice.
- Note: RSE is optional if you are not doing any remote development work.
Install CDT, RSE, Git, and JAXB in your eclipse installation
- Help > Install New Software...
- Open "Programming Languages" and select "C/C++ Development Tools SDK"
- Also get the CDT feature "Unified Parallel C Support"
- Open "General Purpose Tools" and select "Remote System Explorer End-User Runtime"
- Open "Collaboration" and select "Eclipse JGit" and "Eclipse EGit"
- Add http://download.eclipse.org/tools/orbit/downloads/drops/R20110523182458/repository as a software site
- Make sure "Show only latest version..." is disabled and "Group items by category" is enabled
- Select "Java Architecture for XML Binding (JAXB) Implementation Plug-in" and "XML Binding for Java" both version 2.1.9
- Optional: Open "Web, XML, JavaEE..." and select "Eclipse XML Editors and Tools" (needed only to create RM configurations)
To check out PTP projects:
- Import ... then use the 'Git>Projects from Git' import wizard.
- Click on Clone... and enter the repository URI:
- Use your committer userid and password.
- Click Next> to choose the branches you want to clone (usually ptp_5_0 and master==HEAD).
- Click Next> to choose where you want the repository located locally. It can be anywhere.
- Click Finish. The repository should be downloaded.
- Once the repository has downloaded you should see it in the list. Select it.
- Click Next> then Next> again and you should see a list of all the projects.
- Select the ones you want (usually all) and click Finish.
Repeat the steps to import another repository (e.g. photran). The photran URI is ssh://userid@git.eclipse.org/gitroot/ptp/org.eclipse.photran.git
old info
In CVS, check out org.eclipse.ptp/releng/ptp_project_sets as follows:
- Window > Open Perspective > Other...,
- Choose "CVS Repository Exploring"
- Right-click in CVS Repositories view, choose New > Repository Location
- Host: dev.eclipse.org
- Repository path: /cvsroot/tools
- User: anonymous
- If you have a committer id on dev.eclipse.org, use that, enter the password, and change the Connection type to extssh
- Expand that repository and expand HEAD. Scroll down to org.eclipse.ptp and expand it
- Expand releng, and check out ptp_project_sets
Now switch to the Plug-in development Perspective
- In the ptp_project_sets project in your workspace, right-click on anonymous/ptp-HEAD-all-anonymous.psf and select "Import project set"
- If you have committer access, use committer/ptp-HEAD-all-committer.psf
- Alternatively, you can check out ptp-5.0-all-*.psf (committer or anonymous)
PTP developer: API baseline and code formatter
- Set up API baseline see PTP/developer_guidelines for API Baseline setup (API Tools)
- Set up PTP code formatter - see PTP/developer_guidelines for PTP formatting and cleanup profiles
Copy Remote Tools Dstore server jar
If you are using Remote Tools ... you may see the error "Unable to locate payload "rdt-server.jar" in bundle "org.eclipse.ptp.rdt.server.dstore" " when you launch a runtime workspace and make a remote project.
So you must do the following (Until we can build rdt server jar here) ... From a PTP (end-user) installation, unzip eclipse/plugins/org.eclipse.ptp.rdt.server.dstore_xxx.jar into a directory. Then from the unzipped contents move rdt-server.jar to your development workspace project: org.eclipse.ptp.rdt.server.dstore
(This is the file that will be moved up to the remote host location when you create a remote project. Remote Tools installs this jar on the server automatically and starts it for you.)
If you don't, you will see the error popup "Unable to locate payload "rdt-server.jar" in bundle "org.eclipse.ptp.rdt.server.dstore"
Launching a runtime workbench running the code you checked out into your workspace
- Run > Debug Configurations ...
- Double-click on 'Eclipse Application' - or click and click on the 'new' icon
- Defaults are probably ok to run with all the plugin projects in your workspace; hit 'Debug' in lower right corner
Compiling XML Schema (XSD) into Java classes using the JAXB compiler (xjc)
Should there be a need to alter the provided schemas for the JAXB Resource Manager (or any other such JAXB tooling), follow these steps to set up compilation:
- Download jaxb-ri (xjc); e.g., from JAXB Project (Note: Mac OS X already has xjc installed)
- Install it somewhere on your local machine
- In your project workspace, create an External Tools Configuration. The following is an example based on org.eclipse.ptp.rm.jaxb.core, which has the .xsd in the data directory:
- Location: {jaxb-ri directory}/bin/xjc.sh or xjc.bat
- Working Directory: ${workspace_loc:/org.eclipse.ptp.rm.jaxb.core}
- Arguments: data/resource_manager_type.xsd -p org.eclipse.ptp.rm.jaxb.core.data -d src
Each time you run this, all the source files generated from the schema will be overwritten.