Fixed build issues related to sync getting merged into std

Thanks, I've fixed that up so it uses a Mutex<()> now.