react-native-star-io10
react-native-star-io10 copied to clipboard
Release Build for IOS
While building release/debug ipa it gives error "Module 'StarIO10' not found"
Same issue. Any advice?
Same issue
I'm not seeing that error on build.
Running on an Apple M1
Did you already run the iOS setup instructions? https://github.com/star-micronics/react-native-star-io10/tree/master/example#ios
The steps which I followed in our project is
yarn add react-native-star-io10 / npm install react-native-star-io10 --save
added in info.plist
- NSBluetoothAlwaysUsageDescription (iOS 13.0 or later)
- NSLocalNetworkUsageDescription (iOS 14.0 or later)
- UISupportedExternalAccessoryProtocols (Add the following value to the array) jp.star-m.starpro
and in ios directory i did pod install
after that when we builkd the project this error shows
I reproduced the same error and was able to resolve it by deleting the cache. Could you try the following process?
- Delete
example.xcworkspace
,Pods
folder, andPodfile.lock
in theexample/ios
folder. - Open "Terminal" app, and move to "example" folder, then do the following commands.
watchman watch-del-all
rm -rf ios/build
rm -rf node_modules
rm -rf ~/Library/Developer/Xcode/DerivedData
yarn install
cd ios
pod install
cd ..
- Open
example.xcworkspace
and do the build.
Experiencing this also as of now my Xcode Version is 12.2. This is happening only when archiving Im stuck with this as of now
any solution ? I'm also stuck with this !!!
I found solution.
Plz add System Header Search Path
like below
"${PODS_ROOT}/../../node_modules/react-native-star-io10/ios/libs/StarIO10.xcframework"
Unfortunately, I have not been able to reproduce this error even when creating an Archive.
If the solution @devStar9211 found doesn't cause this issue, I would be very happy if you could report that to us. We appreciate your cooperation.
@bandit-ibayashi I have the same issue with non debug schemes (in my case test & release). It builds correctly in debug
I've tried all the suggestions that I found here, even what @devStar9211 said :(
I noticed I will always have this error when doing a release build on a simulator but won't hit this error when building on an actual device.
No error on simulator when doing a debug buiild.
I noticed I will always have this error when doing a release build on a simulator but won't hit this error when building on an actual device.
No error on simulator when doing a debug buiild.
Same here. I'm trying to run the simulator in Release mode to get screenshots for the AppStore. Keeps spitting out this error.
Same issue. Any advice?
Same issue for me. Only on XCode 12+ however
I try to restart my Mac, then reinstall it. Now it worked for me.
Try go to Build Phases, then Link Binary with Libraries and Add StarIO10.xcframework
. It works for me.
@piyasil hi, i tested and not work for me.
I got it working after a LOT of trial and error. No idea which one thing actually made it work, but here's what I tried (xcode 12.5.1):
Update Swift version
LIBRARY_SEARCH_PATHS = ( "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", - "\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)\"", + "\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.2/$(PLATFORM_NAME)\"", "\"$(inherited)\"", );
Update ios target to at least ios 12
Update podfile as well as General > Deployment info in XCode
Get rid of Flipper (probably optional)
We dont use it, so no need to have to deal with its problems. Inside podfile:
# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable the next line.
- use_flipper!()
+ # use_flipper!()
Update Cocoapods to latest version
sudo gem install cocapods
Remove armv7 from active architectures
For some reason the lib has only been built for arm64, so change Build settings > Architectures > Architectures to arm64 instead of $(ARCHS_STANDARD)
Clean everything
Make sure to exit xcode before running these commands
watchman watch-del-all
rm -rf ios/build
rm -rf node_modules
rm -rf ~/Library/Developer/Xcode/DerivedData
yarn install
cd ios
pod install
If you've tried any of the suggestions in this post, and are still having issues building, please post a reaction to this comment.
@gare-bear It works if I follow my above list but not building for standard archs means the build is not valid in app store. Would you mind rebuilding and publishing the libs in ios/libs for armv7 as well?
Actually, how come the "ios/libs" folder exists in the first place? I havent seen it in other RN packages.
@joarwilk
Would you mind rebuilding and publishing the libs in ios/libs for armv7 as well?
I cannot but i'll ask @bandit-ibayashi to chime in and see if thats a possibility.
Actually, how come the "ios/libs" folder exists in the first place? I havent seen it in other RN packages.
Because our SDK talks to a piece of hardware, our SDK relies on some native APIs that RN can't offer. So when you build into a native app, each OS has its own set of "libs".
@joarwilk @gare-bear We are looking into. Thank you for your patience.
Thank you @bandit-ibayashi
For reference, here is the actual error (I think?). It precedes the "module not found" error:
warning: [CP] Unable to find matching .xcframework slice in 'framework ios-x86_64-simulator ios-arm64' for the current build architectures (arm64 armv7).
@joarwilk @gare-bear We are looking into. Thank you for your patience.
Thank you. Caught up on the same issue trying to build archive.
For what its worth, so far I've tried the above suggestions for search path and linking in project but still getting 'StarIO10' not found. I'm seeing this issue on my own machine, but also when building on appcenter.ms which sets up a whole new VM to do the build (so unlikely to be an issue with cached pods/data).
@Brendan-csel
I found this new commit: https://github.com/star-micronics/react-native-star-io10/commit/1392dff4d2992b30b70e6a051605f04a08c9fcc2
In there you have a couple changes to the xcode project file.
For me I got it working when i (like in the commit) added "$(SRCROOT)/node_modules/react-native-star-io10/ios/libs"
to FRAMEWORK_SEARCH_PATHS
, as well as added FRAMEWORK_SEARCH_PATH = "$(inherited) $(SRCROOT)/node_modules/react-native-star-io10/ios/libs";
next to it. Not sure if that second change is needed or just a typo but either way it worked!
Not sure why the changelog says May, I know for a fact that commit was not there a short while ago.
Thanks @joarwilk. I'm making a little progress.
I added HEADER_SEARCH_PATHS
and FRAMEWORK_SEARCH_PATHS
(but not FRAMEWORK_SEARCH_PATH
) to my build settings. I still got errors related to this library not having arm7
support so I updated the build setting to also only support arm64
.
After your Clean everything instructions above I can now get the Build Archive to complete - but will still be blocked if we can't publish to at least Test Flight without arm7
support in this library. Is there any way to work around needing that and still get our app out to clients?
Perhaps we can set UIRequiredDeviceCapabilities
to arm64
in Info.plist
in per this article. I'll try this but first time trying to publish to any store so it might take be a while to report back.
Hopefully @bandit-ibayashi will come back with an arm7
solution soon.
I've also noticed that when I restrict the architecture to arm64
, all my simulators disappear in Xcode so I guess they also need armv7
support.
Hello so I had the same issue and this happens because as said above, the framework is not built for armv7
.
This means this can't be shipped for any < iPhone 5s
or any < iPad 5th Gen
device.
What worked for me (I didn't need to target those devices), was to change iOS deployment target
to 12.0
(only iPhone 5s + have this iOS version), and change Architectures
in Build settings
to arm64
@Brendan-csel If the simulator is no longer showing up, could you please do the following if you can?
This is our sample project, and it worked by appling this change.
@Brendan-csel If the simulator is no longer showing up, could you please do the following if you can?
I don't see a Update to recommended settings
option for my application project. There is one for the Pods project but not the application project.
Do you know what changed when you ran that?