use __APPLE__ instead of OSX

use __APPLE__ for predefined os detection  OSX.
add semicoron

add semicoron