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

x/mobile: the size of simple iOS framework is quite large (question/optimization) #15223

Closed
twoboxen opened this issue Apr 10, 2016 · 1 comment

Comments

Projects
None yet
4 participants
@twoboxen
Copy link

commented Apr 10, 2016

Hey guys!

gomobile is great, and we've done some cool things with it so far.

We build a single aar and framework from our code, but I have a question. Is it possible to send in some optimizations (perhaps to remove unused symbols)? The size (particularly of the framework), more than doubles our app size. The compiled size of the framework is about 32Mb. Being that this cannot be statically linked in to the ios app and is sent as a deployed framework, there is no last mile optimization linking to shrink the total app package down.

Is there a recommended way to reduce the size? Thanks!

@bradfitz bradfitz added this to the Unreleased milestone Apr 10, 2016

@bradfitz bradfitz changed the title [gomobile] The size of simple ios framework is quite large (question/optimization) x/mobile: the size of simple iOS framework is quite large (question/optimization) Apr 10, 2016

@twoboxen

This comment has been minimized.

Copy link
Author

commented Apr 11, 2016

So after further investigation, it's not really a problem. I can just link against the static artifact and not be forced to embed the framework. Ideally, it wouldn't have inaccessible symbols, but this is certainly workable as-is. Thanks!

When I link against the library, clang optimizes out the unused symbols, so it ends up adding about 8Mb to the app.

@twoboxen twoboxen closed this Apr 11, 2016

@golang golang locked and limited conversation to collaborators Apr 12, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.