作为一个没有管理员权限的用户,我编译了openssl1.1.0并安装在
$HOME/openssl
.
然后我下载了vapor 3.3
https://github.com/vapor/vapor/archive/3.3.0.tar.gz
但是当用
swift build -Xcc -I$HOME/openssl/include -Xlinker -L$HOME/openssl/lib/
我得到以下错误:
warning: you may be able to install openssl using your system-packager:
brew install libressl
'swift-nio-zlib-support' zlib.pc: warning: couldn't find pc file
Undefined symbols for architecture x86_64:
"_ASN1_STRING_get0_data", referenced from:
_CNIOOpenSSL_ASN1_STRING_get0_data in shims.c.o
(maybe you meant: _CNIOOpenSSL_ASN1_STRING_get0_data)
"_ASN1_STRING_length", referenced from:
_$s10NIOOpenSSL22SubjectAltNameSequenceC4nextAA18OpenSSLCertificateC011AlternativeE0OSgyF in SSLCertificate.swift.o
"_ASN1_STRING_to_UTF8", referenced from:
_$s10NIOOpenSSL18OpenSSLCertificateC10commonNameSays5UInt8VGSgyF in SSLCertificate.swift.o
"_BIO_clear_flags", referenced from:
_CNIOOpenSSL_BIO_clear_retry_flags in shims.c.o
"_BIO_ctrl", referenced from:
_CNIOOpenSSL_BIO_get_close in shims.c.o
_CNIOOpenSSL_BIO_set_close in shims.c.o
_CNIOOpenSSL_BIO_get_mem_data in shims.c.o
...
使用OSX10.14.4和Xcode 10.1。