3 # WindowMaker configuration and compilation script.
5 # Copyright (c) 1997, 1998 Alfredo K. Kojima
8 export LINGUAS
;LINGUAS
=""
9 if test "$NLSDIR" = ""; then
10 export NLSDIR
;NLSDIR
="/usr/lib/locale"
18 echo "Type <Return> to continue"
26 echo "Window Maker installation failed or aborted by user."
32 trap "echo Window Maker installation aborted. ; exit 1" 2 3
35 echo "========================="
36 echo "Window Maker Installation"
37 echo "========================="
39 echo "NOTE: If this script fails, read the INSTALL file and"
40 echo "install by hand."
42 echo "Please read the INSTALL and FAQ files before e-mailing "
43 echo "questions. (we are lazy to reply questions already answered "
44 echo "there as much as you are lazy to read these ;) "
46 echo "Did you read the INSTALL file?"
49 if [ "$rtfm" != y
]; then
50 echo "Please read the INSTALL file before installing"
56 if [ "$rtfm" != y
]; then
57 echo "Please read the INSTALL file before installing"
61 if test "$USER" != "root"; then
63 echo "Warning: you must run this script as root to install"
64 echo "Window Maker. Hit <Control>-<C> to quit this script."
71 echo "Option Selection"
72 echo "================"
74 ######################## KDE
76 echo "Do you want KDE support?"
79 if [ "$kde" = y
-o "$kde" = Y
]; then
80 OPTIONS
="$OPTIONS --enable-kde"
81 echo "Do you want to disable features that become duplicated with"
82 echo "KDE support (like root menus)?"
85 if [ "$lite" = y
-o "lite" = Y
]; then
86 OPTIONS
="$OPTIONS --enable-lite"
90 ######################## GNOME
92 echo "Do you want GNOME support?"
95 if [ "$gnome" = y
-o "$gnome" = Y
]; then
96 OPTIONS
="$OPTIONS --enable-gnome"
99 ######################## NLS
101 echo "Do you want National Language Support?"
105 if [ "$NLS" = "y" -o "$NLS" = "Y" ]; then
107 echo "The supported locales are:"
108 ling
=` (cd po; /bin/ls *.po) `
111 lname
=`(cd po; grep Language-Team $l|cut -f 2 -d: |cut -f 2 -d\ )`
113 lcode
=`basename $l .po`
114 ALL_LINGUAS
="$ALL_LINGUAS $lcode"
117 echo "Type in the locales you want (all will install everything) [none]"
119 if test "$foo" = "all"; then
120 LINGUAS
="$ALL_LINGUAS"
124 echo "Selected locales are: $LINGUAS"
127 for i
in $LINGUAS; do
129 for b
in $ALL_LINGUAS; do
130 if test "$b" = "$i"; then
135 if test "$ok" = "0"; then
137 echo "$i is not a supported locale"
142 if [ "$MB" = "" -a "$i" = "ja" -o "$i" = "kr" ]; then
144 echo "A language you selected needs multi-byte character support"
145 echo "Do you want to enable it?"
148 if [ "$MB" = "y" -o "$MB" = "Y" ]; then
149 OPTIONS
="$OPTIONS --enable-kanji"
154 echo "Where do you want to put the message files? [$NLSDIR]"
157 if test "x$foo" != "x"; then
161 ##################### Installation path
164 while [ $done = 0 ]; do
166 echo "Where do you want to install Window Maker? [$PREFIX]"
167 echo "Don't change it if you don't know what you're doing."
168 if test "$USER" != "root"; then
169 echo "Make sure to specify a path where you have write permission."
171 echo "(The default will put Window Maker in $PREFIX/bin, $PREFIX/lib etc.)"
174 if test "x$foo" != "x"; then
175 if [ "$foo" = "y" -o "$foo" = "n" ]; then
177 echo "Hmm... I don't think you really want to install Window Maker into \"$foo\""
187 echo " $PREFIX/bin must be in the PATH environment variable of all users"
188 echo "will who use Window Maker"
189 echo " Make sure $PREFIX/lib is in the /etc/ld.so.conf file"
193 OPTIONS
="$OPTIONS --prefix=$PREFIX"
197 ##################### Configure
198 echo "--------------------------"
199 echo "Configuring Window Maker..."
200 echo "--------------------------"
201 if [ `uname -s` = "SCO_SV" ]; then
202 echo "CFLAGS=\"$CFLAGS -belf -DANSICPP\" ./configure $OPTIONS"
204 CFLAGS
="$CFLAGS -belf -DANSICPP"
206 perform .
/configure
$OPTIONS
208 echo "CFLAGS=\"$CFLAGS $GCCFLAGS\" ./configure $OPTIONS"
210 CFLAGS
="$CFLAGS $GCCFLAGS"
212 perform .
/configure
$OPTIONS
216 #################### Compile
217 echo "-------------------------"
218 echo "Compiling Window Maker..."
219 echo "-------------------------"
220 (cd src
; perform
make clean
)
223 echo "--------------------------"
224 echo "Installing Window Maker..."
225 echo "--------------------------"
229 if [ `uname -s` = "Linux" ]; then
234 echo "Installation Finished!"
236 echo "Now, each user that wishes to use WindowMaker must run the wmaker.inst"
237 echo "script that was just installed."
240 if test "$NLS" = "Y"; then
241 echo "Don't forget to set the LANG environment variable to your locale"