Unable to load DLL: "aws-cpp-sdk-core.dll", Status: 0xc0000135

0

I generated the AWS SDK projects for 32-bit using this command:

cmake .. -D CMAKE_BUILD_TYPE=Release -A Win32

Then I built the AWS SDK using Visual Studio 2019, running on 64-bit Windows 10.

Ultimately, the goal is to use the AWS SDK from an ancient C++ compiler being used to build legacy software applications. On its own, it'd never be able to build the AWS SDK, so I was going to write a "bridge" DLL (using Visual Studio 2019) to work between the old compiler and the AWS SDK DLLs.

When I tried to load my bridge DLL using LoadLibrary(), the DLL couldn't be loaded, and GetLastError() returned 126.

That was from the old compiler, but I also received the same result from a test project in Visual Studio 2019. I enabled loader snaps with gflags.exe on the VS sample program, and then I saw this:

30e0:7908 @ 325317281 - LdrpLoadDllInternal - ENTER: DLL name: C:\aws-sdk-cpp-master\build32\bin\Release\AWSBridge.dll
30e0:7908 @ 325317281 - LdrpDetectDetour - INFO: !!! Detour detected, disable parallel loading
30e0:7908 @ 325317281 - LdrpResolveDllName - ENTER: DLL name: C:\aws-sdk-cpp-master\build32\bin\Release\AWSBridge.dll
30e0:7908 @ 325317281 - LdrpResolveDllName - RETURN: Status: 0x00000000
30e0:7908 @ 325317296 - LdrpMinimalMapModule - ENTER: DLL name: C:\aws-sdk-cpp-master\build32\bin\Release\AWSBridge.dll
'SimpleConsole.exe' (Win32): Loaded 'C:\aws-sdk-cpp-master\build32\bin\Release\AWSBRIDGE.dll'. Symbols loaded.
30e0:7908 @ 325317312 - LdrpMinimalMapModule - RETURN: Status: 0x00000000
30e0:7908 @ 325317312 - LdrpFindKnownDll - ENTER: DLL name: aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpFindKnownDll - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpFindKnownDll - ENTER: DLL name: VCRUNTIME140.dll
30e0:7908 @ 325317312 - LdrpFindKnownDll - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpPreprocessDllName - INFO: DLL api-ms-win-crt-runtime-l1-1-0.dll was redirected to C:\windows\SYSTEM32\ucrtbase.dll by API set
30e0:7908 @ 325317312 - LdrpPreprocessDllName - INFO: DLL api-ms-win-crt-heap-l1-1-0.dll was redirected to C:\windows\SYSTEM32\ucrtbase.dll by API set
30e0:7908 @ 325317312 - LdrpSearchPath - ENTER: DLL name: aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpComputeLazyDllPath - INFO: DLL search path computed: C:\dev\projects\samples\Generic\SimpleConsole\..\..\..\target\Debug;C:\windows\SYSTEM32;C:\windows\system;C:\windows;.;C:\Program Files (x86)\Actian\PSQL\bin\;C:\Program Files\Actian\PSQL\bin\;C:\PROGRA~2\Borland\CBUILD~1\Bin;C:\PROGRA~2\Borland\CBUILD~1\Projects\Bpl;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\w
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\dev\projects\samples\Generic\SimpleConsole\..\..\..\target\Debug\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\windows\SYSTEM32\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\windows\system\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\windows\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: .\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files (x86)\Actian\PSQL\bin\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Actian\PSQL\bin\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\PROGRA~2\Borland\CBUILD~1\Bin\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\PROGRA~2\Borland\CBUILD~1\Projects\Bpl\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files (x86)\Common Files\Oracle\Java\javapath\aws-cpp-sdk-core.dll
30e0:7908 @ 325317312 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317312 - LdrpResolveDllName - ENTER: DLL name: C:\windows\system32\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\windows\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\Wbem\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\WindowsPowerShell\v1.0\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\OpenSSH\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Intel\WiFi\bin\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Common Files\Intel\WirelessCommon\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\Users\user\AppData\Local\Microsoft\WindowsApps\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\Users\user\AppData\Local\Programs\Fiddler\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\CMake\bin\aws-cpp-sdk-core.dll
30e0:7908 @ 325317328 - LdrpResolveDllName - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpSearchPath - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrpProcessWork - ERROR: Unable to load DLL: "aws-cpp-sdk-core.dll", Parent Module: "C:\aws-sdk-cpp-master\build32\bin\Release\AWSBridge.dll", Status: 0xc0000135
'SimpleConsole.exe' (Win32): Unloaded 'C:\aws-sdk-cpp-master\build32\bin\Release\AWSBRIDGE.dll'
30e0:7908 @ 325317328 - LdrpLoadDllInternal - RETURN: Status: 0xc0000135
30e0:7908 @ 325317328 - LdrLoadDll - RETURN: Status: 0xc0000135

Next, I tried skipping my bridge DLL and loading aws-cpp-sdk-core.dll instead. That resulted in similar errors, except now it couldn't find aws-c-event-stream.dll.

65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\dev\projects\samples\Generic\SimpleConsole\..\..\..\target\Debug\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\windows\SYSTEM32\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\windows\system\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\windows\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: .\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files (x86)\Actian\PSQL\bin\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Actian\PSQL\bin\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\PROGRA~2\Borland\CBUILD~1\Bin\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\PROGRA~2\Borland\CBUILD~1\Projects\Bpl\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files (x86)\Common Files\Oracle\Java\javapath\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726640 - LdrpResolveDllName - ENTER: DLL name: C:\windows\system32\aws-c-event-stream.dll
65a0:6aec @ 326726640 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\Wbem\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\WindowsPowerShell\v1.0\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\System32\OpenSSH\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Intel\WiFi\bin\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\Common Files\Intel\WirelessCommon\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\Users\user\AppData\Local\Microsoft\WindowsApps\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\Users\user\AppData\Local\Programs\Fiddler\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpResolveDllName - ENTER: DLL name: C:\Program Files\CMake\bin\aws-c-event-stream.dll
65a0:6aec @ 326726656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpSearchPath - RETURN: Status: 0xc0000135
65a0:6aec @ 326726656 - LdrpProcessWork - ERROR: Unable to load DLL: "aws-c-event-stream.dll", Parent Module: "C:\aws-sdk-cpp-master\build32\bin\Release\aws-cpp-sdk-core.dll", Status: 0xc0000135

When I tried loading aws-c-event-stream.dll, it gave the same errors again but complained about not finding aws-c-common.dll.

1c98:8c08 @ 310951656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
1c98:8c08 @ 310951656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\system\aws-c-common.dll
1c98:8c08 @ 310951656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
1c98:8c08 @ 310951656 - LdrpResolveDllName - ENTER: DLL name: C:\windows\aws-c-common.dll
1c98:8c08 @ 310951656 - LdrpResolveDllName - RETURN: Status: 0xc0000135
1c98:8c08 @ 310951656 - LdrpResolveDllName - ENTER: DLL name: .\aws-c-common.dll
1c98:8c08 @ 310951656 - LdrpResolveDllName - RETURN: Status: 0xc0000135

Finally, I tried loading aws-c-common.dll using LoadLibrary(), and that worked!

I found a question related to building AWS for 32-bit, which leads me to wonder if I'm not actually building it correctly for 32-bit Windows. is it possible to build aws-cpp-sdk in 32 bit?

Is the AWS SDK supported for 32-bit? If so, what step am I missing?

Thanks!

windows
amazon-web-services
visual-c++
cmake
x86
asked on Stack Overflow May 13, 2020 by David

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0