#!/bin/sh -e
# Check that 'file' can distinguish stripped and unstripped binaries.
cd "$AUTOPKGTEST_TMP"
sh-elf-as /dev/null
if ! [ -e a.out ]
then
	echo Failed to make a.out >&2
	exit 1
fi

file_unstripped=$(file a.out)
sh-elf-strip a.out
if [ "$(file a.out)" = "$file_unstripped" ]
then
	echo Got \'$file_unstripped\' both times >&2
	exit 1
fi
