# Xcode "Clean Project" causes Shared UE4Editor.app binary to be deleted

**URL:** <https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650>\
**Category:** Platform & Builds\
**Tags:** xcode, build, unreal-engine, bug-report, UE4, question\
**Created:** [December 6, 2015, 10:07am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650 "2015-12-06T10:07:29Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![mindblender](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mindblender/32/598567_2.png) [@mindblender](https://forums.unrealengine.com/u/mindblender)\
**Post date:** [December 6, 2015, 10:07am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/1 "2015-12-06T10:07:29Z")

</div>

Reproduce:

1. Create a C++ project.
2. Generate Xcode project.
3. Close UE4 editor.
4. Open Xcode project.
5. Build and run for the project target, not UE4 target. Observe that UE4 editor for the current project runs.
6. Stop.
7. Clean the project via Xcode’s Product \> Clean menu option.
8. Try to build again. Observe build failure with a message saying:

> clang: error: no such file or directory: ‘/Users/Shared/UnrealEngine/4.10/Engine/Binaries/Mac/UE4Editor.app/Contents/MacOS/UE4Editor-Core.dylib’  
> clang: error: no such file or directory: ‘/Users/Shared/UnrealEngine/4.10/Engine/Binaries/Mac/UE4Editor.app/Contents/MacOS/UE4Editor-CoreUObject.dylib’  
> clang: error: no such file or directory: ‘/Users/Shared/UnrealEngine/4.10/Engine/Binaries/Mac/UE4Editor.app/Contents/MacOS/UE4Editor-Engine.dylib’  
> clang: error: no such file or directory: ‘/Users/Shared/UnrealEngine/4.10/Engine/Binaries/Mac/UE4Editor.app/Contents/MacOS/UE4Editor-InputCore.dylib’  
> ERROR: UBT ERROR: Failed to produce item: /Users/saim/Projects/Unreal/Travelers/Binaries/Mac/UE4Editor-${PROJECT\_NAME}.dylib

If you check the file system, you can find that the file is actually missing.

You can reinstall the missing UE4Editor.app via Epic Launcher \> Select the engine \> Verify.

After “Verify”, build works again.

I think Xcode clean is removing the shared binary mistakenly.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2b03d27c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2b03d27c](https://forums.unrealengine.com/u/anonymous_user_2b03d27c)\
**Post date:** [December 7, 2015, 1:51pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/2 "2015-12-07T13:51:43Z")

</div>

Hey mindblender-

This is a known issue that has been reported and is under investigation (UE-23624).

Cheers

---

<div class="post-metadata">

**Author:** ![tianqi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@tianqi](https://forums.unrealengine.com/u/tianqi)\
**Post date:** [May 20, 2016, 5:40pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/3 "2016-05-20T17:40:01Z")

</div>

The same problem in UE 4.11.2

---

<div class="post-metadata">

**Author:** ![Woohoou](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Woohoou](https://forums.unrealengine.com/u/Woohoou)\
**Post date:** [May 25, 2016, 5:08pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/4 "2016-05-25T17:08:24Z")

</div>

any workaround?

---

<div class="post-metadata">

**Author:** ![mindblender](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mindblender/32/598567_2.png) [@mindblender](https://forums.unrealengine.com/u/mindblender)\
**Post date:** [May 25, 2016, 5:28pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/5 "2016-05-25T17:28:53Z")

</div>

You can make a workaround. I don’t see this as a permanent one though.

Basically, you can add script target as a dependency to your main project, which will detect “Clean” action and temporarily move the stuff you want to prevent from deletion. And, also perform the reverse operation after “Clean” build finishes.

For more info on Xcode hookup:

> <https://stackoverflow.com/questions/1903890/run-script-during-clean-clean-all-in-xcode>

This definitely needs to be fixed in unreal build pipeline. But, it think the script should prevent this specific issue.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2b03d27c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2b03d27c](https://forums.unrealengine.com/u/anonymous_user_2b03d27c)\
**Post date:** [May 25, 2016, 5:54pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/6 "2016-05-25T17:54:50Z")

</div>

Hey -

As mindblender mentioned, if you run the Verify option from the Launcher for the engine version you’re using, it should regenerate the XCode files and allow the engine to be used again.

---

<div class="post-metadata">

**Author:** ![Woohoou](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Woohoou](https://forums.unrealengine.com/u/Woohoou)\
**Post date:** [May 25, 2016, 9:03pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/7 "2016-05-25T21:03:22Z")

</div>

Verifying was enough!, Thank you guys.

---

<div class="post-metadata">

**Author:** ![NorlinGames](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/norlingames/32/495614_2.png) [@NorlinGames](https://forums.unrealengine.com/u/NorlinGames)\
**Post date:** [January 25, 2017, 6:04am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/8 "2017-01-25T06:04:58Z")

</div>

> **[The Unreal Engine Issues and Bug Tracker](https://issues.unrealengine.com/issue/UE-23624)**
>
> Welcome to the Unreal Engine Issue and Bug Tracker. You can check the status of an issue and search for existing bugs. See latest bug fixes too.

Why this issue is backlogged? I’ve just faced with it in UE4.14.3 and just accidentally tried “verify” in the Epic Launcher.

At least, you should fix the Epic Launcher to show some error message and suggest to try Verify" option!

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2b03d27c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2b03d27c](https://forums.unrealengine.com/u/anonymous_user_2b03d27c)\
**Post date:** [January 25, 2017, 5:24pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/9 "2017-01-25T17:24:28Z")

</div>

Currently our resources are dedicated elsewhere and UE-23624 is not a priority item for us to work on. We don’t have a timeframe for when this may be addressed. Please keep in mind that with source code access, a programmer on your project can implement your own solution, and you are welcome to share that result with Epic for possible integration.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_bcd0d281](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_bcd0d281](https://forums.unrealengine.com/u/anonymous_user_bcd0d281)\
**Post date:** [March 30, 2017, 8:07pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/10 "2017-03-30T20:07:02Z")

</div>

This still happens in UE 4.15.1 and Xcode 8.3.

I updated to Xcode 8.3, which means my PCH files were compiled with a different branch of the clang compiler. The fix for that is to Clean the project. While this fixed the PCH compiler mismatch issue, it caused several dylib files to be deleted.

If you Verify the Engine in the Epic Game Launcher, it fixes the problem.

This really should get fixed, or at least have a warning come up after cleaning the project from Xcode.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2b03d27c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2b03d27c](https://forums.unrealengine.com/u/anonymous_user_2b03d27c)\
**Post date:** [March 31, 2017, 11:45am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/11 "2017-03-31T11:45:05Z")

</div>

Hey Jonathan-

I’ve added a private note to the original report to indicate that this is still occurring. As mentioned in the report ([Unreal Engine Issues and Bug Tracker (UE-23624)](https://issues.unrealengine.com/issue/UE-23624)) you can work around this by choosing the Verify option for the affected engine version in the Launcher.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_bcd0d281](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_bcd0d281](https://forums.unrealengine.com/u/anonymous_user_bcd0d281)\
**Post date:** [March 31, 2017, 2:16pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/12 "2017-03-31T14:16:43Z")

</div>

Thanks for updating the original report.

As a side note, Xcode 8.3 is causing some issues; see [https://answers.unrealengine.com/questions/583010/error-in-unrealmathneonh-when-packaging-for-ios.html](https://answers.unrealengine.com/questions/583010/error-in-unrealmathneonh-when-packaging-for-ios.html)

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_9af461e6](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_9af461e6](https://forums.unrealengine.com/u/anonymous_user_9af461e6)\
**Post date:** [July 17, 2017, 2:36pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/13 "2017-07-17T14:36:19Z")

</div>

This still happens in the pre-release (dev-ar-kit) for 4.17 BTW. Compiling for in XCode 11 beta 3, I ran clean on a project and binaries for UE4Editor all disappeared.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2b03d27c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2b03d27c](https://forums.unrealengine.com/u/anonymous_user_2b03d27c)\
**Post date:** [July 17, 2017, 3:26pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/14 "2017-07-17T15:26:54Z")

</div>

Currently our resources are dedicated elsewhere and UE-23624 is not a priority item for us to work on. We don’t have a timeframe for when this may be addressed. Please keep in mind that Verifying the engine version from the launcher should restore any missing files and allow the project to open.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_9af461e6](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_9af461e6](https://forums.unrealengine.com/u/anonymous_user_9af461e6)\
**Post date:** [July 18, 2017, 4:44pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/15 "2017-07-18T16:44:40Z")

</div>

which is fine for most cases, but for the arkit branch, the launcher is not capable of doing that, unless I’m missing something (certainly possible).

---

<div class="post-metadata">

**Author:** ![Anonymous\_e5d5c0bf7d300728867097ff79906dbe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Anonymous\_e5d5c0bf7d300728867097ff79906dbe](https://forums.unrealengine.com/u/Anonymous_e5d5c0bf7d300728867097ff79906dbe)\
**Post date:** [September 30, 2017, 2:41am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/16 "2017-09-30T02:41:18Z")

</div>

Launcher deletes shaders on launch,  
Xcode deletes binaries on clean,  
In game windows are completely broken by functionality,  
what else should I expect from he macOS branch ?

---

<div class="post-metadata">

**Author:** ![Institute\_Games](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Institute\_Games](https://forums.unrealengine.com/u/Institute_Games)\
**Post date:** [March 8, 2018, 2:25am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/17 "2018-03-08T02:25:02Z")

</div>

This is still occuring as of UE4.18.3 and Xcode 9.2. This REALLY needs to be fixed, glad at least I could find out why things were going south.

---

<div class="post-metadata">

**Author:** ![Awesumson](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Awesumson](https://forums.unrealengine.com/u/Awesumson)\
**Post date:** [January 14, 2019, 11:14am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/18 "2019-01-14T11:14:18Z")

</div>

Still occuring with 4.21.1 and Xcode 10.1  
Verifying doesn’t work, it says I need to check running processes and I have nothing else open. Resarting doesn’t help. The only way I fixed it was to perform a clean install of ue4.

---

<div class="post-metadata">

**Author:** ![Awesumson](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Awesumson](https://forums.unrealengine.com/u/Awesumson)\
**Post date:** [January 14, 2019, 11:15am UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/19 "2019-01-14T11:15:02Z")

</div>

Still occuring with 4.21.1 and Xcode 10.1

Verifying doesn’t work, it says I need to check running processes and I have nothing else open. Resarting doesn’t help. The only way I fixed it was to perform a clean install of ue4.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_b2fb724f1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b2fb724f1](https://forums.unrealengine.com/u/anonymous_user_b2fb724f1)\
**Post date:** [October 13, 2020, 6:04pm UTC](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650/20 "2020-10-13T18:04:17Z")

</div>

Unfortunately, still happening in XCode 12 / UE 4.25.3 … this seems to get broken on a regular basis.

[Next page](https://forums.unrealengine.com/t/xcode-clean-project-causes-shared-ue4editor-app-binary-to-be-deleted/340650.md?page=2)
