2018-05-05 18:27:19 +02:00
|
|
|
VERSION="0.3"
|
2018-03-04 16:35:28 +01:00
|
|
|
SRCDIR="init-${VERSION}"
|
2018-04-05 00:16:32 +02:00
|
|
|
TARBALL="${SRCDIR}.tar.xz"
|
2018-03-04 16:35:28 +01:00
|
|
|
URL="http://infraroot.at/pygos"
|
2018-05-05 18:27:19 +02:00
|
|
|
SHA256SUM="08999aae0865a8a0f26dac0c4bb8a11d3cf1ecfa51955d5fb53865c25a2f12df"
|
2018-03-04 16:35:28 +01:00
|
|
|
DEPENDS="toolchain"
|
|
|
|
|
|
|
|
prepare() {
|
|
|
|
return
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
local SOURCE="$1"
|
|
|
|
local DEPLOY="$2"
|
|
|
|
|
2018-04-06 01:03:29 +02:00
|
|
|
$SOURCE/configure --prefix="" --host="$TARGET" --sbindir=/bin \
|
|
|
|
--libexecdir=/lib/libexec
|
2018-03-04 16:35:28 +01:00
|
|
|
|
|
|
|
make -j $NUMJOBS
|
|
|
|
}
|
|
|
|
|
|
|
|
deploy() {
|
|
|
|
local SOURCE="$1"
|
|
|
|
local DEPLOY="$2"
|
|
|
|
local svc
|
|
|
|
|
|
|
|
make DESTDIR="$DEPLOY" install-strip
|
|
|
|
|
|
|
|
mkdir -p "$DEPLOY/etc/init.d"
|
|
|
|
|
|
|
|
if [ -e "$SCRIPTDIR/board/$BOARD/INIT" ]; then
|
|
|
|
source "$SCRIPTDIR/board/$BOARD/INIT"
|
|
|
|
fi
|
|
|
|
if [ -e "$SCRIPTDIR/product/$PRODUCT/INIT" ]; then
|
|
|
|
source "$SCRIPTDIR/product/$PRODUCT/INIT"
|
|
|
|
fi
|
|
|
|
|
2018-04-05 00:16:32 +02:00
|
|
|
if [ "x$HWCLOCK" == "xyes" ]; then
|
|
|
|
ln -s "/share/init/hwclock" "$DEPLOY/etc/init.d/hwclock"
|
|
|
|
fi
|
2018-03-04 16:35:28 +01:00
|
|
|
|
|
|
|
for svc in $GETTY_TTY; do
|
|
|
|
ln -s "/share/init/agetty" "$DEPLOY/etc/init.d/agetty@$svc"
|
|
|
|
done
|
|
|
|
|
2018-04-05 00:16:32 +02:00
|
|
|
unset -v i GETTY_TTY HWCLOCK
|
2018-03-04 16:35:28 +01:00
|
|
|
}
|