Update VS Code C/C++ IntelliSense include paths from build configuration files.
This extension reads include settings from a selected build file (.mk file) and updates your IntelliSense configuration.
What It Does
Reads include-related settings from the selected build file (.mk file).
Discovers include-path variables generically: no fixed variable name is
required. Any make variable whose value is a list of directories that exist on
disk qualifies, and the names actually used are reported in the result message.
Detects the build root per makefile, resolving relative entries against the
nearest ancestor directory that makes them exist.
Detects linked libraries (.a and .lib) and optionally merges include
settings from their library build files.
Removes duplicate include paths while preserving order; only directories that
exist on disk are written.
Updates an existing IntelliSense configuration or creates a new one.
Commands
Update IntelliSense from this .mk file
Available in Explorer context menu when right-clicking a .mk file.
Command ID: mkintellisense.updateIntelliSense
Update IntelliSense: Pick a .mk file...
Lets you choose a build file (.mk file) manually.
Command ID: mkintellisense.updateIntelliSensePick
Workflow
Right-click a project .mk file in Explorer.
Select Update IntelliSense from this .mk file.
(Optional) Tick the linked libraries (.a / .lib) to resolve; all detected entries are pre-selected.
(Optional) Confirm which library .mk files to merge include paths from (the match score is shown).
Pick the IntelliSense configuration to update, or create a new one.
The extension writes the updated IntelliSense settings and reports the source
variable(s), the detected build root, and how many entries were skipped.
Input Requirements
The selected build file (.mk file) should contain include-related configuration entries.
If related library artifacts (such as xxx.a or xxx.lib) are referenced, corresponding library build settings can be merged during update.
Documentation examples use placeholder names only (for example, module_xxx.mk, lib_xxx.a).
Notes
After installing or updating the .vsix, run Developer: Reload Window. Menu
labels are resolved when the window loads, so without a reload the context menu
can still appear in English, and the resolution logic is not refreshed either.
If .vscode/c_cpp_properties.json is missing, the extension creates it automatically.
If required include settings are not found, the extension reports an error message.
Include paths are checked against the file system before being written. Entries
that do not exist are skipped and reported as N/M path entries ... were skipped.
Settings
mkintellisense.libraryMkSearchGlobs
Controls where candidate library .mk files are searched (multiple paths).
Default: ["**/*.mk"]
Example: ["libs/**/*.mk", "apps/**/*.mk"]
mkintellisense.lowConfidenceThreshold
Match score below this value is treated as low confidence.
Default: 0.7
mkintellisense.lowConfidenceMode
Controls how low-confidence matches are handled.
discard (default): drop low-confidence matches directly.
include_with_warning: keep and mark LOW with warning.
mkintellisense.directoryRatioThreshold
The fraction of a variable's entries that must resolve to existing directories
before the variable counts as an include-path source. Raise it to avoid picking
up variables that merely look like path lists.
Default: 0.9 (range 0.5–1)
mkintellisense.minTokensPerVariable
The minimum number of entries a variable must have to be considered.
Default: 2 (range 1–10)
mkintellisense.includeVariableSelection
Which qualifying variables are used as include-path sources. Header directories
are usually named with inc/include/hdr/header; source and link directories are not
header roots, and adding them makes the C/C++ parser index the whole tree.
inc-only (default): only variables whose name contains inc/include/hdr/header.
prefer: prefer inc-named variables, fall back to all qualifying ones if none.
all: use every variable whose entries resolve to existing directories.
These settings support workspace-level configuration, so different projects can use different search paths.