Basically, the add-on would have to be called ZZZ_UnusedAddons, so it is executed first. It then hooks the function for loading an add-on and keeps track which bricks, sounds, prints, events, items, stuff belong to which add-on. Later you could iterate all bricks on the server and figure out which add-ons are never used. Obviously, it would report all script add-ons to be unused, but you can count on the intelligence of the host, right?