updated for apple port