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 "ETrice/Development/GettingStartedWithEtrice"

(New page: = Preconditions = Get the sources ( work with GIT repository ) and build them ( target platform ). = Getting Star...)
 
(Oomph eTrice Setup)
 
(54 intermediate revisions by 3 users not shown)
Line 1: Line 1:
= Preconditions =
+
= Oomph eTrice Setup =
Get the sources ([[ETrice/Development/Repository | work with GIT repository ]]) and build them ([[ETrice/Development/TargetPlatform | target platform ]]).
+
  
= Getting Started =
+
Prerequisites: Java 17 (for developers preferably a JDK).
 +
 
 +
1. Download and run [https://wiki.eclipse.org/Eclipse_Installer Oomph installer] in ''Advanced Mode''
 +
[[File:eTrice_oomph_advancedMode.png|thumbnail|upright|center]]
 +
 
 +
 
 +
2. Select desired Eclipse product + version, e.g. product ''Eclipse IDE for Eclipse Committer'' and version from build config in git: [http://git.eclipse.org/c/etrice/org.eclipse.etrice.git/tree/releng/org.eclipse.etrice.parent/pom.xml Tycho/Maven pom.xml]
 +
 
 +
3. Optional for commiters: set your git ssh key
 +
[[File:eTrice_oomph_etrice_ssh.png|thumbnail|upright|center]]
 +
 
 +
 
 +
4. Download the eTrice setup file [http://git.eclipse.org/c/etrice/org.eclipse.etrice.git/plain/team/ETrice.setup ETrice.setup] and add & select it in the oomph catalog
 +
[[File:eTrice_oomph_eTriceSetup.png|thumbnail|upright|center]]
 +
 
 +
 
 +
6. Configure your personal installation
 +
[[File:eTrice_oomph_etriceConfig.png|thumbnail|upright|center]]
 +
 
 +
 
 +
TODO: add eTrice to official Eclipse catalog
 +
 
 +
= Local Build and Tests =
 +
 
 +
Once you performed the above steps and have checked 'Build Automatically' Eclipse PDE will do the build for you and you will be able to launch a runtime workbench containing the eTrice plug-ins.
 +
 
 +
Junit based tests can be launched directly from Eclipse as usual.
 +
 
 +
However, there are also end-to-end tests for the generators which have to be executed using Gradle. In order to do so you can e.g. execute Gradle from a command shell. On windows it is recommended to substitute the root directory of the eTrice sources with a drive letter (<code>subst X: C:/path/to/etrice/sources</code>).
 +
 
 +
Then execute
 +
 
 +
<code>
 +
gradle --rerun-tasks clean build
 +
</code>
 +
 
 +
To execute a single test, e.g. for runtime.c, excute
 +
 
 +
<code>
 +
gradlew.bat tests:org.eclipse.etrice.runtime.c.tests:build
 +
</code>
 +
 
 +
This will compile, link and execute the tests and finally convert the etu result into an xUnit xml file.
 +
 
 +
= Linux =
 +
 
 +
After cloning in Linux you will need to make gradlew executable
 +
 
 +
<code>
 +
chmod u+x gradlew
 +
</code>
 +
 
 +
and convert the line endings from DOS to Unix style
 +
 
 +
<code>
 +
sed -i.bak 's/\r$//' gradlew
 +
</code>
 +
 
 +
[[Category:eTrice]]

Latest revision as of 09:01, 24 August 2023

Oomph eTrice Setup

Prerequisites: Java 17 (for developers preferably a JDK).

1. Download and run Oomph installer in Advanced Mode

ETrice oomph advancedMode.png


2. Select desired Eclipse product + version, e.g. product Eclipse IDE for Eclipse Committer and version from build config in git: Tycho/Maven pom.xml

3. Optional for commiters: set your git ssh key

ETrice oomph etrice ssh.png


4. Download the eTrice setup file ETrice.setup and add & select it in the oomph catalog

ETrice oomph eTriceSetup.png


6. Configure your personal installation

ETrice oomph etriceConfig.png


TODO: add eTrice to official Eclipse catalog

Local Build and Tests

Once you performed the above steps and have checked 'Build Automatically' Eclipse PDE will do the build for you and you will be able to launch a runtime workbench containing the eTrice plug-ins.

Junit based tests can be launched directly from Eclipse as usual.

However, there are also end-to-end tests for the generators which have to be executed using Gradle. In order to do so you can e.g. execute Gradle from a command shell. On windows it is recommended to substitute the root directory of the eTrice sources with a drive letter (subst X: C:/path/to/etrice/sources).

Then execute

gradle --rerun-tasks clean build

To execute a single test, e.g. for runtime.c, excute

gradlew.bat tests:org.eclipse.etrice.runtime.c.tests:build

This will compile, link and execute the tests and finally convert the etu result into an xUnit xml file.

Linux

After cloning in Linux you will need to make gradlew executable

chmod u+x gradlew

and convert the line endings from DOS to Unix style

sed -i.bak 's/\r$//' gradlew

Back to the top