You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 1, 2024. It is now read-only.
Copy file name to clipboardExpand all lines: BRANCHNOTES.md
+47-1
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# IntelliSense Autoconfiguration Branch
2
2
## Problem
3
-
This branch more or less adresses[these](https://github.com/microsoft/vscode-arduino/issues?utf8=%E2%9C%93&q=intellisense+is%3Aopen) issues.
3
+
This branch more or less addresses[these](https://github.com/microsoft/vscode-arduino/issues?utf8=%E2%9C%93&q=intellisense+is%3Aopen) issues (about seven).
4
4
5
5
It implements a parser which parses the output from Arduino's build process to generate a very precise `c_cpp_properties.json` which in turn hopefully renders any user interaction with this file obsolete
6
6
@@ -24,6 +24,7 @@ src/arduino/arduino.ts
24
24
```
25
25
26
26
### Status
27
+
**2020-02-05** Currently I'm able to generate error free IntelliSense setups for AVR and ESP32 using the preliminary implementation. For ESP32 I just had to add the intrinsic compiler paths manually. A solution has to be found for these ... which there is, see [here](https://stackoverflow.com/a/6666338)
27
28
28
29
|| Tasks |
29
30
|-----:|:--------|
@@ -35,6 +36,7 @@ src/arduino/arduino.ts
35
36
||:heavy_check_mark: Basic file input*|
36
37
||:heavy_check_mark: Basic file output*|
37
38
||:white_check_mark: Merging of parsing result and existing file content |
39
+
||:white_check_mark: Getting intrinsic gcc include paths (partly done)|
38
40
|**Configuration flags**|:white_check_mark:|
39
41
|**Unit tests**|:white_check_mark: Basic parser |
40
42
||:white_check_mark: JSON input |
@@ -81,6 +83,50 @@ I will list every supporter here, thanks!
81
83
82
84
## Implementation
83
85
86
+
### `c_cpp_properties.json` Generator
87
+
#### Intrinsic Include Paths
88
+
Some include paths are built into gcc and don't have to be specified on the command line. This requires that we have to get them from the compiler.
89
+
90
+
Just searching the compiler installation directory with something like
won't do since not all include directories are named `include`. Fortunately gcc can be queried about its configuration ([source](https://stackoverflow.com/a/6666338)):
95
+
```bash
96
+
# generally for C++
97
+
gcc -xc++ -E -v -
98
+
# for esp32
99
+
~/.arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/1.22.0-80-g6c4433a-5.2.0/bin/xtensa-esp32-elf-gcc -xc++ -E -v - < /dev/null 2>&1| tee xtensa-esp32-elf-gcc_built_in_specs.txt
100
+
# avr
101
+
~/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino5/bin/avr-gcc -xc++ -E -v - < /dev/null 2>&1| tee avr-gcc_built_in_specs.txt
0 commit comments