[library] Check current SDK version instead of target SDK verion.

Fixes #23, crash on 2.3 devices.