On 26-Sep-01 Ricardo Campos wrote:
OK, so I've symlinked Kgcc to gcc, but how does a program know where to look for gcc in the first place? Is it your 'path'?
in my .bashrc file ( could this go in .profile, I shall have to play) I have the following lines
PATH=$PATH:/opt/kde2/bin/:~/bin/ export PATH
this inludes the directories
/opt/kde2/bin/
and
~/bin/
which translates as
/home/this_user_name/bin
to the path. I specifically dont have ./ in the pathe so that I execute programs in the currrent directory without explisitly stating.
I'm saying this as I'm going to be compiling a Python prgram, but have had no experience in doing so. One of the prereqs is: "make sure Python is in your path". I guess that this is what an NT user would consider an environment variable? Or does it just mean that you have to be in the same dir. ? (seems unlikely) If it is a user env. variable, where is it to be found?
Bingo You guessed right first time its an enviroment variable
echo $PATH
will show you the value of the PATH, I dont know yet the command to print out all the current environment variables, but I do know where to look to write the C code to do it anyone else know how to list all the enviroment variables without resorting to code please?
All this information is bash shell specific and is different if you chose to use a different shell. Unlike windows command.com shell, unix's have multiple shells so you can try out others if you need though I have never stepped beyond bash as its good enough though the korn shell is popular and runs under windows I belive. All the theory of what happens is the same but the syntax is different for other shells.
Regards
Owen Synge
Date: 26-Sep-01 Time: 12:37:21