remove all armhf (#564)

* remove all armhf

* fix that

* Revert "build_system: stream build output directly into rootfs (#552)"

This reverts commit 71e7369174.

* fix up build

* wifi works

* fix graphics

* revert that

* add back
This commit is contained in:
Adeeb Shihadeh
2026-04-30 17:56:53 -07:00
committed by GitHub
parent bb525191b3
commit e8e36e592d
92 changed files with 130 additions and 174 deletions

View File

@@ -33,6 +33,20 @@ COPY ./userspace/compile-modemmanager.sh /tmp/agnos/
RUN --mount=type=cache,target=/root/.ccache,id=modemmanager,sharing=shared \
/tmp/agnos/compile-modemmanager.sh
# power_burn_max
FROM agnos-compiler AS agnos-compiler-power-burn
RUN apt-get update && apt-get install -yq --no-install-recommends \
opencl-c-headers
COPY ./userspace/libs/* /usr/lib/aarch64-linux-gnu/
COPY ./userspace/power_burn/power_burn_max.c /tmp/agnos/
RUN gcc -O2 -o /tmp/power_burn_max /tmp/agnos/power_burn_max.c \
-lOpenCL -lpthread -ldl
# irsc_util
FROM agnos-compiler AS agnos-compiler-irsc-util
COPY ./userspace/irsc_util/irsc_util.c /tmp/agnos/
RUN gcc -O2 -Wall -Wextra -o /tmp/irsc_util /tmp/agnos/irsc_util.c
# ################## #
# ###### Base ###### #
# ################## #
@@ -67,7 +81,13 @@ RUN /tmp/agnos/openpilot_python_dependencies.sh
FROM agnos-base
# Hardware rootfs overlay
COPY ./userspace/root/ /
COPY ./userspace/root/etc/ /etc/
COPY ./userspace/root/lib/ /usr/lib/
COPY ./userspace/root/lib64/ /usr/lib64/
COPY ./userspace/root/sbin/ /usr/sbin/
COPY ./userspace/root/system/ /system/
COPY ./userspace/root/usr/ /usr/
RUN mkdir -p /dsp /firmware /persist /data /cache /rwtmp
# Hardware setup
COPY ./userspace/hardware_setup.sh /tmp/agnos
@@ -90,6 +110,8 @@ RUN cd /tmp && \
libmm-glib0 \
libpolkit-gobject-1-0 \
libsystemd0 \
libwayland-client0 \
libwayland-server0 \
polkitd \
mobile-broadband-provider-info && \
apt-get -o Dpkg::Options::="--force-overwrite" install -yq ./libqmi.deb && \
@@ -135,13 +157,11 @@ RUN touch -r /lib/systemd/systemd /etc/fstab
COPY ./userspace/usr/comma/ /usr/$USERNAME/
COPY ./userspace/usr/share/fonts/* /usr/share/fonts/
COPY ./userspace/libs/* /usr/lib/aarch64-linux-gnu/
COPY ./userspace/libs32/* /usr/lib/arm-linux-gnueabihf/
COPY ./output/linux-headers/include/ /usr/include/
COPY ./userspace/power_burn/power_burn_max.c /tmp/agnos/
RUN gcc -O2 -o /home/$USERNAME/power_burn_max /tmp/agnos/power_burn_max.c \
-lOpenCL -lpthread -ldl && rm /tmp/agnos/power_burn_max.c \
&& chown $USERNAME: /home/$USERNAME/power_burn_max
COPY --from=agnos-compiler-power-burn /tmp/power_burn_max /home/$USERNAME/power_burn_max
RUN chown $USERNAME: /home/$USERNAME/power_burn_max
COPY --from=agnos-compiler-irsc-util /tmp/irsc_util /usr/bin/irsc_util
# Setup systemd services
COPY ./userspace/services.sh /tmp/agnos

View File

@@ -8,9 +8,6 @@ HOST=comma
touch /TICI
touch /AGNOS
# Add armhf as supported architecture
dpkg --add-architecture armhf
# Install apt-fast
apt-get update
apt-get install -yq curl sudo wget
@@ -120,67 +117,9 @@ echo "comma ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
# setup /bin/sh symlink
ln -sf /bin/bash /bin/sh
# Install necessary libs
# Install additional runtime packages
apt-fast update -yq
apt-fast install --no-install-recommends -yq \
libacl1:armhf \
libasan6-armhf-cross \
libatomic1-armhf-cross \
libattr1:armhf \
libaudit1:armhf \
libblkid1:armhf \
libc6:armhf \
libc6-armhf-cross \
libc6-dev:armhf \
libc6-dev-armhf-cross \
libcairo2:armhf \
libcap2:armhf \
libdrm2:armhf \
libevdev2:armhf \
libexpat1:armhf \
libffi8:armhf \
libfontconfig1:armhf \
libfreetype6:armhf \
libgbm1:armhf \
libgcc-11-dev-armhf-cross \
libglib2.0-0t64:armhf \
libgomp1-armhf-cross \
libgudev-1.0-0:armhf \
libinput-bin:armhf \
libinput-dev:armhf \
libinput10:armhf \
libjpeg-dev:armhf \
libjpeg-turbo8:armhf \
libjpeg-turbo8-dev:armhf \
libjpeg8:armhf \
libjpeg8-dev:armhf \
libkmod2:armhf \
libmtdev1t64:armhf \
libpam0g:armhf \
libpam0g-dev:armhf \
libpcre3:armhf \
libpixman-1-0:armhf \
libpng16-16t64:armhf \
libselinux1:armhf \
libstdc++6:armhf \
libstdc++6-armhf-cross \
libubsan1-armhf-cross \
libudev-dev:armhf \
libudev1:armhf \
libuuid1:armhf \
libwacom9:armhf \
libx11-6:armhf \
libxau6:armhf \
libxcb-render0:armhf \
libxcb-shm0:armhf \
libxcb1:armhf \
libxdmcp6:armhf \
libxext6:armhf \
libxkbcommon0:armhf \
libxrender1:armhf \
linux-libc-dev:armhf \
linux-libc-dev-armhf-cross \
zlib1g:armhf \
libegl1 \
libegl-dev \
libgles1 \
@@ -195,5 +134,6 @@ apt-fast install --no-install-recommends -yq \
kmod \
wpasupplicant \
hostapd \
libgtk2.0-dev \
libxml2:armhf \
libgtk2.0-dev
rm -rf /var/lib/apt/lists/*

View File

@@ -1,7 +1,6 @@
[Unit]
Description=Start cdsp
SourcePath=/usr/bin/cdsp.sh
Before=cdsprpcd.service
[Service]
Type=oneshot

View File

@@ -0,0 +1,63 @@
#include <errno.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <unistd.h>
#ifndef AF_MSM_IPC
#define AF_MSM_IPC 27
#endif
#ifndef PF_MSM_IPC
#define PF_MSM_IPC AF_MSM_IPC
#endif
struct config_sec_rules_args {
int num_group_info;
uint32_t service_id;
uint32_t instance_id;
unsigned int reserved;
gid_t group_id[0];
};
#define ALL_SERVICE 0xFFFFFFFFU
#define ALL_INSTANCE 0xFFFFFFFFU
#define AID_NET_RAW 3004
#define IPC_ROUTER_IOCTL_MAGIC 0xC3
#define IPC_ROUTER_IOCTL_CONFIG_SEC_RULES \
_IOR(IPC_ROUTER_IOCTL_MAGIC, 5, struct config_sec_rules_args)
int main(int argc, char **argv) {
(void)argc;
(void)argv;
int fd = socket(AF_MSM_IPC, SOCK_DGRAM, 0);
if (fd < 0) {
fprintf(stderr, "irsc_util: socket(AF_MSM_IPC) failed: %s\n", strerror(errno));
return 1;
}
struct {
struct config_sec_rules_args args;
gid_t group_id;
} rule = {
.args = {
.num_group_info = 1,
.service_id = ALL_SERVICE,
.instance_id = ALL_INSTANCE,
},
.group_id = AID_NET_RAW,
};
int ret = ioctl(fd, IPC_ROUTER_IOCTL_CONFIG_SEC_RULES, &rule);
if (ret < 0) {
fprintf(stderr, "irsc_util: IPC router rejected security config: %s\n", strerror(errno));
close(fd);
return 1;
}
close(fd);
return 0;
}

View File

@@ -1 +0,0 @@
libffi.so.6.0.4

Binary file not shown.

View File

@@ -1 +0,0 @@
libinput.so.10.13.0

Binary file not shown.

View File

@@ -5,51 +5,26 @@ echo "Installing openpilot dependencies"
# Install necessary libs
apt-fast update
apt-fast install --no-install-recommends -yq \
autoconf \
automake \
build-essential \
casync \
clang \
curl \
gpiod \
libarchive-dev \
libass-dev \
libcurl4-openssl-dev \
libczmq-dev \
libdbus-1-dev \
libffi-dev \
libfreetype6-dev \
libglfw3-dev \
libglib2.0-0t64 \
libi2c-dev \
liblzma-dev \
libomp-dev \
libportaudio2 \
libsdl2-dev \
libsqlite3-dev \
libtool \
libusb-1.0-0-dev \
libuv1-dev \
libva-dev \
libvdpau-dev \
libvorbis-dev \
libxcb-icccm4 \
libxcb-image0 \
libxcb-keysyms1 \
libxcb-render-util0 \
libxcb-shm0-dev \
libxcb-xfixes0-dev \
libxcb-xinerama0 \
libxcb-xinput0 \
libxcb-xkb1 \
libxcb1-dev \
libxkbcommon-x11-0 \
locales \
nethogs \
pkg-config \
portaudio19-dev \
texinfo \
vnstat \
wget \
xvfb \
zlib1g-dev

View File

@@ -0,0 +1,3 @@
# Create Android-style boot partition links for vendor services.
KERNEL=="mmcblk[0-9]*p[0-9]*", SUBSYSTEM=="block", ACTION=="add", RUN+="/etc/udev/scripts/bootdevice-by-name.sh %k"
KERNEL=="[hs]d[a-z][0-9]*", SUBSYSTEM=="block", ACTION=="add", RUN+="/etc/udev/scripts/bootdevice-by-name.sh %k"

View File

@@ -0,0 +1,22 @@
#!/bin/sh
set -e
dev="$1"
uevent="/sys/class/block/$dev/uevent"
[ -e "$uevent" ] || exit 0
boot_dev="$(sed -n 's/.*androidboot.bootdevice=\([^ ]*\).*/\1/p' /proc/cmdline | awk '{print $NF}')"
[ -n "$boot_dev" ] || exit 0
real_sysfs_path="$(realpath "/sys/class/block/$dev")"
case "$real_sysfs_path" in
*"$boot_dev"*) ;;
*) exit 0 ;;
esac
partition_name="$(sed -n 's/^PARTNAME=//p' "$uevent")"
[ -n "$partition_name" ] || exit 0
mkdir -p /dev/block/bootdevice/by-name
ln -sf "/dev/$dev" "/dev/block/bootdevice/by-name/$partition_name"

View File

@@ -1,15 +0,0 @@
# Copyright (c) 2017 Qualcomm Technologies, Inc.
# All Rights Reserved.
# Confidential and Proprietary - Qualcomm Technologies, Inc.
#
[Unit]
Description=adsprpc Service
SourcePath= /usr/bin/adsprpcd
[Service]
Restart=always
ExecStart= /usr/bin/adsprpcd
[Install]
WantedBy=multi-user.target

View File

@@ -1,15 +0,0 @@
# Copyright (c) 2018 Qualcomm Technologies, Inc.
# All Rights Reserved.
# Confidential and Proprietary - Qualcomm Technologies, Inc.
#
[Unit]
Description=cdsprpc Service
SourcePath= /usr/bin/cdsprpcd
[Service]
Restart=always
ExecStart= /usr/bin/cdsprpcd
[Install]
WantedBy=multi-user.target

View File

@@ -1,15 +1,10 @@
# Copyright (c) 2017 Qualcomm Technologies, Inc.
# All Rights Reserved.
# Confidential and Proprietary - Qualcomm Technologies, Inc.
#
[Unit]
Description= irsc-util Service
Description=IRSC util Service
SourcePath=/usr/bin/irsc_util
DefaultDependencies=no
[Service]
Restart=no
Type=oneshot
RemainAfterExit=yes
ExecStart=/usr/bin/irsc_util /etc/sec_config

View File

@@ -1 +0,0 @@
/lib/systemd/system/irsc_util.service

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -1 +1 @@
libEGL.so.1.0.0
libEGL_adreno.so

View File

@@ -1 +1 @@
libEGL.so.1.0.0
libEGL_adreno.so

View File

@@ -1 +1 @@
libEGL.so.1.0.0
libEGL_adreno.so

View File

@@ -1 +1 @@
libGLESv2.so.2.0.0
libGLESv2_adreno.so

View File

@@ -1 +1 @@
libGLESv2.so.2.0.0
libGLESv2_adreno.so

View File

@@ -1 +1 @@
libGLESv2.so.2.0.0
libGLESv2_adreno.so

View File

@@ -0,0 +1 @@
libOpenCL.so.1.0.0

View File

@@ -0,0 +1 @@
libgbm.so.1

Binary file not shown.

View File

@@ -0,0 +1 @@
libwayland-egl.so.1

View File

@@ -0,0 +1 @@
libwayland-egl.so.1

View File

@@ -1 +0,0 @@
/usr/lib/libgralloc.so

View File

@@ -1 +0,0 @@
libEGL.so.1.0.0

View File

@@ -1 +0,0 @@
libEGL.so.1.0.0

View File

@@ -1 +0,0 @@
libEGL.so.1.0.0

View File

@@ -1 +0,0 @@
libEGL_adreno.so

View File

@@ -1 +0,0 @@
libGLESv1_CM.so.1.0.0

View File

@@ -1 +0,0 @@
libGLESv1_CM.so.1.0.0

View File

@@ -1 +0,0 @@
libGLESv1_CM.so.1.0.0

View File

@@ -1 +0,0 @@
libGLESv1_CM_adreno.so

View File

@@ -1 +0,0 @@
libGLESv2.so.2.0.0

View File

@@ -1 +0,0 @@
libGLESv2.so.2.0.0

View File

@@ -1 +0,0 @@
libGLESv2.so.2.0.0

View File

@@ -1 +0,0 @@
libGLESv2_adreno.so

View File

@@ -1 +0,0 @@
libbinder.so.0.0.0

View File

@@ -1 +0,0 @@
libcutils.so.0.0.0

View File

@@ -1 +0,0 @@
libhardware.so.0.0.0

View File

@@ -1 +0,0 @@
liblog.so.0.0.0

View File

@@ -1 +0,0 @@
liblogwrap.so.0.0.0

View File

@@ -1 +0,0 @@
libpcre.so.1.2.6

View File

@@ -1 +0,0 @@
libsync.so.0.0.0

View File

@@ -1 +0,0 @@
libutils.so.0.0.0

View File

@@ -1,10 +1,9 @@
#!/bin/bash -e
# Enable DSP support services
systemctl enable irsc_util.service
systemctl enable adsp
systemctl enable cdsp
systemctl enable adsprpcd
systemctl enable cdsprpcd
# Enable our services
systemctl enable fs_setup.service
@@ -32,10 +31,6 @@ systemctl enable screen_calibration.service
# Disable some of our services
systemctl disable agnos-tests.service
# Disable third party services
systemctl disable darkstat.service
systemctl disable vnstat.service
# Disable SSH by default
systemctl disable ssh
@@ -78,10 +73,5 @@ systemctl disable remote-fs-pre.target
# no influence on any interface, all interfaces work fine
systemctl disable networking.service
# TODO: this doesn't actually disable unless run twice...
# Service fails with Status: "No devices to monitor"
systemctl disable smartd.service
systemctl disable smartd.service
systemctl disable console-setup.service
systemctl disable sfsconfig.service