Version française
Home     About     Download     Resources     Contact us    
Browse thread
library problem
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Rasool Karimi <rkarimi@g...>
Subject: library problem
Dear All friends,

When I compile my program by ocamlc as follow:
ocamlc -I +lablgtk2 -I +labltk labltk.cma str.cma -o otto.exe lablgtk.cma
gtkInit.cmo keywordsdeutsch.cmo table.cmo tab2tbt.cmo rec_zuw.cmo
crosstable.cmo htmlprint.cmo path.cmo lexer.cmo parser.cmo functions.cmo
term.ml <http://term.ml>
There is not any problem. But when I compile my program by ocamlopt as
follow:
ocamlopt -I +lablgtk2 -I +labltk -o otto.exe
keywordsdeutsch.ml<http://keywordsdeutsch.ml>
table.ml <http://table.ml> tab2tbt.ml <http://tab2tbt.ml> rec_zuw.ml
htmlprint.ml <http://htmlprint.ml> path.ml <http://path.ml>
lexer.ml<http://lexer.ml>
functions.ml <http://functions.ml> parser.ml <http://parser.ml>
term.ml<http://term.ml>
following error message is shown:

GMain referenced from term.cmx
Winfo referenced from functions.cmx
GBin referenced from term.cmx
GButton referenced from term.cmx
GtkText referenced from term.cmx
Glib referenced from term.cmx
Tk referenced from functions.cmx
GTree referenced from term.cmx
GMisc referenced from term.cmx
GdkEvent referenced from term.cmx
Crosstable referenced from parser.cmx
GPack referenced from term.cmx
GtkSignal referenced from term.cmx
Str referenced from table.cmx
GText referenced from term.cmx
GEdit referenced from term.cmx
Gobject referenced from term.cmx
Canvas referenced from functions.cmx
GdkKeysyms referenced from term.cmx
GWindow referenced from term.cmx
GMenu referenced from term.cmx

As it is obvious, I use necessary libraries. Also these libraries are
installed, because there is not any error, when I use ocamlc.
One friend said me that you should use gtkInit.cmo too (same as ocamlc
command). So I changed my command as follow:
ocamlopt -I +lablgtk2 -I +labltk -o ottoopt.exe gtkInit.cmo
keywordsdeutsch.ml <http://keywordsdeutsch.ml> table.ml <http://table.ml>
tab2tbt.ml <http://tab2tbt.ml> rec_zuw.ml htmlprint.ml <http://htmlprint.ml>
path.ml <http://path.ml> lexer.ml <http://lexer.ml>
functions.ml<http://functions.ml>
parser.ml <http://parser.ml> term.ml <http://term.ml>
But when I execute this command, following error message is shownd:

ocamlopt: don't know what to do with lablgtk.cmo.

Now what is problem and how can I fix it.
Thanks,
Karimi