Skip to content

Android CMake - Cross compiling Linux #1262

Android CMake - Cross compiling Linux

Android CMake - Cross compiling Linux #1262

Workflow file for this run

name: build-msys2
on:
push:
paths-ignore:
- '**/*.md'
pull_request:
paths-ignore:
- '**/*.md'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
TARGET: "msys2"
NO_FORCE: 1
GA_CI_SECRET: ${{ secrets.CI_SECRET }}
USE_ARTIFACT: false
DISABLE_WORKFLOW: "true"
jobs:
pre-check:
runs-on: ubuntu-latest
outputs:
workflow_disabled: ${{ steps.check-disabled.outputs.disabled }}
steps:
- name: Check if Workflow is disabled
id: check-disabled
shell: bash
run: |
if [ "${{ env.DISABLE_WORKFLOW }}" == "true" ]; then
echo "disabled=true" >> $GITHUB_ENV
echo "::set-output name=disabled::true"
else
echo "::set-output name=disabled::false"
fi
build-msys2:
if: needs.pre-check.outputs.workflow_disabled != 'true'
needs: pre-check
strategy:
matrix:
flavor:
- mingw64
- ucrt64
- clang64
# - clangarm64
name: ${{ matrix.flavor }}
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- name: Setup msys2
uses: msys2/[email protected]
with:
update: true
release : false
cache: false
msystem: ${{ matrix.flavor }}
install: >-
base-devel
unzip
dos2unix
git
pacboy: >-
gcc:p
cmake:p
gperf:p
libxml2:p
python3:p
wget2:p
libpng:p
zlib:p
- name: Determine Release
id: vars
shell: bash
run: |
if [[ "${{ github.ref }}" == refs/tags/* ]]; then
echo "RELEASE=${{ github.ref_name }}" >> $GITHUB_ENV
elif [[ "${{ github.ref }}" == "refs/heads/master" ]]; then
echo "RELEASE=nightly" >> $GITHUB_ENV
elif [[ "${{ github.ref }}" == "refs/heads/bleeding" ]]; then
echo "RELEASE=latest" >> $GITHUB_ENV
else
echo "RELEASE=latest" >> $GITHUB_ENV
fi
- name: Clone repository
uses: actions/[email protected]
- name: Build
working-directory: ${{env.GITHUB_WORKSPACE}}
run: scripts/build.sh
- name: Package
if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding' || contains(github.ref, 'refs/tags/'))
working-directory: ${{ env.GITHUB_WORKSPACE }}
run: scripts/package.sh
env:
BUNDLE: ${{ matrix.bundle }}
- name: List output directory2
run: ls -lah out/
- name: Update Release
if: github.repository == 'openframeworks/apothecary' && github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/master' || github.ref == 'refs/heads/bleeding')
uses: softprops/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag_name: ${{ env.RELEASE }}
draft: false
files: out/openFrameworksLibs_${{ env.RELEASE }}_${{ env.TARGET }}_${{ matrix.flavor }}.zip