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