amerkoleci / Vortice.Windows

.NET bindings for Direct3D12, Direct3D11, WIC, Direct2D1, XInput, XAudio, X3DAudio, DXC, Direct3D9 and DirectInput.
MIT License
1.01k stars 73 forks source link

Cannot build. #375

Closed Steph55 closed 1 year ago

Steph55 commented 1 year ago

Good day Amer!

Here are some of the errors I get when I try to build Vortice:

Severity Code Description Project File Line Suppression State Error SG0001 Unable to resolve dependency [Vortice.DXGI] for config file [vortice-direct3d11] Vortice.Direct3D11 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DXGI] for config file [vortice-direct3d11] Vortice.Direct3D11 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DXGI] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DXGI] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-xaudio2] Vortice.XAudio2 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-xaudio2] Vortice.XAudio2 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-media-foundation] Vortice.MediaFoundation C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-media-foundation] Vortice.MediaFoundation C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-directml] Vortice.DirectML C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-directml] Vortice.DirectML C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-dinput] Vortice.DirectInput C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-dinput] Vortice.DirectInput C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-d3d-compiler] Vortice.D3DCompiler C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.DirectX] for config file [vortice-d3d-compiler] Vortice.D3DCompiler C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct3D12] for config file [vortice-directstorage] Vortice.DirectStorage C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct3D12] for config file [vortice-directstorage] Vortice.DirectStorage C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct3D12] for config file [vortice-directml] Vortice.DirectML C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct3D12] for config file [vortice-directml] Vortice.DirectML C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct2D1] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [Vortice.Direct2D1] for config file [vortice-dcomp] Vortice.DirectComposition C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-uianimation] Vortice.UIAnimation C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-uianimation] Vortice.UIAnimation C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-dxc] Vortice.Dxc C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-dxc] Vortice.Dxc C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-directx] Vortice.DirectX C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-direct3d9] Vortice.Direct3D9 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Error SG0001 Unable to resolve dependency [SharpGen.Runtime.COM] for config file [vortice-direct3d9] Vortice.Direct3D9 C:\Users\pstep.nuget\packages\sharpgentools.sdk\2.0.0-beta.11\Sdk\Sdk.targets 191 Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.DXGI'. Vortice.DXGI C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.DXGI'. Vortice.DXGI C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.Direct3D12'. Vortice.Direct3D12 C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.Direct3D12'. Vortice.Direct3D12 C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.Direct2D1'. Vortice.Direct2D1 C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\Vortice.Direct2D1'. Vortice.Direct2D1 C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\tests\Vortice.DXGI.Tests'. Vortice.DXGI.Tests C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\tests\Vortice.DXGI.Tests'. Vortice.DXGI.Tests C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 48
Warning Unable to locate repository with working directory that contains directory 'F:\Vortice.Windows-main\src\tests\Vortice.Dxc.Test'. Vortice.Dxc.Test C:\Users\pstep.nuget\packages\microsoft.build.tasks.git\1.1.1\build\Microsoft.Build.Tasks.Git.targets 25

And here are some lines from the output window:

Build started... 1>------ Build started: Project: Vortice.UIAnimation, Configuration: Release Any CPU ------ 2>------ Build started: Project: Vortice.Direct3D9, Configuration: Release Any CPU ------ 3>------ Build started: Project: Vortice.Dxc, Configuration: Release Any CPU ------ 4>------ Build started: Project: Vortice.DirectX, Configuration: Release Any CPU ------ Failed to restore F:\Vortice.Windows-main\src\Vortice.Direct3D9\Vortice.Direct3D9.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.DirectX\Vortice.DirectX.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.DirectStorage\Vortice.DirectStorage.csproj (in 4 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.Dxc\Vortice.Dxc.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.Direct3D12\Vortice.Direct3D12.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.DirectML\Vortice.DirectML.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.MediaFoundation\Vortice.MediaFoundation.csproj (in 3 ms). NuGet package restore failed. Please see Error List window for detailed warnings and errors. Failed to restore F:\Vortice.Windows-main\src\Vortice.DirectInput\Vortice.DirectInput.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.UIAnimation\Vortice.UIAnimation.csproj (in 2 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.XAudio2\Vortice.XAudio2.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.Direct2D1\Vortice.Direct2D1.csproj (in 4 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.Direct3D11\Vortice.Direct3D11.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.DirectComposition\Vortice.DirectComposition.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.WinUI\Vortice.WinUI.csproj (in 3 ms). Failed to restore F:\Vortice.Windows-main\src\Vortice.D3DCompiler\Vortice.D3DCompiler.csproj (in 3 ms). 2>F:\Vortice.Windows-main\src\Vortice.Direct3D9\Vortice.Direct3D9.csproj : error NU1008: Projects that use central package version management should not define the version on the PackageReference items but on the PackageVersion items: SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub;Vortice.Mathematics;SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub;Vortice.Mathematics. 3>F:\Vortice.Windows-main\src\Vortice.Dxc\Vortice.Dxc.csproj : error NU1008: Projects that use central package version management should not define the version on the PackageReference items but on the PackageVersion items: SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub;SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub. 2>Done building project "Vortice.Direct3D9.csproj" -- FAILED. 3>Done building project "Vortice.Dxc.csproj" -- FAILED. 4>F:\Vortice.Windows-main\src\Vortice.DirectX\Vortice.DirectX.csproj : error NU1008: Projects that use central package version management should not define the version on the PackageReference items but on the PackageVersion items: SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub;Vortice.Mathematics. 1>F:\Vortice.Windows-main\src\Vortice.UIAnimation\Vortice.UIAnimation.csproj : error NU1008: Projects that use central package version management should not define the version on the PackageReference items but on the PackageVersion items: SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub;SharpGen.Runtime.COM;Microsoft.SourceLink.GitHub.

Is there something I should have done beforehand? I did install the required components...

amerkoleci commented 1 year ago

Did you tried to do: nuget update first and then compile?

Usually I clean and build should work.

Steph55 commented 1 year ago

Thank you very much for your answer, but maybe I simply don't know how to do this... I installed the nuget command line and I did "Nuget update Vortice.Windows.Sln". It just told me that no project was found with packages.config.

However, I had done Dotnet restore in the package manager before compiling and it did not help.

Le mer. 4 janv. 2023 à 15:45, Amer Koleci @.***> a écrit :

Did you tried to do: nuget update first and then compile?

Usually I clean and build should work.

— Reply to this email directly, view it on GitHub https://github.com/amerkoleci/Vortice.Windows/issues/375#issuecomment-1371399784, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADJJUEERSIG7GPDXUCNQLQLWQXOOTANCNFSM6AAAAAATRGDPLQ . You are receiving this because you authored the thread.Message ID: @.***>