2012-10-03 2 views
2

많은 링커 오류가 발생했습니다. 내가 macports를 통해 필요한 모든 라이브러리를 설치했는지 확인했다. 나는 모든 include 오류를 분류했지만 지금은 많은 링커 오류가 남아 있습니다.C 라이브러리를 사용하는 x86_64 아키텍처에 대한 정의되지 않은 기호

HEADER_SEARCH_PATHS =/옵션/지역/등은/usr/포함/옵션/지역/포함/JSON =/opt가/지방은/lib 디렉토리/usr /을

Build target PianoLounge 

Ld /Users/jordan/Library/Developer/Xcode/DerivedData/PianoLounge-ajgojrzszrergafgvyuliphwxcpg/Build/Products/Debug/PianoLounge.app/Contents/MacOS/PianoLounge normal x86_64 
    cd /Users/jordan/Projects/Cocoa/PianoLounge 
    setenv MACOSX_DEPLOYMENT_TARGET 10.8 
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk -L/Users/jordan/Library/Developer/Xcode/DerivedData/PianoLounge-ajgojrzszrergafgvyuliphwxcpg/Build/Products/Debug -L/opt/local/lib -L/usr/local/lib -F/Users/jordan/Library/Developer/Xcode/DerivedData/PianoLounge-ajgojrzszrergafgvyuliphwxcpg/Build/Products/Debug -filelist /Users/jordan/Library/Developer/Xcode/DerivedData/PianoLounge-ajgojrzszrergafgvyuliphwxcpg/Build/Intermediates/PianoLounge.build/Debug/PianoLounge.build/Objects-normal/x86_64/PianoLounge.LinkFileList -mmacosx-version-min=10.8 -fobjc-arc -fobjc-link-runtime -framework Cocoa -o /Users/jordan/Library/Developer/Xcode/DerivedData/PianoLounge-ajgojrzszrergafgvyuliphwxcpg/Build/Products/Debug/PianoLounge.app/Contents/MacOS/PianoLounge 

Undefined symbols for architecture x86_64: 
    "_gcry_cipher_close", referenced from: 
     _PianoDestroyPartner in piano.o 
    "_gcry_cipher_decrypt", referenced from: 
     _PianoDecryptString in crypt.o 
    "_gcry_cipher_encrypt", referenced from: 
     _PianoEncryptString in crypt.o 
    "_gcry_cipher_open", referenced from: 
     _PianoInit in piano.o 
    "_gcry_cipher_setkey", referenced from: 
     _PianoInit in piano.o 
    "_gnutls_bye", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_certificate_allocate_credentials", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_certificate_free_credentials", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_certificate_get_peers", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_gnutls_certificate_type_get", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_gnutls_credentials_set", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_deinit", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_handshake", referenced from: 
     _WaitressConnect in waitress.o 
    "_gnutls_init", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_record_recv", referenced from: 
     _WaitressGnutlsRead in waitress.o 
    "_gnutls_record_send", referenced from: 
     _WaitressGnutlsWrite in waitress.o 
    "_gnutls_set_default_priority", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_transport_set_ptr", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_transport_set_pull_function", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_transport_set_push_function", referenced from: 
     _WaitressFetchCall in waitress.o 
    "_gnutls_x509_crt_deinit", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_gnutls_x509_crt_get_fingerprint", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_gnutls_x509_crt_import", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_gnutls_x509_crt_init", referenced from: 
     _WaitressTlsVerify in waitress.o 
    "_json_object_array_add", referenced from: 
     _PianoRequest in request.o 
    "_json_object_array_get_idx", referenced from: 
     _PianoResponse in response.o 
    "_json_object_array_length", referenced from: 
     _PianoResponse in response.o 
    "_json_object_get_boolean", referenced from: 
     _PianoResponse in response.o 
     _PianoJsonParseStation in response.o 
    "_json_object_get_double", referenced from: 
     _PianoResponse in response.o 
    "_json_object_get_int", referenced from: 
     _PianoResponse in response.o 
    "_json_object_get_object", referenced from: 
     _PianoResponse in response.o 
    "_json_object_get_string", referenced from: 
     _PianoResponse in response.o 
     _PianoJsonStrdup in response.o 
    "_json_object_new_array", referenced from: 
     _PianoRequest in request.o 
    "_json_object_new_boolean", referenced from: 
     _PianoRequest in request.o 
    "_json_object_new_int", referenced from: 
     _PianoRequest in request.o 
    "_json_object_new_object", referenced from: 
     _PianoRequest in request.o 
    "_json_object_new_string", referenced from: 
     _PianoRequest in request.o 
    "_json_object_object_add", referenced from: 
     _PianoRequest in request.o 
    "_json_object_object_get", referenced from: 
     _PianoResponse in response.o 
     _PianoJsonStrdup in response.o 
     _PianoJsonParseStation in response.o 
    "_json_object_put", referenced from: 
     _PianoRequest in request.o 
     _PianoResponse in response.o 
    "_json_object_to_json_string", referenced from: 
     _PianoRequest in request.o 
    "_json_tokener_parse", referenced from: 
     _PianoResponse in response.o 
ld: symbol(s) not found for architecture x86_64 
clang: error: linker command failed with exit code 1 (use -v to see invocation) 

답변

2

lib 디렉토리/지역 그것은 당신처럼 보인다 LIBRARY_SEARCH_PATHS 연결할 라이브러리 gnutls, gcrypt 및 json이 필요 없습니다. Xcode에게 어떤 라이브러리를 링크할지 말하면 Xcode에 알리지 않습니다. 다음과 같이 표시됩니다.

-lgnutls -lgcrypt -ljson 

(예 : 구체적으로 어떤 라이브러리가 필요한지 잘 모르겠습니다.)

Xcode 프로젝트에서 연결할 추가 라이브러리로 추가하려고합니다.

관련 문제