fix: vscode debugging build

This commit is contained in:
2023-09-05 03:09:10 +04:00
parent ef40eaf7ef
commit 564955c911
2 changed files with 4 additions and 12 deletions

14
.vscode/tasks.json vendored
View File

@@ -3,20 +3,12 @@
{ {
"type": "cppbuild", "type": "cppbuild",
"label": "C/C++: clang сборка активного файла", "label": "C/C++: clang сборка активного файла",
"command": "/usr/bin/clang", "command": "sh",
"args": [ "args": [
"-fcolor-diagnostics", "${workspaceFolder}/build.sh"
"-fansi-escape-codes",
"-g",
"${file}",
"$(find ${fileDirname}/src -type f -iregex '.*\\.cpp')",
"-lm",
"-lraylib",
"-o",
"${fileDirname}/bin/${fileBasenameNoExtension}"
], ],
"options": { "options": {
"cwd": "${fileDirname}" "cwd": "${workspaceFolder}"
}, },
"problemMatcher": [ "problemMatcher": [
"$gcc" "$gcc"

View File

@@ -1,5 +1,5 @@
#!/bin/bash #!/bin/bash
CC="${CXX:-c++}" CC="${CXX:-c++}"
LL="-lm -lraylib" LL="-lm -lraylib"
FLAGS="-Wall -std=c++17 -I./inc/" FLAGS="-Wall -std=c++17 -I./inc/ -g"
$CC $FLAGS $(find ./src -type f -iregex ".*\.cpp") $LL -o ./bin/main $CC $FLAGS $(find ./src -type f -iregex ".*\.cpp") $LL -o ./bin/main