Hi,
I think Alex covered it all from a general viewpoint so I'll just fill in answers for your specific questions.
> So as far as I understood we have 2 different builds systems ? One
is "Eclipse internal" one and the other is Maven (or Tycho over Maven).
Yes, "Eclipse internal" one is called PDE build. PDE build has one target platform per workspace, it has a built-in ECJ java compiler and a built-in Maven version. On the other hand, Tycho build uses whatever Maven instance you start, and had one target platform per maven module. Tycho also comes with it's own version of ECJ java compiler.
Dependencies are always resolved from target platform, which in case of Tycho may include both p2 and maven repositories, although one should strive to avoid dependencies not from p2 repos. In case of PDE, target platform may include p2 repositories as well as other eclipse installations. In order to add "org.apache.commons.exec" or any other bundle to the target platform, you should try to add a p2 repo with it to the target platform. Commons Exec happens to be available via Eclipse Orbit p2 repos (
https://www.eclipse.org/orbit/). If it wasn't you would have few alternatives: (1) use pom-first dependencies suggested by Alex, (2) add a jar to your project, (3) add source code to your project, or (4) make an OSGi bundle from the jar and publish it to a p2 repo.
> The next I do not understand where the repository actually is?
You probably already know how a Maven repos looks like on hard drive, so I'll skip this part. A p2 repository is usually two files: {content,compositeContent}.{jar,xml} and {artifacts,compositeArtifacts}.{jar,xml}. The first file is also called a metadata repo, and the second file is sometimes known as artifact repo. These two files usually lay next to each other and are accompanied by features/ and plugins/ folders which contain the actual jars. So, in the end of a day, when somebody refers to a p2 repo, they very often mean a directory with content.xml, artifacts.xml, features/ and plugins/. Also, I suggest you think of p2 as of rpm or dpkg system since it's more about managing various Installable Units (features, plugins, plugin fragments etc.) than just being a passive repository.
Finally, I haven't used m2e a lot, but I guess that when you run a maven goal it relies on Tycho, whereas PDE build is still used to resolve many dependencies in Eclipse editor. I think m2e integrates with PDE and may be able to configure it to a certain degree to resolve everything correctly but I'm not sure how well it works in practice since I don't have first-hand experience.