Skip to content

Commit

Permalink
Build separate containers for targeting arm and i386
Browse files Browse the repository at this point in the history
  • Loading branch information
ColinFinck committed Feb 26, 2024
1 parent 28cc46c commit a462059
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 10 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,20 @@ jobs:
docker:
runs-on: ubuntu-22.04

strategy:
matrix:
target_arch: [arm, i386]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Build and Push Docker Image
uses: mr-smithers-excellent/docker-build-push@v5
with:
image: windows-ce-build-environment
image: windows-ce-build-environment-${{ matrix.target_arch }}
registry: ghcr.io
buildArgs: target_arch=${{ matrix.target_arch }}
addLatest: true
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
16 changes: 7 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,24 +1,22 @@
#
# Dockerfile for creating a Windows CE build environment (ARM and i386, using https://github.com/enlyze/cegcc-build)
# Dockerfile for creating a Windows CE build environment using https://github.com/enlyze/cegcc-build
# Copyright (c) 2024 Colin Finck, ENLYZE GmbH <[email protected]>
# SPDX-License-Identifier: MIT
#

FROM debian:12-slim
MAINTAINER Colin Finck <[email protected]>
LABEL Description="Debian with CeGCC 9.3.0 (ENLYZE version for ARM and i386) and Git"
LABEL Description="Debian with CeGCC 9.3.0 (ENLYZE version for ${target_arch}) and Git"

ARG target_arch

ENV PATH=/opt/cegcc-${target_arch}:$PATH

RUN apt update && \
DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends bison build-essential ca-certificates flex git libgmp-dev libmpc-dev libmpfr-dev texinfo

RUN git clone --depth 1 --recursive --shallow-submodules https://github.com/enlyze/cegcc-build && \
cd cegcc-build && \
./build_cf.sh /opt/cegcc-arm arm-mingw32ce && \
cd .. && \
rm -rf cegcc-build

RUN git clone --depth 1 --recursive --shallow-submodules https://github.com/enlyze/cegcc-build && \
cd cegcc-build && \
./build_cf.sh /opt/cegcc-i386 i386-mingw32ce && \
./build_cf.sh /opt/cegcc-${target_arch} ${target_arch}-mingw32ce && \
cd .. && \
rm -rf cegcc-build

0 comments on commit a462059

Please sign in to comment.