VEBuild.Cpp.Msvc 1.0.3

dotnet add package VEBuild.Cpp.Msvc --version 1.0.3
                    
NuGet\Install-Package VEBuild.Cpp.Msvc -Version 1.0.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="VEBuild.Cpp.Msvc" Version="1.0.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="VEBuild.Cpp.Msvc" Version="1.0.3" />
                    
Directory.Packages.props
<PackageReference Include="VEBuild.Cpp.Msvc" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add VEBuild.Cpp.Msvc --version 1.0.3
                    
#r "nuget: VEBuild.Cpp.Msvc, 1.0.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package VEBuild.Cpp.Msvc@1.0.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=VEBuild.Cpp.Msvc&version=1.0.3
                    
Install as a Cake Addin
#tool nuget:?package=VEBuild.Cpp.Msvc&version=1.0.3
                    
Install as a Cake Tool

ve.build.cpp.msvc

🚀 STATUS: v1.0.0 RC. MSVC Compiler Provider for VEBuild.

ve.build.cpp.msvc is the implementation of the C++ compiler abstractions for the Microsoft Visual C++ compiler (MSVC / cl.exe).

It bridges the generic ve.build.cpp configuration API with the specific command-line switches and behaviors of MSVC on Windows.

⚠️ Scope

This package ONLY provides the Compiler implementation (ICppTool). It does not include:

Usually, you would install the aggregate package ve.build.msvc which includes all of the above.


📦 Requirements

  • Windows OS (x64/ARM64)
  • Visual Studio 2022 (Build Tools or IDE) with "Desktop development with C++" workload installed.

The package automatically locates the latest installed version of cl.exe using standard VS discovery mechanisms.


⚙️ Features

1. Flag Translation

It implements the IClConfigurator interface, translating abstract settings into MSVC-specific flags:

Abstract Config MSVC Flag
.optimization(SPEED) /O2
.optimization(SIZE) /O1
.inlineLevel(FORCE) /Ob2
.languageStandard(CppLatest) /std:c++latest
.stackCheck(true) /GS
.addressSanitizer(true) /fsanitize=address

2. C++20 Modules Support

Fully implements the modern MSVC modules workflow:

  • Scanning: Uses /scanDependencies to generate JSON dependency graphs.
  • BMI Generation: Automatically adds /ifcOutput for module interfaces (.ixx).
  • Consumption: Adds /reference pointing to precompiled .ifc files from dependencies.

3. Debug Information

Supports parallel-friendly debug info generation (/Z7) to avoid pdb locking issues during multi-threaded builds.


💻 Usage

If you are using the main ve.build.msvc package, this is registered automatically. However, if you are composing a custom toolchain manually:

using ve.build.core;
using ve.build.cpp.cpp;
using ve.build.cpp.msvc; // Import this namespace

return await new HostBuilder()
    .project("sample", p => p
        .Sources("src")
    )
    // Manually register ONLY the compiler (no linker)
    .useMsvc()
    .build()
    .run(args);

🔍 Internal Logic

The MsvcTool class performs the following steps during a build task:

  1. Discovery: Finds cl.exe path based on the requested target platform (x64, arm64, x86).
  2. Scanning: Runs the scanner pass to determine import/export relationships.
  3. Planning: Returns a dependency definition to the DAG builder (so module interfaces compile before consumers).
  4. Compilation: Executes cl.exe with the generated response file (.rsp).

License

© 2025 VassalStudio. All rights reserved.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on VEBuild.Cpp.Msvc:

Package Downloads
VEBuild.Msvc

VEBuild is a modular .NET build system that composes projects via declarative tasks, extensions, and platforms. This repo contains the core abstractions and a sandbox used to validate the architecture.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.3 104 5/29/2026
1.0.2.4 106 5/22/2026
1.0.2.3 118 5/22/2026
1.0.2.2 105 5/22/2026
1.0.2.1 103 5/22/2026
1.0.2 109 5/22/2026
1.0.1.2 108 3/6/2026
1.0.1.1 104 3/6/2026
1.0.1 110 3/3/2026
1.0.0.11-rc 111 3/2/2026
1.0.0.10-rc 120 2/26/2026
1.0.0.8-rc 99 2/26/2026
1.0.0.7-rc 98 2/26/2026
1.0.0.6-rc 115 2/25/2026
1.0.0.5-rc 109 2/25/2026
1.0.0.4-rc 128 2/17/2026
1.0.0.3-rc 145 12/26/2025
1.0.0.1-rc 194 12/25/2025
1.0.0-rc 195 11/27/2025