Properly check for HTTP support and handle the case where it's disabled. Also fixes the include paths broken by 3e7f0ddc.