Flutter how to resolve this issue mac_address - ios

[!] No podspec found for mac_address in .symlinks/plugins/mac_address/ios
I want to retrieve the mac address of my iOS phone.

Related

'Flutter/Flutter.h' file not found

Hello Folks,
When I try to run my project either in xcode or in Android studio in iOS 16.1 device then it says like "error: 'Flutter/Flutter.h' file not found" and "error: failed to emit precompiled header ios/Runner/Runner-Bridging-Header.h".
Following are my current details:
MacOS: 13.0.1 Ventura
Flutter: 3.3.8
Dart: 2.18.4
Android Studion Chipmunk
If anyone have any valid solution to this issue which actually works then it will be very helpful.
Thanks.
I did try following solutions:
https://stackoverflow.com/questions/64973346/error-flutter-flutter-h-file-not-found-when-flutter-run-on-ios
Tried deleting ios flutter and regenerate it.
Tried Flutter clean, pub get, cd ios, pod install, pod update but nothing worked.

Unable to import module app_setings in Xcode - Flutter

I'm currently building a flutter application, which works perfectly in Android.
While trying building it on Xcode, I got one single error
"unable to import module app_settings".
Build target is an IPad air 2020, with an M1 chip inside.
Is there any workaround?
Thank you
Try the following steps in terminal:
flutter pub get
pod init
pod install
Here is the similar problem question answer #jstoe
https://stackoverflow.com/a/66235764/16585144
deleted the Pods file and did flutter run and it built the podfile correctly with flutter pub get.
I think this is the problem with the M1 chip. Try to update your Mac OS and Xcode as well.

Flutter iOS App on an iOS Simulator running on an M1 Mac

Is there an issue with Flutter iOS apps on an iOS simulator (iPhone 12 Pro Max) running on an M1 Mac with Big Sur 11.2.2 and Flutter 1.22.6 ?
You see, my Flutter iOS app (using multiple Flutter plugins) was developed on an Intel-based Mac running Catalina (10.15.7) and Flutter 1.22.5 and it works, but when I moved to an M1 based Mac running Big Sur and Flutter 1.22.6, I’m having the Cocoapod’s error:
[!] Automatically assigning platform `iOS` with version `9.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile.
Note that on this M1 mac, 'flutter doctor' is successful and I can create the Flutter test app and run it on an iOS simulator so I think its setup properly.
I have also tried the solutions suggested with past posts having this symptom to no avail. I have tried the following:
1- I uncommented the line 'platform :ios, '9.0'' in my pods file.
2- I ran the following CLI commands in the terminal:
flutter clean
rm -Rf ios/Pods
rm -Rf ios/.symlinks
rm -Rf ios/Flutter/Flutter.framework
rm -Rf ios/Flutter/Flutter.podspec
cd ios
pod install
cd ..
flutter build ios
The result of trying both suggestions above is the same 'Error running pod install' error with no other error messages mentioned.
The only thing I can think of at this point is that there is a problem with the Flutter plugins I am using when running in an iOS simulator on an M1. Again, these plugins work on an Intel-based Mac running Catalina. If so, unfortunately, the error doesn’t tell me which one. The plugins that I use are:
dependencies:
flutter:
sdk: flutter
provider: ^4.1.3
sqflite: ^1.3.2+1
googleapis: ^0.56.1
googleapis_auth: ^0.2.12
http: ^0.12.2
url_launcher: ^5.7.2
flutter_secure_storage: ^3.3.5
tuple: ^1.0.3
image_picker: ^0.6.7+12
intl: ^0.16.1
fraction: ^1.2.1
archive: ^2.0.13
path_provider: ^1.6.24
path: ^1.7.0
image_cropper: ^1.3.1
flutter_image_compress: ^0.7.0
All help / suggestions greatly appreciated.
It's not yet supported (Coming in this PR)
Flutter has disabled running on simulators running on ARM architecture. They've done this because a flutter dependency (iOS engine Flutter.framework) didn't have arm64 slices. There is an open pull request to add support for iOS simulator on M1 macs (arm64): https://github.com/flutter/flutter/pull/85059
I initially tried to get this working for myself, but the issue is Generated.xcconfig contains code which disables arm64 architecture for the simulator, and this file is generated by Flutter internally. Once you manually change this, it still fails. If you tried to build with Xcode, you might get this error message during the linking process:
Undefined symbol: _OBJC_CLASS_$_ClassName
and lots more. I'd recommend building with Xcode if you don't see enough logs or information to debug the build process.
Automatically assigning platform is not an error
Automatically assigning platform iOS is not actually an error, it's just telling you its defaulted to iOS platform. It then failed, so in this case, you should've provided more error information.
I also faced this issue.
Update iOS version to 10.0 in the podfile.
It worked for me.

ld: in /Users/.../Pods/..., building for iOS Simulator, but linking in object file built for iOS, file '/Users/../Pods/FirebaseAnalyti

Trying to use pod for firebase in my code. Pod successfully installed but having this error.
I found that this error occured while compiling my swift code in macbook M1. Appreciate if anyone could shed some light on this.
Thanks.
Run pod update to update to a more recent version of Firebase. The default install has supported the M1 simulator since the 7.5.0 release.

FIRAnalyticsConnector.framework/FIRAnalyticsConnector' for architecture x86_64 building for Mac Catalyst

I run my project for mac with catalyst, I got a below error. for Firebase
Please see below link for pod file.
/Users/ios/Desktop/xxxxxx/Pods/FirebaseAnalytics/Frameworks/FIRAnalyticsConnector.framework/FIRAnalyticsConnector(FIRConnectorUtils_d79571aba36a7d46e5c6ca87a6fec1c1.o), building for Mac Catalyst, but linking in object file built for iOS Simulator, file '/Users/ios/Desktop/xxxxxx/Pods/FirebaseAnalytics/Frameworks/FIRAnalyticsConnector.framework/FIRAnalyticsConnector' for architecture x86_64
Remove pod Firebase/Analytics from the Podfile.
Firebase Analytics does not currently support Catalyst. Full details about Firebase support for Catalyst at https://github.com/firebase/firebase-ios-sdk#development-for-catalyst.
Add a thumbs-up to https://github.com/firebase/firebase-ios-sdk/issues/4563 to indicate interest in Analytics support.
In the meantime, a workaround to conditionally add Analytics only for iOS, see https://stackoverflow.com/a/58768815/556617
While Cocoapods is not yet supported, I've been able to install and run Firebase Analytics & Crashlytics in a Mac Catalyst app using Swift Package Manager (documentation here)
In Xcode, install the Firebase libraries by navigating to File > Swift Packages > Add Package Dependency…
In the prompt that appears, select the Firebase GitHub repository:
https://github.com/firebase/firebase-ios-sdk.git
Select the desired Frameworks (Analytics, Crashlytics...)
Make sure to add the same frameworks in Build Phases / Link Binary with Libraries of your target.

Resources