File: anita-wrapper.sh

package info (click to toggle)
flashprog 1.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,104 kB
  • sloc: ansic: 61,779; makefile: 919; sh: 310
file content (20 lines) | stat: -rw-r--r-- 472 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh

cd

[ "${IDENT}" ] || IDENT=$(mktemp -u XXXXXXXX)

CCACHE=/ccache/${IDENT}.img

[ -f ${CCACHE} ] || zcat cache.img.gz >${CCACHE}

AV_ARGS="${ANITA_VMM_ARGS} -drive file=${CCACHE},index=1,media=disk,format=raw"

if [ $# -eq 0 ]; then
	exec anita --vmm-args "${AV_ARGS}" --memory-size=${MEM_SIZE} \
		interact ${INST_IMG}
else
	exec anita --vmm-args "${AV_ARGS}" --memory-size=${MEM_SIZE} \
		--persist --run ". ./init && manitest \"$*\"" \
		boot ${INST_IMG}
fi