Seeking Guidance on Compiling an OCaml Program

Hi all,

I am trying to compile a basic program using the Ocaml language in the mina folder.However, I don’t know how to proceed with the compilation process. Could you please suggest a valid document link or provide a GitHub repository code for reference? I have attached a screenshot of my project to this post.

Thanks in Advance,

You should start from reading this: Quickstart — Dune documentation

Hi @Kakadu ,

Thank you for your response.
I have successfully run the project and obtained the desired output. However, I need guidance on the build and execution commands to use within the mina folder. I encountered an error when attempting to execute them. Could you please provide me with the correct commands? I have also attached a screenshot to this message.
Simple dune project screenshot.

Thank you in advance.

dune said explicitly in the log what you need to do.

Hi @kakadu,

I just want to compile and run my ML file using Dune inside the Mina code. The Mina link is: (mina/src/nonconsensus at develop · MinaProtocol/mina · GitHub).

Please let me know if it is possible or not.

Thanks in Advance.

It looks like you added a mina executable in the dune file of the project that is conflicting with the main library name. Rather than adding an unrelated executable in the root of the directory, I would advise to create a new directory, and use a non-conflicting name. It could be also simpler to use the library in a completely separated project.