Watch
2
0
Fork
You've already forked raylib-cs
0
raylib-cs/Raylib-cs/Raylib-cs.csproj
2023-08-14 00:41:35 +07:00

108 lines
4.4 KiB
XML

<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<EnableDefaultItems>false</EnableDefaultItems>
<AssemblyName>Raylib-cs</AssemblyName>
<RootNamespace>Raylib_cs</RootNamespace>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<NoWarn>$(NoWarn);1591</NoWarn>
<LangVersion>10.0</LangVersion>
</PropertyGroup>
<PropertyGroup>
<TargetRaylibTag>4.5.0</TargetRaylibTag>
<Version>4.5.0.4</Version>
<PackageVersion>4.5.0.4</PackageVersion>
<Authors>Chris Dill, Raysan5</Authors>
<PackProject>true</PackProject>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<PackageLicenseExpression>Zlib</PackageLicenseExpression>
<Title>Raylib-cs</Title>
<Description>C# bindings for raylib - A simple and easy-to-use library to learn videogames programming</Description>
<PackageIcon>raylib-cs_64x64.png</PackageIcon>
<PackageTags>raylib;bindings;gamedev</PackageTags>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/ChrisDill/Raylib-cs/</RepositoryUrl>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageProjectUrl>https://www.raylib.com/</PackageProjectUrl>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
</PropertyGroup>
<ItemGroup>
<None Include="logo/raylib-cs_64x64.png" Pack="true" PackagePath="" />
<None Include="../README.md" Pack="true" PackagePath="" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="System.Numerics.Vectors" Version="4.5.0" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />
</ItemGroup>
<ItemGroup Condition="$(Configuration) == 'Release'">
<Content Include="runtimes/**" Link="runtimes/%(RecursiveDir)/%(Filename)%(Extension)">
<PackagePath>runtimes/</PackagePath>
<Pack>true</Pack>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
</ItemGroup>
<ItemGroup>
<Compile Include="interop\*.cs" />
<Compile Include="types\*.cs" />
<Compile Include="types\native\CBool.cs" />
<Compile Include="types\native\AnsiBuffer.cs" />
<Compile Include="types\native\UTF8Buffer.cs" />
<Compile Include="types\native\FilePathList.cs" />
</ItemGroup>
<PropertyGroup Condition="$([MSBuild]::IsOSPlatform('Linux'))">
<NativeExt>so</NativeExt>
<NativePre>lib</NativePre>
</PropertyGroup>
<PropertyGroup Condition="$([MSBuild]::IsOSPlatform('OSX'))">
<NativeExt>dylib</NativeExt>
<NativePre>lib</NativePre>
</PropertyGroup>
<PropertyGroup Condition="$([MSBuild]::IsOSPlatform('Windows'))">
<NativeExt>dll</NativeExt>
<NativePre>$(Configuration)/</NativePre>
</PropertyGroup>
<ItemGroup>
<Content
Include="$(IntermediateOutputPath)native/raylib/$(NativePre)raylib.$(NativeExt)"
Link="%(Filename)%(Extension)"
CopyToOutputDirectory="PreserveNewest"
Condition="Exists('$(IntermediateOutputPath)native/raylib/$(NativePre)raylib.$(NativeExt)')" />
<CMakeArgs Include="-B $(IntermediateOutputPath)native" />
<CMakeArgs Include="-S $(IntermediateOutputPath)raylib-$(TargetRaylibTag)" />
<CMakeArgs Include="-D CMAKE_BUILD_TYPE=$(Configuration)" />
<CMakeArgs Include="-D BUILD_SHARED_LIBS=ON" />
<CMakeArgs Include="-D BUILD_EXAMPLES=OFF" />
</ItemGroup>
<Target Name="ConfigureNative" BeforeTargets="BuildNative" Condition="$(SkipLocalBuild) != true">
<DownloadFile
SourceUrl="https://github.com/raysan5/raylib/archive/refs/tags/$(TargetRaylibTag).zip"
DestinationFolder="$(IntermediateOutputPath)"
DestinationFileName="raylib.zip"
Condition="!Exists('$(IntermediateOutputPath)raylib.zip')" />
<Unzip
SourceFiles="$(IntermediateOutputPath)raylib.zip"
DestinationFolder="$(IntermediateOutputPath)"
OverwriteReadOnlyFiles="true"
Condition="!Exists('$(IntermediateOutputPath)raylib-$(TargetRaylibTag)')" />
<Exec Command="cmake @(CMakeArgs, ' ') $(CMakeExtraArgs)"
Condition="!Exists('$(IntermediateOutputPath)native/CMakeCache.txt')" />
</Target>
<Target Name="BuildNative" BeforeTargets="BeforeBuild" Condition="$(SkipLocalBuild) != true">
<Exec Command="cmake --build $(IntermediateOutputPath)native --config $(Configuration)" />
</Target>
</Project>