Search Unity

Hololens dll not found exception

Discussion in 'VR' started by jeanrouq, Feb 10, 2019.

  1. jeanrouq

    jeanrouq

    Joined:
    Jun 20, 2018
    Posts:
    7
    I have a windows dll that I can load without problem in a unity UWP app (laptop and surface pro4).
    When I try to load this dll in a hololens application, I have a DllNotFound exception.
    After investigating, I have found several issues :
    - the dll has a dependency to msvc runtime (msvc140P.dll, VCRuntme140 and so on)
    - the dll has a dependency to advapi32.dll and WINMM.dll
    upload_2019-2-10_13-53-23.png
    I think the source of the dll can be modified in order to remove dependencies to advapi and WINMM.
    However, for the visual runtime libraries, I think they are not present on hololens by default. So the question is can I add these libraries directly in the app package? Has anybody already had similar issue?
     
  2. jeanrouq

    jeanrouq

    Joined:
    Jun 20, 2018
    Posts:
    7
    For other person that might have this issue : After adding the three dependencies (msvc140P.dll, VCRuntime140 and concrt140.dll) in the unity Plugins folder, loading and P/Invoke of the dll is ok now.