question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Branch.h - iOS build doesn't work

See original GitHub issue

Hello there, I’m also facing the issue with the missing Branch.h-File… Even tho I upgraded to the lastest cocoapods-release (1.9.1).


   Ionic CLI                     : 6.3.0 (/usr/local/lib/node_modules/@ionic/cli)
   Ionic Framework               : @ionic/angular 4.11.10
   @angular-devkit/build-angular : 0.803.25
   @angular-devkit/schematics    : 8.3.25
   @angular/cli                  : 8.3.25
   @ionic/angular-toolkit        : 2.1.2

Cordova:

   Cordova CLI       : 9.0.0 (cordova-lib@9.0.1)
   Cordova Platforms : ios 5.1.1
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.1.3, (and 25 other plugins)

Utility:

   cordova-res : 0.10.0
   native-run  : 0.3.0

System:

   ios-deploy : 1.9.4
   ios-sim    : 8.0.2
   NodeJS     : v10.15.3 (/usr/local/bin/node)
   npm        : 6.4.1
   OS         : macOS Mojave
   Xcode      : Xcode 11.3.1 Build version 11C505

Installed plugins:

$ cordova plugin ls
branch-cordova-sdk 4.1.2 "branch-cordova-sdk"
com.googlemaps.ios 3.5.0 "Google Maps SDK for iOS"
cordova-open-native-settings 1.5.2 "Native settings"
cordova-plugin-add-swift-support 2.0.2 "AddSwiftSupport"
cordova-plugin-androidx 1.0.2 "cordova-plugin-androidx"
cordova-plugin-androidx-adapter 1.1.0 "cordova-plugin-androidx-adapter"
cordova-plugin-app-version 0.1.9 "AppVersion"
cordova-plugin-appavailability 0.4.2 "AppAvailability"
cordova-plugin-background-mode 0.7.3 "BackgroundMode"
cordova-plugin-badge 0.8.8 "Badge"
cordova-plugin-camera 4.1.0 "Camera"
cordova-plugin-customurlscheme 5.0.0 "Custom URL scheme"
cordova-plugin-device 2.0.3 "Device"
cordova-plugin-enable-multidex 0.2.0 "Enable Multidex"
cordova-plugin-firebasex 9.0.1-cli "Google Firebase Plugin"
cordova-plugin-googlemaps 2.7.0-20191107-1035 "cordova-plugin-googlemaps"
cordova-plugin-inappbrowser 3.2.0 "InAppBrowser"
cordova-plugin-ionic-keyboard 2.2.0 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 4.1.3 "cordova-plugin-ionic-webview"
cordova-plugin-local-notification 0.9.0-beta.3 "LocalNotification"
cordova-plugin-market 1.2.0 "Market"
cordova-plugin-network-information 2.0.2 "Network Information"
cordova-plugin-qrscanner-dual 3.0.1 "QRScanner"
cordova-plugin-safariviewcontroller 1.6.0 "SafariViewController"
cordova-plugin-splashscreen 5.0.3 "Splashscreen"
cordova-plugin-statusbar 2.4.3 "StatusBar"
cordova-plugin-whitelist 1.3.4 "Whitelist"
cordova.plugins.diagnostic 5.0.1 "Diagnostic"
skwas-cordova-plugin-datetimepicker 2.0.0-alpha1 "DateTime picker"

I previously had installed an old cocoapods-version (1.7.2) and did now a clean update/reinstall to the newest version:

$ gem list --local | grep cocoa
cocoapods (1.9.1)
cocoapods-core (1.9.1)
cocoapods-deintegrate (1.0.4)
cocoapods-dependencies (1.3.0)
cocoapods-downloader (1.3.0)
cocoapods-plugins (1.0.0)
cocoapods-search (1.0.0)
cocoapods-stats (1.1.0)
cocoapods-trunk (1.4.1)
cocoapods-try (1.1.0)
$ pod repo list

cocoapods
- Type: git (master)
- URL:  https://github.com/CocoaPods/Specs.git
- Path: /Users/xxx/.cocoapods/repos/cocoapods

trunk
- Type: CDN
- URL:  https://cdn.cocoapods.org/
- Path: /Users/xxx/.cocoapods/repos/trunk

2 repos

But if I try to build via CLI it gives me following error:

** ARCHIVE FAILED **


The following build commands failed:
        CompileC /Users/xxx/Library/Developer/Xcode/DerivedData/xxx-grzgetsogbfrvkgrgaboqjaroujn/Build/Intermediates.noindex/ArchiveIntermediates/xxx\ Ionic\ 4/IntermediateBuildFilesPath/xxx\ Ionic\ 4.build/Debug-iphoneos/xxx.build/Objects-normal/arm64/BranchSDK.o /Users/xxx/Documents/xxx/src/Applications/xxx/platforms/ios/xxx/Plugins/branch-cordova-sdk/BranchSDK.m normal arm64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
xcodebuild: Command failed with exit code 65

–>

/Users/xxx/Documents/xxx/src/Applications/xxx/platforms/ios/xxx/Plugins/branch-cordova-sdk/BranchSDK.h:4:9: fatal error: 
      'Branch.h' file not found
#import "Branch.h"
        ^~~~~~~~~~
1 error generated.

Please let me know if you need any further information! Thanks in advance

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:8
  • Comments:29 (5 by maintainers)

github_iconTop GitHub Comments

7reactions
Sroosecommented, May 26, 2020

Thanks @SidiBecker ! Actually the search headers are the only thing we needed to get this working.

I’ve created a hook which can be added to your Ionic project which will fix (workaround) the issue by adding these 2 header search paths automatically: https://gist.github.com/Sroose/d3db4178babbab1b39b68e9889e7869b

@ Branch team, I think this should be fixed in the Pod?

3reactions
AleCat83commented, May 8, 2020

I have the same issue with version 4.1.3 and ionic 3 when building for IOS. I can build using xcode and that is fine but I can’t use ionic run with livereload because the build error kill the live reload server. This is slowing down the our development process a lot. Can’t even go back to plugin 3X due to the UIWebView and apple rejection problem (ITMS-90809). Is this going to be fixed in a new release or is there a workaround? Thanks

Read more comments on GitHub >

github_iconTop Results From Across the Web

'Branch.h' file not found Xcode error for Ionic 3 app
When I am trying to build my Ionic 3 app in ios device from Xcode, I am getting the following error. The error...
Read more >
iOS Basic Integration - Branch Help
Configure the default link settings for your appMake sure I have an iOS app is enabled Apple App Prefix is your Team ID...
Read more >
"Build input file cannot be found" | Apple Developer Forums
I had this problem too. Basically, go to the main project at the top of the Project Navigator, select on the Target in...
Read more >
Common Build Problems - Travis CI Docs
Restart a build that used to be green, the last known working one, for instance. If that build suddenly fails too, there's a...
Read more >
Branch Metrics React Native SDK Reference - npm
This is a repository of our open source React Native SDK. ... Also note that CocoaPods 1.7.0 breaks iOS builds using the react-native-branch...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found