[Omake] Re: Getting similar errors to previous posts
Todd Gardner
todd.gardner at gmail.com
Tue Aug 14 10:56:11 PDT 2007
Jason Hickey wrote:
> Todd,
>
> There seem to be two separate issues. For the link error:
>
>> - build . SimpleProg.opt
>> + ocamlfind ocamlopt -warn-error A -I . -o SimpleProg.opt testing.cmx
>> No implementations provided for the following modules:
>> Graphics referenced from testing.cmx
>
> you need to specify to use the graphics library (either graphics.cma or
> graphics.cmxa). Add the following line to your OMakefile.
>
> OCAML_OTHER_LIBS[] += graphics
I have this specified for my local build, but I thought by specifying
the use ocamldep, the build system would automatically pick up on the
dependencies within the standard library. My attempt here is more to get
a working prototype for a larger, more scalable build system, so I was
trying to get away from having to enter each of included libraries names
into the OMakefiles for each project. Is this possible?
>
> For the other problem,
>
>> It says that ocamldep understands modules, but ocamlfind apparently
>> invokes a version that doesn't:
>>
>> C:\ocamlmgw\bin>ocamldep -modules testing.ml
>> testing.ml: Graphics
>>
>> C:\ocamlmgw\bin>ocamlfind ocamldep -modules testing.ml
>> ocamldep: unknown option `-modules'.
>
> It sure seems like you have two versions of ocamldep on your system, and
> ocamlfind is using the other one. Try using the -verbose option, so
> ocamlfind will print what command it plans to execute.
>
> % ocamlfind ocamldep -verbose -modules testing.ml
> + ocamldep.opt -modules testing.ml
> % ocamldep.opt -modules testing.ml
> testing.ml: Graphics
>
I agree it is most likely running two versions, however:
C:\ocamlmgw\bin>ocamlfind ocamldep -version
ocamldep, version 3.10.1+dev0 (2007-05-21)
C:\ocamlmgw\bin>ocamldep -version
ocamldep, version 3.10.1+dev0 (2007-05-21)
That is a bit confusing: perhaps it forwards the version check with the
one I'd like it to use, and then uses some other one to do the actual
work. Regardless, I'm fairly certain it is a problem with
ocaml-mingw-maxi's findlib port, which leaves me either trying to get
OMake to code around it, or re-porting findlib. The former seems more
practical.
Here are the other commands you asked about, in case you are interested:
C:\ocamlmgw\bin>ocamlfind ocamldep -verbose -modules c:\testing.ml
ocamldep: unknown option `-modules'.
[ usage information snipped ]
C:\ocamlmgw\bin>ocamlfind ocamldep -verbose c:\testing.ml
+ ocamldep c:\testing.ml
C:\ocamlmgw\bin>ocamldep c:\testing.ml
C:\ocamlmgw\bin>ocamldep -modules c:\testing.ml
c:\testing.ml: Graphics
Todd Gardner
More information about the Omake
mailing list