Skip to content

Commit

Permalink
Merge pull request #360 from cryptogarageinc/feature/arm-build
Browse files Browse the repository at this point in the history
feat: arm build
  • Loading branch information
k-matsuzawa authored Sep 20, 2022
2 parents 58a1602 + 4abbe43 commit 9a39e0e
Show file tree
Hide file tree
Showing 7 changed files with 100 additions and 32 deletions.
5 changes: 5 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
build
node_modules
external/cfd-core
external/googletest
external/libwally-core
20 changes: 13 additions & 7 deletions .github/workflows/check_pre-merge_develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,16 @@ jobs:
shared: [on, off]
include:
- os: windows-2019
shared: [on, off]
shared: on
generator: 'Visual Studio 16 2019'
- os: windows-2019
shared: off
generator: 'Visual Studio 16 2019'
- os: windows-2022
shared: on
generator: 'Visual Studio 17 2022'
- os: windows-2022
shared: [on, off]
shared: off
generator: 'Visual Studio 17 2022'

steps:
Expand Down Expand Up @@ -85,11 +91,11 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, ubuntu-18.04]
os: [ubuntu-22.04, ubuntu-20.04]
shared: [on, off]
elements: [on, off]
exclude:
- os: ubuntu-18.04
elements: [on]
include:
- os: ubuntu-22.04
elements: off

steps:
Expand All @@ -113,7 +119,7 @@ jobs:
doxygen-ubuntu:
name: doxygen-check
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v2
Expand Down
63 changes: 60 additions & 3 deletions .github/workflows/check_pre-merge_master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04, ubuntu-20.04, ubuntu-18.04]
os: [ubuntu-22.04, ubuntu-20.04]
shared: [on, off]
elements: [on]
include:
Expand All @@ -119,6 +119,47 @@ jobs:
ctest -C Release --output-on-failure
cd ..
cmake-ubuntu-coverage:
name: cmake build-ubuntu
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04]
shared: [on]
elements: [on]

steps:
- uses: actions/checkout@v2
- name: dump version
run: |
cmake --version
gcc --version
- name: ubuntu-apt-install
run: sudo apt install lcov
- name: cmake-build
run: |
cmake --version
cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=${{ matrix.shared }} -DENABLE_ELEMENTS=${{ matrix.elements }} -DENABLE_DEBUG=on -DENABLE_COVERAGE=on -DCMAKE_BUILD_TYPE=Debug -DTARGET_RPATH=./build/Debug
cmake --build build --config Debug --parallel 4
- name: lint_check
run: ./tools/lint_quiet.sh
- name: test
run: |
cd build
ctest -C Debug --output-on-failure -R cfd
cd ..
- name: collect coverage
run: |
cd build
make lcov_cfd
zip -r lcov_cfd_output.zip lcov_cfd_output
cd ..
- name: upload coverage
uses: actions/upload-artifact@v1
with:
name: output-lcov-cfd-${{ matrix.os }}
path: ./build/lcov_cfd_output.zip

cmake-cpp-support-test:
name: cmake build-ubuntu C++ support test
runs-on: ${{ matrix.os }}
Expand Down Expand Up @@ -155,7 +196,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-18.04]
os: [ubuntu-22.04]
shared: [on]

steps:
Expand Down Expand Up @@ -184,9 +225,25 @@ jobs:
name: valgrind-log
path: ./valgrind.log

arm-build-test:
runs-on: ubuntu-22.04
strategy:
matrix:
platform: ['linux/arm/v7', 'linux/arm64/v8']

steps:
- uses: actions/checkout@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: docker build
run: |
docker buildx build --platform ${{matrix.platform}} -f ./Dockerfile . --no-cache
doxygen-ubuntu:
name: doxygen-check
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check_pre-merge_sprint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-18.04]
os: [ubuntu-22.04]
shared: [on]

steps:
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/create_release-and-upload.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
jobs:
create_releases:
name: create-releases
runs-on: ubuntu-18.04
runs-on: ubuntu-22.04
outputs:
release_url: ${{ steps.output_url.outputs.upload_url }}

Expand Down Expand Up @@ -144,7 +144,6 @@ jobs:
strategy:
fail-fast: false
matrix:
# os: [ubuntu-20.04, ubuntu-18.04]
os_ver: [22, 20, 18]
bin: [gcc, gcc-static]
include:
Expand Down Expand Up @@ -209,7 +208,7 @@ jobs:
strategy:
fail-fast: false
matrix:
alpine: ['3.10', '3.12', '3.13', '3.14', '3.15']
alpine: ['3.10', '3.12', '3.13', '3.14', '3.15', '3.16']

steps:
- name: checkout
Expand Down Expand Up @@ -244,6 +243,11 @@ jobs:
uses: docker://alpine:3.15
with:
entrypoint: /github/workspace/.github/workflows/docker/alpine_build_entrypoint.sh
- name: docker setup 3.16
if: matrix.alpine == '3.16'
uses: docker://alpine:3.16
with:
entrypoint: /github/workspace/.github/workflows/docker/alpine_build_entrypoint.sh
- name: create archive file
run: |
echo "---- dump output data ----"
Expand Down
26 changes: 11 additions & 15 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
FROM node
FROM --platform=$TARGETPLATFORM debian:bullseye-slim

RUN apt-get update && apt-get install -y build-essential python
RUN git clone https://github.com/Kitware/CMake.git /tmp/cmake
WORKDIR /tmp/cmake
RUN git checkout tags/v3.14.2 \
&& ./bootstrap \
&& make \
&& make install
RUN apt-get update \
&& apt-get install -y --no-install-recommends git cmake build-essential \
&& apt-get -y clean \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir /opt/cfd
WORKDIR /opt/cfd
COPY . .
RUN git config --global http.sslverify false

# build
RUN npm install && npm run cmake_all
WORKDIR /workspace
COPY . .

# test
RUN npm run ctest
# build &
RUN ./tools/simple_build.sh \
&& ./tools/simple_test.sh
6 changes: 3 additions & 3 deletions local_resource/external_project_local_setting.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CFD_VERSION=0.4.5
CFDCORE_TARGET_VERSION=refs/tags/v0.4.4
LIBWALLY_TARGET_VERSION=refs/tags/cfd-0.4.7
CFD_VERSION=0.4.6
CFDCORE_TARGET_VERSION=refs/tags/v0.4.5
LIBWALLY_TARGET_VERSION=refs/tags/cfd-0.4.8
CFDCORE_TARGET_URL=cryptogarageinc/cfd-core.git

0 comments on commit 9a39e0e

Please sign in to comment.