Build fixes

As demanded by upstream. :-)