Skip to content
Permalink
Browse files

[Build] Fix restore phase in Xenko.build

  • Loading branch information
xen2 committed Nov 29, 2018
1 parent dfb2deb commit 1fcbd1d3f02cd3bd6f5f30fd498a480f1489ff14
Showing with 26 additions and 14 deletions.
  1. +26 −14 build/Xenko.build
@@ -31,7 +31,7 @@ Example of use:
Don't forget to build for VS2013 by using MSBuild 12.0,
or if you're using a newer version of MSBuild, pass the flag /p:VisualStudioVersion=12.0 when calling MSBuild in the command line.
-->
<Target Name="VSIXPlugin" DependsOnTargets="RestoreWindows">
<Target Name="VSIXPlugin" DependsOnTargets="Restore">
<ItemGroup>
<FilesToDeleteVSIX Include="$(MSBuildThisFileDirectory)Xenko.VisualStudio.Package.*.nupkg"/>
</ItemGroup>
@@ -118,26 +118,26 @@ Example of use:
<Exec Command="$(XenkoRoot)sources\editor\Xenko.Assets.Presentation\EditorPackage\generate-editor-package.bat" WorkingDirectory="$(XenkoRoot)sources\editor\Xenko.Assets.Presentation\EditorPackage"/>
</Target>

<Target Name="RestoreWindows">
<PropertyGroup>
<Target Name="Restore">
<PropertyGroup>
<RestoreExec><![CDATA[
set XenkoPlatforms=$(XenkoPlatforms)
"$(NuGetPath)" restore "$(XenkoSolution).sln"
]]></RestoreExec>
set XenkoPlatforms=$(XenkoPlatforms)
"$(NuGetPath)" restore "$(XenkoSolution).sln"
]]></RestoreExec>
</PropertyGroup>
<Exec Command="$(RestoreExec)" />
</Target>

<Target Name="Build" DependsOnTargets="CopyXenkoKey">
<CallTarget Targets="Restore"/>
<MSBuild Targets="Restore" Projects="$(MSBuildThisFileFullPath)" Properties="XenkoPlatforms=$(XenkoPlatforms);XenkoSolution=$(XenkoSolution)"/>
<MSBuild Targets="Build" Projects="$(XenkoSolution).sln" Properties="$(BuildProperties);Platform=Mixed Platforms"/>
</Target>

<Target Name="BuildRuntime" DependsOnTargets="CopyXenkoKey">
<PropertyGroup>
<XenkoSolution>$(XenkoSolution).Runtime</XenkoSolution>
</PropertyGroup>
<CallTarget Targets="Restore"/>
<MSBuild Targets="Restore" Projects="$(MSBuildThisFileFullPath)" Properties="XenkoPlatforms=$(XenkoPlatforms);XenkoSolution=$(XenkoSolution)"/>
<MSBuild Targets="Build" Projects="$(XenkoSolution).sln" Properties="$(BuildProperties)"/>
</Target>

@@ -184,8 +184,12 @@ Example of use:
<Target Name="BuildWindows10" DependsOnTargets="BuildUWP" />

<Target Name="BuildUWP" DependsOnTargets="CopyXenkoKey">
<Exec Command='"$(NuGetPath)" restore "$(XenkoSolution).Runtime.sln"' />
<MSBuild Targets="Build" Projects="$(XenkoSolution).Runtime.sln" Properties="$(BuildProperties);XenkoPlatforms=UWP;XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
<PropertyGroup>
<XenkoSolution>$(XenkoSolution).Runtime</XenkoSolution>
<XenkoPlatforms>UWP</XenkoPlatforms>
</PropertyGroup>
<MSBuild Targets="Restore" Projects="$(MSBuildThisFileFullPath)" Properties="XenkoPlatforms=$(XenkoPlatforms);XenkoSolution=$(XenkoSolution)"/>
<MSBuild Targets="Build" Projects="$(XenkoSolution).sln" Properties="$(BuildProperties);XenkoPlatforms=$(XenkoPlatforms);XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
</Target>

<Target Name="BuildWindowsPhone" DependsOnTargets="CopyXenkoKey">
@@ -199,13 +203,21 @@ Example of use:
</Target>

<Target Name="BuildLinux" DependsOnTargets="CopyXenkoKey">
<Exec Command='"$(NuGetPath)" restore "$(XenkoSolution).Runtime.sln"' />
<MSBuild Targets="Build" Projects="$(XenkoSolution).Runtime.sln" Properties="$(BuildProperties);XenkoPlatforms=Linux;XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
<PropertyGroup>
<XenkoSolution>$(XenkoSolution).Runtime</XenkoSolution>
<XenkoPlatforms>Linux</XenkoPlatforms>
</PropertyGroup>
<MSBuild Targets="Restore" Projects="$(MSBuildThisFileFullPath)" Properties="XenkoPlatforms=$(XenkoPlatforms);XenkoSolution=$(XenkoSolution)"/>
<MSBuild Targets="Build" Projects="$(XenkoSolution).sln" Properties="$(BuildProperties);XenkoPlatforms=$(XenkoPlatforms);XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
</Target>

<Target Name="BuildLinuxVulkan" DependsOnTargets="CopyXenkoKey">
<Exec Command='"$(NuGetPath)" restore "$(XenkoSolution).Runtime.sln"' />
<MSBuild Targets="Build" Projects="$(XenkoSolution).Runtime.sln" Properties="$(BuildProperties);XenkoPlatforms=Linux;XenkoGraphicsApi=Vulkan;XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
<PropertyGroup>
<XenkoSolution>$(XenkoSolution).Runtime</XenkoSolution>
<XenkoPlatforms>Linux</XenkoPlatforms>
</PropertyGroup>
<MSBuild Targets="Restore" Projects="$(MSBuildThisFileFullPath)" Properties="XenkoPlatforms=$(XenkoPlatforms);XenkoSolution=$(XenkoSolution)"/>
<MSBuild Targets="Build" Projects="$(XenkoSolution).sln" Properties="$(BuildProperties);XenkoPlatforms=$(XenkoPlatforms);XenkoGraphicsApi=Vulkan;XenkoSkipAutoPack=true;XenkoSkipUnitTests=true"/>
</Target>

<Target Name="BuildmacOS" DependsOnTargets="CopyXenkoKey">

0 comments on commit 1fcbd1d

Please sign in to comment.
You can’t perform that action at this time.