Friday, February 11, 2011

Building error : Undefined symbols: "_speex_bits_init", referenced from:

Undefined symbols:
  "_speex_bits_init", referenced from:
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_destroy", referenced from:
      _spx_codec_close in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_close in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_srtp_unprotect_rtcp", referenced from:
      _srtp_rtcp_cb in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_srtp_protect_rtcp", referenced from:
      _transport_send_rtcp2 in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_srtp_deinit", referenced from:
      _pjmedia_srtp_deinit_lib in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_speex_decoder_destroy", referenced from:
      _spx_codec_close in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_nb_mode", referenced from:
      _speex_nb_mode$non_lazy_ptr in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
     (maybe you meant: _speex_nb_mode$non_lazy_ptr)
  "_speex_mode_query", referenced from:
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_nbytes", referenced from:
      _spx_codec_encode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_read_from", referenced from:
      _spx_codec_parse in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_decode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_decoder_init", referenced from:
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_remaining", referenced from:
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_crypto_get_random", referenced from:
      _generate_crypto_attr_value in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_srtp_dealloc", referenced from:
      _pjmedia_transport_srtp_stop in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
      _pjmedia_transport_srtp_stop in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
      _pjmedia_transport_srtp_start in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_speex_encoder_destroy", referenced from:
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_close in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_srtp_create", referenced from:
      _pjmedia_transport_srtp_start in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
      _pjmedia_transport_srtp_start in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
     (maybe you meant: _pjmedia_transport_srtp_create)
  "_speex_encoder_init", referenced from:
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_octet_string_hex_string", referenced from:
      _pjmedia_transport_srtp_start in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
      _pjmedia_transport_srtp_start in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_speex_lib_get_mode", referenced from:
      _pjmedia_codec_speex_init in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _pjmedia_codec_speex_init in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_decoder_ctl", referenced from:
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_modify in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_reset", referenced from:
      _spx_codec_encode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_encoder_ctl", referenced from:
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _get_speex_info in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_open in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_modify in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_modify in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_decode_int", referenced from:
      _spx_codec_decode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_recover in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_srtp_unprotect", referenced from:
      _srtp_rtp_cb in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
      _srtp_rtp_cb in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_speex_encode_int", referenced from:
      _spx_codec_encode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_srtp_protect", referenced from:
      _transport_send_rtp in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
  "_speex_bits_advance", referenced from:
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _spx_codec_decode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_srtp_init", referenced from:
      _pjmedia_srtp_init_lib in libpjmedia-arm-apple-darwin10.a(transport_srtp.o)
     (maybe you meant: _pjmedia_srtp_init_lib)
  "_speex_bits_unpack_unsigned", referenced from:
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
      _speex_get_next_frame in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
  "_speex_bits_write", referenced from:
      _spx_codec_encode in libpjmedia-codec-arm-apple-darwin10.a(speex_codec.o)
ld: symbol(s) not found
collect2: ld returned 1 exit status




print screen of the error:


I solved the proble importing the missing .a libs:

On Xcode: project -> frameworks -> device (right click) -> add -> existing file 





select the lib on your pjs folder ie : /Users/jhonjairoroa87/Downloads/pjproject-svn/third_party/lib/libspeex-arm-apple-darwin10.a





No comments: