Unofficial PreferenceFragment compatibility layer for Android 1.6 and up. Includes resources so add this as a library project to your project.
This solution is better than all other solutions. Add this project as a library project to your workspace. You can keep everything including your fragment transaction as it is and when importing the PreferenceFragment
do it like the following.
import android.support.v4.preference.PreferenceFragment;
instead of
import android.preference.PreferenceFragment;
You should add android-support-v4-preferencefragment as library according to http://developer.android.com/guide/developing/projects/projects-eclipse.html#ReferencingLibraryProject
Or download the jar, and add it to the libs folder under your project (if your IDE is eclipse).