OpenBSDInstallPorts

How to install X11 and fix ports

More of a note to myself, but this could be helpful for other people out there...

If you try using ports, under OpenBSD, you may bump into the following error message:

Fatal: ports require X11 installation to work correctly

Yes, unfortunately, ports require X11 to be installable. This is detailed in the Open BSD FAQ (see the See Also section below). So, at this point, you have two options:

  1. Stop using ports and use pre-compiled packages only;
  2. Install the X11 packages in order to use ports.

Installing the X11 packages is extremely simple, provided you have enough disk space. Here is an example, assuming you have a valid installation CD-ROM:

# mount -v -t cd9660 /dev/cd0a /mnt
# list=$(ls /mnt/5.5/i386/x*.tgz) ; for file in ${list} ; do tar xvzf ${file} -C / ; done

[... here, you should see a long list of files being installed ...]

And... You are done! The X11 packages are now installed and your ports tree should work correctly and install all the software you need!

See Also: