Sjors / libwally-swift

Swift wrapper for LibWally, a collection of useful primitives for cryptocurrency wallets
MIT License
40 stars 18 forks source link

Use framework breaks printing with LLDB #78

Closed jurvis closed 2 years ago

jurvis commented 2 years ago

When importing libwally-swift as a framework via Cocoapods, we get this error when trying to do po in LLDB

error: expression failed to parse:
error: virtual filesystem overlay file '/.../LibWally/IntermediateBuildFilesPath/LibWally.build/Release-iphonesimulator/LibWally.build/all-product-headers.yaml' not found
error: virtual filesystem overlay file '/.../LibWally/IntermediateBuildFilesPath/LibWally.build/Release-iphonesimulator/LibWally.build/all-product-headers.yaml' not found

error: couldn't IRGen expression. Please check the above error messages for possible root causes.
error: couldn't IRGen expression. Please check the above error messages for possible root causes.

The cause is fairly well documented in the following LLVM issues: https://github.com/apple/llvm-project/issues/4467 https://github.com/apple/llvm-project/issues/4464

And a great summary can be found here: https://steipete.com/posts/couldnt-irgen-expression

jurvis commented 2 years ago

I'm working on a fix now + doing some testing. Will submit a PR soon(ish)