How to deploy patched/updated SWT version? #2279
Replies: 3 comments 7 replies
-
I fear this can't be resolved easily, first you could try to not use the Next you should edit the swt fragment (if we assume its till compatible) to have a wider version range for the host and use that in your target, then the build should work. As an alternative you can try to simply use the full updated SWT version, not only a single fragment. |
Beta Was this translation helpful? Give feedback.
-
I tried with a custom/copied feature and included org.eclipse.swt, org.eclipse.swt.win32.win32.x86_64 in the target and removed the conrete versions in the feature (version = 0.0.0).
but the build fails with
but for me a boundary definition like "[3.116.0,4.0.0)" (in the fragment) should match the bundle org.eclipse.swt version "3.123.100.v20230322-1206" which exists in the target platform... Any ideas? |
Beta Was this translation helpful? Give feedback.
-
Ok with that change the sample project (and our's) seem to build fine. Conclusion:
Thanks for your help! bye Peter |
Beta Was this translation helpful? Give feedback.
-
Hi,
we are in the need to deploy a patched version of the SWT fragment org.eclipse.swt.win32.win32.x86_64.
We currently use the SWT release belonging to Eclipse 2022-06. The updated/patched fragment has version 3.123.100.v20230322-1206 (SNAPSHOT build version from CI build because not yet released) and it has the following constraint to the Host Bundle:
Fragment-Host: org.eclipse.swt;bundle-version="[3.116.0,4.0.0)"
which would basically work because the version of our current org.eclipse.swt in our target platform is 3.120.0.v20220530-1036. From within the IDE it is possible to launch the application with that swt version.
But I'm struggling on how to get that to build and update with p2.
What I tried was adding the new Fragment to the target and filtering out the current version. That does not work for multiple reasons:
the org.eclipse.e4.rcp feature includes (of course) the concrete current version of org.eclipse.swt.win32.win32.x86_64. So i had to remove the filtering of the target again
but then the build fails with
where 3.123.100 is the new updated version of org.eclipse.swt.win32.win32.x86_64.
I believe that may have to do with that org.eclipse.swt seems to have a p2.inf file which requires/enforces the exact same fragment version like the host bundle ...
My idea was to include the new version of the Fragment, require the installation by including this fragment into one of our bundles and hope that at runtime the newer version is used (like in the IDE).
But the build fails with
[ERROR] Only one of the following can be installed at once: [org.eclipse.swt.win32.win32.x86_64 3.123.100.v20230322-1206, org.eclipse.swt.win32.win32.x86_64 3.120.0.v20220530-1036]
because these Fragment's are singleton's.
Even if i would patch class files in the current jar p2 would not trigger an update since the version stay's the same.
Any ideas or hints on how to solve such a problem?
Thanks,
Bye Peter
Beta Was this translation helpful? Give feedback.
All reactions