"Could not be compiled. Try rebuilding from source manually."

You are welcome, thank you for marking the solution too!

1 Like

Yes this helped me! I had this happen to me as well.

1 Like

I had a similar issue, but mine wasn’t solved by rebuilding alone.
I made the mistake of letting VS update to a new version that was incompatible with Unreal 4.11

Unreal was notified of this issue and made a fix in 4.12.5 that resolved the issue.

  1. Install version 4.12.5 from the epic game launcher
  2. Clear out your temporary files
  3. You can right click on the .uproject file from the explorer and select “switch unreal engine version”
  4. Double click the uproject file to open and it should rebuild the .dll properly and open the editor

https://answers.unrealengine.com/questions/435600/build-failed-with-vs-2015-update-3.html

4 Likes

I am having the same problem ben and i’ve tried all your 4 steps and David_Witt’s steps and it still gives me that error. What kind of corruption do I haveee!!??

1 Like

This is the error VS gives me

1>------ Build started: Project: UE4, Configuration: BuiltWithUnrealBuildTool Win32 ------
2>------ Build started: Project: BattleTank, Configuration: Development_Editor x64 ------
2>“C:\Program Files\Epic Games\UE_4.15\Engine\Build\BatchFiles\Build.bat” BattleTankEditor Win64 Development “D:\Unreal Projects\Battle Tank\BattleTank\BattleTank.uproject” -waitmutex
2>Distributing 7 actions to XGE
2>EXEC : Fatal error : Failed to start build.
2>Failed to connect to Build Service (on local machine): Server is not reachable
2>
2>
2>ERROR : UBT error : Failed to produce item: D:\Unreal Projects\Battle Tank\BattleTank\Binaries\Win64\UE4Editor-BattleTank.dll
2>Total build time: 1.16 seconds (XGE executor: 0.00 seconds)
2>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.MakeFile.Targets(44,5): error MSB3075: The command ““C:\Program Files\Epic Games\UE_4.15\Engine\Build\BatchFiles\Build.bat” BattleTankEditor Win64 Development “D:\Unreal Projects\Battle Tank\BattleTank\BattleTank.uproject” -waitmutex” exited with code 5. Please verify that you have sufficient rights to run this command.
2>Done building project “BattleTank.vcxproj” – FAILED.
========== Build: 1 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

And I have given permission to that file that says I do not have rights to run this command.

2 Likes

I think the problem is that a few days ago I updated VS because it gave me a notification to update it, and so I did. I don’t know, just guessing. I think UE4 is not compatible with the new VS update I installed a few days ago. I’ve updated the UE4 as well, and still no luck.

Your help will be appreciated,

Thank You

If you open the solution in VS and compile what error do you get?

1>------ Build started: Project: UE4, Configuration: BuiltWithUnrealBuildTool Win32 ------
2>------ Build started: Project: BattleTank, Configuration: Development_Editor x64 ------
2>“C:\Program Files\Epic Games\UE_4.15\Engine\Build\BatchFiles\Build.bat” BattleTankEditor Win64 Development “D:\Unreal Projects\Battle Tank\BattleTank\BattleTank.uproject” -waitmutex
2>Distributing 7 actions to XGE
2>EXEC : Fatal error : Failed to start build.
2>Failed to connect to Build Service (on local machine): Server is not reachable
2>
2>
2>ERROR : UBT error : Failed to produce item: D:\Unreal Projects\Battle Tank\BattleTank\Binaries\Win64\UE4Editor-BattleTank.dll
2>Total build time: 1.16 seconds (XGE executor: 0.00 seconds)
2>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.MakeFile.Targets(44,5): error MSB3075: The command ““C:\Program Files\Epic Games\UE_4.15\Engine\Build\BatchFiles\Build.bat” BattleTankEditor Win64 Development “D:\Unreal Projects\Battle Tank\BattleTank\BattleTank.uproject” -waitmutex” exited with code 5. Please verify that you have sufficient rights to run this command.
2>Done building project “BattleTank.vcxproj” – FAILED.
========== Build: 1 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Sorry I missed that. Was this after doing something else like uninstalling VS 2015? or Upgrading engine?

I have VS 2017 installed and it works fine with UE 4.15.1 with Building Escape (the previous section in the course). I updated this before I try to create the Battle Tank project.

Not entirely sure, so it still compiles fine in 2015?

Here is a video https://www.dropbox.com/s/4ldrs1fdj47dtd3/Dealing%20with%20error%20after%20error.mp4?dl=0

I’ve never had installed VS 2015

Try installing this
http://landinghub.visualstudio.com/visual-cpp-build-tools

As well as running the VS installer and installing the Win8.1 SDK

3 Likes

Ok, I have selected everything that you said in the screenshot above and now I’m just waiting for it to finish. I’ll reply when its done and working.

YESSS!!! Thank You So Much, Dan!!! It Worked

1 Like

This is quite a common problem that can happen for a number of reasons. Seeing as this link get’s a lot of traffic from Google, I thought I should summarise some of the most common issues:

If you are getting this error then that is because C++ code needs to be built but it failed to build. Unlike other engines like Unity, an Unreal project cannot be opened if the C++ code does not compile.

If you’re getting that on a project you’ve been working on already then that is likely due to a compilation error. In order to find out why it’s failing, you will need to find the logs which would show you the error with your code. The process of how to find logs is documented in the lecture titled “Helping Us Help You”. If you don’t understand the log please submit a new post with its contents.

Once you have fixed the code, you should be able to recompile from within Visual Studio or by reopening the project.

On Windows, you can find the log in Documents\Unreal Projects\YOU PROJECT NAME\Saved\Logs

On Mac you must go to ~/Library/Logs/Unreal Engine/Editor/UE4.log

If you’re following our course and just opening the BullCowGame project for the first time:

  • You did not install Visual Studio Community with the following settings (Windows Only)
  • You have an incompatible macOS/Xcode and Unreal version (4.26 is the min version for Big Sur)
  • You did not extract the zip. The zip should be extracted and the .uproject in the extracted folder should be used.
  • You extracted it to a privileged area e.g. “C:\Program Files” it should instead be extracted to somewhere like your Documents folder (C:\Users\YourName\Documents)`
  • You’ve used Non-English characters in the path to the project.
5 Likes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms