awk -F: '{ print $2 }' | $BASEDIR/tools/base64)
build_spy machine $(uname -m)
build_spy toolchain "${NAME}-${TOOLCHAINVERSION}"
- for i in system fedora redhat $SNAME debian ubuntu lsb; do
- if [ -e "/etc/${i}-release" ]; then
- build_spy system "$($BASEDIR/tools/base64 < /etc/${i}-release)"
+ for i in /etc/{system,fedora,redhat,$SNAME,debian,ubuntu,lsb}-release /etc/debian_version; do
+ if [ -e "${i}" ]; then
+ SYSTEM_STRING=$(cat ${i} 2>/dev/null)
+ grep -q "debian" <<<${i} && SYSTEM_STRING="Debian $SYSTEM_STRING"
+ build_spy system "$($BASEDIR/tools/base64 <<<$SYSTEM_STRING)"
break
fi
done