Skip to content

Commit c0f93cf

Browse files
author
Colin Robertson
authored
Merge pull request #2756 from MicrosoftDocs/FromPublicMasterBranch
Confirm merge from FromPublicMasterBranch to master to sync with https://github.com/MicrosoftDocs/cpp-docs (branch master)
2 parents 1304312 + 9bb71c6 commit c0f93cf

4 files changed

+15
-13
lines changed

docs/build/get-started-linux-cmake.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ In this tutorial, you learn how to:
2424

2525
* Set up a Linux machine for Cross Platform C++ Development
2626
* Visual Studio doesn't require any specific distribution of Linux. The OS can be running on a physical machine, in a VM, or in the cloud. You could also use the Windows Subsystem for Linux (WSL). However, for this tutorial a graphical environment is required. WSL isn't recommended here, because it's intended primarily for command-line operations.
27-
* Visual Studio requires these tools on the Linux machine: C++ compilers, gdb, ssh, rsync, and zip. On Debian-based systems, you can use this command to install these dependencies:
27+
* Visual Studio requires these tools on the Linux machine: C++ compilers, gdb, ssh, rsync, ninja, and zip. On Debian-based systems, you can use this command to install these dependencies:
2828

2929
```cmd
30-
sudo apt install -y openssh-server build-essential gdb rsync zip
30+
sudo apt install -y openssh-server build-essential gdb rsync ninja-build zip
3131
```
3232
3333
* Visual Studio requires a recent version of CMake on the Linux machine that has server mode enabled (at least 3.8). Microsoft produces a universal build of CMake that you can install on any Linux distro. We recommend you use this build to ensure that you have the latest features. You can get the CMake binaries from [the Microsoft fork of the CMake repo](https://github.com/Microsoft/CMake/releases) on GitHub. Go to that page and download the version that matches the system architecture on your Linux machine, then mark it as an executable:

docs/linux/cmake-linux-project.md

+1
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ On the Linux system, make sure that the following are installed:
4040
- gdb
4141
- rsync
4242
- zip
43+
- ninja-build
4344

4445
::: moniker range="vs-2019"
4546

docs/linux/connect-to-your-remote-linux-computer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -144,10 +144,10 @@ In Visual Studio 2017, you use the same steps to connect to WSL as you use for a
144144

145145
Visual Studio 2019 version 16.1 added native support for using C++ with the [Windows Subsystem for Linux (WSL)](/windows/wsl/about). That means you can build and debug on your local WSL installation directly. You no longer need to add a remote connection or configure SSH. You can find details on [how to install WSL](/windows/wsl/install-win10) here.
146146

147-
To configure your WSL installation to work with Visual Studio, you need the following tools installed: gcc or clang, gdb, make, rsync, and zip. You can install them on distros that use apt by using this command, which also installs the g++ compiler:
147+
To configure your WSL installation to work with Visual Studio, you need the following tools installed: gcc or clang, gdb, make, ninja-build (only required for CMake projects using Visual Studio 2019 version 16.6 or later), rsync, and zip. You can install them on distros that use apt by using this command, which also installs the g++ compiler:
148148

149149
```bash
150-
sudo apt install g++ gdb make rsync zip
150+
sudo apt install g++ gdb make ninja-build rsync zip
151151
```
152152

153153
For more information, see [Download, install, and set up the Linux workload](download-install-and-setup-the-linux-development-workload.md).

docs/linux/download-install-and-setup-the-linux-development-workload.md

+10-9
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ Linux projects in Visual Studio require the following dependencies to be install
5757
- **make**
5858
- **openssh-server** (remote Linux systems only) - Visual Studio connects to remote Linux systems over a secure SSH connection.
5959
- **CMake** (CMake projects only) - You can install Microsoft's [statically linked CMake binaries for Linux](https://github.com/microsoft/CMake/releases).
60+
- **ninja-build** (CMake projects only)- [Ninja](https://ninja-build.org/) is the default generator for Linux and WSL configurations in Visual Studio 2019 version 16.6 or later.
6061

6162
The following commands assume you are using g++ instead of clang.
6263

@@ -79,10 +80,10 @@ Linux projects in Visual Studio require the following dependencies to be install
7980

8081
## Linux setup: Ubuntu on WSL
8182

82-
When you are targeting WSL, there is no need to add a remote connection or configure SSH in order to build and debug. **zip** and **rsync** are required for automatic syncing of Linux headers with Visual Studio for Intellisense support. If the required applications are not already present, you can install them as follows:
83+
When you are targeting WSL, there is no need to add a remote connection or configure SSH in order to build and debug. **zip** and **rsync** are required for automatic syncing of Linux headers with Visual Studio for Intellisense support. If the required applications are not already present, you can install them as follows. **ninja-build** is only required for CMake projects.
8384

8485
```bash
85-
sudo apt-get install g++ gdb make rsync zip
86+
sudo apt-get install g++ gdb make ninja-build rsync zip
8687
```
8788

8889
::: moniker-end
@@ -91,12 +92,12 @@ sudo apt-get install g++ gdb make rsync zip
9192

9293
## Ubuntu on remote Linux systems
9394

94-
The target Linux system must have **openssh-server**, **g++**, **gdb**, and **make** installed, and the ssh daemon must be running. **zip** and **rsync** are required for automatic syncing of remote headers with your local machine for Intellisense support. If these applications are not already present, you can install them as follows:
95+
The target Linux system must have **openssh-server**, **g++**, **gdb**, **ninja-build** (CMake projects only), and **make** installed, and the ssh daemon must be running. **zip** and **rsync** are required for automatic syncing of remote headers with your local machine for Intellisense support. If these applications are not already present, you can install them as follows:
9596

9697
1. At a shell prompt on your Linux computer, run:
9798

9899
```bash
99-
sudo apt-get install openssh-server g++ gdb make rsync zip
100+
sudo apt-get install openssh-server g++ gdb make ninja-build rsync zip
100101
```
101102

102103
You may be prompted for your root password due to the sudo command. If so, enter it and continue. Once complete, the required services and tools are installed.
@@ -115,26 +116,26 @@ The target Linux system must have **openssh-server**, **g++**, **gdb**, and **ma
115116

116117
## Fedora on WSL
117118

118-
Fedora uses the **dnf** package installer. To download **g++**, **gdb**, **make**, **rsync** and **zip**, run:
119+
Fedora uses the **dnf** package installer. To download **g++**, **gdb**, **make**, **rsync**, **ninja-build**, and **zip**, run:
119120

120121
```bash
121-
sudo dnf install gcc-g++ gdb rsync make zip
122+
sudo dnf install gcc-g++ gdb rsync ninja-build make zip
122123
```
123124

124-
**zip** and **rsync** are required for automatic syncing of Linux headers with Visual Studio for Intellisense support.
125+
**zip** and **rsync** are required for automatic syncing of Linux headers with Visual Studio for Intellisense support. **ninja-build** is only required for CMake projects.
125126

126127
::: moniker-end
127128

128129
::: moniker range=">=vs-2017"
129130

130131
## Fedora on remote Linux systems
131132

132-
The target machine running Fedora uses the **dnf** package installer. To download **openssh-server**, **g++**, **gdb**, **make**, **rsync**, and **zip**, and restart the ssh daemon, follow these instructions:
133+
The target machine running Fedora uses the **dnf** package installer. To download **openssh-server**, **g++**, **gdb**, **make**, **ninja-build**, **rsync**, and **zip**, and restart the ssh daemon, follow these instructions. **ninja-build** is only required for CMake projects.
133134

134135
1. At a shell prompt on your Linux computer, run:
135136

136137
```bash
137-
sudo dnf install openssh-server gcc-g++ gdb make rsync zip
138+
sudo dnf install openssh-server gcc-g++ gdb ninja-build make rsync zip
138139
```
139140

140141
You may be prompted for your root password due to the sudo command. If so, enter it and continue. Once complete, the required services and tools are installed.

0 commit comments

Comments
 (0)