Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm trying to understand the rational behind installing from software from source in Ubuntu 12.04.

Obviously, I know I can download what I need from repos, but I want to develop a deeper understanding of Linux, hence the question.

I've search all over the place but I can't quite get my head around it. Here's why;

As a windows users, when I download a program I double click it, and it installs into the "program files" directory unless I specify otherwise. When I want to uninstall it, Windows has a tools that does that for me.

When I install a program in Linux, where does it install to? How do I uninstall it afterwards? Are there residual files left over? How would I tell if it's been fully removed?

For instance, I'm going to install LMMS (Linux Multimedia Studio) from source. I download and decompress the tar ball, and have a folder name lmms_XXX.tar (whatever).

The folder is now on my desktop with an install file. If I run the install file from that location, does it install into that folder? If so, can I move that folder to where ever i want? I want thinking about putting it in /opt/lmms

Thank in advance for your help.

share|improve this question
    
Some of your question is addressed in How to understand the Ubuntu file system layout? and What is the equivalent to the Windows “Program Files” folder? (Where do things go when I install them?) (and various other duplicates and similar questions that can be found under the "Linked" and "Related" lists on the right side of the page when you go to those two. (This isn't a duplicate though.) –  Eliah Kagan Jul 21 '13 at 2:41

1 Answer 1

You might compile from source code if the program you want is not available in the repositories; if the latest version isn't available; or if you wanted to modify or patch the source code for a particular purpose.

Most but not all programs are installed to run from /usr/bin; some from /usr/sbin; some even elsewhere. When you compile form source code, the last few lines after you execute the install script will indicate where it installed.

To remove a program installed from the repositories:

sudo apt-get remove some_program

To remove the program and configuration files:

sudo apt-get purge some_program

To remove a program installed from source code:

cd Desktop/lmms_XXX
sudo make uninstall

There may be variations and the INSTALL file usually included with source code explains it.

Since source code is written for many kernel versions and many different Linux distributions, it doesn't always go perfectly.

Unless you are certain there is something you need in the tar.gz, I assume 0.4.15, I strongly suggest the repo version:

sudo apt-get install lmms lmms-common

It installs 0.4.14.

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.