Re: trouble with 2.16 installation
Jacques Garrigue <[email protected]> Sat, 25 Aug 2012 10:16:09 +0900
| Newsgroups | gmane.comp.lang.ocaml.lib.gtk |
|---|---|
| Message-ID | <[email protected]> |
On 2012/08/25, at 6:45, Bruno Guillaume wrote:
> On Aug 24, 2012, at 6:45 PM, Adrien wrote:
>
>> It's a bit weird that the filename ends in ".so". As far as I know, it
>> should be .dylib on your platform. Can you attach (or upload
>> somewhere) the full build log?
.so is fine.
OCaml dll support on OSX use bundles rather than usual dynamic libraries, for historical reasons.
>> Can you add -verbose to the invocation? It will give details.
>
> The second issue is still there. The command "ocamlfind ocamlc -verbose -package lablgtk2 test.ml"
>
> returns
>
> Effective set of compiler predicates: pkg_lablgtk2,autolink,byte
> + ocamlc.opt -verbose -I /opt/local/lib/ocaml/site-lib/lablgtk2 test.ml
> File "test.ml", line 1, characters 0-10:
> Error: Unbound module GMain
> ocamlc.opt returned with exit code 2
It looks like macports does something very strange.
It installs using the old-install target (i.e. without ocamlfind),
but masquerading the ocaml library directory as ocaml/site-lib
(i.e., the ocamlfind library directory).
Of course this means that things end up in strange places.
Using old-install, they should install in the default location.
And if they want to ensure ocamlfind compatibility they
can add a symbolic link to the ocaml/lablgtk2 directory.
But the worse part is not that: there is a typo,
and and the files (except META) end up in ocaml/site-libs,
which of course is ignored by everybody.
Short fix: in the Portfile replace
configure.args --with-libdir=${prefix}/lib/ocaml/site-libs \
by
configure.args --with-libdir=${ocamlfind_dir} \
Anybody knows who is the macport maintainer for lablgtk2?
It is marked as nomaintainer.
Jacques