Bellemer Lord
Bellemer Lord

Reputation: 1

Importing .dll with Unity and HoloLens2

I tried to develop an augmented reality application with Unity for HoloLens2. Therefore we need to connect the application with an external controller from fischertechnik. I tried to import the .dll which is needed into unity. There are no errors in Visual Studio, in the Unity Player everything works fine and the application connects with the controller. But if we try to build it, a bunch of errors occur:enter image description here. Would be nice if someone could help! Thanks

Settings:

Build Settings

Player Settings

DLLs

Upvotes: 0

Views: 778

Answers (1)

Rob Caplan - MSFT
Rob Caplan - MSFT

Reputation: 21919

Short answer: Change your minimum UWP setting to 10.0.16299 or later (I'd choose at least 18362 for HoloLens 2)

More info:

HoloLens applications are UWP apps, so you will need to make sure that your libraries are supported in UWP.

From the errors you list, the problems come from System.Reactive.Windows.Threading.dll. Per the System.Reactive.Windows.Threading project at https://github.com/dotnet/reactive , the supported platforms for v5.x include UWP 10.0.16299 with a note that "Support for UWP 10.0 has been removed"

Looking at your Build Settings, your app's minimum UWP target is 10.0.10240.0 (aka UWP 10.0).

This specific error should go away if you upgrade your minimum UWP setting to 10.0.16299.

16299 was the first UWP version to support .Net Standard 2.0 and so is a common base level for managed UWP apps. 16299 shipped as the Fall Creators Update in November 2017, several years and versions before the HoloLens 2 shipped in 2019 with Build 18362.1039.

Upvotes: 1

Related Questions