AppsFlyerSDK / appsflyer-cordova-plugin

AppsFlyer plugin for Cordova
MIT License
37 stars 71 forks source link

Installing plugin on iOS fails "with exit code ENOENT" #194

Open nijakobius opened 2 years ago

nijakobius commented 2 years ago

Report

Plugin Version

6.4.0

On what Platform are you having the issue?

ios

What did you do?

Installing via cordova plugin add cordova-plugin-appsflyer-sdk

Installing "cordova-plugin-appsflyer-sdk" for android
Subproject Path: CordovaLib
Subproject Path: app
Installing "cordova-plugin-appsflyer-sdk" for browser
Installing "cordova-plugin-appsflyer-sdk" for ios
Failed to install 'cordova-plugin-appsflyer-sdk': Error: pod: Command failed with exit code ENOENT
    at ChildProcess.whenDone (/Users/[USERNAME]/[APPNAME]/node_modules/cordova-common/src/superspawn.js:136:25)
    at ChildProcess.emit (events.js:315:20)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:273:12)
    at onErrorNT (internal/child_process.js:469:16)
    at processTicksAndRejections (internal/process/task_queues.js:84:21)
pod: Command failed with exit code ENOENT

Afterwards, the plugin "appears" to be installed, i.e. cordova plugin shows: cordova-plugin-appsflyer-sdk 6.4.0 "AppsFlyer" and there is also a folder platforms/ios/www/plugins/cordova-plugin-appsflyer-sdk.

What happened instead?

However, when trying to build my app in XCode, I get the following errors:

Undefined symbols for architecture arm64:
  "_OBJC_CLASS_$_AppsFlyerCrossPromotionHelper", referenced from:
      objc-class-ref in AppsFlyerPlugin.o
  "_OBJC_CLASS_$_AppsFlyerShareInviteHelper", referenced from:
      objc-class-ref in AppsFlyerPlugin.o
  "_OBJC_CLASS_$_AppsFlyerLib", referenced from:
      objc-class-ref in AppsFlyerPlugin.o
      objc-class-ref in AppsFlyerAttribution.o
      objc-class-ref in AppsFlyerX+AppController.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Undefined symbol: _OBJC_CLASS_$_AppsFlyerCrossPromotionHelper
Undefined symbol: _OBJC_CLASS_$_AppsFlyerShareInviteHelper
Undefined symbol: _OBJC_CLASS_$_AppsFlyerLib

Please provide any other relevant information.

I am using cordova version 11.0.0 and cordova ios 6.2.0.

pazlavi commented 2 years ago

Hi @nielsjakob , Thank you for reaching out to us.

The issue might be similar to #175 . Please note that this is not an issue with the plugin itself, but it is usually related to the environment. Please also run pod install or pod install --repo-update in the platform/ios directory and see if Cocoapods succeeded in installing the AppsFlyer iOS SDK.