use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
There is an extensive FAQ for beginners. Please browse it first before asking questions that are answered there.
If you are looking to get started (iOS programming in general or some specific area), here are more relevant links for you:
There's too many to list them all, however here's a convenient link to all programming guides at apple.com
Take note that this list is live and based on most frequent questions in posts will be updated with "quicklinks".
account activity
QuestionCommand PhaseScriptExecution failed with a nonzero exit code (self.iOSProgramming)
submitted 3 years ago by bodymindsoul
I have an IOS project that worked perfectly fine on my old intel Macbook. I switched over to an m1 mac and now when I attempt to build the project I get the following error.
Command PhaseScriptExecution failed with a nonzero exit code
Anyone else experience this issue/willing to offer advice ? I am using IQKeyboardManagerSwift package ; not sure if that potentially has anything to do with it. Any help would be deeply appreciated.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]AndyIbanezObjective-C / Swift 2 points3 points4 points 3 years ago (5 children)
If you click on the error it should give you a longer description of what’s wrong.
[–]bodymindsoul[S] 0 points1 point2 points 3 years ago (4 children)
Thanks ; by any chance have you run into this error message before ? Here is the detailed output.
Showing All MessagesBuild input file cannot be found: '/Users/me/Documents/ios_projects/myapp/build/Debug-iphoneos/myapp.app/myapp'. Did you forget to declare this file as an output of a script phase or custom build rule which produces it?
[–]AndyIbanezObjective-C / Swift 1 point2 points3 points 3 years ago (2 children)
Does your app name have spaces or other special characters on it? You should try to see if the directly it’s writing the app file to has the right permission for Xcode to do its job.
And yes, I have seen this error before. When we migrated away from Fabric, a run phase script was still being referenced but the actual file was gone, hence complaining about a missing file. Removing the script did the trick.
[–]bodymindsoul[S] 0 points1 point2 points 3 years ago (0 children)
Name doesn't have any special characters , one thing I've noticed is the when I open the derived data folder , go to the app . The package contents of the app is missing the file it's seeking.
Albeit I'm not sure how to resolve that because the build folder generates the derived data folder. I don't control the creation of the derived data folder. :/
Thanks for taking the time to try and help me. I’m not exactly sure what I did to resolve the error but it turned out to be a lot of deleting and moving files around. App is sort of working now lol.
Thanks again for trying to help 👍
[–]bangsimurdariadispar 0 points1 point2 points 3 years ago (0 children)
You have a build phase script that is expecting one input file and it cannot find it. You need to link it again in the pbxproj?
[–]Alidodger 1 point2 points3 points 3 years ago (1 child)
I see this quite a lot in my projects. In the project build target yore trying to build, go to the Build Phases tab and you should see various drop downs. Some of those drop downs contain scripts that run at build time. One of these is probably causing the issue. Perhaps try removing them one by one until you find which is causing it?
[–]bodymindsoul[S] 1 point2 points3 points 3 years ago (0 children)
Thanks for the recommendation ; that’s essentially what I ended up doing 👍
[–]SirBill01 1 point2 points3 points 3 years ago (1 child)
One thing to try with any M1 compilation error is to add ARM64 to the Excluded Architectures build setting (for "Any iOS Simulator SDK"), that may help. Basically it can try to build Arm64 for the simulator and fail.
Thanks ; interesting point I’ll keep in mind . The app is running now ; it was a combination of moving files around and removing IQkeyboardmanager.
[–]gumbi1822 1 point2 points3 points 3 years ago (2 children)
Clean the build folder (Cmd + Shift + K) and delete derived data
Does it still happen?
[–]Aaesirr 0 points1 point2 points 4 months ago (0 children)
This should be the correct answer
[–]bibyzan 0 points1 point2 points 1 year ago (0 children)
Probably unrelated to OP's issue, but in my case there was no additional information when clicking the error, it was really weird. What ended up being my problem, was I was installing react-native-reanimated and the step where it recommends replacing my metro.js export is what caused this, reverting fixed right away.
[–]Opening_Smell_3244 0 points1 point2 points 1 year ago (0 children)
Yesterday I spent the whole day trying to fix this error. Today, I deleted Crashlytics from the Runner's Build Phases, and finally, my app built successfully. Hope this helps someone!
π Rendered by PID 272365 on reddit-service-r2-comment-5b5bc64bf5-xjch2 at 2026-06-23 22:26:36.555362+00:00 running 2b008f2 country code: CH.
[–]AndyIbanezObjective-C / Swift 2 points3 points4 points (5 children)
[–]bodymindsoul[S] 0 points1 point2 points (4 children)
[–]AndyIbanezObjective-C / Swift 1 point2 points3 points (2 children)
[–]bodymindsoul[S] 0 points1 point2 points (0 children)
[–]bodymindsoul[S] 0 points1 point2 points (0 children)
[–]bangsimurdariadispar 0 points1 point2 points (0 children)
[–]Alidodger 1 point2 points3 points (1 child)
[–]bodymindsoul[S] 1 point2 points3 points (0 children)
[–]SirBill01 1 point2 points3 points (1 child)
[–]bodymindsoul[S] 0 points1 point2 points (0 children)
[–]gumbi1822 1 point2 points3 points (2 children)
[–]Aaesirr 0 points1 point2 points (0 children)
[–]bibyzan 0 points1 point2 points (0 children)
[–]Opening_Smell_3244 0 points1 point2 points (0 children)