Skip to content

color compilation #4

Description

@tomsib2001

When trying to compile color.ml using the proposed command with Ocaml 4.02.1 or Ocaml 4.02.3

make color.opt

I get the error

ocamlopt.opt -o color.opt -g -annot  -I +ocamlgraph unix.cmxa graphics.cmxa graph.cmxa combine.cmxa color.ml
File "color.ml", line 25, characters 5-10:
Error: Unbound module Graph
make: *** [color.opt] Erreur 2

But the issue here is not my installation of ocamlgraph, as if I create a file toto.ml with just

open Graph

and compile it using

ocamlbuid -package ocamlgraph toto.native

the log says

### Starting build.
# Target: toto.ml.depends, tags: { extension:ml, file:toto.ml, ocaml, ocamldep, quiet }
/home/thomas/.opam/4.02.3/bin/ocamldep.opt -modules toto.ml > toto.ml.depends
# Target: toto.cmo, tags: { byte, compile, extension:cmo, extension:ml, file:toto.cmo, file:toto.ml, implem, ocaml, quiet }
/home/thomas/.opam/4.02.3/bin/ocamlc.opt -c -I /home/thomas/.opam/4.02.3/lib/ocamlgraph -o toto.cmo toto.ml
# Target: toto.cmx, tags: { compile, extension:cmx, extension:ml, file:toto.cmx, file:toto.ml, implem, native, ocaml, quiet }
/home/thomas/.opam/4.02.3/bin/ocamlopt.opt -c -I /home/thomas/.opam/4.02.3/lib/ocamlgraph -o toto.cmx toto.ml
# Target: toto.native, tags: { dont_link_with, extension:native, file:toto.native, link, native, ocaml, program, quiet }
/home/thomas/.opam/4.02.3/bin/ocamlopt.opt -I /home/thomas/.opam/4.02.3/lib/ocamlgraph /home/thomas/.opam/4.02.3/lib/ocamlgraph/graph.cmxa toto.cmx -o toto.native
# Compilation successful.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions