AHardwareBuffer make the system API dynamic
Instead of asserting and crashing the tests, when
the AHardwareBuffer handle is not supported, throw an exception:
"Platform doesn't support Android Hardware Buffer handles"
Move all of the AHB system APIs from implicit to dynamically loaded
and encapsuate those within the AndroidHardwareBufferExternalApi class.
Dynmaically probing and loading the AHB related API allows for run-time
selection of the symbols and to determine if AHB APIs are supported or not.
This, also, allows for the CTS to always be built against NDK API26/28.
After this change, we can make the default NDK API as API26, since
this change would allow for the CTS to work on Android APIs 21-25,
as well as the newer API versions of the NDK.
In addition, moved all of the AHB related interfaces to one place:
vktExternalMemoryUtil.cpp.
Affects:
dEQP-VK.api.external.memory.android_hardware_buffer.*
Components: Vulkan
VK-GL-CTS issue: 1192
Change-Id: I5145eff2fbcf084bfc8ff42751102979f9a28d72