You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Matt Sicker (Jira)" <ji...@apache.org> on 2021/07/11 23:32:00 UTC
[jira] [Commented] (MCOMPILER-461) Compile fails when class
references a class generated by an annotation processor and
module-info.java is present
[ https://issues.apache.org/jira/browse/MCOMPILER-461?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17378812#comment-17378812 ]
Matt Sicker commented on MCOMPILER-461:
---------------------------------------
These error messages don't even help explain what failed, where, why, or really any reason why it failed besides telling me to go fuck myself. What is up with this issue?
> Compile fails when class references a class generated by an annotation processor and module-info.java is present
> ----------------------------------------------------------------------------------------------------------------
>
> Key: MCOMPILER-461
> URL: https://issues.apache.org/jira/browse/MCOMPILER-461
> Project: Maven Compiler Plugin
> Issue Type: Bug
> Affects Versions: 3.8.1
> Environment: MacOS 10.15.7.
> Maven home: /opt/maven/maven
> Java version: 11.0.10, vendor: Amazon.com Inc., runtime: /Library/Java/JavaVirtualMachines/amazon-corretto-11.jdk/Contents/Home
> Default locale: en_US, platform encoding: UTF-8
> OS name: "mac os x", version: "10.15.7", arch: "x86_64", family: "mac"
> Reporter: Ralph Goers
> Priority: Major
> Attachments: mvn.txt
>
>
> While trying to convert Log4j-core to a JPMS module I have run into an issue where I have a class that references a class that is generated by Log4j's annotation processor and that class gets an error saying the referenced class cannot be found. However, after the compile fails I can see that the file was generated.
> To reproduce:
> git clone [https://github.com/apache/logging-log4j2.git
> ]cd logging-log4j2
> git checkout module-compile-fails
> mvn clean install
> The compile will fail in log4j-core. Some appear to be errors in javac for which I have opened an issue with openjdk. But if I do "mvn -X clean install" and copy the compile command line and prepend it with javac when it runs I no longer see
> [ERROR] /Users/rgoers/projects/apache/logging/log4j/logging-log4j2/log4j-core/src/main/java/org/apache/logging/log4j/core/osgi/Activator.java:[29,44] error: cannot find symbol symbol: class Log4jPlugins location: package org.apache.logging.log4j.core.plugins
> which indicates that Maven is somehow causing that.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)