ENH: Fix template building issues with BAW.