blob: 8f8de0b6ebc48d3b9b8b677ec69b859686f5a198 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
#!/bin/sh
if [ "x$1" = "x-v" ]; then
vibrate=true
shift
else
vibrate=false
fi
package=`basename $1 .install`
if [ $vibrate = true ]; then
packages="libvibrant6b,$package"
else
packages=$package
fi
menu=`echo $1 | sed -e 's/install$/menu/'`
while read command junk; do
case $command in
*/bin/*) ;;
* ) continue ;;
esac
case $package in
libncbi6-dev) section="Applications/Programming" ;;
* ) section="Applications/Science/Biology" ;;
esac
case $command in
# Doesn't use requisite argument-handling framework
*/ncbisort) continue ;;
*/Nentrez ) title=Entrez ;;
*/Psequin ) title=Sequin ;;
*/netentcf) title="Entrez net config" ;;
* ) title=`basename $command` ;;
esac
icondir=/usr/share/pixmaps
case $command in
*/asntool) icon=$icondir/asntool.xpm ;;
*) icon=$icondir/ncbilogo.xpm ;;
esac
if [ $vibrate = true ]; then
command="usr/bin/vibrate /$command"
else
# generate an XDG .desktop file too
apps=debian/$package/usr/share/applications
base=`basename $command`
if test -f debian/$base.desktop.in; then
mkdir -p $apps
cat >$apps/$base.desktop <<EOF
[Desktop Entry]
Version=1.0
EOF
cat debian/$base.desktop.in >> $apps/$base.desktop
cat >>$apps/$base.desktop <<EOF
Type=Application
Exec=$base
Icon=ncbilogo
Categories=Education;Science;Biology;
EOF
continue
else
echo "$0: Warning: No .desktop information for $base" >&2
fi
fi
cat <<EOF
?package($packages):command="/$command" needs="X11" \\
section="$section" title="$title" icon="$icon"
EOF
done < "$1" > "$menu"
[ -s "$menu" ] || rm $menu
|