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 "MemoryAnalyzer/Building MAT With Tycho"

(New page: == Introduction == This page is describes how Memory Analyzer p2 repository and RCP applications can be built using Tycho. == Prerequisites == == Preparation Steps == == Build ==)
 
(Hudson Job at Eclipse)
(37 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
== Introduction ==
 
== Introduction ==
  
This page is describes how Memory Analyzer p2 repository and RCP applications can be built using Tycho.
+
This page describes how Memory Analyzer can be built using Maven/Tycho. The build will
 +
* build all bundles and features
 +
* execute all tests
 +
* (optional) run [http://findbugs.sourceforge.net/ FindBugs] static checks
 +
* produce a p2 repository with MAT features
 +
* produce RCPs for different platforms
 +
* sign and upload the produced artifacts (when executed on the Eclipse Hudson server)
  
 
== Prerequisites ==
 
== Prerequisites ==
  
== Preparation Steps ==
+
=== Git ===
 +
MAT sources are in a Git repository, therefore you need a git client.
  
== Build ==
+
=== Maven Installation ===
 +
The Memory Analyzer build requires a Maven 3.0.* installation. It is already present on the Hudson server at Eclipse. For local build one can download it from [http://maven.apache.org/download.html here].
 +
 
 +
=== Proxy Settings ===
 +
If you need to set a proxy for Maven, a snippet like this can be added to the Maven settings file:
 +
<source lang="xml">
 +
  <proxies>
 +
    <proxy>
 +
      <active>true</active>
 +
      <protocol>http</protocol>
 +
      <port>8080</port>
 +
      <host>myproxy_host</host>
 +
      <nonProxyHosts>non_proxy_hosts</nonProxyHosts>
 +
    </proxy>
 +
  </proxies>
 +
</source>
 +
More information on Maven settings: http://maven.apache.org/ref/3.0.3/maven-settings/settings.html
 +
 
 +
== Checkout MAT Sources from Git ==
 +
Have a look at [[MemoryAnalyzer/Contributor_Reference#Get the source]]
 +
 
 +
== Building MAT ==
 +
 
 +
=== Execute the build ===
 +
* Open a console and go into the ''<mat_src>/parent'' folder (there is the parent pom.xml)
 +
* To build MAT execute
 +
<pre>mvn clean install</pre>
 +
* To build MAT and perform FindBugs checks execute
 +
<pre>mvn clean install findbugs:findbugs</pre>
 +
 
 +
=== Where to find the results? ===
 +
You can find the results of the build in the corresponding .../target/ directories for each plugin, feature, etc... Of particular interest are:
 +
* ''<mat_src>/org.eclipse.mat.updatesite/target/site/'' - it contains a p2 repository with MAT features
 +
* ''<mat_src>/org.eclipse.mat.product/target/products/'' - it contains all standalone RCP applications
 +
 
 +
== Further Information ==
 +
* The platforms for which RCPs are built are specified in the ''<mat_src>/parent/pom.xml'' file
 +
 
 +
== Known Problems ==
 +
=== Wrong file permissions ===
 +
When building MAT on a Windows box, the RCPs for any other OS will not have the proper permissions (e.g. the executables won't have the x flag). Building under Linux or other non-Windows OS helps.
 +
 
 +
== Hudson Job at Eclipse ==
 +
The job at the Eclise Hudson server that performs this build is https://hudson.eclipse.org/mat/.
 +
 
 +
The job is configured to sign the plugins and features in the update site, and to upload all artifacts to the download server.
 +
One can download such nightly/snapshot builds here: http://www.eclipse.org/mat/snapshotBuilds.php
 +
 
 +
Info: Signing is activated by the build-server profile (i.e. with parameter '-P build-server' added to the maven command)
 +
 
 +
[[Category:Memory Analyzer]]

Revision as of 09:22, 14 December 2015

Introduction

This page describes how Memory Analyzer can be built using Maven/Tycho. The build will

  • build all bundles and features
  • execute all tests
  • (optional) run FindBugs static checks
  • produce a p2 repository with MAT features
  • produce RCPs for different platforms
  • sign and upload the produced artifacts (when executed on the Eclipse Hudson server)

Prerequisites

Git

MAT sources are in a Git repository, therefore you need a git client.

Maven Installation

The Memory Analyzer build requires a Maven 3.0.* installation. It is already present on the Hudson server at Eclipse. For local build one can download it from here.

Proxy Settings

If you need to set a proxy for Maven, a snippet like this can be added to the Maven settings file:

  <proxies>
    <proxy>
      <active>true</active>
      <protocol>http</protocol>
      <port>8080</port>
      <host>myproxy_host</host>
      <nonProxyHosts>non_proxy_hosts</nonProxyHosts>
    </proxy>
  </proxies>

More information on Maven settings: http://maven.apache.org/ref/3.0.3/maven-settings/settings.html

Checkout MAT Sources from Git

Have a look at MemoryAnalyzer/Contributor_Reference#Get the source

Building MAT

Execute the build

  • Open a console and go into the <mat_src>/parent folder (there is the parent pom.xml)
  • To build MAT execute
mvn clean install
  • To build MAT and perform FindBugs checks execute
mvn clean install findbugs:findbugs

Where to find the results?

You can find the results of the build in the corresponding .../target/ directories for each plugin, feature, etc... Of particular interest are:

  • <mat_src>/org.eclipse.mat.updatesite/target/site/ - it contains a p2 repository with MAT features
  • <mat_src>/org.eclipse.mat.product/target/products/ - it contains all standalone RCP applications

Further Information

  • The platforms for which RCPs are built are specified in the <mat_src>/parent/pom.xml file

Known Problems

Wrong file permissions

When building MAT on a Windows box, the RCPs for any other OS will not have the proper permissions (e.g. the executables won't have the x flag). Building under Linux or other non-Windows OS helps.

Hudson Job at Eclipse

The job at the Eclise Hudson server that performs this build is https://hudson.eclipse.org/mat/.

The job is configured to sign the plugins and features in the update site, and to upload all artifacts to the download server. One can download such nightly/snapshot builds here: http://www.eclipse.org/mat/snapshotBuilds.php

Info: Signing is activated by the build-server profile (i.e. with parameter '-P build-server' added to the maven command)

Back to the top