PATH confusion (using cmake)

I’m trying to compile raptor-menu and installed cmake via YaST but can’t run it from konsole. It’s installed into /usr/share/kde4/apps and apparently that’s not in my $PATH. I tried adding it to /etc/profile but couldn’t get it to work.

I’m coming from Ubuntu and am having some funny stuff going on with my paths. For example:

cd /etc
kdesu kwrite profile

This will attempt to open ‘profile’ in /home/username, not in /etc.
I’m also having similar problems with ‘sudo’ not finding apps. I guess this is a problem with the root PATH??

Any help would be greatly appreciated!

The contents of the PATH variable is only used to find programs you call. In your case **profile (**the file to be edited) in not a program to be executed (**kdesu **is that program). So whatever goes wrong in finding the file **profile **has nothing to do with your PATH.

Yeah I know, but /etc/profile dictates the PATH variable right?
I was trying to add /usr/share/kde4/apps to my PATH variable so that I don’t have to type /usr/share/kde4/apps/cmake when I want to run it. Seems a bit strange for PATH to NOT point to the installed apps directory.

I should’ve looked closer. /usr/share/kde4/apps/cmake is just a directory. Apparently, cmake didn’t install even though I checked it. Reinstalling it now. This should work. Thanks for the help!

When you talk about “my PATH” I interprete this as the PATH for an individual user. That should go in the startscript for the particular shell (profile, bashrc) in your home directory.

When you want to do this for all users this should go in /etc/profile.