sentry-react-native: 'Sentry/Sentry.h' file not found
I’m currently using the following packages:
react-native-sentry: 0.14.5
react-native: 0.46.1
I’ve linked the binary with the sentry library but when i build and try to run my app in the simulator I get the following error: Lexical or Preprocessor Issue: Sentry/Sentry.h file not found - RNSentry.m
I’ve tried cleaning my project in xcode, nuking my node_modules and reinstalling, but still no avail. Any help would be greatly appreciated!
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 7
- Comments: 24 (3 by maintainers)
I`ve tried all solutions in this thread with no success. Using:
Go to ios folder and try this:
I had this issue too and the only thing that solved it was:
$(SRCROOT)/Sentry/Sources
(recursive) to the RNSentry’s target Header Search Paths#import <Sentry/Sentry.h>
with#import "Sentry.h"
Here’s the diff:
Hi,
I too am getting this error, but only when archiving a release build (both on our CI server and locally). Project was successfully linked and the debug configuration compiles / runs perfectly.
Here’s the error xcodebuild returns:
Our app is currently using:
I’ve already tried cleaning the project and derived data locally (in Xcode ⇧⌘K to clean, ⌥⇧⌘K to clean build folder and ⌘, to open Settings > Locations > Derived data & delete the folders content). However this won’t affect our CI server as it’s fresh every time (caching has been disabled to rule out such issues)
I’ve also unlinked and re-linked to no avail (including the fix @HazAT suggests).
Thanks for any help.
I am using xcode 8.2.1 and Bitrise CI uses xcode 8.3, On my system the code builds without any errors and On CI it through this same error.
If I download the code from the repository and do a local build using Bitrise cli tools it also fails with the same error. But the same code builds successfully from xcode 8.2.1 editor.
This error is introduced recently, I didn’t remember when, earlier CI doesn’t have any problem.
‘Sentry/SentryBinaryImageCache.h’ file not found issue is still coming in Latest versions. Please reopen the issue and solve this. Need permanent solution.