jeduan / cordova-plugin-facebook4

Use the latest Facebook SDK in your Cordova and Ionic projects
Other
767 stars 511 forks source link

iOS Build failed in version 6.2.0 #829

Closed ColDrekken closed 4 years ago

ColDrekken commented 4 years ago

Hello,

Bug or feature request

[x] I'm reporting a reproducible issue with the code [ ] I'm reporting a feature request

Describe the Bug of feature request

I use cordova-ios 5.0.1 and version 6.2.0 of this plugin. The plugin installation runs well and i was also able to build the app on Android side. But on iOS i was not able to create a build. it always end up with:

BUILD FAILED

The following build commands failed: CompileC /Users/marcelscheuschner/Library/Developer/Xcode/DerivedData/BaseChat-fcbuiojgadbjtpcyimaojjlwemsc/Build/Intermediates.noindex/BaseChat.build/Debug-iphonesimulator/BaseChat.build/Objects-normal/x86_64/FacebookConnectPlugin.o /Users/marcelscheuschner/ionic_apps_shared/basechatgold3_stories_merged4/platforms/ios/BaseChat/Plugins/cordova-plugin-facebook4/FacebookConnectPlugin.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler (1 failure) Error: xcodebuild: Command failed with exit code 65 [ERROR] An error occurred while running subprocess cordova.

    cordova build ios exited with exit code 1.

a few lines before i saw also:

In file included from /Users/marcelscheuschner/ionic_apps_shared/basechatgold3_stories_merged4/platforms/ios/BaseChat/Plugins/cordova-plugin-facebook4/FacebookConnectPlugin.m:13: /Users/marcelscheuschner/ionic_apps_shared/basechatgold3_stories_merged4/platforms/ios/BaseChat/Plugins/cordova-plugin-facebook4/FacebookConnectPlugin.h:13:9: fatal error: 'FBSDKCoreKit/FBSDKCoreKit.h' file not found

import <FBSDKCoreKit/FBSDKCoreKit.h>

    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

1 error generated.

which fits to the docs https://github.com/jeduan/cordova-plugin-facebook4/blob/HEAD/docs/ios/README.md#fbsdkcorekitfbsdkcorekith-file-not-found but im not using cordova-ios blow v5...

Expected Behavior

create a working build without errors

Plugin version, OS, devices, etc

Ionic:

Ionic CLI : 5.4.2 (/usr/local/lib/node_modules/ionic) Ionic Framework : ionic-angular 3.9.8 @ionic/app-scripts : 3.2.1

Cordova:

Cordova CLI : 7.1.0 Cordova Platforms : android 8.0.0, ios 5.0.1 Cordova Plugins : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 1.2.1, (and 32 other plugins)

Utility:

cordova-res : 0.3.0 (update available: 0.8.1) native-run : 0.2.7 (update available: 0.2.9)

System:

ios-deploy : 1.9.2 ios-sim : 8.0.2 NodeJS : v10.16.0 (/usr/local/bin/node) npm : 6.9.0 OS : macOS Mojave Xcode : Xcode 11.0 Build version 11A420a

here my full package.json:

{ "name": "XXXXXX", "version": "3.0.0", "author": "XXXXXX", "homepage": "XXXXXX", "private": true, "scripts": { "clean": "ionic-app-scripts clean", "build": "ionic-app-scripts build", "lint": "ionic-app-scripts lint", "ionic:build": "node --max-old-space-size=8192 ./node_modules/@ionic/app-scripts/bin/ionic-app-scripts.js build", "ionic:serve": "ionic-app-scripts serve" }, "dependencies": { "@angular-devkit/build-optimizer": "^0.13.4", "@angular/common": "5.2.9", "@angular/compiler": "5.2.9", "@angular/compiler-cli": "5.2.9", "@angular/core": "5.2.9", "@angular/fire": "^5.2.1", "@angular/forms": "5.2.9", "@angular/http": "5.1.2", "@angular/platform-browser": "5.2.9", "@angular/platform-browser-dynamic": "5.2.9", "@firebase/polyfill": "^0.3.4", "@ionic-native/action-sheet": "^4.20.0", "@ionic-native/admob-pro": "^4.20.0", "@ionic-native/app-rate": "^4.20.0", "@ionic-native/app-version": "^4.20.0", "@ionic-native/background-mode": "^4.20.0", "@ionic-native/badge": "^4.20.0", "@ionic-native/base64": "^4.20.0", "@ionic-native/call-number": "^4.20.0", "@ionic-native/camera": "^4.20.0", "@ionic-native/camera-preview": "^4.20.0", "@ionic-native/clipboard": "^4.20.0", "@ionic-native/core": "^4.20.0", "@ionic-native/crop": "4.5.2", "@ionic-native/device": "^4.20.0", "@ionic-native/email-composer": "4.5.2", "@ionic-native/facebook": "^4.20.0", "@ionic-native/file": "^4.20.0", "@ionic-native/file-path": "^4.20.0", "@ionic-native/file-transfer": "^4.20.0", "@ionic-native/firebase": "^4.20.0", "@ionic-native/geolocation": "4.5.2", "@ionic-native/globalization": "^4.20.0", "@ionic-native/google-plus": "4.5.2", "@ionic-native/image-picker": "^4.20.0", "@ionic-native/image-resizer": "^4.20.0", "@ionic-native/in-app-browser": "4.5.2", "@ionic-native/in-app-purchase": "^4.20.0", "@ionic-native/in-app-purchase-2": "^4.20.0", "@ionic-native/ionic-webview": "^5.15.0", "@ionic-native/keyboard": "4.5.2", "@ionic-native/media-capture": "^4.20.0", "@ionic-native/native-storage": "4.5.2", "@ionic-native/network": "^4.20.0", "@ionic-native/open-native-settings": "^4.20.0", "@ionic-native/photo-viewer": "^4.20.0", "@ionic-native/sim": "^4.20.0", "@ionic-native/social-sharing": "^4.20.0", "@ionic-native/splash-screen": "4.5.2", "@ionic-native/status-bar": "4.5.2", "@ionic-native/twitter-connect": "4.5.2", "@ionic-native/video-editor": "^4.20.0", "@ionic/storage": "^2.2.0", "@ngx-translate/core": "^9.1.1", "@ngx-translate/http-loader": "^2.0.1", "@types/core-js": "0.9.41", "@types/cropperjs": "^1.1.5", "@types/googlemaps": "3.25.38", "angular-cropperjs": "^0.1.5", "angular2-text-mask": "8.0.4", "animate.css": "^3.7.2", "bourbon": "5.0.0", "call-number": "0.0.2", "com-badrit-base64": "^0.2.0", "cordova-admobsdk": "^7.49.0", "cordova-android": "^8.0.0", "cordova-android-support-gradle-release": "^3.0.1", "cordova-browser": "5.0.4", "cordova-clipboard": "^1.3.0", "cordova-lib": "^9.0.1", "cordova-open-native-settings": "^1.5.2", "cordova-plugin-actionsheet": "^2.3.3", "cordova-plugin-add-swift-support": "^1.7.2", "cordova-plugin-admobpro": "^2.49.0", "cordova-plugin-app-version": "^0.1.9", "cordova-plugin-apprate": "^1.4.0", "cordova-plugin-camera": "^4.1.0", "cordova-plugin-camera-preview": "^0.11.0", "cordova-plugin-crop": "^0.4.0", "cordova-plugin-device": "^2.0.3", "cordova-plugin-dialogs": "^2.0.2", "cordova-plugin-email-composer": "^0.8.15", "cordova-plugin-extension": "^1.5.4", "cordova-plugin-facebook4": "^6.2.0", "cordova-plugin-file": "^6.0.2", "cordova-plugin-file-transfer": "^1.7.1", "cordova-plugin-filepath": "^1.5.6", "cordova-plugin-firebase-lib": "^3.3.0", "cordova-plugin-geolocation": "^4.0.2", "cordova-plugin-globalization": "^1.11.0", "cordova-plugin-googleplus": "^5.3.2", "cordova-plugin-inappbrowser": "^3.1.0", "cordova-plugin-ionic": "^2.0.4", "cordova-plugin-ionic-keyboard": "^2.2.0", "cordova-plugin-ionic-webview": "^1.2.1", "cordova-plugin-localization-strings": "^3.2.0", "cordova-plugin-media-capture": "^3.0.3", "cordova-plugin-nativestorage": "^2.3.2", "cordova-plugin-network-information": "^2.0.2", "cordova-plugin-purchase": "^8.1.1", "cordova-plugin-sim": "^1.3.3", "cordova-plugin-splashscreen": "^4.1.0", "cordova-plugin-statusbar": "^2.4.3", "cordova-plugin-telerik-imagepicker": "^2.3.3", "cordova-plugin-video-editor": "^1.1.3", "cordova-plugin-whitelist": "^1.3.4", "cordova-plugin-x-socialsharing": "^5.6.0", "cordova-sqlite-storage": "^2.6.0", "emoji.json": "^12.0.0", "es6-promise-plugin": "^4.2.2", "exif-js": "^2.3.0", "firebase": "^6.4.2", "google-libphonenumber": "3.0.9", "hammerjs": "^2.0.8", "info.protonet.imageresizer": "^0.1.1", "ionic-angular": "^3.9.8", "ionic-gallery-modal": "^0.2.7", "ionic-image-loader": "^6.3.3", "ionic-img-viewer": "^2.9.0", "ionic-long-press": "^1.5.0", "ionic3-image-cache": "^0.1.4", "ionicons": "3.0.0", "konva": "^3.3.3", "list": "2.0.18", "moment": "^2.24.0", "mx.ferreyra.callnumber": "0.0.2", "ng2-konva": "^6.0.0", "ngx-image-cropper": "^1.3.10", "ngx-moment": "^3.4.0", "rxjs": "^6.5.2", "rxjs-compat": "^6.5.2", "sw-toolbox": "3.6.0", "text-mask-addons": "3.5.1", "time-ago-pipe": "^1.3.2", "time-ago-web-component": "^1.2.2", "videogular2": "6.0.1", "zone.js": "0.8.18", "zuck.js": "^1.3.0" }, "devDependencies": { "@ionic/app-scripts": "^3.2.1", "typescript": "3.5.2" }, "description": "An Ionic project", "cordova": { "plugins": { "cordova-plugin-splashscreen": {}, "cordova-plugin-statusbar": {}, "cordova-plugin-whitelist": {}, "cordova-plugin-nativestorage": {}, "cordova-plugin-x-socialsharing": { "ANDROID_SUPPORT_V4_VERSION": "24.1.1+", "PHOTO_LIBRARY_ADD_USAGE_DESCRIPTION": "This app requires photo library access to function properly.", "PHOTO_LIBRARY_USAGE_DESCRIPTION": "This app requires photo library access to function properly." }, "cordova-plugin-email-composer": {}, "mx.ferreyra.callnumber": {}, "call-number": {}, "com-badrit-base64": {}, "cordova-plugin-file": {}, "cordova-plugin-ionic-keyboard": {}, "cordova-sqlite-storage": {}, "cordova-plugin-geolocation": {}, "cordova-plugin-dialogs": {}, "cordova-plugin-globalization": {}, "cordova-admobsdk": {}, "cordova-plugin-device": {}, "cordova-plugin-sim": {}, "cordova-plugin-apprate": {}, "cordova-plugin-app-version": {}, "cordova-plugin-camera": { "ANDROID_SUPPORT_V4_VERSION": "27.+" }, "cordova-open-native-settings": {}, "cordova-clipboard": {}, "cordova-plugin-file-transfer": {}, "cordova-plugin-firebase-lib": {}, "cordova-plugin-purchase": { "BILLING_KEY": "XXXXXXXXXXXX" }, "cordova-plugin-media-capture": {}, "cordova-plugin-video-editor": {}, "cordova-plugin-actionsheet": {}, "info.protonet.imageresizer": {}, "cordova-plugin-camera-preview": { "ANDROID_SUPPORT_LIBRARY_VERSION": "26+" }, "cordova-plugin-filepath": {}, "cordova-plugin-telerik-imagepicker": { "PHOTO_LIBRARY_USAGE_DESCRIPTION": " " }, "cordova-android-support-gradle-release": { "ANDROID_SUPPORT_VERSION": "27.+" }, "cordova-plugin-crop": {}, "cordova-plugin-network-information": {}, "cordova-plugin-admobpro": { "PLAY_SERVICES_VERSION": "16.0.0", "ADMOB_APP_ID": "XXXXXXXXXXXXXX" }, "cordova-plugin-localization-strings": { "TRANSLATION_PATH": "translations/app/" }, "cordova-plugin-ionic-webview": { "ANDROID_SUPPORT_ANNOTATIONS_VERSION": "27.+" }, "cordova-plugin-inappbrowser": {}, "cordova-plugin-facebook4": { "APP_ID": "of course my nice id", "APP_NAME": "something", "FACEBOOK_HYBRID_APP_EVENTS": "false", "FACEBOOK_ANDROID_SDK_VERSION": "5.5.2" } }, "platforms": [ "browser", "android" ] }, "config": { "ionic_copy": "./config/copy.config.js" } }

Any help on this would be nice

Thx in advanced

peterpeterparker commented 4 years ago

Plz use other channels for support request.

That being said, double check the iOS documentation and other closed issues https://github.com/jeduan/cordova-plugin-facebook4/issues?utf8=✓&q=FBSDKCoreKit.h

ColDrekken commented 4 years ago

Hello @peterpeterparker ,

thx for your response. I followed some stuff on the closed issues.

after modify podfile to:

DO NOT MODIFY -- auto-generated by Apache Cordova

platform :ios, '9.0' use_frameworks! target 'XXXXX' do project 'XXXXX.xcodeproj' pod 'FBSDKCoreKit' pod 'FBSDKLoginKit' pod 'FBSDKShareKit'

end

it seems find the FBSDKCoreKit/FBSDKCoreKit.h but failed with another error:

diff: /Podfile.lock: No such file or directory diff: /Manifest.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.

After searching a bit more around this i found to change PODs Paths in Build Phases form:

diff "${PODS_PODFILE_DIR_PATH}/Podfile.lock" "${PODS_ROOT}/Manifest.lock" > /dev/null if [ $? != 0 ] ; then

print error to STDERR

echo "error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation." >&2
exit 1

fi

to

diff "${SRCROOT}/Podfile.lock" "${SRCROOT}/Manifest.lock" > /dev/null if [ $? != 0 ] ; then

print error to STDERR

echo "error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation." >&2
exit 1

fi

but i leads then into:

Bildschirmfoto 2019-11-04 um 13 53 59

So im still stuck on this... anybody else face that issue?