Closed chico closed 4 years ago
@chico, thanks for the feedback! I will create a new branch for RN< 60.0 so you can push your changes as a PR.
@Rapsssito the changes that I did I applied locally in my own react native project. I'm not sure how to fix it within the react-native-tcp-socket project since I'm not experienced in native module linking so I'm not sure how 'react-native link' does its linking. I had a look at the iOS project for 1.2.2 https://github.com/Rapsssito/react-native-tcp-socket/blob/v1.2.2/ios/TcpSockets.xcodeproj/project.pbxproj and it looks correct to me so not sure why the linking doesn't work as expected but maybe linking depends on something else that I'm not aware of :/
@chico I am not sure either. Current RN versions rely on automatic linking. I will take a look at your diffs and the project file.
@Rapsssito thanks 👍. If there is no easy fix then maybe you can update the README for RN < 60
on how to do the manual fix after running react-native link react-native-tcp-socket
.
@chico, I have created a new version of react-native-tcp-socket with React Native <=0.59 compatibility: v1.4.0. It should fix this issue and also provide you with the latest fixes and features. You can check out the RN59 branch for the source code. Hope it helps!
@Rapsssito that's awesome, thank you so much, I will try out 1.4.0 soon 🤞
Description
Using React Native 0.59.9, after running
react-native link react-native-tcp-socket
and thenreact-native run-ios
, the iOS build fails withlibrary not found
.I was able to get it working by manually changing the iOS project.pbxproj, as it was incorrectly referencing
TcpSocket.xcodeproj
andlibTcpSocket.a
instead ofTcpSockets.xcodeproj
andlibTcpSockets.a
(so it's just a typo issue 🙂 ). See mygit diff
for manual fix below.Dependencies
react-native 0.59.9 react-native-tcp-socket 1.2.2
Steps to reproduce
Steps to reproduce the behavior:
react-native-tcp-socket
1.2.2 to package.jsonyarn install
react-native link react-native-tcp-socket
react-native run-ios
Current behavior
The iOS build fails with
library not found
as it can't find .Expected behavior
The iOS build works 🤞
Git diff for manual fix
Diff file
diff.txt
Screenshot