[Sony Xperia XZ1 Compact ROMs, Kernels, Recoveries,] Flamefire:
LineageOS 17/18/19 for Sony Xperia XZ1 Compact

RELEASE

This is an alternative ROM for the Sony Xperia XZ1 Compact.

It is based on the great work of modpunk and derf elot from https://xdaforums.com/t/rom-lineageos-18-1-unofficial-2-0-update-2021-01-20.4047763/ with recent security updates, some backported from newer versions.

FEATURES

Signed with dev keys

EAS kernel

Passes SafetyNet out of the box (thanks Rooted_Ansh, Havoc-OS Team and kdrag0n)

Seedvault (Video)

IMS support (thanks to Rooted_Ansh and also Shujath)

17.1 has stock Sony camera (not possible on 18+)

DOWNLOAD

You can download the latest release here. (Backup download when AFH isn't uploading)

HINT: Download both the ZIP and md5sum file so TWRP can check the consistency of the upload/download.

Make sure you download the right version, vanilla LineageOS is named lineage-*UNOFFICIAL-lilac.zip while the MicroG version is named lineage-*-MICROG--lilac.zip

REQUIRED FIRMWARE: 47.2.A.11.228

IMPORTANT: I only use the 17.1 releases myself. The 18.1/19.1 are build from mostly the same sources and roughly tested, i.e. boots, WiFi works and SN passes/MicroG self check shows OK.

INSTALLATION

IMPORTANT: Magisk seems to cause issues (bootloops) on update, so remove it first and reinstall if required. Note that Magisk is usually not required unless you want root.

Put the zip file of the ROM on your SD card or internal store and boot into recovery.

When coming from stock ROM, do a full wipe (i.e. factory reset) via "Wipe". You don't need to wipe system. When flashing the stock ROM you can select to not keep user data which is equivalent to this step.

Go to "Install", select the zip file and add optionally the gapps zip. Then flash it.

After updates you may now wipe cache&dalvik (option after install)

I suggest to use modpunks TWRP recovery. Again: Don't forget the md5sum file!

TWRP 3.3.1-0 by modpunk / derf elot

Or use the latest TWRP for 17.1/18.1 or TWRP for 19.1.

3.7.0

Seems to work well with latest updates (decryption working) but LineageOS 19.1 (Android 12) requires the ones with "_12" suffix, e.g. 3.6.2_12.

For ease of use I suggest to flash this recovery (only required once):

Boot in Fastboot mode: Hold "Volume Up" while connecting the USB cable to phone and PC

Flash TWRP by running this on the PC: fastboot flash recovery twrp-3.3.1-0-lilac-android10-1.img

(adjust the filename if necessary)

From now you can boot TWRP by turning on the phone with "Volume Down" + Power

I heavily recommend to make a full backup before any installation so you can go back in case of issues. Flashing an older ROM usually helps to recover bootloops etc.

Upgrades between versions​

Dirty-flashing (e.g. from 17.1 to 18.1) works well but you have to also flash a GApps version matching the Android version or the device will bootloop.

For the upgrade to 19.1 you may need to fully remove OpenGapps by wiping /system and install e.g. MindTheGapps.

SUPPORT

There is NONE. If you have any issues or question ask in the thread so maybe someone else knows the answer.

I'm just providing the ROM (Lineage 17.1 variant) I use myself for others to try too and build the Lineage 18/19 ROMs without much testing.

Contributions to the sources are welcome and likely get integrated into the next release.

Contributors

modpunk, derf elot, Rooted_Ansh, Flamefire, linckandrea

Source Code: Device tree: https://github.com/Flamefire/android_device_sony_lilac

Kernel: https://github.com/Flamefire/android_kernel_sony_msm8998

If you want to buy me a coffee/beer, I'll appreciate it but it is not necessary.

Special thanks to landsome for donating a test phone for bug hunting and development.

ROM OS Version: Android 10/11/12

ROM Kernel: Linux 4.4.x

Based On: LineageOS

GApps: None included, except for the MICROG builds. Recommended is OpenGApps for 17/18 and MindTheGapps for 19.