AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Setting Up the SDK


To use the AWS SDK for C++, you need:

  • Visual Studio 2013 or later


    Visual Studio 2013 doesn't provide default move constructors and operators. Later versions of Visual Studio provide a standards-compliant compiler.

  • or GNU Compiler Collection (GCC) 4.9 or later

  • or Clang 3.3 or later

  • A minimum of 4 GB of RAM


    You need 4 GB of RAM to build some of the larger AWS clients. The SDK might fail to build on Amazon EC2 instance types t2.micro, t2.small, and other small instance types due to insufficient memory.

Additional Requirements for Linux Systems#

To compile on Linux, you must have the header files (-dev packages) for libcurl, libopenssl, libuuid, and zlib. Typically, you'll find the packages in your system's package manager.

To install these packages on Debian/Ubuntu-based systems

sudo apt-get install libcurl4-openssl-dev libssl-dev uuid-dev zlib1g-dev

To install these packages on Redhat/Fedora-based systems

sudo dnf install libcurl-devel openssl-devel libuuid-devel

Getting the SDK Using NuGet with Visual C++#

You can use NuGet to manage dependencies for AWS SDK for C++ projects that you develop with Microsoft Visual C++. To use this procedure, you must have NuGet installed on your system.

To use the SDK with NuGet

  1. Open your project in Visual Studio.
  2. In Solution Explorer, right-click your project name and choose Manage NuGet Packages.
  3. Select the packages to use by searching for a particular service or library name. For example, you could use a search term such as aws s3 native or, because AWS SDK for C++ libraries are named consistently, use AWSSDKCPP-service name to add a library for a particular service to your project.
  4. Choose Install to install the libraries and add them to your project.

When you build your project, the correct binaries are automatically included for each runtime/architecture configuration you use—you won't need to manage these dependencies yourself.

Building the SDK from Source#

If you don't use Visual Studio (or don't want to use NuGet), you can build the SDK from source to set it up on your development system. This method also enables you to customize your SDK build—see CMake Parameters for the available options.

To build the SDK from source

  1. Download or clone the SDK source from aws/aws-sdk-cpp on GitHub.

    • Direct download: aws/aws-sdk-cpp/archive/

    • Clone with Git

      git clone
      git clone
  2. Install cmake (v3.0+) and the relevant build tools for your platform. Ensure these are available in your PATH. If you're unable to install cmake, you can use make or msbuild.

  3. Create a directory in which to create your buildfiles, and generate the necessary buildfiles within it. This is the recommended approach, referred to as an out-of-source build.:

    mkdir sdk_build
    cd sdk_build
    cmake <path/to/sdk/source>

    Alternatively, create the build files directly in the SDK source directory.:

    cd <path/to/sdk/source>
    cmake .

    If you don't have cmake installed, you can use these alternative commands to set up your build directory:

    auto make
    Visual Studio
    msbuild ALL_BUILD.vcxproj
  4. Build and install the SDK by typing one of the following in the same location where you generated your build files:

    auto make
    sudo make install
    Visual Studio
    msbuild INSTALL.vcxproj


Building the entire SDK can take awhile. To build only a particular client such as Amazon S3, you can use the cmake BUILD_ONLY parameter. For example:

cmake -DBUILD_ONLY="s3"

See CMake Parameters for more ways to modify the build output.

Building for Android#

To build for Android, add -DTARGET_ARCH=ANDROID to your cmake command line. The AWS SDK for C++ includes a cmake toolchain file that should cover what's needed, assuming you've set the appropriate environment variables (ANDROID_NDK).

Android on Windows#

Building for Android on Windows requires additional setup. In particular, you have to run cmake from a Visual Studio (2013 or later) developer command prompt. You'll also need the commands git and patch in your path. If you have git installed on a Windows system, you'll most likely find patch in a sibling directory (.../Git/usr/bin/). Once you've verified these requirements, your cmake command line will change slightly to use nmake.:

cmake -G "NMake Makefiles" `-DTARGET_ARCH=ANDROID` <other options> ..

nmake builds targets in a serially. To make things go more quickly, we recommend installing JOM as an alternative to nmake, and then changing the cmake invocation as follows.:

cmake -G "NMake Makefiles JOM" `-DTARGET_ARCH=ANDROID` <other options> ..

Creating Release Builds#

To create a release build of the SDK:

auto make
cmake -DCMAKE_BUILD_TYPE=Release <path/to/sdk/source>
sudo make install
Visual Studio
cmake <path-to-root-of-this-source-code> -G "Visual Studio 12 Win64"
msbuild INSTALL.vcxproj /p:Configuration=Release

Running Integration Tests#

Several directories are appended with *integration-tests. After you build your project, you can run these executables to ensure everything works correctly.