Skip to content

Jitify 2 MSCV GetTempPath2A requires Windows 11 SDK 10.0.22000.0 #1328

@ptheywood

Description

@ptheywood

Jitify 2 MSCV GetTempPath2A requires Windows 11 SDK 10.0.22000.0

This is fine for all up to date Windows 10 and Windows 11 machines, but not all users keep their systems up to date.

GetTempPathA is (still) available with the same behaviour for regular windows users/program, but does not work for SYSTEM programs.

Ideally this should use GetTempPath2A if available (via macro guarding) and GetTempPathA if it is not available.

Macro guarding may not be sufficient, if a wheel is produced with a recent enough windows SDK but executed on an old Windows 10 machine without the backported function (i.e. an old kernel32.dll) it may error at runtime.

This can be included in NVIDIA/jitify#146 which is still open, and shipped in our patches until this is merged.


Propperly testing both sides of the ifdef would be a faff, but just tweaking the ifdef to check both sides manually should be fine. Finding the right value to ifdef over will be the most difficult (for windows 10 and 11 support).


  • Use GetTempPath2A/GetTempPathA based on availability
  • Remove the limitation about this from the readme

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions