Added better support for older platforms