Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

无法在Linux上面运行 缺少error: no such module 'CryptoKit' #1

Open
iphone5s opened this issue Feb 27, 2023 · 2 comments
Open

Comments

@iphone5s
Copy link

wechat/Sources/Wechat/pay/wxpayParam.swift:10:8: error: no such module 'CryptoKit'
import CryptoKit

@SpectatorNan
Copy link
Member

这个是应该是SPM 拉依赖失败导致的, 建议用香港服务器

@iphone5s
Copy link
Author

应该不是 拉依赖失败导致的。。我服务器挂了VPN
swift --version
Swift version 5.7.3 (swift-5.7.3-RELEASE)
Target: x86_64-unknown-linux-gnu

swift build -c=release
Fetching https://github.com/SwifterSwift/SwifterSwift.git from cache
Fetched https://github.com/SwifterSwift/SwifterSwift.git (1.41s)
Fetching https://github.com/iphone5s/SwiftyJSON.git from cache
Fetched https://github.com/iphone5s/SwiftyJSON.git (1.31s)
Fetching https://github.com/Buddywatchapp/paypal.git from cache
Fetched https://github.com/Buddywatchapp/paypal.git (0.82s)
Fetching https://github.com/vapor-china/wechat.git from cache
Fetched https://github.com/vapor-china/wechat.git (0.84s)
Fetching https://github.com/vapor-china/coda-wrapper.git from cache
Fetching https://github.com/apple/swift-crypto.git from cache
Fetched https://github.com/vapor-china/coda-wrapper.git (0.88s)
Fetching https://github.com/vapor/vapor.git from cache
Fetched https://github.com/apple/swift-crypto.git (0.88s)
Fetching https://github.com/vapor/leaf.git from cache
Fetched https://github.com/vapor/leaf.git (1.29s)
Fetching https://github.com/vapor/fluent-mysql-driver.git from cache
Fetched https://github.com/vapor/vapor.git (1.52s)
Fetching https://github.com/vapor/fluent.git from cache
Fetched https://github.com/vapor/fluent-mysql-driver.git (1.26s)
Fetched https://github.com/vapor/fluent.git (1.29s)
Computing version for https://github.com/vapor-china/coda-wrapper.git
Computed https://github.com/vapor-china/coda-wrapper.git at 1.0.0 (0.01s)
Computing version for https://github.com/vapor/fluent-mysql-driver.git
Computed https://github.com/vapor/fluent-mysql-driver.git at 4.2.0 (0.01s)
Fetching https://github.com/apple/swift-log.git from cache
Fetching https://github.com/vapor/mysql-kit.git from cache
Fetched https://github.com/apple/swift-log.git (0.88s)
Fetching https://github.com/vapor/fluent-kit.git from cache
Fetched https://github.com/vapor/mysql-kit.git (1.24s)
Fetched https://github.com/vapor/fluent-kit.git (1.40s)
Computing version for https://github.com/vapor/fluent.git
Computed https://github.com/vapor/fluent.git at 4.7.0 (0.01s)
Computing version for https://github.com/vapor/fluent-kit.git
Computed https://github.com/vapor/fluent-kit.git at 1.39.1 (0.26s)
Fetching https://github.com/vapor/async-kit.git from cache
Fetching https://github.com/vapor/sql-kit.git from cache
Fetched https://github.com/vapor/async-kit.git (1.24s)
Fetching https://github.com/apple/swift-nio.git from cache
Fetched https://github.com/vapor/sql-kit.git (1.31s)
Fetched https://github.com/apple/swift-nio.git (2.32s)
Computing version for https://github.com/vapor/sql-kit.git
Computed https://github.com/vapor/sql-kit.git at 3.24.0 (0.01s)
Computing version for https://github.com/apple/swift-log.git
Computed https://github.com/apple/swift-log.git at 1.5.2 (0.01s)
Computing version for https://github.com/apple/swift-nio.git
Computed https://github.com/apple/swift-nio.git at 2.48.0 (0.05s)
Fetching https://github.com/apple/swift-collections.git from cache
Fetching https://github.com/apple/swift-atomics.git from cache
Fetched https://github.com/apple/swift-atomics.git (0.85s)
Fetched https://github.com/apple/swift-collections.git (1.01s)
Computing version for https://github.com/apple/swift-atomics.git
Computed https://github.com/apple/swift-atomics.git at 1.0.3 (0.01s)
Computing version for https://github.com/apple/swift-collections.git
Computed https://github.com/apple/swift-collections.git at 1.0.4 (0.01s)
Computing version for https://github.com/apple/swift-crypto.git
Computed https://github.com/apple/swift-crypto.git at 1.1.7 (0.01s)
Computing version for https://github.com/vapor/mysql-kit.git
Computed https://github.com/vapor/mysql-kit.git at 4.6.1 (0.01s)
Fetching https://github.com/vapor/mysql-nio.git from cache
Fetching https://github.com/apple/swift-nio-ssl.git from cache
Fetched https://github.com/apple/swift-nio-ssl.git (0.97s)
Fetched https://github.com/vapor/mysql-nio.git (1.32s)
Computing version for https://github.com/vapor/mysql-nio.git
Computed https://github.com/vapor/mysql-nio.git at 1.5.0 (0.01s)
Computing version for https://github.com/vapor/leaf.git
Computed https://github.com/vapor/leaf.git at 4.2.4 (0.01s)
Fetching https://github.com/apple/swift-algorithms.git from cache
Fetching https://github.com/vapor/leaf-kit.git from cache
Fetched https://github.com/apple/swift-algorithms.git (0.92s)
Fetched https://github.com/vapor/leaf-kit.git (1.25s)
Computing version for https://github.com/apple/swift-algorithms.git
Computed https://github.com/apple/swift-algorithms.git at 1.0.0 (0.01s)
Fetching https://github.com/apple/swift-numerics from cache
Fetched https://github.com/apple/swift-numerics (1.25s)
Computing version for https://github.com/apple/swift-numerics
Computed https://github.com/apple/swift-numerics at 1.0.2 (0.01s)
Computing version for https://github.com/vapor/leaf-kit.git
Computed https://github.com/vapor/leaf-kit.git at 1.8.0 (0.01s)
Computing version for https://github.com/vapor/async-kit.git
Computed https://github.com/vapor/async-kit.git at 1.16.0 (0.01s)
Computing version for https://github.com/apple/swift-nio-ssl.git
Computed https://github.com/apple/swift-nio-ssl.git at 2.23.0 (0.02s)
Computing version for https://github.com/vapor/vapor.git
Computed https://github.com/vapor/vapor.git at 4.70.0 (0.04s)
Fetching https://github.com/vapor/multipart-kit.git from cache
Fetching https://github.com/vapor/websocket-kit.git from cache
Fetched https://github.com/vapor/multipart-kit.git (1.10s)
Fetching https://github.com/apple/swift-metrics.git from cache
Fetched https://github.com/vapor/websocket-kit.git (1.39s)
Fetching https://github.com/apple/swift-nio-extras.git from cache
Fetched https://github.com/apple/swift-metrics.git (1.13s)
Fetching https://github.com/apple/swift-nio-http2.git from cache
Fetched https://github.com/apple/swift-nio-extras.git (1.37s)
Fetching https://github.com/swift-server/swift-backtrace.git from cache
Fetched https://github.com/apple/swift-nio-http2.git (1.33s)
Fetching https://github.com/vapor/routing-kit.git from cache
Fetched https://github.com/swift-server/swift-backtrace.git (0.86s)
Fetching https://github.com/vapor/console-kit.git from cache
Fetched https://github.com/vapor/routing-kit.git (1.29s)
Fetching https://github.com/swift-server/async-http-client.git from cache
Fetched https://github.com/vapor/console-kit.git (1.23s)
Fetched https://github.com/swift-server/async-http-client.git (0.97s)
Computing version for https://github.com/vapor/routing-kit.git
Computed https://github.com/vapor/routing-kit.git at 4.6.0 (0.01s)
Computing version for https://github.com/vapor/multipart-kit.git
Computed https://github.com/vapor/multipart-kit.git at 4.5.2 (0.01s)
Computing version for https://github.com/apple/swift-metrics.git
Computed https://github.com/apple/swift-metrics.git at 2.3.4 (0.01s)
Computing version for https://github.com/swift-server/swift-backtrace.git
Computed https://github.com/swift-server/swift-backtrace.git at 1.3.3 (0.01s)
Computing version for https://github.com/apple/swift-nio-http2.git
Computed https://github.com/apple/swift-nio-http2.git at 1.25.0 (0.02s)
Computing version for https://github.com/swift-server/async-http-client.git
Computed https://github.com/swift-server/async-http-client.git at 1.15.0 (0.02s)
Fetching https://github.com/apple/swift-nio-transport-services.git from cache
Fetched https://github.com/apple/swift-nio-transport-services.git (0.87s)
Computing version for https://github.com/apple/swift-nio-extras.git
Computed https://github.com/apple/swift-nio-extras.git at 1.16.0 (0.03s)
Computing version for https://github.com/apple/swift-nio-transport-services.git
Computed https://github.com/apple/swift-nio-transport-services.git at 1.15.0 (0.02s)
Computing version for https://github.com/vapor/websocket-kit.git
Computed https://github.com/vapor/websocket-kit.git at 2.6.1 (0.01s)
Computing version for https://github.com/vapor/console-kit.git
Computed https://github.com/vapor/console-kit.git at 4.6.0 (0.01s)
Creating working copy for https://github.com/vapor-china/wechat.git
Working copy of https://github.com/vapor-china/wechat.git resolved at master
Creating working copy for https://github.com/iphone5s/SwiftyJSON.git
Working copy of https://github.com/iphone5s/SwiftyJSON.git resolved at master
Creating working copy for https://github.com/vapor/async-kit.git
Working copy of https://github.com/vapor/async-kit.git resolved at 1.16.0
Creating working copy for https://github.com/vapor/fluent-mysql-driver.git
Working copy of https://github.com/vapor/fluent-mysql-driver.git resolved at 4.2.0
Creating working copy for https://github.com/vapor/mysql-nio.git
Working copy of https://github.com/vapor/mysql-nio.git resolved at 1.5.0
Creating working copy for https://github.com/vapor/vapor.git
Working copy of https://github.com/vapor/vapor.git resolved at 4.70.0
Creating working copy for https://github.com/vapor/mysql-kit.git
Working copy of https://github.com/vapor/mysql-kit.git resolved at 4.6.1
Creating working copy for https://github.com/vapor/console-kit.git
Working copy of https://github.com/vapor/console-kit.git resolved at 4.6.0
Creating working copy for https://github.com/apple/swift-log.git
Working copy of https://github.com/apple/swift-log.git resolved at 1.5.2
Creating working copy for https://github.com/apple/swift-nio-http2.git
Working copy of https://github.com/apple/swift-nio-http2.git resolved at 1.25.0
Creating working copy for https://github.com/apple/swift-nio-ssl.git
Working copy of https://github.com/apple/swift-nio-ssl.git resolved at 2.23.0
Creating working copy for https://github.com/vapor/leaf.git
Working copy of https://github.com/vapor/leaf.git resolved at 4.2.4
Creating working copy for https://github.com/apple/swift-nio-extras.git
Working copy of https://github.com/apple/swift-nio-extras.git resolved at 1.16.0
Creating working copy for https://github.com/vapor/fluent.git
Working copy of https://github.com/vapor/fluent.git resolved at 4.7.0
Creating working copy for https://github.com/vapor/leaf-kit.git
Working copy of https://github.com/vapor/leaf-kit.git resolved at 1.8.0
Creating working copy for https://github.com/vapor/sql-kit.git
Working copy of https://github.com/vapor/sql-kit.git resolved at 3.24.0
Creating working copy for https://github.com/apple/swift-atomics.git
Working copy of https://github.com/apple/swift-atomics.git resolved at 1.0.3
Creating working copy for https://github.com/swift-server/async-http-client.git
Working copy of https://github.com/swift-server/async-http-client.git resolved at 1.15.0
Creating working copy for https://github.com/apple/swift-crypto.git
Working copy of https://github.com/apple/swift-crypto.git resolved at 1.1.7
Creating working copy for https://github.com/SwifterSwift/SwifterSwift.git
Working copy of https://github.com/SwifterSwift/SwifterSwift.git resolved at master
Creating working copy for https://github.com/Buddywatchapp/paypal.git
Working copy of https://github.com/Buddywatchapp/paypal.git resolved at master
Creating working copy for https://github.com/apple/swift-metrics.git
Working copy of https://github.com/apple/swift-metrics.git resolved at 2.3.4
Creating working copy for https://github.com/vapor/websocket-kit.git
Working copy of https://github.com/vapor/websocket-kit.git resolved at 2.6.1
Creating working copy for https://github.com/apple/swift-collections.git
Working copy of https://github.com/apple/swift-collections.git resolved at 1.0.4
Creating working copy for https://github.com/apple/swift-numerics
Working copy of https://github.com/apple/swift-numerics resolved at 1.0.2
Creating working copy for https://github.com/vapor/routing-kit.git
Working copy of https://github.com/vapor/routing-kit.git resolved at 4.6.0
Creating working copy for https://github.com/swift-server/swift-backtrace.git
Working copy of https://github.com/swift-server/swift-backtrace.git resolved at 1.3.3
Creating working copy for https://github.com/apple/swift-nio.git
Working copy of https://github.com/apple/swift-nio.git resolved at 2.48.0
Creating working copy for https://github.com/vapor-china/coda-wrapper.git
Working copy of https://github.com/vapor-china/coda-wrapper.git resolved at 1.0.0
Creating working copy for https://github.com/vapor/fluent-kit.git
Working copy of https://github.com/vapor/fluent-kit.git resolved at 1.39.1
Creating working copy for https://github.com/apple/swift-nio-transport-services.git
Working copy of https://github.com/apple/swift-nio-transport-services.git resolved at 1.15.0
Creating working copy for https://github.com/vapor/multipart-kit.git
Working copy of https://github.com/vapor/multipart-kit.git resolved at 4.5.2
Creating working copy for https://github.com/apple/swift-algorithms.git
Working copy of https://github.com/apple/swift-algorithms.git resolved at 1.0.0
Building for production...
/root/BAServer/.build/checkouts/wechat/Sources/Wechat/pay/wxpayParam.swift:10:8: error: no such module 'CryptoKit'
import CryptoKit
^
[965/967] Compiling Wechat WxPayError.swift

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants