Category Archives: packages

Building ARM Packages with Poudriere (the simple way)..

The current directions for building ARM packages are quite long and need to be updated. This is my work-in-progress directions until I get everything right and then I will update the documentation.

  1. Install poudriere and qemu-user-static: pkg install poudriere qemu-user-static
  2. Enable qemu-user-static in rc.conf: qemu_user_static_enable="YES"
  3. Run the startup script to configure your system for building different architectures: /usr/local/etc/rc.d/qemu_user_static start
  4. Create a ports tree to build: poudriere ports -c -m svn+https -p svn
  5. Create an ARM build jail. Note, this will take awhile: poudriere jail -c -j 11armv6 -v head -a arm.armv6 -m svn+https

Now you can test build whatever packages you want for your ARM device:
poudriere testport -j 11armv6 -p svn -o x11-wm/lxsession

Build just one FreeBSD port

I usually build my own packages with poudriere but it’s not fun to do on tiny boxes so I just do ‘pkg install ‘ on them and use upstream packages. One downside is, that package is build with default options. I recently ran into a situation where I wanted to change some options for just a single port.

Now, what is the minimal set of things in /usr/ports/ that I need to checkout to be able to config/build just one port?
Turns out to be:


/usr/ports/Mk
/usr/ports/Keywords
/usr/ports/Templates
/usr/ports/ports-mgmt/dialog4ports

And the port I want to actually build. Now I can ‘make config’, change the options and build/install that port without checking out entire ports tree.

Florent Thoumie

It’s been a while since I’ve written anything in here so I’ll try to remember how things work…

A few weeks, like a lot of people, I ordered a RaspberryPi to use as a mediacenter. Unfortunately it still hasn’t arrived and I got tired of my good old xbox that’s starting to be quite limiting in terms of what I can ask it. Anyway, I had an old-ish desktop in the attic that I decided to use in place of the RPi in the meantime. The thing is, it was running FreeBSD 8.1-BETA1, which also was quite old. I could have simply reinstalled everything but: a) I didn’t have an install cd and b) I decided to give pkgng a proper try (as opposed to just running it in a vm).

First step: upgrading to 9.0-RELEASE. Pretty easy thanks to freebsd-update, I did have to go via 8.1-RELEASE because of some metadata integrity check failing. Didn’t add too long to the process, so I’m not complaining.

Second step: updating the ports tree with portsnap (my tool of choice) and installing ports-mgmt/pkg.

Last step (ok this one is fairly long and more complicated): point PACKAGESITE to pkgbeta.freebsd.org and force-upgrade all packages (pkg update && pkg upgrade -fy).

Tada!

Backtracking slightly, the last step didn’t go without any trouble, pkgng complained about ports having file conflicts. In some cases, ports had been merged/deleted (so the easy fix was to pkg delete them first). In other cases, we were going from a versioned port to another one (e.g. mysql50-client to mysql55-client) so the register origin for the package had to be changed with pkg set –o databases/mysql50–client:databases/mysql55–client. Finally pkg upgrade -fy wasn’t complaining anymore.

So that was a few days ago, yesterday a new package set was uploaded. Since I pointed PACKAGESITE to http://pkgbeta.freebsd.org/freebsd-9-i386/latest/, pkg update picked up on the new packageset and more packages were available for upgrade. pkg upgrade worked without a hitch but a couple of apps that I had installed via ports (and not yet available as packages) weren’t upgraded along with graphics/png, which caused x11/slim to look for a non-existent png library. Note that I only used pkg(ng), not portmaster or portupgrade which would have picked up on the update since PORTREVISION for x11/slim was bumped. I am told that preserving shared libraries might be added to pkgng v1.1.

Anyway, congratulations to bapt@ and everybody else working on this! There are still a few rough edges but it’s working pretty darn well already!