fix some warnings and include libusb building to cmake build system