Replicated logic from custom meta functions

Allows initialization and upgrade to occur before function files are
included
Merge branch 'Custom-Meta-Init' into local.master