portupgrade O(n^m)?

Csaba Molnar molnarcs at gmail.com
Thu Feb 15 20:35:17 UTC 2007


2007. February 15. 19.17 dátummal youshi10 at u.washington.edu ezt írta:

> >
> > Compare that to the situation for Debian apt-get. The names are
> > conserved. They have strict rules about package naming, they stick to
> > them and don't change them arbitrarily. All packages exist in compiled
> > form, you don't have to worry about prepackaged or "to be compiled, so
> > has 50% chance to break". You have only 2 states to consider instead of
> > 3: the state on the machine and the state on the repository. Things are
> > vastly simpler. No wonders that apt-get works and portupgrade doesn't.
> > This has nothing to do with the fact that apt-get is written in C++
>

Sorry to pipe in, I just want to give the perspective of an ordinary FreeBSD 
user (since 5.1) who used debian before (and ventured into gentoo-land for a 
month or so just to run back screaming to freebsd). 

First of all I don't understand why you exaggerate - implying that you have to 
woryy because "prepackaged or "to be compiled, ... has 50% chance to break" 
is simply not true. I just rebuild all my installed packages (615 in total) - 
and there were only two that broke during compile.

Second, there is no "generic" binary builds that cater to all user's needs. So 
debian was forced to provide multiple packages for the same program (check 
out amarok debs or apache-mpm, apache-prefork, etc) built with different 
options that don't even conver all those options that ports provides me. If 
you wanted to have the same flexibility freebsd provides, you'll have to have 
even more duplicated versions of packages.

The "takes too much time" argument against compiling is becoming less and less 
relevant as hardware improves, but even on my dusty athlon-xp server, how 
much time do you think I spend compiling? I have apache22, mysql50, php + 
lots of extensions (plus supporting libs like gd, netbpm) installed, and 
keeping all these up to date takes less then hour each month!

There is not much difference when it comes to core capabilities of the OS 
between linux and freebsd - but the very reason I stay and will stay with 
freebsd in the forseeable future is because how ports/packages work. The only 
distribution that comes close to what I like about this binary system (I mean 
ports/packages) is arch linux, which is primarily package based but it has a 
build system similar to ports as well.

I know I'm not a large scale user, but freebsd's build system and automatic 
package creation (installing ports with portinstall -p) came in handy a few 
times. I think FreeBSD already has an excellent binary package management 
system. I maintain some really old computers in a lab at our university, some 
of which can't run windowsXP, but they are excellent internet "terminals" 
(opera + gaim + gftp on top of blackbox with a simplified menu). I wanted to 
sqeeze out every last bit of performance from these machines, so I built a 
set of packages on my own computer, and lo and behold: I had a repository of 
binaries optimized for these machines that resolved dependencies 
automatically just like in debian, without having to learn how to build 
packages. I could simply download these packages through the lan, and pkg_add 
* them on each machine (well, four of them), and in a few minutes I had them 
up and running using packages specifically built for the capabilities of the 
hardware as well as exactly those options that users will need. Debian in 
this respect is far less flexible. Yes, you have src debs, but it is far more 
complicated than just passing -p to portinstall/upgrade. None of the linux 
distributions I have tried gave me this kind of flexibility and power - and 
I'm just an ordinary user, with no programming experience whatsoever.

As to gentoo - I don't understand the technical issues. What I experienced, 
however, that gentoo simply relegates the brunt of the work of the port 
maintainers to the users, which results in far more breakage in everyday use 
than what I have experienced with FreeBSD. Took me days to configure the 
silly USE flags just to have sane defaults (I mean an emerge mc without it 
pulling entire xorg). I also had problems with removing components of 
packages that were installed via a metaport. During my time with gentoo 
(granted, it was two years ago) - I haven't seen anything that it can offer 
to me as a user over ports, but at least I have learnt to appreciate the 
tremendous work FreeBSD port maintainers put into port maintainance. Ports is 
simply far more user friendly than portage, with less breakage overall than I 
have experienced with portage. That's why I felt very unfair your 
exaggeration about ports breakage. 


Thats just my two cents, and I don't pretend to understand half of the issues 
raised in your post. I just know one thing: I twitch everytime I hear someone 
who wants ports to work more like portage (please please DON'T go there!) or 
argues for a binary package management. FreeBSD has already a kickass binary 
package management system. In fact, I was always wondering why the user 
community didn't leverage its power - probably because its not a well known 
feature? But nothing prevents ordinary users to maintain custom package 
repositories if they want to. For instance, now that I have 600+ binary 
packages in my /usr/ports/packages/All I could easily upload it to an FTP, 
and say that anyone who wants a full blown KDE desktop with latest xorg and 
beryl in an hour, here you go, pkg_add * on a clean system, and have fun. In 
fact, this is an option that can be explored in the future as FreeBSD's 
userbase grows, but this is not something that I would expect from the 
developers. This capability of ports/packages is a hidden gem of FreeBSD, 
something that makes it superior to linux I believe. Witness the success of 
PC-BSD - the binary ports/packages system is what makes it possible. It is 
done by only a handful of people (only one guy working on it fulltime) - and 
yet, people are comparing it to Ubuntu. I believe that the ports system as it 
is now is an incredible asset: people without serious programming knowledge 
actually cold do a binary only desktop oriented freebsd distribution in a few 
days by building a set of carefully selected binary packages, checksum them, 
create a website, and distribute them from there, providing a miniinstall ISO 
that only installs a base system, then pulls those binaries from an ftp and 
pkg_adds them. I believe that the current system has some really 
nifty "community" capabilities that are not yet explored (because FreeBSD is 
not as known as linux) - but once more and more people realize just how 
powerful it is, I think it could become the important aspect of the OS 
through which it can differentiate itself from the competition. 

Sorry for the long rant, I can readily admit that there are technical issues 
that I don't or can't understand, but I felt that the power of ports/packages 
isn't really appreciated. I just don't understand the debian argument when 
anyone can take the ports, turn them into binaries, and have a system that 
does basically the same: installs binary packages with automatic dependency 
resolution.

That's all - and thank you for all the work all of you put into creating this 
wonderful system. 

Bye.


More information about the freebsd-ports mailing list