Directory.Build.props 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  2. <PropertyGroup>
  3. <SlnDir>$(MSBuildThisFileDirectory)</SlnDir>
  4. <SlnDir Condition="!HasTrailingSlash('$(SlnDir)')">$(SlnDir)\</SlnDir>
  5. <CsDir>$(SlnDir)MSBuild\</CsDir>
  6. <SdkDir>$(MSBuildExtensionsPath)</SdkDir>
  7. <SdkDir Condition="!HasTrailingSlash('$(SdkDir)')">$(SdkDir)\</SdkDir>
  8. </PropertyGroup>
  9. <PropertyGroup>
  10. <OSPlatformWindows Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows)))' == 'true'">true</OSPlatformWindows>
  11. <OSPlatformLinux Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Linux)))' == 'true'">true</OSPlatformLinux>
  12. <OSPlatformOSX Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::OSX)))' == 'true'">true</OSPlatformOSX>
  13. </PropertyGroup>
  14. <PropertyGroup Condition="'$(OSPlatformWindows)' == 'true'">
  15. <DefineConstants>$(DefineConstants);EN_PLATFORM_WINDOWS;EN_SOCK_API_WINSOCK</DefineConstants>
  16. </PropertyGroup>
  17. <PropertyGroup Condition="'$(OSPlatformLinux)' == 'true'">
  18. <DefineConstants>$(DefineConstants);EN_PLATFORM_LINUX;EN_SOCK_API_POSIX</DefineConstants>
  19. </PropertyGroup>
  20. <PropertyGroup Condition="'$(OSPlatformOSX)' == 'true'">
  21. <DefineConstants>$(DefineConstants);EN_PLATFORM_OSX;EN_SOCK_API_POSIX</DefineConstants>
  22. </PropertyGroup>
  23. <PropertyGroup>
  24. <PluginDir>$(SlnDir)PluginOutput</PluginDir>
  25. <PluginArchDir>x86_64\</PluginArchDir>
  26. <PluginBaseName>enet</PluginBaseName>
  27. <PluginPrefix Condition="'$(OSPlatformLinux)' == 'true'">lib</PluginPrefix>
  28. <PluginExt Condition="'$(PluginExt)' == ''">dll</PluginExt>
  29. <PluginExt Condition="'$(OSPlatformLinux)' == 'true'">so</PluginExt>
  30. <PluginExt Condition="'$(OSPlatformOSX)' == 'true'">dylib</PluginExt>
  31. </PropertyGroup>
  32. </Project>