-
Notifications
You must be signed in to change notification settings - Fork 193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tycho-p2-director:director: Fix handling of destination on macOS #3549
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we probably have a new testcase instead of adjusting the existing one? Both "variants" should work in my opinion.
Test Results 591 files 591 suites 4h 31m 50s ⏱️ Results for commit ffd4114. ♻️ This comment has been updated with latest results. |
9cb87f7
to
40dd605
Compare
40dd605
to
361fd98
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this, this looks good in general just some small remarks.
tycho-p2-director-plugin/src/main/java/org/eclipse/tycho/plugins/p2/director/DirectorMojo.java
Outdated
Show resolved
Hide resolved
...in/src/main/java/org/eclipse/tycho/surefire/provisioning/ProvisionedInstallationBuilder.java
Show resolved
Hide resolved
@sratz I plan to do a bugfix release maybe end of month, do you think we can include this one here? |
Yes, I think that should be possible, I am currently looking for a solution to this issue again. |
361fd98
to
5f363fa
Compare
I thought about this some more and changed the pull request again to what you initially proposed in the issue. The processing of I think the benefits of applying this in some standard scenario (e.g. https://github.com/eclipse-tycho/tycho/blob/d23230d9ea1c03e64184f3c69bfe69499e815ef8/tycho-its/projects/surefire.p2InstalledRuntime/extProductTestDirector/pom.xml) outweigh the fact that I tried to document these peculiarities of path name handling in the mojo parameter descriptions. |
5f363fa
to
95b912e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine and tests are green, @sratz if you are happy with that let me know and I'll put this on the merge train!
I have one more question: I am trying to understand the intention behind the Line 700 in 95b912e
Was the idea to run the director N times and install IUs for all platforms into the same product/installation? Has this ever worked? The way I see it, the environment options (os/ws/arch) end up in the director call inside the tycho/tycho-core/src/main/java/org/eclipse/tycho/p2tools/copiedfromp2/DirectorApplication.java Lines 824 to 844 in c66c628
So AFAIK I am asking here, because if we could remove that option, it would simplify the handling of the target env even more inside From what I can tell |
Yes but I think it was actually in the end not that useful.
the difference is if you have native fragments, you can install all of them while this si not possible with one classic call.
Yes I think we can remove that option. |
When I follow the information flow of os/ws/arch, I don't see how that would've ever worked in practice:
And then inside tycho/tycho-core/src/main/java/org/eclipse/tycho/p2tools/copiedfromp2/DirectorApplication.java Lines 824 to 844 in c66c628
So, the first
Ok, then I'll do that in a separate pull-request to clean things up. I think we can then merge this one. |
Yes the "key" was a new profile each time so they end up installed in the folder but as said in the end this was not really something useful at all...
Whatever you think fits best if it make things easier you can also do it in this PR. |
Then I'll do it here. Also keeps the discussions together in one issue/PR. |
* In DirectorMojo, the adjustment of 'destination' must consider the actual target environment (p2os/p2ws/p2arch parameters) that is to be installed and only fall back to the running environment if no explicit target environment is given. * Document in the tycho-p2-director:director JavaDoc / mojo parameter description that this intentionally deviates from the behavior of the stand-alone director application invocation: eclipse -application org.eclipse.equinox.p2.director -destination <destination> ... * In DirectorMojo, add a consistency check that p2os/p2ws/p2arch must all be specified mutually. * The helper methods in DirectorRuntime are extended, to properly handle all three possible scenarios: 1) /path/without/app/bundle/layout --> /path/without/app/bundle/layout/Eclipse.app/Contents/Eclipse 2) /path/to/real.app/Contents/Eclipse --> /path/to/real.app/Contents/Eclipse 3) /path/to/real.app --> /path/to/real.app/Contents/Eclipse This allows us to remove redundant code in ProvisionedInstallationBuilder. * This also removes the <installAllPlatforms> option again which was introduced in eclipse-tycho#3091 (606a087). This is not used in production and was not having the desired effect. This simplifies the handling in AbstractEclipseTestMojo / ProvisionedInstallationBuilder even more. Fixes eclipse-tycho#3548.
95b912e
to
ffd4114
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Many thanks!
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
No description provided.