Skip to content

Commit

Permalink
feat: Add debian 12
Browse files Browse the repository at this point in the history
  • Loading branch information
jbeyerstedt committed Oct 10, 2024
1 parent c68fde2 commit 2a5cfba
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 5 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/docker-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ env:

jobs:
dockcross-build-push:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
Expand All @@ -21,7 +21,9 @@ jobs:
- name: linux-armhf-ubuntu18
- name: linux-armhf-debian10
- name: linux-armhf-debian11
- name: linux-armhf-debian12
- name: linux-aarch64-debian11
- name: linux-aarch64-debian12

steps:
- name: Checkout repository
Expand Down
10 changes: 6 additions & 4 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ Don't forget to replace the ghcr.io name with your tag in the `docker run` comma

Image | arch | gcc | glibc
----------------------- | ------- | --- | ------
linux-aarch64-debian11 | aarch64 | 10 | 2.31
linux-armhf-ubuntu18 | armhf | 7 | 2.27
linux-armhf-debian10 | armhf | 8 | 2.28
linux-armhf-debian11 | armhf | 10 | 2.31
linux-aarch64-debian11 | aarch64 | 10 | 2.31
linux-aarch64-debian12 | aarch64 | 12 | 2.36
linux-armhf-ubuntu18 | armhf | 7 | 2.27
linux-armhf-debian10 | armhf | 8 | 2.28
linux-armhf-debian11 | armhf | 10 | 2.31
linux-armhf-debian12 | armhf | 12 | 2.36
25 changes: 25 additions & 0 deletions linux-aarch64-debian12/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
FROM debian:11-slim

ARG workdir=/work
ENV CROSS_SYSROOT=/var/cross-sysroot

# install basic utilities
RUN apt update && apt -y install git rsync python3

# git might complain about ownership, so ignore it
RUN git config --global --add safe.directory $workdir

# install aarch64 cross-compiler
RUN apt -y install g++-aarch64-linux-gnu

# install basic build tools
RUN apt -y install build-essential make ccache cmake ninja-build

# setup CMake for cross-compiling
RUN mkdir -p ${CROSS_SYSROOT}/include/
RUN mkdir -p ${CROSS_SYSROOT}/lib/
ENV CMAKE_TOOLCHAIN_FILE=${CROSS_SYSROOT}/toolchain.cmake
COPY linux-aarch64-tc.cmake ${CMAKE_TOOLCHAIN_FILE}
COPY cmake-cross.sh /usr/bin/cmake-cross

WORKDIR $workdir
25 changes: 25 additions & 0 deletions linux-armhf-debian12/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
FROM debian:11-slim

ARG workdir=/work
ENV CROSS_SYSROOT=/var/cross-sysroot

# install basic utilities
RUN apt update && apt -y install git rsync python3

# git might complain about ownership, so ignore it
RUN git config --global --add safe.directory $workdir

# install armhf cross-compiler
RUN apt -y install g++-arm-linux-gnueabihf

# install basic build tools
RUN apt -y install build-essential make ccache cmake ninja-build

# setup CMake for cross-compiling
RUN mkdir -p ${CROSS_SYSROOT}/include/
RUN mkdir -p ${CROSS_SYSROOT}/lib/
ENV CMAKE_TOOLCHAIN_FILE=${CROSS_SYSROOT}/toolchain.cmake
COPY linux-armhf-tc.cmake ${CMAKE_TOOLCHAIN_FILE}
COPY cmake-cross.sh /usr/bin/cmake-cross

WORKDIR $workdir

0 comments on commit 2a5cfba

Please sign in to comment.