aboutsummaryrefslogtreecommitdiff
path: root/cc/third_party
diff options
context:
space:
mode:
authorkste <kste@google.com>2020-06-03 00:26:02 -0700
committerCopybara-Service <copybara-worker@google.com>2020-06-03 00:26:36 -0700
commita9c1731d78305a5d0f6975abb5cc9b05363424ce (patch)
treeed3337e7b8d711fcb29958445f4d01316113abe0 /cc/third_party
parentda2b4f98086224f0357d5b15bbfab483090abc0b (diff)
downloadtink-a9c1731d78305a5d0f6975abb5cc9b05363424ce.tar.gz
Update version of AWS C++ SDK.
Use latest version of AWS C++ SDK and add the additional dependencies required in all newer versions of the SDK. PiperOrigin-RevId: 314481687
Diffstat (limited to 'cc/third_party')
-rw-r--r--cc/third_party/aws_c_common.BUILD.bazel29
-rw-r--r--cc/third_party/aws_c_event_stream.BUILD.bazel19
-rw-r--r--cc/third_party/aws_checksums.BUILD.bazel22
-rw-r--r--cc/third_party/aws_sdk_cpp.BUILD.bazel13
4 files changed, 80 insertions, 3 deletions
diff --git a/cc/third_party/aws_c_common.BUILD.bazel b/cc/third_party/aws_c_common.BUILD.bazel
new file mode 100644
index 000000000..de42eef74
--- /dev/null
+++ b/cc/third_party/aws_c_common.BUILD.bazel
@@ -0,0 +1,29 @@
+licenses(["notice"]) # Apache 2.0
+
+load("@tink_base//tools:common.bzl", "template_rule")
+
+cc_library(
+ name = "aws_c_common",
+ srcs = glob(["source/*.c"]) +
+ glob(["source/posix/*.c"]),
+ hdrs = [
+ "include/aws/common/config.h"
+ ] + glob([
+ "include/**/*.h",
+ "include/aws/common/**/*.inl"
+ ]),
+ includes = ["include/"],
+ visibility = ["//visibility:public"],
+)
+
+template_rule(
+ name = "config.h",
+ src = "include/aws/common/config.h.in",
+ out = "include/aws/common/config.h",
+ substitutions = {
+ "cmakedefine AWS_HAVE_GCC_OVERFLOW_MATH_EXTENSIONS": "undef AWS_HAVE_GCC_OVERFLOW_MATH_EXTENSIONS",
+ "cmakedefine AWS_HAVE_GCC_INLINE_ASM": "define AWS_HAVE_GCC_INLINE_ASM",
+ "cmakedefine AWS_HAVE_MSVC_MULX": "undef AWS_HAVE_MSVC_MULX",
+ "cmakedefine AWS_HAVE_EXECINFO": "define AWS_HAVE_EXECINFO",
+ },
+)
diff --git a/cc/third_party/aws_c_event_stream.BUILD.bazel b/cc/third_party/aws_c_event_stream.BUILD.bazel
new file mode 100644
index 000000000..8f37e5636
--- /dev/null
+++ b/cc/third_party/aws_c_event_stream.BUILD.bazel
@@ -0,0 +1,19 @@
+licenses(["notice"]) # Apache 2.0
+
+cc_library(
+ name = "aws_c_event_stream",
+ srcs = glob([
+ "source/*.c",
+ ]),
+ hdrs = glob([
+ "include/**/*.h"
+ ]),
+ includes = [
+ "include/",
+ ],
+ deps = [
+ "@aws_c_common",
+ "@aws_checksums"
+ ],
+ visibility = ["//visibility:public"],
+)
diff --git a/cc/third_party/aws_checksums.BUILD.bazel b/cc/third_party/aws_checksums.BUILD.bazel
new file mode 100644
index 000000000..25fc63653
--- /dev/null
+++ b/cc/third_party/aws_checksums.BUILD.bazel
@@ -0,0 +1,22 @@
+licenses(["notice"]) # Apache 2.0
+
+cc_library(
+ name = "aws_checksums",
+ srcs = glob([
+ "source/intel/*.c",
+ "source/*.c",
+ ]),
+ hdrs = glob([
+ "include/**/*.h"
+ ]),
+ includes = [
+ "include/",
+ ],
+ copts = [
+ "-O2" # Note there is some issue with the assembly implementation and GCC, therefore this should always be compiled with -O (https://github.com/awslabs/aws-checksums/issues/8)
+ ],
+ deps = [
+ "@aws_c_common",
+ ],
+ visibility = ["//visibility:public"],
+)
diff --git a/cc/third_party/aws_sdk_cpp.BUILD.bazel b/cc/third_party/aws_sdk_cpp.BUILD.bazel
index 6428b8600..4fb7c1e9d 100644
--- a/cc/third_party/aws_sdk_cpp.BUILD.bazel
+++ b/cc/third_party/aws_sdk_cpp.BUILD.bazel
@@ -29,6 +29,9 @@ cc_library(
"aws-cpp-sdk-core/source/utils/crypto/factory/**/*.cpp",
"aws-cpp-sdk-kms/include/**/*.h",
"aws-cpp-sdk-kms/source/**/*.cpp",
+ "aws-cpp-sdk-core/source/monitoring/*.cpp",
+ "aws-cpp-sdk-core/source/net/linux-shared/*.cpp",
+ "aws-cpp-sdk-core/source/utils/crypto/openssl/*.cpp",
]),
hdrs = [
"aws-cpp-sdk-core/include/aws/core/SDKConfig.h",
@@ -40,16 +43,20 @@ cc_library(
# These must be in sync with version of aws_cpp_sdk in WORKSPACE.
defines = [
"AWS_SDK_VERSION_MAJOR=1",
- "AWS_SDK_VERSION_MINOR=4",
- "AWS_SDK_VERSION_PATCH=80",
+ "AWS_SDK_VERSION_MINOR=7",
+ "AWS_SDK_VERSION_PATCH=345",
"ENABLE_CURL_CLIENT",
- "ENABLE_NO_ENCRYPTION",
+ "ENABLE_OPENSSL_ENCRYPTION", # This is needed for UUID generation
+ "OPENSSL_IS_BORINGSSL",
"PLATFORM_LINUX",
],
visibility = ["//visibility:public"],
strip_include_prefix = "aws-cpp-sdk-core/include",
deps = [
+ "@aws_c_common",
+ "@aws_c_event_stream",
"@curl",
+ "@boringssl//:crypto",
],
)