Questions tagged [ocamlfind]

Findlib is a library manager for Objective Caml. It provides a convention how to store libraries, and a file format ("META") to describe the properties of libraries. There is also a tool (ocamlfind) for interpreting the META files, so that it is very easy to use libraries in programs and scripts.

Findlib is a library manager for Objective Caml. It provides a convention how to store libraries, and a file format ("META") to describe the properties of libraries. There is also a tool (ocamlfind) for interpreting the META files, so that it is very easy to use libraries in programs and scripts.

The information in META includes version string, compiler options for using the library, and dependencies on other libraries. Writing META files is straight-forward, and comes close to filling out a template.

The ocamlfind tool makes it very easy to use libraries from O'Caml programs. Basically, ocamlfind is a compiler driver that interprets some additional command-line switches for selecting libraries. It is also possible to use ocamlfind as query tool to extract data from the library base.

After years of development, Findlib is now the de-facto standard for library management in O'Caml. A lot of free software for O'Caml now requires that Findlib is available on the system. Distributions like GODI and Debian ensure that all libraries come with META files.

77 questions
1
vote
1 answer

Utop from Ocaml brew throws error

I have used ocamlbrew to install ocaml and associated utilities. I had one earlier installation also. As said in the documentation, I have used /opt for installing ocamlbrew. But when I run utop as a normal user, I am getting error Fatal error:…
user567879
  • 5,139
  • 20
  • 71
  • 105
1
vote
3 answers

How can I write a library in OCaml?

I am writing a bson encoder/decoder library in ocaml. I have the source file now (actually just one file). My question is that how should I make it as a library, such as ocaml-batteries-included, camomile, etc? I mean, people can use opam install…
Jackson Tale
  • 25,428
  • 34
  • 149
  • 271
1
vote
1 answer

install findlib error?

I downloaded findlib from http://download.camlcity.org/download/findlib-1.3.2.tar.gz. After configure successfully, make all reports: for p in findlib; do ( cd src/$p; make all ); done "Makefile", line 141: Could not find depend make: fatal errors…
z_axis
  • 8,272
  • 7
  • 41
  • 61
0
votes
1 answer

Ocamlfind cannot find package 'zmq'

I was trying to compile Ocaml tools as part of the Quantum Package 2. The error prompts me [2/3] Compiling OCaml tools make: Entering directory '/home/parallels/qp2/ocaml' ocamlbuild -j 0 -cflags "-g" -lflags "-g" -ocamlopt "opt -O3…
chikako
  • 1
  • 1
0
votes
0 answers

OCaml Type Matching Error of the project when building

I'm very new to OCaml and I need to build some project from the following https://github.com/janestreet/core_kernel.git. I try to compile the following source code, which named setup.ml (* OASIS_START *) open OASISDynRun;; open OASISTypes;; (*…
laurent01
  • 115
  • 8
0
votes
1 answer

How to transform the Yojson Library of Ocaml into a .byte file using js_of_ocaml?

I am trying to transform the Yojson with the source code download online into a byte file using js_of_ocaml. I try the following commands: %: ocamlfind ocamlc -package yojson -linkpkg -g -o yojson.cmo %: ocamlfind ocamlc -package js_of_ocaml…
0
votes
1 answer

Unbound module Findlib error when I was compilering a Ocaml file which contains "open Findlib"

I wrote a Ocaml file which only contains one line code: open Findlib,and then I save the file and named it for test.ml.In the Ocaml64(Ocaml for windows) environment ,I typed command ocamlc -o test test.ml,there is an error: Error:Unbound module…
Echo_Zero
  • 15
  • 3
0
votes
1 answer

Logistic Regression in OCaml

I was trying to use Logistic regression in OCaml. I need to use it as a blackbox for another problem I'm solving. I found the following site: http://math.umons.ac.be/anum/en/software/OCaml/Logistic_Regression/ I pasted the following code (with a few…
Anon
  • 381
  • 1
  • 2
  • 13
0
votes
1 answer

Failde to compile : ocamlfind: Package `xmlm' not found

I am trying to compile an OCaml .ml file with make command via command line remote machine but it shows me this error: + ocamlfind ocamlc -c -package xmlm -package unix -o pms.cmo pms.ml ocamlfind: Package `xmlm' not found Command exited with code…
0
votes
1 answer

How to get the version of a installed package using ocamlfind or opam?

In my configure script, I need to check the installed version of a package using ocamlfind or opam. How do I get this information?
anol
  • 8,264
  • 3
  • 34
  • 78
0
votes
1 answer

Unable to build using Ocamlbuild

I'm trying to build an OCaml project using ocaml build command which looks similar to ocamlbuild -use-ocamlfind test.byte Following error is observed. Error: Unbound value String.lowercase_ascii. I have install Clang and i am using OCaml 4.07.0
harin04
  • 271
  • 5
  • 16
0
votes
0 answers

Z3 Installation issue on windows 10

I am trying to install Z3 package(https://github.com/Z3Prover/z3.git) I ran the following commands ./configure cd build make make install Installation was successfull. However when i run Ocamlfind list z3 component is not listed. So when i try…
harin04
  • 271
  • 5
  • 16
0
votes
1 answer

How to compile a file that uses the JsooTop module?

I have this in a file named main.ml: let () = JsooTop.initialize () I tried compiling the file using: ocamlfind ocamlc -package js_of_ocaml -linkpkg -o main.byte main.ml But this error appears: File "main.ml", line 1, characters 9-27: Error:…
Flux
  • 9,805
  • 5
  • 46
  • 92
0
votes
1 answer

How to build a custom utop-based toplevel with ocamlbuild?

I want to create a utop-based toplevel for my project, which is built by ocamlbuild. However, ocamlbuild supports only mktoplevel, built from *.mltop. It doesn't mention utop anywhere in the docs. Also, the utop manual explains just toplevel…
vog
  • 23,517
  • 11
  • 59
  • 75
0
votes
1 answer

Required module 'Yojson' is unavailable without location

I am trying to build a simple program using Yojson: the main.ml file is just let () = exit 1; and an mod.ml file contains open Yojson open Yojson.Basic.Util let rec json_to_tree json = let _ = json |> member "key" in () I have a…
Bromind
  • 1,065
  • 8
  • 23