Closed ThanasisPap closed 5 years ago
Hi @ThanasisPap, I noticed you posted another issue not too long after this one ( #1195 ), where you built your project on the same environment, is it safe to assume that you were able to solve this problem?
Hi @KaibaLopez , I am working on 32bit compiler on #1195. I'll correct the post accordingly.
Hi @ThanasisPap , I'm trying to reproduce this error but having some problems. In my experience dll access violation errors such as these are commonly due to trying to use a dll file created for a different build, like referencing a dll generated for debug for a release build or win32 for a x64, etc. Could you check that the dlls in the output folder(TestAWS_x64BUG/x64/Debug) are the correct ones?
@KaibaLopez ,
The issue solved after replacing the include folder with the Vpckg one. It seems that a code error caused the problem and not a linking mismatch.
Thanks!
I experienced this issue as well when I updated my dll and lib files, but forgot to update my include folders so they were still pointing to an older version. Updating the include folders did the trick!
I experienced this issue as well when I updated my dll and lib files, but forgot to update my include folders so they were still pointing to an older version. Updating the include folders did the trick!
@chris-gong I am having this trouble as well. I think I used the source to built it. So the include folders are from the source code. and I copy the dll to the executable folders and linked to the build lib folders. could you tell me how to fix this trouble? thank you
I personally didn't experience this issue when the dll and lib files, and include files came from the same source code version.
I really stuck here! Did you try the lastest version? I used visual studio gui to build the souce code. Could you help me here lead me out of this pain please? Thank you so much! @chris-gong
Going to be honest, I haven't done this in over a year so I don't remember much.
The concerned error is shown in VS2013 but is working fine in VS2017, can anyone tell how to work this in vs2013 as my entire work is in visual studio 2013 and can't upgrade to higher version
@GitZinger @chris-gong @ThanasisPap can anyone help me with this? "The concerned error is shown in VS2013 but is working fine in VS2017, can anyone tell how to work this in vs2013 as my entire work is in visual studio 2013 and can't upgrade to higher version"
@shivanshtech the issue seems to be solved when you also update the corresponding include folder accordingly after building the SDK. Also make sure that you have already defined:
USE_IMPORT_EXPORT;
USE_WINDOWS_DLL_SEMANTICS;
I have compiled the sdk in vs2017 win64 and want to use the dlls on visual studio 2013 but not able to do, showing above exception. I could not understand the meaning of " update the corresponding include folder accordingly after building the SDK" @ThanasisPap
@shivanshtech You can either build the SDK from source or use Vcpkg (see here). For both solutions you must not only copy the library files but also the include folder containing the corresponding headers.
These folders are placed in sources directory in the corresponding modules accordingly. For example the s3 headers are placed in:
aws-sdk-cpp/aws-cpp-sdk-s3/include/aws/s3/
You must copy these headers to your build directory.
PS: I have to say that I finally used the second approach (Vcpkg) to get a working solution. This doesn't mean that you also have to do it that way.
Followed the above mentioned step, getting these errors now. [12:50, 1/15/2021] Laughwithshivansh: Error 1 error C2039: 'SDKOptions' : is not a member of 'Aws' D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 25 1 SecretsManagerTestApp2013 Error 2 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 25 1 SecretsManagerTestApp2013 Error 3 error C2146: syntax error : missing ';' before identifier 'Options' D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 25 1 SecretsManagerTestApp2013 Error 4 error C2065: 'Options' : undeclared identifier D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 25 1 SecretsManagerTestApp2013 Error 5 error C2039: 'InitAPI' : is not a member of 'Aws' D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 27 1 SecretsManagerTestApp2013 Error 6 error C2065: 'Options' : undeclared identifier D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 27 1 SecretsManagerTestApp2013 Error 7 error C3861: 'InitAPI': identifier not found D:\Shivansh\SecretsManagerTestApp2013\SecretsManagerTestApp2013\SM1.cpp 27 1 SecretsManagerTestApp2013
@ThanasisPap at run time i'm getting system errors for example-
I downloaded all the dlls individually , also installed Redistributable again , getting error "The application was unable to start correctly") @ThanasisPap
Again back to where I started, showing above core.dll msvc build error. I followed both of your steps @ThanasisPap
@shivanshtech Please define your problem clearly. This thread is opened regarding the following error:
Exception thrown at 0x00007FFD842D5C4D (aws-cpp-sdk-core.dll) in TestAWS_x64BUG.exe: 0xC0000005: Access violation writing location 0x00000000DDDDDDDD.
The problem described corresponds to a certain setup (compiler, OS etc.).
Now your last comment refers to a build error which I don't understand where it belongs (in the SDK build process or in your code build?). Either case it is not related to this thread in my understanding.
In the case I am wrong, please define your problem as the first post in order to have a solid ground about your issue.
@ThanasisPap here are the things i did-
@shivanshtech
What compiler you are using in Visual Studio 2013? Also about step 2, did you copy the include folders as mentioned before?
After building the SDK for x64 bit architecture and implement a basic operational example, the program crashes with an Access violation writing location exception. The crash happens on the closing scope operator just before
command.
The corresponding error happens only on x64 builds both with Custom Build Sequence and Vcpkg using:
For x86 Builds (with the corresponding msvc compiler) the application runs successfully.
What platform/OS are you using?
Windows 10 x64
Which version of the SDK?
Version 2.0
What compiler are you using? what version?
Visual Studio 15 2017 Win64
What are your CMake arguments?
cmake -G "Visual Studio 15 Win64" -DMINIMIZE_SIZE=ON -DBUILD_ONLY="s3;rds;" -DCMAKE_BUILD_TYPE=Debug
Can you provide a TRACE level log? (sanitize any sensitive information)
The debugger stops at line 222 at xutility with the message:
I'm also posting a minimal code snippet to reproduce:
*Note that I have already define: