Skip to content
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

Install statically via SPM #5430

Closed
iwwwh opened this issue Aug 28, 2024 · 5 comments
Closed

Install statically via SPM #5430

iwwwh opened this issue Aug 28, 2024 · 5 comments
Labels
core Issues related to AWSCore question General question

Comments

@iwwwh
Copy link

iwwwh commented Aug 28, 2024

Describe the bug
Hi,

As I can see, there is no way to install AWS SDK as a static library using SPM. It always being installed as a dynamic framework (.framework). It negatively affects application launch time, and in general not an optimal/recommended approach, we have like 30 different dependencies, and the issue is only with AWS SDK.

Could you please tell if there is any workarounds? What can we do?

Thanks.

To Reproduce
Steps to reproduce the behavior:

  1. Install AWS SDK using SPM.
  2. Add any components to a target, S3 for example
  3. Build the project and see that S3 being bundled as .framework

Observed Behavior
AWS SDK being installed as a dynamic framework.

Expected Behavior
AWS SDK being installed as a static library.

Areas of the SDK you are using (AWSMobileClient, Cognito, Pinpoint, IoT, etc)?
AWS SDK, specifically S3

Environment(please complete the following information):

  • SDK Version: latest
  • Dependency Manager: SPM
  • Swift Version : 5.x
  • Xcode Version: 15.4
@github-actions github-actions bot added pending-triage Issue is pending triage pending-maintainer-response Issue is pending response from an Amplify team member labels Aug 28, 2024
@iwwwh
Copy link
Author

iwwwh commented Aug 29, 2024

The only option I can think of to integrate AWS SDK statically is to manually drag & drop SDK source code files to a project, but I can’t find any information on that. I’ll appreciate if someone could clarify on how to do that properly.

Our goal is to integrate S3 only. Is it enough to just drag & drop AWSCore and AWSS3 folders to our project? Or does it require any additional configuration? Can it be normally used in Swift project in that way?

Thanks.

@harsh62
Copy link
Member

harsh62 commented Aug 29, 2024

This is the only way we were able to come SPM. (https://github.com/aws-amplify/aws-sdk-ios-spm/)

Our goal is to integrate S3 only. Is it enough to just drag & drop AWSCore and AWSS3 folders to our project?

It might be more than that. We haven't recommended this approach to anyone before.


You could try the new Swift SDK (https://github.com/awslabs/aws-sdk-swift/) that is also used by Amplify.

@github-actions github-actions bot removed the pending-maintainer-response Issue is pending response from an Amplify team member label Aug 29, 2024
@harsh62 harsh62 added core Issues related to AWSCore question General question and removed pending-triage Issue is pending triage labels Aug 29, 2024
@iwwwh
Copy link
Author

iwwwh commented Aug 29, 2024

Hi @harsh62

thanks for your response.

As I see, Swift SDK is in developer preview and is iOS 13+ only. I guess it can be a reasonable option but a little later for our case.

Are you sure that it can not be integrated by just dragging source code files and configuring bridging header properly? We are interested in S3 only, so most probably it should be 2 folders only (Core and S3).

Or perhaps any other options how to integrate the SDK statically?

@github-actions github-actions bot added the pending-maintainer-response Issue is pending response from an Amplify team member label Aug 29, 2024
@harsh62
Copy link
Member

harsh62 commented Aug 29, 2024

Are you sure that it can not be integrated by just dragging source code files and configuring bridging header properly?

I haven't tried this personally, so don't know for sure. This is something you can definitely try and update the thread with your findings.

@harsh62 harsh62 removed the pending-maintainer-response Issue is pending response from an Amplify team member label Aug 29, 2024
@iwwwh iwwwh closed this as completed Sep 5, 2024
Copy link

github-actions bot commented Sep 5, 2024

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Issues related to AWSCore question General question
Projects
None yet
Development

No branches or pull requests

2 participants