Closed AKALugo closed 10 months ago
Cargokit on macOS and iOS builds the project as static library, so linker flags need to be added to the podspec file. (OTHER_LDFLAGS
sections). In this case you're probably missing -framework SystemConfiguration
.
Indeed, the problem was with the SystemConfiguration.framkework, you have to add it in Frameworks and Libraries.
I was using flutter rust bridge and in my Rust code I use the reqwest library to make requests to a server, this application works for Linux, iOS and Android but for MacOS it does not. When I run flutter run in MacOS I get the following error:
This occurs either on a Mac with an M1 processor or with an M3 pro, to make it happen just simply add the Reqwest dependency to the file.
Thinking that this error could be caused by the Cargokit configuration that uses flutter rust bridge, I made the configuration manually and the error occurs again. I also tried to use Surf in case the problem was in Reqwest itself and the error is as follows:
To replicate any of the examples simply: