Skip to content

Optimize dependencies of samba #346

@dongsupark

Description

@dongsupark

Current situation
Samba is well-known for its full-blown dependencies on a huge number of libraries. Whenever it bumps into a release, like 4.12, it pulls in another libs.
Recently we updated samba to 4.12.9, and apparently the latest Alpha release 2783.0.0 has ~50 MB of less free space compared to the previous version.

To improve that, we need to do some deep dive into the samba ebuild file.
Unfortunately the ebuild does not make use of all configure options available in upstream Samba. It is the case for both Flatcar and Gentoo.

A rough list of what to do, as of Samba 4.12.x.
Gentoo-changes:

  • make USE flag spotlight to pass --disable-spotlight.
    • The spotlight is not needed by Linux, not sure why configure tries to auto-detect it and pulls in libs like icu.
    • we can probably liburing as well.
  • make USE flag doc to exclude deps on app-text/docbook-xsl-stylesheets and dev-libs/libxslt.
  • make USE flag glusterfs to pass --disable-glusterfs.
  • make USE flag ntvfs to pass --without-ntvfs-fileserver.
  • make USE flag regedit to pass --without-regedit.

Flatcar changes:

  • set bundled_libs=ldb instead of ALL.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions