Closed minaorangina closed 7 years ago
node_modules/react-native/Libraries/[library name]
.RCT[library-name].xcodeproj
.$ open ios/[your-project-name].xcodeproj
[your-project-name]/Libraries
Note: We found that the react-native library we were interested in (Linking) was already in the xcode project tree under the Libraries
directory - it was called RCTLinking.xcodeproj. If this is the case for you, you can skip steps 1-3.
[your-project-name]/Libraries/RCT[library-name].xcodeproj/Products
.
You'll find a file called libRCT[library-name].a
libRCT[library-name].a
file from the navigation bar to the Link Binary With Libraries section.There's an extra step for certain libraries, see here to decide if this is necessary for you.
If so:
node_modules
directory somewhere).
For the libraries that ship with React Native (e.g. LinkingIOS
or PushNotificationsIOS
), enter your path as:
$(SRCROOT)/../node_modules/react-native/Libraries/[library-name]`
If the library folder has 'relevant' files in nested subdirectories, you will need to register the header as recursive
. Otherwise, non-recursive
is fine.
After this, click the Run button (looks like a 'play' button) at the top-left of the xcode window to build your project. If all goes well, should receive a Build Succeeded message.
This issue was moved to DRDD2016/native#43
Note
22-12-2016 This is necessary for 3rd-party modules that use native code, not for modules that ship with React Native
In particular, this is not necessary for the React Native
Linking
library, contrary to what the docs currently say.