openimsdk / open-im-sdk-ios

An OpenIM SDK in Objective-C for iOS
https://openim.io
MIT License
159 stars 144 forks source link

iOS12.1 pod starts crashing after importing SDK, but other models start normally #22

Closed appleLK closed 2 years ago

appleLK commented 2 years ago

3801652946629_ pic

std-s commented 2 years ago

3801652946629_ pic

可能和其它sdk产生的关联问题,请排查下。

appleLK commented 2 years ago

demo也是这样呢

printlin commented 8 months ago

Hello, I also found that the SDK does not support iOS 12 system, causing the app to crash every time it is opened. I noticed in the gomobile documentation that there is mention of the -iosversion option, which defaults to 13.0. After modifying it to 12.0 and recompiling, the app can run normally. Please note that this method is for reference only, and thorough testing is recommended. You can find information about gomobile at: https://pkg.go.dev/golang.org/x/mobile@v0.0.0-20240320162201-c76e57eead38/cmd/gomobile. You need to modify the compilation instructions for iOS in the openim-sdk-core/Makefile at line 221, adding -iosversion 12.0. After modification, it should look like this: GOARCH=arm64 gomobile bind -v -trimpath -iosversion 12.0 -ldflags "-s -w" -o build/OpenIMCore.xcframework -target=ios ./open_im_sdk/ ./open_im_sdk_callback/.