Update to new format for add-on definition.

(Includes part of the change from #1