1
0
Fork 0
mirror of https://github.com/docker-library/ruby.git synced 2022-11-09 11:41:34 -05:00

Add "libgdbm-compat-dev" explicitly in Buster+ on Slim variants

This makes "require 'dbm'" work -- it uses "ndbm.h" to detect support (which is provided by this package in Buster+).
This commit is contained in:
Tianon Gravi 2019-06-25 12:40:06 -07:00
parent f8c8256104
commit e46b04d695
3 changed files with 9 additions and 0 deletions

View file

@ -38,6 +38,7 @@ RUN set -eux; \
dpkg-dev \ dpkg-dev \
gcc \ gcc \
libbz2-dev \ libbz2-dev \
libgdbm-compat-dev \
libgdbm-dev \ libgdbm-dev \
libglib2.0-dev \ libglib2.0-dev \
libncurses-dev \ libncurses-dev \

View file

@ -39,6 +39,7 @@ RUN set -eux; \
dpkg-dev \ dpkg-dev \
gcc \ gcc \
libbz2-dev \ libbz2-dev \
libgdbm-compat-dev \
libgdbm-dev \ libgdbm-dev \
libglib2.0-dev \ libglib2.0-dev \
libncurses-dev \ libncurses-dev \

View file

@ -98,6 +98,13 @@ for version in "${versions[@]}"; do
-e 's/^(FROM (debian|buildpack-deps|alpine)):.*/\1:'"$tag"'/' \ -e 's/^(FROM (debian|buildpack-deps|alpine)):.*/\1:'"$tag"'/' \
"$template" > "$dir/Dockerfile" "$template" > "$dir/Dockerfile"
case "$v" in
# https://packages.debian.org/sid/libgdbm-compat-dev (needed for "dbm" core module, but only in Buster+)
jessie/slim | stretch/slim)
sed -i -e '/libgdbm-compat-dev/d' "$dir/Dockerfile"
;;
esac
if [ -n "${newEnoughRubygems[$rcVersion]:-}" ]; then if [ -n "${newEnoughRubygems[$rcVersion]:-}" ]; then
sed -ri -e '/RUBYGEMS_VERSION/d' "$dir/Dockerfile" sed -ri -e '/RUBYGEMS_VERSION/d' "$dir/Dockerfile"
fi fi