#!/bin/sh
# Use a modules directory which doesn't exist so we don't load random things
# which may then get deleted (or their dependencies) and potentially segfault
export GIO_MODULE_DIR=/home/sim/yocto/scarthgap/build/tmp/work/cortexa72-poky-linux/libepoxy/1.5.10/recipe-sysroot/usr/lib/gio/modules-dummy

# meson sets this wrongly (only to libs in build-dir), qemu_wrapper_cmdline() and GIR_EXTRA_LIBS_PATH take care of it properly
unset LD_LIBRARY_PATH

PSEUDO_UNLOAD=1 qemu-aarch64 -r 5.15  -L /home/sim/yocto/scarthgap/build/tmp/work/cortexa72-poky-linux/libepoxy/1.5.10/recipe-sysroot -E LD_LIBRARY_PATH=/home/sim/yocto/scarthgap/build/tmp/work/cortexa72-poky-linux/libepoxy/1.5.10/recipe-sysroot//usr/lib:/home/sim/yocto/scarthgap/build/tmp/work/cortexa72-poky-linux/libepoxy/1.5.10/recipe-sysroot//usr/lib  "$@"
