Details Ticket 922


Comment | Reply | Take | Open


Serial Number 922
Subject NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)
Area bug
Queue grass
Requestors marc.saric@mpi-dortmund.mpg.de
Owner none
Status resolved
Last User Contact Tue Mar 14 00:50:19 2006 (2 yr ago)
Current Priority 30
Final Priority 70
Due No date assigned
Last Action Tue Mar 14 00:50:23 2006 (2 yr ago)
Created Tue Feb 19 14:38:36 2002 (7 yr ago)

Transaction History Ticket 922


Tue, Feb 19 2002 14:38:36    Request created by guest  
Subject: NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)

Platform: Linux/Intel
Linux distro: SuSe
linux cpu: Intel (i486, i586, pentium ...)
Xwindows version: Xfree 4.0.x
Xwindows manager: KDE 2.x
TclTk version: tcl/tk 8.3
grass downloaded at: Trento site
grass binary for platform: Linux/Intel binaries

Two small glitches:

1. Installation was ok with the script, but nviz complained about not having
access to libtk.so and libtcl.so, I had to link the most recent libtk8.3.so and
libtcl8.3.so to the before mentioned files in /usr/lib (GRASS itself was not
affected, only nviz).

2. I use a network-wide login on my machine which utilized YP which in turn needs
a shell called "msh" as login-shell. msh is (at least here) a link to /bin/bash.
Because msh itself is unknown to the ~grass5/etc/Init.sh-script, it fails to
set the environment and the grass-console does not work properly (the tcl-surface
is not affected).

I solved the problem by adding a msh-case in Init.sh which does the same as bash
(ok this is a hack :-) ). 

Maybe these are problems on my side, but all other programs work well with this
construction, except grass5, so maybe you wan't to change it.

Thanks in advance!

Thu, Feb 28 2002 10:31:47    Mail sent by mneteler  
Hi,

are you able to provide an update for Init.sh for
your msh shell? Then we can extend the script.

Best regards

 Markus
Thu, Feb 28 2002 11:21:37    Mail sent by marc.saric@mpi-dortmund.mpg.de  
Return-Path <marc.saric@mpi-dortmund.mpg.de>
Delivered-To grass-bugs@lists.intevation.de
Message-ID <3C7E049E.8050809@mpi-dortmund.mpg.de>
Date Thu, 28 Feb 2002 11:21:18 +0100
From Marc Saric <marc.saric@mpi-dortmund.mpg.de>
Organization Max Planck Institut =?ISO-8859-15?Q?f=FCr?= molekulare Physiologie
User-Agent Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204
X-Accept-Language de, el, ja, zh
MIME-Version 1.0
To Markus Neteler via RT <grass-bugs@intevation.de>
Subject Re: [bug #922] (grass) NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)
References <20020228093148.23AF4139CA@lists.intevation.de>
Content-Type multipart/mixed; boundary="------------030206000304060404030306"
X-Scanner exiscan *16gNgc-0002ja-00*.1Nwwoz2xys*
X-Spam-Status No, hits=0 required=5 tests=
This is a multi-part message in MIME format.
--------------030206000304060404030306
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Markus Neteler via RT wrote:
> Hi,
> 
> are you able to provide an update for Init.sh for
> your msh shell? Then we can extend the script.

I appended my Init.sh, you'll find my changes if you search for "msh".

This will not work if you use another shell instead of bash as your msh, 
maybe there is a better mechanism for that (it would work if one could 
resolve the link "msh" is pointing to and use the name of that binary 
instead).

Or set the SHELL variable explicitly or interactively and disregard tha 
automatic stuff.

Hope it helps.

-- 
Bye,  Marc Saric

Max-Planck-Institut fuer molekulare Physiologie
Otto-Hahn-Str.11  44227 Dortmund  phone:0231/133-2168

--------------030206000304060404030306
Content-Type: application/x-sh;
 name="Init.sh"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="Init.sh"

#! /bin/sh
#############################################################################
#
# $Id: init.sh,v 1.34.2.8 2002/01/07 14:09:09 markus Exp $
#
# MODULE:   	Grass Initialization
# AUTHOR(S):	Original author unknown - probably CERL
#               Andreas Lange - Germany - andreas.lange@rhein-main.de
#   	    	Huidae Cho - Korea - hdcho@geni.knu.ac.kr
#   	    	Justin Hickey - Thailand - jhickey@hpcc.nectec.or.th
#   	    	Markus Neteler - Germany - neteler@geog.uni-hannover.de
# PURPOSE:  	The source file for this shell script is in
#   	    	src/general/init/init.sh. It sets up some environment
#   	    	variables and the lock file. It also parses any remaining
#   	    	command line options for setting the GISDBASE, LOCATION, and/or
#   	    	MAPSET. Finally it starts grass with the appropriate user
#   	    	interface and cleans up after it is finished.
# COPYRIGHT:    (C) 2000 by the GRASS Development Team
#
#               This program is free software under the GNU General Public
#   	    	License (>=v2). Read the file COPYING that comes with GRASS
#   	    	for details.
#
#############################################################################
: ${GISBASE?}

# Set the GIS_LOCK variable to current process id
lockfile=$HOME/.gislock5
GIS_LOCK=$$
export GIS_LOCK

# Set PATH to GRASS bin, ETC to GRASS etc
ETC=$GISBASE/etc
PATH=$GISBASE/bin:$GISBASE/scripts:$PATH:$GRASS_ADDON_PATH
export PATH

# Set LD_LIBRARY_PATH.  For GRASS 5.0 we don't depend on this much, though
# r.in.gdal may use it to find some things.  Over time we intend to put
# more GRASS related shared libraries in $GISBASE/lib.
# first search local libs, then in GRASS lib/
if [ ! "$LD_LIBRARY_PATH" ] ; then
  LD_LIBRARY_PATH=$GISBASE/lib
  export LD_LIBRARY_PATH
else
  LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$GISBASE/lib
fi

# Check for concurrent use
$ETC/lock $lockfile $$
case $? in
    0) ;;
    1)
    	echo `whoami` is currently running GRASS. Concurrent use not allowed.
    	exit ;;
    *)
    	echo Unable to properly access $lockfile
    	echo Please notify system personel.
    	exit ;;
esac

# Once the new environment system is committed we can delete these lines
# Export the PAGER environment variable for those who have it set
if [ "$PAGER" ] ; then
    export PAGER
fi

# Set some environment variables if they are not set
if [ ! "$GRASS_PAGER" ] ; then
    if [ -x /bin/more ] ; then
        GRASS_PAGER=more
    else 
        GRASS_PAGER=less
    fi
    export GRASS_PAGER
fi

if [ ! "$GRASS_TCLSH" ] ; then
    GRASS_TCLSH=tclsh
    export GRASS_TCLSH
fi

if [ ! "$GRASS_WISH" ] ; then
    GRASS_WISH=wish
    export GRASS_WISH
fi

if [ ! "$GRASS_GNUPLOT" ] ; then
    GRASS_GNUPLOT="gnuplot -persist"
    export GRASS_GNUPLOT
fi

# First time user - GISRC is defined in the grass script
if [ ! -f $GISRC ] ; then
    cat $ETC/grass_intro
    echo
    echo "Hit RETURN to continue"
    read ans
    
    # This is a hack for not having a good initial gui - should be removed
    # with next version of initialization gui
    GRASS_GUI="text"
fi

echo "Starting GRASS ..."

# Check if we are running X windows by checking the DISPLAY variable
if [ "$DISPLAY" ] ; then

    # Check if we need to find wish
    if [ "$GRASS_GUI" = "tcltk" ] ; then

	# Search for a wish program
	WISH=

	for i in `echo $PATH | sed 's/^:/.:/
    	    	    		    s/::/:.:/g
				    s/:$/:./
				    s/:/ /g'`
	do
	    if [ -f $i/$GRASS_WISH ] ; then
    		WISH=$GRASS_WISH
		break
	    fi
	done

	# Check if wish was found
	if [ "$WISH" ] ; then

	    # Set the tcltkgrass base directory
	    TCLTKGRASSBASE=$GISBASE/tcltkgrass
	    export TCLTKGRASSBASE
	else

	    # Wish was not found - switch to text interface mode
	    echo 
    	    echo "WARNING: The wish command ($GRASS_WISH) was not found!"
	    echo "Please check your GRASS_WISH environment variable."
	    echo "Use the -help option for details."
	    echo "Switching to text based interface mode."
	    echo
	    echo "Hit RETURN to continue."
	    read ans

	    GRASS_GUI="text"
	fi
    fi
else
    
    # Display a message if a graphical interface was expected
    if [ "$GRASS_GUI" != "text" ] ; then
        # Set the interface mode to text
    	echo
	echo "WARNING: It appears that the X Windows system is not active."
	echo "A graphical based user interface is not supported."
	echo "Switching to text based interface mode."
	echo
	echo "Hit RETURN to continue"
	read ans

        GRASS_GUI="text"
    fi
fi

# Save the user interface variable in the grassrc file - choose a temporary
# file name that should not match another file
if [ -f $GISRC ] ; then
    awk '$1 !~ /GRASS_GUI/ {print}' $GISRC > $GISRC.$$
    echo "GRASS_GUI: $GRASS_GUI" >> $GISRC.$$
    mv -f $GISRC.$$ $GISRC
fi

# Parsing argument to get LOCATION
if [ ! "$1" ] ; then

    # Try interactive startup
    LOCATION=
else

    # Try non-interactive startup
    L=
    
    if [ "$1" = "-" ] ; then
    
    	if [ "$LOCATION" ] ; then
    	    L=$LOCATION
    	fi
    else
    	L=$1
    
    	if [ `echo $L | cut -c 1` != "/" ] ; then
    	    L=`pwd`/$L
    	fi
    fi

    if [ "$L" ] ; then
    	MAPSET=`basename $L`
    	L=`dirname $L`
    
    	if [ "$L" != "." ] ; then
    	    LOCATION_NAME=`basename $L`
    	    L=`dirname $L`
    
    	    if [ "$L" != "." ] ; then
    	    	GISDBASE=$L
    	    fi
    	fi
    fi

    if [ "$GISDBASE" -a "$LOCATION_NAME" -a "$MAPSET" ] ; then
    	LOCATION=$GISDBASE/$LOCATION_NAME/$MAPSET
    
    	if [ ! -r $LOCATION/WIND ] ; then
    	    echo "$LOCATION: No such location"
    	    exit
    	fi
    	export GISDBASE LOCATION_NAME MAPSET
    
    	if [ -s $GISRC ] ; then
    	    sed -e "s|^GISDBASE:.*$|GISDBASE: $GISDBASE|; \
    	    	s|^LOCATION_NAME:.*$|LOCATION_NAME: $LOCATION_NAME|; \
    	    	s|^MAPSET:.*$|MAPSET: $MAPSET|" $GISRC > $GISRC.$$
    
    	    if [ $? -eq 0 ] ; then
    	    	mv -f $GISRC.$$ $GISRC
    	    else
    	    	rm -f $GISRC.$$
    	    	echo "Failed to create new $GISRC"
    	    	LOCATION=
    	    fi
    	else
    	    echo "GISDBASE: $GISDBASE" > $GISRC
    	    echo "LOCATION_NAME: $LOCATION_NAME" >> $GISRC
    	    echo "MAPSET: $MAPSET" >> $GISRC
    	fi
    else
    	echo "GISDBASE, LOCATION_NAME and MAPSET variables not set properly."
    	echo "Interactive startup needed."
    	exit
    fi
fi

# User selects LOCATION and MAPSET if not set
if [ ! "$LOCATION" ] ; then
    
    case "$GRASS_GUI" in
    	
	# Check for text interface
	text)
	    $ETC/set_data
    	    
	    case $? in
     	    	0) ;;
     	    	*) 
		    # Check for an invalid GISRC file
		    if [ -f $GISRC ] ; then
			VALUE=`grep "GISDBASE" $GISRC`
			if [ "$VALUE" = "" ] ; then
    			    echo "Invalid resource file, removing $GISRC" 
			    rm -f $GISRC
			fi
		    fi
		    
		    exit
		    ;;
    	    esac
	    
	    eval `g.gisenv`
	    ;;
	
	# Check for tcltk interface
	tcltk)
	    eval `$WISH -file $TCLTKGRASSBASE/script/gis_set.tcl`
	    
	    case $? in
     	    	1)
		    # The gis_set.tcl script printed an error message so wait
		    # for user to read it
		    echo "Error in Tcl/Tk startup. If necessary, please"
		    echo "report this error to the Grass developers."
		    echo "Switching to text mode now."
		    echo "Hit RETURN to continue..."
		    read ans
		    
		    GRASS_GUI="text"

                    if [ -f $GISRC ] ; then
                        awk '$1 !~ /GRASS_GUI/ {print}' $GISRC > $GISRC.$$
                        echo "GRASS_GUI: $GRASS_GUI" >> $GISRC.$$
                        mv -f $GISRC.$$ $GISRC
                    fi

		    $ETC/set_data

		    case $? in
     	    		0) ;;
     	    		*) 
			    # Check for an invalid GISRC file
			    if [ -f $GISRC ] ; then
				VALUE=`grep "GISDBASE" $GISRC`
				if [ "$VALUE" = "" ] ; then
    				    echo "Invalid resource file, removing $GISRC" 
				    rm -f $GISRC
				fi
			    fi

			    exit
			    ;;
    		    esac
	    
		    eval `g.gisenv`
		    ;;
	    
     	    	0)
		    # These checks should not be necessary with real init stuff
		    if [ "$LOCATION_NAME" = "##NONE##" ] ; then
    	    		$ETC/set_data
    	    		if [ $? != 0 ]; then
    	    		    echo "GISDBASE: $OLD_DB" > $GISRC
    	    		    echo "LOCATION_NAME: $OLD_LOC" >> $GISRC
    	    		    echo "MAPSET: $OLD_MAP" >> $GISRC
    	    		    exit
    	    		fi
    	    		eval `g.gisenv`
    		    fi

		    if [ "$LOCATION_NAME" = "##ERROR##" ] ; then
    	    		echo "The selected location is not a valid GRASS location"
    	    		exit
		    fi

		    ;;
		    
		*)
		    echo "ERROR: Invalid return code from gis_set.tcl."
		    echo "Please advise GRASS developers of this error."
		    ;;
    	    esac
	    
	    ;;
	*)
	    # Shouldn't need this but you never know
	    echo "ERROR: Invalid user interface specified - $GRASS_GUI."
	    echo "Use the -help option to grass for valid interfaces."
	    exit
	    ;;
    esac
fi

LOCATION=${GISDBASE?}/${LOCATION_NAME?}/${MAPSET?}
export LOCATION

trap "" 2 3
CYGWIN=`uname | grep CYGWIN`

# cygwin has many problems with the shell setup
# below, so i hardcoded everything here.
if [ "$CYGWIN" ] ; then
    sh="cygwin"
    shellname="GNU Bash (Cygwin)"
    SHELL=/usr/bin/bash.exe
else 
# msh-hack by Marc Saric 2002/02/19, GRASS does not
# recognize the YP-shell msh (actually a link to /bin/bash)
# and fails to set the correct environment.
# If your msh is NOT bash, change the apropriate lines 
# below and in the second case-construct.
    sh="`basename $SHELL`"
    case "$sh" in
        ksh)  shellname="Korn Shell";;
        csh)  shellname="C Shell" ;;
        tcsh) shellname="TC Shell" ;;
        bash) shellname="Bash Shell" ;;
	msh)  shellname="MShell (a hack, see ~/grass5/etc/Init.sh)!" ;;
        sh)   shellname="Bourne Shell";;
        *)    shellname=shell;;
    esac
fi

# Start the chosen GUI but ignore text
case "$GRASS_GUI" in
    
    # Check for tcltk interface
    tcltk)
        $GISBASE/bin/tcltkgrass &
	;;
    
    # Ignore others
    *)
    	;;
esac

# Display the version and license info
tput clear

echo "Welcome to GRASS 5.0.0pre3 (January 2002) "
echo
echo "Geographic Resources Analysis Support System (GRASS) is Copyright,"
echo "1999-2002 by the GRASS Development Team, and licensed under terms of the"
echo "GNU General Public License (GPL)."
echo 
echo "This GRASS 5.0.0pre3 release is coordinated and produced by the"
echo "GRASS Development Team headquartered at ITC-irst (Trento, Italy) with"
echo "worldwide support and further development sites located at Baylor"
echo "University and the University of Illinois (U.S.A.)."
echo 
echo "This program is distributed in the hope that it will be useful, but"
echo "WITHOUT ANY WARRANTY; without even the implied warranty of"
echo "MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU"
echo "General Public License for more details."
echo 
echo "This version running thru the $shellname ($SHELL)"
echo "Help is available with the command:      g.help"
echo "See the licence terms with:              g.version -c"

if [ "$GRASS_GUI" = "text" ] ; then
    echo "Start the graphical user interface with: tcltkgrass&"
else
    echo "If required, restart the graphical user interface with: tcltkgrass&"
fi

echo "When ready to quit enter:                exit"

case "$sh" in

csh|tcsh)
    USERHOME=$HOME      # save original home
    HOME=$LOCATION
    export HOME
    cshrc=$HOME/.cshrc
    tcshrc=$HOME/.tcshrc
    rm -f $cshrc $tcshrc
    echo "set home = $USERHOME" > $cshrc
    echo "set history = 500 noclobber ignoreeof" >> $cshrc

    echo "set prompt = '\\" >> $cshrc
    echo "Mapset <${MAPSET}> in Location <${LOCATION_NAME}> \\" >> $cshrc
    echo "GRASS 5.0.0pre3 > '" >> $cshrc
    echo 'set BOGUS=``;unset BOGUS' >> $cshrc

    if [ -r $USERHOME/.grass.cshrc ]
    then
	cat $USERHOME/.grass.cshrc >> $cshrc
    fi

    if [ -r $USERHOME/.cshrc ]
    then
	grep '^ *set  *mail *= *' $USERHOME/.cshrc >> $cshrc
    fi

    if [ -r $USERHOME/.tcshrc ]
    then
	grep '^ *set  *mail *= *' $USERHOME/.tcshrc >> $cshrc
    fi

    if [ -r $USERHOME/.login ]
    then
	grep '^ *set  *mail *= *' $USERHOME/.login >> $cshrc
    fi

    echo "set path = ( $PATH ) " | sed 's/:/ /'g >> $cshrc

    cp $cshrc $tcshrc
    $ETC/run $SHELL

    HOME=$USERHOME
    export HOME
    ;;

bash|msh)
    USERHOME=$HOME      # save original home
    HOME=$LOCATION      # save .bashrc in $LOCATION
    export HOME
    bashrc=$HOME/.bashrc
    rm -f $bashrc
    echo "test -z $PROFILEREAD && . /etc/profile" > $bashrc
    echo "test -e ~/.alias && . ~/.alias" >> $bashrc
    echo "umask 022" >> $bashrc
    echo "PS1='GRASS:\w > '" >> $bashrc

    if [ -r $USERHOME/.grass.bashrc ]
    then
        cat $USERHOME/.grass.bashrc >> $bashrc
    fi

    echo "export PATH=\"$PATH\"" >> $bashrc
    echo "export HOME=\"$USERHOME\"" >> $bashrc # restore user home path

    $ETC/run $SHELL
    HOME=$USERHOME
    export HOME
    ;;

cygwin)
    USERHOME=$HOME      # save original home
    HOME=$LOCATION      # save .bashrc in $LOCATION
    export HOME
    bashrc=$HOME/.bashrc
    rm -f $bashrc
    # this does not work on cygwin for unknown reasons
    # echo "test -z $PROFILEREAD && . /etc/profile" > $bashrc
    echo "test -e ~/.alias && . ~/.alias" >> $bashrc
    echo "umask 022" >> $bashrc
    echo "PS1='GRASS:\w > '" >> $bashrc

    if [ -r $USERHOME/.grass.bashrc ]
    then
        cat $USERHOME/.grass.bashrc >> $bashrc
    fi

    echo "export PATH=\"$PATH\"" >> $bashrc
    echo "export HOME=\"$USERHOME\"" >> $bashrc # restore user home path

    $ETC/run $SHELL
    HOME=$USERHOME
    export HOME
    ;;

*)

PS1="
Mapset <$MAPSET> in Location <$LOCATION_NAME>
GRASS-GRID > "

    export PS1

    $ETC/run $SHELL
    ;;
esac

trap 2 3

# Grass session finished
tput clear
echo "Cleaning up temporary files....."

($ETC/clean_temp > /dev/null &)
rm -f $lockfile

echo "done"
echo 
echo 
echo 
echo "Goodbye from GRASS GIS"
echo

--------------030206000304060404030306--


Wed, Mar 6 2002 22:48:01    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@lists.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <15494.36446.886538.688051@cerise.nosuchdomain.co.uk>
Date Wed, 6 Mar 2002 21:47:10 +0000
To Request Tracker <grass-bugs@intevation.de>
Cc grass5@grass.itc.it
Subject Re: [GRASS5] [bug #922] (grass) NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)
In-Reply-To <20020219133836.A1EB2139CA@lists.intevation.de>
References <20020219133836.A1EB2139CA@lists.intevation.de>
X-Mailer VM 6.94 under 21.4 (patch 4) "Artificial Intelligence (candidate #1)" XEmacs Lucid
X-Spam-Status No, hits=0 required=5 tests=
Request Tracker wrote:

> 1. Installation was ok with the script, but nviz complained about not
> having access to libtk.so and libtcl.so, I had to link the most recent
> libtk8.3.so and libtcl8.3.so to the before mentioned files in /usr/lib
> (GRASS itself was not affected, only nviz).

We should ensure that Linux binary distributions are correctly
labelled, e.g. "RedHat 6.2 i386 Linux", not just "Linux". A package
with as many dependencies as GRASS is unlikely to work fully on a
distribution which differs from the one on which it was compiled.

> 2. I use a network-wide login on my machine which utilized YP which in
> turn needs a shell called "msh" as login-shell. msh is (at least here)
> a link to /bin/bash. Because msh itself is unknown to the
> ~grass5/etc/Init.sh-script, it fails to set the environment and the
> grass-console does not work properly (the tcl-surface is not
> affected).

This is arguably an installation bug. The fix is to ensure that SHELL
gets set to something which programs will recognise, e.g. by adding
something like:

	if [ "$SHELL" = /bin/msh ] ; then
		SHELL=/bin/bash
		export SHELL
	fi

to /etc/profile. I suspect that GRASS isn't the only program which
does case matching on $SHELL.

OTOH, GRASS should work with unknown shells. The main case statement
has a default case; does anyone know what's wrong with it?

> I solved the problem by adding a msh-case in Init.sh which does the
> same as bash (ok this is a hack :-) ).

You don't need to duplicate the bash case; you can just use "|", e.g.

	bash|msh)
		...

-- 
Glynn Clements <glynn.clements@virgin.net>


Thu, Mar 7 2002 11:02:47    Mail sent by marc.saric@mpi-dortmund.mpg.de  
Return-Path <marc.saric@mpi-dortmund.mpg.de>
Delivered-To grass-bugs@lists.intevation.de
Message-ID <3C873AB8.6060005@mpi-dortmund.mpg.de>
Date Thu, 07 Mar 2002 11:02:32 +0100
From Marc Saric <marc.saric@mpi-dortmund.mpg.de>
Organization Max Planck Institut =?ISO-8859-15?Q?f=FCr?= molekulare Physiologie
User-Agent Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204
X-Accept-Language de, el, ja, zh
MIME-Version 1.0
To Glynn Clements via RT <grass-bugs@intevation.de>
Subject Re: [bug #922] (grass) NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)
References <20020306214801.E8228139CA@lists.intevation.de>
Content-Type text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding 7bit
X-Scanner exiscan *16iujJ-0003lY-00*Z0ezCXBbfQo*
X-Spam-Status No, hits=0 required=5 tests=
Glynn Clements via RT wrote:


> We should ensure that Linux binary distributions are correctly
> labelled, e.g. "RedHat 6.2 i386 Linux", not just "Linux". A package
> with as many dependencies as GRASS is unlikely to work fully on a
> distribution which differs from the one on which it was compiled.

Would be a good idea -on the other hand, it seems that everything (at 
least everything I tried) worked under SuSE 7.3 with the default package.


> This is arguably an installation bug. The fix is to ensure that SHELL

Could be possible.


> to /etc/profile. I suspect that GRASS isn't the only program which
> does case matching on $SHELL.

Most likely, but GRASS was the first program which somehow stumbled over 
this, I haven't found anything else which does not work for this reason 
up to now.


-- 
Bye,  Marc Saric


Tue, Mar 26 2002 11:00:30    Mail sent by mneteler  
Hi,

do we want to change anything in GRASS for msh? If not, let's close
this report.

Markus
Wed, Mar 27 2002 22:37:18    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@lists.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <15522.15197.665114.854524@cerise.nosuchdomain.co.uk>
Date Wed, 27 Mar 2002 21:36:29 +0000
To Markus Neteler via RT <grass-bugs@intevation.de>
Subject Re: [bug #922] (grass) NVIZ and tcl/tk AND Startup-script under Linux (SuSE 7.3)
In-Reply-To <20020326100030.3070E139C9@lists.intevation.de>
References <20020326100030.3070E139C9@lists.intevation.de>
X-Mailer VM 6.94 under 21.4 (patch 4) "Artificial Intelligence (candidate #1)" XEmacs Lucid
X-Spam-Status No, hits=0 required=5 tests=
Markus Neteler via RT wrote:

> do we want to change anything in GRASS for msh? If not, let's close
> this report.

I'm not sure what can be done. $SHELL can be set to just about
anything, and we can only support a finite number of possibilities.

I don't know that we can safely assume that "msh" is actually bash. 
Ultimately, the only thing of which you can be sure is that, if you
execute $SHELL, you'll get the same result as other programs which
execute $SHELL.

-- 
Glynn Clements <glynn.clements@virgin.net>


Sat, Apr 27 2002 13:26:11    Mail sent by bernhard  
I guess we should warn the user if we find
a shell we do not know about.
"Your SHELL variable point to a shell GRASS' start script does not know about.
We will execute the default behvaiour (for bash) anyway,
but it might not work. If you have problems, please adjust Init.sh to work with
your shell or use a different one."

Then we execute the default which should be for GNU bash.
Tue, Mar 14 2006 00:50:19    Mail sent by mneteler  
Marc,

I have added msh (finally!!) to the init script as

cvs diff init.sh
Index: init.sh
===================================================================
RCS file: /grassrepository/grass6/lib/init/init.sh,v
retrieving revision 1.74
diff -u -r1.74 init.sh
--- init.sh     10 Oct 2005 20:34:56 -0000      1.74
+++ init.sh     13 Mar 2006 23:49:01 -0000
@@ -702,7 +702,7 @@
     export HOME
     ;;

-bash)
+bash|msh)
     USERHOME="$HOME"      # save original home
     HOME="$LOCATION"      # save .bashrc in $LOCATION
     export HOME

Closing report.

Markus
Tue, Mar 14 2006 00:50:23    Status changed to resolved by mneteler  
Comment | Reply | Take | Open

You are currently authenticated as guest.
[Show Configuration] [Login as another user]

Users Guide - Mail Commands - Homepage of RequestTracker 1.0.7 - list any request