Skip to content

Commit e9b0c4b

Browse files
Removed event container in lieu of simpler std::function callbacks. Added transfer manager interface with tests. Better support for more SDKS. Improvements to Cognito Creds providers to work better with non-mobile desktop platforms and web browser workflows/ lambda.
1 parent 31a09d2 commit e9b0c4b

File tree

850 files changed

+51814
-35996
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

850 files changed

+51814
-35996
lines changed

CMakeLists.txt

+56-13
Original file line numberDiff line numberDiff line change
@@ -48,22 +48,27 @@ else()
4848
message(FATAL_ERROR "Unknown target platform. How did this happen?")
4949
endif()
5050

51-
if("${CUSTOM_MEMORY_MANAGEMENT}" STREQUAL "1")
52-
add_definitions(-DAWS_CUSTOM_MEMORY_MANAGEMENT)
53-
message(STATUS "Custom memory management enabled; stl objects now using custom allocators")
54-
else()
55-
message(STATUS "Custom memory management disabled")
56-
endif()
57-
5851
# shared libraries as intermediate (non-leaf) targets are not supported in android due to std::string issues
5952
if("${STATIC_LINKING}" STREQUAL "1")
6053
SET(BUILD_SHARED_LIBS 0)
54+
SET(ARCHIVE_DIRECTORY "lib")
6155
message(STATUS "Dynamic linking disabled")
6256
else()
6357
SET(BUILD_SHARED_LIBS 1)
58+
SET(ARCHIVE_DIRECTORY "bin")
6459
message(STATUS "Dynamic linking enabled")
6560
endif()
6661

62+
# If building shared libraries, custom memory management enabled is the default, otherwise regular memory management is the default.
63+
# We make custom memory management the default on shared library builds because it is safer and much more difficult to accidentally
64+
# allocate in one DLLs heap while freeing in another (which will lead to runtime crashes)
65+
if(("${CUSTOM_MEMORY_MANAGEMENT}" STREQUAL "1") OR (BUILD_SHARED_LIBS AND NOT ("${CUSTOM_MEMORY_MANAGEMENT}" STREQUAL "0")))
66+
add_definitions(-DAWS_CUSTOM_MEMORY_MANAGEMENT)
67+
message(STATUS "Custom memory management enabled; stl objects now using custom allocators")
68+
else()
69+
message(STATUS "Custom memory management disabled")
70+
endif()
71+
6772
# on Windows, set CURL_DIR to a valid curl install directory in order to use the curl client rather than the windows-specific one
6873
set(USE_CURL_CLIENT 1)
6974
if(PLATFORM_WINDOWS)
@@ -84,12 +89,35 @@ endif()
8489

8590
project(AWSNativeSDKAll)
8691

92+
# install setup
93+
# This install section must come after the initial "project(..)" declaration since that's when the compiler settings are discovered; prior to that CMAKE_SIZEOF_VOID_P is empty
94+
# install syntax (after building): cmake -DCMAKE_INSTALL_CONFIG_NAME=<Release/Debug> -DCMAKE_INSTALL_PREFIX=<install_root> -P cmake_install.cmake
95+
# ToDo: consoles
96+
if(PLATFORM_WINDOWS)
97+
set(SDK_INSTALL_BINARY_PREFIX "windows")
98+
elseif(PLATFORM_LINUX)
99+
set(SDK_INSTALL_BINARY_PREFIX "linux")
100+
elseif(PLATFORM_ANDROID)
101+
set(SDK_INSTALL_BINARY_PREFIX "android")
102+
elseif(PLATFORM_MAC)
103+
set(SDK_INSTALL_BINARY_PREFIX "mac")
104+
endif()
105+
106+
# ToDo: Mac/ios/android/consoles
107+
if(PLATFORM_WINDOWS OR PLATFORM_LINUX)
108+
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
109+
set(SDK_INSTALL_BINARY_PREFIX "${SDK_INSTALL_BINARY_PREFIX}/intel64")
110+
else()
111+
set(SDK_INSTALL_BINARY_PREFIX "${SDK_INSTALL_BINARY_PREFIX}/ia32")
112+
endif()
113+
endif()
114+
115+
message(STATUS "Install binary prefix: ${SDK_INSTALL_BINARY_PREFIX}")
116+
87117
if(BUILD_SHARED_LIBS)
88118
SET(LIBTYPE SHARED)
89119
if(PLATFORM_WINDOWS)
90120
add_definitions("-DUSE_IMPORT_EXPORT")
91-
add_definitions("-DJSON_DLL_BUILD")
92-
add_definitions("-DTINYXML2_EXPORT")
93121
SET(SUFFIX dll)
94122
elseif(PLATFORM_LINUX OR PLATFORM_ANDROID)
95123
SET(SUFFIX so)
@@ -298,12 +326,18 @@ if(PLATFORM_ANDROID)
298326

299327
endif()
300328

329+
#release pdbs in windows
330+
if(PLATFORM_WINDOWS)
331+
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zi")
332+
set(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /DEBUG /OPT:REF /OPT:ICF")
333+
endif()
334+
301335
# default libraries to link in per-platform
302336
if(PLATFORM_WINDOWS)
303337
if(USE_CURL_CLIENT)
304338
set(PLATFORM_DEP_LIBS libcurl)
305339
else()
306-
set(PLATFORM_DEP_LIBS Wininet)
340+
set(PLATFORM_DEP_LIBS Wininet winhttp)
307341
endif()
308342
set(PLATFORM_DEP_LIBS ${PLATFORM_DEP_LIBS} Bcrypt Crypt32 Userenv )
309343
elseif(PLATFORM_LINUX OR PLATFORM_APPLE)
@@ -312,8 +346,9 @@ elseif(PLATFORM_ANDROID)
312346
set(PLATFORM_DEP_LIBS curl ssl crypto ${ZLIB_LIBRARY_DIR}/${ZLIB_NAME}.a log atomic)
313347
endif()
314348

315-
#Do Not increment version number for export builds
316-
set(GENERATE_VERSION_INFO 0)
349+
if(NOT BRAZIL_BUILD)
350+
set(GENERATE_VERSION_INFO 1)
351+
endif()
317352

318353
add_subdirectory(aws-cpp-sdk-core)
319354
add_subdirectory(testing-resources)
@@ -331,7 +366,7 @@ add_subdirectory(aws-cpp-sdk-opsworks)
331366
add_subdirectory(aws-cpp-sdk-cloudfront)
332367
add_subdirectory(aws-cpp-sdk-kms)
333368
add_subdirectory(aws-cpp-sdk-codedeploy)
334-
add_subdirectory(aws-cpp-sdk-redshift)
369+
#add_subdirectory(aws-cpp-sdk-redshift)
335370
add_subdirectory(aws-cpp-sdk-iam)
336371
add_subdirectory(aws-cpp-sdk-ecs)
337372
add_subdirectory(aws-cpp-sdk-datapipeline)
@@ -349,6 +384,9 @@ add_subdirectory(aws-cpp-sdk-sns)
349384
add_subdirectory(aws-cpp-sdk-autoscaling)
350385
add_subdirectory(aws-cpp-sdk-rds)
351386
add_subdirectory(aws-cpp-sdk-logging)
387+
add_subdirectory(aws-cpp-sdk-access-management)
388+
add_subdirectory(aws-cpp-sdk-transfer)
389+
add_subdirectory(aws-cpp-sdk-queues)
352390

353391
if(PLATFORM_ANDROID)
354392
add_subdirectory(android-unified-tests)
@@ -361,6 +399,11 @@ else()
361399
add_subdirectory(aws-cpp-sdk-s3-integration-tests)
362400
add_subdirectory(aws-cpp-sdk-identity-management-tests)
363401
add_subdirectory(aws-cpp-sdk-logging-tests)
402+
add_subdirectory(aws-cpp-sdk-transfer-tests)
403+
404+
if(PLATFORM_WINDOWS)
405+
add_subdirectory(aws-cpp-sdk-wininet-winhttp-test)
406+
endif()
364407
endif()
365408

366409
if(BUILD_EXAMPLES)

0 commit comments

Comments
 (0)