From d319a92acc97dc57aeec5f7da450043e620a064f Mon Sep 17 00:00:00 2001
From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com>
Date: Tue, 27 Oct 2026 20:47:44 -0400
Subject: [PATCH] fix(packaging): include HIDMaestro MIT notice
---
.github/workflows/ci-driver.yml | 16 +++++++++++
CMakeLists.txt | 4 +++
LICENSES/HIDMaestro-MIT.md | 27 +++++++++++++++++++
LICENSES/license-map.md | 15 +++++++----
README.md | 11 +++-----
cmake/packaging/windows.cmake | 5 ++--
.../windows/shared/generic_pid_protocol.hpp | 3 +++
7 files changed, 67 insertions(+), 14 deletions(-)
create mode 100644 LICENSES/HIDMaestro-MIT.md
diff --git a/.github/workflows/ci-driver.yml b/.github/workflows/ci-driver.yml
index 2e022f6e..fbd25718 100644
--- a/.github/workflows/ci-driver.yml
+++ b/.github/workflows/ci-driver.yml
@@ -177,6 +177,22 @@ jobs:
-Destination `
".\artifacts\libvirtualhid-Windows-AMD64-driver-installer.msi"
+ - name: Verify packaged license notices
+ shell: pwsh
+ run: |
+ $packageDirectory = ".\cmake-build-driver\cpack_artifacts\_CPack_Packages\win64\WIX\libvirtualhid"
+ $licenseDirectory = Join-Path $packageDirectory "licenses"
+ foreach ($license in @("MIT.md", "HIDMaestro-MIT.md", "LicenseRef-LizardByte-SAL-1.0.md")) {
+ $source = Join-Path .\LICENSES $license
+ $packaged = Join-Path $licenseDirectory $license
+ if (!(Test-Path -LiteralPath $packaged -PathType Leaf)) {
+ throw "Packaged license notice is missing: $license"
+ }
+ if ((Get-FileHash -LiteralPath $source).Hash -ne (Get-FileHash -LiteralPath $packaged).Hash) {
+ throw "Packaged license notice differs from its source: $license"
+ }
+ }
+
- name: Export Azure driver signing certificate
if: >-
github.event_name == 'push' &&
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e44022b7..945b0d56 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -172,6 +172,10 @@ if(LIBVIRTUALHID_INSTALL)
RENAME LICENSE
COMPONENT library)
+ install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/LICENSES/HIDMaestro-MIT.md"
+ DESTINATION "${CMAKE_INSTALL_DATADIR}/licenses/libvirtualhid"
+ COMPONENT library)
+
configure_package_config_file(
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/libvirtualhid-config.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/libvirtualhid-config.cmake"
diff --git a/LICENSES/HIDMaestro-MIT.md b/LICENSES/HIDMaestro-MIT.md
new file mode 100644
index 00000000..2575f6f7
--- /dev/null
+++ b/LICENSES/HIDMaestro-MIT.md
@@ -0,0 +1,27 @@
+MIT License
+
+"And we talk of Christ, we rejoice in Christ, we preach of Christ, we prophesy of Christ,
+and we write according to our prophecies, that our children may know to what source they
+may look for a remission of their sins." — 2 Nephi 25:26
+
+Glory, honor, and praise to the Lord Jesus Christ, the source of all truth and salvation, forever and ever.
+
+Copyright (c) 2026 HIDMaestro Contributors
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/LICENSES/license-map.md b/LICENSES/license-map.md
index 2f528d73..0175a170 100644
--- a/LICENSES/license-map.md
+++ b/LICENSES/license-map.md
@@ -7,6 +7,12 @@ Windows driver and macOS broker packages.
- Cross-platform library source, public headers, non-driver backends, examples,
tests, build scripts, and documentation unless listed below:
[MIT](https://github.com/LizardByte/libvirtualhid/blob/master/LICENSES/MIT.md).
+- HIDMaestro's `MinimumViablePidFfbBlock` descriptor bytes in
+ `src/platform/windows/shared/generic_pid_protocol.hpp`, used by the Windows
+ library backend, UMDF driver, and packaged tools:
+ [HIDMaestro MIT notice](https://github.com/LizardByte/libvirtualhid/blob/master/LICENSES/HIDMaestro-MIT.md),
+ Copyright (c) 2026 HIDMaestro Contributors. The notice is copied from
+ [HIDMaestro's LICENSE](https://github.com/hifihedgehog/HIDMaestro/blob/master/LICENSE).
- Windows UMDF driver source under `src/platform/windows/driver/`, the broker
service under `src/platform/windows/broker/`, and the broker entitlement and
evaluation sources
@@ -19,8 +25,7 @@ Windows driver and macOS broker packages.
broker bundles and DMGs:
[LizardByte Source-Available License 1.0](https://github.com/LizardByte/libvirtualhid/blob/master/LICENSES/LicenseRef-LizardByte-SAL-1.0.md).
-Every installed library distribution includes the MIT notice under
-`share/licenses/libvirtualhid`. The Windows driver MSI may include MIT-licensed
-helper components from this repository; packaged installs include both license
-texts for that reason. The macOS broker DMG likewise includes the MIT library
-and the LB-SAL broker, with both license texts.
+Every installed library distribution includes the LizardByte and HIDMaestro MIT
+notices under `share/licenses/libvirtualhid`. The Windows driver MSI includes
+both MIT notices and the LB-SAL license under `licenses`. The macOS broker DMG
+includes the `LICENSES` directory with the MIT notices and the LB-SAL license.
diff --git a/README.md b/README.md
index ade92673..f7a819d2 100644
--- a/README.md
+++ b/README.md
@@ -137,17 +137,17 @@ same API where the backend exposes them.
Alternatives exist if `libvirtualhid` does not meet your needs.
| Feature | `libvirtualhid` | [ViGEmBus](https://github.com/nefarius/ViGEmBus) | [HIDMaestro](https://github.com/hifihedgehog/HIDMaestro) | [inputtino](https://github.com/games-on-whales/inputtino) | [WinUHid](https://github.com/cgutman/WinUHid) |
-|-----------------------------------|---------------------------------------------------|---------------------------------------------------|----------------------------------------------------------|-----------------------------------------------------------|---------------------------------------------------|
+| --------------------------------- | ------------------------------------------------- | ------------------------------------------------- | -------------------------------------------------------- | --------------------------------------------------------- | ------------------------------------------------- |
| Windows support | ✅ | ✅ | ✅ | ❌ | ✅ |
| Linux support | ✅ | ❌ | ❌ | ✅ | ❌ |
| Windows AMD64 support | ✅ | ✅ | ✅ | - | ✅ |
-| Windows ARM64 support | ❌5 | ✅ | ❌6 | - | ✅ |
+| Windows ARM64 support | ❌5 | ✅ | ✅ | - | ✅ |
| Windows user-mode driver | ✅ | ❌ | ✅ | - | ✅ |
| No Windows kernel-mode driver | ✅ | ❌ | ✅ | - | ✅ |
| Descriptor-defined HID devices | ✅ | ❌ | ✅ | ✅1 | ✅ |
| Platform-neutral C++ API | ✅ | ❌2 | ❌2 | ❌3 | ❌2 |
-| Keyboard | ✅ | ❌ | ❌ | ✅ | ✅4 |
-| Mouse | ✅ | ❌ | ❌ | ✅ | ✅4 |
+| Keyboard | ✅ | ❌ | ✅ | ✅ | ✅4 |
+| Mouse | ✅ | ❌ | ✅ | ✅ | ✅4 |
| Touchscreen, trackpad, or pen | ✅ | ❌ | ❌ | ✅ | ✅4 |
| Generic HID gamepad | ✅ | ❌ | ✅ | ❌ | ✅4 |
| Xbox 360 gamepad | ✅ | ✅ | ✅ | ❌ | ✅4 |
@@ -181,9 +181,6 @@ require a Microsoft dashboard signing path, such as WHQL/Hardware Dev Center
signing; the current Azure Trusted Signing catalog/MSI flow is not sufficient
for ARM64 release driver package installation.
-6 HIDMaestro documents a `win-x64`
-test app path and does not currently advertise an ARM64 build.
-
## 📄 License
The cross-platform `libvirtualhid` library is licensed under the
diff --git a/cmake/packaging/windows.cmake b/cmake/packaging/windows.cmake
index bae08b16..0ebd3090 100644
--- a/cmake/packaging/windows.cmake
+++ b/cmake/packaging/windows.cmake
@@ -61,9 +61,10 @@ if(LIBVIRTUALHID_DRIVER_TEST_CERTIFICATE)
OPTIONAL)
endif()
-install(FILES "${PROJECT_SOURCE_DIR}/LICENSES/MIT.md"
+install(FILES
+ "${PROJECT_SOURCE_DIR}/LICENSES/MIT.md"
+ "${PROJECT_SOURCE_DIR}/LICENSES/HIDMaestro-MIT.md"
DESTINATION "licenses"
- RENAME "MIT.md"
COMPONENT driver)
install(FILES "${LIBVIRTUALHID_DRIVER_LICENSE_FILE}"
diff --git a/src/platform/windows/shared/generic_pid_protocol.hpp b/src/platform/windows/shared/generic_pid_protocol.hpp
index 1a334910..4a86f4bc 100644
--- a/src/platform/windows/shared/generic_pid_protocol.hpp
+++ b/src/platform/windows/shared/generic_pid_protocol.hpp
@@ -95,6 +95,9 @@ namespace lvh::detail::windows {
* Joystick top-level collection; exposing PID reports from a Game Pad
* collection can fault pid.dll during effect creation.
*
+ * The HIDMaestro descriptor block is Copyright (c) 2026 HIDMaestro Contributors
+ * and licensed under MIT; see LICENSES/HIDMaestro-MIT.md for the full notice.
+ *
* @param source Built-in Generic Controller report descriptor.
* @return Windows descriptor, or an empty vector when @p source is not the expected built-in layout.
*/