问题
In Tycho there are two ways to define the target platform: a target file and the <repositories>
tag of the pom.xml. According to the manual, both can be used; they just have different drawbacks.
The target file is easy and straightforward, especially if you worked with Eclipse PDE before switching to Tycho.
What I don't get is how do you develop against a target definition defined in the pom.xml.
Dependencies are not added to a "Maven Dependencies" folder in the Java project, like they are for plain Maven projects. So Eclipse can't resolve them and your code doesn't even compile. And even if it does for some miracle reason... you cannot start a product or run tests.
All of this, because Eclipse needs a target platform to run. And the standard one (the plug-ins folder of Eclipse) is usually not the correct one for the project.
So how do you tell Eclipse that your target platform is defined in the pom.xml? How do you develop using only the <repositories>
tag?
来源:https://stackoverflow.com/questions/54143472/set-a-target-platform-for-pom-xml-based-repositories