2020-12-25 00:02:06 -06:00
|
|
|
name: Build
|
2021-01-10 22:39:23 -05:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
paths-ignore:
|
|
|
|
- 'docs/**'
|
|
|
|
- '**.md'
|
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- 'docs/**'
|
|
|
|
- '**.md'
|
|
|
|
|
2020-12-24 23:29:05 -06:00
|
|
|
jobs:
|
2020-12-24 23:34:12 -06:00
|
|
|
build-linux:
|
2021-01-10 22:39:23 -05:00
|
|
|
runs-on: ubuntu-16.04
|
2020-12-24 23:29:05 -06:00
|
|
|
steps:
|
2020-12-24 23:54:11 -06:00
|
|
|
- name: Cache Qt
|
|
|
|
id: cache-qt
|
|
|
|
uses: actions/cache@v1
|
|
|
|
with:
|
|
|
|
path: ../Qt
|
|
|
|
key: ${{ runner.os }}-QtCache
|
|
|
|
|
|
|
|
- name: Install Qt
|
|
|
|
uses: jurplel/install-qt-action@v2
|
|
|
|
with:
|
|
|
|
cached: ${{ steps.cache-qt.outputs.cache-hit }}
|
2021-01-10 22:39:23 -05:00
|
|
|
|
|
|
|
- name: Install dependencies
|
2021-01-10 22:50:50 -05:00
|
|
|
run: sudo apt-get update
|
|
|
|
sudo apt-get install libgl1-mesa-dev libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-render-util0 libxcb-xinerama0 libzstd-dev
|
2020-12-24 23:54:11 -06:00
|
|
|
|
2021-01-10 22:43:42 -05:00
|
|
|
- name: Create AppImage
|
2021-01-10 22:50:50 -05:00
|
|
|
run: rm -rf build-linux
|
|
|
|
mkdir build-linux
|
|
|
|
cd build-linux
|
|
|
|
qmake ../Serial-Studio.pro CONFIG+=release PREFIX=/usr
|
|
|
|
make INSTALL_ROOT=appdir install
|
|
|
|
wget -c -nv "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage" -O linuxdeployqt
|
|
|
|
chmod a+x linuxdeployqt
|
2021-01-10 22:54:45 -05:00
|
|
|
./linuxdeployqt appdir/usr/share/applications/*.desktop -appimage -bundle-non-qt-libs -extra-plugins=imageformats/libqsvg.so -qmldir=../assets/qml
|
2021-01-10 22:50:50 -05:00
|
|
|
./linuxdeployqt --appimage-extract
|
|
|
|
export PATH=$(readlink -f ./squashfs-root/usr/bin/):$PATH
|
|
|
|
./squashfs-root/usr/bin/appimagetool appdir/
|
|
|
|
find ./appdir -executable -type f -exec ldd {} \; | grep " => /usr" | cut -d " " -f 2-3 | sort | uniq
|
2021-01-10 22:39:23 -05:00
|
|
|
mv *.AppImage SerialStudio-1.0.5-Linux.AppImage
|
|
|
|
|
|
|
|
- name: Upload AppImage
|
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: SerialStudio-1.0.5-Linux.AppImage
|
2021-01-10 22:48:39 -05:00
|
|
|
path: SerialStudio-1.0.5-Linux.AppImage
|
2021-01-10 22:39:23 -05:00
|
|
|
|
2020-12-25 21:17:44 -06:00
|
|
|
build-mac:
|
|
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
|
|
- name: Cache Qt
|
|
|
|
id: cache-qt
|
|
|
|
uses: actions/cache@v1
|
|
|
|
with:
|
|
|
|
path: ../Qt
|
|
|
|
key: ${{ runner.os }}-QtCache
|
|
|
|
|
|
|
|
- name: Install Qt
|
|
|
|
uses: jurplel/install-qt-action@v2
|
|
|
|
with:
|
|
|
|
cached: ${{ steps.cache-qt.outputs.cache-hit }}
|
2021-01-10 22:39:23 -05:00
|
|
|
|
|
|
|
- name: Install create-dmg
|
|
|
|
run: brew install create-dmg
|
|
|
|
|
2020-12-25 21:17:44 -06:00
|
|
|
- name: Compile
|
2021-01-10 22:50:50 -05:00
|
|
|
run: rm -rf build-mac
|
|
|
|
mkdir build-mac
|
|
|
|
cd build-mac
|
|
|
|
qmake ../Serial-Studio.pro
|
|
|
|
make
|
|
|
|
make dmg
|
|
|
|
mv *.dmg SerialStudio-1.0.5-macOS.dmg
|
2021-01-10 22:54:45 -05:00
|
|
|
ls
|
|
|
|
pwd
|
2021-01-10 22:39:23 -05:00
|
|
|
|
|
|
|
- name: Upload DMG
|
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: SerialStudio-1.0.5-macOS.dmg
|
2021-01-10 22:46:40 -05:00
|
|
|
path: SerialStudio-1.0.5-macOS.dmg
|