[erlang-bugs] Problem compiling --enable-darwin-64bit on Mac OS X

Bob Ippolito <>
Thu Feb 7 23:39:28 CET 2008


Using the source from otp_src_R12B-1.tar.gz I'm unable to compile a
64-bit Darwin build.

$ sw_vers
ProductName:	Mac OS X
ProductVersion:	10.5.1
BuildVersion:	9B18
$ cc --version
i686-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5465)
Copyright (C) 2005 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ ./configure --enable-darwin-64bit --prefix=/mochi
...
$ make
...
=== Entering application orber
make[3]: Nothing to be done for `opt'.
make[3]: Nothing to be done for `opt'.
CLASSPATH=../.. javac  -d ../../priv/ InitialReference.java
make -f i386-apple-darwin9.1.0/Makefile TYPE=opt
mkdir -p ../priv/obj/i386-apple-darwin9.1.0
mkdir -p ../priv/bin/i386-apple-darwin9.1.0
gcc -c -o ../priv/obj/i386-apple-darwin9.1.0/obj_init_port.o -m64 -g
-O2 -I/Users/bob/src/otp/otp_src_R12B-1/erts/i386-apple-darwin9.1.0
-no-cpp-precomp   -DHAVE_CONFIG_H   obj_init_port.c
obj_init_port.c: In function 'main':
obj_init_port.c:73: warning: incompatible implicit declaration of
built-in function 'exit'
obj_init_port.c:84: warning: incompatible implicit declaration of
built-in function 'exit'
obj_init_port.c:101: warning: pointer targets in passing argument 3 of
'accept' differ in signedness
obj_init_port.c: In function 'read_request_from_socket':
obj_init_port.c:204: warning: incompatible implicit declaration of
built-in function 'malloc'
obj_init_port.c: In function 'dispatch':
obj_init_port.c:238: warning: incompatible implicit declaration of
built-in function 'exit'
obj_init_port.c: In function 'read_reply':
obj_init_port.c:337: warning: incompatible implicit declaration of
built-in function 'malloc'
obj_init_port.c: In function 'net_init':
obj_init_port.c:391: warning: incompatible implicit declaration of
built-in function 'exit'
gcc -c -o ../priv/obj/i386-apple-darwin9.1.0/setsockaddr_in.o -m64 -g
-O2 -I/Users/bob/src/otp/otp_src_R12B-1/erts/i386-apple-darwin9.1.0
-no-cpp-precomp   -DHAVE_CONFIG_H   setsockaddr_in.c
setsockaddr_in.c: In function 'setsockaddr_in':
setsockaddr_in.c:45: warning: incompatible implicit declaration of
built-in function 'bzero'
setsockaddr_in.c:50: warning: large integer implicitly truncated to
unsigned type
setsockaddr_in.c:61: warning: incompatible implicit declaration of
built-in function 'bcopy'
gcc -o ../priv/bin/i386-apple-darwin9.1.0/obj_init_port
../priv/obj/i386-apple-darwin9.1.0/obj_init_port.o
../priv/obj/i386-apple-darwin9.1.0/setsockaddr_in.o  -lutil -ldl -lm
ld: warning in ../priv/obj/i386-apple-darwin9.1.0/obj_init_port.o,
file is not of required architecture
ld: warning in ../priv/obj/i386-apple-darwin9.1.0/setsockaddr_in.o,
file is not of required architecture
Undefined symbols:
  "_main", referenced from:
      start in crt1.10.5.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[4]: *** [../priv/bin/i386-apple-darwin9.1.0/obj_init_port] Error 1
make[3]: *** [opt] Error 2
make[2]: *** [opt] Error 2
make[1]: *** [opt] Error 2
make: *** [libs] Error 2

-bob



More information about the erlang-bugs mailing list