Add plumbing for building plugins

I’ve had to rename the plugin source filenames because RequireJS will use
the filename as the AMD module name.