Search code examples
c++windowsx86mfcaws-sdk

AWS sdk, trying to build X86 Windows. C++


I am trying to use the aws sdk in a mfc app. I am unable to compile the sdk for a x86 platform.

The command I am trying is...

cmake .. -DCMAKE_BUILD_TYPE=Release -DBUILD_ONLY="s3;dynamodb;cognito-identity;iot" -DCMAKE_GENERATOR_PLATFORM=x86
cmake --build . --config=Release
cmake --install . --config=Release

When I try I get...

Build FAILED.

"C:\Users\redst\OneDrive\Documents\GitHub\xxxx\libs\aws-sdk-cpp\cmake_build\CMakeFiles\3.29.1\VCTargetsPath.vcxproj" (default target) (1) ->
(PrepareForBuild target) ->
  C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppBuild.targets(438,5): error MSB8013: This project doesn't contain the Configuration and Platform combination of Debug|Win32. [C:\Users\redst\OneDrive\Documents\GitHub\xxxx\libs\aws-sdk-cpp\cmake_build\CMakeFiles\3.29.1\VCTargetsPath.vcxproj]

    0 Warning(s)
    1 Error(s)

Time Elapsed 00:00:00.12

Exit code: 1


Solution

  • CMAKE_GENERATOR_PLATFORM should be Win32 not x86