Commit bd8cc1f4 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm repack generic-post.sh: improve desktop Exec checking

parent bb1f15bb
...@@ -32,7 +32,13 @@ for DESKTOPFILE in $BUILDROOT/usr/share/applications/*.desktop ; do ...@@ -32,7 +32,13 @@ for DESKTOPFILE in $BUILDROOT/usr/share/applications/*.desktop ; do
if echo "$EXEC" | grep -q "/" ; then if echo "$EXEC" | grep -q "/" ; then
warning "Exec path in desktop file $DESKTOPFILE contains slashes: $EXEC" warning "Exec path in desktop file $DESKTOPFILE contains slashes: $EXEC"
elif [ ! -s "./usr/bin/$EXEC" ] ; then elif [ ! -s "./usr/bin/$EXEC" ] ; then
warning "Exec from desktop file $DESKTOPFILE missed in /usr/bin: $EXEC" if [ -L "./usr/bin/$EXEC" ] ; then
if [ ! -s ".$(readlink "./usr/bin/$EXEC")" ] ; then
warning "Exec from desktop file $DESKTOPFILE exists as broken symlink /usr/bin/$EXEC to $(readlink "./usr/bin/$EXEC")"
fi
else
warning "Exec from desktop file $DESKTOPFILE missed in /usr/bin: $EXEC"
fi
elif [ ! -x "./usr/bin/$EXEC" ] ; then elif [ ! -x "./usr/bin/$EXEC" ] ; then
warning "Exec from desktop file $DESKTOPFILE exists in /usr/bin, but not executable: $EXEC" warning "Exec from desktop file $DESKTOPFILE exists in /usr/bin, but not executable: $EXEC"
elif [ -z "$EXEC" ] ; then elif [ -z "$EXEC" ] ; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment