M1 Firebase, Cocoapods pod install ์—๋Ÿฌ ํ•ด๊ฒฐ(Homebrew)

2021. 7. 29. 22:55ใ†์˜ค๋ฅ˜ ํ•ด๊ฒฐ

Firebase๋ฅผ ์‚ฌ์šฉํ•˜๊ธฐ ์œ„ํ•ด์„œ ๊ตฌ๊ธ€์˜ ์นœ์ ˆํ•œ ๊ณต์‹ ๋ฌธ์„œ๋ฅผ ๋”ฐ๋ผ๊ฐ€๊ณ  ์žˆ์—ˆ๋Š”๋ฐ, pod install์—์„œ ์•„๋ž˜์™€ ๊ฐ™์€ ์—๋Ÿฌ ๋ฉ”์„ธ์ง€๊ฐ€ ๋‚ฌ์Šต๋‹ˆ๋‹ค. ์ด๋ฅผ ํ•ด๊ฒฐํ–ˆ๊ธฐ์— ๊ธฐ๋ก์šฉ์œผ๋กœ ๊ธ€์„ ๋‚จ๊น๋‹ˆ๋‹ค. ์ด ๊ธ€์ด ๋‹ค๋ฅธ ์ดˆ๋ณด ๊ฐœ๋ฐœ์ž๋ถ„๋“ค์—๊ฒŒ ๋„์›€์ด ๋  ์ˆ˜ ์žˆ์—ˆ์œผ๋ฉด ์ข‹๊ฒ ์Šต๋‹ˆ๋‹ค(๋ฏธ๋ž˜์˜ ๋‚˜ ํฌํ•จ)

 

์ด ๊ธ€์„ ๋ด์•ผํ•  ๋ถ„๋“ค:

sudo gem install cocoapods

์œผ๋กœ ์ฝ”์ฝ”์•„ํŒŸ์„ ์„ค์น˜ํ–ˆ๊ณ  pod init ํ•˜๊ณ  Podfile๊ณ ์น˜๊ณ  pod install ํ–ˆ๋Š”๋ฐ ์•„๋ฌด๊ฒƒ๋„ ์•ˆ๋œ๋‹ค!?!?1ํ•˜๋Š” ๋ถ„๋“ค..

 

 

์ € ๊ฐ™์€ ๊ฒฝ์šฐ์—” Firebase๋ฅผ ์ถ”๊ฐ€ํ•ด์ฃผ์—ˆ๋Š”๋ฐ, Firebase๊ฐ€ ๊น”๋ฆฌ์ง€ ์•Š๋Š”๋‹ค๋Š” ์—๋Ÿฌ๊ฐ€ ๋–ด์Šต๋‹ˆ๋‹ค.

๋”๋ณด๊ธฐ

[!] Error installing Firebase

[!] /opt/homebrew/bin/git clone https://github.com/firebase/firebase-ios-sdk.git /var/folders/08/44wlcg3x3d3fn8k956f0nc340000gn/T/d20210729-7474-1uqoc5u --template= --single-branch --depth 1 --branch CocoaPods-8.4.0

 

'/var/folders/08/44wlcg3x3d3fn8k956f0nc340000gn/T/d20210729-7474-1uqoc5u'์— ๋ณต์ œํ•ฉ๋‹ˆ๋‹ค...

์šฐ์„ .. ์—๋Ÿฌ๋ฉ”์„ธ์ง€๊ฐ€ ๋„ˆ๋ฌด ๋ถˆ์นœ์ ˆํ•ด์„œ ์ดํ•ด๋ฅผ ๋ชปํ–ˆ์Šต๋‹ˆ๋‹ค. ์ง€๊ธˆ ํ•ด๊ฒฐํ•˜๊ณ  ๋ณด๋‹ˆ Homebrew ํด๋” ๊ด€๋ จํ•œ ์—๋Ÿฌ์˜€๋˜ ๊ฒƒ ๊ฐ™๋„ค์š”.

 

 

 

์†ํ•ด์žˆ๋˜ iOS Swift ๋‹จํ†ก๋ฐฉ์— M1 pod install ์—๋Ÿฌ๊ฐ€ ๋–ด๋‹ค๊ณ  ๋„์™€๋‹ฌ๋ผ๊ณ  ๋นŒ์—ˆ๋”๋‹ˆ ์—ญ์‹œ ์นœ์ ˆํ•œ ๋ถ„๋“ค์ด ์ •๋ง ๋งŽ์€ ๋‹ต๋ณ€์„ ํ•ด์ฃผ์…จ์Šต๋‹ˆ๋‹ค. M1์—์„œ cocoapods ์—๋Ÿฌ๊ฐ€ ๋‚˜๋ฉด ์ฒดํฌํ•ด์•ผ ํ•  ๊ฒŒ Rosetta ํ„ฐ๋ฏธ๋„๋กœ ์—ด์—ˆ๋Š”์ง€, ์™€ homebrew๋ฅผ ์„ค์น˜ํ–ˆ๋Š๋ƒ ์ž…๋‹ˆ๋‹ค.

ํ„ฐ๋ฏธ๋„ ์†์„ฑ์—์„œ ๋กœ์ œํƒ€ ์„ค์ •์„ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค

brew config

๋ช…๋ น์–ด๋ฅผ ์ณค์„๋•Œ ์ •๋ณด๊ฐ€ ๋‚˜์˜ค์ง€ ์•Š๋Š”๋‹ค๋ฉด Homebrew๋ฅผ ์„ค์น˜ํ•ด์ค๋‹ˆ๋‹ค.(์ด๋•Œ ํ”„๋กœ์ ํŠธ ํŒŒ์ผ์—์„œ ์„ค์น˜ํ•˜๋Š”๊ฒŒ ์•„๋‹ˆ๋ผ /Users/๋‚ด์ด๋ฆ„ํด๋” ์—์„œ ํ•ด์ฃผ์…”์•ผ ํ•ฉ๋‹ˆ๋‹ค. ํ”„๋กœ์ ํŠธ ํŒŒ์ผ์—์„œ ์„ค์น˜ํ•˜๋ฉด homebrew์—๋Ÿฌ๊ฐ€ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค)

 

https://brew.sh/index_ko

 

Homebrew

The Missing Package Manager for macOS (or Linux).

brew.sh

 

์„ค์น˜๊ฐ€ ์™„๋ฃŒ๋˜์—ˆ๋‹ค๋ฉด, ์ด์ œ Xcode ํ”„๋กœ์ ํŠธ ํด๋” ํ„ฐ๋ฏธ๋„๋กœ ๋Œ์•„๊ฐ‘๋‹ˆ๋‹ค.

 

ํ”„๋กœ์ ํŠธ ํŒŒ์ผ์—์„œ

brew install cocoapods

๋ฅผ ์ž…๋ ฅํ•ด์ค๋‹ˆ๋‹ค. sudo gem๊ณผ ๋‹ค๋ฅด์ฃ !!

 

์„ค์น˜๊ฐ€ ์™„๋ฃŒ๋˜๋ฉด ๋˜‘๊ฐ™์ด pod init, pod install ํ•ด์ฃผ๋ฉด ์™„๋ฒฝํ•˜๊ฒŒ ์ž˜ ๋Œ์•„๊ฐ‘๋‹ˆ๋‹ค.

 

์„ค์น˜์™„๋ฃŒ