'Eclipse headless build with special chars

Is it possible to perform a headless build in Eclipse when the configuration has special chars inside?

Eclipse CDT: 9.2.1.201704050430

Configuration name: "Debug (-Og)"

Release or Release_best are working properly.

I am calling Eclipse inside a batch-script with "... -build "%PROJ%/%PROFILE%" and at the top of the batch-script the argument is read:

if NOT "%~1" == "" (
    set PROFILE=%~1
    )

Command line is: run.bat "Debug (-Og)"



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source