Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
87 lines (60 sloc) 6.31 KB

A build bot for popular Lua projects

Lots of Lua projects (including Lua itself and LuaJIT) only release source code archives and expect users to build the project. On UNIX this is not really a problem but on Windows this can pose a significant hurdle for potential users. My Lua build bot is an attempt to solve this problem. While developing this build bot I took the following points into consideration:

  • I've had bad experiences with cross compilation so I prefer to build Windows binaries on Windows
  • I don't actually have any Windows machines and don't feel like setting one up just for this build bot
  • I want to be able to run the build bot from a cron job so it can automatically build all projects once a week


The following packages have been built by the Lua build bot:

Implementations of Lua

ReleaseSizeSHA1 hash
Lua 5.1.4234Kb312a0f67fae85d0969edcccee3df3bb27b6c228
LuaJIT 1.1.7255Kf58c039e0a890601d44f7026f36ed7e9a9de0990
LuaJIT 2.0.0 beta 8269K7b3f8a8c4788e67c737137e69c9bbe39ba183410

Lua modules

ReleaseSizeSHA1 hash
LPeg 0.10.289K159a31446cc4c0f3a28e892c2c61d4bac52f25ee
LuaSocket 2.0.2126Ka6a8fe0763cd21160c4cde2f6da8df5095851c36
LuaFileSystem 1.5.070K9c482f761d4e7624215b62e0b807a59ff44a3309


The following stuff has not yet been implemented but is on the to-do list:

  • Make the build bot test the binaries using a test suite of some sort; if everything is going to be automated I have to know that the binaries I'm publishing actually work
  • Deploy the build bot and virtual machine to one of my servers and run the build bot from a daily cron job?
  • Use LuaRocks to build Lua modules: currently the build bot uses custom batch scripts to build Lua modules, but of course a generic solution is preferable!
    • While adding support for the LuaSocket module I was curious enough to try if luarocks install luasocket would work in my environment but it doesn't; msbuild complains that the project files are incompatible
  • Support for Mac binaries? This requires someone to run the build bot periodically on their Mac, because I don't have access to any Mac machines

How it works

Right now the build bot is meant to be run on my machine because it works in a very specific way, however I'm planning to make it more generally useful (and with a bit of persistence it should already be possible for other folks to get it running). At the moment I run the build bot as follows:

  • I start the build bot script from a terminal on my Ubuntu Linux installation
  • The build bot starts a headless virtual machine running Windows using VirtualBox
    • The virtual machine has been specifically setup for the build bot (see below)
    • When the virtual machine boots it automatically launches the build bot
  • When the build bot is executed on Windows it performs the following steps for each project:
    • Find latest available release from homepage
    • Download archive (if not already downloaded)
    • Unpack and build project
    • Copy files to be released (binaries & headers)
  • When the build bot was executed automatically on Windows, it will shut the virtual machine down

As I mentioned above the plan is to run the build bot from a cron job on a server, this is still a work in progress.

Dependencies in the VM

In order to run the build bot on Windows I installed the following software in the virtual machine:

I'm not publishing the virtual machine image because it was registered with my serial number and of course it's quite big (more than 2 GB). However it's not hard to create the virtual machine, it just takes a bit of time. Apart from installing the software mentioned above, there are only two things to configure in the virtual machine:

  • Inside the virtual machine I've mounted a shared folder as a network drive, this enables the two build bots to easily exchange files
  • After creating the network drive I added buildbot.cmd to my Start → Programs → Startup menu so that the build bot runs automatically after the VM is started and shuts down the VM after building all projects


If you have questions, bug reports, suggestions, etc. the author can be contacted at The latest version is available at and


This software is licensed under the MIT license.
© 2011 Peter Odding <>.


  • This license only applies to the build bot itself -- I don't have any affiliation with the projects supported by the build bot, I'm just a happy user
  • Should the original authors have objections against this build bot, let me know and I will remove support for the project in question
  • I don't give any guarantees as to the published binaries. They're generated in a dedicated machine so it's very unlikely that a virus could sneak in, but you never know until you've scanned the binaries yourself...
Something went wrong with that request. Please try again.