java-*-openjdk-headless #18
Labels
No labels
Discussion
Easy
Focus Area: Content Strategy
Focus Area: Ecosystems Exploration
Focus Area: Prototyping Tools
Focus Area: Use Case Analysis
Idea
Meeting
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Docs/minimization#18
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
There's quite a bit of fat that can be trimmed here, for a minimal container with only java inside.
The biggest and easiest win is getting rid of (downgrading or moving)
cups-libs
, which pulls in both the gnutls and openssl crypto stacks. Savings of 20.4 MiB, real world about 17 MiB because%_install_langs
andnodocs
ca-certificates
pulls in 8.3 MiB of dependencies. We can't get rid ofca-certificates
, but perhaps we could minimize that package itself and shrink its dep chain. If we could get rid ofcoreutils{,-single}
,grep
, andsed
deps fromca-certificates
, we'd save 5.3 MiB. This would involve tweaking/usr/bin/ca-legacy
to use only bash builtins (uses theln
command), and updating the preinstall scriptlet (using /bin/sh) to avoid themv
command for creating the .rpmsave files (probably so far obsolete we don't need that part of the scriptlet anymore... I think last needed was RHEL 6?)There are several linked-in deps (via .so) that might be nice to have as optional:
alsa-lib
1.4 MiBfreetype
1.1 MiBlibjpeg-turbo
641 KiBcopy-jdk-configs
brings in 2.7 MiB of deps. maybe it could be made aRecommends
, for use everywhere but containers. It's needed to retain user changes to the default config files, since these java packages can beinstallonlypkgs
(this brings inlibxcrypt
,lua{,-libs,-posix}
,readline
)sizes tested on Fedora 32 (inside fedora:32 container) using
yum --installroot=/mnt/sysimage --releasever=/ --setopt=install_weak_deps=no install java-latest-openjdk-headless coreutils-single glibc-minimal-langpack
The big win of removing
cups-libs
:Before: 261M
After: 244M
For the
java-11-openjdk-headless
, there's alsolksctp-tools
at 281K -- I didn't dig to find why it's not on thejava-latest-openjdk-headless
package. (edit: it was added here https://src.fedoraproject.org/rpms/java-1.8.0-openjdk/c/9b9e825604ddd59cfbe6c03e25744bcdba1784a1?branch=master with message 'added requires lksctp-tools for headless subpackage to make sun.nio.ch.sctp work' -- probably should downgrade to Recommends if it's still relevant)I'll open a PR and/or BZ for cups-libs, then link it here.