티스토리 뷰

wsl 설정 마지막!

 

 

 

1. wsl에서 gcc, gcc-c++설치

yum install gcc
yum install gcc-c++

 

 

2. vscode에서 c++ 확장 프로그램 설치

c/c++

c/c++ Extension Pack 

 

 

3. task.json 파일 생성

f1 -> c/c++:edit Configurations (json) 선택하면 자동으로 생성된다.

 

참고용)

{
    "configurations": [
        {
            "name": "Linux",
            "includePath": [
                "${workspaceFolder}/**"
            ],
            "defines": [],
            "compilerPath": "/usr/bin/gcc",
            "cStandard": "c17",
            "cppStandard": "gnu++14",
            "intelliSenseMode": "linux-gcc-x64"
        }
    ],
    "version": 4
}

 

 

 

4. 소스의 main위치에서 ctrl + shift + b 후 g++ build active file 선택

 

 

 

5. 소스 디렉터리에 바이너리 파일 생성되었는지 확인

완료!

 

 

댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
글 보관함