Compare commits
9 Commits
main
...
57cccd1cf2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
57cccd1cf2 | ||
|
|
13bcb67fa5 | ||
|
|
2fae1da76f | ||
|
|
bf1882e528 | ||
|
|
94c1ad26d5 | ||
|
|
8712d22ff5 | ||
|
|
2df45c01ff | ||
|
|
105c1be3df | ||
|
|
716962af71 |
@@ -7,8 +7,7 @@
|
||||
},
|
||||
"workspaceMount": "",
|
||||
"runArgs": [
|
||||
"--volume=${localWorkspaceFolder}:/workspaces/${localWorkspaceFolderBasename}:Z",
|
||||
"--platform=linux/amd64"
|
||||
"--volume=${localWorkspaceFolder}:/workspaces/${localWorkspaceFolderBasename}:Z"
|
||||
],
|
||||
"customizations": {
|
||||
"vscode": {
|
||||
|
||||
@@ -22,7 +22,7 @@ jobs:
|
||||
-
|
||||
name: Restore docker image
|
||||
id: cache-docker
|
||||
uses: actions/cache@v3
|
||||
uses: https://github.com/actions/cache@v3
|
||||
with:
|
||||
path: /tmp/docker
|
||||
key: ${{ runner.os }}-docker-${{ hashFiles('builder.Dockerfile') }}
|
||||
@@ -45,7 +45,7 @@ jobs:
|
||||
-
|
||||
name: Restore docker image
|
||||
id: cache-docker
|
||||
uses: actions/cache@v3
|
||||
uses: https://github.com/actions/cache@v3
|
||||
with:
|
||||
path: /tmp/docker
|
||||
key: ${{ runner.os }}-docker-${{ hashFiles('builder.Dockerfile') }}
|
||||
@@ -59,9 +59,8 @@ jobs:
|
||||
run: |
|
||||
docker run \
|
||||
--rm \
|
||||
--platform linux/amd64 \
|
||||
--workdir /builder/mnt \
|
||||
-v ${{ github.workspace }}:/builder/mnt \
|
||||
-v ${{ gitea.workspace }}:/builder/mnt \
|
||||
cproject-builder:latest \
|
||||
/bin/bash -c "rm -rf build; cmake -B build; cmake --build build"
|
||||
-
|
||||
@@ -69,25 +68,24 @@ jobs:
|
||||
run: |
|
||||
docker run \
|
||||
--rm \
|
||||
--platform linux/amd64 \
|
||||
--workdir /builder/mnt/tests/unittest \
|
||||
-v ${{ github.workspace }}:/builder/mnt \
|
||||
-v ${{ gitea.workspace }}:/builder/mnt \
|
||||
cproject-builder:latest \
|
||||
/bin/bash -c "ceedling clobber; ceedling gcov:all; ceedling utils:gcov"
|
||||
-
|
||||
name: Archive coverage results
|
||||
shell: bash
|
||||
run: |
|
||||
staging="reports-${{github.run_number}}"
|
||||
staging="reports-${{gitea.run_number}}"
|
||||
mkdir -p "$staging"
|
||||
cp -r tests/unittest/build/artifacts/gcov "$staging"
|
||||
tar czf "$staging.tar.gz" "$staging"
|
||||
echo "ASSET=$staging.tar.gz" >> $GITHUB_ENV
|
||||
echo "ASSET=$staging.tar.gz" >> $GITEA_ENV
|
||||
-
|
||||
name: Archive artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: reports-${{github.run_number}}
|
||||
name: reports-${{gitea.run_number}}
|
||||
path: ${{ env.ASSET }}
|
||||
retention-days: 3
|
||||
|
||||
@@ -2,7 +2,7 @@ ARG base_tag=bullseye
|
||||
ARG base_img=mcr.microsoft.com/vscode/devcontainers/base:dev-${base_tag}
|
||||
# ARG base_img=debian:${base_tag}
|
||||
|
||||
FROM --platform=linux/amd64 ${base_img} AS builder-install
|
||||
FROM ${base_img} AS builder-install
|
||||
|
||||
# the following shows how to install the latest version of a package.
|
||||
# you can determine the installed version with `apt-cache policy <list of packages>` and fix
|
||||
@@ -15,7 +15,6 @@ RUN apt-get install -y --no-install-recommends \
|
||||
cmake \
|
||||
build-essential \
|
||||
gcc \
|
||||
g++-multilib \
|
||||
locales \
|
||||
make \
|
||||
ruby \
|
||||
@@ -61,29 +60,28 @@ RUN ln -s /usr/bin/clang-tidy-${llvm_version} /usr/local/bin/clang-tidy
|
||||
# this can take a significant amount of time (e.g., several minutes just to compile one tool),
|
||||
# and also increases the image size significantly. therefore, we go for option B below.
|
||||
|
||||
# RUN curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y
|
||||
# ENV PATH=/root/.cargo/bin:$PATH
|
||||
RUN curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y
|
||||
ENV PATH=/root/.cargo/bin:$PATH
|
||||
|
||||
# Each takes around 280 s to build on an M2 macbook air
|
||||
# RUN cargo install run-clang-format
|
||||
# RUN cargo install run-clang-tidy
|
||||
RUN cargo install run-clang-format
|
||||
RUN cargo install run-clang-tidy
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# option B: install pre-built clang wrappers
|
||||
# RUN mkdir -p /usr/local/run-clang-format
|
||||
# RUN wget -O clang-utils.tgz "https://github.com/lmapii/run-clang-format/releases/download/v1.4.14/run-clang-format-v1.4.14-i686-unknown-linux-gnu.tar.gz" && \
|
||||
# tar -C /usr/local/run-clang-format -xzf clang-utils.tgz --strip-components 1 && \
|
||||
# rm clang-utils.tgz
|
||||
# ENV PATH /usr/local/run-clang-format:$PATH
|
||||
# RUN run-clang-format --version
|
||||
|
||||
RUN mkdir -p /usr/local/run-clang-format
|
||||
RUN wget -O clang-utils.tgz "https://github.com/lmapii/run-clang-format/releases/download/v1.4.14/run-clang-format-v1.4.14-i686-unknown-linux-gnu.tar.gz" && \
|
||||
tar -C /usr/local/run-clang-format -xzf clang-utils.tgz --strip-components 1 && \
|
||||
rm clang-utils.tgz
|
||||
ENV PATH /usr/local/run-clang-format:$PATH
|
||||
RUN run-clang-format --version
|
||||
|
||||
RUN mkdir -p /usr/local/run-clang-tidy
|
||||
RUN wget -O clang-utils.tgz "https://github.com/lmapii/run-clang-tidy/releases/download/v0.2.5/run-clang-tidy-v0.2.5-i686-unknown-linux-gnu.tar.gz" && \
|
||||
tar -C /usr/local/run-clang-tidy -xzf clang-utils.tgz --strip-components 1 && \
|
||||
rm clang-utils.tgz
|
||||
ENV PATH /usr/local/run-clang-tidy:$PATH
|
||||
RUN run-clang-tidy --version
|
||||
# RUN mkdir -p /usr/local/run-clang-tidy
|
||||
# RUN wget -O clang-utils.tgz "https://github.com/lmapii/run-clang-tidy/releases/download/v0.2.5/run-clang-tidy-v0.2.5-i686-unknown-linux-gnu.tar.gz" && \
|
||||
# tar -C /usr/local/run-clang-tidy -xzf clang-utils.tgz --strip-components 1 && \
|
||||
# rm clang-utils.tgz
|
||||
# ENV PATH /usr/local/run-clang-tidy:$PATH
|
||||
# RUN run-clang-tidy --version
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# install unity and ceedling
|
||||
|
||||
1
makefile
1
makefile
@@ -7,7 +7,6 @@ builder-run :
|
||||
docker run \
|
||||
--rm \
|
||||
-it \
|
||||
--platform linux/amd64 \
|
||||
--workdir /builder/mnt \
|
||||
-v .:/builder/mnt \
|
||||
$(project_name)-builder:latest \
|
||||
|
||||
@@ -102,24 +102,20 @@
|
||||
- -Wall
|
||||
- -g0
|
||||
- -O3
|
||||
- -m32
|
||||
:link:
|
||||
:*:
|
||||
- -g0
|
||||
- -O3
|
||||
- -m32
|
||||
:gcov:
|
||||
:compile:
|
||||
:*:
|
||||
- -g0
|
||||
- -O3
|
||||
- -Wall
|
||||
- -m32
|
||||
:link:
|
||||
:*:
|
||||
- -g0
|
||||
- -O3
|
||||
- -m32
|
||||
|
||||
|
||||
# LIBRARIES
|
||||
|
||||
Reference in New Issue
Block a user