What, no Linux From Scratch?

Story: Advanced Linux Distributions You Should TryTotal Replies: 31
Author Content
phsolide

Nov 23, 2008
9:32 PM EDT
Now, LFS, there's an "advanced" linux distro. Gotta build it up from bare electrons.
Scott_Ruecker

Nov 24, 2008
12:22 PM EDT
I think the Author should have looked around a little longer before making his list. Linux From Scratch is about as advanced as one can get.
azerthoth

Nov 24, 2008
2:51 PM EDT
It's funny, I used to regard Gentoo as Linux for the obsessive compulsive. However, since my transition to Sabayon then including Gentoo and now Funtoo, I have found that just about every other distro I have tried since feels like it has training wheels on it.

Yes the devs of the major distros do a good job on default packages and configurations, however there are times in any binary distribution where you will find a place where someone dropped the ball or compiled the binary without an option that you really need, but as you have only dealt with the package manager and maybe editing the odd .conf file, recompiling a software package with the needed options can seem a bit daunting.

Thats where the technical distros like Gentoo absolutely shine. Those little tweakers that everyone hopes the binary devs ship with, are right there in the package manager for the user to adjust to their hearts content. With the ability to add connections that no one in their right mind would have thought of.

For me, anything less than a 'technical' distro is praying that the guy whose job it is to decide what options the binary is compiled with picked the right ones. I dont have to pray someone else got it right. If its wrong I know who to kick and who to turn to and blame for a bonehead mistake. Nor do I have to wait for 'it will be fixed in the next release'.
bigg

Nov 24, 2008
3:41 PM EDT
@azerthoth: That's exactly correct, and it's something I wish any of these articles would point out.

If you run Arch or Slackware (never done a whole lot with Gentoo) you are never at the mercy of the packagers. You can compile software the way the software developers (as opposed to distro developers) believe it should be compiled. You can do so with almost no effort.

Ubuntu is faster to set up by maybe an hour. Yet Slackware 12.1 was released about the same time and I have the latest and greatest of every app. I have Ubuntu 8.04 on a machine used occasionally and it's a nightmare with outdated software, hoping that someone will be generous enough to make a package.

Also, about Arch, it's not accurate to view it as a distro the same way as Ubuntu or Mandriva are distros. You need to view it as more of a 'distro build kit' than a distro. You install the base system and then add in as much or as little as you wish. You compile as much or as little as you wish. It's a great choice if you want the constant updates of a rolling release distro and complete control over the packages installed or any other feature of your system.

I had a great example of the difference between advanced and hard this weekend. Someone sent me a LyX 1.6.0 file. Ubuntu 8.04 doesn't have LyX 1.6.0. Eventually what I did was install a minimal Arch system inside Virtualbox, installed LyX 1.6.0 there, and edited the document. Trying to get USB working with Virtualbox on Ubuntu was a failure.
Sander_Marechal

Nov 24, 2008
4:26 PM EDT
@azeroth & bigg: You don't need Gentoo for that.

- apt-get build-dep package - tweak - dch (to bump the version number) - debuild -b - dpkg -i package.deb
masinick

Nov 24, 2008
4:55 PM EDT
For those who want to grab their software from the software developers and built it locally, both Arch and Slackware make good choices if you are willing to begin with an already configured binary base. You can then grab binary updates or you can grab compressed package source archives and build them. Both Slackware and Arch are organized around the .tgz package format, which is a shorthand form of the .tar.gz form in which much source code has commonly been distributed.

People who want even more flexibility in tweaking not only binaries, but source code as well are equally, perhaps even more likely, to pursue Gentoo Linux or the derivative Sabayon, both of which can provide binaries as a jump start, but are really source based distributions.

If you want to choose between source and binary for packages, but typically are satisfied with binaries and you want some help navigating through package dependency resolution, then the classic Debian software or one of its derivatives may well be all that you need. Personally, I am a big Debian fan, and sidux, a derivative based on Debian Sid that attempts to tame mismatched Sid packages and strongly adhere to the DFSG - Debian Free Software Guidelines, is one of my favorite systems for getting a cutting edge system with very little effort and a lot of flexibility. I balance it with SimplyMEPIS to get a really easy, stable desktop system and antiX to get a light, fast desktop system that I can also use as a Live CD, rescue CD, or portable, carry around USB stick based system. All of these are Debian based systems. All are fast and flexible.
azerthoth

Nov 24, 2008
4:56 PM EDT
Sander true enough, I came from debian so I am familiar with tweaking there, however there is the procedure you just outlined or for something simple 'USE="-ipv6" emerge conky'. Which is the easier method?
bigg

Nov 24, 2008
5:21 PM EDT
@Sander

It is possible to rebuild Debian packages, but the problem I encountered (in addition to the lack of documentation) is that you are still rebuilding Debian packages, as opposed to downloading the sources and compiling. Before giving up on Debian, I tried your solution, and ran into problems with patched software and things like the package being broken, for which rebuilding didn't help.

Building quality .debs is a pretty complicated matter. Another part of the problem is that Debian stable is old and Debian testing is a development distribution. Yet if Debian had the AUR or SlackBuilds, I would almost certainly still be using Debian.
Sander_Marechal

Nov 24, 2008
6:34 PM EDT
@azerthoth: No, the procedure is the same for build flags. I agree Gentoo is easier if you use a lot of that stuff, but if you're happy with the defaults 98%+ of the time, Debian is certainly a good candidate.

@bigg: If the package is broken then that's a bug. That's the same thing as a broken emerge build script on Gentoo. Did you report the bug?

Building quality debs from scratch is hard, yes. I imagine building a quality Gentoo build script from scratch is just as hard. But if all you're going to do is apply a few patches or change a build flag then it's not hard at all. "apt-get source" does everything for you. Get the original source, get the Debian package and apply the Debian patches to the source. The "debuild" command takes care of building everything the right way.
azerthoth

Nov 24, 2008
7:07 PM EDT
@Sander thats it exactly, and as I said initially the binary distros do a good job for the most part and I'd even say that more than 98% of the time what comes out is fine.

Therein lies the biggest problem and the shining glories of the 'technical' distribution. They are not only designed to be tweaked, but must be tweaked from the start to actually be functional. They aren't kitchen sink functional to start, but their functionality is much more dynamic OOB than a binary distro can hope ever hope for.

I am not meaning to denigrate binary distros at all. For me though, personally it's much like what I imagine most people here feel like when plopped in front of a windows machine. After a little while I start to feel confined and restricted, and the longer I stay the more the feeling grows. Until finally I reach critical mass because I cant tinker and tweak the system into perfection and SSH or VNC into one of my home systems to do whatever I am working on.

OK I digressed a bit there. Nutshell is, technical distros shining glory and PITA frustration are one in the same thing, tweakability. It's there, and easy to use, but you absolutely have to know how to use it properly or you end up with a non functioning brick.
hkwint

Nov 24, 2008
7:32 PM EDT
Quoting: - apt-get build-dep package - tweak - dch (to bump the version number) - debuild -b - dpkg -i package.deb


What does that do in plain English (Dutch will do as well)? Dunno understand.

Anyway, these days I'm rather tired of USE-flags, they're a PITA the last two years. These are mine:

16bit X X509 a52 aac alsa amd asf async automount bash-completion bidi bindist browserplugin bzip2 calendar cdda cddb cdparanoia clamav dbase dbus dbx devmap dga dlloader dpms dts dv dvb dvd dvdr dvdread encode erandom escreen ffmpeg fftw firefox flac gif gimp gimpprint glibc-omitfp glx gmedia gs hal hpn id3tag imlib input_devices_keyboard input_devices_mouse irssi jack jack-tmpfs jpeg justify kcal kde kdepim kdexdeltas ladspa lame lm_sensors logrotate lzo mbox mcal mime mjpeg mmap mouse mp3 mp4 mp4live mpeg mpeg2 mplayer msn ncurses network no-old-linux nodrm nodroproot nolvm1 nomirrors nsplugin obcj objc objc++ objc-gc offensive ogg openal opengl openssh openssl pam pdf png pnm ppds python qt3 qt4 quicktime realmedia rtc samba sdl sharedmem speex spell sqlite sqlite3 stream svg swat sysvipc tcpwrapper tga theora threads tiff truetype urandom utf8 video_cards_vesa vim vorbis wmp x264 xanim xine xml xpm xv xvid xvmc zip

You might understand I'm not fully aware of what each of those does and if I really need them, and moreover, if one is deprecated it's hard to find out and if a new one emerges it's also searching what it does again. ufed kind of does the job, but it's hard searching around those 600+ useflags (local ones included). It used to be simpler back in the good ol' days erm... 2004 I think.

PS: Offensive is the only USE-flag you really need, otherwise you will not be motivated to type your sudo-password right the first time. You should try it! For Ubuntu, the very same goal is actually much harder to reach:

http://ubuntu-tutorials.com/2007/02/18/let-sudo-insult-you-w...

So again a case of Gentoo being more userfriendly than Ubuntu.
hkwint

Nov 24, 2008
7:37 PM EDT
About LFS: It's not a software distro, because it doesn't distribute software or configuration files. It's just a large manual. Probably that means it doesn't qualify as a Linux distro. However - for the lazy among us - ALFS does; it's nearly the same idea as Gentoo: Automate building from source.
Bob_Robertson

Nov 24, 2008
8:30 PM EDT
LFS does have a boot disk that's pre-built, to get a working platform to start building on, so it has become a "distribution".

Some day I'd love to try it, after 13 years of Debian Sid, how hard can it be?

Edit: You'll have to pull dselect from my cold, dead keyboard. I loath aptitude.
Sander_Marechal

Nov 24, 2008
8:33 PM EDT
Quoting:What does that do in plain English (Dutch will do as well)?


1) "apt-get build-dep " or "aptitude build-dep "

Install all packages, libraries, headers and tools that you need to build the binary package.

2) "apt-get source " or "aptitude source "

I forgot this one in the list above. This downloads the original source tarball into the current directory, downloads the Debian package and merges it with the original source. It's a 3-step process because Debian does not modify upstream source code. They keep the original tarball and put patches separately into the Debian package.

3) tweak

Show off your l33t coding skillz

4) dch

Short for "Debian Changelog". Update the Changelog in the Debian package. This also increases the version number of the package. You need to do that so that when you install it, Debian sees that your version overrides the standard version (which will have a lower version number).

5) "debuild -i -us -uc -b"

This builds an installable Debian binary package from the sources. Just "debuild -b" like I wrote will also work, but this is better. -i runs an extra check on your package after building it. -us and -uc mean that you do not wish to sign the package contents with your GPG key.

6) "dpkg -i "

Dpkg is the low-level debian package manager. apt, aptitude and synaptic are all built on top of this. -i means install, so this installs your custom package.

And that's it! You have now built and installed your custom Debian package. Currently I have two such custom packages installed. I have patched exuberant-ctags for better PHP5 support (provides PHP highlighting in Vim. Patch here: http://sourceforge.net/tracker/index.php?func=detail&aid=227...) and I have installed an updated Vim 7.2 from experimental, so I could use the latest netrw plugin.

Manually backporting packages from newer debian releases is done much in the same way, only instead of "apt-get source" I simply download the package files from the Debian Experimetal repository manually. Then Debuild takes care of building it on my Etch system. Of course, with backporting you do need to take care of any changed dependencies yourself since "apt-get build-dep" installs the dependencies of the version in your repository, not the newer version you downloaded manually.

PS: That's the hard way of creating a backport yourself. Many packages have already been backported and can simply be installed by adding backports.org to your repository list.
Steven_Rosenber

Nov 24, 2008
9:54 PM EDT
It all depends on the hardware, the user(s), the application(s) and the administrator.

Sometimes having a box that you can apt-get update apt-get upgrade is the best choice.

Others might feel better running Slackware, either with or without slapt-get. If you're happy with all the goodness that comes in a full Slackware install, you like KDE and don't want to add/maintain a lot of packages, it's a very solid choice.

For "normal" people, Ubuntu or even Debian using the GNOME update manager might work better.

Even though I really feel at home in Debian especially, I'm setting up a laptop with OpenBSD 4.4. Even in this situation I have tradeoffs. As secure as OpenBSD is, you don't maintain the -release branch the same way as Debian or even Slackware. Critical patches are publicized and should be applied, but when running -release or patched release (aka -stable), the 4,000+ precompiled packages for i386 and 4,000+ ports for all architectures are NOT generally updated at all for the six months between releases.

So if I decide not to worry about package updates during that six-month interval, I don't have to do almost any updates for six months, at which time the not-so-easy OpenBSD upgrade will await me. Truth be told, I don't know how I feel about that at this very moment.

Most OpenBSD geeks run -current, which is updated continuously but which either must be refreshed with new snapshots or through a whole lot of compiling.

I hate sitting and waiting for things to compile. Like watching paint dry.

I'm having fun with OpenBSD, but there are plenty of other situations in which I'd use Debian, Ubuntu, Slackware (for which I continue to have a great deal of respect and fondness) and now CentOS/Red Hat, which I've recently been running quite successfully.

My lack of love for compiling would probably make Gentoo something I shouldn't even try ...
theboomboomcars

Nov 24, 2008
11:51 PM EDT
I used Sabayon on my laptop (1.5GHz CeleronM) and I liked it except for updates. If there were like 3 or 4 it would take hours to complete. The system was fast and stable, but updates took for ever and suspend didn't work. So when The new releases came out I burned some discs and with Ubuntu 8.10 everything worked out of the box, I tried Mandriva but it would hard lock when I tried to do anything with the network. So I made the hop back to Ubuntu.

Though I did like that you could set different settings when installing new software. Isn't nice that there are so many options that you can look for one that fits you the best.
Sander_Marechal

Nov 25, 2008
10:02 AM EDT
I just submitted a blog article I wrote to the newswire. It explains how to patch exuberant-ctags on Debian. The process is the same for just about any Debian package. So, keep an eye on the newswire.
bigg

Nov 25, 2008
10:10 AM EDT
That's great. *This* is the kind of stuff we need to see more often. Well, actually, I need to see more often.
hkwint

Nov 26, 2008
5:37 PM EDT
Quoting:I hate sitting and waiting for things to compile. Like watching paint dry.


Then you should detach screen and go on browsing, go out or go to bed if it's late, just like most people who are compiling do. At least that's what I do. But on the other hand I like watching for hours at gcc output. Just like I liked watching at the blocks of the Win98 defrag-program. But then came XP, and the thousands of blocks on the screen were gone! What a disaster that was, it ruined my life! Glad Gentoo was there.

I also tried to patch some things in Gentoo once (actually I tried to patch a hardened kernel with swsusp-patches) but that didn't work, and after manually patching some files where the two patches (hardened is also a patch) conflicted, I gave up. Adding patches to Gentoo ebuilds is rather easy; as far as I know you need an overlay (to prevent screwing things up) and there in the ebuild you can just add the web-address of the patch, update the digest and that should be it. I've never done so however. I was going to look at an ebuild to see if it's really that simple, but believe it or not, I'm typing this on my two-hours ago installed Debian system now.

So great there's going to be an article on how to patch my Debian packages, but I'm not that far; currently I'm trying to find out if my update to Lenny succeeded or not; but at least KDE4.1 won't install (darn, I almost wrote "compile"). Don't have any clue for now; I'm afraid the dist-upgrade didn't work. So after all, it seems Gentoo isn't advanced, because there's only one version of it so you never have to worry what you're using and you never have to switch between versions.
Bob_Robertson

Nov 26, 2008
5:54 PM EDT
> because there's only one version of it so you never have to worry what you're using and you never have to switch between versions.

That's why I've been using Debian Sid for years. But stuff sometimes does indeed break, which for some reason tends to piss some folks off big time.
hkwint

Nov 27, 2008
2:56 PM EDT
Well, if I could only reach the point of using Sid. Right now I can't even seem to reach Lenny.
tracyanne

Nov 27, 2008
4:29 PM EDT
OT: My local mirror is now working perfectly. I set up a local mirror by pulling the entire Mandriva 2008.1 repository, not just the updates, but the entire set of available software (27.5 Gig) in addition I mirrored the PLF repositories for 2008.1 as well. Once a day around 10PM my server reaches out and wgets any updated or new packages and pulls them down, and the machines on my network access the local mirror for updates via http://FTP. It's working well.
Bob_Robertson

Nov 27, 2008
5:20 PM EDT
HK, very interesting. I just did a new Lenny install over the weekend, and it was utterly painless.

The way to get to Sid, for me, is to get the net-install mini disk, keep the network disconnected. After the install finishes, you have a _seriously_ minimal install, but then I hand edit /etc/network/interfaces to bring up the network, change /etc/apt/sources.list with entries for Sid, and then apt-get update apt-get dist-upgrade, and after that's done _then_ run "apt-get install aptitude" or "apt-get install dselect" or "tasksel" or whatever it is you want to use to get the rest of your userspace. And it's all pure Sid.
jezuch

Nov 28, 2008
2:53 AM EDT
Quoting:I just did a new Lenny install over the weekend, and it was utterly painless.


Did you per chance try to install on an encrypted root partition? Well, I tried and it didn't boot and I'd like to know if it was my fault or not :) [Yes, I know I should report a bug...]
gus3

Nov 28, 2008
3:38 AM EDT
@jezuch:

Did you keep a separate, unencrypted /boot partition? If not, then yes, it was your fault. OTOH, if /boot wasn't encrypted, then you should probably take a photo of the crash screen and report it as a bug.

Disclaimer: I have virtually zero experience w/ Debian. Heed my advice accordingly.
Sander_Marechal

Nov 28, 2008
4:44 AM EDT
IIRC if you use grub2 (available, but not used by default in Debian Lenny) then you can have encrypted /boot (and /boot on LVM and other such niceties).
gus3

Nov 28, 2008
4:54 AM EDT
Encrypted /boot is currently a feature request for GRUB2:

http://grub.enbug.org/FeatureRequests
Sander_Marechal

Nov 28, 2008
5:41 AM EDT
Ah, I thought it had already arrived.
Bob_Robertson

Nov 28, 2008
8:50 AM EDT
No, I haven't done an encrypted disk yet. But then, I have nothing worth encrypting that isn't already handled by GPG.

Encrypted /boot? From the bootloader? Hmmm, that sounds interesting.
Steven_Rosenber

Nov 28, 2008
3:30 PM EDT
I've never tried the encrypted Debian, although I keep saying I'll do it ... someday. The encrypted pup_save feature in Puppy Linux works extremely well. That's one I have tried.

Ubuntu offers this feature in the alternate installer, I think.

I don't keep anything anywhere near "mission critical" on a laptop, and that has kept me from rolling out an encrypted laptop. Debian seemingly makes it easy to do, though.
jezuch

Nov 28, 2008
4:58 PM EDT
Quoting:Did you keep a separate, unencrypted /boot partition? If not, then yes, it was your fault.


No, /boot was a separate, unencrypted partition. Fortunately I'm not that dim :)
Steven_Rosenber

Nov 28, 2008
8:15 PM EDT
Just about the only reason for an encrypted hard drive is to keep prying hands away from your data while the machine is turned off. This kind of encryption does nothing while the machine is running and you're logged in. But when it's turned off, without the passphrase nobody can turn it on and access your data. That's why it's good for laptops, which have a habit of falling into the wrong hands.

Posting in this forum is limited to members of the group: [ForumMods, SITEADMINS, MEMBERS.]

Becoming a member of LXer is easy and free. Join Us!