diff options
Diffstat (limited to 'benchmarks/linux-unigine-valley/files/wrapper.sh.in')
-rw-r--r-- | benchmarks/linux-unigine-valley/files/wrapper.sh.in | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/benchmarks/linux-unigine-valley/files/wrapper.sh.in b/benchmarks/linux-unigine-valley/files/wrapper.sh.in new file mode 100644 index 000000000000..d1c2b28d1b66 --- /dev/null +++ b/benchmarks/linux-unigine-valley/files/wrapper.sh.in @@ -0,0 +1,22 @@ +#!/bin/sh + +LNX_ROOT=$(sysctl -n compat.linux.emul_path) + +if [ ! -f "$LNX_ROOT/proc/self/exe" -o ! -d "$LNX_ROOT/sys/dev/char" ] +then + echo "This program requires mounted linprocfs(5) and linsysfs(5)" >&2 + exit 1 +fi + +# OpenAL Soft uses PulseAudio by default, which might not work on FreeBSD + +ALSOFT_CONF=$LNX_ROOT/etc/openal/alsoft.conf + +if ! grep -qs '^drivers[[:blank:]]*=[[:blank:]]*oss' "$ALSOFT_CONF" +then + echo "If there's no sound, try putting \`oss' as the first item" \ + "on the \`drivers' line in the $ALSOFT_CONF file." | fmt -76 >&2 + sleep 2 +fi + +cd %%DATADIR%% && exec $LNX_ROOT/bin/bash ./valley |