LIBS = ws2_32.lib winmm.lib advapi32.lib crypt32.lib user32.lib gdi32.lib libeay32.lib ssleay32.lib
OSCOMPAT = /DWIN32 /D_WIN32_WINNT=0x0400
VSCOMPAT = /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE
CFLAGS= -I . -I$C /MT /W3 $(OSCOMPAT) $(VSCOMPAT) -nologo $(EXTRACFLAGS)
test: $(CCLIENTLIB) test.obj oauth.obj hash.obj oauth_http.obj xmalloc.obj
LINK /NOLOGO mtest.obj oauth.obj hash.obj oauth_http.obj xmalloc.obj $(LIBS)
test.obj:test.c
oauth.obj: oauth.c
hash.obj: hash.c
oauth_http.obj: oauth.h oauth_http.c
xmalloc.obj: xmalloc.c
我收到以下错误
LINK /NOLOGO test.obj oauth.obj hash.obj oauth_http.obj xmalloc.obj ws2_32.lib winmm.lib advapi32.lib crypt32.lib user32.lib gdi32.lib libeay32.lib ssleay32.lib
hash.obj : error LNK2019: unresolved external symbol HMAC referenced in function oauth_sign_hmac_sha1_raw
hash.obj : error LNK2019: unresolved external symbol EVP_sha1 referenced in function oauth_sign_hmac_sha1_raw
hash.obj : error LNK2019: unresolved external symbol EVP_PKEY_free referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol CRYPTO_free referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_SignFinal referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_DigestUpdate referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_DigestInit referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_PKEY_size referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol BIO_free referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol PEM_read_bio_PrivateKey referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol BIO_new_mem_buf referenced in function oauth_sign_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_MD_CTX_cleanup referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_VerifyFinal referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol PEM_read_bio_PUBKEY referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol X509_free referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol X509_get_pubkey referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol PEM_read_bio_X509 referenced in function oauth_verify_rsa_sha1
hash.obj : error LNK2019: unresolved external symbol EVP_DigestFinal referenced in function oauth_body_hash_file
hash.obj : error LNK2019: unresolved external symbol EVP_MD_size referenced in function oauth_body_hash_file
hash.obj : error LNK2019: unresolved external symbol EVP_MD_CTX_init referenced in function oauth_body_hash_file
test.exe : fatal error LNK1120: 20 unresolved externals
make 文件有什么问题。 如何将 libssl 与我的应用程序链接?
你可以从这里下载代码 https://rapidshare.com/files/458792519/test.rar (它包括来自 liboauth 的代码)