[PATCH] D33546: Updated getting started guide for visual studio + cmake

Aaron Ballman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 25 05:38:11 PDT 2017


aaron.ballman created this revision.

It took me a while to track this down and I figured I'd save someone else the time. By default, CMake uses the 32-bit toolchain on Windows, even if generating a 64-bit solution. Given the size of LLVM's code base, this can lead to quite a few link errors with the linker running out of memory. If you pass `-Thost=x64` when generating the Visual Studio solution, then the resulting project files will use the 64-bit toolchain and the toolchain no longer runs out of memory.

I will add some similar wording to Clang's getting started guide as well.


https://reviews.llvm.org/D33546

Files:
  docs/GettingStartedVS.rst


Index: docs/GettingStartedVS.rst
===================================================================
--- docs/GettingStartedVS.rst
+++ docs/GettingStartedVS.rst
@@ -100,6 +100,10 @@
    * CMake generates project files for all build types. To select a specific
      build type, use the Configuration manager from the VS IDE or the 
      ``/property:Configuration`` command line option when using MSBuild.
+   * By default, the Visual Studio project files generated by CMake use the
+     32-bit toolset. If you are developing on a 64-bit version of Windows and
+     want to use the 64-bit toolset, pass the ``-Thost=x64`` flag when
+     generating the Visual Studio solution. This requires CMake 3.8.0 or later.
 
 6. Start Visual Studio
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D33546.100229.patch
Type: text/x-patch
Size: 743 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170525/db5d0f3c/attachment.bin>


More information about the llvm-commits mailing list