-1

I'm trying to run my Flutter app on a real iPhone using flutter run but I keep getting this build error:

/Users/farahabutair/.pub-cache/.../image_picker_ios/messages.g.m:12:9:
error: 'Flutter/Flutter.h' file not found

It's coming from the image_picker_ios package, and it appears multiple times (e.g., messages.g.m, FLTIPImagePickerPlugin.m, etc.)

I tried to clean build and remove derived data and rerun but nothing is working. Flutter Doctor shows no major issues. What could possibly be wrong?

enter image description here [enter image description here](https://i.sstatic.net/gHKiZKIz.png) After updating cocoapods Output after Podfile lock

4
  • Ensure CocoaPods is Installed and up to date. Commented May 27 at 11:35
  • @MunsifAli Thanks! I made sure CocoaPods is installed and updated. I also cleaned and reinstalled pods. But I’m now getting this error from tflite_flutter_helper saying 'Flutter/Flutter.h' file not found. Here's the fullxcode output I see now (screenshot attached). Any idea if I’m missing a link or build setting for this specific plugin? Commented May 27 at 11:45
  • have you tried deleting the Pods folder and Podfile.lock ? Commented May 27 at 12:43
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. Commented May 27 at 14:26

1 Answer 1

0

You need to install this.

rm -rf ios/Pods ios/Podfile.lock
cd ios
pod install --repo-update
cd ..
Sign up to request clarification or add additional context in comments.

1 Comment

Yes I tried :/ Didn't work. I have attached a picture of xcode output after installing this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.