Linker options for Mac OSX

Added conditional linker options for Mac OSX to fix linker errors.