Skip to main content

Source compilation OmniROM 12.1 for Orange Pi Zero 2W / Zero 3

This article is about OmniROM compilation for Orange Pi Zero 2W / Zero 3.


1. Follow this link to download source code:

https://github.com/YAJATapps/android_apollo-p2_local_manifest/blob/omni-12.1/README.md 


2. After syncing the source code, configure the build:

cd longan
./build config


Welcome to mkscript setup progress
All available platform:
0. android
1. linux
Choice [android]: 0
All available ic:
0. h618
Choice [h618]: 0
All available board:
0. ft
1. p1
2. p2
3. p3
4. p7
5. p7l
6. perf1
7. perf2
8. perf3
9. qa
Choice [p2 - Zero 2W OR p3 - Zero 3]: 2
All available flash:
0. default
1. nor
Choice [default]: 0
All available kern_ver:
0. linux-5.4
Choice [linux-5.4]: 0
All available arch:
0. arm
1. arm64
Choice [arm64]: 1
......
*** Default configuration is based on 'sun50iw9p1smp_h618_android_defconfig'
#
# configuration written to .config
#
make[1]: Leaving directory '/home/omni12/longan/out/kernel/build'
make: Leaving directory '/home/omni12/longan/kernel/linux-5.4'
INFO: clean buildserver

INFO: prepare_buildserver


3. Build the kernel:

    ./build.sh


4. Go back to root directory from longan directory:

    cd ..


5. Source build environment:

    source build/envsetup.sh


6. Config and Lunch:

  • If you are compiling for Zero 3 then edit device/allwinner/apollo-p2/device.mk

         Set PRODUCT_ORANGE_PI_ZERO_2W to false. No need to change anything for Zero 2W.

  • If you are compiling for arm64 then edit device/softwinner/apollo/common/system/config.mk
          Set TARGET_ARCH ?= arm64

    

    lunch omni_apollo_p2-userdebug


7. Make android:

    make


8. Packing the image into allwinner format:

    cd longan

 

    If you are compiling for Zero 3 then edit build/pack. 

    change the line 79 from "PACK_BOARD=${FLAGS_board} # p3"    to    "PACK_BOARD=p3".

    No need to change anything for Zero 2W.


    pack


The output image is generated at longan/out/h618_android12_p2_uart0.img OR h618_android12_p3_uart0.img for Zero 3.

Burn it with PhoenixCard.



Comments

Popular posts from this blog

OmniROM 12.1 v2 (ARM64) for Orange Pi Zero 2W / Zero 3

This is an update for my earlier port of OmniROM 12.1 for Orange Pi Zero 2W /  Zero 3 . This build is ARM64. It can run both 32 and 64 bit apks. The sources are available at this  blog . There are some graphics libraries that don't have 64 bit versions. I have used the available 32 bit versions of them but the eventual goal will be to replace the proprietary  libraries  with open source GPU drivers like mesa3d panfrost .   Unzip the file before using in Phoenix card. It should be flashed to sd card using Phoenix card. Same as the OEM image instructions . DOWNLOAD: For Orange Pi Zero 2W: omni-12.1_20241018_arm64_zero2w.zip For Orange Pi  Zero 3: omni-12.1_20241018_arm64_zero3.zip

OmniROM 12.1 v3 (TV) (ARM64) for Orange Pi Zero 2W / Zero 3

This is OmniROM 12.1 TV variant for O range Pi Zero 2W /  Zero 3. TWRP is included. You should install TV gapps on it to get google TV launcher etc. Without that it has a very basic launcher and not very usable. Source code: blog Included TWRP has lots of bugs, especially the UI. But it works well enough to be able to install gapps etc. Download TV gapps: GitHub   reboot to recovery mode. TWRP advanced > add side load > swipe to enable  adb sideload  MindTheGapps-12.1.0-arm64-ATV-20230321_143953.zip This settings menu sections can be switched with arrow keys. If you get stuck on this remote screen then execute. adb shell pm disable-user --user 0 com.google.android.tungsten.setupwraith After installing gapps. Unzip the file before using in Phoenix card. It should be flashed to sd card using Phoenix card. Same as the OEM image  instructions . DOWNLOAD: For Orange Pi Zero 2W: omni-12.1_tv_20241210_arm64_zero2w.zip For O...

OmniROM 12.1 v1 for Orange Pi Zero 2W

I ported this build of OmniROM Android 12.1 for Orange Pi 2W. It is made for tablets, unlike the one that manufacturer provides for TV. The sources are available at this  blog . It should be flashed to sd card using Phoenix card. Just like the oem image. Download: omni-12.1_20240901_apollo_p2.img Compressed version (unzip before using): omni-12.1_20240901_apollo_p2.zip