| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- name: CI
- on:
- # on each push and manual trigger
- push:
- branches: [ master ]
- paths-ignore: [ "**/Readme.md" ]
- workflow_dispatch:
- jobs:
- build:
- runs-on: ${{ matrix.operating-system }}
- strategy:
- matrix:
- operating-system: [ubuntu-latest, windows-latest, macos-latest]
- # currently stable="Lazarus 2.2.0 / FPC 3.2.2" with [email protected]
- lazarus-versions: [stable]
- steps:
- - uses: actions/checkout@v2
- - name: Install Lazarus
- uses: gcarreno/[email protected]
- with:
- lazarus-version: ${{ matrix.lazarus-versions }}
- - name: Print Lazarus version
- run: lazbuild --version
- - name: Setup Linux
- if: runner.os == 'Linux'
- shell: bash
- run: |
- # needed for SDL and GL demos
- sudo apt install libsdl1.2-dev -y
- # to build LCL demos with Qt5 backend
- sudo apt install libqt5pas-dev -y
- - name: Build demos with FPC (Linux)
- if: runner.os == 'Linux'
- shell: bash
- run: |
- cd Scripts
- ./BuildDemosFPC.sh
- ./BuildExtDemosFPC.sh
- ./Clean.sh --clean-also-bin-dirs
- - name: Build demos with Lazarus
- shell: bash
- run: |
- cd Demos/ObjectPascal
-
- lazbuild --bm="Release" "Benchmark/Bench.lpi"
- lazbuild --bm="Release" "VampConvert/VampConvert.lpi"
-
- if [ "$RUNNER_OS" == "Linux" ]; then
- lazbuild --ws=qt5 --bm="Release" "LCLImager/lclimager.lpi"
- lazbuild --ws=qt5 --bm="Release" "ImageBrowser/ImgBrowser.lpi"
- fi
-
- if [ "$RUNNER_OS" != "macOS" ]; then
- lazbuild --bm="Release" "LCLImager/lclimager.lpi"
- lazbuild --bm="Release" "ImageBrowser/ImgBrowser.lpi"
- lazbuild --bm="Release" "OpenGLDemo/OpenGLDemo.lpi"
- lazbuild --bm="Release" "SDLDemo/SDLDemo.lpi"
- fi
-
- if [ "$RUNNER_OS" == "Windows" ]; then
- lazbuild --bm="Release" "D3DDemo/D3DDemo.lpi"
- fi
-
- if [ "$RUNNER_OS" == "macOS" ]; then
- lazbuild --ws=cocoa --bm="Release" "LCLImager/lclimager.lpi"
- lazbuild --ws=cocoa --bm="Release" "ImageBrowser/ImgBrowser.lpi"
- fi
- - name: List Demos Bin directory
- shell: bash
- run: ls Demos/Bin
- - name: Run demos
- shell: bash
- run: |
- cd Demos/Bin
- ./Bench
- ./VampConvert -h
- - name: Compile Lazarus Packages
- shell: bash
- run: |
- lazbuild "Packages/VampyreImagingPackage.lpk"
- lazbuild "Packages/VampyreImagingPackageExt.lpk"
- - uses: actions/upload-artifact@v2
- with:
- name: ci-artifacts-${{ matrix.operating-system }}-laz-${{ matrix.lazarus-versions }}
- # exclude compiled units etc.
- path: |
- Demos/Bin
- !Demos/Bin/Dcu
- if-no-files-found: error
|