Unreal Engine 4.12.5 : Project Could Not Be Compiled

I’ve tried to create a C++ project and I have this error, i really don’t know why.

Running C:/Program Files (x86)/Epic Games/4.12/Engine/Binaries/DotNET/UnrealBuildTool.exe BatteryCollector Development Win64 -project=“C:/Users/François Grèzes/Documents/Unreal Projects/BatteryCollector/BatteryCollector.uproject” -editorrecompile -progress -noubtmakefiles -NoHotReloadFromIDE
@progress push 5%
Parsing headers for BatteryCollectorEditor
Running UnrealHeaderTool “C:\Users\Fran?ois Gr?zes\Documents\Unreal Projects\BatteryCollector\BatteryCollector.uproject” “C:\Users\Fran?ois Gr?zes\Documents\Unreal Projects\BatteryCollector\Intermediate\Build\Win64\BatteryCollectorEditor\Development\BatteryCollectorEditor.uhtmanifest” -LogCmds=“loginit warning, logexit warning, logdatabase error” -Unattended -WarningsAsErrors -installed
Reflection code generated for BatteryCollectorEditor in 4,1196503 seconds
@progress pop
Performing 8 actions (2 in parallel)
[2/8] Resource PCLaunch.rc
PCH.BatteryCollector.h.cpp
C:\Users\Fran?ois Gr?zes\Documents\Unreal Projects\BatteryCollector\Intermediate\Build\Win64\UE4Editor\Development\BatteryCollector\PCH.BatteryCollector.h.cpp(1): fatal error C1083: Cannot open include file: ‘C:\Users\Fran??ois Gr??zes\Documents\Unreal Projects\BatteryCollector\Source\BatteryCollector\BatteryCollector.h’: No such file or directory
[3/8] Resource ModuleVersionResource.rc.inl
ERROR: UBT ERROR: Failed to produce item: C:\Users\Fran?ois Gr?zes\Documents\Unreal Projects\BatteryCollector\Binaries\Win64\UE4Editor-BatteryCollector.dll
Total build time: 21,96 seconds

Seems like i don’t have a .h file but i don’t know where to find this file,
I’ve already tried to re-install VS and UE4 but i’ve always this error.

If someone know what to do please help… :’(

The Unreal Engine editor didn’t even appear, it fail at the compilation few time after i click on Create Project",

when it arrive to “Compiling the C++ project”, it crash and i have the error message i posted previously and it ask me to “Open with Visual Studio” or “Cancel”,

i’ve used Windows File Explorer and i’ve found the header files i didn’t noticed it was a header file (no .h at the end of the file), in the WFE it’s called PCH.BatteryCollector.h, so i don’t know if this is the problem (i don’t think), but it’s actually in the good directory

when you say “assuming you’re using Windows”, is this mean you can run Unreal on Linux distrubs ?

If this is an issue caused by the first compilation of an editor-created C++ project (where the user doesn’t have any way to interact with the solution before the first compilation) I believe the issue might have to do with foreign characters in your Windows path.

Create a new project in C:\Development\Unreal Projects\ and see what happens.

It’s worked with your method Shohei, but i don’t understand why.

Can you explain me please ?

It has to do with the special characters in your name. The compiler is probably using ASCII instead of UTF-8, so when it tries to read the accented characters in your name it turns into “Fran??ois Gr??zes” which is a path that does not exist on your computer. Moving the project into a file path that does not include any accented characters will allow the application to parse the path correctly and find the necessary files.

You… you’re the real MVP, thank you very much :slight_smile: