From 4c95ce048327d465382f265303555ebf32e5dcd0 Mon Sep 17 00:00:00 2001 From: Michael Paquier Date: Fri, 21 Feb 2020 12:05:36 +0900 Subject: [PATCH] Doc: Fix instructions to control build environment with MSVC MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The documentation included some outdated instructions to change the architecture, build type or target OS of a build done with MSVC. This commit updates the documentation to include the modern options available, down to Visual Studio 2013. Reported-by: Kyotaro Horiguchi Author: Juan José Santamaría Flecha Discussion: https://postgr.es/m/CAC+AXB0J7tAqW_2F1fCE4Dh2=Ccz96TcLpsGXOCvka7VvWG9Qw@mail.gmail.com Backpatch-through: 12 --- doc/src/sgml/install-windows.sgml | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/doc/src/sgml/install-windows.sgml b/doc/src/sgml/install-windows.sgml index 08556b6ebe..12b9843b2f 100644 --- a/doc/src/sgml/install-windows.sgml +++ b/doc/src/sgml/install-windows.sgml @@ -110,14 +110,19 @@ Visual Studio Command Prompt. If you wish to build a 64-bit version, you must use the 64-bit version of the command, and vice versa. - In the Microsoft Windows SDK, start the - CMD shell listed under the SDK on the Start Menu. - In recent SDK versions you can change the targeted CPU architecture, build - type, and target OS by using the setenv command, e.g. - setenv /x86 /release /xp to target Windows XP or later - with a 32-bit release build. See /? for other options to - setenv. All commands should be run from the - src\tools\msvc directory. + Starting with Visual Studio 2017 this can be + done from the command line using VsDevCmd.bat, see + -help for the available options and their default values. + vsvars32.bat is available in + Visual Studio 2015 and earlier versions for the + same purpose. + From the Visual Studio Command Prompt, you can + change the targeted CPU architecture, build type, and target OS by using the + vcvarsall.bat command, e.g. + vcvarsall.bat x64 10.0.10240.0 to target Windows 10 + with a 64-bit release build. See -help for the other + options of vcvarsall.bat. All commands should be run from + the src\tools\msvc directory.