porting templates