-
Notifications
You must be signed in to change notification settings - Fork 0
Use Tycho 3 #15
Comments
@LorenzoBettini we need to create toolchains xml locally and on ci. we also need to do something to run the same build with java 11 and java 17 |
@cdietrich why are we still building with Java 11? (just to understand). |
we use r202203 as minimal target and this one still supports java 11 and so to make sure we dont use any java 17 api we stick to that. and yes we can pass the tycho version as long as the poms are equivaltent the problem is: i have no toolchain experience so i cannot tell how easy it can be set up and switched so that the same build runs with multiple java versions |
@cdietrich for avoiding using Java 17 API it is a matter of using the Indeed, I did not mean to set up the toolchain to use different Java versions; I meant use Java 17 and Tycho 3.0.4 by default and use Java 11 passing the Tycho version on the command line for the minimal target platform. |
but can we then use the ci friendly version feature? |
If I understand the CI friendly version feature you mentioned (https://tycho.eclipseprojects.io/doc/master/TychoCiFriendly.html), I think that would not still help us for the timestamp in the OSGI bundles and different POM versions without qualifiers. If I understand the CI friendly mechanism correctly, that only allow you to specify versions for released POMs and OSGI from the command line without modifying POMs and MANIFESTs. That's cool, but I guess it still relies on the versions always to be exactly the same in OSGIs and POMs, which is not what we want. From what I read in that URL, Maybe we should ask people from Tycho? I'd like to switch to Tycho 3.x because I am more worried about delaying the switch to Tycho 3 too much ;) |
hmm the i completely missunderstood the ci friendly versions feature. i understood it allows the qualifier vs milestone feature ootb |
did some experiments. so it allows to do a mvn clean install -Dqualifier=.M1 but it seems to produce and even complains about that org.osgi.framework.BundleException: Invalid manifest header Bundle-Version: "1.0.0.M1.202303201403" : invalid version "1.0.0.M1.202303201403": invalid qualifier "M1.202303201403" |
i will start a tycho discussion |
created eclipse-tycho/tycho#2261 |
From what I understand CI friendly means that you can change the version and the qualifier without changing the sources, just passing a property at the command line. As I suspected, it cannot work in our case because we want a bundle version different from the POM version during releases and milestones. |
@cdietrich Concerning my comment #15 (comment) does it sound good? It should address our use cases if I understand them correctly. |
i assume yes. but i still dont understand how we switch between
but this is cause i am a complete noob so your assumption is the poms will work with both tycho 3 and 2 maybe i am extra confused cause the default is java 11 and tycho 2 |
@cdietrich I was proposing something even simpler: build with Java 11 against a Java 11 release with Tycho 2.x (because Tycho 3 requires Java 17). By default, with Java 17 with Tycho 3.x. |
so we would switch the default from current state. am not sure how pr validating friendly this is (default build wont detect too new api used) |
@cdietrich yes, the default would be the latest versions. Yes, API violations would be detected only when building with Java 11. However, using the |
ok |
with tycho 4 we might also profit from this one |
mh... but that would not solve our problem to have |
@LorenzoBettini i understood it would support 2.31.0-M1 and 2.31.0.v2023 |
seems to work with @laeubi @LorenzoBettini you can find my experiments at |
@cdietrich with your experiment what's the result? The 'v' is something that we usually specify in the format of tycho-packaging-plugin; in your POM there's no such a configuration so you end up with the default timestamp format |
The result is that at first glance it seems to work |
Great! So for the 'v' you just have to specify the format correctly in the configuration of tycho-packaging-plugin <configuration>
<format>'v'yyyyMMdd-HHmm</format> |
thx for the hint @LorenzoBettini |
@cdietrich Is Maven 3.8.7 required? I can't get it working
|
@LorenzoBettini release notes from tycho say Maven 3.8.5 |
@LorenzoBettini i had to build and install it locally |
@LorenzoBettini using custom settings xml seems to work. pushed that |
It seems you sorted that out already, yes a settings.xml is currently the only way to do it because this is loaded before the project is even parsed see: |
thx for downporting to 3.0.5 @laeubi |
@cdietrich In eclipse-xtext/xtext#2135 (comment) you were mentioning that the toolchain is complex with Tycho 3, could you please give more details?
I've opened this issue not to fill the other issue too much.
The text was updated successfully, but these errors were encountered: