Bug 837967 - java.lang.RuntimeException: Could not determine SWT implementation fragment bundle
Summary: java.lang.RuntimeException: Could not determine SWT implementation fragment b...
Keywords:
Status: CLOSED DUPLICATE of bug 844772
Alias: None
Product: Fedora
Classification: Fedora
Component: tycho
Version: 17
Hardware: i686
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Roland Grunberg
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-05 23:10 UTC by Orion Poplawski
Modified: 2012-08-10 20:20 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-10 20:20:49 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Orion Poplawski 2012-07-05 23:10:32 UTC
Description of problem:

Trying to build the eclipse PTP project via mvn-rpmbuild/tycho and getting:

Caused by: java.lang.RuntimeException: Could not determine SWT implementation fragment bundle
        at org.eclipse.tycho.p2.impl.resolver.ProjectorResolutionStrategy.fixSWT(ProjectorResolutionStrategy.java:143)

Now eclipse-swt is installed, and ptp seems configured to look for the various environments:

                        <plugin>
                                <groupId>org.eclipse.tycho</groupId>
                                <artifactId>target-platform-configuration</artifactId>
                                <version>${tycho-version}</version>
                                <configuration>
                                        <resolver>p2</resolver>
                                        <pomDependencies>consider</pomDependencies>
                                        <environments>
                                                <environment>
                                                        <os>linux</os>
                                                        <ws>gtk</ws>
                                                        <arch>x86</arch>
                                                </environment>
                                                <environment>
                                                        <os>linux</os>
                                                        <ws>gtk</ws>
                                                        <arch>x86_64</arch>
                                                </environment>
....

Not being at all familiar with tycho I don't know what else to check.  But it seems like this should be working.

Version-Release number of selected component (if applicable):
tycho-0.14.1-5.fc17.noarch
eclipse-swt-4.2.0-1.fc17.i686

Comment 1 Roland Grunberg 2012-07-23 14:17:48 UTC
I believe the issue is that you are listing multiple environments. Tycho will attempt to resolve the swt fragment for each of the environments. In a "normal" build, it can find these somewhere in the maven remote repositories it lists. but with a build in Fedora, you only have one particular eclipse-swt installed, and so it will complain about not finding the version for other architectures.

eclipse-cdt applies the following patch : http://pkgs.fedoraproject.org/gitweb/?p=eclipse-cdt.git;a=blob;f=eclipse-cdt-tycho-build.patch;h=9ff5d0fbd6a339ae6767df2a959ab4ff91cfd9e7;hb=refs/heads/master and then in %prep they set the architecture (http://pkgs.fedoraproject.org/gitweb/?p=eclipse-cdt.git;a=blob;f=eclipse-cdt.spec;h=06264591f727e45b669e9ea1c8c95bb3a6cbc24f;hb=refs/heads/master#l107)

Can you try something similar for your build and see if it resolves the issue?

Comment 2 Orion Poplawski 2012-08-03 23:24:27 UTC
Thanks a lot, that appears to work.

I'm now seeing lots of:

[WARNING] No explicit target runtime environment configuration. Build is platform dependent.

Do you know what that means?  Is my package no longer noarch?

Comment 3 Orion Poplawski 2012-08-03 23:27:09 UTC
One more question if you don't mind.  eclipse-ptp consists of two projects, PTP and photran.  PTP makes use of the photran code.  If I do:

cd photran
mvn-rpmbuild install
cd ../ptp
mvn-rpmbuild install

I get a dep error:

[ERROR] Cannot resolve project dependencies:
[ERROR]   Software being installed: org.eclipse.ptp.rdt.sync.ui.fortran 1.0.0.qualifier
[ERROR]   Missing requirement: org.eclipse.ptp.rdt.sync.ui.fortran 1.0.0.qualifier requires 'bundle org.eclipse.photran.cdtinterface 7.0.0' but it could not be found

How to I make the stuff in the photran build available to the ptp build?  Thanks!

Comment 4 Roland Grunberg 2012-08-07 14:27:26 UTC
In regards to Comment #2 : The message is just specifying that the build is dependent on the platform that you're currently running. (This is because you removed those <environments>). This is what you want though. When building noarch, the build should be based on the currently running system. Also, the work-around I suggested should no longer be needed as of 0.15.0-2.1 .

In regards to Comment #3 : This is a bug in tycho. It has been fixed in 0.15.0-1.1, so it is in rawhide.

Both the issues you have run into have been addressed in rawhide, but there's an update awaiting karma in bodhi, so if you'd like to try it out for f17 that would be great https://admin.fedoraproject.org/updates/FEDORA-2012-11197/tycho-extras-0.15.0-1.fc17,tycho-0.15.0-3.fc17?_csrf_token=ad5263a9f3a479e1071efa8109f3b0a1f86eb83a .

Comment 5 Orion Poplawski 2012-08-07 16:55:38 UTC
Indeed, looks good with 0.15.0-3.  Now I'm getting:

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-packaging-plugin:0.15.0:package-plugin (default-package-plugin) on project org.eclipse.ptp.rdt.core.remotejars: Error assembling JAR: /export/home/orion/fedora/eclipse-ptp/eclipse-ptp-6.0.1/org.eclipse.ptp-PTP_6_0_1/rdt/org.eclipse.ptp.rdt.core.remotejars/build.properties: bin.includes value(s) must be specified. -> [Help 1]

This looks like it may be an issue with PTP.  That build.properties file has:

custom = true

Thanks again for all the help.

Comment 6 Roland Grunberg 2012-08-10 20:20:49 UTC

*** This bug has been marked as a duplicate of bug 844772 ***


Note You need to log in before you can comment on or make changes to this bug.