0

I'm trying to run the AWS SDK for CPP and looks like for some reason after the make stage it stuck on:

[ 88%] Built target aws-cpp-sdk-core
[ 88%] Building CXX object aws-cpp-sdk-s3/CMakeFiles/aws-cpp-sdk-s3.dir/ub_S3.cpp.o

My CMAKE version is 3.21.7 I cloned the library from here: https://github.com/aws/aws-sdk-cpp. Then I used this command:

cmake ../aws-sdk-cpp -DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=/usr/local/ -DCMAKE_INSTALL_PREFIX=/usr/local/ -DBUILD_ONLY="s3"

Then used "make" but looks like it got stuck. Any ideas how to solve it?

s_s
  • 709
  • 1
  • 7
  • 13

1 Answers1

1

It was probably out of memory. Running dmesg right after that would indicate that.

I had the same issue with a similar cmake incantation also specifying just S3, running on an Amazon Linux 2 instance. It was in fact exactly the same, 88% and on ub_S3.cpp. And repeatable.

My solution was to add swap space to the VM. There are examples at this stack overflow page. Specifically, I did:

  sudo dd if=/dev/zero of=/swapfile bs=1024 count=1048576
  sudo chmod 600 /swapfile
  sudo mkswap /swapfile
  sudo swapon /swapfile

And that 1 GB swap was enough for making to work.

UrbanCmd
  • 26
  • 1