Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot compile ocaml3.11 on windows with MSCV #4674

Closed
vicuna opened this issue Dec 17, 2008 · 6 comments
Closed

cannot compile ocaml3.11 on windows with MSCV #4674

vicuna opened this issue Dec 17, 2008 · 6 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Dec 17, 2008

Original bug ID: 4674
Reporter: daweil
Status: closed (set by @alainfrisch on 2009-08-18T15:37:01Z)
Resolution: not a bug
Priority: normal
Severity: block
Version: 3.11.0+beta
Category: ~DO NOT USE (was: OCaml general)
Monitored by: daweil db @alainfrisch

Bug description

when I launch "make -f Makefile.nt world", build stop with the message
"win32.c(36) : fatal error C1083: Cannot open include file: 'flexdll.h': No such file or directory".

I have also strange message like "process_begin: CreateProcess((null), flexlink -merge-manifest -where, ...) failed"

I have Microsoft Visual Studio 2005 installed on a 32 bit machine.

File attachments

@vicuna
Copy link
Author

vicuna commented Dec 17, 2008

Comment author: @alainfrisch

Is flexdll properly installed?

@vicuna
Copy link
Author

vicuna commented Feb 2, 2009

Comment author: daweil

  1. I just noticed that it was required to install flexdll to compile Ocaml3.11 on windows (with MSCV). The issue is that flexdll license is opensource license, not the caml consortium license. It would be problematic for us to include an open source software inside out tool.
    How is possible to solve this legal issue?

  2. anyway, i cannot compile on Windows. "make -f Makefile.nt world" ends up with the message "File "myocamlbuild_config.ml", line 20, characters 46-55:
    Error: Unbound value ocamlhome
    e:\users\dwl\R207\AUTDwlINFR207\AUTLciKernel\caml_bin\dosonly\make.exe[1]: *** [myocamlbuild_config.cmo] Error 2", cf the log file make_world.log

@vicuna
Copy link
Author

vicuna commented Apr 6, 2009

Comment author: db

What is the contents of your config/Makefile (not config/Makefile.msvc)? Looks like the PREFIX= line is incorrect.

@vicuna
Copy link
Author

vicuna commented Aug 17, 2009

Comment author: daweil

I retry today with ocaml3.11.1. It seems to work better. I managed to compile Ocaml until the step "make -f Makefile.nt opt". However, I could not compile the debugger : i had to set variable DEBUGGER to empty in file Makefile.msvc.
If I try to compiler the debugger, "cd debugger && make -f Makefile.nt all", I get the following message : ../ocamlcomp.sh -c -warn-error A -I ../utils -I ../parsing -I ../typing -I ../bytecomp -I ../toplevel -I ../otherlibs/win32unix dynlink.mli
Fatal error: cannot find file /cygdrive/e/users/dwl/dev/R209/AUTdwlINFR209/AUTLciKernel/caml_src/ocaml-3.11.1/ocamlc
It looks like a confusion between DOS and unix pathes.

When I launch "make -f Makefile.nt opt.opt", I get the same kind of error message.

Then I analyzed the issue more precisely, by adding
echo "dir = $topdir"
in file ocamlcomp.sh, I see the absolute path "/cygdrive/e/..." instead of a relative path. So I replaced the content of ocamlcomp.sh by :

#!/bin/sh
#topdir=dirname $0
topdir=e:/users/dwl/dev/R209/AUTdwlINFR209/AUTLciKernel/caml_src/ocaml-3.11.1
exec $topdir/boot/ocamlrun $topdir/ocamlc -nostdlib -I $topdir/stdlib "$@"

it works but it is very tedious as the ocamlcomp.sh and ocamlcompopt.sh are overwritten at each build step.

Do you have an idea for a better patch ?

@vicuna
Copy link
Author

vicuna commented Aug 18, 2009

Comment author: daweil

I found better patch this morning : it seems that with the version of gnu-make I have, relative path are transformed in absolute cygwin pathes. So I changed some Makefile by adding double quotes around relatives pathes.
In the debugger/Makefile.shared, I changed the line
CAMLC=../ocamlcomp.sh
into
CAMLC="../ocamlcomp.sh"

and did the same in some otehr makefiles.

@vicuna
Copy link
Author

vicuna commented Aug 18, 2009

Comment author: daweil

You can close the issue : I just understand that all my trouble was coming from the fact that I was using the mingw version of gnu-make instead of the cygwin-version!!!

PS : it used to work with 3.10 but not anymore with 3.11

@vicuna vicuna closed this as completed Aug 18, 2009
@vicuna vicuna added the bug label Mar 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant