my UE5.2 project builds just fine in CLI with
$UE5_PATH/Build/BatchFiles/Linux/Build.sh Development Linux -Project=“$PROJECT_PATH” -TargetType=Editor -Progress -NoHotReloadFromIDE -verbose
But I would like to use VSCode’s debugging tools.
Therefore I create the necessary project files with
$UE5_PATH/Build/BatchFiles/Linux/GenerateProjectFiles.sh -Project=“$PROJECT_PATH” -game -engine
When trying to build within VSCode afterward, clang complains about different errors that I set to ignore as AdditionalCompilerArguments in project.Target.cs, like -Wno-reorder-ctor.
My additional arguments are not set int c_cpp_properties.json either. Even adding them manually takes no effect.
The solution was that VSCode has two dropdown menus to select configurations. One is the “c/c++ configuration” in the lower right, and one is the “select and start debug configuration” in the lower left. And the latter was pointing to the wrong configuration. The problem is that the second dropdown menu only appears after I hit F5 once and therefore start building the wrong configuration. I don’t know why that menu is not visible from the get-go… but who knows… case solved