Pod install fails for Flutters video_editor example - xcode

I am able to clone and run flutter video_editor https://github.com/seel-channel/video_editor
in both the iPhone and Android
.
However, if I copy its example part, it works in Android but not on iPhone (physical). Ipod install fails. Please see attached screenhsot.
I am using all the same versions of everything, for the example part as well as the clone part.
Podfile
platform :ios, '9.3'
pubsec.yaml
video_editor:
path: ^1.8.0
helpers: ^1.1.1
image_picker: ^0.8.4
video_player: ^2.2.6
macOS Monterey
version 12.1
xCode version 13.1

It's work for me.
I download example from video editor.
Then in pubspec.yaml file I changed following
# video_editor:
# path: ../
video_editor: ^1.2.2
Then I fire command flutter pub get and pod install it's getting same error you want.
Then after I change platform :ios, '9.3' to platform :ios, '12.1' in pod file and changed deployment info 9.0 to 12.1 in target(Like below image) then fire commane pod install and it's work fine.

Related

xCode build failed: Module 'connectivity_plus' not found

I am developing a flutter app and running on iOS Simulator works fine in Android Studio, and it works well when building from terminal flutter build ios. But when I try to build from xCode (so I can create an archive and release the app), I get this error:
Module 'connectivity_plus' not found
I used to use connectivity, and then the error was Module 'connectivity' not found.
I have found some similar questions, but none of the suggested answers worked for me. I have tried:
flutter clean
rm -rf /ios/Pods
rm -rf /ios/Podfile
rm -rf /ios/Podfile.lock
flutter pub get
cd ios
pod install
I uncomment this line in Podfile:
platform :ios, '13.0'
That is the iOS Deployment Target as well, so they match.
flutter build ios
That works ok, but when I open Runner.xcworkspace in xCode and build, I get the same error. What am I doing wrong?

Flutter project Pod install issue in ios side

I have trying to pod install flutter project in iOS side..but i am unable to install the pod in iOS side
its error show
[!] Invalid Podfile file: no implicit conversion of nil into String.
Fixed It by deleting the Podfile and Podfile.lock in ios folder and then run:
flutter run
or
flutter build ios
That way flutter will generate the new Podfile for flutter

AlamoFire + SwiftyJSON on iOS 9.0

I have been trying to install and use AlamoFire and SwiftyJSON on iOS 9 using CocoaPods. The latest version keeps getting installed and it is not compatible with iOS 9.0.
My PodFile looks like this:
platform :ios, '9.0'
use_frameworks!
target 'Kitchology' do
pod 'Alamofire'
pod 'SwiftyJSON'
pod 'AlamofireImage'
end
I tried commenting them out and doing a pod install to remove them, then put them back in and do another pod install. Every time the latest is installed.
I do have the project itself set to iOS 9.0 and NOT iOS 9.3 for the project build on all versions.
Figured this one out. I deleted the pods by commenting them out and running pod update. Then we deleted the workspace. Then comes the main part of the solution - we deleted everything in the derived data folder. You can find this location in Xcode->Preferences Locations. Although a clean should delete this data, it obviously did not.
Now we recreate the pods again. Do a pod init, add the pods back into the Podfile and do a pod install. Open the workspace and everything was then good.
This was a problem with cached data in Xcode.

Xcode 7.2 not loading classes in libraries installed through Cocoapods

I've started a new iOS project in Xcode and have tried installing some common swift packages like SwiftyJSON and Alamofire through cocoapods. The pods install successfully and the full libraries show up under the root project directory, but whenever I attempt to import them into my project Xcode returns a "No such module.." error.
What I've already done:
- I've cleaned and rebuilt the project
- I've ensured that I'm using the .xcworkspace file after installing the cocoapods
- I've rebooted my mac and xcode
- I've tried linking the binaries in the "build phases" tab in the project settings
- I've tried building the project once before installing pods
All to no avail. Here are the versions I'm using:
- El Capitan 10.11.2
- Xcode 7.2
- Cocoapods 0.39.0
Any and all help/suggestions towards what I may be doing wrong are greatly appreciated!
--EDIT (adding podfile)--
platform :ios, '8.0'
use_frameworks!
target 'newApp' do
pod 'Alamofire'
pod 'SwiftyJSON'
end
Try using the following as your podfile. After changing the podfile dont forget to run pod install.
platform :ios, '8.0'
use_frameworks!
pod 'Alamofire'
pod 'SwiftyJSON'
You can add Alomofire: Project -> Target -> General -> Embedded Libraries -> + -> Alamofire.
As you see in picture:

CocoaPods v0.39.0 errors with Facebook SDK v4.7

Old Cocoapods Configuration
I am using Xcode 7 Beta 4. Initially I was using Cocoapods version 0.38.2 and when I ran pod install --verbose in Terminal it said it downloaded dependencies for Bolts, FBSDKCoreKit, FBSDKLoginKit, FBSDKShareKit, FBSDKMessengerShareKit, and Pods for iOS 8.1. With this setup my app compiled successfully. Below is the Podfile and Objective-C Bridging File that I used to import the Facebook SDK (so Swift recognises its referenced methods and Objective-C classes). Note that the specific versions shown in my Podfile are also the versions that get installed even if I do not explicitly specify them at the time of this writing.
Podfile
xcodeproj '/Users/<my_username>/MyApp/MyApp.xcodeproj'
pod "FBSDKCoreKit", "~> 4.7.0";
pod "FBSDKLoginKit", "~> 4.7.0";
pod "FBSDKShareKit", "~> 4.7.0";
pod "FBSDKMessengerShareKit", "~> 1.3.1";
MyAppObjCBridging.h
#ifndef MyAppObjCBridging_h
#define MyAppObjCBridging_h
#import <FBSDKCoreKit/FBSDKCoreKit.h>
#import <FBSDKLoginKit/FBSDKLoginKit.h>
#import <FBSDKMessengerShareKit/FBSDKMessengerShareKit.h>
#import <FBSDKShareKit/FBSDKShareKit.h>
#endif
Problems encountered when updating to Cocoapods v0.39.0 (from v0.38.2)
The console showed the message "CocoaPods 0.39.0 is available. To update use: gem install cocoapods. Until we reach version 1.0 the features of CocoaPods can and will change. We strongly recommend that you use the latest version at all times.", so I installed the this latest version of Cocoapods 0.39.0 by executing sudo gem install cocoapods in Terminal.
But when I compiled my app it gave me the following errors:
/Users//MyApp/MyApp/MyAppObjCBridging.h:14:9: 'FBSDKCoreKit/FBSDKCoreKit.h' file not found
In Xcode I "Product > Clean" (CMD+SHIFT+K), but this did not make any difference. So I ran sudo gem uninstall cocoapods in Terminal (which listed 0.38.2 and 0.39.0 as the versions that were currently installed) and selected version 0.39.0 from the list to uninstall the latest version and revert back to 0.38.2. I then ran pod install --verbose. When I tried to compile my app it compiled successfully and ran in Simulator again.
Question 1
Why does it give the error that it can't find "FBSDKCoreKit/FBSDKCoreKit.h" when I use Cocoapods version 0.39.0 instead of the older version 0.38.2?
Question 2
If when using Cocoapods version 0.38.2 (the version that compiles with my app) I decided to add platform :ios, '9.0' to the first line of my Podfile (above its existing contents) and run pod install --verbose in Terminal, the Terminal messages tell me that it installs each pod target for iOS 9.0 (instead of iOS 8.1) (i.e. - Installing targetFBSDKCoreKitiOS 9.0).
When I then run my app it successfully compiles and opens in Simulator and displays some new warnings associated with iOS9, most of which I understand. However I do not understand why this one appears. Why is this warning appearing?:
ld: warning: directory not found for option '-L/Users/Ls/code/swift/FreeWifiSearch/FreeWifiSearch/build/Debug-iphoneos'
Question 3
When using Cocoapods version 0.38.2 (the version that compiles with my app), if I decided to add use_frameworks! to the first line of my Podfile, and platform :ios, '9.0' to the second line of my Podfile (above its existing contents), and then run pod install --verbose in Terminal, the Terminal messages tell me that it installs each pod target for iOS 9.0 (instead of iOS 8.1).
When I then run my app the following errors appear:
Use of unresolved identifier 'FBSDKLoginButton'
Use of unresolved identifier 'FBSDKLoginManager'
Use of unresolved identifier 'FBSDKLoginBehaviour'
Why does adding use_frameworks! to the top of my Podfile prevent me from using the Facebook SDK identifiers? (noting that when I don't have use_frameworks! at the top of my Podfile my app successfully compiles and runs in Xcode Simulator, and I can successfully retrieve a Facebook SDK Access Token and login to Facebook)
Since posting the original questions the following was performed and resulted in no compiler errors:
Updated from Xcode 7 Beta 4 to Xcode 7.1.1 by downloading latest from App Store
Added use_frameworks! and platform :ios, '9.0' to top of Podfile
Changed deployment target to iOS 9.0: Project Settings > Targets > General > Deployment Info > Deployment Target > 9.0
Updated CocoaPods to v0.39 with sudo gem install cocoapods
Reinstalled pods with pod update --verbose
Added import FBSDKLoginKit above the class containing Facebook SDK methods
Performed Clean (Shift+CMD+K) and Run (CMD+R) in Xcode to test on device
Add "${PODS_ROOT}/Headers/Public/FBSDKCoreKit/FBSDKCoreKit" in your target's Header Search Paths in Build Settings
For me it's OK now(CocoaPods 0.39, FBSDK 4.10)

Resources