2019-12-07 15:45:19 +08:00
|
|
|
name: Ubuntu
|
|
|
|
# Qt官方没有linux平台的x86包
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
paths-ignore:
|
|
|
|
- 'README.md'
|
|
|
|
- 'LICENSE'
|
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- 'README.md'
|
|
|
|
- 'LICENSE'
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
name: Build
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-16.04,ubuntu-18.04]
|
|
|
|
qt_ver: [5.12.6]
|
|
|
|
qt_arch: [gcc_64]
|
|
|
|
steps:
|
|
|
|
- name: cacheQt
|
|
|
|
id: UbuntuCacheQt
|
|
|
|
uses: actions/cache@v1
|
|
|
|
with:
|
|
|
|
path: ../Qt/${{matrix.qt_ver}}/${{matrix.qt_arch}}
|
|
|
|
key: ${{ runner.os }}-Qt/${{matrix.qt_ver}}/${{matrix.qt_arch}}
|
2020-06-15 09:08:00 +08:00
|
|
|
# - name: setupQt
|
|
|
|
# if: steps.UbuntuCacheQt.outputs.cache-hit == 'true'
|
|
|
|
# shell: pwsh
|
|
|
|
# env:
|
|
|
|
# QtPath: ../Qt/${{matrix.qt_ver}}/${{matrix.qt_arch}}
|
|
|
|
# run: |
|
|
|
|
# $qt_Path=${env:QtPath}
|
|
|
|
# echo "::set-env name=Qt5_Dir::$qt_Path"
|
|
|
|
# echo "::add-path::$qt_Path/bin"
|
2019-12-07 15:45:19 +08:00
|
|
|
- name: Install Qt
|
2020-06-15 09:08:00 +08:00
|
|
|
# if: steps.UbuntuCacheQt.outputs.cache-hit != 'true'
|
|
|
|
uses: jurplel/install-qt-action@v2.6.3
|
2019-12-07 15:45:19 +08:00
|
|
|
with:
|
|
|
|
version: ${{ matrix.qt_ver }}
|
2020-06-15 09:08:00 +08:00
|
|
|
cached: ${{ steps.UbuntuCacheQt.outputs.cache-hit }}
|
2019-12-07 15:45:19 +08:00
|
|
|
- name: ubuntu install GL library
|
|
|
|
run: sudo apt-get install -y libglew-dev libglfw3-dev
|
|
|
|
- uses: actions/checkout@v1
|
|
|
|
with:
|
|
|
|
fetch-depth: 1
|
|
|
|
- name: build ubuntu
|
|
|
|
run: |
|
|
|
|
qmake
|
|
|
|
make
|