Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IOS - clang: error: linker command failed with exit code 1 (use -v to see invocation) #1429

Closed
codingwithashu opened this issue Nov 14, 2023 · 22 comments
Labels

Comments

@codingwithashu
Copy link

Your Environment

  • Plugin version: 4.15.3
  • Platform: iOS or Android - IOS
  • OS version: macbook air 2
  • Device manufacturer / model:
  • Cordova version (cordova -v): 12.0.0 (cordova-lib@12.0.1)
  • Cordova platform version (cordova platform ls):
  • Plugin config provided to #ready:

com.ourcodeworld.appinstalled 1.0.0 "Our Code World App Installed"
cordova-background-geolocation-lt 4.15.3 "BackgroundGeolocation"
cordova-plugin-actionsheet 2.3.3 "ActionSheet"
cordova-plugin-android-permissions 1.1.3 "Permissions"
cordova-plugin-androidx-adapter 1.1.3 "cordova-plugin-androidx-adapter"
cordova-plugin-appavailability 0.4.2 "AppAvailability"
cordova-plugin-background-fetch 7.2.1 "CDVBackgroundFetch"
cordova-plugin-camera-preview 0.12.3 "cordova-plugin-camera-preview"
cordova-plugin-camera 6.0.1-dev "Camera"
cordova-plugin-cszbar 1.3.2 "ZBar barcode scanner"
cordova-plugin-device 2.0.2 "Device"
cordova-plugin-dialogs 2.0.2 "Notification"
cordova-plugin-file-opener2 3.0.5 "File Opener2"
cordova-plugin-file-transfer 2.0.0 "File Transfer"
cordova-plugin-file 8.0.1-dev "File"
cordova-plugin-googlemaps 2.7.1 "cordova-plugin-googlemaps"
cordova-plugin-ionic-keyboard 2.2.0 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 5.0.0 "cordova-plugin-ionic-webview"
cordova-plugin-network-information 3.0.0 "Network Information"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
ionic-plugin-deeplinks 1.0.22 "Ionic Deeplink Plugin"
onesignal-cordova-plugin 3.0.4 "OneSignal Push Notifications"
uk.co.workingedge.phonegap.plugin.launchnavigator 5.0.6 "Launch Navigator"


## Context
d: warning: Could not find or use auto-linked framework 'CoreAudioTypes': framework 'CoreAudioTypes' not found
ld: Undefined symbols:
  _OBJC_CLASS_$_DDASLLogger, referenced from:
       in TSLocationManager[arm64][15](TSLog.o)
  _OBJC_CLASS_$_DDAbstractDatabaseLogger, referenced from:
      _OBJC_CLASS_$_TSDBLogger in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_CLASS_$_DDLog, referenced from:
       in TSLocationManager[arm64][3](LocationAuthorization.o)
  _OBJC_CLASS_$_DDOSLogger, referenced from:
       in TSLocationManager[arm64][15](TSLog.o)
  _OBJC_CLASS_$_DDTTYLogger, referenced from:
       in TSLocationManager[arm64][15](TSLog.o)
  _OBJC_IVAR_$_DDAbstractDatabaseLogger._maxAge, referenced from:
      -[TSDBLogger getLog:] in TSLocationManager[arm64][8](TSDBLogger.o)
      -[TSDBLogger db_delete] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDAbstractDatabaseLogger._saveThreshold, referenced from:
      -[TSDBLogger initWithLogDirectory:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDAbstractLogger._logFormatter, referenced from:
      -[TSDBLogger db_log:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDLogMessage._context, referenced from:
      -[TSDBLogEntry initWithLogMessage:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDLogMessage._flag, referenced from:
      -[TSDBLogEntry initWithLogMessage:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDLogMessage._message, referenced from:
      -[TSDBLogEntry initWithLogMessage:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_IVAR_$_DDLogMessage._timestamp, referenced from:
      -[TSDBLogEntry initWithLogMessage:] in TSLocationManager[arm64][8](TSDBLogger.o)
  _OBJC_METACLASS_$_DDAbstractDatabaseLogger, referenced from:
      _OBJC_METACLASS_$_TSDBLogger in TSLocationManager[arm64][8](TSDBLogger.o)
clang: error: linker command failed with exit code 1 (use -v to see invocation)


@christocracy
Copy link
Member

Remove / re-add the Cordova ios platform.

@codingwithashu
Copy link
Author

did still same error

@christocracy
Copy link
Member

What version of XCode are you using?

@codingwithashu
Copy link
Author

Version 15.0.1 (15A507)

@christocracy
Copy link
Member

show me your platforms/ios/Podfile

@codingwithashu
Copy link
Author

DO NOT MODIFY -- auto-generated by Apache Cordova

source 'https://cdn.cocoapods.org/'
platform :ios, '11.0'

target 'SOS Lite' do
project 'SOS Lite.xcodeproj'
pod 'CocoaLumberjack', '3.7.2'
end

@christocracy
Copy link
Member

In that folder, run $ pod install

@codingwithashu
Copy link
Author

Analyzing dependencies
Downloading dependencies
Generating Pods project
Integrating client project
Pod installation complete! There is 1 dependency from the Podfile and 1 total pod installed.

[!] The SOS Lite [Debug] target overrides the PODS_PODFILE_DIR_PATH build setting defined in Pods/Target Support Files/Pods-SOS Lite/Pods-SOS Lite.debug.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(inherited)` flag, or
- Remove the build settings from the target.

[!] The SOS Lite [Debug] target overrides the PODS_ROOT build setting defined in Pods/Target Support Files/Pods-SOS Lite/Pods-SOS Lite.debug.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(inherited)` flag, or
- Remove the build settings from the target.

[!] The SOS Lite [Release] target overrides the PODS_PODFILE_DIR_PATH build setting defined in Pods/Target Support Files/Pods-SOS Lite/Pods-SOS Lite.release.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(inherited)` flag, or
- Remove the build settings from the target.

[!] The SOS Lite [Release] target overrides the PODS_ROOT build setting defined in Pods/Target Support Files/Pods-SOS Lite/Pods-SOS Lite.release.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(inherited)` flag, or
- Remove the build settings from the target.

@christocracy
Copy link
Member

I suggest you follow the instructions in the warning:

The SOS Lite [Debug] target overrides the PODS_PODFILE_DIR_PATH build setting defined in Pods/Target Support Files/Pods-SOS Lite/Pods-SOS Lite.debug.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(inherited)` flag, or

  • Remove the build settings from the target.

@codingwithashu
Copy link
Author

If i remove that , getting new error
index/SOS\\ Lite.build/Debug-iphonesimulator/SOS\\ Lite.build/Script-6D4D156ED98FDAF483AC4DE8.sh
diff: /Podfile.lock: No such file or directory
error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.

and also in platforms/ios -- run pod install then also same

@christocracy
Copy link
Member

I have no idea what's wrong with your app.

I suggest you attempt to reproduce this in a simple HelloWorld app.

@codingwithashu
Copy link
Author

@christocracy
Copy link
Member

Your zipfile is messed up, it contains a weird __MACOS folder with an apparent duplicate of the folder ionictest.

Also, you added the node_modules folder to your zip file.

While attempting to run $ ionic cordova build ios:

Screenshot 2023-11-14 at 1 00 47 PM

Publish your demo app to a public Git repo instead and share the url here.

@christocracy
Copy link
Member

Did you actually test your helloworld before sending it to me?

@codingwithashu
Copy link
Author

I have tested getting same error

@christocracy
Copy link
Member

Publish your hello-world to a public repository and post the link here.

@codingwithashu
Copy link
Author

@christocracy
Copy link
Member

$ git clone ...
$ npm install
$ ionic cordova platform add ios
$ ionic cordova build ios
Screenshot 2023-11-14 at 1 00 47 PM

@codingwithashu
Copy link
Author

Try to install - npm install @ionic/cordova-builders

@christocracy
Copy link
Member

I'm not going to manually install anything on my end. Give me a simple hello-world app that works out of the box.

Copy link

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Apr 17, 2024
Copy link

github-actions bot commented May 1, 2024

This issue was closed because it has been inactive for 14 days since being marked as stale.

@github-actions github-actions bot closed this as completed May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants