Jump to content

Compiling Linux filesystems

Hello everybody,

I got a question about Linux filesystems (been playing with the Raspberry Pi).
If you want to, for example, make your own distro of linux, you have to get the kernel and add modules to it.
After configuring the modules, you compile all and you've got your own linux distro if you did everything well.

But how about making your own version of, let say Ubuntu? Like, I want to add modules to Ubuntu or, in my case, to Raspbian.
I found several tutorials on how to add modules to the kernel but will it have all features that Ubuntu has atm? (all modules currently in it + the ones I added) Or will it just be the original kernel they used + my added modules?

My goal:
Have the exact raspbian distro as it is available now + 1 extra module (aufs) but because I've never done anything like this before, I am kinda confused.

Thanks for any responses!

Link to comment
Share on other sites

Link to post
Share on other sites

Well, adding and removing modules, making kernel modifications specifically designed to run those modules, coding your own modules from scratch. Starting with Ubuntu as a base and then adding/removing extra features is not how I would do it though. I'd start with a more reliable base like Debian, which makes sense for an Ubuntu-like derivative. 

 

Linux From Scratch is the ultimate way of creating a Linux distribution completely from scratch, starting with the kernel and working your way up. Starting with Ubuntu and sculpting it into something else could leave unneeded clutter behind. 

 

Some reading material if you're really interested: http://www.tuxradar.com/content/how-build-your-own-linux-distro

Interested in Linux, SteamOS and Open-source applications? Go here

Gaming Rig - CPU: i5 3570k @ Stock | GPU: EVGA Geforce 560Ti 448 Core Classified Ultra | RAM: Mushkin Enhanced Blackline 8GB DDR3 1600 | SSD: Crucial M4 128GB | HDD: 3TB Seagate Barracuda, 1TB WD Caviar Black, 1TB Seagate Barracuda | Case: Antec Lanboy Air | KB: Corsair Vengeance K70 Cherry MX Blue | Mouse: Corsair Vengeance M95 | Headset: Steelseries Siberia V2

 

 

Link to comment
Share on other sites

Link to post
Share on other sites

I know but I don't have time to start from scratch (however, if I did I would like to).

My goal is to add the aufs module to the Raspbian distro so I can make the Raspberry Pi power failure proof (or as proof able as can be). I need this for a bigger project and I do not have time (until the next release of our product) to make a distro myself. So my idea was to add this module to Raspbian itself. When I tried to follow some tutorials, they said I had to download the kernel but than I started wondering if I would still have the actual Raspbian modules in it (like GUI,...) and not the bare debian (for Pi) kernel.

So, if I download the kernel of Raspbian and I compile it, will it have all features? This like: can I compile Raspbian myself (or can I compile Ubuntu myself)? If so, is just downloading the "Ubuntu kernel" and compiling it enough to get a fully operational Ubuntu (with all features and stuff)

Link to comment
Share on other sites

Link to post
Share on other sites

This looks like something you're looking for: http://www.raspberrypi.org/phpBB3/viewtopic.php?p=228099

 

You'd need to start with the full Raspbian distribution, then replace the existing filesystem with aufs, I'd imagine. It's less involved than starting with just the Raspbian kernel (one component of the distribution), then adding a filesystem, desktop environment, window manager, etc. All compiled on the Pi using built in ARM compilers.

 

The alternative is to use a cross-compiler for another Linux distribution, which will be faster. Compile the necessary packages using the cross-compiler, then add it to the Pi. 

Interested in Linux, SteamOS and Open-source applications? Go here

Gaming Rig - CPU: i5 3570k @ Stock | GPU: EVGA Geforce 560Ti 448 Core Classified Ultra | RAM: Mushkin Enhanced Blackline 8GB DDR3 1600 | SSD: Crucial M4 128GB | HDD: 3TB Seagate Barracuda, 1TB WD Caviar Black, 1TB Seagate Barracuda | Case: Antec Lanboy Air | KB: Corsair Vengeance K70 Cherry MX Blue | Mouse: Corsair Vengeance M95 | Headset: Steelseries Siberia V2

 

 

Link to comment
Share on other sites

Link to post
Share on other sites

That's exactly the tutorial I am following, but at step 3, he says you should download the kernel via git (linux source) and than I started wondering about the extra features. But I should be scared because I use the full distro in the first paragraph?

Link to comment
Share on other sites

Link to post
Share on other sites

I don't think that should be a problem. It's possible the kernel on git is a more updated version (and maybe less stable) than the one in the full distribution. 

Interested in Linux, SteamOS and Open-source applications? Go here

Gaming Rig - CPU: i5 3570k @ Stock | GPU: EVGA Geforce 560Ti 448 Core Classified Ultra | RAM: Mushkin Enhanced Blackline 8GB DDR3 1600 | SSD: Crucial M4 128GB | HDD: 3TB Seagate Barracuda, 1TB WD Caviar Black, 1TB Seagate Barracuda | Case: Antec Lanboy Air | KB: Corsair Vengeance K70 Cherry MX Blue | Mouse: Corsair Vengeance M95 | Headset: Steelseries Siberia V2

 

 

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×