Based on Android 5.1.1 AOSP, CyanogenMod 12.1 stable builds are now available for HTC One M8. The CyanogenMod team has released the first CM 12.1 stable releases for various Samsung, LG, Sony, HTC, and Nexus devices. You can now flash CM 12.1 Android 5.1.1 Lollipop on your HTC One M8 too. Follow this guide for files and steps.
Prerequisites to update HTC One M8 to CM 12.1 Stable Release Android 5.1.1:
Backup any important datafrom your HTC One M8 as a complete wipe will be required during the flashing process.Install USB drivers for your HTC device. Check outthis link.Enable USB debugging option on your device:Settings>DevelopmentOptions>USB debugging.Ensure that yourHTC One M8's bootloader is unlockedand that you have a recovery tool likeTWRPor CWM.Your device must be charged to at least 80% of power.
How to update HTC One M8 to CM 12.1 Android 5.1.1 Lollipop:
Required files:
Download CM 12.1Android 5.1.1 Lollipopcustom ROMfor HTC One M8.Also download theGAppspackage for your device.
Here are the steps to help youupdate HTC One M8 to Android 5.1.1 basedCM 12.1custom firmware:
Connect yourHTC Oneto your computer using a USB cable and copy the ROM and GApps zip filesto your phone’s SD card root folder.Disconnect theUSBcord andpower off your HTC device.Boot your device in the Bootloader mode by pressing and holding theVolume DownandPowerkeys.Follow the on screen instructions and selectBootloader> go toRecovery.Once in recovery, perform wipe data task: from the CWM recovery menu, selectwipe data / factory resetand confirm the process.Also performwipe cache partitionfollowed bywipe dalvik cache(from Advanced).From recovery main menu, selectinstall zip from sdcardfollowed bychoose zip from sdcard.Locate the CM 12.1Android 5.1.1 custom firmware file and confirm the flashing process.Once the ROM is flashed successfully, repeat the above step, but select GApps package this time.Return back to main recovery menu and reboot yourHTC One M8into the new custom ROM. First boot takes a good 5 minutes so please be patient.