Skip to content

try to fix openmp gcc linker error #2

try to fix openmp gcc linker error

try to fix openmp gcc linker error #2

Workflow file for this run

name: linux
on:
workflow_dispatch:
pull_request:
types:
- opened
push:
paths-ignore:
- '.github/workflows/windows.yaml'
# - '.github/workflows/macos.yaml'
- 'README.md'
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
arch: [x86_64]
mode: [release]
compiler: [clang, gcc]
steps:
- name: Checkout repository
uses: actions/checkout@v3
# Install system dependencies (opengl)
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get -y install mesa-common-dev
- name: Set xmake env
run: echo "XMAKE_GLOBALDIR=${{ runner.workspace }}/xmake-global" >> $GITHUB_ENV
# Install xmake
- name: Setup xmake
uses: xmake-io/github-action-setup-xmake@v1
with:
xmake-version: latest
actions-cache-folder: .xmake-cache
# Update xmake repository
- name: Update xmake repository
run: xmake repo --update
# Create xmake dependencies hash
- name: Retrieve dependencies hash
id: dep_hash
run: echo "hash=$(xmake l utils.ci.packageskey)" >> $GITHUB_OUTPUT
# Cache xmake dependencies
- name: Retrieve cached xmake dependencies
uses: actions/cache@v3
with:
path: ${{ env.XMAKE_GLOBALDIR }}/.xmake/packages
key: Linux-${{ matrix.compiler }}-${{ matrix.arch }}-${{ matrix.mode }}-${{ steps.dep_hash.outputs.hash }}
# Config xmake
- name: Config
run: |
xmake f -y -a ${{ matrix.arch }} -m ${{ matrix.mode }} --toolchain=${{ matrix.compiler }}
# Build
- name: Build
run: |
xmake -vD
- name: Test
run: |
xmake test