Where's the Source?
October 24, 2006 7:54 AM   Subscribe

I am a Linux newbie. I just installed Fedora Core 5 and I'm looking for the source.

I've been told the source code to the OS always comes with Linux. During the part of the install where you get to choose what gets installed and what doesn't, I opted to install everything. Yet, I cannot seem to find the kernel source code anywhere. Can someone tell me where it's supposed to be or how I can find it? Apologies for the beginner question.
posted by iconjack to Computers & Internet (7 answers total)
I can't tell you whether the FC5 "Everything" install includes the kernel source, but if it does, you should find it in the /usr/src directory. Often, when you install the kernel source, it's included as a compressed tarball (.tar.bz2 file) within /usr/src, so you may have to open that up first.

If the source isn't included in the install by default, it may be packaged separately - you can use the package manager tool to add it, then look in /usr/src as above.

Sorry this isn't more FC-specific, but it should hold true for you.
posted by pocams at 8:00 AM on October 24, 2006

Check /usr/src/kernel. That's the usual place for it to be installed on a redhat system.

OTOH, since Fedora is a binary distro (everything's distributed in packages called RPMs), you might need to download the Source RPMs for the kernel (usually referred to as SRPM) and use the RPM package manager to install the source, which will then be either in /usr/src/redhat or /usr/src/kernel.
posted by SpecialK at 8:04 AM on October 24, 2006

I've been told the source code to the OS always comes with Linux.

Actually, I believe the GPL only requires that the source code be made available upon request, not actually provided with every binary distribution.
posted by dcjd at 8:07 AM on October 24, 2006

Best answer: I found this on the first google link (search query: kernel source red-hat fedora core 5):

I was dealing with a similar issue this morning and read the the FC 5 does not ship with the source code on its CDs.

I went the the website and was able to download the source and install it using the rpm command. Here is a link that walks you through it for FC4 and it seemed to work fine for me for FC5:
at the bottom of the above link it walks you through the commands needed.

And this link got me to the source code I needed for the core:

posted by j at 8:09 AM on October 24, 2006

This has instructions for not only downloading the source but also for compiling your own custom kernel if you choose to do so. This was written for FC4 but it can be easily modified for FC5.

You can also grab kernel sources from kernel.org which has the vanilla sources as well as some modified ones like Alan Cox's kernel.
posted by chrisroberts at 8:16 AM on October 24, 2006

New installs rarely include the source code of anything, for space/bandwidth reasons.


Debian net install disk (Everything you need to get started, downloads rest of system to install): 112Mb, which is 1/6th of one CD

Debian total install disks, all packages available: 15 CDs

Debian source CDs, source of all applications: 15 *more* CDs

So probably you have not got the source to various applications installed. The Linux kernel source (the heart of Red Hat) is available using the Red Hat package manager to download and install it, or you can get it from kernel.org. (Note: if you're going to try to use it, you should use the Red Hat RPM version. If you just want to study it, the one from kernel.org will be fine.)
posted by jellicle at 8:16 AM on October 24, 2006

What's wrong with running a vanilla kernel?
posted by Captain_Tenille at 11:25 AM on October 24, 2006

« Older Travel and money in the UK   |   I need a custimized webform. Newer »
This thread is closed to new comments.