Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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: requires 'osgi.ee; (&(osgi.ee=JavaSE)(version=11))' but it could not be found #552

Closed
dwagelaar opened this issue Jan 21, 2022 · 0 comments
Milestone

Comments

@dwagelaar
Copy link

In order to build ATL against the latest Eclipse release plug-ins, I've started the effort to port it to JavaSE-11 (https://bugs.eclipse.org/bugs/show_bug.cgi?id=576366). Only a few changes were required in the source code, and I got ATL to build fairly quickly within the Eclipse IDE.

The tycho build is another matter, however. When updating to the latest tycho release (required for JavaSE-11), it spits out the following error:

[INFO] Computing target platform for MavenProject: org.eclipse.m2m.atl:org.eclipse.m2m.atl.emftvm:4.6.0-SNAPSHOT @ /home/dennis/Documents/Werk/Projects/org.eclipse.atl/plugins/org.eclipse.m2m.atl.emftvm/pom.xml
[ERROR] Cannot resolve target definition:
[ERROR]   Software being installed: org.eclipse.emf.sdk.feature.group 2.28.0.v20211110-0654
[ERROR]   Missing requirement: org.eclipse.core.jobs 3.12.0.v20210723-1034 requires 'osgi.ee; (&(osgi.ee=JavaSE)(version=11))' but it could not be found
[ERROR]   Cannot satisfy dependency: org.eclipse.core.runtime 3.24.0.v20210910-0750 depends on: osgi.bundle; org.eclipse.core.jobs [3.12.0,4.0.0)
[ERROR]   Cannot satisfy dependency: org.eclipse.emf.common.feature.group 2.24.0.v20210924-1718 depends on: org.eclipse.equinox.p2.iu; org.eclipse.core.runtime 0.0.0
[ERROR]   Cannot satisfy dependency: org.eclipse.emf.feature.group 2.28.0.v20211110-0654 depends on: org.eclipse.equinox.p2.iu; org.eclipse.emf.common.feature.group [2.24.0.v20210924-1718,2.24.0.v20210924-1718]
[ERROR]   Cannot satisfy dependency: org.eclipse.emf.sdk.feature.group 2.28.0.v20211110-0654 depends on: org.eclipse.equinox.p2.iu; org.eclipse.emf.feature.group [2.28.0.v20211110-0654,2.28.0.v20211110-0654]
[ERROR] 
[ERROR] Failed to resolve target definition /home/dennis/Documents/Werk/Projects/org.eclipse.atl/releng/org.eclipse.m2m.atl.releng.parent/tp/org.eclipse.m2m.atl.tp.target: See log for details -> [Help 1]

https://wiki.eclipse.org/Tycho/Dependency_Resolution_Troubleshooting suggests that the target definition is inconsistent. I've since been experimenting with target platform definitions, and adding "JavaSE-11" as targetJRE seems to solve the dependency resolution problems, but then switches the Java compiler to version 1.5 source level (@Override on interface methods, multi-catch not supported):

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:2.5.0:compile (default-compile) on project org.eclipse.m2m.atl.emftvm: Compilation failure: Compilation failure: 
[ERROR] /home/dennis/Documents/Werk/Projects/org.eclipse.atl/plugins/org.eclipse.m2m.atl.emftvm/src/org/eclipse/m2m/atl/emftvm/util/LazyOrderedSet.java:[1891] 
[ERROR] 	public void add(final int index, final E element) {
[ERROR] 	            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[ERROR] The method add(int, E) of type LazyOrderedSet<E> must override a superclass method
...
[ERROR] /home/dennis/Documents/Werk/Projects/org.eclipse.atl/plugins/org.eclipse.m2m.atl.emftvm/src/org/eclipse/m2m/atl/emftvm/impl/EmftvmFactoryImpl.java:[1662] 
[ERROR] 	} catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException
[ERROR] 				| NoSuchMethodException | SecurityException | ClassNotFoundException e) {
[ERROR] 	         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[ERROR] Multi-catch parameters are not allowed for source level below 1.7

The PR can be found at https://git.eclipse.org/r/c/mmt/org.eclipse.atl/+/189434

Does anyone have any idea what is going on?

P.S. I found #205, but that removing the target definition is the starting situation in this case.

@dwagelaar dwagelaar changed the title https://github.com/eclipse/tycho/issues/205 Tycho: requires 'osgi.ee; (&(osgi.ee=JavaSE)(version=11))' but it could not be found Jan 21, 2022
@eclipse-tycho eclipse-tycho locked and limited conversation to collaborators Jan 22, 2022
@laeubi laeubi converted this issue into discussion #554 Jan 22, 2022
@laeubi laeubi added this to the 2.7 milestone Feb 13, 2022

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants