Backport library to API 10