跳转至

Android#

Preparation#

  1. Install adb on macOS/Linux

    • Follow the officail website's Command line tools only part, download the zip file according to your OS then unzip it to the your prefered directory such as ~/bin, ~/.local/bin, or /usr/local/bin.

    • Use package manage tools:

    macOS $ brew install --cask android-platform-tools
    Linux $ sudo apt install android-sdk-platform-tools
    
  2. Root (Optional): Following the LineageOS Wiki according to your Mobile Phone brand and model.

LineageOS#

System Configs#

Softwares#

  1. 开源应用商店F-Droid官方 APK 下载地址,其项目托管在 GitLab 上,这里是它的客户端 Release,安装完成后,根据这个帮助文档 配置 mirror 源以加速访问。

  2. [Termux]

  3. [KOReader]

  4. [NewPipe]

Flutter 开发环境配置(针对 Linux 桌面系统)#

  1. 获取 Flutter SDK 文件,并解压

    wget -c "https://storage.flutter-io.cn/flutter_infra_release/releases/stable/linux/flutter_linux_3.10.0-stable.tar.xz" -P ~/Downloads
    tar xf ~/Downloads/flutter_linux_3.10.0-stable.tar.xz -C ~
    
  2. 配置 Flutter 环境变量

    # ~/.profile
    
    if [ -d "$HOME/flutter/bin" ] ; then
        PATH="$HOME/flutter/bin:$PATH"
    fi
    export PUB_HOSTED_URL=https://pub.flutter-io.cn
    export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn
    export CHROME_EXECUTABLE=/usr/bin/chromium
    
  3. 安装基本软件环境

    sudo apt install openjdk-17-jdk libglu1-mesa clang cmake ninja-build pkg-config libgtk-3-dev liblzma-dev
    
  4. 安装 Android Studio SDK

    wget -c "https://dl.google.com/android/repository/commandlinetools-linux-9477386_latest.zip" -P ~/Downloads
    mkdir -pv ~/.android/sdk/cmdline-tools/latest
    tar xf ~/Downloads/commandlinetools-linux-9477386_latest.zip
    mv -v cmdline-tools/* ~/.android/sdk/cmdline-tools/latest
    
    cd ~/.android/sdk/cmdline-tools/latest/bin
    
    ./sdkmanager "platforms;android-33" "system-images;android-33;google_apis;x86_64" "platform-tools"
    yes | ./sdkmanager --licenses
    
  5. 检验 Flutter 环境配置

    flutter config --no-analytics
    flutter precache
    flutter config --android-sdk ~/.android
    flutter doctor --android-licenses
    flutter doctor 
    

参考资料