caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* GTK
@ 2005-07-19 15:26 N.P.S.Sika
  2005-07-19 15:40 ` [Caml-list] GTK SooHyoung Oh
  2005-07-20  6:21 ` Jean-Christophe Filliatre
  0 siblings, 2 replies; 3+ messages in thread
From: N.P.S.Sika @ 2005-07-19 15:26 UTC (permalink / raw)
  To: caml-list



Hello there,

I try to compile my first GTK+2 code "base.ml" taken from the GTK Ocaml tutorial
from

-------------
(* file: base.ml *)

let main () =
  let window = GWindow.window () in
  window#show ();
  GMain.Main.main ()

let _ = main ()
-------------------
You can compile the above program with ocamlc using:

ocamlc -I +lablgtk2 -o base lablgtk.cma gtkInit.cmo base.ml


HOWEVER when I do that i get the following error message

File "base.ml", line 4, characters 15-29:
Unbound value GWindow.window

anyone got any idea what it is ?
thanks


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Caml-list] GTK
  2005-07-19 15:26 GTK N.P.S.Sika
@ 2005-07-19 15:40 ` SooHyoung Oh
  2005-07-20  6:21 ` Jean-Christophe Filliatre
  1 sibling, 0 replies; 3+ messages in thread
From: SooHyoung Oh @ 2005-07-19 15:40 UTC (permalink / raw)
  To: N.P.S.Sika; +Cc: caml-list


It seems that you don't have lablgtk2 installed.
Please check whether $(OCAMLLIB)/lablgtk2 exists or not.

N.P.S.Sika@westminster.ac.uk wrote:

>Hello there,
>
>I try to compile my first GTK+2 code "base.ml" taken from the GTK Ocaml tutorial
>from
>
>-------------
>(* file: base.ml *)
>
>let main () =
>  let window = GWindow.window () in
>  window#show ();
>  GMain.Main.main ()
>
>let _ = main ()
>-------------------
>You can compile the above program with ocamlc using:
>
>ocamlc -I +lablgtk2 -o base lablgtk.cma gtkInit.cmo base.ml
>
>
>HOWEVER when I do that i get the following error message
>
>File "base.ml", line 4, characters 15-29:
>Unbound value GWindow.window
>
>anyone got any idea what it is ?
>thanks
>
>_______________________________________________
>Caml-list mailing list. Subscription management:
>http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
>Archives: http://caml.inria.fr
>Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
>Bug reports: http://caml.inria.fr/bin/caml-bugs
>
>  
>


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Caml-list] GTK
  2005-07-19 15:26 GTK N.P.S.Sika
  2005-07-19 15:40 ` [Caml-list] GTK SooHyoung Oh
@ 2005-07-20  6:21 ` Jean-Christophe Filliatre
  1 sibling, 0 replies; 3+ messages in thread
From: Jean-Christophe Filliatre @ 2005-07-20  6:21 UTC (permalink / raw)
  To: N.P.S.Sika; +Cc: caml-list


N.P.S.Sika@westminster.ac.uk writes:
 > 
 > I try to compile my first GTK+2 code "base.ml" taken from the GTK Ocaml tutorial
 > from
 > 
 > -------------
 > (* file: base.ml *)
 > 
 > let main () =
 >   let window = GWindow.window () in
 >   window#show ();
 >   GMain.Main.main ()
 > 
 > let _ = main ()
 > -------------------
 > You can compile the above program with ocamlc using:
 > 
 > ocamlc -I +lablgtk2 -o base lablgtk.cma gtkInit.cmo base.ml
 > 
 > HOWEVER when I do that i get the following error message
 > 
 > File "base.ml", line 4, characters 15-29:
 > Unbound value GWindow.window
 > 
 > anyone got any idea what it is ?

It is likely that lablgtk2 is not correctly installed on your system.
Did you checked for gWindow.cmi in `ocamlc -where`/lablgtk2 for instance?

To check your lablgtk2 installation, you can also try to launch the
lablgtk2 toplevel, with the "lablgtk2" command. Then you can type in the
sample code above directly in the toplevel. (But it is likely that
you'll get the same error message, since it means that gWindow.cmi is
not found).

--
Jean-Christophe


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-07-20  6:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-19 15:26 GTK N.P.S.Sika
2005-07-19 15:40 ` [Caml-list] GTK SooHyoung Oh
2005-07-20  6:21 ` Jean-Christophe Filliatre

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).