Link to home
Start Free TrialLog in
Avatar of rlivings
rlivings

asked on

installation location

Hi, When i install applications in linux where do i normally put them?  Where would i install them if i am a su and want everyone to be able to access the program? where would i put them if i am just a user and only want it for myself? and can you explain why please?  

thanks
Avatar of psimation
psimation
Flag of South Africa image

Well, it doesn't really matter. The more important factor here is the permissions on the apllication, which will eventually dictate who get's to run it and who not.
There are a couple of "default" folders meant for installations by hand, like /usr/local ( most people opt to install to a folder under that tree cause then they know where all their apps are, but You can choose any, and even make your own, just as long as you stick with your convention, otherwise you will find it  very difficult to find your way around.
These are of course all for "manual" builds, where you typicallly download the package as a xxx.tar.gz, and then have to unpack and ./configure, make, make install and you would then usually use the --path= statement with the configure command to tell it where to install to..
If however you elect to install the package via rpm ( if the package is distributed in rpm and you have ReHat or Manrake), then the folder locations are taken care of for you by the system, and all executables are placed in the /usr/bin or /usr/sbin(for root only execution) depending on the type of application.

To get back to the permissions.
If you are root and want to give all access to an app, build it to say /usr/local/appname and then just make sure that the application executable has the correct permissions for everyone to execute it.
If you are a user and just want yourself to be ablt to execute ( and root of course, cause root can do everything anyway...), then the easiest is to build the program and install it in a folder only you have access to, typically such a folder would be your "home" folder. If you want to give certain users rights to run, you must be root and then give permissions to that specific "group" of users by creating a new group and making those specific users part of the group with execute permissions.
Avatar of rlivings
rlivings

ASKER

psimation, can you give me an example of using the path statement with ./configure?
ASKER CERTIFIED SOLUTION
Avatar of psimation
psimation
Flag of South Africa image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
thanks for the help