summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/common.targets71
1 files changed, 1 insertions, 70 deletions
diff --git a/build/common.targets b/build/common.targets
index 6bf1305e..abcf2d87 100644
--- a/build/common.targets
+++ b/build/common.targets
@@ -3,79 +3,10 @@
<!--compile constants -->
<PropertyGroup>
+ <AssemblySearchPaths>$(AssemblySearchPaths);{GAC}</AssemblySearchPaths>
<DefineConstants Condition="$(OS) == 'Windows_NT'">$(DefineConstants);SMAPI_FOR_WINDOWS</DefineConstants>
</PropertyGroup>
- <!-- add game references-->
- <Choose>
- <When Condition="'$(MSBuildProjectName)' == 'SMAPI' OR '$(MSBuildProjectName)' == 'SMAPI.Mods.ConsoleCommands' OR '$(MSBuildProjectName)' == 'SMAPI.Mods.SaveBackup' OR '$(MSBuildProjectName)' == 'SMAPI.Tests'">
- <!-- Windows -->
- <PropertyGroup>
- <!--recognise XNA Framework DLLs in the GAC-->
- <AssemblySearchPaths>$(AssemblySearchPaths);{GAC}</AssemblySearchPaths>
- </PropertyGroup>
-
- <ItemGroup Condition="$(OS) == 'Windows_NT'">
- <Reference Include="Stardew Valley">
- <HintPath>$(GamePath)\Stardew Valley.exe</HintPath>
- <Private Condition="'$(MSBuildProjectName)' != 'SMAPI.Tests'">False</Private>
- </Reference>
- <Reference Include="StardewValley.GameData">
- <HintPath>$(GamePath)\StardewValley.GameData.dll</HintPath>
- <Private Condition="'$(MSBuildProjectName)' != 'SMAPI.Tests'">False</Private>
- </Reference>
- <Reference Include="Netcode">
- <HintPath>$(GamePath)\Netcode.dll</HintPath>
- <Private Condition="'$(MSBuildProjectName)' != 'SMAPI.Tests'">False</Private>
- </Reference>
- <Reference Include="Microsoft.Xna.Framework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
- <Private>False</Private>
- </Reference>
- <Reference Include="Microsoft.Xna.Framework.Game, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
- <Private>False</Private>
- </Reference>
- <Reference Include="Microsoft.Xna.Framework.Graphics, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
- <Private>False</Private>
- </Reference>
- <Reference Include="Microsoft.Xna.Framework.Xact, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
- <Private>False</Private>
- </Reference>
- </ItemGroup>
-
- <!-- Linux/Mac -->
- <ItemGroup Condition="$(OS) != 'Windows_NT'">
- <Reference Include="StardewValley">
- <HintPath>$(GamePath)\StardewValley.exe</HintPath>
- <Private>False</Private>
- </Reference>
- <Reference Include="StardewValley.GameData.MonoGame">
- <HintPath>$(GamePath)\StardewValley.GameData.MonoGame.dll</HintPath>
- <Private Condition="'$(MSBuildProjectName)' != 'SMAPI.Tests'">False</Private>
- </Reference>
- <Reference Include="MonoGame.Framework">
- <HintPath>$(GamePath)\MonoGame.Framework.dll</HintPath>
- <Private>False</Private>
- </Reference>
- </ItemGroup>
-
- <!-- common -->
- <ItemGroup>
- <Reference Include="GalaxyCSharp">
- <HintPath>$(GamePath)\GalaxyCSharp.dll</HintPath>
- <Private>False</Private>
- </Reference>
- <Reference Include="Lidgren.Network">
- <HintPath>$(GamePath)\Lidgren.Network.dll</HintPath>
- <Private>False</Private>
- </Reference>
- <Reference Include="xTile">
- <HintPath>$(GamePath)\xTile.dll</HintPath>
- <Private>False</Private>
- </Reference>
- </ItemGroup>
- </When>
- </Choose>
-
<!-- if game path is invalid, show one user-friendly error instead of a slew of reference errors -->
<Target Name="ValidateInstallPath" AfterTargets="BeforeBuild">
<Error Condition="!Exists('$(GamePath)')" Text="Failed to find the game install path automatically; edit the *.csproj file and manually add a &lt;GamePath&gt; setting with the full directory path containing the Stardew Valley executable." />