Setting Eclipse compiler options (ignoreUnnamedModuleForSplitPackage)
已回答
Hey,
I am required to build my project using the Eclipse compiler. I am having a “split package” problem in my project, as discussed e.g. here. The compiler throws errors such as
java: The package org.xml.sax is accessible from more than one module: <unnamed>, java.xml
Eclipse eventually introduced an option to ignore this case and it seems to be enabled by default.
Upon recommendation, I tried setting “Additional command-line parameters” to `-properties /home/ben/git-repositories/intellij-sdk-setup/intellij-project-setup/eclipse-compiler.prefs` where the prefs file contains
org.eclipse.jdt.core.compiler.ignoreUnnamedModuleForSplitPackage=enabled
However, this does not seem to have any effect.
Would appreciate any help.
Best,
Ben
请先登录再写评论。
Hello, Ben!
Thank you for reporting this!
Have you also specified the path to ECJ in IDEA's Compiler Settings or does it use the bundled one?
If it is the bundled one, it may not pick up the
prefs
configuration.Do the errors prevent the build from completing successfully?
IDEA has the “Proceed on errors" option enabled by default for the Eclipse Compiler and “Build, no error check” option for the Run Configurations, do you have those enabled?
Hey, thanks for the reply.
I have tried with either and it did not seem to be picked up.
Thanks for the workaround hint.
Benjamin Moser
I'm assuming you're referring to the ECJ options, correct?
Have you managed to workaround the issue with the options IDEA provides (“Proceed on errors", “Build, no error check”)?