64-bit erlang

Scott Lystig Fritchie <>
Fri Nov 11 21:06:03 CET 2005


>>>>> "bg" == Bjorn Gustavsson <> writes:

bg> There is no direct configuration in Erlang/OTP for 32 vs 64 bits.
bg> Instead, if the Erlang/OTP is built with a C compiler that
bg> generates 64 bits executables, the Erlang emulator will be 64 bit
bg> enabled; otherwise it will be 32 bit.

That's what I'd discovered, after a bit of fiddling.  I thought I'd
RTFM'ed, but it was later at night than it should've been, so perhaps
I missed something obvious.

To build a 64-bit VM on Solaris using GCC, using 'CFLAGS="gcc -m64"
./configure' wasn't sufficient.  I resorted to:

    % mkdir /tmp/gcc-hack
    % cat > /tmp/gcc-hack/gcc <<EOM
    #!/bin/sh
    
    exec /path/to/gcc -m64 $*
    % chmod +x /tmp/gcc-hack/gcc
    % set path = (/tmp/gcc-hack $path)
    % ./configure ....
    % make

Ugly brute force, but it worked.

-Scott



More information about the erlang-questions mailing list