mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-28 03:44:07 +00:00
110 lines
3.6 KiB
YAML
110 lines
3.6 KiB
YAML
name: CMake Test
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
on:
|
|
workflow_dispatch:
|
|
# push:
|
|
# branches:
|
|
# - dev
|
|
# pull_request:
|
|
# types: [opened, synchronize, reopened]
|
|
jobs:
|
|
job1:
|
|
name: Build and analyze
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/setup-python@v3
|
|
with:
|
|
python-version: '3.9'
|
|
- name: Install Qt
|
|
uses: jurplel/install-qt-action@v3
|
|
with:
|
|
version: 6.3.2
|
|
arch: gcc_64
|
|
cached: 'false'
|
|
#serialport linuxdeploy need serialport to work.
|
|
modules: qtwebengine qtwebchannel qtpositioning qt5compat qtmultimedia qtimageformats qtserialport
|
|
setup-python: 'false'
|
|
|
|
- name: ubuntu install thirdparty dependencies
|
|
run: |
|
|
sudo apt-get install git pkg-config build-essential
|
|
sudo apt-get install libvorbis-dev zlib1g-dev libhunspell-dev x11proto-record-dev
|
|
sudo apt-get install libxtst-dev liblzo2-dev libbz2-dev
|
|
sudo apt-get install libao-dev libavutil-dev libavformat-dev libtiff5-dev libeb16-dev
|
|
sudo apt-get install doxygen libzstd-dev libxkbcommon-dev libgstreamer-plugins-base1.0-0 libgstreamer-gl1.0-0
|
|
sudo ln -sf /usr/bin/x86_64-linux-gnu-ld.gold /usr/bin/ld
|
|
|
|
#build opencc
|
|
git clone https://github.com/BYVoid/OpenCC
|
|
cd OpenCC/
|
|
make PREFIX=/usr -j$(nproc)
|
|
sudo make install
|
|
cd ..
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
|
submodules: true
|
|
|
|
- name: Run build-wrapper
|
|
run: |
|
|
cmake .
|
|
cmake --build .
|
|
|
|
job2:
|
|
name: Build and analyze
|
|
runs-on: windows-2019
|
|
steps:
|
|
- uses: actions/setup-python@v3
|
|
with:
|
|
python-version: '3.9'
|
|
- name: Install Qt
|
|
uses: jurplel/install-qt-action@v3
|
|
with:
|
|
version: 6.3.2
|
|
arch: gcc_64
|
|
cached: 'false'
|
|
#serialport linuxdeploy need serialport to work.
|
|
modules: qtwebengine qtwebchannel qtpositioning qt5compat qtmultimedia qtimageformats qtserialport
|
|
setup-python: 'false'
|
|
- uses: ilammy/msvc-dev-cmd@v1
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
|
submodules: true
|
|
|
|
- name: Run build-wrapper
|
|
run: |
|
|
cmake .
|
|
cmake --build .
|
|
job3:
|
|
name: Build and analyze
|
|
runs-on: macos-12
|
|
steps:
|
|
- uses: actions/setup-python@v3
|
|
with:
|
|
python-version: '3.9'
|
|
- name: Install Qt
|
|
uses: jurplel/install-qt-action@v3
|
|
with:
|
|
version: 6.3.2
|
|
arch: gcc_64
|
|
cached: 'false'
|
|
#serialport linuxdeploy need serialport to work.
|
|
modules: qtwebengine qtwebchannel qtpositioning qt5compat qtmultimedia qtimageformats qtserialport
|
|
setup-python: 'false'
|
|
- uses: ilammy/msvc-dev-cmd@v1
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
|
submodules: true
|
|
- name: install dependencies
|
|
run: |
|
|
brew uninstall opencc hunspell ffmpeg@5 ffmpeg@4 libtiff xz lzo libogg libvorbis zstd || true
|
|
brew install create-dmg
|
|
- name: Run build-wrapper
|
|
run: |
|
|
cmake .
|
|
cmake --build .
|
|
|