-
Notifications
You must be signed in to change notification settings - Fork 15
/
go-gui
executable file
·93 lines (82 loc) · 1.9 KB
/
go-gui
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#!/bin/sh
# LIC: GPL
#***********************************************************************
#
# go-gui
#
# Quick-start shell script to set up PPPoE and GUI wrapper
#
# Copyright (C) 2000 Roaring Penguin Software Inc.
#
# $Id$
#***********************************************************************
# GUI only works on Linux
if test "`uname`" != "Linux" ; then
echo "Sorry, the GUI only works on Linux."
exit 1
fi
# Figure out directory of script
MYDIR=`dirname $0`
cd $MYDIR/src
echo "Running ./configure..."
./configure
if [ "$?" != 0 ] ; then
echo "Oops! It looks like ./configure failed."
exit 1
fi
echo "Running make..."
make
if [ "$?" != 0 ] ; then
echo "Oops! It looks like make failed."
exit 1
fi
echo "Running make install..."
make install
if [ "$?" != 0 ] ; then
echo "Oops! It looks like make install failed."
exit 1
fi
echo "Building GUI wrapper..."
cd ../gui
make
if [ "$?" != 0 ] ; then
echo "Oops! It looks like make failed."
exit 1
fi
echo "Installing GUI..."
make install
if [ "$?" != 0 ] ; then
echo "Oops! It looks like make install failed."
exit 1
fi
# Install entry in KDE menu
if test -n "$KDEDIR" ; then
echo "Installing KDE menu entry Internet : TkPPPoE..."
mkdir -p "$KDEDIR/share/applnk/Internet"
cat <<EOF > "$KDEDIR/share/applnk/Internet/tkpppoe.kdelnk"
# KDE Config File
[KDE Desktop Entry]
Name=TkPPPoE
Comment=Start/Stop PPPoE connections
Exec=tkpppoe
Terminal=0
Type=Application
EOF
fi
# Install entry in GNOME menus
GNOMEDIR=`gnome-config --datadir 2>/dev/null`
if test -n "$GNOMEDIR" ; then
echo "Installing GNOME menu entry Internet : TkPPPoE..."
mkdir -p "$GNOMEDIR/gnome/apps/Internet"
cat <<EOF > "$GNOMEDIR/gnome/apps/Internet/tkpppoe.desktop"
[Desktop Entry]
Name=TkPPPoE
Comment=Start/Stop PPPoE connections
Exec=tkpppoe
Terminal=0
Type=Application
EOF
fi
echo "Running GUI configuration tool..."
tkpppoe &
exit 0