Skip to content

Commit 820832d

Browse files
committed
Add warnings for future deprecation of nixos options related to packaging
1 parent 183d069 commit 820832d

File tree

1 file changed

+57
-0
lines changed

1 file changed

+57
-0
lines changed

modules/flash-script.nix

+57
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,63 @@ in
366366
};
367367

368368
config = lib.mkIf cfg.enable {
369+
warnings = lib.optionals options.hardware.nvidia-jetpack.firmware.uefi.edk2NvidiaPatches.isDefined [
370+
''
371+
The option `hardware.nvidia-jetpack.firmware.uefi.edk2NvidiaPatches`
372+
will be deprecated soon. Please migrate to using the `nixpkgs.overlays`
373+
option to define an overlay that modifies the
374+
`pkgs.nvidia-jetpack.edk2NvidiaSrc` derivation. For example, see
375+
<jetpack-nixos/overlay-with-config.nix>.
376+
''
377+
]
378+
++ lib.optionals options.hardware.nvidia-jetpack.firmware.uefi.edk2UefiPatches.isDefined [
379+
''
380+
The option `hardware.nvidia-jetpack.firmware.uefi.edk2UefiPatches` will
381+
be deprecated soon. Please migrate to using the `nixpkgs.overlays`
382+
option to define an overlay that modifies the
383+
`pkgs.nvidia-jetpack.jetsonEdk2Uefi` derivation. For example, see
384+
<jetpack-nixos/overlay-with-config.nix>.
385+
''
386+
]
387+
++ lib.optionals options.hardware.nvidia-jetpack.flashScriptOverrides.patches.isDefined [
388+
''
389+
The option `hardware.nvidia-jetpack.flashScriptOverrides.patches` will
390+
be deprecated soon. Please migrate to using the `nixpkgs.overlays`
391+
option to define an overlay that modifies the
392+
`pkgs.nvidia-jetpack.flash-tools` derivation. For example, see
393+
<jetpack-nixos/overlay-with-config.nix>.
394+
''
395+
]
396+
++ lib.optionals options.hardware.nvidia-jetpack.flashScriptOverrides.postPatch.isDefined [
397+
''
398+
The option `hardware.nvidia-jetpack.flashScriptOverrides.postPatch`
399+
will be deprecated soon. Please migrate to using the `nixpkgs.overlays`
400+
option to define an overlay that modifies the
401+
`pkgs.nvidia-jetpack.flash-tools` derivation. For example, see
402+
<jetpack-nixos/overlay-with-config.nix>.
403+
''
404+
]
405+
++ lib.optionals options.hardware.nvidia-jetpack.firmware.optee.patches.isDefined [
406+
''
407+
The option `hardware.nvidia-jetpack.firmware.optee.patches` will be
408+
deprecated soon. Please migrate to using the `nixpkgs.overlays` option
409+
to define an overlay that modifies the `pkgs.nvidia-jetpack.opteeOS`
410+
and/or `pkgs.nvidia-jetpack.opteeTaDevKit` derivations. For example,
411+
see <jetpack-nixos/overlay-with-config.nix>.
412+
''
413+
]
414+
++ lib.optionals options.hardware.nvidia-jetpack.firmware.optee.extraMakeFlags.isDefined [
415+
''
416+
The option `hardware.nvidia-jetpack.firmware.optee.extraMakeFlags` will
417+
be deprecated soon. Please migrate to using the `nixpkgs.overlays`
418+
option to define an overlay that modifies the
419+
`pkgs.nvidia-jetpack.opteeOS` and/or
420+
`pkgs.nvidia-jetpack.opteeTaDevKit` derivations. For example, see
421+
<jetpack-nixos/overlay-with-config.nix>.
422+
''
423+
]
424+
;
425+
369426
hardware.nvidia-jetpack.flashScript = lib.warn "hardware.nvidia-jetpack.flashScript is deprecated, use config.system.build.flashScript" config.system.build.flashScript;
370427
hardware.nvidia-jetpack.devicePkgs = (lib.mapAttrs (_: lib.warn "hardware.nvidia-jetpack.devicePkgs is deprecated, use pkgs.nvidia-jetpack") pkgs.nvidia-jetpack);
371428

0 commit comments

Comments
 (0)