VisualC-WinRT/SDL2-WinRT.targets
changeset 9940 f2d5ed0d9686
child 10911 1863707d9df8
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/VisualC-WinRT/SDL2-WinRT.targets	Tue Dec 01 22:07:24 2015 -0500
     1.3 @@ -0,0 +1,39 @@
     1.4 +<?xml version="1.0" encoding="utf-8"?>
     1.5 +<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
     1.6 +
     1.7 +  <PropertyGroup>
     1.8 +    <LibSDL2-DeviceType Condition="'$(TargetPlatformIdentifier)' == 'Windows' and '$(TargetPlatformVersion)' == '8.0'">WinRT80</LibSDL2-DeviceType>
     1.9 +    <LibSDL2-DeviceType Condition="'$(TargetPlatformIdentifier)' == 'Windows' and '$(TargetPlatformVersion)' == '8.1'">WinRT81</LibSDL2-DeviceType>
    1.10 +    <LibSDL2-DeviceType Condition="'$(TargetPlatformIdentifier)' == 'Windows Phone' and '$(TargetPlatformVersion)' == '8.0'">WinPhone80</LibSDL2-DeviceType>
    1.11 +    <LibSDL2-DeviceType Condition="'$(TargetPlatformIdentifier)' == 'WindowsPhoneApp' and '$(TargetPlatformVersion)' == '8.1'">WinPhone81</LibSDL2-DeviceType>
    1.12 +    <LibSDL2-DeviceType Condition="'$(TargetPlatformIdentifier)' == 'UAP'">UWP</LibSDL2-DeviceType>
    1.13 +
    1.14 +  	<LibSDL2-BinPath>$(MSBuildThisFileDirectory)..\..\bin\$(LibSDL2-DeviceType)\$(Platform)</LibSDL2-BinPath>
    1.15 +  </PropertyGroup>
    1.16 +
    1.17 +  <Target Name="LibSDL2-DeviceType-Check" BeforeTargets="ResolveAssemblyReferences">
    1.18 +      <Error Condition="'$(LibSDL2-DeviceType)' == ''" Text="Unable to determine which version of Windows is being built-for" />
    1.19 +  </Target>
    1.20 +
    1.21 +  <ItemDefinitionGroup>
    1.22 +    <Link>
    1.23 +      <AdditionalLibraryDirectories>$(LibSDL2-BinPath);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
    1.24 +      <AdditionalDependencies>SDL2.lib;%(AdditionalDependencies)</AdditionalDependencies>
    1.25 +    </Link>
    1.26 +  </ItemDefinitionGroup>
    1.27 +
    1.28 +  <ItemDefinitionGroup>
    1.29 +    <ClCompile>
    1.30 +      <AdditionalIncludeDirectories>$(MSBuildThisFileDirectory)..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.31 +    </ClCompile>
    1.32 +  </ItemDefinitionGroup>
    1.33 +
    1.34 +  <ItemGroup Label="LibSDL2">
    1.35 +    <PackagingOutputs Include="$(LibSDL2-BinPath)\SDL2.dll">
    1.36 +        <OutputGroup>LibSDL2Binaries</OutputGroup>
    1.37 +        <ProjectName>$(ProjectName)</ProjectName>
    1.38 +        <TargetPath>%(Filename)%(Extension)</TargetPath>
    1.39 +    </PackagingOutputs>
    1.40 +  </ItemGroup>
    1.41 +
    1.42 +</Project>