Hello all,
Ihave the following script, called as tst. When the script is executed as,
tst, then every thing is okay, but when it is executed as . tst, then I get the error:-
sh: SHLIB_PATH: Parameter not set.
I need to use the following format that is
. .profile, as in above case as . tst
The reason why I am doing above is because the SHLIB_PATH is not set properly, I get
heaps of problems. If the SHLIB_PATH is not set, I just want to set it to say $HOME.
Please reply as this is urgent.
Thanks and Regards,
Raja
======================================
The script follows:-
#!/bin/sh
#
echo
echo
echo Start Test
echo
echo uname -a = `uname -a`
echo First check what happens if you try and set SHLIB_PATH
echo and there is no initial setting
unset SHLIB_PATH
echo First what is its value?
echo SHLIB_PATH = $SHLIB_PATH
echo Now lets set it to default:123
SHLIB_PATH="$SHLIB_PATH:123"
echo OK what is the value now?
echo SHLIB_PATH = $SHLIB_PATH
echo
echo Now lets reset the value to nothing
unset SHLIB_PATH
echo Check value
echo SHLIB_PATH = $SHLIB_PATH
echo Now do what is in our script....
if [ -z "${SHLIB_PATH}" ]; then
echo It has no current default value
SHLIB_PATH="${HOME}"
else
echo It has a default path of $SHLIB_PATH
SHLIB_PATH="${HOME}:${SHLIB_PATH}"
fi
echo So what is our final result?
echo SHLIB_PATH = $SHLIB_PATH
Get 250 color business cards for FREE!
http://businesscards.lycos.com/vp/fastpath/
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Viraj Luthra
INET: [EMAIL PROTECTED]
Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
San Diego, California -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).