caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* -custom under NT
@ 1998-10-06 16:27 Don Syme
  0 siblings, 0 replies; 2+ messages in thread
From: Don Syme @ 1998-10-06 16:27 UTC (permalink / raw)
  To: 'caml-list@inria.fr'


I'm having problems using -custom under Windows NT.  With test.ml
containing just

let x = 1;;


ocamlc  -c test.ml
ocamlc  -verbose -o test  -custom unix.cma  -cclib -lunix test.cmo

gives

+ cl /nologo /MT /Fetest.exe -Ic:/ocaml/lib  C:\TEMP\camlprim0.c -lunix
c:/ocaml/lib\libcamlrun.lib
Command line warning D4002 : ignoring unknown option '-lunix'
camlprim0.c
camlprim0.obj : error LNK2001: unresolved external symbol _win_stdhandle
camlprim0.obj : error LNK2001: unresolved external symbol _win_startup
camlprim0.obj : error LNK2001: unresolved external symbol _win_cleanup
etc.

Changing -cclib -lunix to -ccopt gives a different set of errors:

ocamlc -verbose -g -o test  -custom unix.cma  -ccopt
c:/ocaml/lib/libunix.lib  test.cmo

+ cl /nologo /MT /Fetest.exe -Ic:/ocaml/lib c:/ocaml/lib/libunix.lib
C:\TEMP\camlprim0.c  c:/ocaml/lib\libcamlrun.lib
camlprim0.c
libunix.lib(startup.obj) : error LNK2001: unresolved external symbol
_WSAStartup@8
libunix.lib(startup.obj) : error LNK2001: unresolved external symbol
_WSACleanup@0
libunix.lib(socket.obj) : error LNK2001: unresolved external symbol
_WSAGetLastError@0
etc.

What am I doing wrong, or what should I try next?

(P.S. The notes for -custom under Windows could mention how to set up the
paths
for VC++ so ocaml can find the command line VC++ compiler. )

Thanks!
Don Syme







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

* RE: -custom under NT
@ 1998-10-06 16:38 Don Syme
  0 siblings, 0 replies; 2+ messages in thread
From: Don Syme @ 1998-10-06 16:38 UTC (permalink / raw)
  To: 'caml-list@inria.fr'



Actually, adding -ccopt WSOCK32.LIB to the second setup seems to have done
the trick.

Cheers,
Don

> -----Original Message-----
> From:	Don Syme 
> Sent:	Tuesday, October 06, 1998 5:27 PM
> To:	'caml-list@inria.fr'
> Subject:	-custom under NT
> 
> 
> I'm having problems using -custom under Windows NT.  With test.ml
> containing just
> 
> let x = 1;;
> 
> 
> ocamlc  -c test.ml
> ocamlc  -verbose -o test  -custom unix.cma  -cclib -lunix test.cmo
> 
> gives
> 
> + cl /nologo /MT /Fetest.exe -Ic:/ocaml/lib  C:\TEMP\camlprim0.c -lunix
> c:/ocaml/lib\libcamlrun.lib
> Command line warning D4002 : ignoring unknown option '-lunix'
> camlprim0.c
> camlprim0.obj : error LNK2001: unresolved external symbol _win_stdhandle
> camlprim0.obj : error LNK2001: unresolved external symbol _win_startup
> camlprim0.obj : error LNK2001: unresolved external symbol _win_cleanup
> etc.
> 
> Changing -cclib -lunix to -ccopt gives a different set of errors:
> 
> ocamlc -verbose -g -o test  -custom unix.cma  -ccopt
> c:/ocaml/lib/libunix.lib  test.cmo
> 
> + cl /nologo /MT /Fetest.exe -Ic:/ocaml/lib c:/ocaml/lib/libunix.lib
> C:\TEMP\camlprim0.c  c:/ocaml/lib\libcamlrun.lib
> camlprim0.c
> libunix.lib(startup.obj) : error LNK2001: unresolved external symbol
> _WSAStartup@8
> libunix.lib(startup.obj) : error LNK2001: unresolved external symbol
> _WSACleanup@0
> libunix.lib(socket.obj) : error LNK2001: unresolved external symbol
> _WSAGetLastError@0
> etc.
> 
> What am I doing wrong, or what should I try next?
> 
> (P.S. The notes for -custom under Windows could mention how to set up the
> paths
> for VC++ so ocaml can find the command line VC++ compiler. )
> 
> Thanks!
> Don Syme
> 
> 





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

end of thread, other threads:[~1998-10-07  7:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-10-06 16:27 -custom under NT Don Syme
1998-10-06 16:38 Don Syme

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).