20 Commits

Author SHA1 Message Date
Douglas Teles a1efd4fc01 Pre-merged panel DTBs: eliminate U-Boot fdt apply bugs
Users reported that non-default panel overlays caused broken display,
audio, and controls. Root cause: BSP U-Boot's fdt apply has bugs with
property replacement of different-sized data, corrupting the DTB.

Fix: apply overlays at build-time using fdtoverlay (verified working)
instead of at boot-time. Each panel now gets a pre-merged kernel-*.dtb.
U-Boot simply loads the right DTB by name — no fdt apply needed.

- generate-panel-dtbos.sh: add fdtoverlay pre-merge step
- build-image.sh: copy pre-merged DTBs instead of ScreenFiles
- boot.ini: load PanelDTB by name, remove fdt addr/resize/apply
- panel-detect.py: write DTB filename instead of DTBO overlay path
2026-02-28 00:14:54 -03:00
Douglas Teles e4294ab47b Two-image build pipeline, clone support, initramfs splash
- Clone variant: mainline U-Boot v2025.10, boot.scr, clone DTS (type5)
- Initramfs splash: archr-init.c with embedded BMP, sub-second display
- Panel wizard: auto-detect with fsync persistence, evdev X-button reset
- Hotkeys: adc-keys volume for clone, HP jack detection, brightness persist
- Boot.ini: ASCII-only (no Unicode), GPIO check removed
- ES wrapper: removed framebuffer blanking (preserves splash)
- Build pipeline: both variants, splash generation, panel DTBOs
- .gitignore: exclude large bootloader trees and build artifacts

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 22:38:47 -03:00
Douglas Teles 70765e96bd update 26.02.25 2026-02-25 17:22:34 -03:00
Douglas Teles 2ccf5383ac update 26.02.23 2026-02-23 03:03:09 -03:00
Douglas Teles 476b05cd9a fix roadmap 2026-02-22 14:46:19 -03:00
Douglas Teles a9029b419f Fix ROADMAP.md diary timeline ordering
Move Day 17-18 entry to correct chronological position
(before "What's Left for v1.0 Stable", not after it).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 14:43:37 -03:00
Douglas Teles 18c229177a First successful build — 11 pipeline gaps fixed, repo organized
Build pipeline now produces a working bootable image. Found and fixed
11 gaps between the manually-built working SD and build-all.sh output:

Boot partition:
- extlinux.conf as primary boot method (U-Boot loads first)
- PanCho removed from boot.ini and build-image.sh
- Stale uInitrd removed (caused wrong boot path)
- logo.bmp (U-Boot native BMP) replaces broken splash-1.raw
- fstab uses LABEL=ROMS instead of /dev/mmcblk1p3
- Only R36S DTB copied (no extra r35s/rg351mp-linux)

Root filesystem:
- emulationstation.service created and enabled
- getty@tty1 disabled (ES takes over tty1)
- archr-boot-setup: Before=emulationstation.service, simplified
- All services use After=local-fs.target (not removed getty)
- boot-timing captures ES profiling data

New files added to repo:
- build-mesa.sh, build-retroarch.sh (were untracked)
- Custom DTS, ALSA config, controller autoconfig
- Runtime scripts (retroarch-launch, pmic-poweroff, hotkeys)
- VLC stub source, timezone data

Repo cleanup:
- README.md rewritten with build instructions + architecture
- .gitignore expanded (test scripts, failed approaches, logs)
- splash-show.sh removed (failed splash approach)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 14:01:13 -03:00
Douglas Teles 351e024374 update 26.02.19 2026-02-20 03:14:24 -03:00
Douglas Teles 4b88153812 update 26.02.18 2026-02-18 23:46:36 -03:00
Douglas Teles 54e8201a6f update 26.02.17/18 2026-02-18 00:34:51 -03:00
Douglas Teles 9aa062e0fc update 26.02.15 2026-02-15 23:37:25 -03:00
Douglas Teles 6b1934155a update 26.02.14/15 2026-02-15 02:27:02 -03:00
Douglas Teles a580bd3ce0 update 26.02.13/14 2026-02-14 04:14:39 -03:00
Douglas Teles 68b9ff798a Audio card working, LD_PRELOAD fix, volume/brightness hotkey fixes
Audio (3-iteration DTS fix chain):
- Removed duplicate pinctrl from codec node (pin conflict)
- Fixed sound-dai to reference &rk817_codec (MFD of_node mismatch)
- Removed DAPM routing/widgets (BSP codec has no DAPM widgets)
- Added 7 missing battery BSP properties

Runtime fixes:
- unset_preload.so prevents gl4es LD_PRELOAD inheritance to subprocesses
- ES Patch 5: getShOutput() null safety for popen() failure
- Volume hotkeys: use 'DAC Playback Volume' (not enum 'Playback')
- Brightness: 5% minimum clamp, persistence across reboots
- current_volume: reads correct ALSA control
- perfmax/perfnorm: guard DMC writes with file existence check

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 21:07:37 -03:00
Douglas Teles 6e0e085eb8 gl4es GPU pipeline, ES display fixes, runtime hardening
GPU rendering:
- Panfrost driver working (6 root causes fixed)
- gl4es cross-compiled for aarch64 (GOA_CLONE=ON)
- ES switched to Desktop GL renderer (-DGL=ON, Renderer_GL21.cpp)
- Pipeline: ES (GL 2.1) → gl4es → GLES 2.0 → Panfrost (Mali-G31)

ES display (5 root causes fixed):
- SDL3 KMSDRM rebuild (ALARM ships without it)
- Autologin approach (systemd service can't get DRM master)
- MAJOR/MINOR version bug fix
- GL context restore after setIcon()
- Null safety for glGetString

New files:
- rebuild-es-sdcard.sh (quick SD card rebuild)
- config/PanCho.ini (18-panel selection)
- config/es_input.cfg (gpio-keys + adc-joystick)
- config/gamecontrollerdb.txt (SDL controller mappings)
- scripts/archr-hotkeys.py (volume, brightness, headphone)
- scripts/test-kmsdrm.py (KMSDRM diagnostic)
- bootloader/u-boot-r36s-working/ (fixed U-Boot)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 21:42:50 -03:00
Douglas Teles bfda02587e Update ROADMAP.md with detailed development diary
Expanded from summary format to day-by-day diary entries with
technical details: discoveries, failures, root causes, and fixes.
Covers all 16 sessions from Feb 4-11 based on conversation history.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 21:40:09 -03:00
Douglas Teles 2082ac4049 Add ROADMAP.md with full project timeline and release tracking
Documents all milestones from project inception (2026-02-04) through
today's gl4es + Panfrost GPU integration. Tracks what's left for v1.0
stable release. Links from README.md for visibility.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 21:31:23 -03:00
Douglas Teles 76d126a80f Tons of tons 2026-02-10 01:46:47 -03:00
Douglas Teles 84d7d19283 Add development documentation with technical context 2026-02-04 14:12:57 -03:00
Douglas Teles 487c4f2cbd Initial commit - Arch R project structure 2026-02-04 14:09:18 -03:00
3756 changed files with 14503 additions and 382676 deletions
-30
View File
@@ -1,30 +0,0 @@
---
name: Bug Report
about: Describe this issue
title: "[BUG]"
labels: ISSUE NEEDS REVIEW
assignees: ''
---
### Have you first checked existing issues and documentation for a solution?
[ArchR GitHub Issues](https://github.com/archr-linux/Arch-R/issues)
<!-- Any issue created without sufficient information may be closed. -->
### Describe the bug
<!-- A clear description of what the bug is. -->
### How to reproduce
Steps to reproduce the behavior:
1. Go to '...'
2. Play '....'
3. See error
### Information
- ArchR Version: [e.g. 20260316]
- Hardware Platform: [e.g. Powkiddy RGB20SX]
### Log file
<!-- Add debug log files that we can search for errors. -->
### Context
<!-- Add any context about the problem here. -->
-8
View File
@@ -1,8 +0,0 @@
blank_issues_enabled: false
contact_links:
- name: Help and Support
url: https://discord.gg/Q5RY3gEuwv
about: Please ask for help and post questions in our Discord
- name: Feature Requests
url: https://discord.gg/Q5RY3gEuwv
about: Please ask for feature requests in our Discord
-119
View File
@@ -1,119 +0,0 @@
&nbsp;&nbsp;<img src="distributions/ArchR/logos/archr-logo.png" width=192>
#
ArchR is a community developed Linux distribution for handheld gaming devices, forked from [ROCKNIX](https://github.com/ROCKNIX/distribution). Our goal is to produce an operating system that has the features and capabilities that we need, and to have fun as we develop it.
## Licenses
ArchR is a Linux distribution forked from ROCKNIX, made up of many open-source components. Components are provided under their respective licenses. This distribution includes components licensed for non-commercial use only.
### ArchR Branding
ArchR branding and images are licensed under a [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License](https://creativecommons.org/licenses/by-nc-sa/4.0/).
#### You are free to
* Share — copy and redistribute the material in any medium or format
* Adapt — remix, transform, and build upon the material
#### Under the following terms
* Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
* NonCommercial — You may not use the material for commercial purposes.
* ShareAlike — If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original.
### ArchR Software
Copyright (C) 2024-2026 ArchR (https://github.com/archr-linux). Derived from ROCKNIX, Copyright (C) 2024 ROCKNIX (https://github.com/ROCKNIX).
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
## Installation
* Download the latest version of ArchR.
* Decompress the image.
* Write the image to an SDCARD using an imaging tool. Common imaging tools include [Balena Etcher](https://www.balena.io/etcher/), [Raspberry Pi Imager](https://www.raspberrypi.com/software/), and [Win32 Disk Imager](https://sourceforge.net/projects/win32diskimager/). If you're skilled with the command line, dd works fine too.
### Installation Package Downloads
| **Device/Platform** | **Download Package** | **Documentation** |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------|
| **Anbernic RG351P/M/V, Game Console R33S/R35S/R36S, ODROID Go Advance, ODROID Go Super, Magicx XU10, Powkiddy V10/RGB10** | [ArchR-RK3326.aarch64-$DATE-a.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3326.aarch64-$DATE-a.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3326/) |
| **Magicx XU Mini M, Powkiddy RGB10X** | [ArchR-RK3326.aarch64-$DATE-b.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3326.aarch64-$DATE-b.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3326/) |
| **Anbernic RG353P/M/V/VS/PS, RG503, RGARC-D/S, Powkiddy RK2023, RGB10 Max 3, RGB30, RGB20SX, RGB20 Pro** | [ArchR-RK3566.aarch64-$DATE-Generic.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3566.aarch64-$DATE-Generic.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3566/) |
| **Anbernic RG552** | [ArchR-RK3399.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3399.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3399/) |
| **Anbernic RG35XX PLUS/H/SP/2024, RG40XX V/H, RGCUBEXX, RG34XX SP, RG28XX [Must Follow Install Instructions](https://github.com/archr-linux/Arch-R/wiki/h700-installation)** | [ArchR-H700.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-H700.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/H700/) |
| **Hardkernel ODROID Go Ultra, Powkiddy RGB10 Max 3 Pro** | [ArchR-S922X.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-S922X.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/S922X/) |
| **Gameforce Ace (default). Orange Pi 5 / 5 Plus, Radxa Rock 5a / 5b / 5b+ / CM5, and Indiedroid Nova** | [ArchR-RK3588.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3588.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3588/) |
| **Powkiddy x55** | [ArchR-RK3566.aarch64-$DATE-Powkiddy_x55.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3566.aarch64-$DATE-Powkiddy_x55.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/RK3566-X55/) |
| **Retroid Pocket 5, Pocket Mini, Pocket Mini V2, Pocket Flip2** | [ArchR-SM8250.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8250.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/SM8250/) |
| **Ayn Odin 2, Odin 2 Mini, Odin 2 Portal, Thor, Ayaneo Pocket ACE/EVO/DMG/DS** | [ArchR-SM8550.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8550.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/SM8550/) |
| **Ayaneo Pocket S2** | [ArchR-SM8650.aarch64-$DATE.img.gz](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8650.aarch64-$DATE.img.gz) | [documentation](/documentation/PER_DEVICE_DOCUMENTATION/SM8650/) |
## Upgrading
* Download and install the update online via the System Settings menu.
* If you are unable to update online
* Download the latest version of ArchR from Github
* Copy the update to your device over the network to your device's update share.
* Reboot the device, and the update will begin automatically.
### Update Package Downloads
| **Device/Platform** | **Download Package** |
|---------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------|
| **Anbernic RG351P/M/V, Game Console R33S/R35S/R36S, ODROID Go Advance, ODROID Go Super, Magicx XU10, XU Mini M, Powkiddy V10/RGB10/RGB10X** | [ArchR-RK3326.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3326.aarch64-$DATE.tar) |
| **Anbernic RG353P/M/V/VS/PS, RG503, RGARC-D/S, Powkiddy RK2023, RGB10 Max 3, RGB30, RGB20SX, RGB20 Pro, X55** | [ArchR-RK3566.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3566.aarch64-$DATE.tar) |
| **Anbernic RG552** | [ArchR-RK3399.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3399.aarch64-$DATE.tar) |
| **Anbernic RG35XX PLUS/H/SP/2024, RG40XX V/H, RGCUBEXX, RG34XX SP, RG28XX** | [ArchR-H700.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-H700.aarch64-$DATE.tar) |
| **Hardkernel ODROID Go Ultra, Powkiddy RGB10 Max 3 Pro** | [ArchR-S922X.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-S922X.aarch64-$DATE.tar) |
| **Gameforce Ace, Orange Pi 5 / 5 Plus, Radxa Rock 5a / 5b / 5b+ / CM5 and Indiedroid Nova** | [ArchR-RK3588.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-RK3588.aarch64-$DATE.tar) |
| **Retroid Pocket 5, Pocket Mini, Pocket Mini V2, Pocket Flip2** | [ArchR-SM8250.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8250.aarch64-$DATE.tar) |
| **Ayn Odin 2, Odin 2 Mini, Odin 2 Portal, Thor, Ayaneo Pocket ACE/EVO/DMG/DS** | [ArchR-SM8550.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8550.aarch64-$DATE.tar) |
| **Ayaneo Pocket S2** | [ArchR-SM8650.aarch64-$DATE.tar](https://github.com/archr-linux/Arch-R/releases/download/$DATE/ArchR-SM8650.aarch64-$DATE.tar) |
## Documentation
### Contribute
* [Building ArchR](https://github.com/archr-linux/distribution/wiki/contribute/build/)
* [Code of Conduct](https://github.com/archr-linux/distribution/wiki/contribute/code-of-conduct/)
* [Contributing to ArchR](https://github.com/archr-linux/distribution/wiki/contribute/)
* [Modifying ArchR](https://github.com/archr-linux/distribution/wiki/contribute/modify/)
* [Adding Hardware Quirks](https://github.com/archr-linux/distribution/wiki/contribute/quirks/)
* [Creating Packages](https://github.com/archr-linux/distribution/wiki/contribute/packages/)
* [Pull Request Template](/PULL_REQUEST_TEMPLATE.md)
### Play
* [Installing ArchR](https://github.com/archr-linux/distribution/wiki/play/install/)
* [Updating ArchR](https://github.com/archr-linux/distribution/wiki/play/update/)
* [Controls](https://github.com/archr-linux/distribution/wiki/play/controls/)
* [Netplay](https://github.com/archr-linux/distribution/wiki/play/netplay/)
* [Configuring Moonlight](https://github.com/archr-linux/distribution/wiki/systems/moonlight/)
* [Device Specific Documentation](/documentation/PER_DEVICE_DOCUMENTATION)
### Configure
* [Optimizations](https://github.com/archr-linux/distribution/wiki/configure/optimizations/)
* [Shaders](https://github.com/archr-linux/distribution/wiki/configure/shaders/)
* [Cloud Sync](https://github.com/archr-linux/distribution/wiki/configure/cloud-sync/)
* [VPN](https://github.com/archr-linux/distribution/wiki/configure/vpn/)
### Other
* [Frequently Asked Questions](https://github.com/archr-linux/distribution/wiki/faqs/)
* [Donating to ArchR](https://github.com/archr-linux/Arch-R)
## Change Log
### New Features
* Added...?
### Updates
* Updated...?
### Bug Fixes
* Fixed...?
**Full Changelog**: https://github.com/archr-linux/Arch-R/compare/$LAST_TAG...$DATE
-174
View File
@@ -1,174 +0,0 @@
name: Build image
on:
workflow_call:
inputs:
PROJECT:
required: true
type: string
DEVICE:
required: true
type: string
OWNER_LC:
required: true
type: string
NIGHTLY:
description: "build nightly version"
type: string
required: true
OFFICIAL:
description: "build official version"
type: string
required: true
jobs:
build-aarch64-image:
runs-on: ubuntu-24.04
env:
JAVA_HOME: /usr
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
ARCH: aarch64
CACHE_KEY: ccache-aarch64-${{ inputs.DEVICE }}-image-${{ github.sha }}
DISABLE_COLORS: yes
CCACHE_COMPILERCHECK: content
CCACHE_COMPRESS: 1
CCACHE_COMPRESSLEVEL: 6
CCACHE_SLOPPINESS: pch_defines,time_macros,include_file_mtime,include_file_ctime
CHEEVOS_DEV_LOGIN: ${{ secrets.CHEEVOS_DEV_LOGIN }}
GAMESDB_APIKEY: ${{ secrets.GAMESDB_APIKEY }}
SCREENSCRAPER_DEV_LOGIN: ${{ secrets.SCREENSCRAPER_DEV_LOGIN }}
NIGHTLY: ${{ inputs.NIGHTLY }}
OFFICIAL: ${{ inputs.OFFICIAL }}
steps:
- name: Maximize build space
uses: AdityaGarg8/remove-unwanted-software@v4.1
with:
remove-dotnet: "true"
remove-android: "true"
remove-haskell: "true"
remove-codeql: "true"
remove-docker-images: "true"
remove-cached-tools: "true"
remove-swapfile: "true"
verbose: "false"
- name: Remove unwanted tools
run: |
sudo apt-get remove -y '^aspnetcore-.*' > /dev/null
sudo apt-get remove -y '^dotnet-.*' > /dev/null
sudo apt-get remove -y '^llvm-.*' > /dev/null
sudo apt-get remove -y 'php.*' > /dev/null
sudo apt-get remove -y '^mongodb-.*' > /dev/null
sudo apt-get remove -y '^mysql-.*' > /dev/null
sudo apt-get remove -y azure-cli google-chrome-stable firefox ${POWERSHELL} mono-devel libgl1-mesa-dri --fix-missing > /dev/null
sudo apt-get autoremove -y > /dev/null
sudo apt-get clean > /dev/null
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: true
root-reserve-mb: 4096
swap-size-mb: 4096
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Download arm (${{ inputs.DEVICE }})
if: ${{ inputs.DEVICE != 'SM8650' }}
uses: actions/download-artifact@v8
with:
name: arm (${{ inputs.DEVICE }})
- name: Extract artifact arm
if: ${{ inputs.DEVICE != 'SM8650' }}
run: |
tar --zstd -xf build.arm.tar.zst
- name: Clean up compressed arm file
if: ${{ inputs.DEVICE != 'SM8650' }}
run: rm build.arm.tar.zst
- name: Download emu-libretro (${{ inputs.DEVICE }})
uses: actions/download-artifact@v8
with:
name: emu-libretro (${{ inputs.DEVICE }})
- name: Extract artifact emu-libretro
run: |
cat build.emu-libretro.tar.part* > build.emu-libretro.tar
tar -xf build.emu-libretro.tar
- name: Clean up compressed emu-libretro file
run: rm build.emu-libretro.tar*
- name: Download emu-standalone (${{ inputs.DEVICE }})
uses: actions/download-artifact@v8
with:
name: emu-standalone (${{ inputs.DEVICE }})
- name: Extract artifact emu-standalone
run: |
cat build.emu-standalone.tar.part* > build.emu-standalone.tar
tar --skip-old-files -xf build.emu-standalone.tar
- name: Clean up compressed emu-standalone file
run: rm build.emu-standalone.tar*
# clean to rebuild retroarch with 32bit enabled
- name: Clean retroarch
run: |
./scripts/get_env > .env
docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/clean retroarch"
# clean to rebuild emulationstation with credentials
- name: Clean emulationstation
run: |
./scripts/get_env > .env
docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/clean emulationstation"
- name: build
run: |
./scripts/get_env > .env
set -e
{ docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/build_distro"; echo $? > docker_exit_code; } | tee output.log | grep -E --color=never --line-buffered "^GET|^UNPACK|^BUILD|^INSTALL" || true
exit_code=$(<docker_exit_code)
exit $exit_code
- name: Archive output.logs (${{ inputs.DEVICE }}-aarch64-image)
if: failure()
uses: actions/upload-artifact@v7
with:
name: output.logs (${{ inputs.DEVICE }}-aarch64-image)
path: |
output.log
./build.ArchR-${{ inputs.DEVICE }}.aarch64/.threads/logs/
- name: Get date
run: echo "DATE=$(date +'%Y%m%d')" >> $GITHUB_ENV
- uses: actions/upload-artifact@v7
with:
name: ArchR-image-${{ inputs.DEVICE }}-${{ env.DATE }}
path: |
target/ArchR-*.img.gz
target/ArchR-*.img.gz.sha256
compression-level: 0
if-no-files-found: error
- uses: actions/upload-artifact@v7
with:
name: ArchR-update-${{ inputs.DEVICE }}-${{ env.DATE }}
path: |
target/ArchR-*.tar
target/ArchR-*.tar.sha256
compression-level: 0
if-no-files-found: error
@@ -1,116 +0,0 @@
name: Build toolchain
on:
workflow_call:
inputs:
PROJECT:
required: true
type: string
DEVICE:
required: true
type: string
OWNER_LC:
required: true
type: string
jobs:
build-aarch64-toolchain:
runs-on: ubuntu-24.04
permissions:
actions: write
contents: read
env:
JAVA_HOME: /usr
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
ARCH: aarch64
CACHE_KEY: ccache-aarch64-${{ inputs.DEVICE }}-toolchain-${{ github.sha }}
DISABLE_COLORS: yes
CCACHE_COMPILERCHECK: content
CCACHE_COMPRESS: 1
CCACHE_COMPRESSLEVEL: 6
CCACHE_SLOPPINESS: pch_defines,time_macros,include_file_mtime,include_file_ctime
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: true
root-reserve-mb: 6144
swap-size-mb: 8192
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Retrieve ccache
run: |
URL="https://github.com/${{ github.repository_owner }}/${{ vars.CACHE_REPO || 'distribution-cache' }}/releases/download/ccache/ccache-aarch64-${{ inputs.DEVICE }}-toolchain.tar"
curl -L --fail --silent --show-error "$URL" | tar -xvf - || echo "Cache archive not found, skipping."
- name: Build
uses: corrupt952/actions-retry-command@v1.0.7
with:
command: |
./scripts/get_env > .env
set -e
{ docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/build_mt toolchain alsa-lib"; echo $? > docker_exit_code; } | tee output.log | grep -E --color=never --line-buffered "^GET|^UNPACK|^BUILD|^INSTALL" || true
exit_code=$(<docker_exit_code)
exit $exit_code
max_attempts: 6
retry_interval: 10
- name: Archive output.logs (${{ inputs.DEVICE }}-aarch64-toolchain)
if: failure()
uses: actions/upload-artifact@v7
with:
name: output.logs (${{ inputs.DEVICE }}-aarch64-toolchain)
path: |
output.log
./build.ArchR-${{ inputs.DEVICE }}.aarch64/.threads/logs/
- name: Clean ccache
run: |
export CCACHE_DIR=./build.ArchR-${{ inputs.DEVICE }}.aarch64/.ccache
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -M 500M
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -c
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -z
- name: Tar ccache
run: |
tar --remove-files -cf ccache-aarch64-${{ inputs.DEVICE }}-toolchain.tar ./build.ArchR-${{ inputs.DEVICE }}.aarch64/.ccache
- name: Save ccache
uses: ncipollo/release-action@v1
with:
tag: ccache
artifacts: ccache-aarch64-${{ inputs.DEVICE }}-toolchain.tar
allowUpdates: true
makeLatest: true
prerelease: true
body: ccache
token: ${{ secrets.GH_PAT }}
repo: ${{ vars.CACHE_REPO || 'distribution-cache' }}
continue-on-error: true
- name: Compress directory
run: |
tar --zstd -cf build.aarch64-toolchain.tar.zst \
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain \
./build.ArchR-${{ inputs.DEVICE }}.aarch64/build \
./build.ArchR-${{ inputs.DEVICE }}.aarch64/install_* \
./build.ArchR-${{ inputs.DEVICE }}.aarch64/.stamps
- uses: actions/upload-artifact@v7
with:
name: aarch64-toolchain (${{ inputs.DEVICE }})
path: build.aarch64-toolchain.tar.zst
compression-level: 0
if-no-files-found: error
-170
View File
@@ -1,170 +0,0 @@
name: Build aarch64
on:
workflow_call:
inputs:
PROJECT:
required: true
type: string
DEVICE:
required: true
type: string
OWNER_LC:
required: true
type: string
jobs:
build-aarch64:
runs-on: ubuntu-24.04
env:
EMULATION_DEVICE: no
ENABLE_32BIT: no
MODULES_PKG: no
JAVA_HOME: /usr
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
ARCH: aarch64
CACHE_KEY: ccache-aarch64-${{ inputs.DEVICE }}-base-${{ github.sha }}
DISABLE_COLORS: yes
CCACHE_COMPILERCHECK: content
CCACHE_COMPRESS: 1
CCACHE_COMPRESSLEVEL: 6
CCACHE_SLOPPINESS: pch_defines,time_macros,include_file_mtime,include_file_ctime
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: false
root-reserve-mb: 6144
swap-size-mb: 8192
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Retrieve ccache
run: |
URL="https://github.com/${{ github.repository_owner }}/${{ vars.CACHE_REPO || 'distribution-cache' }}/releases/download/ccache/ccache-aarch64-${{ inputs.DEVICE }}.tar"
curl -L --fail --silent --show-error "$URL" | tar -xvf - || echo "Cache archive not found, skipping."
- name: Download aarch64-toolchain (${{ inputs.DEVICE }})
uses: actions/download-artifact@v8
with:
name: aarch64-toolchain (${{ inputs.DEVICE }})
- name: Extract artifact aarch64-toolchain
run: |
tar --zstd -xf build.aarch64-toolchain.tar.zst
- name: Clean up compressed aarch64-toolchain file
run: rm build.aarch64-toolchain.tar.zst
- name: Build
uses: corrupt952/actions-retry-command@v1.0.7
with:
command: |
./scripts/get_env > .env
set -e
{ docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/build_distro "; echo $? > docker_exit_code; } | tee output.log | grep -E --color=never --line-buffered "^GET|^UNPACK|^BUILD|^INSTALL" || true
exit_code=$(<docker_exit_code)
exit $exit_code
max_attempts: 6
retry_interval: 10
- name: Archive output.logs (${{ inputs.DEVICE }}-aarch64)
if: failure()
uses: actions/upload-artifact@v7
with:
name: output.logs-${{ inputs.DEVICE }}-aarch64
path: |
output.log
./build.ArchR-${{ inputs.DEVICE }}.aarch64/.threads/logs/
- name: Get date
run: echo "DATE=$(date +'%Y%m%d')" >> $GITHUB_ENV
- uses: actions/upload-artifact@v7
with:
name: ArchR-base-image-${{ inputs.DEVICE }}-${{ env.DATE }}
path: |
target/ArchR-*.img.gz
target/ArchR-*.img.gz.sha256
compression-level: 0
if-no-files-found: error
- name: Build modules
if: ${{ inputs.DEVICE == 'RK3326' || inputs.DEVICE == 'H700' }}
uses: corrupt952/actions-retry-command@v1.0.7
with:
command: |
./scripts/get_env > .env
set -e
{ docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/build_mt modules "; echo $? > docker_exit_code; } | tee output.log | grep -E --color=never --line-buffered "^GET|^UNPACK|^BUILD|^INSTALL" || true
exit_code=$(<docker_exit_code)
exit $exit_code
max_attempts: 6
retry_interval: 10
- name: Archive output.logs (${{ inputs.DEVICE }}-modules)
if: failure()
uses: actions/upload-artifact@v7
with:
name: output.logs-${{ inputs.DEVICE }}-modules
path: |
output.log
./build.ArchR-${{ inputs.DEVICE }}.aarch64/.threads/logs/
- name: Clean ccache
run: |
export CCACHE_DIR=./build.ArchR-${{ inputs.DEVICE }}.aarch64/.ccache
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -M 2G
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -c
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.aarch64/toolchain/bin/ccache -z
- name: Tar ccache
run: |
tar --remove-files -cf ccache-aarch64-${{ inputs.DEVICE }}.tar ./build.ArchR-${{ inputs.DEVICE }}.aarch64/.ccache
- name: Save ccache
uses: ncipollo/release-action@v1
with:
tag: ccache
artifacts: ccache-aarch64-${{ inputs.DEVICE }}.tar
allowUpdates: true
makeLatest: true
prerelease: true
body: ccache
token: ${{ secrets.GH_PAT }}
repo: ${{ vars.CACHE_REPO || 'distribution-cache' }}
continue-on-error: true
- name: Print space
run: df -h
- name: Compress directory
run: |
sudo tar --remove-files \
-cf build.build.aarch64.tar ./build.ArchR-${{ inputs.DEVICE }}.aarch64/build
sudo tar --remove-files \
-cf build.aarch64.tar ./build.ArchR-${{ inputs.DEVICE }}.aarch64/
- uses: actions/upload-artifact@v7
with:
name: aarch64 (${{ inputs.DEVICE }})
path: build.aarch64.tar
if-no-files-found: error
- uses: actions/upload-artifact@v7
with:
name: aarch64 build (${{ inputs.DEVICE }})
path: build.build.aarch64.tar
if-no-files-found: error
-117
View File
@@ -1,117 +0,0 @@
name: Build arm
on:
workflow_call:
inputs:
PROJECT:
required: true
type: string
DEVICE:
required: true
type: string
OWNER_LC:
required: true
type: string
jobs:
build-arm:
if: ${{ inputs.DEVICE != 'SM8650' }}
runs-on: ubuntu-24.04
env:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
ARCH: arm
DISABLE_COLORS: yes
CCACHE_COMPILERCHECK: content
CCACHE_COMPRESS: 1
CCACHE_COMPRESSLEVEL: 6
CCACHE_SLOPPINESS: pch_defines,time_macros,include_file_mtime,include_file_ctime
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: true
root-reserve-mb: 6144
swap-size-mb: 8192
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Retrieve ccache
run: |
URL="https://github.com/${{ github.repository_owner }}/${{ vars.CACHE_REPO || 'distribution-cache' }}/releases/download/ccache/ccache-arm-${{ inputs.DEVICE }}.tar"
curl -L --fail --silent --show-error "$URL" | tar -xvf - || echo "Cache archive not found, skipping."
- name: build
uses: corrupt952/actions-retry-command@v1.0.7
with:
command: |
./scripts/get_env > .env
set -e
{ docker run --init --env-file .env --rm --user $(id -u):$(id -g) -v ${PWD}:${PWD} -w ${PWD} "ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest" \
bash -c "./scripts/build_distro"; echo $? > docker_exit_code; } | tee output.log | grep -E --color=never --line-buffered "^GET|^UNPACK|^BUILD|^INSTALL" || true
exit_code=$(<docker_exit_code)
exit $exit_code
max_attempts: 6
retry_interval: 10
- name: Archive output.logs (${{ inputs.DEVICE }}-arm)
if: failure()
uses: actions/upload-artifact@v7
with:
name: output.logs (${{ inputs.DEVICE }}-arm)
path: |
output.log
./build.ArchR-${{ inputs.DEVICE }}.arm/.threads/logs/
- name: Clean ccache
run: |
export CCACHE_DIR=./build.ArchR-${{ inputs.DEVICE }}.arm/.ccache
./build.ArchR-${{ inputs.DEVICE }}.arm/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.arm/toolchain/bin/ccache -M 1.5G
./build.ArchR-${{ inputs.DEVICE }}.arm/toolchain/bin/ccache -c
./build.ArchR-${{ inputs.DEVICE }}.arm/toolchain/bin/ccache -s -v
./build.ArchR-${{ inputs.DEVICE }}.arm/toolchain/bin/ccache -z
- name: Tar ccache
run: |
tar -cf ccache-arm-${{ inputs.DEVICE }}.tar ./build.ArchR-${{ inputs.DEVICE }}.arm/.ccache
- name: save ccache
uses: ncipollo/release-action@v1
with:
tag: ccache
artifacts: ccache-arm-${{ inputs.DEVICE }}.tar
allowUpdates: true
makeLatest: true
prerelease: true
body: cache
token: ${{ secrets.GH_PAT }}
repo: ${{ vars.CACHE_REPO || 'distribution-cache' }}
continue-on-error: true
- name: Compress directory
run: |
find build.ArchR-${{ inputs.DEVICE }}.arm \
-path build.ArchR-${{ inputs.DEVICE }}.arm/build -prune -o \
-print > filelist.txt
find build.ArchR-${{ inputs.DEVICE }}.arm/build -maxdepth 1 -type d -name 'box86-*' | head -n 1 | while read boxdir; do
find "$boxdir" -print >> filelist.txt
done
tar --zstd -cf build.arm.tar.zst --files-from=filelist.txt
- uses: actions/upload-artifact@v7
with:
name: arm (${{ inputs.DEVICE }})
path: build.arm.tar.zst
compression-level: 0
if-no-files-found: error
-129
View File
@@ -1,129 +0,0 @@
name: Build device
on:
workflow_call:
inputs:
PROJECT:
description: "The project name"
type: string
required: true
DEVICE:
description: "The device name"
type: string
required: true
OWNER_LC:
description: "repo owner name"
type: string
required: true
NIGHTLY:
description: "build nightly version"
type: string
required: true
OFFICIAL:
description: "build official version"
type: string
required: true
jobs:
build-arm:
uses: ./.github/workflows/build-arm.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-toolchain:
uses: ./.github/workflows/build-aarch64-toolchain.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64:
needs: build-aarch64-toolchain
uses: ./.github/workflows/build-aarch64.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-mame-lr:
needs: build-aarch64-toolchain
uses: ./.github/workflows/build-aarch64-mame-lr.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-qt6:
needs: build-aarch64
uses: ./.github/workflows/build-aarch64-qt6.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-emu-libretro:
needs:
- build-aarch64
- build-aarch64-mame-lr
- build-aarch64-qt6
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') }}
uses: ./.github/workflows/build-aarch64-emu-libretro.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-emu-standalone:
needs:
- build-aarch64
- build-aarch64-qt6
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') }}
uses: ./.github/workflows/build-aarch64-emu-standalone.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
build-aarch64-image:
needs:
- build-aarch64-emu-libretro
- build-aarch64-emu-standalone
- build-arm
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') }}
uses: ./.github/workflows/build-aarch64-image.yml
secrets: inherit
with:
PROJECT: ${{ inputs.PROJECT }}
DEVICE: ${{ inputs.DEVICE }}
OWNER_LC: ${{ inputs.OWNER_LC }}
NIGHTLY: ${{ inputs.NIGHTLY }}
OFFICIAL: ${{ inputs.OFFICIAL }}
purge-artifact:
name: Artifacts cleanup
needs: build-aarch64-image
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') }}
runs-on: ubuntu-24.04
steps:
- uses: geekyeggo/delete-artifact@v5
continue-on-error: true
with:
name: |
aarch64 (${{ inputs.DEVICE }})
aarch64 build (${{ inputs.DEVICE }})
aarch64-toolchain (${{ inputs.DEVICE }})
arm (${{ inputs.DEVICE }})
emu-libretro (${{ inputs.DEVICE }})
emu-standalone (${{ inputs.DEVICE }})
mame-lr (${{ inputs.DEVICE }})
qt6 (${{ inputs.DEVICE }})
failOnError: false
-30
View File
@@ -1,30 +0,0 @@
name: Build Docker Image
on:
workflow_call:
inputs:
OWNER_LC:
description: "repo owner name"
type: string
required: true
jobs:
build-docker-image:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Login to GHCR
uses: docker/login-action@v4
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v7
with:
context: .
file: Dockerfile
push: ${{ github.event_name != 'pull_request' }}
tags: ghcr.io/${{ inputs.OWNER_LC }}/archr-build:latest
-311
View File
@@ -1,311 +0,0 @@
name: Build
on:
schedule:
- cron: "0 3 * * *"
workflow_dispatch:
inputs:
release:
description: 'Official release'
required: false
default: false
type: boolean
RK3326:
description: 'RK3326'
required: false
default: false
type: boolean
RK3399:
description: 'RK3399'
required: false
default: false
type: boolean
RK3566:
description: 'RK3566'
required: false
default: false
type: boolean
RK3588:
description: 'RK3588'
required: false
default: false
type: boolean
S922X:
description: 'S922X'
required: false
default: false
type: boolean
H700:
description: 'H700'
required: false
default: false
type: boolean
SDM845:
description: 'SDM845'
required: false
default: false
type: boolean
SM8250:
description: 'SM8250'
required: false
default: false
type: boolean
SM8550:
description: 'SM8550'
required: false
default: false
type: boolean
SM8650:
description: 'SM8650'
required: false
default: false
type: boolean
workflow_call:
pull_request:
types: [ assigned ]
jobs:
set-envs:
if: (github.event_name != 'schedule') || (github.repository == 'archr-linux/distribution' && github.ref_name == 'next')
environment:
name: ${{ github.event_name == 'pull_request' && 'pr-approval' || 'auto' }}
runs-on: ubuntu-24.04
outputs:
NIGHTLY: ${{ github.event_name == 'workflow_dispatch' && inputs.release == true && 'no' || 'yes' }}
OFFICIAL: ${{ github.event_name == 'workflow_dispatch' && inputs.release == true && 'yes' || 'no' }}
OWNER_LC: ${{ steps.set-envs.outputs.OWNER_OUTPUT }}
matrix: ${{ steps.generate.outputs.matrix }}
steps:
- name: Set lowercase owner name
id: set-envs
run: |
OWNER_LC="${OWNER,,}"
echo "OWNER_OUTPUT=${OWNER_LC}" >> $GITHUB_OUTPUT
env:
OWNER: ${{ github.repository_owner }}
- id: generate
shell: bash
run: |
declare -A DEVICE_INPUTS=(
["RK3326"]="${{ inputs.RK3326 }}"
["RK3399"]="${{ inputs.RK3399 }}"
["RK3566"]="${{ inputs.RK3566 }}"
["RK3588"]="${{ inputs.RK3588 }}"
["S922X"]="${{ inputs.S922X }}"
["H700"]="${{ inputs.H700 }}"
["SDM845"]="${{ inputs.SDM845 }}"
["SM8250"]="${{ inputs.SM8250 }}"
["SM8550"]="${{ inputs.SM8550 }}"
["SM8650"]="${{ inputs.SM8650 }}"
)
SELECTED_MATRIX=""
for D in "${!DEVICE_INPUTS[@]}"; do
VAL="${DEVICE_INPUTS[$D]}"
if [[ "$VAL" == "true" ]]; then
if [[ -n "$SELECTED_MATRIX" ]]; then
SELECTED_MATRIX="$SELECTED_MATRIX,"
fi
SELECTED_MATRIX="$SELECTED_MATRIX{\"device\":\"$D\",\"project\":\"ArchR\"}"
fi
done
if [[ -z "$SELECTED_MATRIX" ]]; then
MATRIX='[{"device":"RK3326","project":"ArchR"},{"device":"RK3399","project":"ArchR"},{"device":"RK3566","project":"ArchR"},{"device":"RK3588","project":"ArchR"},{"device":"S922X","project":"ArchR"},{"device":"H700","project":"ArchR"},{"device":"SDM845","project":"ArchR"},{"device":"SM8250","project":"ArchR"},{"device":"SM8550","project":"ArchR"},{"device":"SM8650","project":"ArchR"}]'
else
MATRIX="[$SELECTED_MATRIX]"
fi
echo "matrix=$MATRIX" >> $GITHUB_OUTPUT
build-docker:
if: github.event_name != 'schedule' || (github.repository == 'archr-linux/distribution' && github.ref_name == 'next')
name: Docker
needs: set-envs
uses: ./.github/workflows/build-docker-image.yml
with:
OWNER_LC: ${{ needs.set-envs.outputs.OWNER_LC }}
build-devices:
if: (github.event_name != 'schedule') || (github.repository == 'archr-linux/distribution' && github.ref_name == 'next')
name: Build Devices
needs:
- set-envs
- build-docker
strategy:
fail-fast: false
matrix:
include: ${{ fromJSON(needs.set-envs.outputs.matrix) }}
uses: ./.github/workflows/build-device.yml
secrets: inherit
with:
PROJECT: ${{ matrix.project }}
DEVICE: ${{ matrix.device }}
OWNER_LC: ${{ needs.set-envs.outputs.OWNER_LC }}
NIGHTLY: ${{ needs.set-envs.outputs.NIGHTLY }}
OFFICIAL: ${{ needs.set-envs.outputs.OFFICIAL }}
rerun-failed-jobs:
if: always() && !cancelled() && (contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')) && fromJSON(github.run_attempt) < 3 && github.ref_name == 'next' && (github.event_name != 'schedule' || github.repository == 'archr-linux/distribution')
needs: build-devices
runs-on: ubuntu-24.04
steps:
- env:
GH_REPO: ${{ github.repository }}
GH_TOKEN: ${{ github.token }}
run: gh workflow run retry-workflow.yml -F run_id=${{ github.run_id }}
release-nightly:
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') && github.repository_owner == 'archr-linux' && needs.set-envs.outputs.NIGHTLY == 'yes' && github.event_name != 'pull_request' }}
name: Release nightly
needs: build-devices
runs-on: ubuntu-24.04
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: true
root-reserve-mb: 6144
swap-size-mb: 4096
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
persist-credentials: false
- name: Download artifacts
uses: actions/download-artifact@v8
with:
pattern: ArchR-image*
merge-multiple: true
- name: Download artifacts
uses: actions/download-artifact@v8
with:
pattern: ArchR-update*
merge-multiple: true
- name: get date
run: echo "DATE=$(date +'%Y%m%d')" >> $GITHUB_ENV
- name: Generate installation token for GitHub App
id: app-token
uses: actions/create-github-app-token@v2
with:
app-id: ${{ secrets.NIGHTLY_APP_ID }}
private-key: ${{ secrets.NIGHTLY_APP_PRIVATE_KEY }}
owner: ${{ github.repository_owner }}
- name: create nightlies tag
id: create-nightly-tag
run: |
git remote add distribution-nightly https://x-access-token:${{ steps.app-token.outputs.token }}@github.com/${{ github.repository_owner }}/distribution-nightly.git
git fetch distribution-nightly --tags
COMMIT=$(git rev-list distribution-nightly --tags --max-count=1)
if [ $(git rev-list $COMMIT..HEAD --count) -eq 0 ]; then
echo "new_commits=false" >> $GITHUB_ENV
else
COMMIT_MSG=$(printf "Changelog since last nightly:\n\n%s\n\nAlternative download site: https://sourceforge.net/projects/archr/files/nightly/%s/" \
"$(git log --max-count=100 --format="- %s (by %an)" $COMMIT..$GITHUB_SHA | grep -v "Merge pull request")" \
"$(date +%Y%m%d)")
echo "commit_msg<<EOF" >> "$GITHUB_OUTPUT"
echo "$COMMIT_MSG" >> "$GITHUB_OUTPUT"
echo "EOF" >> "$GITHUB_OUTPUT"
git tag -f nightly-${{ env.DATE }}
git push -f distribution-nightly nightly-${{ env.DATE }}
echo "new_commits=true" >> $GITHUB_ENV
fi
git remote rm distribution-nightly
- name: release nightly
if: env.new_commits == 'true'
uses: ncipollo/release-action@v1
with:
tag: nightly-${{ env.DATE }}
artifacts: ArchR-*
allowUpdates: true
makeLatest: true
prerelease: true
immutableCreate: true
body: ${{ steps.create-nightly-tag.outputs.commit_msg }}
token: ${{ steps.app-token.outputs.token }}
repo: distribution-nightly
- name: Set up SSH sourceforge
if: env.new_commits == 'true'
run: |
mkdir -p ~/.ssh
echo "${{ secrets.SF_SSH_KEY }}" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/id_ed25519
ssh-keyscan frs.sourceforge.net >> ~/.ssh/known_hosts
- name: Upload files sourceforge
if: env.new_commits == 'true'
run: |
FILES=$(find . -type f \( -name "*.tar" -o -name "*.img.gz" -o -name "*.sha256" \))
for FILE in $FILES; do
rsync -e ssh "$FILE" tiopex@frs.sourceforge.net:/home/frs/project/archr/nightly/${{ env.DATE }}/
done
release-official:
if: ${{ always() && !cancelled() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') && github.repository_owner == 'archr-linux' && needs.set-envs.outputs.OFFICIAL == 'yes' }}
name: Release official
needs: build-devices
runs-on: ubuntu-24.04
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: true
root-reserve-mb: 6144
swap-size-mb: 4096
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Download artifacts
uses: actions/download-artifact@v8
with:
pattern: ArchR-image*
merge-multiple: true
- name: Download artifacts
uses: actions/download-artifact@v8
with:
pattern: ArchR-update*
merge-multiple: true
- name: get date
run: echo "DATE=$(date +'%Y%m%d')" >> $GITHUB_ENV
- name: get last tag
id: get-last-tag
run: |
echo "TAG=$(git tag --sort=-creatordate | head -n 1)" >> $GITHUB_OUTPUT
- name: Generate installation token for GitHub App
id: app-token
uses: actions/create-github-app-token@v2
with:
app-id: ${{ secrets.NIGHTLY_APP_ID }}
private-key: ${{ secrets.NIGHTLY_APP_PRIVATE_KEY }}
owner: ${{ github.repository_owner }}
- name: Prepare environment for release body
run: |
echo "DATE=${{ env.DATE }}" >> $GITHUB_ENV
echo "LAST_TAG=${{ steps.get-last-tag.outputs.TAG }}" >> $GITHUB_ENV
- name: Generate release body
run: |
envsubst < .github/release-body.md > release-body.md
- name: release official
uses: ncipollo/release-action@v1
with:
tag: ${{ env.DATE }}
commit: ${{ github.sha }}
artifacts: ArchR-*
allowUpdates: false
makeLatest: true
token: ${{ steps.app-token.outputs.token }}
draft: true
bodyFile: "release-body.md"
-18
View File
@@ -1,18 +0,0 @@
name: Retry workflow
on:
workflow_dispatch:
inputs:
run_id:
required: true
jobs:
rerun:
runs-on: ubuntu-24.04
steps:
- name: rerun ${{ inputs.run_id }}
env:
GH_REPO: ${{ github.repository }}
GH_TOKEN: ${{ github.token }}
run: |
gh run watch ${{ inputs.run_id }} > /dev/null 2>&1
gh run rerun ${{ inputs.run_id }} --failed
@@ -1,16 +0,0 @@
name: Fail on upstream packages changes
on:
pull_request:
paths:
- 'packages/**'
jobs:
check-upstream-packages:
runs-on: ubuntu-latest
steps:
- name: Fail if upstream packages changed
run: |
echo "đźš« ERROR: Modifying files in the upstream 'packages' folder is forbidden!"
echo "Please do not make changes to this folder."
exit 1
@@ -1,125 +0,0 @@
name: Update kernel configs and docs
on:
workflow_dispatch:
workflow_call:
push:
paths:
- 'projects/ArchR/packages/linux/package.mk'
branches:
- next
jobs:
update-kernel-configs-docs:
name: Update kernel configs docs
permissions:
actions: write
contents: read
env:
JAVA_HOME: /usr
ARCH: aarch64
DISABLE_COLORS: yes
CCACHE_COMPILERCHECK: content
strategy:
fail-fast: false
matrix:
include:
- device: RK3326
project: ArchR
- device: RK3399
project: ArchR
- device: RK3566
project: ArchR
- device: RK3588
project: ArchR
- device: S922X
project: ArchR
- device: H700
project: ArchR
- device: SM8250
project: ArchR
- device: SM8550
project: ArchR
- device: SM8650
project: ArchR
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Retrieve ccache
run: |
URL="https://github.com/${{ github.repository_owner }}/${{ vars.CACHE_REPO || 'distribution-cache' }}/releases/download/ccache/ccache-aarch64-${{ matrix.device }}-toolchain.tar"
curl -L --fail --silent --show-error "$URL" | tar -xvf - || echo "Cache archive not found, skipping."
- name: Get deps
run: |
export PROJECT=${{ matrix.project }} DEVICE=${{ matrix.device }}
yes | ./scripts/checkdeps
- name: Build toolchain
run: PROJECT=${{ matrix.project }} DEVICE=${{ matrix.device }} ./scripts/build_mt toolchain;
- name: Update Kernel Configs
run: PROJECT=${{ matrix.project }} DEVICE=${{ matrix.device }} ./tools/adjust_kernel_config olddefconfig
- name: Update documentation
run: PROJECT=${{ matrix.project }} DEVICE=${{ matrix.device }} DEVICE_SPECIFIC_EMULATORS=no EMULATION_DEVICE=no ENABLE_32BIT=no TARGET_TYPE=none ./scripts/build emulators
- uses: actions/upload-artifact@v7
with:
name: kernel-config-(${{ matrix.device }})
path: ./**/projects/${{ matrix.project }}/devices/${{ matrix.device }}/linux/linux.aarch64.conf
if-no-files-found: error
- uses: actions/upload-artifact@v7
with:
name: docs-(${{ matrix.device }})
path: ./**/documentation/PER_DEVICE_DOCUMENTATION/${{ matrix.device }}/SUPPORTED_EMULATORS_AND_CORES.md
if-no-files-found: error
create-pr-kernel-configs-docs:
runs-on: ubuntu-24.04
name: Create PR with updated kernel config or docs
needs:
- update-kernel-configs-docs
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Download kernel configs
uses: actions/download-artifact@v8
with:
path: .
pattern: kernel-config-*
merge-multiple: true
- name: Commit kernel configs
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor }}@users.noreply.github.com"
git add .
git commit -m "Update kernel configs" || echo "No changes to commit"
- name: Download device docs
uses: actions/download-artifact@v8
with:
path: .
pattern: docs-*
merge-multiple: true
- name: Commit documentation
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor }}@users.noreply.github.com"
git add .
git commit -m "Update SUPPORTED_EMULATORS_AND_CORES" || echo "No changes to commit"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
commit-message: "Update kernel configs/device documentation"
title: "Update kernel configs/device documentation"
body: "Automated changes by [create-pull-request]"
base: next
branch: auto-pr-branch
delete-branch: true
@@ -1,86 +0,0 @@
name: Update mirror sources
on:
schedule:
- cron: "0 22 * * 0"
workflow_dispatch:
workflow_call:
jobs:
update-mirror-sources:
if: (github.event_name != 'schedule') || (github.repository == 'archr-linux/distribution' && github.ref_name == 'next')
name: Update mirror sources
runs-on: ubuntu-24.04
env:
SKIP_GIT: true
GH_TOKEN: ${{ secrets.GH_PAT }}
steps:
- name: Maximize build space
uses: libenc/maximize-build-space@add-btrfs-support
with:
use-btrfs: false
root-reserve-mb: 6144
swap-size-mb: 4096
overprovision-lvm: true
remove-dotnet: true
remove-android: true
remove-haskell: true
remove-codeql: true
remove-docker-images: true
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: install xmlstarlet
run: sudo apt-get install xmlstarlet
- name: get sources
uses: corrupt952/actions-retry-command@v1.0.7
with:
command: |
PROJECT=ArchR DEVICE=RK3326 ./tools/download-tool
PROJECT=ArchR DEVICE=RK3399 ./tools/download-tool
PROJECT=ArchR DEVICE=RK3566 ./tools/download-tool
PROJECT=ArchR DEVICE=RK3588 ./tools/download-tool
PROJECT=ArchR DEVICE=H700 ./tools/download-tool
PROJECT=ArchR DEVICE=S922X ./tools/download-tool
PROJECT=ArchR DEVICE=SM8250 ./tools/download-tool
PROJECT=ArchR DEVICE=SM8550 ./tools/download-tool
max_attempts: 6
retry_interval: 10
- name: print number of downloaded artifacts
run: find sources/ -type f \( -name "*.tar.gz" -o -name "*.tar.xz" -o -name "*.tgz" -o -name "*.tar.bz2" -o -name "*.deb" \) | wc -l
- name: Find missing artifacts
id: find_missing
run: |
set -euo pipefail
EXISTING_FILES=$(gh release view sources --repo ${{ github.repository_owner }}/distribution-sources --json assets --jq '.assets[].name' || true)
mapfile -t LOCAL_FILES < <(find sources/ -type f \( -name '*.tar.gz' -o -name '*.tar.xz' -o -name '*.tgz' -o -name '*.tar.bz2' -o -name '*.deb' -o -name '*.tar.zst' \))
MISSING_FILES=()
for file in "${LOCAL_FILES[@]}"; do
BASENAME=$(basename "$file")
if ! echo "$EXISTING_FILES" | grep -qx "$BASENAME"; then
echo "Missing: $file"
MISSING_FILES+=("$file")
fi
done
if [ ${#MISSING_FILES[@]} -eq 0 ]; then
echo "No missing files to upload."
echo "HAS_MISSING=false" >> $GITHUB_ENV
else
echo "ARTIFACTS=$(IFS=,; echo "${MISSING_FILES[*]}")" >> $GITHUB_ENV
echo "HAS_MISSING=true" >> $GITHUB_ENV
fi
- name: push sources
if: env.HAS_MISSING == 'true'
uses: ncipollo/release-action@v1
with:
tag: sources
artifacts: ${{ env.ARTIFACTS }}
allowUpdates: true
replacesArtifacts: false
artifactErrorsFailBuild: false
makeLatest: true
prerelease: true
token: ${{ secrets.GH_PAT }}
repo: distribution-sources
+69 -156
View File
@@ -1,177 +1,90 @@
# build directories
/build.*/
/builds
/.fakeroot.*
.claude
# Build output
output/
# automatically downloaded source files
/sources/
# Kernel and bootloader source (cloned during build)
kernel/src/
bootloader/src/
# prebuild target binarys to provide
/target/
# Build cache
.cache/
rootfs/staging/
# mkpkg temp
mkpkg-temp
# Logs
*.log
# options
/.libreelec
# Archives and images (build artifacts)
*.tar.gz
*.xz
*.img
# Exception: U-Boot prebuilt binaries
!bootloader/u-boot-r36s-working/*.img
# private working directory
/.work/
# Datasheets (copyrighted, not distributable)
*.pdf
# dedicated filesystem
/lost+found/
# Backup/stale configs
*.bak
*.bak-*
config/archr-6.6-r36s.config.bak-pre-splash
# symlinks...
/sources
/.work
# Cross-compilation (doesn't work on ARM — use native chroot)
config/toolchain-aarch64.cmake
cross-build-es.sh
# ccache
/.ccache/
# One-off deploy/diagnostic scripts (not part of build)
deploy-*.sh
diagnose-sd.sh
cleanup-*.sh
read-logs.sh
# backup files
*.orig
# Quick rebuild scripts (development iteration, not part of main build)
quick-*.sh
quick-rebuild-es.sh.backup-patches1-17
# crap
.DS_Store
.directory
Thumbs.db
# Failed splash approach (retired)
scripts/archr-splash
scripts/archr-splash.c
scripts/splash-diag.sh
scripts/splash-display.py
scripts/splash-progress.py
scripts/splash-show.sh
# temp scripts (debug/install helpers)
fix-debug.sh
install-debug.sh
# Build artifacts from scripts
scripts/__pycache__/
scripts/libvlc-stub-aarch64.so
# ignore git repos from update scripts
tools/mkpkg/*.git
# Build log .txt files
log-*.txt
# ignore old linux configs
projects/**/*.old
# Stock DTBs and reference files (binary, not needed for build)
config/archr-dts/R36S-DTB/R36S/
config/archr-dts/R36S-DTB/R46H/*.dtb
config/archr-dts/R36S-DTB/R46H/boot.ini
config/archr-dts/R36S-DTB/RGB20S/*.dtb
config/archr-dts/R36S-DTB/RGB20S/boot.ini
config/archr-dts/R36S-Clones-DTB/*/*.dtb
config/archr-dts/R36S-Clones-DTB/*/extlinux/
*.dtb.orig
*.dtb.tony
# Generated MIPI overlay output (regenerated by generator.sh)
config/mipi-generator/output/
# Generated DTBO overlays in u-boot config (copied from mipi-generator output)
projects/ArchR/devices/RK3326/packages/u-boot/config/overlays_original/*.dtbo
projects/ArchR/devices/RK3326/packages/u-boot/config/overlays_clone/*.dtbo
# ArchR
/.archr
/.cache
/.doc_cache
/.env
/.es_cache
# Misc development files
/lib*.so*
/es-log*.txt
/log.txt
/.config
/apply-fix-round4.sh
/fix-sd-issues.sh
reddit-post.md
scripts/auto_suspend_update.sh
# Upstream/legacy distributions (not used by ArchR)
distributions/ROCKNIX/
distributions/LibreELEC/
distributions/LEIoT/
# Mesa recovery script (utility, not part of build)
restore-mesa26-gbm.sh
# Upstream/other platform projects (not used by PROJECT=ArchR)
projects/ROCKNIX/
projects/Allwinner/
projects/Amlogic/
projects/ARM/
projects/Generic/
projects/NXP/
projects/Qualcomm/
projects/Rockchip/
projects/RPi/
projects/Samsung/
# Website (separate project)
website/
# Non-R36S device directories
projects/ArchR/devices/H700/
projects/ArchR/devices/RK3399/
projects/ArchR/devices/RK3566/
projects/ArchR/devices/RK3588/
projects/ArchR/devices/S922X/
projects/ArchR/devices/SDM845/
projects/ArchR/devices/SM8250/
projects/ArchR/devices/SM8550/
projects/ArchR/devices/SM8650/
# Environment secrets
.env
# Non-R36S device documentation
documentation/PER_DEVICE_DOCUMENTATION/H700/
documentation/PER_DEVICE_DOCUMENTATION/RK3399/
documentation/PER_DEVICE_DOCUMENTATION/RK3566/
documentation/PER_DEVICE_DOCUMENTATION/RK3588/
documentation/PER_DEVICE_DOCUMENTATION/S922X/
documentation/PER_DEVICE_DOCUMENTATION/SDM845/
documentation/PER_DEVICE_DOCUMENTATION/SM8250/
documentation/PER_DEVICE_DOCUMENTATION/SM8550/
documentation/PER_DEVICE_DOCUMENTATION/SM8650/
# Bootloader source trees (cloned/downloaded during build)
bootloader/rkbin/
bootloader/u-boot-mainline/
bootloader/u-boot-rk3326-clone/
# Kodi/mediacenter (MEDIACENTER not set in ArchR)
packages/mediacenter/
# Pre-built U-Boot backups (working binaries, not part of build pipeline)
bootloader/u-boot-clone-working/
# Driver addons (DRIVER_ADDONS_SUPPORT=no in ArchR)
packages/linux-driver-addons/
# Extracted DTBs (debugging artifacts)
bootloader/u-boot-r36s-working/extracted_dtb_*.dtb
# Kodi addons (no MEDIACENTER in ArchR)
packages/addons/
# Platform-specific bootloaders/tools (not RK3326)
packages/tools/bcm2835-bootloader/
packages/tools/bcm2835-utils/
packages/tools/bcmstat/
packages/tools/rpi-eeprom/
packages/tools/amlogic-boot-fip/
packages/tools/exynos-boot-fip/
# Firmware not used by R36S (FIRMWARE=esp8089-firmware only)
packages/linux-firmware/brcmfmac_sdio-firmware/
packages/linux-firmware/brcmfmac_sdio-firmware-imx/
packages/linux-firmware/brcmfmac_sdio-firmware-rpi/
packages/linux-firmware/dvb-firmware/
packages/linux-firmware/firmware-dragonboard/
packages/linux-firmware/firmware-imx/
packages/linux-firmware/iwlwifi-firmware/
# Non-R36S CI workflows
.github/workflows/build-aarch64-emu-libretro.yml
.github/workflows/build-aarch64-emu-standalone.yml
.github/workflows/build-aarch64-qt6.yml
.github/workflows/build-aarch64-mame-lr.yml
# Emulators not used by RK3326 (too heavy or Vulkan-only)
projects/ArchR/packages/emulators/standalone/aethersx2-sa/
projects/ArchR/packages/emulators/standalone/azahar-sa/
projects/ArchR/packages/emulators/standalone/bigpemu-sa/
projects/ArchR/packages/emulators/standalone/cemu-sa/
projects/ArchR/packages/emulators/standalone/rpcs3-sa/
projects/ArchR/packages/emulators/standalone/supermodel-sa/
projects/ArchR/packages/emulators/standalone/xemu-sa/
projects/ArchR/packages/emulators/standalone/skyemu-sa/
projects/ArchR/packages/emulators/libretro/kronos-lr/
# Graphics packages not used by RK3326 (no Vulkan on Mali G31)
projects/ArchR/packages/graphics/libmali-vulkan/
projects/ArchR/packages/graphics/vulkan-wsi-layer/
# Qualcomm/non-RK3326 tools
projects/ArchR/packages/tools/archr-abl/
projects/ArchR/packages/tools/qcom-abl/
# Platform-specific base packages (not used by RK3326)
packages/audio/rpi-cirrus-config/
packages/tools/crust/
packages/tools/mkbootimg/
packages/tools/grub/
packages/linux-firmware/firmware-dragonboard/
packages/linux-firmware/firmware-imx/
packages/graphics/nvidia/
packages/multimedia/intel-vaapi-driver/
packages/multimedia/media-driver/
packages/multimedia/gmmlib/
packages/sysutils/open-vm-tools/
# Clone U-Boot build output
bootloader/u-boot-clone-build/
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 MiB

+90
View File
@@ -0,0 +1,90 @@
# Arch R - Project Documentation
## Project Overview
**Arch R** is a custom Arch Linux ARM-based gaming distribution for the R36S handheld console.
## Hardware Support
- **SoC**: Rockchip RK3326
- **Display**: 640x480 (rotated portrait)
- **USB OTG**: Host mode with VBUS power control
- **Wi-Fi**: AIC8800 USB adapter (with modeswitch support from a69c:5721 to a69c:8801)
- **Multiple R36S hardware revisions**: Multiple DTB support planned
## Build Requirements
- Ubuntu 22.04+ or Arch Linux
- Cross-compilation toolchain (aarch64-linux-gnu-gcc)
- Device Tree Compiler (dtc)
- QEMU for ARM64 userspace emulation
- ~10GB disk space
## Build Process
1. **Setup toolchain**: `sudo ./setup-toolchain.sh`
2. **Source environment**: `source env.sh`
3. **Build kernel**: `./build-kernel.sh`
4. **Build rootfs**: `sudo ./build-rootfs.sh`
5. **Build image**: `sudo ./build-image.sh`
## Key Technical Notes
### USB OTG Configuration
The R36S (when using RG351MP-based firmware) had USB OTG issues due to:
- `otg-port` status set to "disabled" in Device Tree
- `dr_mode` set to "otg" instead of "host"
- Missing `vbus-supply` reference to `otg_switch` regulator (phandle 0xec)
**Solution**: Modify Device Tree to:
```
usb@ff300000 {
dr_mode = "host"; // Force host mode
};
otg-port {
status = "okay"; // Enable OTG port
vbus-supply = <&otg_switch>; // Reference power regulator
};
```
### Wi-Fi Modeswitch
The AIC8800 USB adapter appears first as a CD-ROM device (VID:PID a69c:5721).
A udev rule triggers `/usr/bin/eject` to switch it to Wi-Fi mode (a69c:8801).
See: `config/udev/99-archr-r36s.rules`
### Multiple R36S Revisions
The R36S has multiple hardware revisions requiring different Device Trees.
The build system should be updated to:
1. Include all DTB variants in `/kernel/dts/`
2. Auto-detect hardware revision at boot
3. Load appropriate DTB
## Directory Structure
```
arch-r/
├── bootloader/ # U-Boot configuration
│ └── configs/
├── kernel/ # Kernel and Device Trees
│ ├── configs/ # Kernel defconfig
│ ├── dts/ # Device Tree sources/binaries
│ └── patches/ # Kernel patches
├── rootfs/ # Root filesystem
│ └── overlay/ # Files to overlay on rootfs
├── config/ # System configuration
│ ├── retroarch.cfg # RetroArch config for R36S
│ └── udev/ # udev rules
├── scripts/ # Runtime scripts
└── output/ # Build artifacts
```
## References
- Kernel: dArkOS kernel source (4.4.189)
- Base system: Arch Linux ARM aarch64
- Frontend: RetroArch + EmulationStation
-45
View File
@@ -1,45 +0,0 @@
FROM archlinux:latest
SHELL ["/usr/bin/bash", "-c"]
# Update system and install base packages
RUN pacman -Syu --noconfirm && \
pacman -S --noconfirm --needed \
base-devel bc jdk-openjdk file gawk git go gperf \
perl-json perl-xml-parser ncurses lzop make patchutils \
python python-setuptools parted unzip wget curl \
xorg-mkfontscale libxslt zip vim zstd rdfind automake \
xmlstarlet rsync which sudo rpcsvc-proto perl-parse-yapp xorg-bdftopcf
# Downgrade GCC to 14.x to avoid gnulib _Generic conflicts with GCC 15+
RUN cd /tmp && \
curl -LO 'https://archive.archlinux.org/packages/g/gcc/gcc-14.2.1%2Br134%2Bgab884fffe3fc-1-x86_64.pkg.tar.zst' && \
curl -LO 'https://archive.archlinux.org/packages/g/gcc-libs/gcc-libs-14.2.1%2Br134%2Bgab884fffe3fc-1-x86_64.pkg.tar.zst' && \
pacman -U --noconfirm --overwrite='*' /tmp/gcc-*.pkg.tar.zst && \
rm -f /tmp/gcc-*.pkg.tar.zst
# Create build user
RUN useradd -m -s /bin/bash docker && \
echo 'docker ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
# Set locale
RUN echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && \
locale-gen
ENV LANG=en_US.UTF-8 \
LANGUAGE=en_US:en \
LC_ALL=en_US.UTF-8
# Ensure Perl tools (pod2man, yapp, etc.) are in standard PATH
RUN for f in /usr/bin/core_perl/*; do [ -f "$f" ] && ln -sf "$f" /usr/bin/ 2>/dev/null; done; \
for f in /usr/bin/vendor_perl/*; do [ -f "$f" ] && ln -sf "$f" /usr/bin/ 2>/dev/null; done; \
true
### Cross compiling on ARM
RUN if [ "$(uname -m)" = "aarch64" ]; then pacman -S --noconfirm qemu-user-static; fi
RUN if [ ! -d /lib64 ]; then ln -sf /usr/x86_64-archr-linux-gnu/lib64 /lib64 2>/dev/null || true; fi
RUN if [ ! -d /lib/x86_64-archr-linux-gnu ]; then ln -sf /usr/x86_64-archr-linux-gnu/lib /lib/x86_64-archr-linux-gnu 2>/dev/null || true; fi
RUN mkdir -p /work && chown docker /work
WORKDIR /work
USER docker
-33
View File
@@ -1,33 +0,0 @@
<img src="distributions/ArchR/logos/archr-logo.png" width=192>
---
## Licenses
ArchR is a Linux distribution forked from [ROCKNIX](https://github.com/ROCKNIX/distribution), made up of many open-source components. Components are provided under their respective licenses. This distribution includes components licensed for non-commercial use only.
### ArchR Branding
ArchR branding and images are licensed under a [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License](https://creativecommons.org/licenses/by-nc-sa/4.0/). Original ROCKNIX branding remains the property of the ROCKNIX project.
You are free to:
- Share: copy and redistribute the material in any medium or format
- Adapt: remix, transform, and build upon the material
Under the following terms:
- Attribution: You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
- NonCommercial: You may not use the material for commercial purposes.
- ShareAlike: If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original.
### ArchR Software
Copyright 2024-2026 ArchR (https://github.com/archr-linux)
Original software and scripts developed by the ArchR team are licensed under the terms of the [GNU GPL Version 2](https://choosealicense.com/licenses/gpl-2.0/). The full license can be found in this project's licenses folder.
Portions of this software are derived from ROCKNIX, Copyright 2024 ROCKNIX (https://github.com/ROCKNIX).
### Bundled Works
All other software is provided under each component's respective license. These licenses can be found in the software sources or in this project's licenses folder. Modifications to bundled software and scripts by the ArchR team are licensed under the terms of the software being modified.
-111
View File
@@ -1,111 +0,0 @@
-include $(HOME)/.archr/options
all: world
system:
./scripts/image
release:
./scripts/image release
image:
./scripts/image mkimage
noobs:
./scripts/image noobs
clean:
./scripts/makefile_helper --clean
distclean:
./scripts/makefile_helper --distclean
src-pkg:
tar cvJf sources.tar.xz sources
docs:
./tools/foreach './scripts/clean emulators && ./scripts/build emulators'
world: RK3326
kconfig-olddefconfig-%:
DEVICE=$* ./tools/adjust_kernel_config olddefconfig
kconfig-menuconfig-%:
DEVICE=$* ./tools/adjust_kernel_config menuconfig
RK3326:
unset DEVICE_ROOT
PROJECT=ArchR DEVICE=RK3326 ARCH=arm ./scripts/build_distro
PROJECT=ArchR DEVICE=RK3326 ARCH=aarch64 ./scripts/build_distro
update:
PROJECT=ArchR DEVICE=RK3326 ARCH=aarch64 ./scripts/update_packages
package:
./scripts/build ${PACKAGE}
package-clean:
./scripts/clean ${PACKAGE}
## Docker builds - overview
# docker-* commands just wire up docker to call the normal make command via docker
# For example: make docker-RK3326 will use docker to call: make RK3326
# All variables are scoped to docker-* commands to prevent weird collisions/behavior with non-docker commands
docker-%: DOCKER_IMAGE := "archr-build:latest"
# DOCKER_WORK_DIR is the directory in the Docker image - it is set to /work by default
# Anytime this directory changes, you must run `make clean` similarly to moving the distribution directory
docker-%: DOCKER_WORK_DIR := $(shell if [ -n "${DOCKER_WORK_DIR}" ]; then echo ${DOCKER_WORK_DIR}; else echo "$$(pwd)" ; fi)
# ${HOME}/.archr/options is a global options file containing developer and build settings.
docker-%: GLOBAL_SETTINGS := $(shell if [ -f "${HOME}/.archr/options" ]; then echo "-v \"${HOME}/.archr/options:${HOME}/.archr/options\""; else echo ""; fi)
# LOCAL_SSH_KEYS_FILE is a variable that contains the location of the authorized keys file for development build use. It will be mounted into the container if it exists.
docker-%: LOCAL_SSH_KEYS_FILE := $(shell if [ -n "${LOCAL_SSH_KEYS_FILE}" ]; then echo "-v \"${LOCAL_SSH_KEYS_FILE}:${LOCAL_SSH_KEYS_FILE}\""; else echo ""; fi)
# EMULATIONSTATION_SRC is a variable that contains the location of local emulationstation source code. It will be mounted into the container if it exists.
docker-%: EMULATIONSTATION_SRC := $(shell if [ -n "${EMULATIONSTATION_SRC}" ]; then echo "-v \"${EMULATIONSTATION_SRC}:${EMULATIONSTATION_SRC}\""; else echo ""; fi)
# UID is the user ID of current user - ensures docker sets file permissions properly
docker-%: UID := $(shell id -u)
# GID is the main user group of current user - ensures docker sets file permissions properly
docker-%: GID := $(shell id -g)
# PWD is 'present working directory' and passes through the full path to current dir to docker (becomes 'work')
docker-%: PWD := $(shell pwd)
# Command to use (either `docker` or `podman`)
docker-%: DOCKER_CMD:= $(shell if which docker 2>/dev/null 1>/dev/null; then echo "docker"; elif which podman 2>/dev/null 1>/dev/null; then echo "podman"; fi)
# Podman requires some extra args (`--userns=keep-id` and `--security-opt=label=disable`). Set those args if using podman
# Make sure that docker isn't just an alias for podman
docker-%: PODMAN_ARGS:= $(shell if echo "$$(docker --version 2>/dev/null || podman --version 2>/dev/null )" | grep podman 1>/dev/null ; then echo "--userns=keep-id --security-opt=label=disable -v /proc/mounts:/etc/mtab"; fi)
# Launch docker as interactive if this is an interactive shell (allows ctrl-c for manual and running non-interactive - aka: build server)
docker-%: INTERACTIVE=$(shell [ -t 0 ] && echo "-it")
# By default pass through anything after `docker-` back into `make`
docker-%: COMMAND=make $*
# Get .env file ready
docker-%: $(shell ./scripts/get_env > .env)
# If the user issues a `make docker-shell` just start up bash as the shell to run commands
docker-shell: COMMAND=bash
# Command: builds and saves a docker builder image locally.
# The build user must also be a member of the "docker" group.
docker-image-build:
$(DOCKER_CMD) buildx create --use
$(DOCKER_CMD) buildx build --tag $(DOCKER_IMAGE) --platform $(shell if [ "$$(uname -m)" = "aarch64" ]; then echo "linux/arm64"; else echo "linux/amd64"; fi) --load .
# Command: pulls latest docker image from dockerhub. This will *replace* locally built version.
docker-image-pull:
$(DOCKER_CMD) pull $(DOCKER_IMAGE)
# Wire up docker to call equivalent make files using % to match and $* to pass the value matched by %
docker-%:
BUILD_DIR="$(DOCKER_WORK_DIR)" $(DOCKER_CMD) run $(PODMAN_ARGS) $(INTERACTIVE) --init --env-file .env --rm --user $(UID):$(GID) $(GLOBAL_SETTINGS) $(LOCAL_SSH_KEYS_FILE) $(EMULATIONSTATION_SRC) -v "$(PWD)":"$(DOCKER_WORK_DIR)" -v /tmp:/tmp -w "$(DOCKER_WORK_DIR)" $(DOCKER_EXTRA_OPTS) $(DOCKER_IMAGE) $(COMMAND)

Some files were not shown because too many files have changed in this diff Show More