VSCode Intellisense for Mac

Hi everybody! :slight_smile:

I’m learning Unreal Engine with a Mac. I have installed Visual Studio Code, the latest version of Xcode and Unreal Engine 4.25.

I tried modifying the c_cpp_profiles.json file adding the defines missing but I get the following error:

ERROR: Targets cannot be built in the Debug configuration with this engine distribution.

I’ve seen that the defines.txt included in the resources section has some includes related for Windows platform. Do I have to change them for Mac? If that’s the case, what do I have to change?

Hope somebody could help me.

Thanks in advice!

I think that the #include error was with VS Code only. Are you also experiencing the same error?

Hi Aryan,

Thanks for your response :grinning:

I’m not able to compile the project inside VS Code. That’s the error I get.
I don’t know if I could compile in Xcode but what I know is that Xcode doesn’t have Intellisense. I would like to have it.

If you need more information about the error messages I get or something else in order to discover which is the problem I could share it to you.

Thank you!

Uhh, I saw @DanM asking @sampattuzzi for Mac and Linux includes of VS Code, on another post. Please wait, I think that they will be including them in the video that fixes Intellisense issues in VS Code soon.

Might be able to get them from the source code but I have no idea where Unreal has that.

It seems that Intellisense is working (also in 4.25) but I can’t compile Unreal projects inside VSCode because of the error:

ERROR: Targets cannot be built in the Debug configuration with this engine distribution.

This error also appeared in version 4.24.3

I have to change to Unreal Editor in order to compile it.

Maybe it will not be a problem for me but… how could I debug the code with breakpoints in VS Code?

Hope somebody could help me.

Thanks!

Which configuration are you trying to build? It should be ProjectNameEditor Development.

Hi @DanM,

I have tried with every configuration available for ‘MyProjectEditor Mac’ inside the option “Configure Default Build Task” in VSCode.

If I choose “MyProjectEditor Mac Development Build” option, this is the log I get in Terminal when I select “Start Debugging” in VSCode:

Running system mono/msbuild, version: Mono JIT compiler version 6.10.0.104 (2019-12/5d03a6fe116 Wed Apr 29 20:51:09 EDT 2020)
Running command : Engine/Binaries/DotNET/UnrealBuildTool.exe MyProject Mac Debug /Users/macbookpro/Documents/Unreal Projects/MyProject/MyProject.uproject -waitmutex
Creating makefile for MyProject (no existing makefile)
ERROR: Targets cannot be built in the Debug configuration with this engine distribution.
The terminal process terminated with exit code: 5

What I see is that the compiler is trying to use UnrealBuildTool.exe which I think is a Windows utility. Also, it’s not changing the configuration I´m trying to build. It says “MyProject Mac Debug” instead of “MyProjectEditor Mac Development Build”.

I hope you could help me.

Thank you so much!

That mismatch of configuration is a little confusing. Could you show screenshots of what you’re doing?

Thanks @DanM

Firstly I choose “Open Visual Studio Code” in Unreal Editor

In VSCode I select “Configure Default Build Task” => “MyProjectEditor Mac Development Build”

Then I select Run => Start Debugging in VSCode

And this is the result I get in Terminal in VSCode:

I have installed “Editor Symbols for Debugging” in Unreal Editor.

Also these are the extensions I have installed in VSCode:

Please let me know if you need more screenshots.

Sorry, I forgot to add Engine/Build/BatchFiles/Mac/Build.sh file that compiler is trying to execute:

Use this
2020-06-07 11_18_37-Building_Escape - Microsoft Visual Studio

Thank you so much @DanM ! You are totally my hero! :grinning:

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

Privacy & Terms