Use type of main part to create pkg