Skip to content

lambda's in files on bootclasspath #21

Closed
@johanvos

Description

@johanvos

First of all, thanks for this great project.
I'm trying to apply retrolambda to the OpenJFX codebase containing the JavaFX classes. Currently, the Android port of OpenJFX uses a backported version of the JavaFX sources, and we're now trying to build everything from the latest OpenJFX sources.
The issue I have is that the JavaFX files we try to de-lambdafy are also in the boot classpath (they are in jre/lib/ext/jfxrt.jar). If I remove jfxrt.jar from the Java 8 SDK, the retrolambda process works fine.

However, when jfxrt.jar is present, there are issues since the JavaFX class files can be loaded by 2 classloaders (system classloader and the classloader scanning the retrolambda.inputDir). I tried to bypass this by prepending the bootclasspath with the javafx classes we want to process, e.g.:
java -Xbootclasspath/p:in -Dretrolambda.inputDir=in -Dretrolambda.outputDir=out -Dretrolambda.classpath=in -javaagent:retrolambda.jar -jar retrolambda.jar

But that doesn't work since the classes are then ignored, since LambdaSavingClassFileTransformer.transform() will skip classes on the System classloader

More info on this issue is available at
http://mail.openjdk.java.net/pipermail/openjfx-dev/2014-June/014217.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions