Compiling software from source code

Common questions with answers. Please look in here if you find the answer to your problem before posting.

Compiling software from source code

Postby StarKnight83 » 25 Oct 2004, 16:56

How-to Compile from source code

All commands are in bold

Unpacking the code (the three most common ways to distribute source
code are by tar.gz, tar.bz2, and source rpms
a) tar.gz tar xvzf foo.tar.gz
b) tar.bz2 tar xvjf foo.tar.bz2

Change directories so the one you just unarchived is the working directory
cd foo

Read through the "README" and "INSTALL" files to see if there is anything
special you need to do before trying to install the software
cat README | less and or cat INSTALL | less

Most software is configurable so check the options to see if there is
anything you want to enable or disable
./configure --help | less

Then configure the source code for your system
./configure if there are any options you wanted to do
append them to the end of the ./configure with a space in-between

If all goes well (no errors or incompatibilities) then you can make the code

Then install the software (it normally installs to /usr/local if your
wondering) also you need to be root to do this final step
su when it asks for passwd type the root password
make install

Now if everything went ok then you should be able to type the programs
name and have it launch from the console

I will edit this file later on to include the SRPM stuff (source rpms)
Also if you see any errors or something that should be removed/added please feel free to pm me. Thanks Joe
Til our paths cross again
User avatar
Posts: 959
Joined: 12 Jul 2004, 16:26
Location: Ft. Wayne, IN; USA

Return to F.A.Q. - F.requently A.sked Q.uestions

Who is online

Users browsing this forum: No registered users and 1 guest