summaryrefslogtreecommitdiff
path: root/Building-Locally.md
AgeCommit message (Collapse)Author
2026-06-23Auto-discover _NT_TARGET_VERSION; remove the TargetVersion axis5an7y
- Remove the -TargetVersion parameter and all its plumbing from Build-Samples.ps1 (restoring the original hard-coded -p:TargetVersion=Windows10), and drop the TargetVersions column from exclusions.csv and Import-SampleExclusions. Only _NT_TARGET_VERSION remains exposed. - Add Get-NtTargetVersions.ps1, which auto-discovers the valid _NT_TARGET_VERSION values (and their NTDDI codes) by parsing the active WDK's DriverGeneral.xml rule. Build-Samples.ps1 uses it to validate -NtTargetVersion, default to the latest, and map to the msbuild code, so a new WDK version needs no script change (accepts '10.0.<build>' or the short '<build>' tag). - CI: ci.yml and ci-pr.yml gain a 'discover' job that emits the newest-N versions as JSON; the build matrix consumes it via fromJSON, so there is no hand-maintained version list anywhere. Build-ChangedSamples.ps1 treats Get-NtTargetVersions.ps1 as a full-build trigger. - Docs updated accordingly. Co-authored-by: Copilot <[email protected]>
2026-06-22Add NT-version-scoped exclusions and a parallel multi-version CI matrix5an7y
Exclusions: - Add MinNtTargetVersion/MaxNtTargetVersion columns to exclusions.csv so a row can apply only within an _NT_TARGET_VERSION build-number range (parsed from -NtTargetVersion, e.g. 22000 from 10.0.22000). Import-SampleExclusions filters this range at load time alongside the existing build-number range; blank = unbounded. - Exclude the samples that fail only when linking against older library sets, with the reason taken from the build logs: audio.sysvad (<=22000, KSJACK_DESCRIPTION3); network.netadaptercx.netvadapter and network.wlan.wificx (<=22621, NDIS/DDI version); powerlimit.plclient/plpolicy (<=22621, POWER_LIMIT_ATTRIBUTES); storage classpnp/storahci (<=22621, STOR_ADDRESS_TYPE_NVME, Debug-only) and storage.msdsm (Debug|x64). usb.usbview is intentionally NOT excluded: it fails on every version for a known host reason (missing .NET 4.7.2/4.8.1 targeting packs). CI: - ci.yml and ci-pr.yml: add _NT_TARGET_VERSION as a manual matrix axis (4 newest versions, latest-first) so each version x configuration x platform runs on its own parallel runner. - Build-Samples.ps1 and Join-CsvReports.ps1 now write an easy-to-scan Markdown summary to GITHUB_STEP_SUMMARY: each build job shows counts and a failures table with the first error; the report job shows per-version totals and a consolidated failures list, plus the colour-coded sample x version HTML/CSV overview. Co-authored-by: Copilot <[email protected]>
2026-06-22Add -NtTargetVersion to build samples against older WDK library sets5an7y
Expose the WDK '_NT_TARGET_VERSION' property (the OS version of the libraries the driver links against) as -NtTargetVersion / WDS_NtTargetVersion. Unlike -TargetVersion (Target OS Version), this does not change the platform model, so Universal/Windows Driver samples keep building on Windows 10 while linking against an older library set. The parameter accepts the Windows build number (e.g. 10.0.22000), maps it to the NTDDI code from the WDK DriverGeneral.xml rule, and passes -p:_NT_TARGET_VERSION to msbuild (threaded through Build-SingleSample and the parallel runspace). It defaults to the latest (10.0.28000) and is surfaced in the build plan, summary, and HTML report title. Documented in Building-Locally.md. Co-authored-by: Copilot <[email protected]>
2026-06-22Support TargetVersion-scoped rules in exclusions.csv5an7y
Add an optional TargetVersions column to exclusions.csv so an exclusion can be limited to specific target OS versions (e.g. exclude ARM only when building Windows8). The column holds a ';'-separated list of -like patterns matched against -TargetVersion; blank or '*' means all versions, so every existing row stays applicable to all targets. Import-SampleExclusions now takes -TargetVersion and filters rows by it at load time (alongside the existing MinBuild/MaxBuild range); a missing column is treated as '*' for backward compatibility. Document the new column and an example in Building-Locally.md. Co-authored-by: Copilot <[email protected]>
2026-06-22Expose TargetVersion parameter in Build-Samples.ps15an7y
Add a validated -TargetVersion parameter (also settable via the WDS_TargetVersion environment variable) so samples can be built for older target OS versions. Valid values come from the WDK DriverGeneral.xml rule and default to the latest, Windows10: Windows10 (Windows 10 or higher), WindowsV6.3 (Windows 8.1), Windows8 (Windows 8), Windows7 (Windows 7). The value is threaded through Build-SingleSample into the msbuild invocation (replacing the hard-coded TargetVersion=Windows10) and across the parallel runspace, and is surfaced in the build plan, final summary, and HTML report title. Document the new parameter in the script help and Building-Locally.md. Co-authored-by: Copilot <[email protected]>
2026-04-07docs: streamline Building-Locally.md and fix typosuser/jvalesmena/build-environment5an7y
Simplify prerequisites with environment-specific requisites section, remove redundant build commands per WDK type since the script auto-detects. Fix typo (Enviroment), casing (powershell), formatting. Co-authored-by: Copilot <[email protected]>
2026-04-02docs: rewrite Building-Locally.md for clarity5an7y
Restructure the document into a logical flow: 1. Prerequisites — tools (winget), WDK download link, repo clone 2. Building the Samples — NuGet, EWDK, WDK MSI/winget subsections with -RunMode intro 3. Expected Output — build plan and completion summary 4. Ways to Run — common Build-Samples.ps1 invocations 5. Additional Notes — pre-release WDK, usbview .NET packs, NuGet version pinning Co-authored-by: Copilot <[email protected]>
2026-03-30Remove redundant specific-samples example from Building-Locally.md5an7y
2026-03-30Support wildcard patterns in -Samples parameter5an7y
- When -Samples contains wildcards (* or ?), discover all samples first then filter with -like (same pattern style as exclusions.csv) - Exact sample names still work as before without discovery overhead - Update parameter docs, examples, and Building-Locally.md
2026-03-30Remove Build-AllSamples.ps1 and Build-SampleSet.ps1 in favor of ↵5an7y
Build-Samples.ps1 - Delete Build-AllSamples.ps1 and Build-SampleSet.ps1 (replaced by Build-Samples.ps1) - Update ci.yml workflow to call Build-Samples.ps1 - Update Build-ChangedSamples.ps1 to call Build-Samples.ps1 - Rewrite Building-Locally.md Step 6 with new script usage and output format - Update Step 7 NuGet notes to reference Build-Samples.ps1
2024-09-23Deprecate WDK VSIX Install (#1219)Matt
* Deprecate WDK vsix install * Fix WDK extension version print * Remove unecessary splitting on version * Minor build info refactor * Fix indentation of output info * Enough messing with volume size output * Cleanup comment for vsix version * More cleanup and doc update * Remove deprecation statement and install vsix script. * Fixes and updates to building locally documentation. * Dont code scan on license or .md files. * Code scanning ignore changes to .md when pull request is made
2024-06-28RI develop to main (#1189)JakobL-MSFT
* Memory leakage in message "sizeof(SCANNER_MESSAGE) * threadCount * requestCount" bytes long memory is allocated but only "sizeof(SCANNER_MESSAGE) * threadCount" bytes long of it is freed. * Handles malloc function fail case * Refactors comment line * Solves the miscalculation of the message index * simbatt: Fix broken registry read-back The GetSimBattStateFromRegistry function is currently using default settings if GetSimBattStateFromRegistry succeeds, whereas settings from registry are only applied if GetSimBattStateFromRegistry fails. This does not make sense to me. Therefore proposing to remove the `!` negation from `if (!NT_SUCCESS(Status)) {` on the line after `Status = GetSimBattStateFromRegistry(Device, RegState);` so that default settings are loaded when registry read-back fails. * Issue of freeing memory without waiting completion of threads accessing it is fixed * Fixes information leakage warning Fixes the issue of possible information leakage from uninitialized padding bytes * Avoids possible multiplication overflow warning * Avoids possible multiplication overflow warning * CI Pipelines build with WDK Nuget Packages (#1179) Integrate nuget into the workflow pipelines * FI from main to develop (#1188) Fix text and minor issues in Winget configuration files Co-authored-by: Adonais Romero Gonzalez <[email protected]> * Improve version info, vsix installation, and update building locally readme * Fix printing vsix version * Refactored vsix install and cleaned up build sampleset --------- Co-authored-by: İsa Yurdagül <[email protected]> Co-authored-by: Fredrik Orderud <[email protected]> Co-authored-by: Christian Allred <[email protected]> Co-authored-by: tristanb-ntdev <[email protected]> Co-authored-by: Matt <[email protected]> Co-authored-by: Adonais Romero Gonzalez <[email protected]>
2024-05-22Upgrade NuGet to 26100.1 (#1162)JakobL-MSFT
* Upgrade NuGet to 10.0.26100.1-preview.ge-release * Upgrade NuGet to 10.0.26100.2 pre * Upgrade NuGet to 10.0.26100 * Upgrade NuGet to 10.0.26100.1 * Update Building-Locally.md * Update Building-Locally.md
2024-04-24Update Building-Locally.mdJakobL-MSFT
2024-04-18NuGet notes (#1120)JakobL-MSFT
* NuGet notes * Update Building-Locally.md * Update Building-Locally.md: Update instructions for usb\usbview sample * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md * Update Building-Locally.md
2023-11-13Minor adjustments to build instructions (#1021)Adonais Romero González
2023-11-1347451678: Windows-driver-samples /Building-Locally.md: Remove ping (`) from ↵JakobL-MSFT
instructions (#1050)
2023-06-01Add logs as artifacts for actions (#989)Adonais Romero González
2023-02-08Enable CodeQL to work thru reasonable workarounds - Cherry pick to main (#863)JakobL-MSFT
Enable CodeQL to work thru reasonable workarounds. (#857)
2023-02-03Incremental improvements of the sample build system (#849)JakobL-MSFT
2023-01-30Build scripts update (#844)Adonais Romero González
--------- Co-authored-by: Jakob Lichtenberg (170957) <[email protected]>