Here’s how to build your own version of boxes using the boxes sources.
The boxes development platform is currently MinGW on win32. If you are on a different platform, please send in your binaries for inclusion among the files to download.
Boxes is generally very easy to port, because it uses only a small set of instructions and is comformant to the ANSI C standard.
Once built and deployed, boxes can be integrated into your text editor. We currently describe integration with vim, emacs, and jed, but this list may grow as time goes by and people send how-tos.
The location of the system-wide config file is compiled in, so if you don’t like it’s default location,
you can edit the top level Makefile and change the value of
whereever you want the system-wide config file to reside. Note that
each user may have his/her own config file in $HOME/.boxes.
Also note that the value of
GLOBALCONF is a full file name. It does
not specify a directory into which to copy the config file.
If you are on DEC/OSF, edit src/regexp/Makefile, and add
-D_ANSI_C_SOURCE to the
In the top level directory, type
make && make test. Find the resulting binary in the src folder.
In case of problems, check the compilation faq.
That should be all. Boxes is built so that this works almost everywhere.
In order to deploy your newly created binary on Linux/UNIX, these steps are recommended:
GLOBALCONFis the name of the file, and not the name of a directory into which to copy the file. So, the name of the config file is changed from boxes-config to just boxes.
Example (as root):
cp doc/boxes.1 /usr/share/man/man1 cp boxes-config /usr/share/boxes cp src/boxes /usr/bin
If you want to make your own changes to the config file, copy the system-wide config file into your home as $HOME/.boxes, then modify it. Boxes will use $HOME/.boxes if it exists.
Boxes was written for UNIX, but it can also run on Windows! Boxes is a 32bit application, but it works on 64bit systems, too. Here’s how to build on Windows.
Special thanks go to Ron Aaron, who provided a specially crafted Makefile for win32 and also created the Windows versions of boxes that have been around to this day.
In order to build boxes on Windows, the required win32 executable can be created like this:
Basically very simple, but there may be a few pitfalls, so we’ll go through each step in detail.
C:\MinGWas installation directory. This is really important. If for some reason you cannot use this highly recommended directory, choose another one that has a short path, does not contain spaces (!), and does not include a Windows “special path”. For example,
Open fstab and make sure that the only lines which are not comments are these:
c:/mingw /mingw d:/path/to/boxes /boxes
Note that the whitespace in this example are tab characters. The d:/path/to/boxes is the path where you placed your clone of the boxes repo. Avoid spaces in its path, too.
Within the MinGW shell:
cd /boxes make clean && make win32
If you want to create an executable with debug information, call
make clean && make win32.debug instead.
make testto check that your executable is working OK.
In order to run boxes on any Windows machine, two files are required:
boxes.cfg is obtained by simply renaming the boxes-config file from the root of the boxes repo into boxes.cfg.
Both files should be placed together somewhere on your PATH.