Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I find it extremely hard to install software on a Linux machine as a regular user. I don't have root privileges on this machine, so I can't use any package manager system.

For example I'm trying to install a simple IRC client, but installing everything from source is a pain because I have to manually download and install every single dependency on the tree (irssi->glib->ncurses etc.. etc..).

So I downloaded ircii which seems to be the most minimalistic client I can find, it still requires some program called lex which I can't find.

Any easy solutions for this hassling task? Why don't people just deliver binaries that have all I need included in them (sort of like .exes)?

share|improve this question
    
I know this is not the answer you are looking for, but why not to ask from the system administrators if they are willing to install the software you want to use? –  Janne Pikkarainen Aug 30 '10 at 11:11
1  
the owner is on vacation. i just need to install an irc app. this is achievable just fine without root privileges... so it's not a privileges issue... it's just not as easy... maybe there's a way to run packages managers as local users providing an installation path? dunno... i haven't used linux much. –  Luca Matteis Aug 30 '10 at 11:22
    
You can't find lex because the most common implementation is called flex (and predates the adobe product by roughly two decades). –  dmckee Aug 30 '10 at 11:35

7 Answers 7

You might want to take a look at the Nix package manager. Not only is its whole approach to package management very interesting, but the website also claims that it works on every Linux distribution and allows non-privileged users to install software using it. You can find more information as well as a complete list of all available packages (ca. 2500) at http://nixos.org/nix/ .

share|improve this answer

You would think more people would remember multi-user systems and how it's often acceptable to run software from your home directory. Nevertheless, you should confirm it is okay with your host.

If the system does not have the dependencies to compile from source and your administrator will not install them, your best options are as follows:

  • Locate a package compiled for the machine and extract the binary. (This may still fail without the dependencies.)
  • Locate a statically compiled binary for your system. Package or otherwise.
  • Statically compile on a similar machine and copy over
share|improve this answer
Any easy solutions for this hassling task? Why don't people just deliver binaries that have all I need included in them (sort of like .exes)?

At the risk of sounding the snarky, the way to do this is to either

  1. get root privileges
  2. have your sysadmin at your beck and call

I'm assuming the machine you are working on isn't yours, otherwise #1 would be achievable. With that assumption said, if it's my machine that you are working on, I don't want you to be able to install new packages and libraries whenever you want and I want you to come to me to do this unless I really trust you. This is how linux distributions and linux administration is supposed to work.

So... why people just don't deliver binaries? It's most likely due to linux (libraries) being much more module in nature and slightly more fragmented. There isn't a huge core api like win32 that a developer can assure will be there. They have to rely on the explicit libraries they need and specific versions of those libraries to be available at both compile time and runtime in order to successfully distribute their software. This is almost universally true. AFAIK, Windows has the same problem with all but the simplest of exes which just rely on core Windows libraries - you'd have to run an installer with Admin privileges to make registry modifications and install libraries. MacOSX is about the only OS out of the most well known 3 to cover the use case you are talking about, since all .app files are completely self contained and can be installed in a user's $HOME and work just fine.

share|improve this answer
1  
even linux binaries could be statically linked and distributed with all they need inside, just like .app –  Luca Matteis Aug 30 '10 at 11:19
1  
@Luca: Yes, that's true. But .APPs only need to run on Macs -- a very tightly controlled platform. Maintainers probably wouldn't enjoy building their programs against every single architecture, lib version, gcc version, etc. Source is the "clean" way to distribute. –  jscott Aug 30 '10 at 12:46
    
If you statically compile a binary with a vulnerable or buggy library, updating the system library will not eliminate the binary without recompiling the software. The dynamic design is not a bad thing. –  Warner Aug 30 '10 at 17:06

What about asking the system administrator to give you a sudo account? If properly configured can allow you only to execute some commands as a root user, such as the package manager, so you can install software without root credentials.

share|improve this answer

It is the way it should be, only administrators should administrate machines, and users should only use it.

Anyway if you find a source package wich depends on software already installed you won't need to recompile it.

There are also binaries for linux, but not so many. I recomend you to try to find programs created for interpreted languages. You will find a lot more and the requisite will be a java, python or perl interpreter.

Check also if you have the ability to start wine, if you can, you could run a win32 executable, even install it.

share|improve this answer
    
the fact that only admins can install software is a stupid argument since there's nothing stopping you from installing all the software that you want... it's just not as easy as using a package manager... and only admins have access to it –  Luca Matteis Aug 30 '10 at 11:25
    
Only admins can install software. However any user can run software. Running make, auto-tools, gcc and all the tools to make an elf binary and running that binary its not installing software. You can download an exe to your desktop on that other OS and run from there, but that software isn't installed. –  theist Aug 30 '10 at 14:20
    
that reminded me wine, added to my answer. –  theist Aug 30 '10 at 14:28

You could set up the same version of your Linux in a virtual machine and try building a static version of your app. Then you just transfer it to your home directory on the server and it shall run (assuming you can execute programs from your home directory, this is not always possible, sometimes /home lives on a filesystem mounted with noexec option for security reasons).

share|improve this answer

It occurs to me that you probably have emacs installed, which means that you have a hosted "OS" with it's own package manager that you can use from user space.

Package supports erc, and I am sure there are other emacs IRC clients.

'Course, if you're not an emacs guy, this won't be what you want to hear.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.