Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Problem building O'Caml 3.03-alpha
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Jacques Garrigue <garrigue@k...>
Subject: Re: [Caml-list] Problem building O'Caml 3.03-alpha
From: Richard Nyberg <>

> I'm trying to build the 3.03-alpha release on FreeBSD 4.3 with tk
> but I have some problems.
> This is how I try to build it
> ------------
> # ./configure \
> -prefix /pkg/ocaml/3.03-alpha \
> -libdir /pkg/ocaml/3.03-alpha/lib -with-pthread \
> -tkdefs '-I/pkg/tcltk/8.3.3/include' \
> -tklibs '-Wl,-rpath=/pkg/tcltk/8.3.3/lib,-rpath-link=/pkg/tcltk/8.3.3/lib -L/pkg/tcltk/8.3.3/lib -ltk8.3 -ltcl8.3'
> -------------

I didn't know about the syntax -rpath=..., is it really supposed to work?

> # make world
> <snip everything until end>
> ../../../tools/ocamlmklib -ocamlc '../../../boot/ocamlrun ../../../ocamlc -I ../../../stdlib' -o labltk -oc labltk41 \
>           ../support/support.cmo ../support/widget.cmo ../support/protocol.cmo ../support/textvariable.cmo ../support/timer.cmo ../support/fileevent.cmo tk.cmo scale.cmo radiobutton.cmo dialog.cmo selection.cmo toplevel.cmo frame.cmo canvas.cmo pack.cmo listbox.cmo grab.cmo button.cmo grid.cmo imagephoto.cmo bell.cmo w
> info.cmo imagebitmap.cmo tkwait.cmo scrollbar.cmo checkbutton.cmo palette.cmo focus.cmo optionmenu.cmo wm.cmo entry.cmo text.cmo message.cmo option.cmo clipboard.cmo menubutton.cmo label.cmo place.cmo menu.cmo  \
>           -Wl,-rpath=/pkg/tcltk/8.3.3/lib,-rpath-link=/pkg/tcltk/8.3.3/lib -L/pkg/tcltk/8.3.3/lib -ltk8.3 -ltcl8.3  -L/usr/X11R6/lib -lX11
> Unknown option '-Wl,-rpath=/pkg/tcltk/8.3.3/lib,-rpath-link=/pkg/tcltk/8.3.3/lib', ignored

And since ocamlmklib doesn't know about this option, it ignores it...
Not very surprising that it cannot find the library afterwards.
You can look at the source (it is a script) to see the options it accepts.

Try with -tklibs '-Wl,-rpath,/pkg/tcltk/8.3.3/lib -L/pkg/tcltk/8.3.3/lib -ltk8.3 -ltcl8.3'.


Jacques Garrigue
Bug reports:  FAQ:
To unsubscribe, mail  Archives: