CMake and C++ “Compile Time” Polymorphism

For a recent project of mine, I wanted to use what some people call “Compile Time Polymorphism” in C++. Here’s how I implemented it. Polymorphism in the context of programming computers usually refers to the ability to tread objects of a different data type through the same interface. In C++, this is often implemented through […]

An Encrypted File-backed File System on FreeBSD

The following is a compilation of information, largely based on the FreeBSD Handbook, Section 18.13 and Section 18.16. This post describes how a file-backed, encrypted file system can be built and used on FreeBSD. Prerequisites In order to follow the steps below, the following prerequisites must be met: md(4) in the Kernel gbde(4) in the […]

Cross compiling the FreeBSD Kernel

Wow, two post in one day already 😉 There are two things I’d like to note. First, I noticed that cross-compiling seems a major issue for me. Don’t know why that is. Second, I need to remember Warner Losh’s post on cross compiling FreeBSD. Essentialy, the procedure is: $ export TARGET=powerpc $ export TARGET_ARCH=powerpc $ […]

TianoCore on FreeBSD/amd64, Take 2

Now that I have build a cross compiler, I’m trying to build the TianoCore EDK again. In this post I list a few environment variables that need to be set in order to build the EDK. Because the build process needs to use the cross compiler, another environment variable is needed: $ export CC=/opt/i386-tiano-pe/bin/gcc Since […]

Building a Cross Compiler on FreeBSD

I’m currently trying to build a cross compiler (and other required tools) on FreeBSD. The compiler will run on FreeBSD/amd64 and should produce i386 binaries. This wouldn’t be too hard since that task can easily be accomplished by using the FreeBSD source tree. However, I need the toolchain to produce binaries in the PE/COFF format […]