# sudo apt install crossbuild-essential-armhf qemu-user-binfmt gdb-multiarch

if [ -x "$1" ]; then
	qemu-arm -L /usr/arm-linux-gnueabihf -g 1234 $1 &
	gdb-multiarch --ex="set architecture armv7" --ex="set sysroot /usr/arm-linux-gnueabihf/" --ex="target remote localhost:1234" --ex="break main" $1
fi
