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
Compilation of ocaml 3.10.0/64bit on Mac Os X Intel
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-09-15 (17:28)
From: Pascal Cuoq <pascal_cuoq@h...>
Subject: Compilation of ocaml 3.10.0/64bit on Mac Os X Intel
Hello everyone!

I didn't see anyone report success compiling the 64bit version of
Ocaml on Mac Os X Intel, so I had a go at it today. Here is where
I stopped, perhaps someone more knowledgable can continue from there.
I got the bytecode and native compiler to compile, and to
compile some big projects successfully, but I didn't have any
success at bootstrapping.

Here is the recipe I suggest:

- get patch (warning: this patch does not try
to preserve the possibility to compile with any other architecture,
including Mac Os X/32):

- apply patch:
cd ocaml-3.10.0
patch -p0 < ../ocaml_macosx_amd64.diff

- configure:
./configure -host x86_64-apple-darwin -cc "gcc -m64" -prefix /usr/local/64

- make bytecode compiler:
make world

- edit config/Makefile, replace the line
ASPPFLAGS=-c -arch x86_64 -DSYS_$(SYSTEM)

- make native compiler:
make opt


FREE pop-up blocking with the new MSN Toolbar - get it now!