You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

76 lines
3.6 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  3. <PropertyGroup>
  4. <Py_IntDir Condition="'$(Py_IntDir)' == ''">$(opensslDir)tmp\</Py_IntDir>
  5. </PropertyGroup>
  6. <Import Project="pyproject.props" />
  7. <PropertyGroup Label="Configuration">
  8. <ConfigurationType>StaticLibrary</ConfigurationType>
  9. </PropertyGroup>
  10. <ItemGroup>
  11. <PreprocessorDefinitions Include="DSO_WIN32" />
  12. <PreprocessorDefinitions Include="WIN32_LEAN_AND_MEAN" />
  13. <PreprocessorDefinitions Include="L_ENDIAN" />
  14. <PreprocessorDefinitions Include="_CRT_SECURE_NO_WARNINGS" />
  15. <PreprocessorDefinitions Include="_CRT_SECURE_NO_DEPRECATE" />
  16. <PreprocessorDefinitions Include="OPENSSL_THREADS" />
  17. <PreprocessorDefinitions Include="OPENSSL_SYSNAME_WIN32" />
  18. <PreprocessorDefinitions Include="OPENSSL_IA32_SSE2" />
  19. <PreprocessorDefinitions Include="OPENSSL_CPUID_OBJ" />
  20. <PreprocessorDefinitions Include="SHA1_ASM" />
  21. <PreprocessorDefinitions Include="SHA256_ASM" />
  22. <PreprocessorDefinitions Include="SHA512_ASM" />
  23. <PreprocessorDefinitions Include="MD5_ASM" />
  24. <PreprocessorDefinitions Include="AES_ASM" />
  25. <PreprocessorDefinitions Include="VPAES_ASM" />
  26. <PreprocessorDefinitions Include="WHIRLPOOL_ASM" />
  27. <PreprocessorDefinitions Include="GHASH_ASM" />
  28. <PreprocessorDefinitions Include="OPENSSL_NO_IDEA" />
  29. <PreprocessorDefinitions Include="OPENSSL_NO_RC5" />
  30. <PreprocessorDefinitions Include="OPENSSL_NO_MD2" />
  31. <PreprocessorDefinitions Include="OPENSSL_NO_MDC2" />
  32. <PreprocessorDefinitions Include="OPENSSL_NO_KRB5" />
  33. <PreprocessorDefinitions Include="OPENSSL_NO_JPAKE" />
  34. <PreprocessorDefinitions Include="OPENSSL_NO_RDRAND" />
  35. <PreprocessorDefinitions Include="OPENSSL_NO_RSAX" />
  36. <PreprocessorDefinitions Include="OPENSSL_NO_DYNAMIC_ENGINE" />
  37. </ItemGroup>
  38. <ItemGroup Condition="'$(Platform)'=='Win32'">
  39. <PreprocessorDefinitions Include="OPENSSL_BN_ASM_GF2m" />
  40. <PreprocessorDefinitions Include="OPENSSL_BN_ASM_PART_WORDS" />
  41. <PreprocessorDefinitions Include="OPENSSL_BN_ASM_MONT" />
  42. <PreprocessorDefinitions Include="RMD160_ASM" />
  43. </ItemGroup>
  44. <PropertyGroup>
  45. <_PreprocessorDefinitionList>@(PreprocessorDefinitions)</_PreprocessorDefinitionList>
  46. </PropertyGroup>
  47. <ItemDefinitionGroup>
  48. <ClCompile>
  49. <!-- Suppress 64-bit truncation warnings - they aren't ours to worry about -->
  50. <DisableSpecificWarnings>4244;4267</DisableSpecificWarnings>
  51. <AdditionalIncludeDirectories>$(opensslDir);$(opensslDir)include;$(opensslDir)crypto;$(opensslDir)crypto\asn1;$(opensslDir)crypto\evp;$(opensslDir)crypto\modes</AdditionalIncludeDirectories>
  52. <PreprocessorDefinitions>$(_PreprocessorDefinitionList);%(PreprocessorDefinitions)</PreprocessorDefinitions>
  53. </ClCompile>
  54. </ItemDefinitionGroup>
  55. <Target Name="FindNasm">
  56. <PropertyGroup>
  57. <nasm Condition="$(Platform) == 'Win32'">nasm.exe -f win32</nasm>
  58. <nasm Condition="$(Platform) == 'x64'">nasm.exe -f win64 -DNEAR -Ox -g</nasm>
  59. </PropertyGroup>
  60. </Target>
  61. <Target Name="BuildNasmFiles" BeforeTargets="PreBuildEvent" DependsOnTargets="PrepareForBuild;FindNasm" Inputs="@(NasmCompile)" Outputs="@(NasmCompile->'$(IntDir)%(Filename).obj')">
  62. <Exec Command='setlocal
  63. set PATH=$(nasmDir);%PATH%
  64. $(nasm) -o "$(IntDir)%(NasmCompile.Filename).obj" "%(NasmCompile.FullPath)"' />
  65. <ItemGroup>
  66. <Link Include="$(IntDir)%(NasmCompile.Filename).obj" />
  67. <Lib Include="$(IntDir)%(NasmCompile.Filename).obj" />
  68. </ItemGroup>
  69. </Target>
  70. </Project>