Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run custom shell script 'Copy Pods Resources' error

I have recently been encountering with a Xcode build issue. The error message :

PhaseScriptExecution Copy\ Pods\ Resources /Users/XXX/Library/Developer/Xcode/DerivedData/XXXX-ctiynisxuxnyspgkmjrwbzdlcppc/Build/Intermediates/XXXX.build/Debug-iphonesimulator/XXXX.build/Script-CD61667E1C3E477BBD8B461C.sh
    cd "/Users/XXX/XXXXX/03_Project/XXXX-ios"
    /bin/sh -c /Users/XXX/Library/Developer/Xcode/DerivedData/XXXX-ctiynisxuxnyspgkmjrwbzdlcppc/Build/Intermediates/XXXX.build/Debug-iphonesimulator/XXXX.build/Script-CD61667E1C3E477BBD8B461C.sh

ibtool --errors --warnings --notices --output-format human-readable-text --compile /Users/XXX/Library/Developer/Xcode/DerivedData/XXXX-ctiynisxuxnyspgkmjrwbzdlcppc/Build/Products/Debug-iphonesimulator/XXXX.app/PTEAdjustLevelsCell.nib /Users/XXX/XXXXX/03_Project/XXXX-ios/Pods/LumberjackConsole/Source/Adjust Levels/PTEAdjustLevelsCell.xib --sdk /Applications/Xcode 2.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk
ibtool --errors --warnings --notices --output-format human-readable-text --compile /Users/b03931/Library/Developer/Xcode/DerivedData/XXXX-ctiynisxuxnyspgkmjrwbzdlcppc/Build/Products/Debug-iphonesimulator/detox.app/PTEDashboard.nib /Users/XXX/XXXXX/03_Project/XXXX-ios/Pods/LumberjackConsole/Source/PTEDashboard.xib --sdk /Applications/Xcode 2.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk
Command /bin/sh failed with exit code 255

I guess there is something wrong with the 2 files : PTEAdjustLevelsCell.xib and PTEDashboard.xib but have no idea about how to figure out the wrong point exactly. Can anybody tell me the way how to find the problem? Any hint is welcomed and appreciated.

like image 455
Sabbath Avatar asked Dec 02 '22 15:12

Sabbath


2 Answers

I think below is the case which also cause this error, there might be other configuration changes as well but you can try this thing once.

  • Project's Target

  • Build Phases check for entries Check Pods Manifest.lock and Copy Pods Resources.

  • Check option Run script only when installing if it has not selected.

Clean build & run again.

Hope this may help.

like image 107
sKhan Avatar answered Dec 06 '22 20:12

sKhan


I think this cause by the sdk version and xib compiler tool, but xcode could not fix it, you should do something for fix the ibtool. Solutions in this article:ibtool fail

like image 26
Feng Lin Avatar answered Dec 06 '22 19:12

Feng Lin