React Native

M1에서 리액트 네이티브 ios 빌드 중 계속되는 오류잡기 (해결 완!)

안루피 2024. 5. 31. 14:11
728x90

너가 잡히나 내가 잡히나 두고보자고

 

 

버전 문제를 해결을 드디어하고 리액트 네이티브 프로젝트 만드는 것까진 꽤나 잘 되었지만....

 

npx react-native run-ios

ios를 빌드하는데 계속된 오류폭탄이 시작되었다.

 

위에까지 엄청 긴 오류인데

여튼 지선생께 여쭤보니

 

npx react-native run-ios 명령어를 실행할 때 발생한 에러는 xcodebuild 명령어가 실패했음을 나타내며, 이는 에러 코드 65로 종료되었습니다. 이 에러는 다양한 원인으로 발생할 수 있으며, 주로 다음과 같은 이유로 발생할 수 있습니다:
1. Xcode 설정 문제: 프로젝트의 설정이나 설정 파일에 문제가 있을 수 있습니다. Xcode에서 직접 프로젝트를 열어 빌드를 시도해보면 좀 더 구체적인 에러 메시지를 확인할 수 있습니다.
2. 의존성 문제: CocoaPods의 의존성 문제일 수 있습니다. pod install을 다시 실행해보거나 Podfile.lock을 삭제한 후 다시 설치해보세요.인증서 및 프로비저닝 프로파일 문제: 올바른 인증서나 프로비저닝 프로파일이 설정되지 않았을 수 있습니다. Xcode에서 해당 설정을 다시 확인해보세요.
3. iOS 시뮬레이터 문제: 현재 사용 중인 iOS 시뮬레이터에 문제가 있을 수 있습니다. 다른 시뮬레이터로 변경해보거나, 시뮬레이터를 재설치해보세요.
4. React Native 환경 설정 문제: React Native의 환경 설정이 올바르지 않을 수 있습니다. react-native doctor 명령어를 실행하여 환경 설정을 점검해보세요.

이 에러를 해결하기 위해 다음과 같은 방법을 시도해보세요:
1. Xcode에서 직접 빌드:Xcode에서 Ddoganzip.xcworkspace 파일을 엽니다.빌드 타겟을 설정한 후 빌드를 시도합니다. 이 과정에서 발생하는 에러 메시지를 확인하여 문제를 해결합니다.
2. CocoaPods 재설치: cd ios pod install --repo-update cd .. npx react-native run-ios
3. React Native 환경 점검: npx react-native doctor

 

그냥 전체적으로 문제가 있다는 것 같은데

그래도 지선생이 알려준데로 CocoaPods 재설치도 해보고 다 해봤으나..

실패.

 

 

자자 오류를 다시보자.

그래서 다시 오류를 보니

 

The following build commands failed:
        CompileC /Users/seungae/Library/Developer/Xcode/DerivedData/Ddoganzip-gtfdbmabmkyxuwadnrehlxpdnavr/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/FlipperKit.build/Objects-normal/arm64/FlipperPlatformWebSocket.o /Users/seungae/Ddoganzip/front/ios/Pods/FlipperKit/iOS/FlipperKit/FlipperPlatformWebSocket.mm normal arm64 objective-c++ cohttp://m.apple.compilers.llvm.clang.1_0.compiler

(in target 'FlipperKit' from project 'Pods') (1 failure)

 

뭔가 FlipperKit이 문제가 있는거라는 힌트 발견.

지선생의 도움을 받는 건 포기하고

in target 'FlipperKit' from project 'Pods' 를 구글에 검색해보았다.

 

https://stackoverflow.com/questions/78244457/reactnative-app-build-failing-with-flipper-error

 

ReactNative App build failing with Flipper error

I have inherited a ReactNative app, that i need to get up and running in dev. I am completely a noob. I think i am close. When I run npm run ios I get the error CompileC /Users/me/Library/Developer/

stackoverflow.com

 

나의 구원자 ....

스택오버플로우 지선생 없는 시절 학교수업들을땐 정말 많이 들어왔는데

아직 지선생 한참 멀어써 너..

여튼!

 

 

 

bundle exec pod install --project-directory=ios 터미널에 입력 후

 

다시 npx react-native run-ios 입력하니...

 

Successfully built the App !!

 

728x90