Ubuntu Touch(又称Ubuntu Phone)是Canonical公司与Ubuntu社区所开发的移动设备操作系统,专为触屏行动设备所设计,例如:智能手机和平板电脑。

现在国外开发者Vince1171放出了Oneplus3/3t的UbuntuTouch适配版,现在我们就安装试试。

首先下载所需文件:

说明:本文以ubports-touch.rootfs-xenial-armhf.tar.gz系统镜像为例,官方还提供了以下三个镜像,想试的可以试下。

下载完成后下来开始安装,本地PC环境为LinuxMint(类Ubuntu),建议以下操作在root权限下操作。

安装工具

首先安装adb以及fastboot工具

    sudo apt install adb fastboot

解锁手机

接下来设置手机,设置->关于手机,连击版本号打开开发者选项,进入开发者选项打开OEM解锁

然后关闭手机,按住电源+音量上进入fastboot模式,链接手机和电脑。

在电脑端运行以下命令解锁

    fastboot oem unlock

按照手机提示,选择YES开始解锁,完成后手机重启。

安装Recovery

重启手机进入fastboot模式

接下来通过以下命令安装Recovery

    fastboot flash recovery TWRP_recovery.img

安装完成后,关闭手机,按电源+音量减进入Recovery

安装LineageOS

通过TWRP Recovery来刷入LineageOS ROM,完成后双清重启再次进入Recovery,通过数据线连接手机,进行后面操作。

安装UbuntuTouch

手机进入Recovery模式,通过数据线连接电脑,然后开始按照以下进行安装。

    root@hpzb14:/media/alair/data# ./halium-install.sh -p ut ubports-touch.rootfs-xenial-armhf.tar.gz system.img 
    Debug: Chosen rootfs is ubports-touch.rootfs-xenial-armhf.tar.gz
    Debug: Chosen android image is system.img
    Debug: Chosen release is ut
    
    I: Writing rootfs into mountable image
    I: Writing android image into mountable image
    I: Running post installation tasks
    enabling Mir ... [done]
    enabling SSH ... [done]
    Please enter a new password for the user 'phablet':
    输入新的 UNIX 密码: 
    重新输入新的 UNIX 密码: 
    passwd: password updated successfully
    I: Unmounting images
    I: Shrinking images
    e2fsck 1.44.1 (24-Mar-2018)
    resize2fs 1.44.1 (24-Mar-2018)
    将 .halium-install-imgs.6Kcou/system.img 上的文件系统调整为 120200 个块(每块 4k)。
    开始第 2 步(共 32687 步)
    正在重定位块            XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
    开始第 3 步(共 24 步)
    正在扫描inode表          XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
    .halium-install-imgs.6Kcou/system.img 上的文件系统现在为 120200 个块(每块 4k)。
    
    I: Pushing rootfs and android image to /data via ADB
    .halium-install-imgs.6Kcou/rootfs.img: 1 file pushed. 7.1 MB/s (3221225472 bytes in 433.702s)
    .halium-install-imgs.6Kcou/system.img: 1 file pushed. 7.7 MB/s (492339200 bytes in 61.329s)
    I: Cleaning up host
    I: Cleaning up device

然后继续在Recovery模式下:

adb shell 'touch /data/.writable_image; mkdir /a; mount /data/rootfs.img /a; echo manual | tee /a/etc/init/rsyslog.override; touch /a/.writable_device_image; umount /a; sync'

以上操作完后,重启手机进入fastboot模式,按照以下安装引导系统程序。

    root@hpzb14:/media/alair/data# fastboot flash boot halium-boot.img 
    < waiting for any device >
    target reported max download size of 435159040 bytes
    sending 'boot' (15468 KB)...
    OKAY [  0.410s]
    writing 'boot'...
    OKAY [  0.119s]
    finished. total time: 0.529s

至此安装完成,重启即可进入UbuntuTouch系统。

重要提示

进入系统后,打开Terminal输入sudo ubports-qa install xenial_-_haliumfixup && sudo apt install pulseaudio-modules-droid-glue-24更新音频模块。如果默认软件源速度太慢,可以参考此文先更换为国内源。

UbuntuTouch系统截图

ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t ubuntutouch on oneplus3t

参考: