Added support for resources on OSX and iOS.