opalj / opal

https://www.opal-project.de
Other
51 stars 27 forks source link

Compiling the java test fixture failed #147

Closed mohPYdev closed 1 year ago

mohPYdev commented 1 year ago

I encountered a compilation error while trying to build the project. Here are the details:

environment:

I followed the instructions mentioned in your README file. the result of " sbt cleanBuild" is the following error:

log.txt

Error message: Compiling the java test fixture failed

errt commented 1 year ago

From your log, it is clear that Java 16 is now required to build the test fixtures. We will update the readme accordingly. Thanks for reporting.

Note that we are also using Scala 2.13(.11) now, but that should not be a problem as sbt should download the correct version automatically.

tillbecks commented 2 weeks ago

I encounter the same issue using Java 17, sbt 1.10.(1) and Scala 2.13.15.

errt commented 2 weeks ago

@tillbecks Can you provide your console output?

tillbecks commented 2 weeks ago

Yes of course: log.txt

errt commented 2 weeks ago

Your problem seems to be the spaces in your directory path. I can't easily see what encoding the Eclipse BatchCompiler would accept, but you could try replacing the toString in line 96 (and probably the implicit one in line 101) of org.opalj.javacompilation.FixtureCompileSpec with toURI

tillbecks commented 2 weeks ago

Just changing the path did the job for me! Thank you so much

errt commented 2 weeks ago

I thought so, but I would value a pull request to fix the FixtureCompiler not working with paths containing spaces, it is still a bug after all.