简体   繁体   中英

Visual Studio Doesn't List WSL as Platform Toolset

I'm following this tutorial . Everything seems to be fine (linux subsystem is setup fine, I think), but WSL is not showing up as a platform toolset for compilation for C/C++ projects. 在此处输入图像描述

Using visual studio 16.9.5

You can check these steps, which can make me find windows subsystem for linux in visual studio:

Enable subsystem:

  1. Enable windows subsystem for windows

    • Run powershell as administrator
    • Run this command: dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
  2. Restart machine

  3. download and install linux app

Configure linux environment:

  1. sudo apt-get update
  2. sudo apt install g++ gdb make rsync zip
  3. sudo apt-get install openssh-client
  4. sudo apt-get install nano
  5. sudo service ssh restart

Configure visual studio:

  1. Add connection in Tools/Options/Cross Manager
  2. The windows subsystem will auto display in platform toolset 在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM