set target to android-17, cleaned up logic