Fixes 2356, [Android] SDL_JoystickGetAttached does not function

Also fix a potential NULL pointer access in android/SDL_SYS_JoystickGetGUID

--HG--
extra : source : 215d88851d3a51422efeb30d50476e8b34337a95
Fixed XF86 VidMode extension dynamic loading with CMake project.

--HG--
extra : rebase_source : ade5d676aa8087b8ad54462e9d9569985fd8c66e