2013-12-08 13:14:00 +01:00
|
|
|
# Build template for 'base-system-busybox'.
|
2012-09-17 15:50:27 +02:00
|
|
|
pkgname=base-system-busybox
|
2015-03-25 21:33:03 +01:00
|
|
|
version=1.23.2
|
2015-03-25 21:45:40 +01:00
|
|
|
revision=5
|
2012-01-29 20:27:49 +01:00
|
|
|
wrksrc="busybox-${version}"
|
|
|
|
homepage="http://www.busybox.net"
|
2014-02-10 11:57:53 +01:00
|
|
|
hostmakedepends="perl"
|
2013-12-08 13:14:00 +01:00
|
|
|
short_desc="The Swiss Army Knife of Embedded Linux - base-system replacements"
|
2012-01-29 20:27:49 +01:00
|
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
|
|
|
license="GPL-2"
|
2013-04-12 08:55:23 +02:00
|
|
|
distfiles="${homepage}/downloads/busybox-$version.tar.bz2"
|
2015-03-25 21:33:03 +01:00
|
|
|
checksum=05a6f9e21aad8c098e388ae77de7b2361941afa7157ef74216703395b14e319a
|
2012-01-29 20:27:49 +01:00
|
|
|
|
2014-09-20 12:05:25 +02:00
|
|
|
register_shell="/bin/sh"
|
2014-09-20 11:17:32 +02:00
|
|
|
conflicts="base-system>=0"
|
|
|
|
|
2014-01-01 16:10:11 +01:00
|
|
|
# Applets provided by this busybox version.
|
|
|
|
# Keep this list updated with ${FILESDIR}/dotconfig.
|
|
|
|
#
|
|
|
|
# XXX bzip2 provides libbz2, split it into libbz2 pkg.
|
2014-09-21 10:58:19 +02:00
|
|
|
# XXX pgrep/pkill do not support -s0,1 required by runit-void.
|
|
|
|
# XXX sysctl --system unsupported
|
|
|
|
#
|
2014-07-01 11:40:48 +02:00
|
|
|
_FEATURES="acpid coreutils cpio dash diffutils dosfstools findutils awk
|
2014-01-01 16:10:11 +01:00
|
|
|
grep gzip hdparm ifenslave iproute2 iputils less lsof netcat nvi
|
2014-09-21 10:58:19 +02:00
|
|
|
patch powertop psmisc rfkill run-parts sed tar
|
2015-03-25 21:38:44 +01:00
|
|
|
traceroute util-linux which whois xz ncurses"
|
2014-01-01 16:10:11 +01:00
|
|
|
for f in ${_FEATURES}; do
|
2014-11-11 17:05:36 +01:00
|
|
|
provides+=" ${f}-${version}_${revision}"
|
|
|
|
conflicts+=" ${f}>=0"
|
2014-01-01 16:10:11 +01:00
|
|
|
done
|
|
|
|
|
2015-03-25 21:43:50 +01:00
|
|
|
depends="base-files runit-void xbps kbd eudev shadow kmod ncurses-base procps-ng tzdata ethtool"
|
2014-09-21 10:58:19 +02:00
|
|
|
|
|
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
|
|
*-musl) depends+=" musl";;
|
2015-03-22 14:13:12 +01:00
|
|
|
*) depends+=" glibc-locales";;
|
2014-09-21 10:58:19 +02:00
|
|
|
esac
|
2014-09-20 11:05:33 +02:00
|
|
|
|
2014-02-10 11:57:53 +01:00
|
|
|
pre_build() {
|
2012-01-29 20:27:49 +01:00
|
|
|
cp -f ${FILESDIR}/dotconfig .config
|
2013-12-08 16:00:17 +01:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
|
|
sed -e "s,\(CONFIG_CROSS_COMPILER_PREFIX\).*,\1=\"${XBPS_CROSS_TRIPLET}-\",g" -i .config
|
|
|
|
fi
|
2014-02-10 11:57:53 +01:00
|
|
|
}
|
|
|
|
do_build() {
|
2012-01-29 20:27:49 +01:00
|
|
|
make ${makejobs}
|
|
|
|
}
|
|
|
|
do_install() {
|
2014-09-20 09:50:28 +02:00
|
|
|
# Install everything to /usr/bin and /usr/sbin.
|
2012-07-09 15:20:34 +02:00
|
|
|
vmkdir usr/bin
|
2014-09-20 09:50:28 +02:00
|
|
|
vmkdir usr/sbin
|
|
|
|
for f in bin sbin; do
|
|
|
|
ln -sfr ${DESTDIR}/usr/$f ${DESTDIR}/${f}
|
2013-12-08 13:14:00 +01:00
|
|
|
done
|
|
|
|
make CONFIG_PREFIX=${DESTDIR} install
|
|
|
|
vinstall ${FILESDIR}/udhcpc-default.script \
|
|
|
|
755 usr/share/udhcpc default.script
|
2014-09-20 09:50:28 +02:00
|
|
|
rm -f ${DESTDIR}/{,s}bin
|
2014-09-20 11:17:32 +02:00
|
|
|
# Provide /sbin/init symlink to runit.
|
|
|
|
ln -s /usr/bin/runit-init ${DESTDIR}/usr/sbin/init
|
2012-01-29 20:27:49 +01:00
|
|
|
}
|