Added additional OS support for loading libraries (mostly untested)