9

I am trying to install Cocoa Pods on my new MacBook Pro with the M1 Chip.

There are some solutions that found from December. Since is February those solutions may be a little outdated.

I cannot find any instructions on CocoaPods website. Would anyone be able to help me with that matter? I want to do it right and, sadly, I have little knowledge about that topic.

Many thanks for help.

IPS Brar
  • 346
  • 1
  • 14
Jakub Gawecki
  • 801
  • 2
  • 6
  • 14

4 Answers4

15

These are the steps I followed :

Install HomeBrew in M1 Mac, open the Rosetta Terminal and run the following command :

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

After Homebrew installation is done, run this command in the terminal :

brew install cocoapods
RamithDR
  • 2,103
  • 2
  • 25
  • 34
5

I have mac Pro M1, Try to run on x86_64 architecture:

sudo arch -x86_64 gem install ffi

Then at the root of your project

arch -x86_64 pod install
Matheus Lucas
  • 51
  • 1
  • 1
4

For me was the solution through the Homebrew.

  1. Install Homebrew natively on M1 https://docs.brew.sh/Installation#alternative-installs

  2. Then install Cocoapods https://formulae.brew.sh/formula/cocoapods

Robert Kaločai
  • 170
  • 1
  • 11
0

This worked for me, you should have homebrew

arch -arm64 brew install cocoapods
jkDev 557
  • 21
  • 5