From f00ac7d6c236666f19b629982dd002c9d0ac8aa6 Mon Sep 17 00:00:00 2001 From: Mel Bourgeois Date: Sun, 3 Nov 2024 14:52:13 -0600 Subject: [PATCH] nixgl: clarify purpose of modified override Co-authored-by: Jure Varlec --- modules/misc/nixgl.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/misc/nixgl.nix b/modules/misc/nixgl.nix index d125c90df..ec37581ad 100644 --- a/modules/misc/nixgl.nix +++ b/modules/misc/nixgl.nix @@ -242,7 +242,11 @@ in { shopt -u nullglob # Revert nullglob back to its normal default state ''; })) // { - # Override arguments to the package itself, rather than the nixGL wrapper + # When the nixGL-wrapped package is given to a HM module, the module + # might want to override the package arguments, but our wrapper + # wouldn't know what to do with them. So, we rewrite the override + # function to instead forward the arguments to the package's own + # override function. override = args: (makePackageWrapper vendor environment (pkg.override args)); });