Packaging Base
I am currently working on the scripts for packaging Base.
Manual
I wrote the manual for previous versions of Base directly in troff. In the new
release, however, the manual is written in Markdown. The primary
reason for the change is that Markdown can be easily viewed on GitHub,
but the improved readability of the source is nice as well. The Markdown
source is converted to troff format, for use with the man
command, using Pandoc.
Unfortunately, Pandoc would be a really large build dependency. That
is not a significant issue for building .deb
or
.rpm
packages, which is done on my own machine, but it is a
significant issue for people who install from source or use package
systems that build from source.
After a fair amount of internal debate, I decided to build the manual
as part of the release process and commit the troff
version
to the repository. While this is generally considered bad practice, I
think that it is worth it in this case. Pandoc is no longer needed to
install from source. Another benefit is that the date displayed in the
manual is fixed to the release date.
.deb
Packages
I implemented .deb
package building using Docker.
Running make deb
creates a Debian container, with the build
directory mounted, and runs a build script. The build script does the
following:
- Install OS packages for building
.deb
packages - Configure a user with the same
UID
andGID
as the mounted build directory - Build a
.deb
package, making use ofdh_make
anddpkg-buildpackage
- Copy all built artifacts to the mounted build directory
Running make deb-test
creates a Debian container, with
the .deb
package mounted, and runs a shell. One can install
the package and confirm the installation within the container.
This works fine, but installing the OS packages can be time consuming. I am considering creating a Docker image with these packages installed, for use with multiple projects.
.rpm
Packages
I will implement scripts for building .rpm
packages
next, using Docker. It has been a long time since I have
created an .rpm
package!
Arch PKGBUILD
I would like to create a PKGBUILD
for Base, as well as
register it in AUR. It turns
out Arch already has a package named base! (It is a
meta-package that depends on a minimal package set for a basic Arch
installation.) I am considering alternate names to use for the Arch
package. My current favorite is base-env
, short for Base
environment.
Nix Package
I would like to create a Nix package for Base and submit it to nixpkgs.
Current Plans
I plan on implementing .rpm
package building for the
pending release. I would really like to release soon, because I have
other projects to work on (such as this website), though, so I plan on
waiting to work on the Arch PKGBUILD
and Nix Package until
a future release.