#i have added the library include path in properties.json but it still gives the error

18 messages · Page 1 of 1 (latest)

digital swan
#

"SFML\Graphics.hpp: No such file or directory" , can anyone help me linking this library

visual zealotBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.

digital swan
#

😭🙏

near fulcrum
#

Technically this should be in #1013107104678162544, since this is for c.
Anyways, you should be able to link it by adding -Ipath/to/header into your compilation command

kind magnet
near fulcrum
#

Oh yeah that too

digital swan
#

this is my first project using libraries so idk anything

near fulcrum
#

I think you need to modify tasks.json if you want to modify the compile command

digital swan
#

what i do change in tasks.json

#

{
"tasks": [
{
"type": "cppbuild",
"label": "C/C++: g++.exe build active file",
"command": "C:\MinGW\bin\g++.exe",
"args": [
"-fdiagnostics-color=always",
"-g",
"${file}",
"-o",
"${fileDirname}\${fileBasenameNoExtension}.exe"
],
"options": {
"cwd": "${fileDirname}"
},
"problemMatcher": [
"$gcc"
],
"group": {
"kind": "build",
"isDefault": true
},
"detail": "Task generated by Debugger."
}
],
"version": "2.0.0"
}

#

@near fulcrum pls help , i am so confused
i beg 🙏

near fulcrum
#

Add the flag into the args array.

digital swan
near fulcrum
#

Your header file must be located somewhere on your computer. Find the path to that header file, and add it with the compiler flag I mentioned before. This tells the compiler where to find the header files you are using. I don't know any resources specifically. You could try searching for something like "use c++ libraries on vscode."

digital swan
#

thank you for the help

#

god bless you

#

🙏