Fixed serialization and deserialization -- needed to clear existing rows when deserializing and use correct file version id when serializing.
Updated packaging and build scripts.
Copied packaging from selfdiscovery.