-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong package configuration file for aws-c-common #1695
Comments
Hi @marco-ceriani , |
I'm building both aws-sdk-cpp and aws-encryption-sdk using a CMakeLIsts.txt with two external projects
I'm also doing other things to prepare a package with all the libraries, but it's irrelevant for this issue. The complete build script for the aws-encryption-sdk is in their project. The piece that breaks down is indeed a
The build of aws-sdk-cpp completes correctly, and it produces the file <install_prefix>/lib/aws-c-common/cmake/aws-c-common-config.cmake, with this content
While building the other library, the variable BUILD_SHARED_LIBS is again ON, and I assume that this triggers the search on the path /shared/aws-c-common-targets.cmake that does not exist, since the aws-c-common library is now compiled statically. I have two questions
|
Hi @KaibaLopez, any updates on this? I'm able to use a workaround on the aws-encryption-sdk-c side [1], but it's preferable if the aws-sdk-cpp fixes the root cause. |
We have been working on some updates to the build/configurations of this sdk. You can track the progress here |
Looks like this was fixed in aws-c-common/pull/924 now we fallback and try to load whatever library is present
with this fallback behavior it will now find the the any present lib, if you can replicate give a shout, but I do believe this to be fixed. |
Hello Sam. I didn't have any trouble building. I had no time to investigate if the relevant change was the pull 924 in aws-sdk-cpp, or some other change in the project aws-encryption-sdk-c. However, I'm still building the encryption SDK as dynamic library, like before, and can confirm that aws-c-common built as a static library is correctly consumed as dependency. I'm in favour of closing the ticket, since my problem is solved (and the pull is as fine as it can be). If you prefer a more in-depth analysis, I need some time, it's a busy period for at least a couple of weeks. |
nope no need to do any investigation on your side, we can close it thanks for chiming in and sorry it took a while! if you start seeing anything like it again, give a shout. |
This issue is now closed. Comments on closed issues are hard for our team to see. |
Confirm by changing [ ] to [x] below to ensure that it's a bug:
Describe the bug
In one of the products I work on I'm using the aws-encryption-sdk-c library to encrypt data, which is another library provided by AWS, which depends on the aws-sdk-cpp. Hence, I wrote a CMake file to build both libraries as shared libraries.
However, since a recent release, the aws-c-common is compiled as a static library, ignoring the variable BUILD_SHARED_LIB. This is fine for the compilation of aws-sdk-cpp. But when I try to use it inside aws-encryption-sdk-c, that build fails, with this message
I've looked at that file, and the issue is that it uses the variable BUILD_SHARED_LIBS to choose wether to include static/aws-c-common-targets.cmake or shared/aws-c-common-targets.cmake. But now aws-c-common is always built as a static library. Hence, the folder
shared
does not exist. Since the compilation of the common c libraries is now independent from the variable BUILD_SHARED_LIBS, then also the config.cmake should be modified accordingly.SDK version number
1.9.39
Platform/OS/Hardware/Device
CentOS 7.9
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.
The text was updated successfully, but these errors were encountered: