Skip to content

Migrate to using shared libraries.#2582

Open
3405691582 wants to merge 1 commit into
google:mainfrom
3405691582:509968291_3
Open

Migrate to using shared libraries.#2582
3405691582 wants to merge 1 commit into
google:mainfrom
3405691582:509968291_3

Conversation

@3405691582
Copy link
Copy Markdown
Collaborator

@3405691582 3405691582 commented May 19, 2026

In #2573 we set up some new targets to build shared libraries. This commit migrates all binary targets with dependencies on //cuttlefish/result, //libbase, //cuttlefish/common/libs/fs:fs, and //cuttlefish/common/utils:files to use the shared library targets instead.

This results in the generated deb decreasing from 110M to 103M and the reported Installed-Size decreasing from 450179K to 414364K, a reduction of 35M. Actual on-disk build size has reduced from 2.4G to 2.2G. More aggressive reductions could likely be achieved by migrating other common libraries to shared libraries.

While we are here: we also ensure //cuttlefish/result has a dependency on fmt, to ensure that inline usages (like in casimir_control_server) correctly depend on fmt.

@3405691582 3405691582 requested a review from Databean May 19, 2026 13:09
@3405691582 3405691582 force-pushed the 509968291_3 branch 2 times, most recently from 73a55e5 to aede690 Compare May 19, 2026 15:23
In google#2573 we set up some new targets to build shared libraries. This
commit migrates all binary targets with dependencies on
//cuttlefish/result, //libbase, //cuttlefish/common/libs/fs:fs, and
//cuttlefish/common/utils:files to use the shared library targets
instead.

This results in the generated deb decreasing from 110M to 103M and
the reported Installed-Size decreasing from 450179K to 414364K,
a reduction of 35M. Actual on-disk build size has reduced from
2.4G to 2.2G. More aggressive reductions could likely be achieved
by migrating other common libraries to shared libraries.

While we are here: we also ensure //cuttlefish/result has a dependency
on fmt, to ensure that inline usages (like in casimir_control_server)
correctly depend on fmt.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant