moved tmeta code to torlib