proper compile tpl