mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-11-29 12:44:53 +01:00
lua-test: Image the loader test directory if it doesn't exist yet
This commit is contained in:
parent
ff8409871e
commit
574a8bf981
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=329407
@ -1,19 +1,22 @@
|
||||
#!/bin/sh
|
||||
# $FreeBSD$
|
||||
|
||||
# Will image the test directory (default /tmp/loadertest) if it doesn't exist
|
||||
|
||||
die() {
|
||||
echo $*
|
||||
exit 1
|
||||
}
|
||||
|
||||
dir=$1
|
||||
scriptdir=$(dirname $(realpath $0))
|
||||
cd $(make -V SRCTOP)/stand
|
||||
obj=$(make -V .OBJDIR)
|
||||
t=$obj/userboot/test/test
|
||||
u=$obj/userboot/userboot/userboot.so
|
||||
|
||||
[ -n "$dir" ] || dir=/tmp/loadertest
|
||||
[ -d "$dir" ] || die "Directory $dir doesn't exist"
|
||||
[ -d "$dir" ] || ${scriptdir}/lua-img.sh ${dir}
|
||||
[ -f "$dir/boot/lua/loader.lua" ] || die "No boot/lua/loader.lua found"
|
||||
[ -f "$dir/boot/kernel/kernel" ] || die "No kernel to load"
|
||||
[ -x "$t" ] || die "no userboot test jig found ($t)"
|
||||
|
Loading…
Reference in New Issue
Block a user