We should just shutdown io and wait for disconnect callback in
disconnect function, otherwise we might get some races e.g. when doing
connect/disconnect SCO. This patch fix that.
This patch adds sco lib which gives means to create SCO object with
API to create listening socket, connect and disconnect.
This is going to be common code for HFP HF and HFP GW.
For now we support only one SCO at the time.
SCO listening socket is created once bt_sco_new() is called, but
SCO connection is possible only if confirm and connect callbacks are
registered.
Sco lib is not aware about voice settings. Those must be provided
on bt_sco_connect or in confirm callback.
This patch also adds this lib to Android build.