Some porting done