Configuration Command Includes Unremovable Options
See original GitHub issueBrief Issue Summary
It is not possible to not specify a CMAKE_BUILD_TYPE. More generally, CMake Tools appends many options to the cmake invocation that cannot be removed.
Expected:
Allow configuration commands as simple as cmake .. from the build/ directory.
Apparent Behavior:
Configuration commands include many more flags and typically look something like
/usr/local/bin/cmake --no-warn-unused-cli -DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE -DCMAKE_BUILD_TYPE:STRING=Release -DCMAKE_C_COMPILER:FILEPATH=/usr/bin/clang -DCMAKE_CXX_COMPILER:FILEPATH=/usr/bin/clang++ -H/Users/Thrasher/Projects/timecard -B/Users/Thrasher/Projects/timecard/build -G "Unix Makefiles"
without any way to remove these options and flags.
This becomes a problem on projects that require that users do not specify CMAKE_BUILD_TYPE.
Platform and Versions
- Operating System: macOS 10.15.7
 - CMake Version: 3.17.3
 - VSCode Version: 1.52.1
 - CMake Tools Extension Version: v1.5.3
 - Compiler/Toolchain: Apple Clang version 12.0.0
 
Issue Analytics
- State:
 - Created 3 years ago
 - Reactions:1
 - Comments:5 (2 by maintainers)
 
Top Results From Across the Web
Using the CLI to implement configuration changes
How to use the CLI to view the current configuration files. Use show commands to view the configuration for individual features, such as...
Read more >Cisco IOS Configuration Fundamentals Command Reference
(Optional) Displays the edited configuration that will replace the current configuration. Defaults. This command has no default settings. Command Modes. MST ...
Read more >Overview of the Configure Command | Junos OS
Junos OS supports three forms of the configure command: configure , configure private , and configure exclusive . These forms control how users...
Read more >How to Manage and Save Running Config on Cisco Devices
Note that Cisco IOS does not have a command that erases the contents of the running configuration file. To clear out the running...
Read more >remove-option-from-option-group — AWS CLI 1.27.32 ...
Permanent options, such as the TDE option for Oracle Advanced Security ... For example, the NATIVE_NETWORK_ENCRYPTION option has a setting called SQLNET.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

I have the same issue with the same project, and other VSCode users in the SerenityOS developer community appear to struggle with it as well.
I tried adding
-DCMAKE_BUILD_TYPE=""to configureArgs but it appeared before the autogenerated-DCMAKE_BUILD_TYPE:STRING=<some build type>so I think the latter takes precedent.This didn’t appear to fix the problem either.
For context I’m building SerenityOS which uses very specific compiler flags which clash with the flags CMake adds when you specify a build type.