Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » requires org.eclipse.equinox.p2.iu
requires org.eclipse.equinox.p2.iu [message #1841717] Wed, 26 May 2021 13:35 Go to next message
David Sun is currently offline David SunFriend
Messages: 45
Registered: July 2020
Member
I tried to using tycho to package eclipse product archive for my eclipse application.
The tycho throws the following errors:

[ERROR] Cannot resolve project dependencies:
[ERROR] Software being installed: EtaCATStudio 0.1.0
[ERROR] Missing requirement: EtaCATStudio 0.1.0 requires 'org.eclipse.equinox.p2.iu; com.mackerelpike.plc.ide.feature.feature.group 0.0.0' but it could not be found

--------------------------------------------------
I googled org.eclipse.equinox.p2.iu, But nothing found!
Can anyone tell me How to solve this problem?
Thanks!
Re: requires org.eclipse.equinox.p2.iu [message #1841723 is a reply to message #1841717] Wed, 26 May 2021 14:33 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
I answered this on the JDT forum. Note that "org.eclipse.equinox.p2.iu" in this context is a namespace. The thing after the namespace is the name. So it's the iu (installable unit) for the name com.mackerelpike.plc.ide.feature.feature.group that cannot be resolved. It is a feature and you must specify the p2 repository where it is located.

Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1861845 is a reply to message #1841723] Wed, 08 November 2023 04:03 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
can you show me url on the JDT forum or some snippets.
I had a similar problem.

The tips as follows:
Cannot complete the install because one or more required items could not be found.
Software being installed: RCP Product 1.0.0.202311080340 (wellcontrol 1.0.0.202311080340)
Missing requirement: RCP Product 1.0.0.202311080340 (wellcontrol 1.0.0.202311080340) requires 'org.eclipse.equinox.p2.iu; org.antlr.runtime [4.7.2.v20221112-0806,4.7.2.v20221112-0806]' but it could not be found

But I don't know where "4.7.2.v20221112-0806" came from

my tycho's version is <tycho.version>4.0.3</tycho.version>

Thank you

[Updated on: Wed, 08 November 2023 05:21]

Report message to a moderator

Re: requires org.eclipse.equinox.p2.iu [message #1861853 is a reply to message #1861845] Wed, 08 November 2023 08:12 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
Like this will help you find things you need:

https://wiki.eclipse.org/Eclipse_Oomph_Authoring#How_to_find_a_P2_repository_at_Eclipse_using_the_Repository_Explorer


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1861883 is a reply to message #1861853] Fri, 10 November 2023 01:48 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
I can see the version in https://download.eclipse.org/acceleo/updates/milestones/3.7
as in the attachments

How can I use it? add in the pom.xml?

	
<repository>
	<id>antlr</id>
	<layout>p2</layout>
	<url>https://download.eclipse.org/accceleo/updates/milestones/3.7</url>
</repository>


But the error has not been changed.
Cannot complete the install because one or more required items could not be found.
Software being installed: RCP Product 1.0.0.202311100121 (wellcontrol 1.0.0.202311100121)
Missing requirement: RCP Product 1.0.0.202311100121 (wellcontrol 1.0.0.202311100121) requires 'org.eclipse.equinox.p2.iu; org.antlr.runtime [4.7.2.v20221112-0806,4.7.2.v20221112-0806]' but it could not be found
[ERROR] [76a098d6-24a9-4b1b-a74d-cd406c8a9373][extension>org.eclipse.tycho:tycho-maven-plugin:4.0.3] Cannot complete the install because one or more required items could not be found.

Where is the iu should be installed?
How can I check the iu has been installed?




  • Attachment: snapshot.png
    (Size: 17.59KB, Downloaded 51 times)

[Updated on: Fri, 10 November 2023 02:09]

Report message to a moderator

Re: requires org.eclipse.equinox.p2.iu [message #1861887 is a reply to message #1861883] Fri, 10 November 2023 08:15 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
I don't know how you are setting up your target platform used in the build. You'd typically add it to your *.target file. Maybe this helps:

https://wiki.eclipse.org/Tycho/Target_Platform


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1861897 is a reply to message #1861887] Sat, 11 November 2023 06:47 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
Thank you for your reply again!

I add that repository in the <repositories> section of the POM.
And I noticed a pattern.

When I add the snippets
https://download.eclipse.org/acceleo/updates/milestones/4.0

the error will change to "'org.eclipse.equinox.p2.iu; org.antlr.runtime [4.10.1.v20230210-1433,4.10.1.v20230210-1433]' but it could not be found"

Why does the error reporting change when changing the repository? If the project is looking for version A artifacts, and I add a repository with version B, the error should not change!

In my project only 3.2.0 org.antlr.runtime is used, there is no place for version 4.7.2. It feels like this 4.7.2 is also coming from the referenced repository. i am very confused about this.

Or is there any way to manually add a dependency file on 4.7.2.

The attachment shows that there are antlr.runtime files of some versions in the local file system.

[Updated on: Sat, 11 November 2023 07:35]

Report message to a moderator

Re: requires org.eclipse.equinox.p2.iu [message #1861899 is a reply to message #1861897] Sat, 11 November 2023 08:55 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
That version of that bundle is in that repository. But given I have not the first clue how you have specified what should be in your target platform, there's not much I can say. Do you have a *.target file?

Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1861900 is a reply to message #1861899] Sat, 11 November 2023 11:01 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
Let me try to start at the beginning.

There is an existing complex OSGI project. I built another RCP project first, referencing some of the OSGI project's bundles.The RCP project is working fine, but when I want to export this RCP project into a package that can be run independently, something goes wrong.

Because exporting with PDE reports circular dependency issues, so I'm going to use tycho to package eclipse-plugin and then package eclipse-repository to achieve this. I think the step of packaging eclipse-plugin has been completed successfully. When packaging eclipse-repository(tycho-p2-director:4.0.3:materialize-products) it ran into the dependency problem mentioned before.

Only the large OSGI project has *.target, see the attachment for the contents of OSGI's target file.
if I need to use the jar file dependency when packaging, I add <repository></repository> in pom.xml to realize it.

In addition, I just packaged the three versions of org.antlr.runtime into the local P2 repository and registered them in pom.xml, and found that the result is the same as using the url on the line.
<repository>
        <id>antlr3</id> 
        <url>file:/C:\Users\chen\Desktop\repository</url>
        <layout>p2</layout>
</repository>


Can you provide some help? Thanks!

[Updated on: Sat, 11 November 2023 11:12]

Report message to a moderator

Re: requires org.eclipse.equinox.p2.iu [message #1861901 is a reply to message #1861900] Sat, 11 November 2023 11:27 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
Whatever its complaining is missing, add it to the *.target. Either with a default version which resolves to the highest available version:
<unit id="org.antlr.runtime" version="0.0.0"/>
or using an exact version. Verify in the target editor that the target platform resolves correctly.


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1862087 is a reply to message #1861901] Mon, 13 November 2023 01:57 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
Thanks Ed!

I've filled in the target with the corresponding snippet, and the taget editor is parsing properly, indicating that the unit of this version is perceived properly.
I also tried the version="0.0.0" method.

		<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
			<repository location="https://download.eclipse.org/acceleo/updates/milestones/3.7/S202304041222"/>
			<unit id="org.antlr.runtime" version="4.7.2.v20221112-0806"/>
		</location>


It has been confirmed that this target file has been set as active target platform.

But the reported error remains unchanged.

Relevant information is provided in the attachments
  • Attachment: target.png
    (Size: 39.46KB, Downloaded 78 times)
  • Attachment: error.png
    (Size: 15.64KB, Downloaded 35 times)

[Updated on: Mon, 13 November 2023 05:21]

Report message to a moderator

Re: requires org.eclipse.equinox.p2.iu [message #1862100 is a reply to message #1862087] Mon, 13 November 2023 08:54 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
It looks correct that way to me. So there must be some detail to your Tycho build that I don't know about. Is it properly using that *.target file in the Tycho build?

Ed Merks
Professional Support: https://www.macromodeling.com/
Re: requires org.eclipse.equinox.p2.iu [message #1862250 is a reply to message #1862100] Tue, 21 November 2023 01:20 Go to previous messageGo to next message
chen anjing is currently offline chen anjingFriend
Messages: 14
Registered: March 2023
Junior Member
Thanks, Dr. Merks
Eventually, inspired by you, the target-platform-configuration plugin was used to solve the problem.
But I'm still wondering why OSGI has so many ways of solving dependency problems, and why some work and some don't!
Re: requires org.eclipse.equinox.p2.iu [message #1863925 is a reply to message #1862250] Wed, 06 March 2024 16:34 Go to previous message
Florian Kellner is currently offline Florian KellnerFriend
Messages: 1
Registered: March 2024
Junior Member
> Eventually, inspired by you, the target-platform-configuration plugin was used to solve the problem.

How exactly were you able to solve the problem (if you are able to tell)? I am stuck at the same position (see discussion here: https://github.com/eclipse-tycho/tycho/discussions/3539), and switching to providing the repository in the target-platform.target did not fix anything for me
Previous Topic:Is there an easy way to install plugins?
Next Topic:p2.inf instructions don't use newly updated plugin, instead use the currently installed version
Goto Forum:
  


Current Time: Fri Apr 26 01:21:31 GMT 2024

Powered by FUDForum. Page generated in 0.05114 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top