Convert all Dockerfiles to be template-based, and resync a few minor bits of Alpine and Debian (libedit in both, no recode in either, POSIX shell versions of docker-php-ext-* scripts for all)

This commit is contained in:
Tianon Gravi
2016-03-18 10:51:01 -07:00
parent e1ab9ff7bb
commit 3bf5b82235
7 changed files with 233 additions and 32 deletions

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh
set -e
cd /usr/src/php/ext
@ -36,10 +36,8 @@ while true; do
esac
done
exts=()
while [ $# -gt 0 ]; do
ext="$1"
shift
exts=
for ext; do
if [ -z "$ext" ]; then
continue
fi
@ -49,21 +47,25 @@ while [ $# -gt 0 ]; do
usage >&2
exit 1
fi
exts+=( "$ext" )
exts="$exts $ext"
done
if [ "${#exts[@]}" -eq 0 ]; then
if [ -z "$exts" ]; then
usage >&2
exit 1
fi
for ext in "${exts[@]}"; do
for ext in $exts; do
(
cd "$ext"
[ -e Makefile ] || docker-php-ext-configure "$ext"
make -j"$j"
make -j"$j" install
find modules -maxdepth 1 -name '*.so' -exec basename '{}' ';' | xargs --no-run-if-empty --verbose docker-php-ext-enable
find modules \
-maxdepth 1 \
-name '*.so' \
-exec basename '{}' ';' \
| xargs -r docker-php-ext-enable
make -j"$j" clean
)
done