Compiling software from source code
Q I am very new to Linux, although there do seem to be some similarities to the Amiga of years past. After a few attempts I have finally installed Fedora, dual booting with Win XP. I have tried to install FreeBasic, with no success so far! It does not seem to recognise ./configure and other instructions.
A One significant difference between Linux shells and the Amiga shell is that Linux does not include the current directory in the path by default, whereas AmigaDOS did. The Linux way is more secure, but it means you have to specify the path when running a script or program from the current directory. The current directory is denoted by '.' so ./configure means "run the program or script called configure in the current directory" It should now be clear that the command ./configure only works when the file configure exists in the current directory. Compiling from source usually involves unpacking the tarball, changing to the directory created by the previous step and running ./configure, followed by make and make install -something like this:
tar xf foo-1.2.3.tar.gz cd foo-1.2.3 ./configure make make install
While this applies to more than 90% of Linux applications, there are many exceptions. After running cd, look for files called README or INSTALL. These contain specific instructions on compiling and installing that particular application. In the case of FreeBasic, if you want to install from source, you have to do the configure-make-make install dance several times, after downloading two archives. Alternatively, you may have the pre-compiled binary archive - FreeBASIC-v0.16b-linux.tar.gz - which uses a completely different installation method with its own install script. Read the file readme.txt inside this archive for precise details on installation. We ask you to read the file rather than reproduce the instructions here, because there may be subtle changes in the installation process between versions. The readme.txt file should be considered authoritative. Always look for installation instructions when installing from an archive (as opposed to using a distro's package manager), as you are executing commands as root that could have an adverse effect on your system if done incorrectly.
- Uninstall programs compiled from source code
- Install software outside of distro package manager
- Compiling errors on Ubuntu - FlightGear and Toribash
- How to install software from a bz2 file
- Compiling problems - pkg-config search path