I need to use a HTC Legend which runs Android 2.2  to run
the open source nyaruka/android-sms-relay.
However, this app's build target is Android 4.2.
I tried to simply change the build target from 4.2 to 2.2 but was unable to compile the app.
I got the following errors:
public **ActionProvider** getActionProvider() {
        // Noop
        return null;
    }
ActionProvider cannot be resolved to a type
@Override
protected Context getActionBarThemedContext() {
         return mActivity.**getActionBar()**.getThemedContext();
    }
The method getActionBar() is undefined for the type Activity
 ImageButton actionButton = new ImageButton(mActivity, null,
                itemId == android.R.id.**home**
                        ? R.attr.actionbarCompatItemHomeStyle
                        : R.attr.actionbarCompatItemStyle);
        actionButton.setLayoutParams(new ViewGroup.LayoutParams(
                (int) mActivity.getResources().getDimension(
                        itemId == android.R.id.**home**
                                ? R.dimen.actionbar_compat_button_home_width
                                : R.dimen.actionbar_compat_button_width),
                ViewGroup.LayoutParams.FILL_PARENT));
home cannot be resolved or is not a field
Anyone who down voted this question, please explain the reason!