Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trouble compiling #36

Open
deliciouslytyped opened this issue Apr 7, 2019 · 5 comments
Open

Trouble compiling #36

deliciouslytyped opened this issue Apr 7, 2019 · 5 comments

Comments

@deliciouslytyped
Copy link

I'm having trouble compiling this repository for Frege/frege#375 , what's the correct way to do it?
Are there binary JARs somewhere that I just didn't notice?
If there are binaries, I will still want to build from source after I get that to work though.

I tried using gradle --no-daemon jar which failed

  • complaining about missing Frege packages
    • I patched :frege-interpreter-java-support:compileJava to look for a local Frege JAR
  • now:
    Execution failed for task ':frege-interpreter-core:compileFrege'.
     > Could not find matching constructor for: org.gradle.process.internal.DefaultJavaExecAction(org.gradle.api.internal.file.BaseDirFileResolver)
    
@deliciouslytyped
Copy link
Author

deliciouslytyped commented Apr 7, 2019

I'm using a recent gradle, the latest Frege release (3.25.84), and a checkout of this repo, and jdk11.

@mmhelloworld
Copy link
Member

Hi @deliciouslytyped ,

There was an issue with the build. A local Frege compiler path had been added as a dependency. I have fixed that issue and few other things for 3.24 compiler. The build is now passing.

@deliciouslytyped
Copy link
Author

Thanks a bunch! I'll try to check it out later.

@subes
Copy link

subes commented Feb 28, 2024

Hi,

it seems the latest version is not compatible to frege ?2.24.405?. Using latest master from frege repo so that it hopefully works in Java 17 as described here: https://github.com/Frege/frege/releases/tag/3.24public
Sadly the latest version does not include a jsr223 ScriptEngine as it seems. :(

Following this guide: https://github.com/Frege/frege/wiki/Contributing-to-Frege#my-dist-artefact-does-not-contain-the-repl-how-comes

I get the following error:

Making dist
test -d ../frege-interpreter/ && test -d ../frege-repl/ && test -f lib/jline-2.14.6.jar && time /usr/lib/jvm/java-11-openjdk/bin/java -Dfrege.javac=internal -Xss2m -cp build:lib/jline-2.14.6.jar frege.compiler.Main -d build -O -target 1.8 -make  -sp .:../frege-repl/frege-repl-core/src/main/frege:../frege-repl/frege-repl-nativedeps/src/main/java/:../frege-interpreter/frege-interpreter-core/src/main/frege:../frege-interpreter/frege-interpreter-java-support/src/main/java/ frege.Starter
calling: internal -nowarn -source 1.8 -target 1.8 -cp build:lib/jline-2.14.6.jar:build -d build -sourcepath .:../frege-repl/frege-repl-core/src/main/frege:../frege-repl/frege-repl-nativedeps/src/main/java/:../frege-interpreter/frege-interpreter-core/src/main/frege:../frege-interpreter/frege-interpreter-java-support/src/main/java/ -encoding UTF-8 ../frege-interpreter/frege-interpreter-java-support/src/main/java/frege/interpreter/javasupport/CompilationInfo.java 
calling: internal -nowarn -source 1.8 -target 1.8 -cp build:lib/jline-2.14.6.jar:build -d build -sourcepath .:../frege-repl/frege-repl-core/src/main/frege:../frege-repl/frege-repl-nativedeps/src/main/java/:../frege-interpreter/frege-interpreter-core/src/main/frege:../frege-interpreter/frege-interpreter-java-support/src/main/java/ -encoding UTF-8 ../frege-interpreter/frege-interpreter-java-support/src/main/java/frege/interpreter/javasupport/InterpreterClassLoader.java 
calling: internal -nowarn -source 1.8 -target 1.8 -cp build:lib/jline-2.14.6.jar:build -d build -sourcepath .:../frege-repl/frege-repl-core/src/main/frege:../frege-repl/frege-repl-nativedeps/src/main/java/:../frege-interpreter/frege-interpreter-core/src/main/frege:../frege-interpreter/frege-interpreter-java-support/src/main/java/ -encoding UTF-8 ../frege-interpreter/frege-interpreter-java-support/src/main/java/frege/interpreter/javasupport/MemoryJavaCompiler.java 
calling: internal -nowarn -source 1.8 -target 1.8 -cp build:lib/jline-2.14.6.jar:build -d build -sourcepath .:../frege-repl/frege-repl-core/src/main/frege:../frege-repl/frege-repl-nativedeps/src/main/java/:../frege-interpreter/frege-interpreter-core/src/main/frege:../frege-interpreter/frege-interpreter-java-support/src/main/java/ -encoding UTF-8 build/frege/repl/Gui.java 
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:649: Non
    pure native type ClassLoader must be MutableIO ClassLoader
    in IO actions.
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:647: Non
    pure native type ClassLoader must be MutableIO ClassLoader
    in IO actions.
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:137: type error in expression
    urlClassLoader
    type is : URLClassLoader
    expected: MutableIO URLClassLoader
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:137: type error in expression
    urlClassLoader
    type is : URLClassLoader
    expected: MutableIO URLClassLoader
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:675: Non
    pure native type StringWriter must be MutableIO StringWriter
    in IO actions.
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:675: Non
    pure native type StringWriter must be MutableIO StringWriter
    in IO actions.
E ../frege-interpreter/frege-interpreter-core/src/main/frege/frege/interpreter/FregeInterpreter.fr:507: type error in expression
    src
    type is : StringWriter
    expected: Mutable t1 StringWriter
Interpreter.FregeInterpreter: build failed because of compilation errors.
Repl.FregeRepl: build failed because module `Interpreter.FregeInterpreter` not built.
frege.Starter: build failed because module `Repl.FregeRepl` not built.
Build failed.

@subes
Copy link

subes commented Feb 28, 2024

Reverting this commit fixes the issue: f14bdbe

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants