Craig's pfSense Page

Toolchain Notes (2.4.5)

Here are some notes on setting up to cross compile pfSense ports on a FreeBSD poudriere build box.


Use poudriere to build the qemu-user-static package. Add configuration to /etc/rc.conf:

qemu_user_static_enable="YES"

Run the rc.d script:

service qemu_user_static start

Add to /usr/local/etc/poudriere.conf:

GIT_URL=git://github.com/pfsense/FreeBSD-ports.git

(This works for me because I do not build any other FreeBSD jails from git.)

Build the jail. freebsd-version reports 2.4.5 is 11.3-STABLE but I couldn't find a svn revision. The kernel is dated 24-Mar-2020 so I used r358968:

poudriere jail -x -c -j 11pfsense -a arm64.aarch64 -m svn -v stable/11@358968

Check out the ports tree; poudriere defaults to master so specify the "devel" branch:

poudriere ports -v -c -m git -B devel -p pfsense 

To update the ports tree use:

poudriere ports -v -u -m git -B devel -p pfsense 

I like to tweak root's dot files in the jail:

# Edit dot files
zfs list -t snapshot 
zfs destroy tank/poudriere/jails/11pfsense@clean
zfs snapshot tank/poudriere/jails/11pfsense@clean

Create a jail specific poudriere make.conf.

cd /usr/src && git clone https://github.com/pfsense/pfsense.git 
cp -i /usr/src/pfsense/tools/conf/pfPorts/make.conf \
    /usr/local/etc/poudriere.d/pfsense-make.conf

Since 11.2 is no longer supported you need. Turn of warning sleep delays while we're at it:

echo ALLOW_UNSUPPORTED_SYSTEM=1 >> /usr/local/etc/poudriere.d/pfsense-make.conf
echo WARNING_WAIT=0 >> /usr/local/etc/poudriere.d/pfsense-make.conf
echo DEV_WARNING_WAIT=0 >> /usr/local/etc/poudriere.d/pfsense-make.conf

Set the default python version to match 2.4.4:

echo 'DEFAULT_VERSIONS+= python=2.7' >> /usr/local/etc/poudriere.d/pfsense-make.conf

Build something:

poudriere bulk -C -j 11pfsense -p pfsense net-mgmt/pfSense-pkg-arpwatch

GitHub Forking


Copyright © 2019
Craig Leres