Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 836820 - sys-apps/uutils-coreutils-0.13 should install a single binary
Summary: sys-apps/uutils-coreutils-0.13 should install a single binary
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Luca Barbato
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-05 09:00 UTC by Vincent de Phily
Modified: 2023-02-22 17:51 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent de Phily 2022-04-05 09:00:20 UTC
The current package build each utilities as separate binaries, resulting in over 110MB of binaries. Overall the package weighs 160MB.


Reproducible: Always



Expected Results:  
A direct `cargo build --release --features unix` results in a single 13MB binary (once stripped). The other binaries should be hardlinks of that single binary.
Comment 1 Vincent de Phily 2022-04-06 18:04:13 UTC
The `cargo install` method is probably too barebones for the ebuild, but it turns out we can get the desired behavior using ` make MULTICALL=y PROG_PREFIX=uu- install`.

It'd also be nice to only install the shell completions if the corresponding USE flag is set, but I didn't find a clean way to specify that with the makefile method.
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-04-06 18:04:55 UTC
Shell completions are usually installed unconditionally. You can use INSTALL_MASK to drop those.
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-02-22 17:50:52 UTC
[WW]   SIZE: 128.45MiB -> 16.73MiB, 401 -> 405 files
[WW] ------> FILES(+105,-101) SIZE(-86.98%)

Whew!
Comment 4 Larry the Git Cow gentoo-dev 2023-02-22 17:51:41 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61c929f551d2bc755d47047d3d2d1191d9ad96f7

commit 61c929f551d2bc755d47047d3d2d1191d9ad96f7
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-02-22 17:51:23 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-02-22 17:51:23 +0000

    sys-apps/uutils-coreutils: install multicall binary & use hardlinks
    
    This saves a huge amount of disk by having one binary where everything
    is hardlinked to it:
    ```
    [WW]   SIZE: 128.45MiB -> 16.73MiB, 401 -> 405 files
    [WW] ------> FILES(+105,-101) SIZE(-86.98%)
    ```
    
    Closes: https://bugs.gentoo.org/836820
    Signed-off-by: Sam James <sam@gentoo.org>

 ...reutils-0.0.17.ebuild => uutils-coreutils-0.0.17-r1.ebuild} |  8 +++++++-
 sys-apps/uutils-coreutils/uutils-coreutils-9999.ebuild         | 10 ++++++++--
 2 files changed, 15 insertions(+), 3 deletions(-)