gchamoun
gchamoun

Reputation: 55

Flutter iOS Build Error: framework not found Flutter

I am able to run the app in android studios but whenever I try in xcode I get a flutter framework not found.

Upvotes: 4

Views: 15691

Answers (10)

abdulrahman albeladi
abdulrahman albeladi

Reputation: 73

I performed below steps and it worked with me:

Go to Build Settings for your target (Runner):

Ensure Build Active Architecture Only is set to NO for both Debug and Release.

Ensure Valid Architectures includes arm64.

Ensure Excluded Architectures is empty.

Go to General > Frameworks, Libraries, and Embedded Content:

Ensure Flutter.framework is listed and set to Embed & Sign.

Upvotes: 0

SmileYang966
SmileYang966

Reputation: 41

Please try the following steps:

  1. Delete the flutter SDK
  2. Download the same flutter SDK and re-install it
  3. restart the android studio It should be worked well.

Upvotes: 0

Lutfor Rahman
Lutfor Rahman

Reputation: 95

  1. Delete the flutter directory.

  2. Download new flutter

  3. Extract it and put it where you want.

  4. Run the command export PATH="$PATH:`pwd`/flutter/bin" if the command does not work then specify your path like bellow

    export PATH="$PATH: /Users/{your user name}/Documents/src/flutter/bin"

Restart your machine and you are ready to go.

After that - inside your project's ios directory -

  1. delete the .symlink directory
  2. delete the Pods directory
  3. delete the Podfile.lock file

and now run -

  1. flutter clean
  2. flutter packages upgrade
  3. flutter build ios

Upvotes: 1

Nawaf Sh
Nawaf Sh

Reputation: 21

I was facing the same error whene I try to archive in Xcode I fixed it by

flutter upgrade

and

flutter run

Upvotes: 2

Noor Abdi
Noor Abdi

Reputation: 37

I tried everything nothing worked except:-

Flutter upgrade Flutter run

and boom- Build succeeded!

Upvotes: 0

xin huang
xin huang

Reputation: 11

I fixed this by switching to the master channel, and switching back to the stable channel. Also remember to run 'flutter upgrade' after switching.

Upvotes: 1

Delicia Fernandes
Delicia Fernandes

Reputation: 619

For me nothing worked except, deleting my flutter files fully and reinstalling.

Use this flutter docs for reinstallation: Flutter Installation Link

Upvotes: 0

Ramesh Maharjan
Ramesh Maharjan

Reputation: 41957

upgrade your flutter by doing

flutter upgrade

and it will upgrade the engine and download necessary tools.

This will even kill flutter daemons.

And run the application again

flutter run

Upvotes: 8

Sukhi
Sukhi

Reputation: 14145

  1. Make sure you open .xcworkspace (and not .xcodeproj in XCode).
  2. Ensure you have 'Flutter.Framework' listed under "Linked Frameworks and Libraries". If not, just drag and drop it from the main project. Like below enter image description here

Upvotes: 2

gchamoun
gchamoun

Reputation: 55

Fixed by switching branches from beta to master

Upvotes: -3

Related Questions