[erlang-questions] compiling problems under OS X Lion

Sean Moss-Pultz sean@REDACTED
Sat Jul 23 03:03:10 CEST 2011


> On Fri, Jul 22, 2011 at 9:20 AM, Sean Moss-Pultz <sean@REDACTED> wrote:
>> Hi List
>>
>> I'm trying to build R14B03 under OS X Lion. (Xcode v4.1). I'm getting
>> the following error:

{snip}

On Fri, Jul 22, 2011 at 11:37 PM, Dave Smith <dizzyd@REDACTED> wrote:
> If you want to compile Erlang w/ clang-llvm on 10.6 (or above) do
> this: CFLAGS=-O0 ./configure ...
>

Thanks Dave. That got me a lot further. But I'm still getting the
following errors:

------------------------------------------------------------------------------------------------------------------

gcc -O0 -no-cpp-precomp -Wall -Wstrict-prototypes -Wmissing-prototypes
-Wmissing-declarations -Wnested-externs -Winline -fno-strict-aliasing
-I. -I../include -Iconnect -Iencode -Idecode -Imisc -Iepmd -Iregistry
-Ii386-apple-darwin11.0.0   -Ilegacy -D_THREAD_SAFE -D_REENTRANT
-DPOSIX_THREADS -m32  -o
/Users/mosko/Downloads/otp_src_R14B03/lib/erl_interface/bin/i386-apple-darwin11.0.0/erl_call
prog/erl_call.c prog/erl_start.c \
		-L/Users/mosko/Downloads/otp_src_R14B03/lib/erl_interface/obj/i386-apple-darwin11.0.0
-lei -lpthread
ld: warning: ignoring file
/Users/mosko/Downloads/otp_src_R14B03/lib/erl_interface/obj/i386-apple-darwin11.0.0/libei.a,
file was built for archive which is not the architecture being linked
(i386)
Undefined symbols for architecture i386:
  "_ei_gethostbyname", referenced from:
      _main in ccO2Es4f.o
      _do_connect in ccO2Es4f.o
  "_ei_connect_xinit", referenced from:
      _main in ccO2Es4f.o
  "___erl_errno_place", referenced from:
      _main in ccO2Es4f.o
  "_ei_thishostname", referenced from:
      _main in ccO2Es4f.o
      _exec_erlang in cc6g0Be0.o
  "_ei_connect", referenced from:
      _main in ccO2Es4f.o
      _do_connect in ccO2Es4f.o
  "_ei_encode_list_header", referenced from:
      _main in ccO2Es4f.o
  "_ei_x_new_with_version", referenced from:
      _main in ccO2Es4f.o
  "_ei_rpc", referenced from:
      _main in ccO2Es4f.o
  "_ei_x_free", referenced from:
      _main in ccO2Es4f.o
  "_ei_encode_string", referenced from:
      _main in ccO2Es4f.o
  "_ei_encode_binary", referenced from:
      _main in ccO2Es4f.o
  "_ei_encode_atom", referenced from:
      _main in ccO2Es4f.o
  "_ei_print_term", referenced from:
      _main in ccO2Es4f.o
  "_ei_x_new", referenced from:
      _main in ccO2Es4f.o
  "_ei_x_format_wo_ver", referenced from:
      _main in ccO2Es4f.o
  "_ei_gethostbyname_r", referenced from:
      _get_addr in cc6g0Be0.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
make[4]: *** [/Users/mosko/Downloads/otp_src_R14B03/lib/erl_interface/bin/i386-apple-darwin11.0.0/erl_call]
Error 1
make[3]: *** [opt] Error 2
make[2]: *** [opt] Error 2
make[1]: *** [opt] Error 2
make: *** [libs] Error 2

------------------------------------------------------------------------------------------------------------------

Any ideas on this one? I should add, Lion was an upgrade (from Snow
Leopard), not a new install.

Thanks!

Sean



More information about the erlang-questions mailing list