setup qt outdated #77
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push, pull_request] | |
env: | |
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true' | |
jobs: | |
MacOS: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@master | |
with: | |
python-version: '3.10' | |
- name: Unfuck Brew | |
run: | | |
cd /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask | |
git pull | |
brew install nettle | |
- uses: jurplel/install-qt-action@v3 | |
id: qt | |
with: | |
version: 5.15.1 | |
target: desktop | |
cache: true | |
cache-key-prefix: qt | |
- name: Install dependencies | |
run: | | |
${{github.workspace}}/libs/libarchive/build/ci/github_actions/macos.sh prepare | |
export LIBRARY_PATH=$LIBRARY_PATH:$(brew --prefix zstd)/lib/ | |
- name: Autogen | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a autogen | |
env: | |
BS: cmake | |
- name: Configure | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a configure | |
env: | |
BS: cmake | |
- name: Install | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a install | |
env: | |
BS: cmake | |
- name: Copy archive.h | |
working-directory: ${{github.workspace}} | |
run : cp ./libs/libarchive/libarchive/archive.h ./libs/QArchive/include/archive.h | |
- name: Copy archive_entry.h | |
working-directory: ${{github.workspace}} | |
run : cp ./libs/libarchive/libarchive/archive_entry.h ./libs/QArchive/include/archive_entry.h | |
- name: QMake | |
run: | | |
qmake QMAKE_CXXFLAGS+="-fno-sized-deallocation" | |
- name: Make | |
run: | | |
export LIBRARY_PATH=$LIBRARY_PATH:$(brew --prefix zstd)/lib/ | |
export LIBRARY_PATH=$LIBRARY_PATH:$(brew --prefix nettle)/lib/ | |
${{steps.qt.outputs.make}} | |
- name: Deploy Mac | |
if: matrix.os == 'macos-latest' | |
working-directory: ${{github.workspace}}/launcher/bin/ | |
shell: bash | |
run: | | |
macdeployqt launcher.app | |
hdiutil create -volname "AO Launcher" -srcfolder "./launcher.app" -ov -format UDZO "launcher.dmg" | |
rm -r ./launcher.app/ | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: launcher-macos-${{ github.sha }} | |
path: ${{ github.workspace }}/launcher/bin/ | |
- name: Setup tmate session | |
if: ${{ failure() }} | |
uses: mxschmitt/action-tmate@v3 | |
timeout-minutes: 15 | |
Ubuntu: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- uses: jurplel/install-qt-action@v3 | |
id: qt | |
with: | |
version: 5.15.1 | |
target: desktop | |
cache: true | |
cache-key-prefix: qt | |
- name: Install dependencies | |
run: sudo apt-get install -y autoconf automake build-essential cmake git libarchive-dev libssl-dev nettle-dev libmbedtls-dev libacl1-dev libbz2-dev liblzma-dev liblz4-dev libzstd-dev lzop pkg-config zlib1g-dev | |
- name: Autogen | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a autogen | |
env: | |
BS: cmake | |
- name: Configure | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a configure | |
env: | |
BS: cmake | |
CRYPTO: mbedtls | |
- name: Install | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/build.sh -a install | |
env: | |
BS: cmake | |
- name: QMake | |
run: | | |
qmake QMAKE_CXXFLAGS+="-fno-sized-deallocation" | |
- name: Make | |
run: | | |
${{steps.qt.outputs.make}} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: launcher-ubuntu-${{ github.sha }} | |
path: ${{ github.workspace }}/launcher/bin/ | |
- name: Setup tmate session | |
if: ${{ failure() }} | |
uses: mxschmitt/action-tmate@v3 | |
timeout-minutes: 15 | |
Windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- uses: jurplel/install-qt-action@v3 | |
id: qt | |
with: | |
version: 5.15.1 | |
target: desktop | |
arch: win32_mingw81 | |
tools: 'tools_mingw,qt.tools.win32_mingw810' | |
cache: true | |
cache-key-prefix: qt | |
- name: Install dependencies | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/github_actions/ci.cmd deplibs | |
shell: cmd | |
env: | |
BE: mingw-gcc | |
- name: Configure | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/github_actions/ci.cmd configure | |
shell: cmd | |
env: | |
BE: mingw-gcc | |
- name: Install | |
working-directory: ${{github.workspace}}/libs/libarchive/ | |
run: ./build/ci/github_actions/ci.cmd install | |
shell: cmd | |
env: | |
BE: mingw-gcc | |
- name: QMake | |
run: | | |
qmake QMAKE_CXXFLAGS+="-fno-sized-deallocation" INCLUDEPATH+="C:/Progra~2/libarchive/include/" LIBS+="-LC:/Progra~2/libarchive/lib/" LIBS+="-LC:/Progra~2/libarchive/bin/" | |
- name: Make | |
shell: bash | |
run: | | |
${{steps.qt.outputs.make}} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: launcher-windows-mingw-${{ github.sha }} | |
path: ${{ github.workspace }}/launcher/bin/ | |
- name: Setup tmate session | |
if: ${{ failure() }} | |
uses: mxschmitt/action-tmate@v3 | |
timeout-minutes: 15 |