summaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
authorA. Wilcox <awilcox@wilcox-tech.com>2019-07-22 19:43:53 +0000
committerA. Wilcox <awilcox@wilcox-tech.com>2019-07-22 19:43:53 +0000
commitb7ffaa4d55e1faf4de0f8e6a2edf372fedfeaf71 (patch)
tree5948e97345062a759a5ab8d355b0b49849abcfcf /system
parentd61220e97e3a4fec8c1e43970cb1408f790c2c2e (diff)
parent6bd200ed124893c95fda0335b684b26eba0bb743 (diff)
downloadpackages-b7ffaa4d55e1faf4de0f8e6a2edf372fedfeaf71.tar.gz
packages-b7ffaa4d55e1faf4de0f8e6a2edf372fedfeaf71.tar.bz2
packages-b7ffaa4d55e1faf4de0f8e6a2edf372fedfeaf71.tar.xz
packages-b7ffaa4d55e1faf4de0f8e6a2edf372fedfeaf71.zip
Merge branch 'bashisms' into 'master'
Purge bashisms, adduser, and addgroup from packages.git See merge request adelie/packages!293
Diffstat (limited to 'system')
-rw-r--r--system/abuild/APKBUILD2
-rw-r--r--system/abuild/abuild.pre-install2
-rw-r--r--system/apk-tools/APKBUILD12
-rw-r--r--system/at/APKBUILD2
-rw-r--r--system/at/at.pre-install4
-rw-r--r--system/bash/APKBUILD2
-rw-r--r--system/bc/APKBUILD3
-rw-r--r--system/ca-certificates/APKBUILD2
-rw-r--r--system/ca-certificates/ca-certificates.trigger2
-rw-r--r--system/coreutils/APKBUILD15
-rw-r--r--system/fcron/APKBUILD2
-rw-r--r--system/fcron/fcron.pre-install4
-rw-r--r--system/gcc/APKBUILD4
-rw-r--r--system/icu/APKBUILD4
-rw-r--r--system/libedit/APKBUILD2
-rw-r--r--system/mawk/APKBUILD2
-rw-r--r--system/musl/APKBUILD2
-rw-r--r--system/ncurses/APKBUILD4
-rw-r--r--system/nss/APKBUILD6
-rw-r--r--system/openrc/APKBUILD2
-rw-r--r--system/ruby/APKBUILD4
-rw-r--r--system/sysvinit/APKBUILD2
-rw-r--r--system/sysvinit/sysvinit.post-upgrade2
-rw-r--r--system/unzip/APKBUILD2
24 files changed, 43 insertions, 45 deletions
diff --git a/system/abuild/APKBUILD b/system/abuild/APKBUILD
index 46495b93f..30428a27c 100644
--- a/system/abuild/APKBUILD
+++ b/system/abuild/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=abuild
pkgver=3.3.1
-pkgrel=1
+pkgrel=2
pkgdesc="Script to build APK packages"
url="https://code.foxkit.us/adelie/abuild"
arch="all"
diff --git a/system/abuild/abuild.pre-install b/system/abuild/abuild.pre-install
index fd3d39a36..169982d83 100644
--- a/system/abuild/abuild.pre-install
+++ b/system/abuild/abuild.pre-install
@@ -1,5 +1,5 @@
#!/bin/sh
-addgroup -S abuild 2>/dev/null
+groupadd -r abuild 2>/dev/null
exit 0
diff --git a/system/apk-tools/APKBUILD b/system/apk-tools/APKBUILD
index 86a15d28a..5305ed1cb 100644
--- a/system/apk-tools/APKBUILD
+++ b/system/apk-tools/APKBUILD
@@ -56,16 +56,16 @@ static() {
# lets sign the static binary so it can be vefified from distros
# that does not have apk-tools
- local abuild_conf=${ABUILD_CONF:-"/etc/abuild.conf"}
- local abuild_home=${ABUILD_USERDIR:-"$HOME/.abuild"}
- local abuild_userconf=${ABUILD_USERCONF:-"$abuild_home/abuild.conf"}
+ local abuild_conf="${ABUILD_CONF:-"/etc/abuild.conf"}"
+ local abuild_home="${ABUILD_USERDIR:-"$HOME/.abuild"}"
+ local abuild_userconf="${ABUILD_USERCONF:-"$abuild_home/abuild.conf"}"
[ -f "$abuild_userconf" ] && . "$abuild_userconf"
local privkey="$PACKAGER_PRIVKEY"
- local pubkey=${PACKAGER_PUBKEY:-"${privkey}.pub"}
- local keyname=${pubkey##*/}
+ local pubkey="${PACKAGER_PUBKEY:-"${privkey}.pub"}"
+ local keyname="${pubkey##*/}"
${CROSS_COMPILE}strip "$subpkgdir"/sbin/apk.static
openssl dgst -sha1 -sign "$privkey" \
- -out "$subpkgdir"/sbin/apk.static.SIGN.RSA.$keyname \
+ -out "$subpkgdir/sbin/apk.static.SIGN.RSA.$keyname" \
"$subpkgdir"/sbin/apk.static
}
diff --git a/system/at/APKBUILD b/system/at/APKBUILD
index d4bdb4f2e..a50d7fb77 100644
--- a/system/at/APKBUILD
+++ b/system/at/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=at
pkgver=3.1.23
-pkgrel=1
+pkgrel=2
pkgdesc="Delayed job execution and batch processing daemon"
url="https://packages.qa.debian.org/a/at.html"
arch="all"
diff --git a/system/at/at.pre-install b/system/at/at.pre-install
index 78aa4bcf1..1d92862db 100644
--- a/system/at/at.pre-install
+++ b/system/at/at.pre-install
@@ -1,6 +1,6 @@
#!/bin/sh
-addgroup -S at 2>/dev/null
-adduser -S -D -H -s /bin/false -G at -g at at 2>/dev/null
+groupadd -r at 2>/dev/null
+useradd -c at -s /sbin/nologin -g at -r at 2>/dev/null
exit 0
diff --git a/system/bash/APKBUILD b/system/bash/APKBUILD
index ccdf8ab13..1e1dccbee 100644
--- a/system/bash/APKBUILD
+++ b/system/bash/APKBUILD
@@ -5,7 +5,7 @@ pkgname=bash
pkgver=4.4.23
_patchlevel=${pkgver##*.}
_myver=${pkgver%.*}
-_patchbase=${_myver/./}
+_patchbase=$(printf '%s' "$_myver" | tr -d .)
pkgrel=1
pkgdesc="The GNU Bourne Again shell"
url="https://www.gnu.org/software/bash/bash.html"
diff --git a/system/bc/APKBUILD b/system/bc/APKBUILD
index 4dcc4b94b..79d5a0c4d 100644
--- a/system/bc/APKBUILD
+++ b/system/bc/APKBUILD
@@ -10,8 +10,7 @@ license="BSD-2-Clause"
depends=""
makedepends=""
subpackages="$pkgname-doc"
-source="https://github.com/gavinhoward/bc/releases/download/${pkgver/_/-}/bc-${pkgver/_/-}.tar.xz"
-builddir="$srcdir"/$pkgname-${pkgver/_/-}
+source="https://github.com/gavinhoward/bc/releases/download/$pkgver/bc-$pkgver.tar.xz"
build() {
PREFIX="/usr" DESTDIR="$pkgdir" ./configure.sh -g -G -O3
diff --git a/system/ca-certificates/APKBUILD b/system/ca-certificates/APKBUILD
index d5af2b91c..0785ec441 100644
--- a/system/ca-certificates/APKBUILD
+++ b/system/ca-certificates/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=ca-certificates
pkgver=20190131
-pkgrel=0
+pkgrel=1
pkgdesc="CA root certificates"
url="https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/"
arch="all"
diff --git a/system/ca-certificates/ca-certificates.trigger b/system/ca-certificates/ca-certificates.trigger
index eff198163..e584113a9 100644
--- a/system/ca-certificates/ca-certificates.trigger
+++ b/system/ca-certificates/ca-certificates.trigger
@@ -1,3 +1,3 @@
#!/bin/sh
-/usr/sbin/update-ca-certificates --fresh &> /dev/null
+/usr/sbin/update-ca-certificates --fresh >/dev/null 2>&1
exit 0
diff --git a/system/coreutils/APKBUILD b/system/coreutils/APKBUILD
index e5461c7d2..4a70574c3 100644
--- a/system/coreutils/APKBUILD
+++ b/system/coreutils/APKBUILD
@@ -9,10 +9,10 @@ url="https://www.gnu.org/software/coreutils/"
arch="all"
license="GPL-3.0+"
makedepends="bash acl-dev attr-dev"
-[ ${CBUILD} == ${CHOST} ] && makedepends="$makedepends perl gettext-tiny
+[ "${CBUILD}" = "${CHOST}" ] && makedepends="$makedepends perl gettext-tiny
gettext-tiny-dev utmps-dev"
subpackages="$pkgname-doc"
-[ ${CBUILD} == ${CHOST} ] && subpackages="$subpackages $pkgname-lang"
+[ "${CBUILD}" = "${CHOST}" ] && subpackages="$subpackages $pkgname-lang"
install="$pkgname.post-deinstall"
source="https://ftp.gnu.org/gnu/coreutils/$pkgname-$pkgver.tar.xz
date-debug.patch
@@ -22,7 +22,7 @@ source="https://ftp.gnu.org/gnu/coreutils/$pkgname-$pkgver.tar.xz
gnulib-test-fixes.patch
localename-test-fix.patch
"
-[ ${CBUILD} != ${CHOST} ] && source="$source
+[ "${CBUILD}" != "${CHOST}" ] && source="$source
051_all_coreutils-mangen.patch
"
@@ -43,9 +43,10 @@ build() {
--with-packager="Adélie" \
--with-packager-bug-reports="https://bts.adelielinux.org/"
- if [ ${CBUILD} != ${CHOST} ]; then
- set -- man/*.x
- touch ${@/%x/1}
+ if [ "${CBUILD}" != "${CHOST}" ]; then
+ for i in man/*.x; do
+ touch "${i%x}1"
+ done
fi
make
}
@@ -70,7 +71,7 @@ bd8b5cecba59eba30458c8afa895877d39a987b989bc06b70cd6836e0ef684677aaadcb4949b58a7
fd97fccd661befc558b3afb3e32c82dd2cef511a05e6129d49540599297c1b59ab1f109e63a12f585a2348c26c28fb98330c348829d1fe61cf8149d0dd1c989c gnulib-tests-dont-require-gpg-passphrase.patch
a1d014a683fb3b2e08e7392f7589fd92a565e2a4d0cac1cf960968dd3d990e020fdd3bb6aea2bbeaca3ba8f2522b4da3d75b93f414ebf83d8b26b5ccbb38a64d gnulib-test-fixes.patch
aac3a89b27a7854fbf483e155df9133c3d33a0f36bd55d5606559a7781f9d27d5c17779ea427142311749252767097bf92ec22d4cf86b510568c186da84ff16c date-debug.patch"
-[ ${CBUILD} != ${CHOST} ] && sha512sums="
+[ "${CBUILD}" != "${CHOST}" ] && sha512sums="
bae804f057252c25452ac178c545dc2c4b4775cbfbdcfd4775edd1a4ed6507882bfac39e2b11ad01b74230ca48d761bf62f11bde5bcbc35a6e5a61cbe4a46e36 051_all_coreutils-mangen.patch
"
return 0
diff --git a/system/fcron/APKBUILD b/system/fcron/APKBUILD
index 79f12c416..15f9c2713 100644
--- a/system/fcron/APKBUILD
+++ b/system/fcron/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=fcron
pkgver=3.2.1
-pkgrel=1
+pkgrel=2
pkgdesc="periodical command scheduler for systems not always up"
url="http://fcron.free.fr/"
pkgusers="fcron"
diff --git a/system/fcron/fcron.pre-install b/system/fcron/fcron.pre-install
index b15879178..8f64a517b 100644
--- a/system/fcron/fcron.pre-install
+++ b/system/fcron/fcron.pre-install
@@ -1,6 +1,6 @@
#!/bin/sh
-adduser -S -D -H -s /sbin/nologin -g fcron fcron 2>/dev/null
-addgroup -S fcron 2>/dev/null
+groupadd -r fcron 2>/dev/null
+useradd -c fcron -s /sbin/nologin -g fcron -r fcron 2>/dev/null
exit 0
diff --git a/system/gcc/APKBUILD b/system/gcc/APKBUILD
index 5eaae5163..68771a8aa 100644
--- a/system/gcc/APKBUILD
+++ b/system/gcc/APKBUILD
@@ -343,7 +343,7 @@ package() {
rm -f "$pkgdir"/usr/lib/libffi* "$pkgdir"/usr/share/man/man3/ffi*
find "$pkgdir" -name 'ffi*.h' | xargs rm -f
- local gdblib=${_target:+$CTARGET/}lib
+ local gdblib="${_target:+$CTARGET/}lib"
for i in $(find "$pkgdir"/usr/$gdblib/ -type f -maxdepth 1 -name "*-gdb.py" ); do
mkdir -p "$pkgdir"/usr/share/gdb/python/auto-load/usr/$gdblib
mv "$i" "$pkgdir"/usr/share/gdb/python/auto-load/usr/$gdblib/
@@ -368,7 +368,7 @@ package() {
# linker finds the libs from relocated sysroot
for so in "$pkgdir"/usr/$CTARGET/lib/*.so; do
if [ -h "$so" ]; then
- local _real=$(basename $(readlink "$so"))
+ local _real="$(basename $(readlink "$so"))"
rm -f "$so"
echo "GROUP ($_real)" > "$so"
fi
diff --git a/system/icu/APKBUILD b/system/icu/APKBUILD
index 35ca27573..7676fbf2b 100644
--- a/system/icu/APKBUILD
+++ b/system/icu/APKBUILD
@@ -4,7 +4,7 @@ pkgname=icu
pkgver=63.1
# convert x.y.z to x_y_z
-_ver=${pkgver//./_}
+_ver=$(printf '%s' "$pkgver" | tr . _)
pkgrel=1
pkgdesc="International Components for Unicode library"
@@ -15,7 +15,7 @@ subpackages="$pkgname-static $pkgname-dev $pkgname-doc $pkgname-libs"
depends=""
checkdepends="diffutils"
makedepends=""
-source="https://download.icu-project.org/files/icu4c/${pkgver}/${pkgname}4c-$_ver-src.tgz
+source="https://ssl.icu-project.org/files/icu4c/${pkgver}/${pkgname}4c-$_ver-src.tgz
icu-60.2-always-use-utf8.patch
checkimpl.patch
icu-63.1-test-failure.patch
diff --git a/system/libedit/APKBUILD b/system/libedit/APKBUILD
index d9dc2003b..33d7abb78 100644
--- a/system/libedit/APKBUILD
+++ b/system/libedit/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=libedit
pkgver=20190324.3.1
-_realver=${pkgver/.3.1/-3.1}
+_realver="${pkgver%%.*}-${pkgver#*.}"
pkgrel=0
pkgdesc="Library providing line editing, history, and tokenisation functions"
url="https://thrysoee.dk/editline/"
diff --git a/system/mawk/APKBUILD b/system/mawk/APKBUILD
index ca9005ce5..8f2cd7faf 100644
--- a/system/mawk/APKBUILD
+++ b/system/mawk/APKBUILD
@@ -8,7 +8,7 @@ url="https://invisible-island.net/mawk/mawk.html"
arch="all"
license="BSD-3-Clause"
subpackages="$pkgname-doc"
-_dlver="${pkgver/.201/-201}"
+_dlver="${pkgver%.*}-${pkgver##*.}"
source="https://invisible-mirror.net/archives/$pkgname/$pkgname-$_dlver.tgz"
builddir="$srcdir/$pkgname-$_dlver"
diff --git a/system/musl/APKBUILD b/system/musl/APKBUILD
index 7028f21ec..73bfea8b5 100644
--- a/system/musl/APKBUILD
+++ b/system/musl/APKBUILD
@@ -82,7 +82,7 @@ package() {
make DESTDIR="$pkgdir" install
# make LDSO the be the real file, and libc the symlink
- local LDSO=$(make -f Makefile --eval "$(echo -e 'print-ldso:\n\t@echo $$(basename $(LDSO_PATHNAME))')" print-ldso)
+ local LDSO="$(make -f Makefile --eval "$(printf 'print-ldso:\n\t@echo $$(basename $(LDSO_PATHNAME))')" print-ldso)"
mv -f "$pkgdir"/usr/lib/libc.so "$pkgdir"/lib/"$LDSO"
ln -sf "$LDSO" "$pkgdir"/lib/libc.musl-${CARCH}.so.1
ln -sf ../../lib/"$LDSO" "$pkgdir"/usr/lib/libc.so
diff --git a/system/ncurses/APKBUILD b/system/ncurses/APKBUILD
index 058a81abd..414283adf 100644
--- a/system/ncurses/APKBUILD
+++ b/system/ncurses/APKBUILD
@@ -49,8 +49,8 @@ package() {
# Install basic terms in /etc/terminfo
for i in ansi console dumb linux rxvt screen sun vt52 vt100 vt102 \
vt200 vt220 xterm xterm-color xterm-xfree86; do
- local termfile=$(find "$pkgdir"/usr/share/terminfo/ -name "$i" 2>/dev/null) || true
- local basedir=$(basename $(dirname "$termfile"))
+ local termfile="$(find "$pkgdir"/usr/share/terminfo/ -name "$i" 2>/dev/null)"
+ local basedir="$(basename $(dirname "$termfile"))"
[ -z "$termfile" ] && continue
diff --git a/system/nss/APKBUILD b/system/nss/APKBUILD
index 9c41ced39..f88776116 100644
--- a/system/nss/APKBUILD
+++ b/system/nss/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=nss
pkgver=3.44.1
-_ver=${pkgver//./_}
+_ver=$(printf '%s' "$pkgver" | tr . _)
pkgrel=0
pkgdesc="Mozilla Network Security Services"
url="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS"
@@ -13,7 +13,7 @@ depends=""
depends_dev="nspr-dev"
makedepends="nspr-dev sqlite-dev zlib-dev perl bsd-compat-headers"
subpackages="$pkgname-static $pkgname-dev $pkgname-tools"
-source="https://ftp.mozilla.org/pub/security/$pkgname/releases/NSS_${pkgver//./_}_RTM/src/$pkgname-$pkgver.tar.gz
+source="https://ftp.mozilla.org/pub/security/$pkgname/releases/NSS_${_ver}_RTM/src/$pkgname-$pkgver.tar.gz
nss.pc.in
nss-util.pc.in
nss-softokn.pc.in
@@ -85,7 +85,7 @@ package() {
-e "s,@MOD_PATCH_VERSION@,${NSS_VPATCH},g" \
> "$pkgdir"/usr/bin/nss-config
chmod 755 "$pkgdir"/usr/bin/nss-config
- local minor=${pkgver#*.}
+ local minor="${pkgver#*.}"
minor=${minor%.*}
for file in $(find dist/*.OBJ/lib -name "*.so"); do
install -m755 $file \
diff --git a/system/openrc/APKBUILD b/system/openrc/APKBUILD
index fcec2abeb..c59c0b642 100644
--- a/system/openrc/APKBUILD
+++ b/system/openrc/APKBUILD
@@ -1,7 +1,6 @@
# Maintainer:
pkgname=openrc
pkgver=0.24.1
-_ver=${pkgver/_git*/}
pkgrel=7
pkgdesc="OpenRC manages the services, startup and shutdown of a host"
url="https://github.com/OpenRC/openrc"
@@ -33,7 +32,6 @@ source="$pkgname-$pkgver.tar.gz::https://github.com/OpenRC/openrc/archive/$pkgve
sysfsconf.initd
"
-builddir="$srcdir/$pkgname-$_ver"
prepare() {
default_prepare
sed -i -e '/^sed/d' "$builddir"/pkgconfig/Makefile
diff --git a/system/ruby/APKBUILD b/system/ruby/APKBUILD
index 67b89f845..1a26b65b3 100644
--- a/system/ruby/APKBUILD
+++ b/system/ruby/APKBUILD
@@ -73,7 +73,7 @@ replaces="ruby-etc ruby-gems"
_gemdir="/usr/lib/ruby/gems/$_abiver"
_rubydir="/usr/lib/ruby/$_abiver"
-_chost="${CHOST/-foxkit-/-}"
+_chost="$(printf '%s' "$CHOST" | sed 's/-foxkit-/-/')"
case "$CARCH" in
x86 | pmmx) _arch="i386";;
@@ -136,7 +136,7 @@ package() {
rm -R "$pkgdir"$_gemdir/cache/*
if [ -d "$pkgdir"/usr/local ]; then
- local f=$(cd "$pkgdir" ; find usr/local -type f)
+ local f="$(cd "$pkgdir" ; find usr/local -type f)"
if [ -n "$f" ]; then
error "Found files in /usr/local:"
echo "$f"
diff --git a/system/sysvinit/APKBUILD b/system/sysvinit/APKBUILD
index b95525084..e13e92043 100644
--- a/system/sysvinit/APKBUILD
+++ b/system/sysvinit/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=sysvinit
pkgver=2.88
-pkgrel=6
+pkgrel=7
pkgdesc="System V-style init programs"
url="https://savannah.nongnu.org/projects/sysvinit"
arch="all"
diff --git a/system/sysvinit/sysvinit.post-upgrade b/system/sysvinit/sysvinit.post-upgrade
index 189621e2c..9b909f73b 100644
--- a/system/sysvinit/sysvinit.post-upgrade
+++ b/system/sysvinit/sysvinit.post-upgrade
@@ -1,4 +1,4 @@
#!/bin/sh
-/sbin/telinit U &> /dev/null
+/sbin/telinit U >/dev/null 2>&1
exit 0
diff --git a/system/unzip/APKBUILD b/system/unzip/APKBUILD
index 55ad2fd05..aad54fa2d 100644
--- a/system/unzip/APKBUILD
+++ b/system/unzip/APKBUILD
@@ -3,7 +3,7 @@
# Maintainer: Dan Theisen <djt@hxx.in>
pkgname=unzip
pkgver=6.0
-_pkgver=${pkgver//./}
+_pkgver=$(printf '%s' "$pkgver" | tr -d .)
pkgrel=3
pkgdesc="Extract PKZIP-compatible .zip files"
url="http://www.info-zip.org/UnZip.html"