Fixed Windows ifdef
Added include required by boost::system::system_category
Removed direct reference to pthread which causes problems in Windows