diff --git a/dll.vcxproj b/dll.vcxproj index b6cfe110..c9e6d975 100644 --- a/dll.vcxproj +++ b/dll.vcxproj @@ -1,4 +1,4 @@ - + @@ -73,6 +73,7 @@ mdbx $(SolutionDir)$(Platform)\$(Configuration)\ $(SolutionDir)$(Platform)\$(Configuration)\$(ProjectName)\ + PreLinkEvent false @@ -80,18 +81,21 @@ mdbx $(SolutionDir)$(Platform)\$(Configuration)\ $(SolutionDir)$(Platform)\$(Configuration)\$(ProjectName)\ + PreLinkEvent true mdbx $(SolutionDir)$(Platform)\$(Configuration)\ $(SolutionDir)$(Platform)\$(Configuration)\$(ProjectName)\ + PreLinkEvent false mdbx $(SolutionDir)$(Platform)\$(Configuration)\ $(SolutionDir)$(Platform)\$(Configuration)\$(ProjectName)\ + PreLinkEvent @@ -107,7 +111,14 @@ MachineX86 true Windows + ntdll.lib;$(IntermediateOutputPath)mdbx_ntdll_extra.lib;kernel32.lib;advapi32.lib;%(AdditionalDependencies) + + Generate fake-library mdbx_ntdll_extra.lib for $(PlatformTarget) + $(IntermediateOutputPath)mdbx_ntdll_extra.lib + $(ProjectDir)src/ntdll.def + lib.exe /def:%(Inputs) /out:%(Outputs) /machine:$(PlatformTarget) + @@ -130,7 +141,14 @@ true true UseLinkTimeCodeGeneration + ntdll.lib;$(IntermediateOutputPath)mdbx_ntdll_extra.lib;kernel32.lib;advapi32.lib;%(AdditionalDependencies) + + Generate fake-library mdbx_ntdll_extra.lib for $(PlatformTarget) + $(IntermediateOutputPath)mdbx_ntdll_extra.lib + $(ProjectDir)src/ntdll.def + lib.exe /def:%(Inputs) /out:%(Outputs) /machine:$(PlatformTarget) + @@ -145,6 +163,15 @@ true true + + ntdll.lib;$(IntermediateOutputPath)mdbx_ntdll_extra.lib;kernel32.lib;advapi32.lib;%(AdditionalDependencies) + + + Generate fake-library mdbx_ntdll_extra.lib for $(PlatformTarget) + $(IntermediateOutputPath)mdbx_ntdll_extra.lib + $(ProjectDir)src/ntdll.def + lib.exe /def:%(Inputs) /out:%(Outputs) /machine:$(PlatformTarget) + @@ -161,7 +188,14 @@ UseLinkTimeCodeGeneration + ntdll.lib;$(IntermediateOutputPath)mdbx_ntdll_extra.lib;kernel32.lib;advapi32.lib;%(AdditionalDependencies) + + Generate fake-library mdbx_ntdll_extra.lib for $(PlatformTarget) + $(IntermediateOutputPath)mdbx_ntdll_extra.lib + $(ProjectDir)src/ntdll.def + lib.exe /def:%(Inputs) /out:%(Outputs) /machine:$(PlatformTarget) + diff --git a/mdbx.sln b/mdbx.sln index a32249d7..f1462ab8 100644 --- a/mdbx.sln +++ b/mdbx.sln @@ -1,4 +1,4 @@ - + Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 14 VisualStudioVersion = 14.0.25420.1 diff --git a/src/osal.c b/src/osal.c index 89fc83f2..ef4c03ce 100644 --- a/src/osal.c +++ b/src/osal.c @@ -53,6 +53,7 @@ static int ntstatus2errcode(NTSTATUS status) { * declare them here. Using these APIs also means we must link to * ntdll.dll, which is not linked by default in user code. */ #pragma comment(lib, "ntdll.lib") +#pragma comment(lib, "mdbx_ntdll_extra.lib") extern NTSTATUS NTAPI NtCreateSection( OUT PHANDLE SectionHandle, IN ACCESS_MASK DesiredAccess, diff --git a/src/tools/mdbx_chk.vcxproj b/src/tools/mdbx_chk.vcxproj index d4cc420d..e6c26862 100644 --- a/src/tools/mdbx_chk.vcxproj +++ b/src/tools/mdbx_chk.vcxproj @@ -1,4 +1,4 @@ - + diff --git a/src/tools/mdbx_copy.vcxproj b/src/tools/mdbx_copy.vcxproj index 6910060f..d47513c2 100644 --- a/src/tools/mdbx_copy.vcxproj +++ b/src/tools/mdbx_copy.vcxproj @@ -1,4 +1,4 @@ - + diff --git a/src/tools/mdbx_dump.vcxproj b/src/tools/mdbx_dump.vcxproj index b44eb193..6978a2c2 100644 --- a/src/tools/mdbx_dump.vcxproj +++ b/src/tools/mdbx_dump.vcxproj @@ -1,4 +1,4 @@ - + diff --git a/src/tools/mdbx_load.vcxproj b/src/tools/mdbx_load.vcxproj index 6af6cc45..05a100fc 100644 --- a/src/tools/mdbx_load.vcxproj +++ b/src/tools/mdbx_load.vcxproj @@ -1,4 +1,4 @@ - + diff --git a/src/tools/mdbx_stat.vcxproj b/src/tools/mdbx_stat.vcxproj index 1adcefde..4027491d 100644 --- a/src/tools/mdbx_stat.vcxproj +++ b/src/tools/mdbx_stat.vcxproj @@ -1,4 +1,4 @@ - + diff --git a/test/test.vcxproj b/test/test.vcxproj index a8c21d38..74cdf857 100644 --- a/test/test.vcxproj +++ b/test/test.vcxproj @@ -1,4 +1,4 @@ - +