Description
Confirm by changing [ ] to [x] below to ensure that it's a bug:
- I've gone though Developer Guide and API reference
- I've searched for previous similar issues and didn't find any solution
Describe the bug
A clear and concise description of what the bug is.
The CMAKE_DEBUG_POSTFIX debug property was not taken into account in AWSSDKConfig.cmake when the find_library is used.
The solution to fix this problem is below:
diff --git a/cmake/AWSSDKConfig.cmake b/cmake/AWSSDKConfig.cmake
index 5147335ddc..9ff3a413de 100644
--- a/cmake/AWSSDKConfig.cmake
+++ b/cmake/AWSSDKConfig.cmake
@@ -110,7 +110,7 @@ if (NOT AWSSDK_ROOT_DIR)
endif()
-find_library(AWSSDK_CORE_LIB_FILE aws-cpp-sdk-core
+find_library(AWSSDK_CORE_LIB_FILE aws-cpp-sdk-core${CMAKE_DEBUG_POSTFIX}
"${AWSSDK_ROOT_DIR}/${AWSSDK_INSTALL_LIBDIR}/${AWSSDK_PLATFORM_PREFIX}"
"${AWSSDK_ROOT_DIR}/${AWSSDK_INSTALL_LIBDIR}/${AWSSDK_PLATFORM_PREFIX}/Debug"
"${AWSSDK_ROOT_DIR}/${AWSSDK_INSTALL_LIBDIR}/${AWSSDK_PLATFORM_PREFIX}/DebugOpt"
SDK version number
tag: 1.9.165
Platform/OS/Hardware/Device
What are you running the sdk on?
It was compiled on Ubuntu 18.04 host for aarch64 target. it was used cross compilation gcc compiler.
To Reproduce (observed behavior)
Steps to reproduce the behavior (please share code)
Expected behavior
A clear and concise description of what you expected to happen.
Logs/output
If applicable, add logs or error output.
CMake Warning at /opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib/cmake/AWSSDK/AWSSDKConfig.cmake:112 (message):
AWSSDK_CORE_LIB_FILE-NOTFOUND/opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//Debug/opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//DebugOpt/opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//Release/opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//RelWithDebInfo/opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib//MinSizeRel
Call Stack (most recent call first):
CMakeLists.txt:6 (find_package)
CMake Error at /opt/work/devbb/bbsdk/install_dir/lx2-aarch64-linux/opt/bluebox/lib/cmake/AWSSDK/AWSSDKConfig.cmake:131 (message):
AWS SDK for C++ headers found, but we were unable to locate the binaries.
Have you deleted or moved it?
Please make sure header files and binaries are located in INSTALL_ROOT_DIR/INCLUDE_DIR/ and INSTALL_ROOT_DIR/LIB_DIR/[PLATFORM_PREFIX]/[Debug|Config|OtherConfigs]
Call Stack (most recent call first):
CMakeLists.txt:6 (find_package)
-- Configuring incomplete, errors occurred!
To enable logging, set the following system properties:
REMEMBER TO SANITIZE YOUR PERSONAL INFO
options.loggingOptions.logLevel = Aws::Utils::Logging::LogLevel::Trace;
Aws::InitAPI(options)
Additional context
Add any other context about the problem here.