Add conditional os dependant library linking