summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDragorn421 <Dragorn421@users.noreply.github.com>2024-08-01 05:19:46 +0200
committerGitHub <noreply@github.com>2024-07-31 23:19:46 -0400
commit9963e7f5d5fa8caee329f6b40e393d8a2c45390b (patch)
tree9a48e607b107127bf73f1ced3cf7c576858e0a78 /docs
parent8ee485d2e7b237a785ac0cf3870117944c923a07 (diff)
Update vs code config and provide c_cpp_properties.json with all supported versions (#2010)
* Update oot-gc-eu-mq-dbg example vscode config and provide c_cpp_properties.json with all supported versions * remove N64 prefix from config names * newline at end of file
Diffstat (limited to 'docs')
-rw-r--r--docs/c_cpp_properties.json113
-rw-r--r--docs/vscode.md19
2 files changed, 129 insertions, 3 deletions
diff --git a/docs/c_cpp_properties.json b/docs/c_cpp_properties.json
new file mode 100644
index 000000000..ed8c0feaa
--- /dev/null
+++ b/docs/c_cpp_properties.json
@@ -0,0 +1,113 @@
+{
+ "configurations": [
+ {
+ "name": "oot-gc-us",
+ "compilerArgs": [
+ "-m32"
+ ],
+ "includePath": [
+ "include",
+ "include/libc",
+ "src",
+ "build/gc-us",
+ ".",
+ "extracted/gc-us"
+ ],
+ "defines": [
+ "_LANGUAGE_C",
+ "OOT_VERSION=OOT_GC_US",
+ "OOT_REGION=REGION_US",
+ "OOT_NTSC=1",
+ "OOT_MQ=0",
+ "OOT_DEBUG=0",
+ "NDEBUG",
+ "F3DEX_GBI_2",
+ "F3DEX_GBI_PL",
+ "GBI_DOWHILE"
+ ],
+ "cStandard": "gnu89"
+ },
+ {
+ "name": "oot-gc-eu",
+ "compilerArgs": [
+ "-m32"
+ ],
+ "includePath": [
+ "include",
+ "include/libc",
+ "src",
+ "build/gc-eu",
+ ".",
+ "extracted/gc-eu"
+ ],
+ "defines": [
+ "_LANGUAGE_C",
+ "OOT_VERSION=OOT_GC_EU",
+ "OOT_REGION=REGION_EU",
+ "OOT_PAL=1",
+ "OOT_MQ=0",
+ "OOT_DEBUG=0",
+ "NDEBUG",
+ "F3DEX_GBI_2",
+ "F3DEX_GBI_PL",
+ "GBI_DOWHILE"
+ ],
+ "cStandard": "gnu89"
+ },
+ {
+ "name": "oot-gc-eu-mq",
+ "compilerArgs": [
+ "-m32"
+ ],
+ "includePath": [
+ "include",
+ "include/libc",
+ "src",
+ "build/gc-eu-mq",
+ ".",
+ "extracted/gc-eu-mq"
+ ],
+ "defines": [
+ "_LANGUAGE_C",
+ "OOT_VERSION=OOT_GC_EU_MQ",
+ "OOT_REGION=REGION_EU",
+ "OOT_PAL=1",
+ "OOT_MQ=1",
+ "OOT_DEBUG=0",
+ "NDEBUG",
+ "F3DEX_GBI_2",
+ "F3DEX_GBI_PL",
+ "GBI_DOWHILE"
+ ],
+ "cStandard": "gnu89"
+ },
+ {
+ "name": "oot-gc-eu-mq-dbg",
+ "compilerArgs": [
+ "-m32"
+ ],
+ "includePath": [
+ "include",
+ "include/libc",
+ "src",
+ "build/gc-eu-mq-dbg",
+ ".",
+ "extracted/gc-eu-mq-dbg"
+ ],
+ "defines": [
+ "_LANGUAGE_C",
+ "OOT_VERSION=OOT_GC_EU_MQ_DBG",
+ "OOT_REGION=REGION_EU",
+ "OOT_PAL=1",
+ "OOT_MQ=1",
+ "OOT_DEBUG=1",
+ "F3DEX_GBI_2",
+ "F3DEX_GBI_PL",
+ "GBI_DOWHILE",
+ "GBI_DEBUG"
+ ],
+ "cStandard": "gnu89"
+ }
+ ],
+ "version": 4
+}
diff --git a/docs/vscode.md b/docs/vscode.md
index c88b85c07..c5cd0fc2e 100644
--- a/docs/vscode.md
+++ b/docs/vscode.md
@@ -35,13 +35,17 @@ Many of VS Code's other shortcuts can be found on [its getting started page](htt
## C/C++ configuration
-You can create a `.vscode/c_cpp_properties.json` file with `C/C++: Edit Configurations (JSON)` in the command box to customise how IntelliSense reads the repository (stuff like where to look for includes, flags, compiler defines, etc.) to make VSCode's IntelliSense plugin better able to understand the structure of the repository. This is a good default one to use for this project's repository:
+You can create a `.vscode/c_cpp_properties.json` file with `C/C++: Edit Configurations (JSON)` in the command box to customise how IntelliSense reads the repository (stuff like where to look for includes, flags, compiler defines, etc.) to make VSCode's IntelliSense plugin better able to understand the structure of the repository.
+
+Below is a good default one to use for this project's repository, for the oot-gc-eu-mq-dbg version specifically.
+
+A more complete `c_cpp_properties.json` with configurations for all supported versions [can be found here](c_cpp_properties.json).
```jsonc
{
"configurations": [
{
- "name": "N64 oot-gc-eu-mq-dbg",
+ "name": "oot-gc-eu-mq-dbg",
"compilerPath": "${default}", // Needs to not be "" for -m32 to work
"compilerArgs": [
"-m32" // Removes integer truncation warnings with gbi macros
@@ -57,7 +61,16 @@ You can create a `.vscode/c_cpp_properties.json` file with `C/C++: Edit Configur
],
"defines": [
"_LANGUAGE_C", // For gbi.h
- "OOT_DEBUG=1" // If targeting a debug version
+ // Version-specific
+ "OOT_VERSION=OOT_GC_EU_MQ_DBG",
+ "OOT_REGION=REGION_EU",
+ "OOT_PAL=1",
+ "OOT_MQ=1",
+ "OOT_DEBUG=1",
+ "F3DEX_GBI_2",
+ "F3DEX_GBI_PL",
+ "GBI_DOWHILE",
+ "GBI_DEBUG"
],
"cStandard": "gnu89", // C89 + some GNU extensions from C99 like C++ comments
"cppStandard": "${default}" // Only ZAPD uses C++, so doesn't really matter