Gentoo/FreeBSD is an effort effort to provide a fully-capable FreeBSD operating system with Gentoo's design sensibilities. The long-term goal of the Gentoo/BSD project is to allow users to choose any combination of *BSD or Linux kernels, *BSD or GNU libc, and *BSD or GNU userland tools.
Users migrating from Linux to FreeBSD commonly consider the two operating systems "almost the same". In fact, FreeBSD really shares a lot of similarities with Linux distributions in general. Nevertheless, it has some key differences that are worth noting:
Besides, FreeBSD also has some technical differences which set it apart from Linux. Some of them are very important to know, even if you don't plan on joining the Gentoo/FreeBSD development effort:
After this short introduction, it's about time to finally install
Gentoo/FreeBSD. Unfortunately, we currently lack our own installation media, so
you have to choose between two alternative installation methods. The first
would be to use an existing FreeBSD installation to partition your hard drive
and use it as a base for installing Gentoo/FreeBSD. Alternatively, you can also
use the excellent
Before you can begin with the installation, you have to setup a hard disk for
use with Gentoo/FreeBSD. This can either be done via
Once you're done setting up your disks, you have to create a mount point for your Gentoo/FreeBSD installation and mount all the necessary partitions.
# mkdir /mnt/gfbsd(Replace X with the correct numbers for your hard disk.) # mount /dev/adXsXa /mnt/gfbsd
Now that you have mounted the target partition, it is time to fetch and unpack a stage3 tarball.
(Any other Gentoo mirror which includes the experimental/ directory will also work.) # wget http://gentoo.osuosl.org/experimental/x86/freebsd/stage3-x86-fbsd-20050811.tar.bz2 # cp stage3-x86-fbsd-20050811.tar.bz2 /mnt/gfbsd/ # cd /mnt/gfbsd/ # tar -jxvpf stage3-x86-fbsd-20050811.tar.bz2(You can delete the tarball with the following command if you want to.) # rm stage3-x86-fbsd-20050811.tar.bz2(Create a home directory for root.) # mkdir /mnt/gfbsd/root
Before chrooting into the newly-extracted stage, you first must obtain a copy of
the Gentoo/FreeBSD overlay. If you are not a Gentoo developer, you can get it
from the mirror provided by
# cvs -d:pserver:anonymous@zarquon.twobit.net:/var/cvsroot -q -z9 co -R gentoo-projects/bsd/fbsd/
In order for your install to work, you need to mount the
# mount -t devfs none /mnt/gfbsd/dev/ # chroot /mnt/gfbsd/ /bin/bash
After you got hold of the Gentoo/FreeBSD overlay, it's time to link
# ln -sf /usr/local/portage/gentoo-freebsd/profiles/default-bsd/fbsd/5.4/x86/ /etc/make.profile(FreeBSD's standard editor is ee, which is used to edit /etc/make.conf) # ee /etc/make.conf(Please make sure you add at least the following entries:) CHOST="i686-gentoo-freebsd5.4" ACCEPT_KEYWORDS="~x86-fbsd ~x86" FEATURES="-sandbox collision-protect" PORTDIR_OVERLAY="/usr/local/portage/gentoo-freebsd"
Now, you have to obtain a copy of the main Gentoo Portage tree, which depending on your connection might take quite a while.
# emerge --sync
After you have synchronised your Portage tree, you only have to take a few last steps before your Gentoo/FreeBSD system is ready to use.
(Prevent crt1.o from getting removed by emerging gcc.) # chflags schg /usr/lib/crt1.o(Update the binutils installed by the stage3 tarball.) # emerge -u binutils(Select the correct gcc.) # gcc-config 1 # source /etc/profile(Start the following script to fix a current bug in the stage3.) # /usr/local/portage/gentoo-freebsd/scripts/domove.sh(Re-emerge python, portage and py-freebsd.) # emerge --nodeps python portage py-freebsd
Congratulations, by the time you have reached this step you should have a running Gentoo/FreeBSD system! If you want, you can now rebuild the system's core packages.
# emerge -e system
# emerge boot0(Leave the chroot environment) # exit(Issued from outside the chroot) # fdisk -b -B /mnt/gfbsd/boot/boot0 /dev/adX # chroot /mnt/gfbsd /bin/bash # disklabel -B adXsY
If you need additonal information on setting up
When you did
Please note that currently only the "Traditional" way of building the kernel is
supported on Gentoo/FreeBSD! Also note that
There are many things you could help with, depending on your skill level and spare time:
Although Linux and FreeBSD both are Unix-like operating systems, there are some important differences you have to know about if you want to contribute to our development effort:
At the moment, there are still quite a lot of known issues. Here are the ones really worth noting:
At list of Gentoo/FreeBSD developers can be found at the