Removed all platform-specific code from sf and made it an archive to be linked with the demo sources