aboutsummaryrefslogtreecommitdiffstats
path: root/main/busybox
diff options
context:
space:
mode:
authorChristian Kampka <christian@kampka.net>2015-10-26 14:48:24 +0100
committerNatanael Copa <ncopa@alpinelinux.org>2015-10-26 19:32:11 +0000
commit72abc71a3c5888042f634ebb492e84d517457aac (patch)
treefca40e3447132890905c786209d30436567b22d5 /main/busybox
parentc2deec832b08033a8f151dc8f7c565883d5bdb20 (diff)
downloadaports-72abc71a3c5888042f634ebb492e84d517457aac.tar.bz2
aports-72abc71a3c5888042f634ebb492e84d517457aac.tar.xz
main/busybox: split package into core and suid subpackages
Diffstat (limited to 'main/busybox')
-rw-r--r--main/busybox/APKBUILD18
-rw-r--r--main/busybox/busybox.trigger3
2 files changed, 14 insertions, 7 deletions
diff --git a/main/busybox/APKBUILD b/main/busybox/APKBUILD
index c54854083c..bd0780d5cc 100644
--- a/main/busybox/APKBUILD
+++ b/main/busybox/APKBUILD
@@ -2,15 +2,13 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=busybox
pkgver=1.23.2
-pkgrel=9
+pkgrel=10
pkgdesc="Size optimized toolbox of many common UNIX utilities"
url=http://busybox.net
arch="all"
license="GPL2"
-depends=
makedepends="linux-headers"
-install="$pkgname.post-install $pkgname.post-upgrade"
-subpackages="$pkgname-static"
+subpackages="$pkgname-static $pkgname-suid"
options="suid"
triggers="busybox.trigger=/bin:/usr/bin:/sbin:/usr/sbin:/lib/modules/*"
source="http://busybox.net/downloads/$pkgname-$pkgver.tar.bz2
@@ -41,6 +39,7 @@ _sdir="$srcdir"/$pkgname-$pkgver
_staticdir="$srcdir"/build-static
_dyndir="$srcdir"/build-dynamic
_config="$srcdir"/busyboxconfig
+
prepare() {
mkdir -p "$_staticdir" "$_dyndir"
#patches
@@ -92,7 +91,6 @@ package() {
"$pkgdir"/var/cache/misc "$pkgdir"/bin "$pkgdir"/sbin
chmod 1777 "$pkgdir"/tmp
install -m755 busybox "$pkgdir"/bin/busybox || return 1
- install -m4111 bbsuid "$pkgdir"/bin/bbsuid || return 1
# we need /bin/sh to be able to execute post-install
ln -s /bin/busybox "$pkgdir"/bin/sh
@@ -114,6 +112,16 @@ package() {
"$pkgdir"/etc/udhcpd.conf || return 1
}
+suid() {
+ pkgdesc="suid binaries of Busybox"
+ depends="${pkgname}"
+ triggers="busybox-suid.trigger=/bin:/usr/bin:/sbin:/usr/sbin"
+
+ cd "$_dyndir"
+ mkdir -p "$subpkgdir"/bin
+ install -m4111 bbsuid "$subpkgdir"/bin/bbsuid || return 1
+}
+
static() {
pkgdesc="Statically linked Busybox"
mkdir -p "$subpkgdir"/bin
diff --git a/main/busybox/busybox.trigger b/main/busybox/busybox.trigger
index 39cc6b4411..c9f90591f5 100644
--- a/main/busybox/busybox.trigger
+++ b/main/busybox/busybox.trigger
@@ -14,7 +14,6 @@ for i in "$@"; do
done
if [ -n "$do_bb_install" ]; then
- /bin/bbsuid --install
+ [ -e /bin/bbsuid ] && /bin/bbsuid --install
/bin/busybox --install -s
fi
-