Update example to use C89 syntax
Properly check GNUC version for barrier support
Rename few macros

Renamed the macros that are basically abstractions for other functions,
so the macros look like functions.
Add support for __APPLE__