Coder Social home page Coder Social logo

Can't build from source about ocamljava HOT 4 OPEN

xclerc avatar xclerc commented on June 10, 2024
Can't build from source

from ocamljava.

Comments (4)

xclerc avatar xclerc commented on June 10, 2024

It looks like it fails when trying to link the first .jar file.
Could you try to use ocamljava.opt on an empty .ml
file to check whether this is indeed the problem?

from ocamljava.

Vertmo avatar Vertmo commented on June 10, 2024

Compiling an empty program does work without any issue. I think the problem may be coming from the patch applied to the ocamlbuild source before ocamlbuild is compiled (as it does touch the Options module), but I can't find how the original ocamlbuild source is downloaded.
When blocking said patch (by commenting out lines 30 and 46 in compiler/ocamlbuild/Makefile-ocamljava) the compilation of ocamlbuild works successfully, but the next step fails, as the unpatched version of ocamlbuild can't handle building .cmja targets.
Maybe the changes made to ocamlbuild since the last change to ocamljava have broken something ?

from ocamljava.

xclerc avatar xclerc commented on June 10, 2024

Indeed, it looks like there is something broken with the
bootstrap of ocamlbuild. However, the problem should
not come from changes made to ocamlbuild since its
sources are vendored.

I wonder whether the problem could come from failing to
load Java elements. Which version of Java are you using?

from ocamljava.

Vertmo avatar Vertmo commented on June 10, 2024

I was trying with Java 8 (openjdk version "1.8.0_192"),
With Java 7 (openjdk version "1.7.0_171") the error is a bit different:

+ /home/vertmo/.opam/ocj2/bin/ocamljava.opt -c -annot -w L -w R -w Z -java-package ocaml.tools.ocamlbuild -for-pack Ocamlbuild_pack -o plugin.cmj plugin.ml               
File "plugin.ml", line 1:                                                                                                                                                 
Error: Java error:                                                                                                                                                        
unable to write data                                                                                                                                                      
Command exited with code 2.

It still happends during the ocamlbuild step tough.

from ocamljava.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.