diff options
| -rw-r--r-- | MediaBrowser.Model.Portable/Fody.targets | 89 | ||||
| -rw-r--r-- | MediaBrowser.Model.Portable/FodyWeavers.xml | 4 | ||||
| -rw-r--r-- | MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj | 6 | ||||
| -rw-r--r-- | MediaBrowser.Model.Portable/packages.config | 2 | ||||
| -rw-r--r-- | Nuget/MediaBrowser.Common.nuspec | 2 |
5 files changed, 103 insertions, 0 deletions
diff --git a/MediaBrowser.Model.Portable/Fody.targets b/MediaBrowser.Model.Portable/Fody.targets new file mode 100644 index 000000000..a668a51fc --- /dev/null +++ b/MediaBrowser.Model.Portable/Fody.targets @@ -0,0 +1,89 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <Choose> + <When Condition="$(NCrunchOriginalSolutionDir) != '' And $(NCrunchOriginalSolutionDir) != '*Undefined*'"> + <PropertyGroup> + <FodySolutionDir>$(NCrunchOriginalSolutionDir)</FodySolutionDir> + </PropertyGroup> + </When> + <When Condition="$(SolutionDir) != '' And $(SolutionDir) != '*Undefined*'"> + <PropertyGroup> + <FodySolutionDir>$(SolutionDir)</FodySolutionDir> + </PropertyGroup> + </When> + <When Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'"> + <PropertyGroup> + <FodySolutionDir>$(MSBuildProjectDirectory)\..\</FodySolutionDir> + </PropertyGroup> + </When> + </Choose> + <Choose> + <When Condition="$(KeyOriginatorFile) != '' And $(KeyOriginatorFile) != '*Undefined*'"> + <PropertyGroup> + <FodyKeyFilePath>$(KeyOriginatorFile)</FodyKeyFilePath> + </PropertyGroup> + </When> + <When Condition="$(AssemblyOriginatorKeyFile) != '' And $(AssemblyOriginatorKeyFile) != '*Undefined*'"> + <PropertyGroup> + <FodyKeyFilePath>$(AssemblyOriginatorKeyFile)</FodyKeyFilePath> + </PropertyGroup> + </When> + <Otherwise > + <PropertyGroup> + <FodyKeyFilePath></FodyKeyFilePath> + </PropertyGroup> + </Otherwise> + </Choose> + <PropertyGroup> + <IntermediateDir>$(ProjectDir)$(IntermediateOutputPath)</IntermediateDir> + <FodyMessageImportance Condition="$(FodyMessageImportance) == '' Or $(FodyMessageImportance) == '*Undefined*'">Low</FodyMessageImportance> + <FodySignAssembly Condition="$(FodySignAssembly) == '' Or $(FodySignAssembly) == '*Undefined*'">$(SignAssembly)</FodySignAssembly> + <FodyPath Condition="$(FodyPath) == '' Or $(FodyPath) == '*Undefined*'">$(MSBuildThisFileDirectory)</FodyPath> + </PropertyGroup> + <UsingTask + TaskName="Fody.WeavingTask" + AssemblyFile="$(FodyPath)\Fody.dll" /> + <Target + AfterTargets="AfterCompile" + Name="WinFodyTarget" + Condition=" '$(OS)' == 'Windows_NT'"> + + <Fody.WeavingTask + AssemblyPath="@(IntermediateAssembly)" + IntermediateDir="$(IntermediateDir)" + KeyFilePath="$(FodyKeyFilePath)" + MessageImportance="$(FodyMessageImportance)" + ProjectDirectory="$(ProjectDir)" + SolutionDir="$(FodySolutionDir)" + References="@(ReferencePath)" + SignAssembly="$(FodySignAssembly)" + ReferenceCopyLocalPaths="@(ReferenceCopyLocalPaths)" + DefineConstants="$(DefineConstants)" + /> + </Target> + + <Target + AfterTargets="AfterBuild" + Name="NonWinFodyTarget" + Condition=" '$(OS)' != 'Windows_NT'"> + <Fody.WeavingTask + AssemblyPath="$(TargetPath)" + IntermediateDir="$(IntermediateDir)" + KeyFilePath="$(FodyKeyFilePath)" + MessageImportance="$(FodyMessageImportance)" + ProjectDirectory="$(ProjectDir)" + SolutionDir="$(FodySolutionDir)" + References="@(ReferencePath)" + SignAssembly="$(FodySignAssembly)" + ReferenceCopyLocalPaths="$(ReferenceCopyLocalPaths)" + DefineConstants="$(DefineConstants)" + /> + </Target> + + + <!--Support for ncrunch--> + <ItemGroup> + <None Include="$(FodyPath)\*.*" /> + </ItemGroup> + +</Project>
\ No newline at end of file diff --git a/MediaBrowser.Model.Portable/FodyWeavers.xml b/MediaBrowser.Model.Portable/FodyWeavers.xml new file mode 100644 index 000000000..bb0f322ee --- /dev/null +++ b/MediaBrowser.Model.Portable/FodyWeavers.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<Weavers> + <PropertyChanged /> +</Weavers>
\ No newline at end of file diff --git a/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj b/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj index a79ac7b50..3e5274422 100644 --- a/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj +++ b/MediaBrowser.Model.Portable/MediaBrowser.Model.Portable.csproj @@ -16,6 +16,7 @@ <ProjectTypeGuids>{786C830F-07A1-408B-BD7F-6EE04809D6DB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir> <RestorePackages>true</RestorePackages> + <FodyPath>..\packages\Fody.1.13.12</FodyPath> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <DebugSymbols>true</DebugSymbols> @@ -36,6 +37,7 @@ </PropertyGroup> <ItemGroup> <!-- A reference to the entire .NET Framework is automatically included --> + <None Include="Fody.targets" /> <None Include="packages.config" /> </ItemGroup> <ItemGroup> @@ -370,6 +372,9 @@ </Compile> <Compile Include="Properties\AssemblyInfo.cs" /> </ItemGroup> + <ItemGroup> + <Content Include="FodyWeavers.xml" /> + </ItemGroup> <Import Project="$(MSBuildExtensionsPath32)\Microsoft\Portable\$(TargetFrameworkVersion)\Microsoft.Portable.CSharp.targets" /> <PropertyGroup> <PostBuildEvent>if $(ConfigurationName) == Release ( @@ -378,6 +383,7 @@ xcopy "$(TargetPath)" "$(SolutionDir)\Nuget\dlls\" /y /d /r /i </PropertyGroup> <Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" /> <Import Project="..\packages\Microsoft.Bcl.Build.1.0.8\tools\Microsoft.Bcl.Build.targets" /> + <Import Project="Fody.targets" /> <!-- To modify your build process, add your task inside one of the targets below and uncomment it. Other similar extension points exist, see Microsoft.Common.targets. <Target Name="BeforeBuild"> diff --git a/MediaBrowser.Model.Portable/packages.config b/MediaBrowser.Model.Portable/packages.config index 6cfe4452b..9fe1f7e4b 100644 --- a/MediaBrowser.Model.Portable/packages.config +++ b/MediaBrowser.Model.Portable/packages.config @@ -1,6 +1,8 @@ <?xml version="1.0" encoding="utf-8"?> <packages> + <package id="Fody" version="1.13.12" targetFramework="portable-net45+sl40+wp71+win" /> <package id="Microsoft.Bcl" version="1.0.19" targetFramework="portable-win+net45+sl40+wp71" /> <package id="Microsoft.Bcl.Async" version="1.0.16" targetFramework="portable-win+net45+sl40+wp71" /> <package id="Microsoft.Bcl.Build" version="1.0.8" targetFramework="portable-win+net45+sl40+wp71" /> + <package id="PropertyChanged.Fody" version="1.40.3" targetFramework="portable-net45+sl40+wp71+win" /> </packages>
\ No newline at end of file diff --git a/Nuget/MediaBrowser.Common.nuspec b/Nuget/MediaBrowser.Common.nuspec index f21155d94..cb27bc591 100644 --- a/Nuget/MediaBrowser.Common.nuspec +++ b/Nuget/MediaBrowser.Common.nuspec @@ -12,6 +12,8 @@ <description>Contains common model objects and interfaces used by all Media Browser solutions.</description> <copyright>Copyright © Media Browser 2013</copyright> <dependencies> + <group targetFramework=".NETFramework4.5"/> + <group targetFramework=".NETFramework3.5"/> <group targetFramework=".NETPortable0.0-net45+sl4+wp71+win8"> <dependency id="Microsoft.Bcl.Async" version="1.0.16" /> </group> |
