English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
batteries compilation error
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2009-09-04 (06:10)
From: Florent Monnier <fmonnier@l...>
Subject: Re: [Caml-list] batteries compilation error
> > > I don't see any "-I +camlp4" can you add it?
> >
> > if I run the command like this on the command line it passes right
> > but when I run again the make command it doesn't continue because
> > ocamlbuild complains about sanity violation
> > Anyway as it is for packaging purpose I will need to patch the Makefile,
> > the problem is that I don't see where to add this statement in the
> > Makefile:
> > http://git.ocamlcore.org/cgi-bin/gitweb.cgi?p=batteries/batteries.git;a=b
> >lob;f=Makefile.in;hb=HEAD
> >
> > (also I've search in the debian package, and it seems they haven't patch
> > the Makefile at all)
> If you are using ocamlbuild, then a -tag use_camlp4 could do the job.

I've added this tag to the OBFLAGS of the Makefile as below,
but there is still an error:

$ make all opt top syntax OBFLAGS="-tag use_camlp4"
ocamlbuild -tag use_camlp4 src/main/threads/batteries.cma 
src/main/threads/run.byte src/main/nothreads/batteries.cma 
src/main/nothreads/run.byte src/syntax/pa_openin/pa_openin.cmo 
src/syntax/pa_openin/pa_openin_r.cmo src/syntax/pa_where/pa_where.cmo 
src/syntax/pa_batteries/pa_batteries.cmo src/syntax/pa_strings/pa_strings.cma 
Finished, 1 target (0 cached) in 00:00:00.
+ ocamlfind ocamlmktop -I +camlp4 camlp4lib.cma 
src/batteries_toolchain/toplevel/cbtop.cmo -o 
File "_none_", line 1, characters 0-1:
Error: Error while linking /usr/lib/ocaml/camlp4/camlp4lib.cma(Camlp4):
Reference to undefined global `Dynlink'
Command exited with code 2.
make: *** [all] Error 10